61enum ETestCommandIdentifiers {
111const char *filetypes[] = {
"All files",
"*",
"ROOT files",
"*.root",
"ROOT macros",
112 "*.C",
"Text files",
"*.[tT][xX][tT]",
nullptr,
nullptr};
114struct shutterData_t {
115 const char *pixmap_name;
116 const char *tip_text;
121shutterData_t histo_data[] = {{
"h1_s.xpm",
"TH1", 1001,
nullptr},
122 {
"h2_s.xpm",
"TH2", 1002,
nullptr},
123 {
"h3_s.xpm",
"TH3", 1003,
nullptr},
124 {
"profile_s.xpm",
"TProfile", 1004,
nullptr},
125 {
nullptr,
nullptr, 0,
nullptr}};
127shutterData_t function_data[] = {
128 {
"f1_s.xpm",
"TF1", 2001,
nullptr}, {
"f2_s.xpm",
"TF2", 2002,
nullptr}, {
nullptr,
nullptr, 0,
nullptr}};
130shutterData_t tree_data[] = {{
"ntuple_s.xpm",
"TNtuple", 3001,
nullptr},
131 {
"tree_s.xpm",
"TTree", 3002,
nullptr},
132 {
"chain_s.xpm",
"TChain", 3003,
nullptr},
133 {
nullptr,
nullptr, 0,
nullptr}};
135const char *editortxt1 =
"This is the ROOT text edit widget TGTextEdit. It is not intended as\n"
136 "a full developers editor, but it is relatively complete and can ideally\n"
137 "be used to edit scripts or to present users editable config files, etc.\n\n"
138 "The text edit widget supports standard emacs style ctrl-key navigation\n"
139 "in addition to the arrow keys. By default the widget has under the right\n"
140 "mouse button a popup menu giving access to several built-in functions.\n\n"
141 "Cut, copy and paste between different editor windows and any other\n"
142 "standard text handling application is supported.\n\n"
143 "Text can be selected with the mouse while holding the left button\n"
144 "or with the arrow keys while holding the shift key pressed. Use the\n"
145 "middle mouse button to paste text at the current mouse location.";
146const char *editortxt2 =
"Mice with scroll-ball are properly supported.\n\n"
147 "This are the currently defined key bindings:\n"
149 " Move the cursor one character leftwards.\n"
150 " Scroll when cursor is out of frame.\n"
152 " Move the cursor one character rightwards.\n"
153 " Scroll when cursor is out of frame.\n"
155 " Deletes the character on the left side of the text cursor and moves the\n"
156 " cursor one position to the left. If a text has been marked by the user";
157const char *editortxt3 =
" (e.g. by clicking and dragging) the cursor will be put at the beginning\n"
158 " of the marked text and the marked text will be removed.\n"
160 " Moves the text cursor to the left end of the line. If mark is TRUE text\n"
161 " will be marked towards the first position, if not any marked text will\n"
162 " be unmarked if the cursor is moved.\n"
164 " Moves the text cursor to the right end of the line. If mark is TRUE text\n"
165 " will be marked towards the last position, if not any marked text will\n"
166 " be unmarked if the cursor is moved.\n"
168const char *editortxt4 =
" Deletes the character on the right side of the text cursor. If a text\n"
169 " has been marked by the user (e.g. by clicking and dragging) the cursor\n"
170 " will be put at the beginning of the marked text and the marked text will\n"
172 "Shift - Left Arrow\n"
173 " Mark text one character leftwards.\n"
174 "Shift - Right Arrow\n"
175 " Mark text one character rightwards.\n"
177 " Select the whole text.\n"
179 " Move the cursor one character leftwards.";
180const char *editortxt5 =
"Control-C\n"
181 " Copy the marked text to the clipboard.\n"
183 " Delete the character to the right of the cursor.\n"
185 " Move the cursor to the end of the line.\n"
187 " Start Search Dialog.\n"
189 " Delete the character to the left of the cursor.\n"
191 " Delete marked text if any or delete all\n"
192 " characters to the right of the cursor.\n"
194 " Start GoTo Line Dialog";
195const char *editortxt6 =
"Control-U\n"
196 " Delete all characters on the line.\n"
198 " Paste the clipboard text into line edit.\n"
200 " Cut the marked text, copy to clipboard.\n"
202 " Paste the clipboard text into line edit.\n"
205 "All other keys with valid ASCII codes insert themselves into the line.";
218 TileFrame *fContainer;
224 TGPopupMenu *fMenuFile, *fMenuTest, *fMenuView, *fMenuHelp;
225 TGPopupMenu *fCascadeMenu, *fCascade1Menu, *fCascade2Menu;
227 TGLayoutHints *fMenuBarLayout, *fMenuBarItemLayout, *fMenuBarHelpLayout;
231 virtual ~TestMainFrame();
236 void HandleMenu(
Int_t id);
237 void HandlePopup() { printf(
"menu popped up\n"); }
238 void HandlePopdown() { printf(
"menu popped down\n"); }
240 void Created() { Emit(
"Created()"); }
241 void Welcome() { printf(
"TestMainFrame has been created. Welcome!\n"); }
252 TGButton *fOkButton, *fCancelButton, *fStartB, *fStopB;
253 TGButton *fBtn1, *fBtn2, *fChk1, *fChk2, *fRad1, *fRad2;
273 virtual ~TestDialog();
280 void DoTab(
Int_t id);
281 void HandleButtons(
Int_t id = -1);
292 TGButton *fTestButton, *fCloseButton;
305 virtual ~TestMsgBox();
331 virtual ~TestSliders();
335 void DoText(const
char *
text);
336 void DoSlider(
Int_t pos = 0);
353 void AddShutterItem(const
char *
name, shutterData_t *
data);
357 void HandleButtons();
372 virtual ~TestDirList();
388 void DisplayFile(const
TString &fname);
389 void DisplayDirectory(const
TString &fname);
394 virtual ~TestFileList();
416 virtual ~TestProgress();
449 virtual ~EntryTestDlg();
470 void LoadFile(
const char *file);
471 void LoadBuffer(
const char *buffer);
472 void AddBuffer(
const char *buffer);
474 TGTextEdit *GetEditor()
const {
return fEdit; }
497 virtual ~TileFrame() {
delete fFrame; }
499 TGFrame *GetFrame()
const {
return fFrame; }
501 void SetCanvas(
TGCanvas *canvas) { fCanvas = canvas; }
502 void HandleMouseWheel(
Event_t *event);
510 fFrame->Connect(
"ProcessedEvent(Event_t*)",
"TileFrame",
this,
"HandleMouseWheel(Event_t*)");
518void TileFrame::HandleMouseWheel(
Event_t *event)
529 if (fCanvas->GetContainer()->GetHeight())
530 page =
Int_t(
Float_t(fCanvas->GetViewPort()->GetHeight() * fCanvas->GetViewPort()->GetHeight()) /
531 fCanvas->GetContainer()->GetHeight());
536 Int_t newpos = fCanvas->GetVsbPosition() - page;
539 fCanvas->SetVsbPosition(newpos);
543 Int_t newpos = fCanvas->GetVsbPosition() + page;
544 fCanvas->SetVsbPosition(newpos);
557 fMain->Connect(
"CloseWindow()",
"TestMainFrame",
this,
"CloseWindow()");
563 fMenuDock->SetWindowName(
"GuiTest Menu");
570 fMenuFile->AddEntry(
"&Open...", M_FILE_OPEN);
571 fMenuFile->AddEntry(
"&Save", M_FILE_SAVE);
572 fMenuFile->AddEntry(
"S&ave as...", M_FILE_SAVEAS);
573 fMenuFile->AddEntry(
"&Close", -1);
574 fMenuFile->AddSeparator();
575 fMenuFile->AddEntry(
"&Print", M_FILE_PRINT);
576 fMenuFile->AddEntry(
"P&rint setup...", M_FILE_PRINTSETUP);
577 fMenuFile->AddSeparator();
578 fMenuFile->AddEntry(
"E&xit", M_FILE_EXIT);
580 fMenuFile->DisableEntry(M_FILE_SAVEAS);
581 fMenuFile->HideEntry(M_FILE_PRINT);
584 fCascade2Menu->AddEntry(
"ID = 2&3", M_CASCADE_1);
585 fCascade2Menu->AddEntry(
"ID = 2&4", M_CASCADE_2);
586 fCascade2Menu->AddEntry(
"ID = 2&5", M_CASCADE_3);
589 fCascade1Menu->AddEntry(
"ID = 4&1", 41);
590 fCascade1Menu->AddEntry(
"ID = 4&2", 42);
591 fCascade1Menu->AddEntry(
"ID = 4&3", 43);
592 fCascade1Menu->AddSeparator();
593 fCascade1Menu->AddPopup(
"Cascade&d 2", fCascade2Menu);
596 fCascadeMenu->AddEntry(
"ID = 5&1", 51);
597 fCascadeMenu->AddEntry(
"ID = 5&2", 52);
598 fCascadeMenu->AddEntry(
"ID = 5&3", 53);
599 fCascadeMenu->AddSeparator();
600 fCascadeMenu->AddPopup(
"&Cascaded 1", fCascade1Menu);
603 fMenuTest->AddLabel(
"Test different features...");
604 fMenuTest->AddSeparator();
605 fMenuTest->AddEntry(
"&Dialog...", M_TEST_DLG);
606 fMenuTest->AddEntry(
"&Message Box...", M_TEST_MSGBOX);
607 fMenuTest->AddEntry(
"&Sliders...", M_TEST_SLIDER);
608 fMenuTest->AddEntry(
"Sh&utter...", M_TEST_SHUTTER);
609 fMenuTest->AddEntry(
"&List Directory...", M_TEST_DIRLIST);
610 fMenuTest->AddEntry(
"&File List...", M_TEST_FILELIST);
611 fMenuTest->AddEntry(
"&Progress...", M_TEST_PROGRESS);
612 fMenuTest->AddEntry(
"&Number Entry...", M_TEST_NUMBERENTRY);
613 fMenuTest->AddEntry(
"F&ont Dialog...", M_TEST_FONTDIALOG);
614 fMenuTest->AddSeparator();
615 fMenuTest->AddEntry(
"Add New Menus", M_TEST_NEWMENU);
616 fMenuTest->AddSeparator();
617 fMenuTest->AddPopup(
"&Cascaded menus", fCascadeMenu);
620 fMenuView->AddEntry(
"&Dock", M_VIEW_DOCK);
621 fMenuView->AddEntry(
"&Undock", M_VIEW_UNDOCK);
622 fMenuView->AddSeparator();
623 fMenuView->AddEntry(
"Enable U&ndock", M_VIEW_ENBL_DOCK);
624 fMenuView->AddEntry(
"Enable &Hide", M_VIEW_ENBL_HIDE);
625 fMenuView->DisableEntry(M_VIEW_DOCK);
627 fMenuDock->EnableUndock(
kTRUE);
628 fMenuDock->EnableHide(
kTRUE);
629 fMenuView->CheckEntry(M_VIEW_ENBL_DOCK);
630 fMenuView->CheckEntry(M_VIEW_ENBL_HIDE);
634 fMenuDock->Connect(
"Undocked()",
"TestMainFrame",
this,
"HandleMenu(=M_VIEW_UNDOCK)");
637 fMenuHelp->AddEntry(
"&Contents", M_HELP_CONTENTS);
638 fMenuHelp->AddEntry(
"&Search...", M_HELP_SEARCH);
639 fMenuHelp->AddSeparator();
640 fMenuHelp->AddEntry(
"&About", M_HELP_ABOUT);
643 fMenuNew1->AddEntry(
"Remove New Menus", M_NEW_REMOVEMENU);
646 fMenuNew2->AddEntry(
"Remove New Menus", M_NEW_REMOVEMENU);
650 fMenuFile->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
651 fMenuFile->Connect(
"PoppedUp()",
"TestMainFrame",
this,
"HandlePopup()");
652 fMenuFile->Connect(
"PoppedDown()",
"TestMainFrame",
this,
"HandlePopdown()");
653 fMenuTest->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
654 fMenuView->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
655 fMenuHelp->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
656 fCascadeMenu->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
657 fCascade1Menu->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
658 fCascade2Menu->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
659 fMenuNew1->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
660 fMenuNew2->Connect(
"Activated(Int_t)",
"TestMainFrame",
this,
"HandleMenu(Int_t)");
663 fMenuBar->AddPopup(
"&File", fMenuFile, fMenuBarItemLayout);
664 fMenuBar->AddPopup(
"&Test", fMenuTest, fMenuBarItemLayout);
665 fMenuBar->AddPopup(
"&View", fMenuView, fMenuBarItemLayout);
666 fMenuBar->AddPopup(
"&Help", fMenuHelp, fMenuBarHelpLayout);
668 fMenuDock->AddFrame(fMenuBar, fMenuBarLayout);
671 fCanvasWindow =
new TGCanvas(fMain, 400, 240);
672 fContainer =
new TileFrame(fCanvasWindow->GetViewPort());
673 fContainer->SetCanvas(fCanvasWindow);
674 fCanvasWindow->SetContainer(fContainer->GetFrame());
680 for (
int i = 0; i < 256; ++i)
681 fCanvasWindow->AddFrame(
690 fTestButton =
new TGTextButton(fStatusFrame,
"&Open editor...", 150);
691 fTestButton->
Connect(
"Clicked()",
"TestMainFrame",
this,
"DoButton()");
695 fTestText->SetToolTipText(
"This is a text entry widget");
696 fTestText->Resize(300, fTestText->GetDefaultHeight());
699 gClient->GetColorByName(
"yellow", yellow);
705 fMain->SetWindowName(
"GuiTest Signal/Slots");
707 fMain->MapSubwindows();
713 Connect(
"Created()",
"TestMainFrame",
this,
"Welcome()");
717TestMainFrame::~TestMainFrame()
726 delete fCascade1Menu;
727 delete fCascade2Menu;
735void TestMainFrame::CloseWindow()
742void TestMainFrame::DoButton()
746 Editor *ed =
new Editor(fMain, 600, 400);
747 ed->LoadBuffer(editortxt1);
748 ed->AddBuffer(editortxt2);
749 ed->AddBuffer(editortxt3);
750 ed->AddBuffer(editortxt4);
751 ed->AddBuffer(editortxt5);
752 ed->AddBuffer(editortxt6);
756void TestMainFrame::HandleMenu(
Int_t id)
767 printf(
"fIniDir = %s\n", fi.
fIniDir);
773 case M_FILE_SAVE: printf(
"M_FILE_SAVE\n");
break;
776 printf(
"M_FILE_PRINT\n");
777 printf(
"Hiding itself, select \"Print Setup...\" to enable again\n");
778 fMenuFile->HideEntry(M_FILE_PRINT);
781 case M_FILE_PRINTSETUP:
782 printf(
"M_FILE_PRINTSETUP\n");
783 printf(
"Enabling \"Print\"\n");
784 fMenuFile->EnableEntry(M_FILE_PRINT);
791 case M_TEST_DLG:
new TestDialog(
gClient->GetRoot(), fMain, 400, 200);
break;
793 case M_TEST_MSGBOX:
new TestMsgBox(
gClient->GetRoot(), fMain, 400, 200);
break;
795 case M_TEST_SLIDER:
new TestSliders(
gClient->GetRoot(), fMain, 400, 200);
break;
797 case M_TEST_SHUTTER:
new TestShutter(
gClient->GetRoot(), fMain, 400, 200);
break;
799 case M_TEST_DIRLIST:
new TestDirList(
gClient->GetRoot(), fMain, 400, 200);
break;
801 case M_TEST_FILELIST:
new TestFileList(
gClient->GetRoot(), fMain, 400, 200);
break;
803 case M_TEST_PROGRESS:
new TestProgress(
gClient->GetRoot(), fMain, 600, 300);
break;
805 case M_TEST_NUMBERENTRY:
new EntryTestDlg(
gClient->GetRoot(), fMain);
break;
807 case M_TEST_FONTDIALOG: {
810 if (
prop.fName !=
"")
811 printf(
"Selected font: %s, size %d, italic %s, bold %s, color 0x%lx, align %u\n",
prop.fName.Data(),
815 case M_TEST_NEWMENU: {
816 if (fMenuTest->IsEntryChecked(M_TEST_NEWMENU)) {
817 HandleMenu(M_NEW_REMOVEMENU);
820 fMenuTest->CheckEntry(M_TEST_NEWMENU);
822 fMenuBar->AddPopup(
"New 1", fMenuNew1, fMenuBarItemLayout,
p);
823 p = fMenuBar->GetPopup(
"Help");
824 fMenuBar->AddPopup(
"New 2", fMenuNew2, fMenuBarItemLayout,
p);
825 fMenuBar->MapSubwindows();
829 fMenuTest->AddEntry(
"Remove New Menus", M_NEW_REMOVEMENU,
nullptr,
nullptr,
e);
832 case M_NEW_REMOVEMENU: {
833 fMenuBar->RemovePopup(
"New 1");
834 fMenuBar->RemovePopup(
"New 2");
836 fMenuTest->DeleteEntry(M_NEW_REMOVEMENU);
837 fMenuTest->UnCheckEntry(M_TEST_NEWMENU);
840 case M_VIEW_ENBL_DOCK:
841 fMenuDock->EnableUndock(!fMenuDock->EnableUndock());
842 if (fMenuDock->EnableUndock()) {
843 fMenuView->CheckEntry(M_VIEW_ENBL_DOCK);
844 fMenuView->EnableEntry(M_VIEW_UNDOCK);
846 fMenuView->UnCheckEntry(M_VIEW_ENBL_DOCK);
847 fMenuView->DisableEntry(M_VIEW_UNDOCK);
851 case M_VIEW_ENBL_HIDE:
852 fMenuDock->EnableHide(!fMenuDock->EnableHide());
853 if (fMenuDock->EnableHide()) {
854 fMenuView->CheckEntry(M_VIEW_ENBL_HIDE);
856 fMenuView->UnCheckEntry(M_VIEW_ENBL_HIDE);
861 fMenuDock->DockContainer();
862 fMenuView->EnableEntry(M_VIEW_UNDOCK);
863 fMenuView->DisableEntry(M_VIEW_DOCK);
867 fMenuDock->UndockContainer();
868 fMenuView->EnableEntry(M_VIEW_DOCK);
869 fMenuView->DisableEntry(M_VIEW_UNDOCK);
872 default: printf(
"Menu item %d selected\n",
id);
break;
882 fMain->Connect(
"CloseWindow()",
"TestDialog",
this,
"DoClose()");
883 fMain->DontCallClose();
891 fOkButton->
Connect(
"Clicked()",
"TestDialog",
this,
"DoOK()");
892 fCancelButton =
new TGTextButton(fFrame1,
"&Cancel", 2);
893 fCancelButton->
Connect(
"Clicked()",
"TestDialog",
this,
"DoCancel()");
899 fFrame1->
AddFrame(fCancelButton, fL1);
902 fMain->AddFrame(fFrame1, fL2);
906 fTab =
new TGTab(fMain, 300, 300);
907 fTab->
Connect(
"Selected(Int_t)",
"TestDialog",
this,
"DoTab(Int_t)");
920 tf = fTab->
AddTab(
"Tab 2");
936 for (i = 0; i < 20; i++) {
938 snprintf(tmp, 20,
"Entry %i", i + 1);
944 fBtn1->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
945 fBtn2->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
946 fChk1->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
947 fChk2->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
948 fRad1->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
949 fRad2->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
956 tf = fTab->
AddTab(
"Tab 3");
958 fStartB =
new TGTextButton(fF3,
"Start &Filling Hists", 40);
959 fStopB =
new TGTextButton(fF3,
"&Stop Filling Hists", 41);
960 fStartB->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
961 fStopB->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
979 fEc1->
GetCanvas()->
Connect(
"ProcessedEvent(Int_t,Int_t,Int_t,TObject*)",
"TestDialog",
this,
980 "HandleEmbeddedCanvas(Int_t,Int_t,Int_t,TObject*)");
984 gClient->GetColorByName(
"yellow", yellow);
991 tf = fTab->
AddTab(
"Tab 4");
994 bt->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
997 bt->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
1001 fCheckMulti->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
1004 for (i = 0; i < 20; ++i) {
1011 fListBox->
Resize(150, 80);
1014 tf = fTab->
AddTab(
"Tab 5");
1025 for (j = 0; j < 4; j++) {
1026 snprintf(buff, 100,
"Module %i", j + 1);
1034 tent->
SetFont(
"-adobe-courier-bold-r-*-*-14-*-*-*-*-*-iso8859-1");
1046 bt->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
1050 bt->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
1054 bt->
Connect(
"Clicked()",
"TestDialog",
this,
"HandleButtons()");
1062 fMain->AddFrame(fTab, fL5);
1064 fMain->MapSubwindows();
1068 fMain->CenterOnParent();
1070 fMain->SetWindowName(
"Dialog");
1076TestDialog::~TestDialog()
1080 fMain->DeleteWindow();
1083void TestDialog::FillHistos()
1090 fHpx =
new TH1F(
"hpx",
"This is the px distribution", 100, -4, 4);
1091 fHpxpy =
new TH2F(
"hpxpy",
"py vs px", 40, -4, 4, 40, -4, 4);
1101 while (fFillHistos) {
1104 fHpxpy->
Fill(px, py);
1111 fHpxpy->
Draw(
"cont");
1122void TestDialog::DoClose()
1124 printf(
"\nTerminating dialog: via window manager\n");
1136void TestDialog::CloseWindow()
1143void TestDialog::DoOK()
1146 printf(
"\nTerminating dialog: OK pressed\n");
1167void TestDialog::DoCancel()
1170 printf(
"\nTerminating dialog: Cancel pressed\n");
1180void TestDialog::HandleButtons(
Int_t id)
1189 printf(
"DoButton: id = %d\n",
id);
1192 static int newtab = 0;
1196 fFillHistos =
kTRUE;
1210 snprintf(tmp, 20,
"Entry %i", fLastEntry);
1211 fListBox->
AddEntry(tmp, fLastEntry);
1216 if (fFirstEntry <= fLastEntry) {
1225 if ((s ==
"Tab 3") && (fMain->MustCleanup() !=
kDeepCleanup)) {
1241 for (
int i = 0; i < nt; i++) {
1251 snprintf(tmp, 20,
"New Tab %d", ++newtab);
1263void TestDialog::DoTab(
Int_t id)
1265 printf(
"Tab item %d activated\n",
id);
1273 printf(
"event = %d, x = %d, y = %d, obj = %s::%s\n", event,
x,
y,
sel->IsA()->GetName(),
sel->GetName());
1277 : fRedTextGC(
TGButton::GetDefaultGC())
1284 fMain->Connect(
"CloseWindow()",
"TestMsgBox",
this,
"CloseWindow()");
1285 fMain->DontCallClose();
1295 gClient->GetColorByName(
"red", red);
1310 fTestButton->
Connect(
"Clicked()",
"TestMsgBox",
this,
"DoTest()");
1314 gClient->GetColorByName(
"green", green);
1318 fCloseButton->
Connect(
"Clicked()",
"TestMsgBox",
this,
"DoClose()");
1328 f1->AddFrame(fTestButton, fL1);
1329 f1->AddFrame(fCloseButton, fL1);
1330 f1->AddFrame(fPictButton, fL1);
1331 fMain->AddFrame(
f1, fL21);
1355 for (i = 0; i < 13; ++i)
1363 for (i = 0; i < 4; ++i) {
1365 fR[i]->
Connect(
"Clicked()",
"TestMsgBox",
this,
"DoRadio()");
1380 fTbtitle->
AddText(0,
"MsgBox");
1381 fTbmsg->
AddText(0,
"This is a test message box.");
1398 fMain->AddFrame(f2, fL2);
1400 fMain->MapSubwindows();
1404 fMain->CenterOnParent();
1406 fMain->SetWindowName(
"Message Box Test");
1415TestMsgBox::~TestMsgBox()
1419 fMain->DeleteWindow();
1422void TestMsgBox::CloseWindow()
1429void TestMsgBox::DoClose()
1436void TestMsgBox::DoTest()
1440 int i, buttons, retval;
1444 for (i = 0; i < 13; i++)
1446 buttons |= mb_button_id[i];
1448 for (i = 0; i < 4; i++)
1450 icontype = mb_icon[i];
1457 fMain->Disconnect(
"CloseWindow()");
1458 fMain->Connect(
"CloseWindow()",
"TestMsgBox",
this,
"TryToClose()");
1460 fMain->Disconnect(
"CloseWindow()");
1461 fMain->Connect(
"CloseWindow()",
"TestMsgBox",
this,
"CloseWindow()");
1464void TestMsgBox::TryToClose()
1468 printf(
"Can't close the window '%s' : a message box is still open\n", fMain->GetWindowName());
1471void TestMsgBox::DoRadio()
1478 if (
id >= 21 &&
id <= 24) {
1479 for (
int i = 0; i < 4; i++)
1480 if (fR[i]->WidgetId() !=
id)
1490 fMain->Connect(
"CloseWindow()",
"TestSliders",
this,
"CloseWindow()");
1491 fMain->DontCallClose();
1505 fTeh1->
Connect(
"TextChanged(char*)",
"TestSliders",
this,
"DoText(char*)");
1506 fTev1->
Connect(
"TextChanged(char*)",
"TestSliders",
this,
"DoText(char*)");
1509 fHslider1->
Connect(
"PositionChanged(Int_t)",
"TestSliders",
this,
"DoSlider(Int_t)");
1513 fVslider1->
Connect(
"PositionChanged(Int_t)",
"TestSliders",
this,
"DoSlider(Int_t)");
1516 fVframe1->
Resize(100, 100);
1524 fTeh2->
Connect(
"TextChanged(char*)",
"TestSliders",
this,
"DoText(char*)");
1525 fTev2->
Connect(
"TextChanged(char*)",
"TestSliders",
this,
"DoText(char*)");
1528 fHslider2->
Connect(
"PositionChanged(Int_t)",
"TestSliders",
this,
"DoSlider(Int_t)");
1534 fVslider2->
Connect(
"PositionChanged()",
"TestSliders",
this,
"DoSlider()");
1535 fVframe2->
Resize(100, 100);
1543 fVframe1->
AddFrame(fHslider1, fBly);
1544 fVframe1->
AddFrame(fVslider1, fBly);
1548 fVframe2->
AddFrame(fHslider2, fBly);
1549 fVframe2->
AddFrame(fVslider2, fBly);
1553 fMain->AddFrame(fVframe2, fBfly1);
1554 fMain->AddFrame(fVframe1, fBfly1);
1556 fMain->SetWindowName(
"Slider Test");
1558 fMain->Resize(
size);
1560 fMain->SetWMSize(
size.fWidth,
size.fHeight);
1561 fMain->SetWMSizeHints(
size.fWidth,
size.fHeight,
size.fWidth,
size.fHeight, 0, 0);
1566 fMain->CenterOnParent();
1568 fMain->MapSubwindows();
1574TestSliders::~TestSliders()
1578 fMain->DeleteWindow();
1581void TestSliders::CloseWindow()
1588void TestSliders::DoText(
const char * )
1604void TestSliders::DoSlider(
Int_t pos)
1637 }
else if (
id == VSId1) {
1648 }
else if (
id == HSId2) {
1659 }
else if (
id == VSId2) {
1679 fMain->Connect(
"CloseWindow()",
"TestShutter",
this,
"CloseWindow()");
1680 fMain->DontCallClose();
1688 AddShutterItem(
"Histograms", histo_data);
1689 AddShutterItem(
"Functions", function_data);
1690 AddShutterItem(
"Trees", tree_data);
1693 fMain->AddFrame(fShutter, fLayout);
1695 fMain->MapSubwindows();
1696 fMain->Resize(80, 300);
1699 fMain->CenterOnParent();
1701 fMain->SetWindowName(
"Shutter Test");
1707void TestShutter::AddShutterItem(
const char *
name, shutterData_t *
data)
1713 static int id = 5001;
1720 for (
int i = 0;
data[i].pixmap_name !=
nullptr; i++) {
1723 printf(
"<TestShutter::AddShutterItem>: missing pixmap \"%s\", using default",
data[i].pixmap_name);
1724 buttonpic = fDefaultPic;
1730 button->Connect(
"Clicked()",
"TestShutter",
this,
"HandleButtons()");
1738TestShutter::~TestShutter()
1742 gClient->FreePicture(fDefaultPic);
1743 fMain->DeleteWindow();
1746void TestShutter::CloseWindow()
1751void TestShutter::HandleButtons()
1754 printf(
"Shutter button %d\n", btn->
WidgetId());
1762 fMain->Connect(
"CloseWindow()",
"TestDirList",
this,
"CloseWindow()");
1763 fMain->DontCallClose();
1774 fMain->AddFrame(canvas, lo);
1775 fContents->
Connect(
"DoubleClicked(TGListTreeItem*,Int_t)",
"TestDirList",
this,
1776 "OnDoubleClick(TGListTreeItem*,Int_t)");
1777 fContents->
Connect(
"Clicked(TGListTreeItem*,Int_t)",
"TestDirList",
this,
"OnDoubleClick(TGListTreeItem*,Int_t)");
1779 fContents->
AddItem(0,
"c:\\");
1781 fContents->
AddItem(
nullptr,
"/");
1785 fMain->CenterOnParent();
1787 fMain->SetWindowName(
"List Dir Test");
1789 fMain->MapSubwindows();
1794TestDirList::~TestDirList()
1803void TestDirList::CloseWindow()
1835 TList *files = dir.GetListOfFiles();
1845 if ((fname !=
"..") && (fname !=
".")) {
1846 fContents->
AddItem(item, fname);
1848 }
else if (fname.
EndsWith(
".root")) {
1849 fContents->
AddItem(item, fname, fIcon, fIcon);
1863 fMain->Connect(
"CloseWindow()",
"TestDirList",
this,
"CloseWindow()");
1864 fMain->DontCallClose();
1871 fMain->AddFrame(mb, lo);
1876 fMenu->AddEntry(
"&List",
kLVList);
1878 fMenu->AddSeparator();
1879 fMenu->AddEntry(
"&Close", 10);
1880 fMenu->Connect(
"Activated(Int_t)",
"TestFileList",
this,
"DoMenu(Int_t)");
1884 fMain->AddFrame(
lv, lo);
1887 gClient->GetColorByName(
"white", white);
1889 fContents->
Connect(
"DoubleClicked(TGFrame*,Int_t)",
"TestFileList",
this,
"OnDoubleClick(TGLVEntry*,Int_t)");
1892 fMain->CenterOnParent();
1894 fMain->SetWindowName(
"File List Test");
1895 fMain->MapSubwindows();
1897 fContents->SetDefaultHeaders();
1898 fContents->DisplayDirectory();
1899 fContents->AddFile(
"..");
1901 fContents->StopRefreshTimer();
1905TestFileList::~TestFileList()
1924void TestFileList::DisplayFile(
const TString &fname)
1932 fContents->SetColHeaders(
"Name",
"Title");
1934 TIter next(file.GetListOfKeys());
1937 while ((key = (
TKey *)next())) {
1950void TestFileList::DisplayDirectory(
const TString &fname)
1954 fContents->SetDefaultHeaders();
1956 fContents->ChangeDirectory(fname);
1957 fContents->DisplayDirectory();
1958 fContents->AddFile(
"..");
1968 static TFile *file =
nullptr;
1971 file =
new TFile(fname);
1995 const char *fname = (
const char *)
f->GetUserData();
1998 DisplayObject(fname,
name);
1999 }
else if (
name.EndsWith(
".root")) {
2002 DisplayDirectory(
name);
2009void TestFileList::CloseWindow()
2021 fMain->Connect(
"CloseWindow()",
"TestProgress",
this,
"DoClose()");
2022 fMain->DontCallClose();
2032 fVProg1->SetBarColor(
"purple");
2035 fVProg2->SetBarColor(
"green");
2037 fHframe1->Resize(300, 300);
2042 fHProg1->ShowPosition();
2044 fHProg2->SetBarColor(
"lightblue");
2045 fHProg2->ShowPosition(
kTRUE,
kFALSE,
"%.0f events");
2050 fGO->Connect(
"Clicked()",
"TestProgress",
this,
"DoGo()");
2052 fVframe1->
Resize(300, 300);
2060 fHframe1->AddFrame(fVProg1, fHint1);
2061 fHframe1->AddFrame(fVProg2, fHint1);
2063 fVframe1->
AddFrame(fHProg1, fHint2);
2064 fVframe1->
AddFrame(fHProg2, fHint2);
2065 fVframe1->
AddFrame(fHProg3, fHint2);
2068 fMain->AddFrame(fHframe1, fHint4);
2069 fMain->AddFrame(fVframe1, fHint5);
2071 fMain->SetWindowName(
"Progress Test");
2073 fMain->Resize(
size);
2076 fMain->CenterOnParent();
2078 fMain->MapSubwindows();
2084TestProgress::~TestProgress()
2088 fMain->DeleteWindow();
2091void TestProgress::CloseWindow()
2098void TestProgress::DoClose()
2117void TestProgress::DoGo()
2127 fVProg2->SetBarColor(
"green");
2128 int cnt1 = 0, cnt2 = 0, cnt3 = 0, cnt4 = 0;
2129 int inc1 = 4, inc2 = 3, inc3 = 2, inc4 = 1;
2130 while (cnt1 < 100 || cnt2 < 100 || cnt3 < 100 || cnt4 < 100) {
2133 fVProg1->Increment(inc1);
2137 fVProg2->Increment(inc2);
2139 fVProg2->SetBarColor(
"red");
2143 fHProg1->Increment(inc3);
2147 fHProg2->Increment(inc4);
2148 fHProg3->Increment(inc4);
2161const char *numlabel[] = {
2162 "Integer",
"One digit real",
"Two digit real",
"Three digit real",
"Four digit real",
"Real",
"Degree.min.sec",
2163 "Min:sec",
"Hour:min",
"Hour:min:sec",
"Day/month/year",
"Month/day/year",
"Hex"};
2175 12 * 3600 + 15 * 60,
2184 fMain->Connect(
"CloseWindow()",
"EntryTestDlg",
this,
"CloseWindow()");
2185 fMain->DontCallClose();
2190 TGGC myGC = *
gClient->GetResourcePool()->GetFrameGC();
2191 TGFont *myfont =
gClient->GetFont(
"-adobe-helvetica-bold-r-*-*-12-*-*-*-*-*-iso8859-1");
2197 fMain->AddFrame(fF1, fL1);
2199 for (
int i = 0; i < 13; i++) {
2203 fF[i]->AddFrame(fNumericEntries[i], fL2);
2205 fF[i]->AddFrame(fLabel[i], fL2);
2209 fMain->AddFrame(fF2, fL3);
2213 fLimits[0]->SetLogStep(
kFALSE);
2218 fLimits[1]->SetLogStep(
kFALSE);
2225 fSetButton->Connect(
"Clicked()",
"EntryTestDlg",
this,
"SetLimits()");
2228 fExitButton->Connect(
"Clicked()",
"EntryTestDlg",
this,
"DoOK()");
2232 fMain->SetWindowName(
"Number Entry Test");
2233 fMain->SetIconName(
"Number Entry Test");
2234 fMain->SetClassHints(
"NumberEntryDlg",
"NumberEntryDlg");
2236 fMain->MapSubwindows();
2240 fMain->CenterOnParent();
2251EntryTestDlg::~EntryTestDlg()
2255 fMain->DeleteWindow();
2258void EntryTestDlg::CloseWindow()
2263void EntryTestDlg::DoOK()
2267 fMain->SendCloseMessage();
2270void EntryTestDlg::SetLimits()
2272 Double_t min = fLimits[0]->GetNumber();
2296 for (
int i = 0; i < 13; i++) {
2297 fNumericEntries[i]->SetFormat(fNumericEntries[i]->GetNumStyle(),
attr);
2298 fNumericEntries[i]->SetLimits(lim, min, max);
2307 fMain->Connect(
"CloseWindow()",
"Editor",
this,
"CloseWindow()");
2308 fMain->DontCallClose();
2315 fMain->AddFrame(fEdit, fL1);
2316 fEdit->Connect(
"Opened()",
"Editor",
this,
"DoOpen()");
2317 fEdit->Connect(
"Saved()",
"Editor",
this,
"DoSave()");
2318 fEdit->Connect(
"Closed()",
"Editor",
this,
"DoClose()");
2322 gClient->GetColorByName(
"#3399ff", pxl);
2323 fEdit->SetSelectBack(pxl);
2327 fOK->Connect(
"Clicked()",
"Editor",
this,
"DoOK()");
2329 fMain->AddFrame(fOK, fL2);
2333 fMain->MapSubwindows();
2345 fMain->DeleteWindow();
2348void Editor::SetTitle()
2352 TGText *txt = GetEditor()->GetText();
2357 snprintf(title, 256,
"ROOT Editor - Untitled");
2361 fMain->SetWindowName(title);
2362 fMain->SetIconName(title);
2372void Editor::LoadBuffer(
const char *buffer)
2376 fEdit->LoadBuffer(buffer);
2379void Editor::LoadFile(
const char *file)
2383 fEdit->LoadFile(file);
2386void Editor::AddBuffer(
const char *buffer)
2392 fEdit->AddText(&txt);
2395void Editor::CloseWindow()
2409void Editor::DoOpen()
2414void Editor::DoSave()
2419void Editor::DoClose()
2428 new TestMainFrame(
gClient->GetRoot(), 400, 220);
2433int main(
int argc,
char **argv)
2437 if (
gROOT->IsBatch()) {
2438 fprintf(stderr,
"%s: cannot run in batch mode\n", argv[0]);
const Mask_t kButtonPressMask
const Mask_t kAnyModifier
const Mask_t kPointerMotionMask
const Mask_t kButtonReleaseMask
ULong_t Pixel_t
Pixel value.
#define RQ_OBJECT(sender_class)
size_t size(const MatrixT &matrix)
retrieve the size of a square matrix
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 void data
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 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 prop
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 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 cname
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t attr
Option_t Option_t TPoint TPoint const char mode
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t height
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t button
Option_t Option_t TPoint TPoint const char text
R__EXTERN void * gTQSender
R__EXTERN TRandom * gRandom
char * StrDup(const char *str)
Duplicate the string str.
R__EXTERN TSystem * gSystem
This class creates the ROOT Application Environment that interfaces to the windowing system eventloop...
virtual void Terminate(Int_t status=0)
Terminate the application by call TSystem::Exit() unless application has been told to return from Run...
virtual void SetFillColor(Color_t fcolor)
Set the fill area color.
Bool_t InheritsFrom(const char *cl) const override
Return kTRUE if this class inherits from a class with name "classname".
static ULong_t RGB2Pixel(Int_t r, Int_t g, Int_t b)
Convert r,g,b to graphics system dependent pixel value.
TObject * Get(const char *namecycle) override
Return pointer to object identified by namecycle.
Describe directory structure in memory.
A ROOT file is an on-disk file, usually with extension .root, that stores objects in a file-system-li...
A frame containing two scrollbars (a horizontal and a vertical) and a viewport.
Like a checkbutton but instead of the check mark there is color area with a little down arrow.
A combobox (also known as a drop down listbox) allows the selection of one item out of a list of item...
virtual void AddEntry(TGString *s, Int_t id)
virtual void Select(Int_t id, Bool_t emit=kTRUE)
Make the selected item visible in the combo box window and emit signals according to the second param...
The base class for composite widgets (menu bars, list boxes, etc.).
virtual void SetLayoutManager(TGLayoutManager *l)
Set the layout manager for the composite frame.
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=nullptr)
Add frame to the composite frame using the specified layout hints.
void MapSubwindows() override
Map all sub windows that are part of the composite frame.
void Layout() override
Layout the elements of the composite frame.
void RemoveAll() override
Remove all items from the container.
virtual void SetPagePosition(const TGPosition &pos)
Set page position.
A frame with handles that allow it to be undocked (i.e.
DoubleSlider widgets allow easy selection of a min and a max value out of a range.
virtual Float_t GetMinPosition() const
virtual void SetRange(Float_t min, Float_t max)
virtual void SetPosition(Float_t min, Float_t max)
Dragging the slider will generate the event:
This class creates a file selection dialog.
char * fFilename
selected file name
const char ** fFileTypes
file types used to filter selectable files
char * fIniDir
on input: initial directory, on output: new directory
void SetIniDir(const char *inidir)
Set directory name.
Font selection dialog, allowing to select one in the list of available fonts in the system.
Encapsulate fonts used in the GUI system.
FontStruct_t GetFontStruct() const
FontH_t GetFontHandle() const
A subclasses of TGWindow, and is used as base class for some simple widgets (buttons,...
void Resize(UInt_t w=0, UInt_t h=0) override
Resize the frame.
static Pixel_t GetWhitePixel()
Get white pixel value.
virtual UInt_t GetDefaultWidth() const
virtual UInt_t GetDefaultHeight() const
TClass * IsA() const override
virtual void DeleteWindow()
Delete window.
virtual void ChangeBackground(Pixel_t back)
Change frame background color.
Encapsulate a graphics context used in the low level graphics.
void SetFont(FontH_t v)
Set font.
void SetForeground(Pixel_t v)
Set foreground color.
A composite frame with a border and a title.
TGDimension GetDefaultSize() const override
Returns default size.
virtual void SetTitlePos(ETitlePos pos=kLeft)
Concrete class for horizontal slider.
A composite frame that layout their children in horizontal way.
TGHotString is a string with a "hot" character underlined.
virtual void SetSubnames(const char *n1="", const char *n2="", const char *n3="", const char *n4="", const char *n5="", const char *n6="", const char *n7="", const char *n8="", const char *n9="", const char *n10="", const char *n11="", const char *n12="")
Sets new subnames.
void SetUserData(void *userData)
This class handles GUI labels.
This class describes layout hints used by the layout classes.
A listbox is a box, possibly with scrollbar, containing entries.
virtual void RemoveEntry(Int_t id=-1)
remove entry with id.
void Resize(UInt_t w, UInt_t h) override
Resize the listbox widget.
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 SetMultipleSelections(Bool_t multi=kTRUE)
virtual const char * GetText() const =0
TGListTreeItem * GetParent() const
virtual void * GetUserData() const =0
virtual void SetUserData(void *, Bool_t=kFALSE)
A list tree is a widget that can contain a number of items arranged in a tree structure.
void AddItem(TGListTreeItem *parent, TGListTreeItem *item)
Add given item to list tree.
A list view is a widget that can contain a number of items arranged in a grid or list.
Defines top level windows that interact with the system Window Manager.
This layout managers does not make use of TGLayoutHints.
TGNumberEntry is a number entry input widget with up/down buttons.
The TGPicture class implements pictures and icons used in the different GUI elements and widgets.
Pixmap_t GetPicture() const
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.
Slider widgets allow easy selection of a range.
virtual void SetPosition(Int_t pos)
Set slider position.
virtual void SetRange(Int_t min, Int_t max)
Set slider range.
TGString wraps a TString and adds some graphics routines like drawing, size of string on screen depen...
Service classes of the tab widget.
const char * GetString() const
A tab widget contains a set of composite frames each with a little tab with a name (like a set of fol...
TGTabElement * GetTabTab(Int_t tabIndex) const
Return the tab element of tab with index tabIndex.
Int_t GetNumberOfTabs() const
Return number of tabs.
virtual void RemoveTab(Int_t tabIndex=-1, Bool_t storeRemoved=kTRUE)
Remove container and tab of tab with index tabIndex.
virtual TGCompositeFrame * AddTab(TGString *text)
Add a tab to the tab widget.
A text buffer is used in several widgets, like TGTextEntry, TGFileDialog, etc.
void AddText(Int_t pos, const char *text)
const char * GetString() const
Yield an action as soon as it is clicked.
A TGTextEdit is a specialization of TGTextView.
A TGTextEntry is a one line text input widget.
Int_t GetCursorPosition() const
void Deselect()
Deselects all text (i.e.
virtual void SetCursorPosition(Int_t pos)
Set the cursor position to newPos.
virtual void SetFont(TGFont *font, Bool_t local=kTRUE)
Changes text font specified by pointer to TGFont object.
A TGText is a multi line text buffer.
Bool_t LoadBuffer(const char *txtbuf)
Load a 0 terminated buffer. Lines will be split at ' '.
const char * GetFileName() const
This is a layout manager for the TGListView widget.
Defines transient windows that typically are used for dialogs windows.
Concrete class for vertical slider.
A composite frame that layout their children in vertical way.
ROOT GUI Window base class.
1-D histogram with a float per channel (see TH1 documentation)
virtual Int_t Fill(Double_t x)
Increment bin with abscissa X by 1.
void Draw(Option_t *option="") override
Draw this histogram with options.
2-D histogram with a float per channel (see TH1 documentation)
Int_t Fill(Double_t) override
Invalid Fill method.
Book space in a file, create I/O buffers, to fill them, (un)compress them.
const char * GetTitle() const override
Returns title (title can contain 32x32 xpm thumbnail/icon).
virtual const char * GetClassName() const
const char * GetName() const override
Returns name of object.
Mother of all ROOT objects.
virtual Bool_t IsFolder() const
Returns kTRUE in case object contains browsable objects (like containers or lists of other objects).
virtual void Browse(TBrowser *b)
Browse object. May be overridden for another default action.
void SetBit(UInt_t f, Bool_t set)
Set or unset the user status bits as specified in f.
virtual void Print(Option_t *option="") const
This method must be overridden when a class wants to print itself.
void SetBorderMode(Short_t bordermode) override
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.
virtual void Rannor(Float_t &a, Float_t &b)
Return 2 numbers distributed following a gaussian with mean=0 and sigma=1.
This class creates a TGCanvas in which a TCanvas is created.
TCanvas * GetCanvas() const
Bool_t EndsWith(const char *pat, ECaseCompare cmp=kExact) const
Return true if string ends with the specified string.
Describes an Operating System directory for the browser.
A TSystemFile describes an operating system file.
virtual Bool_t IsDirectory(const char *dir=nullptr) const
Check if object is a directory.
virtual const char * PrependPathName(const char *dir, TString &name)
Concatenate a directory and a file name.
virtual Bool_t ChangeDirectory(const char *path)
Change directory.
virtual void Sleep(UInt_t milliSec)
Sleep milliSec milli seconds.
virtual const char * WorkingDirectory()
Return working directory.
virtual Bool_t ProcessEvents()
Process pending events (GUI, timers, sockets).
static void SingleShot(Int_t milliSec, const char *receiver_class, void *receiver, const char *method)
This static function calls a slot after a given time interval.
static TVirtualPadEditor * GetPadEditor(Bool_t load=kTRUE)
Returns the pad editor dialog. Static method.
static void Terminate()
Close the global pad editor. Static method.
__device__ AFloat max(AFloat x, AFloat y)
EGEventType fType
of event (see EGEventType)
UInt_t fCode
key or button code