Window Class Reference

An abstract user interface window. More...

#include <yatecbase.h>

Inheritance diagram for Window:

GenObject List of all members.

Public Member Functions

 Window (const char *id=0)
virtual ~Window ()
virtual const StringtoString () const
virtual void title (const String &text)
virtual void context (const String &text)
virtual bool setParams (const NamedList &params)
virtual void setOver (const Window *parent)=0
virtual bool hasElement (const String &name)=0
virtual bool setActive (const String &name, bool active)=0
virtual bool setFocus (const String &name, bool select=false)=0
virtual bool setShow (const String &name, bool visible)=0
virtual bool setText (const String &name, const String &text)=0
virtual bool setCheck (const String &name, bool checked)=0
virtual bool setSelect (const String &name, const String &item)=0
virtual bool setUrgent (const String &name, bool urgent)=0
virtual bool hasOption (const String &name, const String &item)=0
virtual bool addOption (const String &name, const String &item, bool atStart=false, const String &text=String::empty())=0
virtual bool delOption (const String &name, const String &item)=0
virtual bool addTableRow (const String &name, const String &item, const NamedList *data=0, bool atStart=false)
virtual bool delTableRow (const String &name, const String &item)
virtual bool setTableRow (const String &name, const String &item, const NamedList *data)
virtual bool getTableRow (const String &name, const String &item, NamedList *data=0)
virtual bool clearTable (const String &name)
virtual bool getText (const String &name, String &text)=0
virtual bool getCheck (const String &name, bool &checked)=0
virtual bool getSelect (const String &name, String &item)=0
virtual void populate ()=0
virtual void init ()=0
virtual void show ()=0
virtual void hide ()=0
virtual void size (int width, int height)=0
virtual void move (int x, int y)=0
virtual void moveRel (int dx, int dy)=0
virtual bool related (const Window *wnd) const
virtual void menu (int x, int y)=0
const Stringid () const
const Stringtitle () const
const Stringcontext () const
bool visible () const
void visible (bool yes)
bool master () const
bool popup () const

Protected Attributes

String m_id
String m_title
String m_context
bool m_visible
bool m_master
bool m_popup

Friends

class Client

Detailed Description

An abstract user interface window.

A window is the basic user interface element. Everything inside is implementation specific functionality.


Constructor & Destructor Documentation

Window ( const char *  id = 0  ) 

Constructor, creates a new windows with an ID

Parameters:
id String identifier of the new window

virtual ~Window (  )  [virtual]

Destructor


Member Function Documentation

virtual const String& toString (  )  const [virtual]

Retrive the standard name of this Window, used to search in lists

Returns:
Identifier of this window

Reimplemented from GenObject.

virtual void context ( const String text  )  [virtual]

Set the contextual information previously associated with this window

Parameters:
text New contextual information

virtual bool setParams ( const NamedList params  )  [virtual]

Set window parameters or widget contents

Parameters:
params List of parameters to set in the window and its widgets
Returns:
True if all parameters could be set

virtual void setOver ( const Window parent  )  [pure virtual]

Force this window on top of another one which becomes its parent

Parameters:
parent Window to force as parent of this one

virtual bool hasElement ( const String name  )  [pure virtual]

Check if this window has an element by name

Parameters:
name Name of the element to search for
Returns:
True if one element with the given name exists

virtual bool setActive ( const String name,
bool  active 
) [pure virtual]

Set an element as interactive in the window

Parameters:
name Name of the element
active True to make interactive, false to disallow interaction
Returns:
True if the operation was successfull

virtual bool setFocus ( const String name,
bool  select = false 
) [pure virtual]

Set an element as receiving input in the window

Parameters:
name Name of the element
select Also select the content of the focused element
Returns:
True if the operation was successfull

virtual bool setShow ( const String name,
bool  visible 
) [pure virtual]

Set the visibility of an element in the window

Parameters:
name Name of the element
visible True to make element visible, false to hide it
Returns:
True if the operation was successfull

virtual bool setText ( const String name,
const String text 
) [pure virtual]

Set the displayed text of an element in the window

Parameters:
name Name of the element
text Text value to set in the element
Returns:
True if the operation was successfull

virtual bool setCheck ( const String name,
bool  checked 
) [pure virtual]

Set the checked or toggled status of an element in the window

Parameters:
name Name of the element
checked True to make element checked or toggled
Returns:
True if the operation was successfull

virtual bool setSelect ( const String name,
const String item 
) [pure virtual]

Set the selection of an item in an element in the window

Parameters:
name Name of the element
item Name of the item that should be selected
Returns:
True if the operation was successfull

virtual bool setUrgent ( const String name,
bool  urgent 
) [pure virtual]

Flag an element as requiring immediate attention

Parameters:
name Name of the element
urgent True if the element requires immediate attention
Returns:
True if the operation was successfull

virtual bool hasOption ( const String name,
const String item 
) [pure virtual]

Check if an element has an item by its name

Parameters:
name Name of the element to search for
item Name of the item that should be searched
Returns:
True if one item with the given name exists in the element

virtual bool addOption ( const String name,
const String item,
bool  atStart = false,
const String text = String::empty() 
) [pure virtual]

Add an item to an element that supports such an operation (list)

Parameters:
name Name of the element
item Name of the item to add
atStart True to insert item on the first position, false to append
text Displayed text to associate with the item (not all lists support it)
Returns:
True if the operation was successfull

virtual bool delOption ( const String name,
const String item 
) [pure virtual]

Remove an item from an element (list)

Parameters:
name Name of the element
item Name of the item to remove
Returns:
True if the operation was successfull

const String& id (  )  const [inline]

Retrive the standard name of this Window

Returns:
Identifier of this window

const String& context (  )  const [inline]

Get the contextual information previously associated with this window

Returns:
String contextual information

bool visible (  )  const [inline]

Get the visibility status of this window

Returns:
True if window is visible, false if it's hidden

void visible ( bool  yes  )  [inline]

Set the visibility status of this window

Parameters:
yes True if window should be visible

bool master (  )  const [inline]

Check if this window is a master (topmost) window

Returns:
True if this window is topmost

bool popup (  )  const [inline]

Check if this window is a popup window

Returns:
True if this window is initially hidden


The documentation for this class was generated from the following file:
Generated on Mon Oct 22 07:43:09 2007 for Yate by  doxygen 1.5.2