library: libGui #include "TGListBox.h" |
TGListBox
class description - header file - source file - inheritance tree (.pdf)
protected:
virtual void InitListBox()
void SetContainer(TGFrame* f)
public:
TGListBox(const TGWindow* p = 0, Int_t id = -1, UInt_t options = kSunkenFrame|kDoubleBorder, Pixel_t back = GetWhitePixel())
TGListBox(const TGListBox&)
virtual ~TGListBox()
virtual void AddEntry(TGString* s, Int_t id)
virtual void AddEntry(const char* s, Int_t id)
virtual void AddEntry(TGLBEntry* lbe, TGLayoutHints* lhints)
virtual void AddEntrySort(TGString* s, Int_t id)
virtual void AddEntrySort(const char* s, Int_t id)
virtual void AddEntrySort(TGLBEntry* lbe, TGLayoutHints* lhints)
virtual void ChangeBackground(Pixel_t back)
static TClass* Class()
virtual void DrawBorder()
virtual TGLBEntry* FindEntry(const char* s) const
virtual TGFrame* GetContainer() const
virtual TGDimension GetDefaultSize() const
virtual TGLBEntry* GetEntry(Int_t id) const
virtual Bool_t GetMultipleSelections() const
virtual Int_t GetNumberOfEntries() const
virtual TGScrollBar* GetScrollBar() const
virtual Int_t GetSelected() const
virtual void GetSelectedEntries(TList* selected)
virtual TGLBEntry* GetSelectedEntry() const
virtual Bool_t GetSelection(Int_t id)
virtual TGViewPort* GetViewPort() const
virtual TGVScrollBar* GetVScrollbar() const
virtual void InsertEntry(TGString* s, Int_t id, Int_t afterID)
virtual void InsertEntry(const char* s, Int_t id, Int_t afterID)
virtual void InsertEntry(TGLBEntry* lbe, TGLayoutHints* lhints, Int_t afterID)
virtual void IntegralHeight(Bool_t mode)
virtual TClass* IsA() const
virtual void Layout()
virtual void MoveResize(Int_t x, Int_t y, UInt_t w, UInt_t h)
virtual void NewEntry(const char* s = "Entry")
virtual Bool_t ProcessMessage(Long_t msg, Long_t parm1, Long_t parm2)
virtual void RemoveAll()
virtual void RemoveEntries(Int_t from_ID, Int_t to_ID)
virtual void RemoveEntry(Int_t id = -1)
virtual void Resize(UInt_t w, UInt_t h)
virtual void Resize(TGDimension size)
virtual void SavePrimitive(ostream& out, Option_t* option = "")
virtual TGLBEntry* Select(Int_t id, Bool_t sel = kTRUE)
virtual void Selected(Int_t widgetId, Int_t id)
virtual void Selected(Int_t id)
virtual void Selected(const char* txt)
virtual void SelectionChanged()
virtual void SetLayoutManager(TGLayoutManager*)
virtual void SetMultipleSelections(Bool_t multi = kTRUE)
virtual void SetTopEntry(Int_t id = -1)
virtual void ShowMembers(TMemberInspector& insp, char* parent)
virtual void SortByName(Bool_t ascend = kTRUE)
virtual void Streamer(TBuffer& b)
void StreamerNVirtual(TBuffer& b)
protected:
UInt_t fItemVsize maximum height of single entry
Bool_t fIntegralHeight true if height should be multiple of fItemVsize
TGLBContainer* fLbc listbox container
TGViewPort* fVport listbox viewport (see TGCanvas.h)
TGVScrollBar* fVScrollbar vertical scrollbar
TGListBox, TGLBContainer, TGLBEntry and TGTextLBEntry
A listbox is a box, possibly with scrollbar, containing entries.
Currently entries are simple text strings (TGTextLBEntry).
A TGListBox looks a lot like a TGCanvas. It has a TGViewPort
containing a TGLBContainer which contains the entries and it also
has a vertical scrollbar which becomes visible if there are more
items than fit in the visible part of the container.
The TGListBox is user callable. The other classes are service
classes of the listbox.
Selecting an item in the listbox will generate the event:
kC_COMMAND, kCM_LISTBOX, listbox id, item id.
void InitListBox()
Initiate the internal classes of a list box.
void AddEntry(TGString *s, Int_t id)
Add entry with specified string and id to listbox. The id will be
used in the event processing routine when the item is selected.
The string will be adopted by the listbox.
void AddEntry(const char *s, Int_t id)
Add entry with specified string and id to listbox. The id will be
used in the event processing routine when the item is selected.
void AddEntrySort(TGString *s, Int_t id)
Add entry with specified string and id to listbox sorted by increasing id.
This sorting works proberly only if EntrySort functions are used to add
entries without mixing them with other add or insert functions. The id will be
used in the event processing routine when the item is selected.
The string will be adopted by the listbox.
void AddEntrySort(const char *s, Int_t id)
Add entry with specified string and id to listbox sorted by increasing id.
This sorting works proberly only if EntrySort functions are used to add
entries without mixing them with other add or insert functions. The id will be
used in the event processing routine when the item is selected.
void AddEntrySort(TGLBEntry *lbe, TGLayoutHints *lhints)
Add specified TGLBEntry and TGLayoutHints to listbox sorted by increasing id.
This sorting works proberly only if EntrySort functions are used to add
entries without mixing them with other add or insert functions. The
entry and layout will be adopted and later deleted by the listbox.
void InsertEntry(TGString *s, Int_t id, Int_t afterID)
Insert entry with specified string and id behind the entry with afterID.
The string will be adopted and later deleted by the listbox.
void InsertEntry(const char *s, Int_t id, Int_t afterID)
Insert entry with specified string and id behind the entry with afterID.
void NewEntry(const char *s)
method used to add entry via context menu
Author: Fons Rademakers 12/01/98
Last update: root/gui:$Name: $:$Id: TGListBox.cxx,v 1.57 2006/07/03 16:10:45 brun Exp $
Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
ROOT page - Class index - Class Hierarchy - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.