143   int max_ascent, max_descent;
 
  147   fTHeight = max_ascent + max_descent;
 
  166   int max_ascent, max_descent;
 
  202   int max_ascent, max_descent;
 
  205   fTHeight = max_ascent + max_descent;
 
  239                 GetDefaultFontStruct(), options, back)
 
  248   memcpy(gcv.
fDashes, 
"\x5\x5", 3);
 
  253   int max_ascent, max_descent;
 
  258                                max_ascent, max_descent);
 
  259   fTHeight = max_ascent + max_descent;
 
  292   static const char* dashed = 
"\x3\x3";
 
  293   static const char* dotted= 
"\x1\x2";
 
  294   static const char* dasheddotted = 
"\x3\x4\x1\x4";
 
  295   static const char* ls05 = 
"\x5\x3\x1\x3";
 
  296   static const char* ls06 = 
"\x5\x3\x1\x3\x1\x3\x1\x3";
 
  297   static const char* ls07 = 
"\x5\x5";
 
  298   static const char* ls08 = 
"\x5\x3\x1\x3\x1\x3";
 
  299   static const char* ls09 = 
"\x20\x5";
 
  300   static const char* ls10 = 
"\x20\x10\x1\x10";
 
  303   if (linestyle <= 1)  {
 
  383                 GetDefaultFontStruct(), options, back)
 
  385   int max_ascent, max_descent;
 
  395                                max_ascent, max_descent);
 
  396   fTHeight = max_ascent + max_descent;
 
  449   if (pic) ((
TGPicture *)pic)->AddReference();
 
  471      const char *
