FXList

class FXList

List Widget

Inheritance:


Public Methods

[more] FXList(FXComposite* p, FXint nvis, FXObject* tgt=NULL, FXSelector sel=0, FXuint opts=LIST_NORMAL, FXint x=0, FXint y=0, FXint w=0, FXint h=0)
Construct a list with nvis visible items; the list is initially empty
[more]virtual void create()
Create server-side resources
[more]virtual void detach()
Detach server-side resources
[more]virtual FXint getDefaultWidth()
Return default width
[more]virtual FXint getDefaultHeight()
Return default height
[more]virtual FXint getContentWidth()
Compute and return content width
[more]virtual FXint getContentHeight()
Return content height
[more]virtual void recalc()
Recalculate layout
[more]virtual FXbool canFocus() const
List widget can receive focus
[more]virtual void setFocus()
Move the focus to this window
[more]virtual void killFocus()
Remove the focus from this window
[more]FXint getNumItems() const
Return the number of items in the list
[more]FXint getNumVisible() const
Return number of visible items
[more]void setNumVisible(FXint nvis)
Change the number of visible items
[more]FXListItem* retrieveItem(FXint index) const
Return the item at the given index
[more]FXint replaceItem(FXint index, FXListItem* item, FXbool notify=FALSE)
Replace the item with a [possibly subclassed] item
[more]FXint replaceItem(FXint index, const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Replace items text, icon, and user-data pointer
[more]FXint insertItem(FXint index, FXListItem* item, FXbool notify=FALSE)
Insert a new [possibly subclassed] item at the give index
[more]FXint insertItem(FXint index, const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Insert item at index with given text, icon, and user-data pointer
[more]FXint appendItem(FXListItem* item, FXbool notify=FALSE)
Append a [possibly subclassed] item to the list
[more]FXint appendItem(const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Append new item with given text and optional icon, and user-data pointer
[more]FXint prependItem(FXListItem* item, FXbool notify=FALSE)
Prepend a [possibly subclassed] item to the list
[more]FXint prependItem(const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Prepend new item with given text and optional icon, and user-data pointer
[more]void removeItem(FXint index, FXbool notify=FALSE)
Remove item from list
[more]void clearItems(FXbool notify=FALSE)
Remove all items from list
[more]FXint getItemWidth(FXint index) const
Return item width
[more]FXint getItemHeight(FXint index) const
Return item height
[more]FXint getItemAt(FXint x, FXint y) const
Return index of item at x,y, if any
[more]FXint hitItem(FXint index, FXint x, FXint y) const
Return item hit code: 0 no hit; 1 hit the icon; 2 hit the text
[more]FXint findItem(const FXString& text, FXint start=-1, FXuint flags=SEARCH_FORWARD|SEARCH_WRAP) const
Search items for item by name, starting from start item; the flags argument controls the search direction, and case sensitivity
[more]void makeItemVisible(FXint index)
Scroll to bring item into view
[more]void setItemText(FXint index, const FXString& text)
Change item text
[more]FXString getItemText(FXint index) const
Return item text
[more]void setItemIcon(FXint index, FXIcon* icon)
Change item icon
[more]FXIcon* getItemIcon(FXint index) const
Return item icon, if any
[more]void setItemData(FXint index, void* ptr)
Change item user-data pointer
[more]void* getItemData(FXint index) const
Return item user-data pointer
[more]FXbool isItemSelected(FXint index) const
Return TRUE if item is selected
[more]FXbool isItemCurrent(FXint index) const
Return TRUE if item is current
[more]FXbool isItemVisible(FXint index) const
Return TRUE if item is visible
[more]FXbool isItemEnabled(FXint index) const
Return TRUE if item is enabled
[more]void updateItem(FXint index)
Repaint item
[more]FXbool enableItem(FXint index)
Enable item
[more]FXbool disableItem(FXint index)
Disable item
[more]FXbool selectItem(FXint index, FXbool notify=FALSE)
Select item
[more]FXbool deselectItem(FXint index, FXbool notify=FALSE)
Deselect item
[more]FXbool toggleItem(FXint index, FXbool notify=FALSE)
Toggle item selection state
[more]void setCurrentItem(FXint index, FXbool notify=FALSE)
Change current item
[more]FXint getCurrentItem() const
Return current item, if any
[more]void setAnchorItem(FXint index)
Change anchor item
[more]FXint getAnchorItem() const
Return anchor item, if any
[more]FXint getCursorItem() const
Get item under the cursor, if any
[more]FXbool extendSelection(FXint index, FXbool notify=FALSE)
Extend selection from anchor item to index
[more]FXbool killSelection(FXbool notify=FALSE)
Deselect all items
[more]void sortItems()
Sort items using current sort function
[more]void setFont(FXFont* fnt)
Change text font
[more]FXFont* getFont() const
Return text font
[more]FXColor getTextColor() const
Return normal text color
[more]void setTextColor(FXColor clr)
Change normal text color
[more]FXColor getSelBackColor() const
Return selected text background
[more]void setSelBackColor(FXColor clr)
Change selected text background
[more]FXColor getSelTextColor() const
Return selected text color
[more]void setSelTextColor(FXColor clr)
Change selected text color
[more]FXListSortFunc getSortFunc() const
Return sort function
[more]void setSortFunc(FXListSortFunc func)
Change sort function
[more]FXuint getListStyle() const
Return list style
[more]void setListStyle(FXuint style)
Change list style
[more]void setHelpText(const FXString& text)
Set the status line help text for this list
[more]FXString getHelpText() const
Get the status line help text for this list
[more]virtual void save(FXStream& store) const
Save list to a stream
[more]virtual void load(FXStream& store)
Load list from a stream
[more]virtual ~FXList()
Destructor


Inherited from FXScrollArea:

Public Methods

ovirtual FXint getViewportHeight()
ovoid setScrollStyle(FXuint style)
oFXuint getScrollStyle() const
oFXbool isHorizontalScrollable() const
oFXbool isVerticalScrollable() const
oFXScrollbar* horizontalScrollbar() const
oFXScrollbar* verticalScrollbar() const
oFXint getXPosition() const
oFXint getYPosition() const
ovoid setPosition(FXint x, FXint y)
ovoid getPosition(FXint& x, FXint& y) const
ovirtual void moveContents(FXint x, FXint y)


Inherited from FXComposite:

Public Methods

ovirtual void destroy()
oFXint maxChildWidth() const
oFXint maxChildHeight() const
ovirtual FXbool isComposite() const


Inherited from FXWindow:

Public Methods

oFXWindow* getParent() const
oFXWindow* getOwner() const
oFXWindow* getShell() const
oFXWindow* getRoot() const
oFXWindow* getNext() const
oFXWindow* getPrev() const
oFXWindow* getFirst() const
oFXWindow* getLast() const
oFXWindow* getFocus() const
ovoid setKey(FXuint k)
oFXuint getKey() const
ovoid setTarget(FXObject* t)
oFXObject* getTarget() const
ovoid setSelector(FXSelector sel)
oFXSelector getSelector() const
oFXint getX() const
oFXint getY() const
ovirtual FXint getWidthForHeight(FXint givenheight)
ovirtual FXint getHeightForWidth(FXint givenwidth)
ovoid setX(FXint x)
ovoid setY(FXint y)
ovoid setWidth(FXint w)
ovoid setHeight(FXint h)
ovoid setLayoutHints(FXuint lout)
oFXuint getLayoutHints() const
oFXAccelTable* getAccelTable() const
ovoid setAccelTable(FXAccelTable* acceltable)
ovoid addHotKey(FXHotKey code)
ovoid remHotKey(FXHotKey code)
oFXbool isShell() const
oFXbool isChildOf(const FXWindow* window) const
oFXbool containsChild(const FXWindow* child) const
oFXWindow* getChildAt(FXint x, FXint y) const
oFXint numChildren() const
oFXint indexOfChild(const FXWindow* window) const
oFXWindow* childAtIndex(FXint index) const
ostatic FXWindow* commonAncestor(FXWindow* a, FXWindow* b)
ovoid setDefaultCursor(FXCursor* cur)
oFXCursor* getDefaultCursor() const
ovoid setDragCursor(FXCursor* cur)
oFXCursor* getDragCursor() const
oFXint getCursorPosition(FXint& x, FXint& y, FXuint& buttons) const
oFXint setCursorPosition(FXint x, FXint y)
oFXbool isEnabled() const
oFXbool isActive() const
oFXbool hasFocus() const
ovirtual void setDefault(FXbool enable=TRUE)
oFXbool isDefault() const
ovoid setInitial(FXbool enable=TRUE)
oFXbool isInitial() const
ovirtual void enable()
ovirtual void disable()
ovirtual void raise()
ovirtual void lower()
ovirtual void move(FXint x, FXint y)
ovirtual void resize(FXint w, FXint h)
ovirtual void position(FXint x, FXint y, FXint w, FXint h)
ovoid forceRefresh()
ovirtual void reparent(FXWindow* newparent)
ovoid scroll(FXint x, FXint y, FXint w, FXint h, FXint dx, FXint dy)
ovoid update(FXint x, FXint y, FXint w, FXint h)
ovoid update()
ovoid repaint(FXint x, FXint y, FXint w, FXint h)
ovoid repaint()
ovoid grab()
ovoid ungrab()
oFXbool grabbed() const
ovoid grabKeyboard()
ovoid ungrabKeyboard()
oFXbool grabbedKeyboard() const
ovirtual void show()
ovirtual void hide()
oFXbool shown() const
oFXbool underCursor() const
oFXbool hasSelection() const
oFXbool acquireSelection(const FXDragType* types, FXuint numtypes)
oFXbool releaseSelection()
oFXbool hasClipboard() const
oFXbool acquireClipboard(const FXDragType* types, FXuint numtypes)
oFXbool releaseClipboard()
ovoid dropEnable()
ovoid dropDisable()
oFXbool isDropEnabled() const
oFXbool isDragging() const
oFXbool beginDrag(const FXDragType* types, FXuint numtypes)
oFXbool handleDrag(FXint x, FXint y, FXDragAction action=DRAG_COPY)
oFXbool endDrag(FXbool drop=TRUE)
oFXbool isDropTarget() const
ovoid setDragRectangle(FXint x, FXint y, FXint w, FXint h, FXbool wantupdates=TRUE)
ovoid clearDragRectangle()
ovoid acceptDrop(FXDragAction action=DRAG_ACCEPT)
oFXDragAction didAccept() const
oFXbool inquireDNDTypes(FXDNDOrigin origin, FXDragType*& types, FXuint& numtypes)
oFXbool offeredDNDType(FXDNDOrigin origin, FXDragType type)
oFXDragAction inquireDNDAction() const
oFXbool setDNDData(FXDNDOrigin origin, FXDragType type, FXuchar* data, FXuint size)
oFXbool getDNDData(FXDNDOrigin origin, FXDragType type, FXuchar*& data, FXuint& size)
ovirtual FXbool contains(FXint parentx, FXint parenty) const
ovoid translateCoordinatesFrom(FXint& tox, FXint& toy, const FXWindow* fromwindow, FXint fromx, FXint fromy) const
ovoid translateCoordinatesTo(FXint& tox, FXint& toy, const FXWindow* towindow, FXint fromx, FXint fromy) const
ovirtual void setBackColor(FXColor clr)
oFXColor getBackColor() const
ovoid linkBefore(FXWindow* sibling)
ovoid linkAfter(FXWindow* sibling)


Inherited from FXDrawable:

Public Methods

oFXint getWidth() const
oFXint getHeight() const
oFXVisual* getVisual() const
ovoid setVisual(FXVisual* vis)


Inherited from FXId:

Public Methods

oFXApp* getApp() const
oFXID id() const
ovoid setUserData(void* ptr)
ovoid* getUserData() const


Inherited from FXObject:

Public Methods

oconst FXchar* getClassName() const
oFXbool isMemberOf(const FXMetaClass* metaclass) const


Documentation

List Widget
o FXList(FXComposite* p, FXint nvis, FXObject* tgt=NULL, FXSelector sel=0, FXuint opts=LIST_NORMAL, FXint x=0, FXint y=0, FXint w=0, FXint h=0)
Construct a list with nvis visible items; the list is initially empty

ovirtual void create()
Create server-side resources

ovirtual void detach()
Detach server-side resources

ovirtual FXint getDefaultWidth()
Return default width

ovirtual FXint getDefaultHeight()
Return default height

ovirtual FXint getContentWidth()
Compute and return content width

ovirtual FXint getContentHeight()
Return content height

ovirtual void recalc()
Recalculate layout

ovirtual FXbool canFocus() const
List widget can receive focus

ovirtual void setFocus()
Move the focus to this window

ovirtual void killFocus()
Remove the focus from this window

oFXint getNumItems() const
Return the number of items in the list

oFXint getNumVisible() const
Return number of visible items

ovoid setNumVisible(FXint nvis)
Change the number of visible items

oFXListItem* retrieveItem(FXint index) const
Return the item at the given index

oFXint replaceItem(FXint index, FXListItem* item, FXbool notify=FALSE)
Replace the item with a [possibly subclassed] item

oFXint replaceItem(FXint index, const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Replace items text, icon, and user-data pointer

oFXint insertItem(FXint index, FXListItem* item, FXbool notify=FALSE)
Insert a new [possibly subclassed] item at the give index

oFXint insertItem(FXint index, const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Insert item at index with given text, icon, and user-data pointer

oFXint appendItem(FXListItem* item, FXbool notify=FALSE)
Append a [possibly subclassed] item to the list

oFXint appendItem(const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Append new item with given text and optional icon, and user-data pointer

oFXint prependItem(FXListItem* item, FXbool notify=FALSE)
Prepend a [possibly subclassed] item to the list

oFXint prependItem(const FXString& text, FXIcon* icon=NULL, void* ptr=NULL, FXbool notify=FALSE)
Prepend new item with given text and optional icon, and user-data pointer

ovoid removeItem(FXint index, FXbool notify=FALSE)
Remove item from list

ovoid clearItems(FXbool notify=FALSE)
Remove all items from list

oFXint getItemWidth(FXint index) const
Return item width

oFXint getItemHeight(FXint index) const
Return item height

oFXint getItemAt(FXint x, FXint y) const
Return index of item at x,y, if any

oFXint hitItem(FXint index, FXint x, FXint y) const
Return item hit code: 0 no hit; 1 hit the icon; 2 hit the text

oFXint findItem(const FXString& text, FXint start=-1, FXuint flags=SEARCH_FORWARD|SEARCH_WRAP) const
Search items for item by name, starting from start item; the flags argument controls the search direction, and case sensitivity

ovoid makeItemVisible(FXint index)
Scroll to bring item into view

ovoid setItemText(FXint index, const FXString& text)
Change item text

oFXString getItemText(FXint index) const
Return item text

ovoid setItemIcon(FXint index, FXIcon* icon)
Change item icon

oFXIcon* getItemIcon(FXint index) const
Return item icon, if any

ovoid setItemData(FXint index, void* ptr)
Change item user-data pointer

ovoid* getItemData(FXint index) const
Return item user-data pointer

oFXbool isItemSelected(FXint index) const
Return TRUE if item is selected

oFXbool isItemCurrent(FXint index) const
Return TRUE if item is current

oFXbool isItemVisible(FXint index) const
Return TRUE if item is visible

oFXbool isItemEnabled(FXint index) const
Return TRUE if item is enabled

ovoid updateItem(FXint index)
Repaint item

oFXbool enableItem(FXint index)
Enable item

oFXbool disableItem(FXint index)
Disable item

oFXbool selectItem(FXint index, FXbool notify=FALSE)
Select item

oFXbool deselectItem(FXint index, FXbool notify=FALSE)
Deselect item

oFXbool toggleItem(FXint index, FXbool notify=FALSE)
Toggle item selection state

ovoid setCurrentItem(FXint index, FXbool notify=FALSE)
Change current item

oFXint getCurrentItem() const
Return current item, if any

ovoid setAnchorItem(FXint index)
Change anchor item

oFXint getAnchorItem() const
Return anchor item, if any

oFXint getCursorItem() const
Get item under the cursor, if any

oFXbool extendSelection(FXint index, FXbool notify=FALSE)
Extend selection from anchor item to index

oFXbool killSelection(FXbool notify=FALSE)
Deselect all items

ovoid sortItems()
Sort items using current sort function

ovoid setFont(FXFont* fnt)
Change text font

oFXFont* getFont() const
Return text font

oFXColor getTextColor() const
Return normal text color

ovoid setTextColor(FXColor clr)
Change normal text color

oFXColor getSelBackColor() const
Return selected text background

ovoid setSelBackColor(FXColor clr)
Change selected text background

oFXColor getSelTextColor() const
Return selected text color

ovoid setSelTextColor(FXColor clr)
Change selected text color

oFXListSortFunc getSortFunc() const
Return sort function

ovoid setSortFunc(FXListSortFunc func)
Change sort function

oFXuint getListStyle() const
Return list style

ovoid setListStyle(FXuint style)
Change list style

ovoid setHelpText(const FXString& text)
Set the status line help text for this list

oFXString getHelpText() const
Get the status line help text for this list

ovirtual void save(FXStream& store) const
Save list to a stream

ovirtual void load(FXStream& store)
Load list from a stream

ovirtual ~FXList()
Destructor


This class has no child classes.

Alphabetic index HTML hierarchy of classes or Java



This page was generated with the help of DOC++.