50 void DoHPosition(
Int_t);
51 void DoVPosition(
Int_t);
52 void DoLeftMargin(
char*);
53 void DoRightMargin(
char*);
54 void DoTopMargin(
char*);
55 void DoBottomMargin(
char*);
83 "&This button has a multi-line label\nand shows features\n"
84 "available in the button classes");
85 fButton->Resize(300, 200);
86 fButton->ChangeOptions(fButton->GetOptions() |
kFixedSize);
87 fButton->SetToolTipText(
"The assigned tooltip\ncan be multi-line also",200);
95 disable->
Connect(
"Toggled(Bool_t)",
"TGButton", fButton,
"SetEnabled(Bool_t)");
107 horizontal->
Connect(
"Pressed(Int_t)",
"ButtonWindow",
this,
108 "DoHPosition(Int_t)");
119 vertical->
Connect(
"Pressed(Int_t)",
"ButtonWindow",
this,
120 "DoVPosition(Int_t)");
128 TextMargin *left =
new TextMargin(margins,
"Left");
130 left->GetEntry()->Connect(
"TextChanged(char*)",
"ButtonWindow",
131 this,
"DoLeftMargin(char*)");
133 TextMargin *right =
new TextMargin(margins,
"Right");
135 right->GetEntry()->Connect(
"TextChanged(char*)",
"ButtonWindow",
136 this,
"DoRightMargin(char*)");
138 TextMargin *top =
new TextMargin(margins,
"Top");
140 top->GetEntry()->Connect(
"TextChanged(char*)",
"ButtonWindow",
141 this,
"DoTopMargin(char*)");
143 TextMargin *bottom =
new TextMargin(margins,
"Bottom");
145 bottom->GetEntry()->Connect(
"TextChanged(char*)",
"ButtonWindow",
146 this,
"DoBottomMargin(char*)");
155 Connect(
"CloseWindow()",
"TApplication",
gApplication,
"Terminate()");
161 SetWMSizeHints(GetDefaultWidth(), GetDefaultHeight(), 1000, 1000, 0 ,0);
162 SetWindowName(
"Button Test");
167void ButtonWindow::DoHPosition(
Int_t id)
171 Int_t tj = fButton->GetTextJustify();
176 fButton->SetTextJustify(tj);
180void ButtonWindow::DoVPosition(
Int_t id)
184 Int_t tj = fButton->GetTextJustify();
190 fButton->SetTextJustify(tj);
194void ButtonWindow::DoLeftMargin(
char *val)
198 fButton->SetLeftMargin(atoi(val));
203void ButtonWindow::DoRightMargin(
char *val)
207 fButton->SetRightMargin(atoi(val));
212void ButtonWindow::DoTopMargin(
char *val)
216 fButton->SetTopMargin(atoi(val));
221void ButtonWindow::DoBottomMargin(
char *val)
225 fButton->SetBottomMargin(atoi(val));
#define ClassDef(name, id)
R__EXTERN TApplication * gApplication
winID h TVirtualViewer3D TVirtualGLPainter p
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 GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize MapSubwindows
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t SetWMSizeHints
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=nullptr)
Add frame to the composite frame using the specified layout hints.
A composite frame with a border and a title.
virtual void SetTitlePos(ETitlePos pos=kLeft)
A composite frame that layout their children in horizontal way.
This class handles GUI labels.
This class describes layout hints used by the layout classes.
Defines top level windows that interact with the system Window Manager.
TGNumberEntry is a number entry input widget with up/down buttons.
TGNumberEntryField * GetNumberEntry() const
Get the number entry field.
Yield an action as soon as it is clicked.
A TGTextEntry is a one line text input widget.
A vertical 3D line is a line that can be used to separate groups of widgets.
A composite frame that layout their children in vertical way.
ROOT GUI Window base class.
Bool_t Connect(const char *signal, const char *receiver_class, void *receiver, const char *slot)
Non-static method is used to connect from the signal of this object to the receiver slot.