t1 = 
f1->GetText()->Data();
 
  474      if ((d1 = atof(
t1)) && (d2 = atof(t2))) {
 
  477         return strcmp(
t1, t2);
 
  556      if (
e->EntryId() == afterID) 
break;
 
  559   if (!el && afterID != -1) {
 
  592      if (
e->EntryId() > lbe->
EntryId()) 
break;
 
  625      if (
e->EntryId() == 
id) {
 
  653      if ((
e->EntryId() >= from_ID) && (
e->EntryId() <= to_ID)) {
 
  716      if (
f->EntryId() == 
id) {
 
  751      if (
f->EntryId() == 
id)
 
  752         return f->IsActive();
 
  821   int xf0, yf0, xff, yff;
 
  842      if (newpos < 0) newpos = 0;
 
  864            xff = xf0 + 
f->GetWidth();
 
  865            yff = yf0 + 
f->GetHeight();
 
  868                        (
x > xf0) && (
x < xff) && (
y > yf0) &&  (
y < yff);
 
  894            xff = xf0 + 
f->GetWidth();
 
  895            yff = yf0 + 
f->GetHeight();
 
  898                        (
x > xf0) && (
x < xff) && (
y > yf0) &&  (
y < yff) && !
f->IsActive();
 
  952   int xf0, yf0, xff, yff;
 
  957   if ((now-was) < 50) 
return kFALSE;
 
  984            xff = xf0 + 
f->GetWidth();
 
  985            yff = yf0 + 
f->GetHeight();
 
  987                        (
x > xf0) && (
x < xff) && (
y > yf0) &&  (
y < yff);
 
 1006         xff = xf0 + 
f->GetWidth();
 
 1007         yff = yf0 + 
f->GetHeight();
 
 1010                        (
x > xf0) && (
x < xff) && (
y > yf0) &&  (
y < yff)  && !
f->IsActive();
 
 1048   if (vb && 
y > 0 && 
y < 10) {
 
 1051      if (newpos < 0) newpos = 0;
 
 1067         yff = yf0 + 
f->GetHeight();
 
 1068         if ((
y + pos.
fY > yf0) && (
y + pos.
fY < yff)) {
 
 1104      if (
f->EntryId() == 
id)
 
 1186         if (
gClient->GetStyle() > 1) 
break;
 
 1380      if (lbe->
EntryId() == 
id) 
return lbe;
 
 1474      if ((
Int_t) cw < 0) {
 
 1475         Warning(
"Layout", 
"width would become too small, setting to 10");
 
 1486   container->
Resize(cw, tch);
 
 1617   Emit(
"Selected(Int_t,Int_t)", args);
 
 1630   Emit(
"DoubleClicked(Int_t,Int_t)", args);
 
 1655   out << std::endl << 
"   // list box" << std::endl;
 
 1657   out<<
"   TGListBox *";
 
 1663            out <<
");" << std::endl;
 
 1665            out << 
"," << 
fWidgetId << 
");" << std::endl;
 
 1674      out << 
"   " << 
GetName() << 
"->SetName(\"" << 
GetName() << 
"\");" << std::endl;
 
 1682      out << 
"   " << 
GetName() << 
"->AddEntry(";
 
 1684      out << 
");"<< std::endl;
 
 1687       << 
");" << std::endl;
 
 1699   out << quote << content << quote << 
"," << 
EntryId();
 
const Mask_t kGCLineStyle
 
const Mask_t kGCLineWidth
 
const Mask_t kButtonMotionMask
 
const Mask_t kButtonPressMask
 
const Mask_t kGCFillStyle
 
Handle_t Window_t
Window handle.
 
Handle_t GContext_t
Graphics context handle.
 
const Mask_t kPointerMotionMask
 
const Mask_t kButtonReleaseMask
 
ULong_t Pixel_t
Pixel value.
 
ULongptr_t Handle_t
Generic resource handle.
 
Handle_t FontStruct_t
Pointer to font structure.
 
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
 
winID h TVirtualViewer3D TVirtualGLPainter p
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t sel
 
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize id
 
Option_t Option_t TPoint TPoint const char text
 
R__EXTERN TSystem * gSystem
 
Bool_t IsEditable() const
 
TGGC * GetGC(GCValues_t *values, Bool_t rw=kFALSE)
Get graphics context from the gc pool.
 
void FreeGC(const TGGC *gc)
Free a graphics context.
 
const TGResourcePool * GetResourcePool() const
 
void FreePicture(const TGPicture *pic)
Free picture resource.
 
The base class for composite widgets (menu bars, list boxes, etc.).
 
TGLayoutManager * fLayoutManager
layout manager
 
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=nullptr)
Add frame to the composite frame using the specified layout hints.
 
virtual TList * GetList() const
 
Int_t MustCleanup() const override
 
virtual void Cleanup()
Cleanup and delete all objects contained in this composite frame.
 
Bool_t fMapSubwindows
kTRUE - map subwindows
 
TList * fList
container of frame elements
 
static TGLayoutHints * fgDefaultHints
 
void SetEditDisabled(UInt_t on=1) override
Set edit disable flag for this frame and subframes.
 
virtual void ActivateItem(TGFrameElement *el)
Activate item.
 
TTimer * fScrollTimer
autoscroll timer
 
Bool_t HandleDoubleClick(Event_t *event) override
Handle double click mouse event.
 
virtual void ClearViewPort()
Clear view port and redraw full content.
 
const TGWindow * fMsgWindow
window handling container messages
 
void Layout() override
Layout container entries.
 
void DoRedraw() override
Redraw content of container in the viewport region.
 
Bool_t fScrolling
kTRUE - when scrolling is ON
 
virtual TGDimension GetPageDimension() const
Returns page dimension.
 
TGViewPort * fViewPort
container viewport
 
virtual void DoubleClicked(TGFrame *f, Int_t btn)
Emit DoubleClicked() signal.
 
virtual TGPosition GetPagePosition() const
Returns page position.
 
TGFrameElement * fLastActiveEl
last active item
 
Encapsulate fonts used in the GUI system.
 
FontStruct_t GetFontStruct() const
 
A subclasses of TGWindow, and is used as base class for some simple widgets (buttons,...
 
void AddInput(UInt_t emask)
Add events specified in the emask to the events the frame should handle.
 
void MoveResize(Int_t x, Int_t y, UInt_t w=0, UInt_t h=0) override
Move and/or resize the frame.
 
static const TGGC & GetBlackGC()
Get black graphics context.
 
UInt_t fOptions
frame options
 
void Resize(UInt_t w=0, UInt_t h=0) override
Resize the frame.
 
void RemoveInput(UInt_t emask)
Remove events specified in emask from the events the frame should handle.
 
static Pixel_t GetWhitePixel()
Get white pixel value.
 
UInt_t fHeight
frame height
 
virtual UInt_t GetDefaultWidth() const
 
virtual UInt_t GetDefaultHeight() const
 
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a frame widget as a C++ statement(s) on output stream out.
 
virtual void DrawBorder()
Draw frame border.
 
Int_t fBorderWidth
frame border width
 
static Pixel_t fgDefaultSelectedBackground
 
virtual void Activate(Bool_t)
 
void DoRedraw() override
Redraw the frame.
 
void MapWindow() override
map window
 
virtual Pixel_t GetForeground() const
Return frame foreground color.
 
static const TGGC & GetHilightGC()
Get highlight color graphics context.
 
virtual UInt_t GetOptions() const
 
TString GetOptionString() const
Returns a frame option string - used in SavePrimitive().
 
void UnmapWindow() override
unmap window
 
virtual void SendMessage(const TGWindow *w, Longptr_t msg, Longptr_t parm1, Longptr_t parm2)
Send message (i.e.
 
static const TGGC & GetShadowGC()
Get shadow color graphics context.
 
virtual void SetWidth(UInt_t w)
 
static Pixel_t fgWhitePixel
 
void SaveUserColor(std::ostream &out, Option_t *)
Save a user color in a C++ macro file - used in SavePrimitive().
 
virtual void SetHeight(UInt_t h)
 
Pixel_t fBackground
frame background color
 
static const TGGC & GetBckgndGC()
Get background color graphics context.
 
Encapsulate a graphics context used in the low level graphics.
 
void SetLineWidth(Int_t v)
Set line width.
 
void SetCapStyle(Int_t v)
Set cap style (kCapNotLast, kCapButt, kCapRound, kCapProjecting).
 
void SetDashList(const char v[], Int_t len)
Set dash pattern. First use SetDashOffset() if not 0.
 
void SetLineStyle(Int_t v)
Set line style (kLineSolid, kLineOnOffDash, kLineDoubleDash).
 
void DoRedraw() override
Redraw icon & text listbox entry.
 
virtual void SetPicture(const TGPicture *pic=nullptr)
Change the icon of listbox entry containing icon & text.
 
virtual ~TGIconLBEntry()
Delete icon & text listbox entry.
 
void DrawCopy(Handle_t id, Int_t x, Int_t y) override
Draw copy on window/pixmap.
 
TGIconLBEntry(const TGIconLBEntry &)=delete
 
const TGPicture * fPicture
 
void Update(TGLBEntry *e) override
Update icon & text listbox entry.
 
A Composite frame that contains a list of TGLBEnties.
 
TGLBContainer(const TGLBContainer &)=delete
 
Bool_t fMultiSelect
true if multi selection is switched on
 
virtual Bool_t GetSelection(Int_t id)
Returns kTrue if entry id is selected.
 
void OnAutoScroll() override
Autoscroll while close to & beyond The Wall.
 
virtual void SetListBox(TGListBox *lb)
 
void RemoveAll() override
Remove all entries in this container.
 
void SetVsbPosition(Int_t newPos) override
Set new vertical scroll bar position.
 
TGVScrollBar * GetVScrollbar() const override
Return a pointer to vertical scroll bar.
 
Int_t fChangeStatus
defines the changes (select or unselect) while the mouse moves over a multi selectable list box
 
virtual Int_t GetSelected() const
Returns id of selected entry.
 
Bool_t HandleButton(Event_t *event) override
Handle mouse button event in the listbox container.
 
virtual Bool_t GetMultipleSelections() const
 
void Layout() override
Layout container.
 
virtual ~TGLBContainer()
Delete the listbox container.
 
void ActivateItem(TGFrameElement *el) override
Activate item.
 
virtual TGLBEntry * Select(Int_t id, Bool_t sel)
Select / deselect the entry with the specified id.
 
TGLBEntry * fLastActive
last active listbox entry in single selection listbox
 
Bool_t HandleDoubleClick(Event_t *event) override
Handle double click mouse event in the listbox container.
 
virtual void RemoveEntries(Int_t from_ID, Int_t to_ID)
Remove entries from from_ID to to_ID (including).
 
TGListBox * fListBox
list box which contains this container
 
virtual void AddEntry(TGLBEntry *lbe, TGLayoutHints *lhints)
Add listbox entry with hints to container.
 
virtual Int_t GetPos(Int_t id)
Returns the position in the list box of the entry id.
 
virtual void AddEntrySort(TGLBEntry *lbe, TGLayoutHints *lhints)
Insert listbox entry before the list box entry with a higher id.
 
virtual void InsertEntry(TGLBEntry *lbe, TGLayoutHints *lhints, Int_t afterID)
Insert listbox entry after specified entry with id afterID.
 
virtual void RemoveEntry(Int_t id)
Remove the entry with specified id from the listbox container.
 
virtual void GetSelectedEntries(TList *selected)
Adds all selected entries (TGLBEntry) of the list box into the list selected.
 
void DoRedraw() override
redraw
 
void Associate(const TGWindow *w) override
 
Bool_t HandleMotion(Event_t *event) override
Handle mouse motion event in listbox container.
 
virtual void SetMultipleSelections(Bool_t multi)
Enables and disables multiple selections of entries.
 
Pixel_t fBkcolor
entry background color
 
Int_t fEntryId
message id of listbox entry
 
void DoRedraw() override
Redraw the frame.
 
virtual void Toggle()
Toggle active state of listbox entry.
 
Bool_t fActive
true if entry is active
 
void SetBackgroundColor(Pixel_t col) override
Set background color (override from TGWindow base class).
 
TGLBEntry(const TGWindow *p=nullptr, Int_t id=-1, UInt_t options=kHorizontalFrame, Pixel_t back=GetWhitePixel())
Base class entry constructor.
 
void Activate(Bool_t a) override
Toggle active state of listbox entry.
 
TGLBFrameElement(TGFrame *f, TGLayoutHints *l)
 
virtual ~TGLBFrameElement()
 
Int_t Compare(const TObject *obj) const override
Compare abstract method.
 
Bool_t IsSortable() const override
 
This class describes layout hints used by the layout classes.
 
Line style and width listbox entries.
 
Style_t fLineStyle
line style
 
TGGC * fLineGC
line graphics context
 
UInt_t fLineLength
line length
 
UInt_t fLineWidth
line width
 
void DrawCopy(Handle_t id, Int_t x, Int_t y) override
Draw copy on window/pixmap.
 
void DoRedraw() override
Redraw line style listbox entry.
 
void Update(TGLBEntry *e) override
Update line style listbox entry.
 
virtual ~TGLineLBEntry()
Delete line style listbox entry.
 
virtual void SetLineWidth(Int_t width)
Set or change line width in an entry.
 
virtual void SetLineStyle(Style_t style)
Set the line style corresponding to the TPad line styles.
 
TGLineLBEntry(const TGLineLBEntry &)=delete
 
A listbox is a box, possibly with scrollbar, containing entries.
 
virtual void InitListBox()
Initiate the internal classes of a list box.
 
Bool_t fIntegralHeight
true if height should be multiple of fItemVsize
 
virtual void AddEntrySort(TGString *s, Int_t id)
Add entry with specified string and id to listbox sorted by increasing id.
 
TGListBox(const TGListBox &)=delete
 
virtual ~TGListBox()
Delete a listbox widget.
 
virtual void SortByName(Bool_t ascend=kTRUE)
Sort entries by name.
 
virtual TGVScrollBar * GetVScrollbar() const
 
TGViewPort * fVport
listbox viewport (see TGCanvas.h)
 
UInt_t fItemVsize
maximum height of single entry
 
TGDimension GetDefaultSize() const override
Return default size of listbox widget.
 
virtual Int_t GetNumberOfEntries() const
 
TGLBContainer * fLbc
listbox container
 
virtual TGLBEntry * GetSelectedEntry() const
 
virtual void RemoveEntry(Int_t id=-1)
remove entry with id.
 
virtual void NewEntry(const char *s="Entry")
method used to add entry via context menu
 
void Resize(UInt_t w, UInt_t h) override
Resize the listbox widget.
 
virtual Int_t GetSelected() const
Return id of selected listbox item.
 
void MoveResize(Int_t x, Int_t y, UInt_t w, UInt_t h) override
Move and resize the listbox widget.
 
virtual void SetTopEntry(Int_t id=-1)
Scroll the entry with id to the top of the listbox.
 
void ChangeBackground(Pixel_t back) override
Change background to all entries.
 
virtual void AddEntry(TGString *s, Int_t id)
Add entry with specified string and id to listbox.
 
void Layout() override
Layout the listbox components.
 
virtual void DoubleClicked(Int_t widgetId, Int_t id)
Emit DoubleClicked signal with list box id and entry id.
 
virtual void InsertEntry(TGString *s, Int_t id, Int_t afterID)
Insert entry with specified string and id behind the entry with afterID.
 
virtual void SelectionChanged()
 
virtual Bool_t GetMultipleSelections() const
 
void SetContainer(TGFrame *f)
 
TGVScrollBar * fVScrollbar
vertical scrollbar
 
void DrawBorder() override
Draw borders of the list box widget.
 
virtual TGLBEntry * GetEntry(Int_t id) const
Returns list box entry with specified id.
 
virtual TGViewPort * GetViewPort() const
 
virtual TGFrame * GetContainer() const
 
void SavePrimitive(std::ostream &out, Option_t *option="") override
Save a list box widget as a C++ statement(s) on output stream out.
 
virtual void GetSelectedEntries(TList *selected)
Adds all selected entries (TGLBEntry) of the list box into the list selected.
 
virtual void RemoveEntries(Int_t from_ID, Int_t to_ID)
Remove a range of entries defined by from_ID and to_ID.
 
Bool_t ProcessMessage(Longptr_t msg, Longptr_t parm1, Longptr_t parm2) override
Process messages generated by the listbox container and forward messages to the listbox message handl...
 
virtual TGLBEntry * FindEntry(const char *s) const
Find entry by name.
 
void RemoveAll() override
Remove all entries.
 
virtual void Selected(Int_t widgetId, Int_t id)
Emit Selected signal with list box id and entry id.
 
TGClient * fClient
Connection to display server.
 
Handle_t fId
X11/Win32 Window identifier.
 
The TGPicture class implements pictures and icons used in the different GUI elements and widgets.
 
void Draw(Option_t *="") override
Default Draw method for all objects.
 
Pixel_t GetBlackColor() const
 
Pixel_t GetSelectedFgndColor() const
 
TGString wraps a TString and adds some graphics routines like drawing, size of string on screen depen...
 
const char * GetString() const
 
virtual void Draw(Drawable_t id, GContext_t gc, Int_t x, Int_t y)
Draw string.
 
Text string listbox entries.
 
Bool_t fTextChanged
true if text has been changed
 
const TGString * GetText() const
 
GContext_t fNormGC
text drawing graphics context
 
static const TGFont * fgDefaultFont
 
void DoRedraw() override
Redraw text listbox entry.
 
void SavePrimitive(std::ostream &out, Option_t *="") override
Save a list box entry widget as a C++ statement(s) on output stream out.
 
void DrawCopy(Handle_t id, Int_t x, Int_t y) override
Draw text listbox entry on window/pixmap.
 
const char * GetTitle() const override
Returns title of object.
 
UInt_t fTHeight
text height
 
TGString * fText
entry text string
 
void Update(TGLBEntry *e) override
 
FontStruct_t fFontStruct
font used to draw string
 
static FontStruct_t GetDefaultFontStruct()
Return default font structure in use for a text listbox entry.
 
virtual ~TGTextLBEntry()
Delete text listbox entry.
 
static const TGGC & GetDefaultGC()
Return default graphics context in use for a text listbox entry.
 
TGTextLBEntry(const TGTextLBEntry &)=delete
 
static TGGC * fgDefaultGC
 
void SetText(TGString *new_text)
Set or change text in text entry.
 
TGFrame * GetContainer() const
 
virtual void SetVPos(Int_t ypos)
Moves content of container frame in vertical direction.
 
ROOT GUI Window base class.
 
virtual void SetEditDisabled(UInt_t on=kEditDisable)
 
const TGWindow * fParent
Parent window.
 
@ kEditDisableLayout
window layout cannot be edited
 
@ kEditDisableBtnEnable
window can handle mouse button events
 
@ kEditDisableGrab
window grab cannot be edited
 
@ kEditDisable
disable edit of this window
 
@ kEditDisableKeyEnable
window can handle keyboard events
 
virtual void DestroyWindow()
destroy window
 
virtual void SetWindowName(const char *name=nullptr)
Set window name.
 
const TGWindow * GetParent() const
 
virtual Bool_t IsMapped()
Returns kTRUE if window is mapped on screen, kFALSE otherwise.
 
const char * GetName() const override
Return unique name, used in SavePrimitive methods.
 
UInt_t fEditDisabled
flags used for "guibuilding"
 
void AddAfter(const TObject *after, TObject *obj) override
Insert object after object after in the list.
 
TObject * After(const TObject *obj) const override
Returns the object after object obj.
 
void Add(TObject *obj) override
 
TObject * Remove(TObject *obj) override
Remove object from the list.
 
TObject * First() const override
Return the first object in the list. Returns 0 when list is empty.
 
void AddBefore(const TObject *before, TObject *obj) override
Insert object before object before in the list.
 
void AddFirst(TObject *obj) override
Add object at the beginning of the list.
 
virtual void Sort(Bool_t order=kSortAscending)
Sort linked list.
 
Mother of all ROOT objects.
 
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
 
virtual const char * GetTitle() const
Returns title of object.
 
void Emit(const char *signal, const T &arg)
Activate signal with single parameter.
 
const char * Data() const
 
TString & ReplaceAll(const TString &s1, const TString &s2)
 
virtual TTime Now()
Get current time in milliseconds since 0:00 Jan 1 1995.
 
virtual void AddTimer(TTimer *t)
Add timer to list of system timers.
 
virtual TTimer * RemoveTimer(TTimer *t)
Remove timer from list of system timers.
 
void Reset()
Reset the timer.
 
Short_t Max(Short_t a, Short_t b)
Returns the largest of a and b.
 
Double_t Ceil(Double_t x)
Rounds x upward, returning the smallest integral value that is not less than x.
 
EGEventType fType
of event (see EGEventType)
 
UInt_t fState
key or button mask
 
Int_t fYRoot
coordinates relative to root
 
UInt_t fCode
key or button code
 
Graphics context structure.
 
Int_t fDashOffset
patterned/dashed line information
 
Int_t fLineWidth
line width
 
Mask_t fMask
bit mask specifying which fields are valid
 
Int_t fLineStyle
kLineSolid, kLineOnOffDash, kLineDoubleDash
 
Char_t fDashes[8]
dash pattern list (dash length per byte)
 
Int_t fFillStyle
kFillSolid, kFillTiled, kFillStippled, kFillOpaeueStippled
 
Int_t fDashLen
number of dashes in fDashes