147 static int id = 1000;
389 const char *
text =
b->GetText()->GetString();
390 char hotpos =
b->GetText()->GetHotPos();
391 Int_t lentext =
b->GetText()->GetLength();
392 char *outext =
new char[lentext+2];
408 out <<
" // " << quote << outext << quote <<
" shutter item " << std::endl;
409 out <<
" TGShutterItem *";
411 <<
", new TGHotString(" << quote << outext << quote <<
"),"
415 if (option && strstr(option,
"keep_names"))
416 out <<
" " <<
GetName() <<
"->SetName(\"" <<
GetName() <<
"\");" << std::endl;
423 <<
" = (TGCompositeFrame *)" <<
GetName() <<
"->GetContainer();" << std::endl;
432 out <<
");"<< std::endl;
442 out <<
" // shutter" << std::endl;
444 out <<
" TGShutter *";
449 out <<
" " <<
GetName() <<
"->SetDefaultSize(";
452 if (option && strstr(option,
"keep_names"))
453 out <<
" " <<
GetName() <<
"->SetName(\"" <<
GetName() <<
"\");" << std::endl;
464 out <<
");"<< std::endl;
467 out <<
" " <<
GetName() <<
"->SetSelectedItem("
virtual Int_t GetEntries() const
A frame containing two scrollbars (a horizontal and a vertical) and a viewport.
virtual void SetContainer(TGFrame *f)
TGViewPort * GetViewPort() const
void SetScrolling(Int_t scrolling)
Set scrolling policy.
Pixel_t GetShadow(Pixel_t base_color) const
Return pixel value of shadow color based on base_color.
The base class for composite widgets (menu bars, list boxes, etc.).
TGLayoutManager * fLayoutManager
layout manager
virtual TList * GetList() const
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=0)
Add frame to the composite frame using the specified layout hints.
virtual Int_t MustCleanup() const
virtual void MapSubwindows()
Map all sub windows that are part of the composite frame.
virtual void ShowFrame(TGFrame *f)
Show sub frame.
TList * fList
container of frame elements
virtual void RemoveFrame(TGFrame *f)
Remove frame from composite frame.
virtual void HideFrame(TGFrame *f)
Hide sub frame.
A subclasses of TGWindow, and is used as base class for some simple widgets (buttons,...
UInt_t fHeight
frame height
virtual UInt_t GetDefaultHeight() const
Int_t fBorderWidth
frame border width
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save a frame widget as a C++ statement(s) on output stream out.
TGFrameElement * GetFrameElement() const
virtual void SetBackgroundColor(Pixel_t back)
Set background color (override from TGWindow base class).
static Pixel_t GetDefaultFrameBackground()
Get default frame background.
virtual UInt_t GetOptions() const
TString GetOptionString() const
Returns a frame option string - used in SavePrimitive().
virtual void MoveResize(Int_t x, Int_t y, UInt_t w=0, UInt_t h=0)
Move and/or resize the frame.
TGHotString is a string with a "hot" character underlined.
This class describes layout hints used by the layout classes.
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save layout hints as a C++ statement(s) on output stream out.
TGClient * fClient
Connection to display server.
TGLayoutHints * fL2
positioning hints
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save a shutter item widget as a C++ statement(s) on output stream out.
TGFrame * fContainer
container in canvas containing shutter items
virtual ~TGShutterItem()
Clan up shutter item.
TGCanvas * fCanvas
canvas of shutter item
TGButton * GetButton() const
TGButton * fButton
shutter item button
TGShutterItem(const TGShutterItem &)=delete
TGFrame * GetContainer() const
A shutter widget contains a set of shutter items that can be open and closed like a shutter.
virtual void AddItem(TGShutterItem *item)
Add shutter item to shutter frame.
virtual void RemovePage()
Remove selected page.
TGShutterItem * fClosingItem
Item closing down.
TTimer * fTimer
Timer for animation.
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save a shutter widget as a C++ statement(s) on output stream out.
TGShutterItem * GetItem(const char *name)
returns a shutter item by name (name is hot string of shutter item)
virtual void Layout()
Layout shutter items.
virtual Bool_t HandleTimer(TTimer *t)
Shutter item animation.
UInt_t fDefHeight
Default height.
TGShutterItem * fSelectedItem
Item currently open.
virtual void EnableItem(const char *name, Bool_t on=kTRUE)
Disable/enbale shutter item.
virtual void SetSelectedItem(TGShutterItem *item)
Set item to be the currently open shutter item.
TGShutter(const TGShutter &)=delete
TList * fTrash
Items that need to be cleaned up.
Int_t fHeightIncrement
Height delta.
virtual void SetDefaultSize(UInt_t w, UInt_t h)
Set the default / minimal size of the widget.
Int_t fClosingHeight
Closing items current height.
virtual TGDimension GetDefaultSize() const
Return the default / minimal size of the widget.
virtual void Selected(TGShutterItem *item)
TGShutterItem * GetSelectedItem() const
Int_t fClosingHadScrollbar
Closing item had a scroll bar.
virtual TGShutterItem * AddPage(const char *item="Page")
Add new page (shutter item)
virtual ~TGShutter()
Cleanup shutter widget.
virtual void RenamePage(const char *name)
Rename selected page.
virtual Bool_t ProcessMessage(Longptr_t cmd, Longptr_t parm1, Longptr_t parm2)
Handle shutter messages.
UInt_t fDefWidth
Default width.
virtual void RemoveItem(const char *name)
Remove item from shutter.
Yield an action as soon as it is clicked.
virtual void SetText(TGHotString *new_label)
Set new button text.
TString GetString() const
A composite frame that layout their children in vertical way.
ROOT GUI Window base class.
virtual const char * GetName() const
Return unique name, used in SavePrimitive methods.
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
virtual void DestroyWindow()
destroy window
UInt_t fEditDisabled
flags used for "guibuilding"
virtual void Add(TObject *obj)
virtual TObject * After(const TObject *obj) const
Returns the object after object obj.
virtual TObject * FindObject(const char *name) const
Find an object in this list using its name.
virtual TObject * Before(const TObject *obj) const
Returns the object before object obj.
virtual void Delete(Option_t *option="")
Remove all objects from the list AND delete all heap based objects.
virtual TObject * First() const
Return the first object in the list. Returns 0 when list is empty.
R__ALWAYS_INLINE Bool_t IsZombie() const
const char * Data() const
Handles synchronous and a-synchronous timer events.
virtual void TurnOff()
Remove timer from system timer list.
virtual void TurnOn()
Add the timer to the system timer list.
void Reset()
Reset the timer.