Hi RootTalk,
I am still a beginner with Root framework and have some good knowledge in C++.
My question is that I want to see a code of a text box within a pad I have divided in. Preferably using TGTextEdit.
My code:
[code] //draws lepto logo on pad 4, mid canvas of tc1
pad[4]->cd();
pad[4]->Divide(2, 1);
//left side of pad 4 is the logo
pad[4]->cd(1);
image.Draw(“X”);
//right side of pad 4 is the comment box
pad[4]->cd(2);
TGMainFrame *fMain;
TGHorizontalFrame *hframe = new TGHorizontalFrame(fMain, 200, 40);
fMain = new TGMainFrame(gClient->GetRoot());
auto uGC = new TGGC(); //for textbox
TGFont *uFont;
uFont = gClient->GetFont("-*-helvectiva-medium-r-*-*-12-*-*-*-*-*-iso8859-1"); // for textbox
TGTextEdit *fTextEdit606 = new TGTextEdit(hframe, -1, uGC->GetGC(), uFont->GetFontStruct(), kSunkenFrame | kDoubleBorder | kOwnBackground);
hframe->AddFrame(fTextEdit606, new TGLayoutHints(kLHintsLeft | kLHintsTop, 2, 2, 2, 2));
[/code]
I would like to emphasis again, show me a code of a text box within a pad. This textbox is used for entering text and saving it. Please help me here, as I have been stuck in this for the past couple of days. Really appreciate any help.
Thanks,
Moj