95 "Enacapsulated PostScript",
"*.eps",
98 "ASImage XML",
"*.xml",
121 virtual ~TGuiBldMenuDialog();
126 void ConnectButtonSignals();
130 void Add(
const char *argname,
const char *value,
const char *
type);
147 fWidgets =
new TList();
157 ConnectButtonSignals();
169TGuiBldMenuDialog::~TGuiBldMenuDialog()
180void TGuiBldMenuDialog::ConnectButtonSignals()
184 fCancel->Connect(
"Pressed()",
"TGuiBldDragManager",
gGuiBldDragManager,
"DoDialogCancel()");
190void TGuiBldMenuDialog::ApplyMethod()
193 fObject->Execute(fMethod->GetName(), params);
199const char *TGuiBldMenuDialog::GetParameters()
201 static char params[1024];
214 TIter next(fWidgets);
217 while ((obj = next())) {
218 if (obj->IsA() != TGLabel::Class())
break;
225 const char *data = 0;
227 if (obj->IsA() == TGTextEntry::Class())
233 if (selfobjpos == nparam-1) {
234 if (params[0]) strlcat(params,
",", 1024-strlen(params));
236 strlcat(params, param, 1024-strlen(params));
239 if (params[0]) strlcat(params,
",", 1024-strlen(params));
241 if (!strncmp(
type,
"char*", 5))
242 snprintf(param, 255,
"\"%s\"", data);
244 strlcpy(param, data,
sizeof(param));
246 strlcpy(param,
"0",
sizeof(param));
248 strlcat(params, param, 1024-strlen(params));
252 if (selfobjpos == nparam) {
253 if (params[0]) strlcat(params,
",", 1024-strlen(params));
255 strlcat(params, param, 1024-strlen(params));
271 ret +=
" [default: ";
283void TGuiBldMenuDialog::Add(
const char *argname,
const char *value,
const char *
type)
287 b->AddText(0, value);
303void TGuiBldMenuDialog::CloseWindow()
311void TGuiBldMenuDialog::Build()
314 Int_t selfobjpos = -1;
316 TIter next(fMethod->GetListOfMethodArgs());
321 if (selfobjpos != argpos) {
323 const char *argname = arg_name.
Data();
326 const char *charstar =
"char*";
330 strlcpy(basictype, datatype->
GetTypeName(),
sizeof(basictype));
334 Warning(
"Dialog",
"data type is not basic type, assuming (int)");
335 strlcpy(basictype,
"int",
sizeof(basictype));
338 if (strchr(argname,
'*')) {
339 strlcat(basictype,
"*", 32-strlen(basictype));
344 if (
m &&
m->GetterMethod(fObject->IsA())) {
349 if (!strncmp(basictype,
"char*", 5)) {
352 if (tdefval && strlen(tdefval))
353 strlcpy(val, tdefval,
sizeof(val));
354 }
else if (!strncmp(basictype,
"float", 5) ||
355 !strncmp(basictype,
"double", 6)) {
357 m->GetterMethod()->Execute(fObject,
"", ddefval);
359 }
else if (!strncmp(basictype,
"char", 4) ||
360 !strncmp(basictype,
"bool", 4) ||
361 !strncmp(basictype,
"int", 3) ||
362 !strncmp(basictype,
"long", 4) ||
363 !strncmp(basictype,
"short", 5)) {
365 m->GetterMethod()->
Execute(fObject,
"", ldefval);
373 if ((opt =
m->GetOptions())) {
374 Warning(
"Dialog",
"option menu not yet implemented");
384 if (tval) strlcpy(val, tval,
sizeof(val));
401 height = fOK->GetDefaultHeight();
414 fWidgets->Add(fCancel);
415 height = fCancel->GetDefaultHeight();
433void TGuiBldMenuDialog::Popup()
450 SetWMSize(
width, height);
451 SetWMSizeHints(
width, height,
width, height, 0, 0);
478 !
gClient->IsEditable())
return 0;
480 dst = src = child =
gVirtualX->GetDefaultRootWindow();
482 while (child && dst) {
485 gVirtualX->TranslateCoordinates(src, dst, xx, yy, xx, yy, child);
496 if (!frame || !frame->
InheritsFrom(TGCompositeFrame::Class())) {
522 const char * ,
const char * )
527class TGuiBldDragManagerGrid {
538 TGuiBldDragManagerGrid();
539 ~TGuiBldDragManagerGrid();
541 void SetStep(
UInt_t step);
547ULong_t TGuiBldDragManagerGrid::fgPixel = 0;
548TGGC *TGuiBldDragManagerGrid::fgBgnd = 0;
553TGuiBldDragManagerGrid::TGuiBldDragManagerGrid()
568TGuiBldDragManagerGrid::~TGuiBldDragManagerGrid()
570 fWindow =
gClient->GetWindowById(fWinId);
573 fWindow->SetBackgroundPixmap(0);
574 fWindow->SetBackgroundColor(((
TGFrame*)fWindow)->GetBackground());
589void TGuiBldDragManagerGrid::SetStep(
UInt_t step)
596 fWinId = fWindow->
GetId();
605void TGuiBldDragManagerGrid::InitBgnd()
620 fgBgnd->SetForeground(fgPixel);
626void TGuiBldDragManagerGrid::InitPixmap()
632 fPixmap =
gVirtualX->CreatePixmap(
gClient->GetDefaultRoot()->GetId(), fgStep, fgStep);
633 gVirtualX->FillRectangle(fPixmap, fgBgnd->GetGC(), 0, 0, fgStep, fgStep);
637 fgStep - 1, fgStep - 1, 1, 1);
644void TGuiBldDragManagerGrid::Draw()
650 fWindow =
gClient->GetWindowById(fWinId);
652 if (fWindow && (fWindow !=
gClient->GetRoot())) {
663 fWinId = fWindow->
GetId();
671class TGuiBldDragManagerRepeatTimer :
public TTimer {
684class TGGrabRect :
public TGFrame {
738 gVirtualX->ChangeWindowAttributes(fId, &attr);
746 fClient->GetColorByName(
"black", back);
755 SetBackgroundPixmap(fPixmap);
770class TGAroundFrame :
public TGFrame {
780TGAroundFrame::TGAroundFrame() :
TGFrame(
gClient->GetDefaultRoot(), 1, 1,
788 gVirtualX->ChangeWindowAttributes(fId, &attr);
790 fClient->GetColorByName(
"blue", blue);
791 SetBackgroundColor(blue);
796class TGuiBldDragManagerPimpl {
807 TGuiBldDragManagerGrid *fGrid;
812 Int_t fGrabX, fGrabY;
814 Int_t fLastPopupAction;
816 TGGrabRect *fGrabRect[8];
825 TList *fFrameMenuTrash;
831 fRepeatTimer =
new TGuiBldDragManagerRepeatTimer(
m, 100);
834 for (i = 0; i <8; i++) {
835 fGrabRect[i] =
new TGGrabRect(i);
837 for (i = 0; i <4; i++) {
838 fAroundFrame[i] =
new TGAroundFrame();
841 fFrameMenuTrash =
new TList();
850 fX0 = fY0 = fX = fY = fXf = fYf = fGrabX = fGrabY = 0;
857 fGrabListPosition = 0;
861 fSpacePressedFrame = 0;
863 fFrameMenuTrash->
Delete();
867 ~TGuiBldDragManagerPimpl() {
869 for (i = 0; i <8; i++) {
872 for (i = 0; i <4; i++) {
873 delete fAroundFrame[i];
878 fFrameMenuTrash->
Delete();
879 delete fFrameMenuTrash;
904 fPimpl =
new TGuiBldDragManagerPimpl(
this);
931 fName =
"Gui Builder Drag Manager";
988 TList *methodList = IsA()->GetListOfMethods();
989 TIter next(methodList);
993 while ((method = (
TMethod*) next())) {
1012 fPimpl->fGrid =
new TGuiBldDragManagerGrid();
1029 fPimpl->fGrid->SetStep(step);
1112 if (
fPimpl->fGrab && (gid !=
fPimpl->fGrab->GetId())) {
1115 gid =
fPimpl->fGrab->GetId();
1136 for (
int i = 0; i < 8; i++) {
1175 if (
fStop || !frame) {
1197 str +=
" cannot be editted.";
1203 if (frame != comp) {
1231 str +=
"can not be selected";
1243 static Int_t x, x0,
y, y0, xx, yy;
1264 str +=
" Press SpaceBar to unselect the frame.";
1265 if (
IsFixedSize(frame)) str +=
" This frame cannot be resized.";
1389 str +=
" is grabbed";
1413 str +=
fPimpl->fGrab->GetName();
1414 str +=
" ungrabbed";
1427 while (parent && (parent !=
gClient->GetDefaultRoot())) {
1428 if (parent->
GetId() ==
id) {
1450 dst = src = child = w;
1455 gVirtualX->TranslateCoordinates(src, dst,
x,
y,
x,
y, child);
1482 if (
fPimpl->fPlacePopup) {
1491 if (now-was < 100) {
1511 fPimpl->fGrab->GetHeight()-2)) {
1543 fPimpl->fAroundFrame[0]->MapRaised();
1545 fPimpl->fAroundFrame[1]->MapRaised();
1547 fPimpl->fAroundFrame[2]->MapRaised();
1549 fPimpl->fAroundFrame[3]->MapRaised();
1551 for (
int i = 0; i < 4; i++)
fPimpl->fAroundFrame[i]->UnmapWindow();
1577 fPimpl->fGrabRect[i]->MapRaised();
1588 if (
fStop || !win || (win == gw)) {
1608 fPimpl->fPlane->ChangeOptions(
fPimpl->fPlane->GetOptions() & ~kRaisedFrame);
1638 static Int_t gy = 0;
1639 static Int_t gx = 0;
1640 static UInt_t gstate = 0;
1654 if (
fPimpl->fRepeatTimer) {
1656 fPimpl->fRepeatTimer->Reset();
1657 fPimpl->fRepeatTimer->Remove();
1712 fPimpl->fButtonPressed) {
1767 if (!
fPimpl->fSpacePressedFrame) {
1773 context_fr =
fPimpl->fSpacePressedFrame;
1783 fPimpl->fX0 =
event->fXRoot;
1784 fPimpl->fY0 =
event->fYRoot;
1788 fPimpl->fClickFrame = frame;
1802 if (frame ==
fPimpl->fGrab) {
1813 fPimpl->fX =
event->fXRoot;
1814 fPimpl->fY =
event->fYRoot;
1829 if (frame ==
fPimpl->fGrab) {
1874 fPimpl->fX =
event->fXRoot;
1875 fPimpl->fY =
event->fYRoot;
1888 if (
fStop || !frame) {
1988 win =
event->fWindow;
2007 switch (event->
fType) {
2031 static Long_t gLastClick = 0;
2032 static UInt_t gLastButton = 0;
2033 static Int_t gDbx = 0;
2034 static Int_t gDby = 0;
2036 if ((event->
fTime - gLastClick < 350) &&
2037 (event->
fCode == gLastButton) &&
2048 }
else if (!(event->
fState & 0xFF)) {
2062 gDbw =
event->fWindow;
2063 gLastClick =
event->fTime;
2064 gLastButton =
event->fCode;
2065 gDbx =
event->fXRoot;
2066 gDby =
event->fYRoot;
2221 event->fUser[0] = fr->
GetId();
2259 event->fUser[0] = w->
GetId();
2278 !
fPimpl->fGrab->IsEditable()) {
2320 return ((
TGFrame*)w)->HandleKey(event);
2330 event->fWindow = parent->
GetId();
2333 return ((
TGFrame*)w)->HandleKey(event);
2337 fPimpl->fSpacePressedFrame = 0;
2350 gVirtualX->LookupString(event, tmp,
sizeof(tmp), keysym);
2354 switch ((
EKeySym)keysym & ~0x20) {
2369 if (
fPimpl->fClickFrame && !
fPimpl->fClickFrame->IsEditable()) {
2469 }
else if (
fPimpl->fGrab) {
2517 Int_t x0, y0, xx, yy;
2521 if (!newfr || !newfr->
GetId() || !oldfr || !oldfr->
GetId())
return;
2526 x0 = x0 < 0 ? 0 : x0;
2527 y0 = y0 < 0 ? 0 : y0;
2544 if ((frame->
GetX() >= x0) && (frame->
GetY() >= y0) &&
2548 if (frame ==
fPimpl->fGrab) {
2555 frame->
GetX(), frame->
GetY(), xx, yy,
c);
2641 if (
fStop || !cont) {
2651 w = w < 100 ? 100 : w;
2652 h =
h < 100 ? 100 :
h;
2714 if (
fPimpl->fGrab->InheritsFrom(TGCompositeFrame::Class()) &&
2715 !
fPimpl->fGrab->InheritsFrom(TGCanvas::Class()) &&
2716 !
fPimpl->fGrab->InheritsFrom(TGContainer::Class()) &&
2724 if ((
fPimpl->fGrab->IsA() == TGCanvas::Class()) &&
2725 !((
TGCanvas*)
fPimpl->fGrab)->GetContainer()->InheritsFrom(TGContainer::Class()) &&
2761 TString str =
"Grab action performed.";
2762 str +=
" Press Cntrl-Return to Drop grabbed frames.";
2763 str +=
" Presss Return for TCanvas Grab";
2767 }
else if (on &&
fPimpl->fGrab) {
2778 if (
fPimpl->fGrab->InheritsFrom(TGCompositeFrame::Class())) {
2839 if ((fr->
GetX() >= x0) && (fr->
GetY() >= y0) &&
2849 else fr->
Move(x0, y0);
2863 else fr->
Move(x0, y0);
2926 str +=
fPimpl->fGrab->GetName();
2927 str +=
" cannot be deleted";
2973 if ((fr->
GetX() >= x0) && (fr->
GetY() >= y0) &&
3024 if (
fStop || !frame) {
3043 if (frame ==
fPimpl->fGrab) {
3080 fPimpl->fGrab->GetWidth(),
3081 fPimpl->fGrab->GetHeight());
3126 str +=
fPimpl->fGrab->GetName();
3127 str +=
" copied to clipboard";
3156 if (!
fPimpl->fReplaceOn) {
3211 str +=
fPimpl->fGrab->GetName();
3212 str +=
" replaced by ";
3283 f->
Resize(
f->GetWidth() + 10,
f->GetHeight() + 10);
3328 main->SetWMSizeHints(
main->GetDefaultWidth(),
main->GetDefaultHeight(), 10000, 10000, 0, 0);
3333 if (
gVirtualX->InheritsFrom(
"TGX11"))
main->SetIconPixmap(
"bld_rgb.xpm");
3334 main->SaveSource(fname.
Data(),
file ?
"keep_names quiet" :
"keep_names");
3351 main->RaiseWindow();
3361 !
fPimpl->fGrab || !
fPimpl->fGrab->InheritsFrom(TGCompositeFrame::Class())) {
3440static Int_t canResize(TGFrame *frame, Int_t x, Int_t y, UInt_t &w, UInt_t &h)
3442 if (frame->InheritsFrom(TGCompositeFrame::Class())) return 0;
3444 TGCompositeFrame *comp = (TGCompositeFrame*)frame;
3446 TIter next(comp->GetList());
3448 Int_t d = gGuiBldDragManager->GetGridStep();
3451 while ((fe = (TGFrameElement*)next())) {
3452 if (x + fe->fFrame->GetX() + fe->fFrame->GetWidth() > w) {
3453 w = fe->fFrame->GetX() + x + fe->fFrame->GetWidth();
3456 if (y + fe->fFrame->GetY() + fe->fFrame->GetHeight() > h) {
3457 h = fe->fFrame->GetY() + y + fe->fFrame->GetHeight();
3506 switch (
fPimpl->fResizeType) {
3508 if ((((
int)fr->
GetWidth() >
x) || (
x < 0)) &&
3511 if (fr->
GetY() +
y < 2) {
3514 if (fr->
GetX() +
x < 2) {
3537 if ((
x > 0) && (((
int)fr->
GetHeight() >
y) || (
y < 0))) {
3539 if (fr->
GetY() +
y < 2) {
3565 if (fr->
GetY() +
y < 2) {
3577 if ((((
int)fr->
GetWidth() >
x) || (
x < 0)) && (
y > 0)) {
3579 if (fr->
GetX() +
x < 2) {
3602 if ((
x > 0) && (
y > 0)) {
3607 w = fr->
GetX() + w > wp ? wp - fr->
GetX() : w;
3632 if (fr->
GetX() +
x < 2) {
3710 Bool_t move = (
x > 0) && (
y > 0) && ((
x +
fPimpl->fGrab->GetWidth()) < (w - 0)) &&
3711 ((
y +
fPimpl->fGrab->GetHeight()) < (
h - 30));
3715 if (!move && !
gVirtualX->InheritsFrom(
"TGX11")) {
3726 str +=
fPimpl->fGrab->GetName();
3727 str +=
" is moved to absolute position ";
3761 if (
fStop || !comp) {
3825 if (w && (w !=
gVirtualX->GetDefaultRootWindow())) {
3845 if ((comp !=
fPimpl->fGrab) && (
x >= 0) && (
y >= 0) &&
3898 static Int_t gy =
event->fYRoot;
3899 static Int_t gx =
event->fXRoot;
3919 fPimpl->fX =
event->fXRoot;
3920 fPimpl->fY =
event->fYRoot;
3970 x =
x > x0 ? x0 :
x;
3971 y =
y > y0 ? y0 :
y;
3988 frame->
Resize(w < grid ? grid : w,
h < grid ? grid :
h);
3991 frame->
Resize(w < grid ? 15*grid : w,
h < grid ? 30*grid :
h);
3992 }
else if (frame->
InheritsFrom(TGHorizontalFrame::Class())) {
3993 frame->
Resize(w < grid ? 30*grid : w,
h < grid ? 15*grid :
h);
3995 else frame->
Resize(w < 2*grid ? 2*grid : w,
h < 2*grid ? 2*grid :
h);
4032 frame = ((
TGCanvas*)frame)->GetContainer();
4064 if ((
x == x0) || (
y==y0 ))
return;
4067 x0 = x0 < 0 ? 0 : x0;
4077 y0 = y0 < 0 ? 0 : y0;
4096 xswap ?
x : x0, yswap ?
y : y0,
4099 xswap ? x0 :
x, yswap ? y0 :
y,
4115 TString str =
"Lasso drawn. Align frames inside or presss Return key to grab frames.";
4274 if (
fPimpl->fSpacePressedFrame) {
4277 mov =
fPimpl->fSpacePressedFrame;
4279 fPimpl->fSpacePressedFrame = 0;
4300 fPimpl->fRepeatTimer->Reset();
4362 fPimpl->fSpacePressedFrame = 0;
4461 str +=
" dropped into ";
4465 str +=
" at position ";
4472 if (parent && (parent ==
fPimpl->fGrabParent) &&
fPimpl->fGrabListPosition &&
4473 frame && parent->
InheritsFrom(TGCompositeFrame::Class())) {
4493 fPimpl->fGrabListPosition = 0;
4537 fPimpl->fGrab->InheritsFrom(TGCompositeFrame::Class())) {
4565 if ((
d.fWidth > 10) && (
d.fHeight > 10)) {
4567 }
else if (
d.fWidth > 10) {
4569 }
else if (
d.fHeight > 10) {
4587 if ((
d.fWidth > 10) && (
d.fHeight > 10)) {
4589 }
else if (
d.fWidth > 10) {
4591 }
else if (
d.fHeight > 10) {
4630 if (
fPimpl->fRepeatTimer) {
4631 fPimpl->fRepeatTimer->Reset();
4642 if (
fPimpl->fRepeatTimer) {
4643 fPimpl->fRepeatTimer->Remove();
4695 fPimpl->fLastPopupAction = act;
4891 fEditor->
Connect(
"UpdateSelected(TGFrame*)",
"TGuiBldDragManager",
this,
4892 "HandleUpdateSelected(TGFrame*)");
4968 if (
fPimpl->fGrid->fgStep > 1) {
4969 fPimpl->fGrid->SetStep(1);
5016 if (parent->
InheritsFrom(TGMdiFrame::Class()))
return ret;
5032 if (
f->GetParent() &&
5033 f->GetParent()->InheritsFrom(TGCompositeFrame::Class())) {
5049 if (
f->InheritsFrom(TGCompositeFrame::Class())) {
5068 if (
fPimpl->fGrabRectHidden) {
5077 for (i = 0; i < 8; i++)
fPimpl->fGrabRect[i]->UnmapWindow();
5078 for (i = 0; i < 4; i++)
fPimpl->fAroundFrame[i]->UnmapWindow();
5150 str +=
" layout cannot be broken";
5160 str += (frame->
IsLayoutBroken() ?
" Disable Layout" :
" Enable Layout");
5163 if (
fPimpl->fGrab && (
fPimpl->fGrab->IsA() == TGCanvas::Class())) {
5188 if (
m->InheritsFrom(TGHorizontalLayout::Class())) {
5189 opt &= ~kHorizontalFrame;
5196 str +=
" Vertical Layout ON";
5199 }
else if (
m->InheritsFrom(TGVerticalLayout::Class())) {
5200 opt &= ~kVerticalFrame;
5207 str +=
" Horizontal Layout ON";
5217 if (
fPimpl->fGrab && (
fPimpl->fGrab->IsA() == TGCanvas::Class())) {
5275 if (p1 ==
kNPOS)
return "";
5279 if (p2 ==
kNPOS)
return "";
5281 return in(p1, p2-p1);
5298 while ((bc = (
TBaseClass*)nextBaseClass())) {
5315 if (!menu || !
object) {
5324 TClass *cl =
object->IsA();
5327 while ((method = (
TMethod*) next())) {
5350 if (!menu || !
object) {
5354 TList *menuItemList;
5367 menuItemList =
object->IsA()->GetMenuList();
5368 TIter nextItem(menuItemList);
5374 switch (menuItem->
GetType()) {
5380 methodList =
new TList;
5381 object->IsA()->GetMenuItems(methodList);
5383 TIter next(methodList);
5385 while ((method = (
TMethod*) next())) {
5386 if (classPtr != method->
GetClass()) {
5405 if (
m->GetterMethod()) {
5408 fPimpl->fFrameMenuTrash->Add(
r);
5409 TIter nxt(
m->GetOptions());
5419 fPimpl->fFrameMenuTrash->Add(t);
5423 if (t->
GetState())
r->CheckEntryByData(t);
5436 fPimpl->fFrameMenuTrash->Add(t);
5459 fPimpl->fFrameMenuTrash->Add(t);
5465 const char* menuItemTitle = menuItem->
GetTitle();
5466 if (strlen(menuItemTitle)==0) menuItemTitle = menuItem->
GetFunctionName();
5493 if (!me || !
fPimpl->fMenuObject) {
5501 str2.
Form(
"((TGuiBldDragManager*)0x%lx)->%s((%s*)0x%lx)", (
ULong_t)
this, method->
GetName(),
5535 fPimpl->fFrameMenuTrash->Delete();
5581 fPimpl->fClickFrame = frame;
5601 fFrameMenu->
Connect(
"Activated(Int_t)",
"TGuiBldDragManager",
this,
"DoClassMenu(Int_t)");
5687 const char *label = (frame->
IsLayoutBroken() ?
"Allow Layout\tCtrl+B" :
5688 "Break Layout\tCtrl+B");
5704 if (lm && ((lm->IsA() == TGVerticalLayout::Class()) ||
5705 (lm->IsA() == TGHorizontalLayout::Class())) && !
IsFixedLayout(frame)) {
5707 if (lm->IsA() == TGVerticalLayout::Class()) {
5710 }
else if (lm->IsA() == TGHorizontalLayout::Class()) {
5732 fPimpl->fSaveGrab = frame;
5738 fFrameMenu->
Connect(
"Activated(Int_t)",
"TGuiBldDragManager",
this,
"HandleAction(Int_t)");
5778 fLassoMenu->
Connect(
"Activated(Int_t)",
"TGuiBldDragManager",
this,
"HandleAction(Int_t)");
5806 for (i = 0; i < 10; i++) {
5809 for (i = 0; i < 10; i++) {
5864 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGFrame", fr,
"ChangeBackground(Pixel_t)");
5878 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGCompositeFrame", fr,
5879 "ChangeSubframesBackground(Pixel_t)");
5900 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGGroupFrame", fr,
"SetTextColor(Pixel_t)");
5928 fd->
Connect(
"FontSelected(char*)",
"TGGroupFrame", fr,
"SetTextFont(char*)");
5929 fd->
Connect(
"ColorSelected(Pixel_t)",
"TGGroupFrame", fr,
"SetTextColor(Pixel_t)");
5958 fd->
Connect(
"FontSelected(char*)",
"TGTextButton", fr,
"SetFont(char*)");
5959 fd->
Connect(
"ColorSelected(Pixel_t)",
"TGTextButton", fr,
"SetTextColor(Pixel_t)");
5960 fd->
Connect(
"AlignSelected(Int_t)",
"TGTextButton", fr,
"SetTextJustify(Int_t)");
5982 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGTextButton", fr,
"SetTextColor(Pixel_t)");
6051 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGFrame", fr,
"ChangeBackground(Pixel_t)");
6052 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGScrollBar", fr->
GetHScrollbar(),
"ChangeBackground(Pixel_t)");
6053 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGScrollBar", fr->
GetVScrollbar(),
"ChangeBackground(Pixel_t)");
6072 "ChangeBackground(Pixel_t)");
6077 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGLBEntry", se,
6078 "SetBackgroundColor(Pixel_t)");
6084 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGTextEntry", te,
6085 "SetBackgroundColor(Pixel_t)");
6125 fd->
Connect(
"FontSelected(char*)",
"TGLabel", fr,
"SetTextFont(char*)");
6126 fd->
Connect(
"ColorSelected(Pixel_t)",
"TGLabel", fr,
"SetTextColor(Pixel_t)");
6127 fd->
Connect(
"AlignSelected(Int_t)",
"TGLabel", fr,
"SetTextJustify(Int_t)");
6150 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGLabel", fr,
"SetTextColor(Pixel_t)");
6167 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGListBox", fr,
"ChangeBackground(Pixel_t)");
6185 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGProgressBar", fr,
"SetBarColor(Pixel_t)");
6207 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGProgressBar", fr,
6208 "SetForegroundColor(Pixel_t)");
6225 cd->
Connect(
"ColorSelected(Pixel_t)",
"TGTextEntry", fr,
"SetTextColor(Pixel_t)");
6249 fd->
Connect(
"FontSelected(char*)",
"TGTextEntry", fr,
"SetFont(char*)");
6250 fd->
Connect(
"ColorSelected(Pixel_t)",
"TGTextEntry", fr,
"SetTextColor(Pixel_t)");
6256 int tw, max_ascent, max_descent;
6264 gVirtualX->GetFontProperties(fs, max_ascent, max_descent);
6265 fr->
Resize(tw + 8, max_ascent + max_descent + 7);
const Mask_t kWAOverrideRedirect
const Mask_t kButtonPressMask
const Mask_t kWASaveUnder
Handle_t Pixmap_t
Pixmap handle.
const Mask_t kKeyPressMask
const Mask_t kButton1Mask
const Mask_t kKeyShiftMask
const Mask_t kKeyControlMask
const Mask_t kButton3Mask
const Mask_t kButton2Mask
Handle_t FontStruct_t
Pointer to font structure.
ULong_t Pixel_t
Pixel value.
Handle_t Window_t
Window handle.
include TDocParser_001 C image html pict1_TDocParser_001 png width
void Warning(const char *location, const char *msgfmt,...)
Use this function in warning situations.
ErrorHandlerFunc_t SetErrorHandler(ErrorHandlerFunc_t newhandler)
Set an errorhandler function. Returns the old handler.
void GetParameters(TFitEditor::FuncParams_t &pars, TF1 *func)
Stores the parameters of the given function into pars.
static const char * gSaveMacroTypes[]
@ kMWMInputFullApplicationModal
static Bool_t containBaseClass(const char *somestring, TClass *cl)
Helper.
static TString CreateArgumentTitle(TMethodArg *argument)
Create a string describing method argument.
static const char * gSaveMacroTypes[]
static Window_t GetWindowFromPoint(Int_t x, Int_t y)
Helper. Return a window located at point x,y (in screen coordinates)
static TGuiBldDragManager * gGuiBldDragManager
static TGuiBldMenuDialog * gMenuDialog
static TString FindMenuIconName(TString &in)
Return a name of icon.
static void GuiBldErrorHandler(Int_t, Bool_t, const char *, const char *)
Our own error handler (not used yet)
static const char * gImageTypes[]
static void layoutFrame(TGFrame *frame)
Helper to layout.
static Bool_t IsParentOfGrab(Window_t id, const TGWindow *grab)
Helper for IsPointVisible.
R__EXTERN TInterpreter * gCling
R__EXTERN TRandom * gRandom
R__EXTERN TSystem * gSystem
R__EXTERN TVirtualDragManager * gDragManager
R__EXTERN Atom_t gROOT_MESSAGE
R__EXTERN Atom_t gWM_DELETE_WINDOW
Each class (see TClass) has a linked list of its base class(es).
TClass * GetClassPointer(Bool_t load=kTRUE)
Get pointer to the base class TClass.
TClass instances represent classes, structs and namespaces in the ROOT type system.
TList * GetListOfBases()
Return list containing the TBaseClass(es) of a class.
Long_t Property() const
Returns the properties of the TClass as a bit field stored as a Long_t value.
static TClass * GetClass(const char *name, Bool_t load=kTRUE, Bool_t silent=kFALSE)
Static method returning pointer to TClass of the specified class name.
virtual Int_t GetEntries() const
virtual Bool_t IsEmpty() const
virtual Int_t GetSize() const
Return the capacity of the collection, i.e.
static ULong_t RGB2Pixel(Int_t r, Int_t g, Int_t b)
Convert r,g,b to graphics system dependent pixel value.
static ULong_t Number2Pixel(Int_t ci)
Static method that given a color index number, returns the corresponding pixel value.
All ROOT classes may have RTTI (run time type identification) support added.
TMethodCall * GetterMethod(TClass *cl=0)
Return a TMethodCall method responsible for getting the value of data member.
Basic data type descriptor (datatype information is obtained from CINT).
TString GetTypeName()
Get basic type of typedef, e,g.: "class TDirectory*" -> "TDirectory".
const char * GetSignature()
Return signature of function.
virtual void SetContainer(TGFrame *f)
TGFrame * GetContainer() const
virtual void MapSubwindows()
Map all canvas sub windows.
TGVScrollBar * GetVScrollbar() const
TGViewPort * GetViewPort() const
TGHScrollBar * GetHScrollbar() const
const TGWindow * GetDefaultRoot() const
Returns the root (i.e.
Bool_t IsEditable() const
const TGWindow * GetRoot() const
Returns current root (i.e.
void WaitForUnmap(TGWindow *w)
Wait for window to be unmapped.
void ResetWaitFor(TGWindow *w)
reset waiting
const TGResourcePool * GetResourcePool() const
TList * GetListOfPopups() const
void WaitFor(TGWindow *w)
Wait for window to be destroyed.
TGWindow * GetWindowById(Window_t sw) const
Find a TGWindow via its handle. If window is not found return 0.
const TGPicture * GetPicture(const char *name)
Get picture from the picture pool.
void SetRoot(TGWindow *root=nullptr)
Sets the current root (i.e.
void NeedRedraw(TGWindow *w, Bool_t force=kFALSE)
Set redraw flags.
EGEventType GetWaitForEvent() const
void FreePicture(const TGPicture *pic)
Free picture resource.
void UnregisterWindow(TGWindow *w)
Remove a TGWindow from the list of windows.
virtual void SetCurrentColor(Pixel_t col)
Change current color.
TGColorPalette * GetCustomPalette() const
void SetColor(Int_t ix, Pixel_t color)
Set color at index ix of color entries.
virtual TGLBEntry * GetSelectedEntry() const
virtual TGTextEntry * GetTextEntry() const
virtual TGListBox * GetListBox() const
virtual Bool_t HandleDragEnter(TGFrame *)
Handle drag enter event.
virtual void SetLayoutBroken(Bool_t on=kTRUE)
Set broken layout. No Layout method is called.
virtual TList * GetList() const
virtual void AddFrame(TGFrame *f, TGLayoutHints *l=0)
Add frame to the composite frame using the specified layout hints.
virtual UInt_t GetDefaultWidth() const
virtual TGLayoutManager * GetLayoutManager() const
virtual void SetEditable(Bool_t on=kTRUE)
Switch ON/OFF edit mode.
virtual void Layout()
Layout the elements of the composite frame.
virtual Bool_t IsLayoutBroken() const
virtual void ChangeOptions(UInt_t options)
Change composite frame options. Options is an OR of the EFrameTypes.
virtual void SetCleanup(Int_t mode=kLocalCleanup)
Turn on automatic cleanup of child frames in dtor.
virtual TGDimension GetDefaultSize() const
std::cout << fWidth << "x" << fHeight << std::endl;
virtual Bool_t TranslateCoordinates(TGFrame *child, Int_t x, Int_t y, Int_t &fx, Int_t &fy)
Translate coordinates to child frame.
virtual UInt_t GetDefaultHeight() const
virtual void SetEditDisabled(UInt_t on=1)
Set edit disable flag for this frame and subframes.
virtual void RemoveFrame(TGFrame *f)
Remove frame from composite frame.
virtual Bool_t IsEditable() const
Return kTRUE if frame is being edited.
TGUndockedFrame * GetUndocked() const
Bool_t IsUndocked() const
void SetIniDir(const char *inidir)
Set directory name.
virtual void SetAlign(Int_t align)
Set align.
virtual void SetFont(TGFont *font)
Set font.
virtual void EnableAlign(Bool_t on=kTRUE)
Enable/disable align combobox.
virtual void SetColor(Pixel_t color)
Set color.
TGFont * FindFont(FontStruct_t font) const
Find font based on its font struct. Returns 0 if font is not found.
virtual void ChangeOptions(UInt_t options)
Change frame options. Options is an OR of the EFrameTypes.
virtual TGDimension GetDefaultSize() const
std::cout << fWidth << "x" << fHeight << std::endl;
void AddInput(UInt_t emask)
Add events specified in the emask to the events the frame should handle.
virtual Bool_t IsLayoutBroken() const
static const TGGC & GetBlackGC()
Get black graphics context.
virtual Bool_t HandleDoubleClick(Event_t *)
Int_t GetBorderWidth() const
virtual void ReparentWindow(const TGWindow *p, Int_t x=0, Int_t y=0)
Reparent window, make p the new parent and position the window at position (x,y) in new parent.
virtual Bool_t HandleDragLeave(TGFrame *)
virtual void MapRaised()
map raised
virtual Bool_t HandleKey(Event_t *)
static Pixel_t GetWhitePixel()
Get white pixel value.
virtual UInt_t GetDefaultWidth() const
virtual UInt_t GetDefaultHeight() const
TGFrameElement * GetFrameElement() const
virtual void SetLayoutBroken(Bool_t=kTRUE)
virtual Bool_t HandleDragMotion(TGFrame *)
virtual void SetBackgroundColor(Pixel_t back)
Set background color (override from TGWindow base class).
virtual UInt_t GetOptions() const
static const TGGC & GetShadowGC()
Get shadow color graphics context.
virtual void Move(Int_t x, Int_t y)
Move frame.
virtual void Resize(UInt_t w=0, UInt_t h=0)
Resize the frame.
virtual Bool_t HandleButton(Event_t *)
virtual void SetEditable(Bool_t)
void SetFrameElement(TGFrameElement *fe)
virtual void SetCleanup(Int_t=kLocalCleanup)
virtual Bool_t IsEditable() const
virtual Pixel_t GetBackground() const
virtual void MoveResize(Int_t x, Int_t y, UInt_t w=0, UInt_t h=0)
Move and/or resize the frame.
virtual Bool_t HandleDragDrop(TGFrame *, Int_t, Int_t, TGLayoutHints *)
virtual void MapWindow()
map window
virtual void MapSubwindows()
map sub windows
static const TGGC & GetBckgndGC()
Get background color graphics context.
virtual void UnmapWindow()
unmap window
TGGC * FindGC(const TGGC *gc)
Find graphics context. Returns 0 in case gc is not found.
Pixel_t GetForeground() const
void SetForeground(Pixel_t v)
Set foreground color.
void SetBackground(Pixel_t v)
Set background color.
FontStruct_t GetFontStruct() const
GContext_t GetNormGC() const
virtual void SetImage(const char *img)
Set icon image.
virtual void SetImagePath(const char *path)
Set directory where image is located.
FontStruct_t GetFontStruct() const
Int_t GetTextJustify() const
GContext_t GetNormGC() const
virtual void SaveSource(const char *filename="Rootappl.C", Option_t *option="")
Save the GUI main frame widget in a C++ macro file.
void SetClassHints(const char *className, const char *resourceName)
Set the windows class and resource name.
virtual void CloseWindow()
Close and delete main frame.
void SetIconName(const char *name)
Set window icon name. This is typically done via the window manager.
void SetWMSize(UInt_t w, UInt_t h)
Give the window manager a window size hint.
void SetWMPosition(Int_t x, Int_t y)
Give the window manager a window position hint.
void SetMWMHints(UInt_t value, UInt_t funcs, UInt_t input)
Set decoration style for MWM-compatible wm (mwm, ncdwm, fvwm?).
void SetWMSizeHints(UInt_t wmin, UInt_t hmin, UInt_t wmax, UInt_t hmax, UInt_t winc, UInt_t hinc)
Give the window manager minimum and maximum size hints.
void SetWindowName(const char *name=0)
Set window name. This is typically done via the window manager.
const TGPicture * SetIconPixmap(const char *iconName)
Set window icon pixmap by name.
virtual void MoveResize(Int_t x, Int_t y, UInt_t w, UInt_t h)
Move the MDI window at position x, y and set size to w, h.
TGMdiTitleBar * GetTitleBar() const
Bool_t SetCurrent(TGMdiFrameList *newcurrent)
Set current (active) MDI child window (by frame list).
TGMdiFrame * GetCurrent() const
Return pointer on current (active) MDI child window.
Pixel_t GetBarColor() const
GContext_t GetNormGC() const
TGFontPool * GetFontPool() const
TGGCPool * GetGCPool() const
UInt_t GetBufferLength() const
UInt_t GetTextLength() const
FontStruct_t GetFontStruct() const
Int_t GetTextJustify() const
TGTextBuffer * GetBuffer() const
const char * GetText() const
FontStruct_t GetFontStruct() const
Pixel_t GetTextColor() const
virtual void SetWindowName(const char *name=0)
Set window name.
virtual const TGWindow * GetMainFrame() const
Returns top level main frame.
virtual const char * GetName() const
Return unique name, used in SavePrimitive methods.
virtual UInt_t GetEditDisabled() const
virtual void SetBackgroundPixmap(Pixmap_t pixmap)
set background pixmap
virtual void RequestFocus()
request focus
virtual void SetEditDisabled(UInt_t on=kEditDisable)
virtual void SetName(const char *name)
virtual void SetEditable(Bool_t on=kTRUE)
virtual void DestroyWindow()
destroy window
virtual Bool_t IsEditable() const
const TGWindow * GetParent() const
virtual Bool_t IsMapped()
Returns kTRUE if window is mapped on screen, kFALSE otherwise.
virtual void Resize(UInt_t w, UInt_t h)
Resize the window.
virtual void RaiseWindow()
raise window
TGFrame * GetEditableParent(TGFrame *f)
Return the parent frame which can be editted.
void ChangeSelected(TGFrame *f)
Inform outside wold that selected frame was changed.
void HandleAction(Int_t act)
Main handler of actions.
Bool_t IsFixedH(TGWindow *f) const
void DoDialogCancel()
Process dialog Cancel button pressed.
void DeleteMenuDialog()
Delete dialog and trash.
void SetCursorType(Int_t cur)
Set cursor for selcted/grabbed frame.
void SwitchLayout()
Switch Horizontal/Vertical layout of selected/grabbed composite frame.
void ChangeImage(TGIcon *)
Invoke file dialog to assign a new image.
void DoClassMenu(Int_t)
Process a method chosen via frame context menu.
Bool_t IsMoveWaiting() const
Waits for either the mouse move from the given initial ButtonPress location or for the mouse button t...
void ChangeTextFont(TGGroupFrame *)
Change text font via font selection dialog.
Bool_t CheckDragResize(Event_t *event)
Check resize type event.
void SelectFrame(TGFrame *frame, Bool_t add=kFALSE)
Grab/Select frame.
TGFrame * InEditable(Window_t id)
Return a pointer to the parent window (which is being editted)
Bool_t CanChangeLayoutOrder(TGWindow *w) const
kTRUE - if it's possible to change layout order in the parent's layout of window w
Bool_t HandleSelection(Event_t *)
not used yet.
void HandlePaste()
Handle paste action.
virtual ~TGuiBldDragManager()
Destructor.
void Snap2Grid()
Draw grid on editable frame and restore background on previuosly editted one.
Bool_t IsPointVisible(Int_t x, Int_t y)
Helper function for IsSelectedWindow method.
void PutToCanvas(TGCompositeFrame *cont)
Create a new TGCanvas and place container into it.
Bool_t HandleMotion(Event_t *)
Handle motion event.
void CheckTargetUnderGrab()
Look for the drop target under grabbed/selected frame while moving.
void HideGrabRectangles()
Hide/Unmap grab rectangles.
void CreatePropertyEditor()
Create widget property editor (it could be located outside of guibuilder)
void SetGridStep(UInt_t step)
Set the grid step.
friend class TGuiBldMenuDialog
void Compact(Bool_t global=kTRUE)
Layout and Resize frame.
Bool_t HandleTimerEvent(Event_t *ev, TTimer *t)
Handle timer events or events coming from the recorder.
void DrawLasso()
Draw lasso for allocation new object.
void Menu4Frame(TGFrame *, Int_t x, Int_t y)
Create and place context menu for selected frame.
Int_t GetEndDragY() const
Returns the current Y coordinate of the dragged frame.
friend class TGuiBldDragManagerRepeatTimer
void RaiseMdiFrame(TGFrame *in)
Raise guibuilder's mdi frame.
void DeleteFrame(TGFrame *frame)
Delete frame.
void DoDialogApply()
Process dialog Apply button pressed.
Bool_t HandleExpose(Event_t *)
Handle repaint event.
void DoMove()
Handle move.
void ChangeBarColor(TGProgressBar *)
Set progress bar color via TGColorDialog.
void HandleDelete(Bool_t crop=kFALSE)
Handle delete or crop action.
void HandleButon3Pressed(Event_t *, TGFrame *frame=0)
Handle 3d mouse pressed (popup context menu)
void Menu4Lasso(Int_t x, Int_t y)
Create context menu for lasso actions.
void ReparentFrames(TGFrame *newfr, TGCompositeFrame *oldfr)
Reparent frames.
Int_t GetStrartDragX() const
Return the X coordinate where drag started.
void HandleLayoutOrder(Bool_t forward=kTRUE)
Change layout order.
Bool_t SaveFrame(const char *file=0)
Save composite frame as macro.
Bool_t IgnoreEvent(Event_t *e)
Return kTRUE if event is rejected for processing by drag manager.
void CloneEditable()
Create a frame which is the same as currently editted frame.
Bool_t Cancel(Bool_t delSrc)
Do cancel action.
void HandleReplace()
Handle replace.
void DoDialogOK()
Process dialog OK button pressed.
TList * GetFramesInside(Int_t x0, Int_t y0, Int_t x, Int_t y)
Return the list of frames inside of some area.
void DoResize()
handle resize
Bool_t HandleSelectionRequest(Event_t *)
not used yet.
TGCompositeFrame * FindCompositeFrame(Window_t id)
Find the first composite parent of window.
Bool_t EndDrag()
End dragging.
Bool_t HandleButtonPress(Event_t *)
Handle button press event.
Int_t GetStrartDragY() const
Return the Y coordinate where drag started.
void DrawGrabRectangles(TGWindow *win=0)
Draw small grab rectangles around grabbed/selected/frame.
void TimerEvent(Event_t *ev)
void HandleAlignment(Int_t to, Bool_t lineup=kFALSE)
Align frames located inside lasso area.
void SwitchEditable(TGFrame *frame)
Switch editable.
void DrawGrabRect(Int_t i, Int_t x, Int_t y)
Helper method to draw grab rectangle at position x,y.
Bool_t Drop()
Drop grabbed frame.
void UnmapAllPopups()
Unmap all popups.
void ChangePicture(TGPictureButton *)
Invoke file dialog to assign a new picture.
void DoRedraw()
Redraw the editted window.
Bool_t IsEditDisabled(TGWindow *f) const
TGFrame * FindMdiFrame(TGFrame *in)
Return a pointer to the parent mdi frame.
void ChangeBackgroundColor(TGListBox *)
Set background color for list box entries.
Bool_t HandleKey(Event_t *)
Handle key event.
Bool_t StartDrag(TGFrame *src, Int_t x, Int_t y)
Start dragging.
TGuiBldDragManagerPimpl * fPimpl
Bool_t CanCompact(TGWindow *w) const
kTRUE is frame could be compacted/"layouted"
void CloseMenus()
Helper to close all menus.
Bool_t HandleEvent(Event_t *)
Handle all events.
void GrabFrame(TGFrame *frame)
grab frame (see SelectFrame)
void AddClassMenuMethods(TGPopupMenu *menu, TObject *object)
Add entries with class //*MENU* methods.
void HandleCopy(Bool_t brk_layout=kTRUE)
Handle copy.
void ToGrid(Int_t &x, Int_t &y)
Return grid coordinates which are close to given.
void CreateListOfDialogs()
Create a list of dialog methods.
static TGFontDialog * fgGlobalFontDialog
void SetLassoDrawn(Bool_t on)
Set lasso drawn flag.
Bool_t IsFixedW(TGWindow *f) const
Bool_t RecognizeGesture(Event_t *, TGFrame *frame=0)
Recognize what was done when mouse button pressed.
void HandleCut()
Handle cut action.
TGWindow * GetResizableParent(TGWindow *p)
Find parent frame which can be resized.
static void MapGlobalDialog(TGMainFrame *dialog, TGFrame *fr)
Map dialog and place it relative to selected frame.
Bool_t HandleTimer(TTimer *)
The main event loop is originated here It repeadeatly queries pointer state and position on the scree...
void HandleReturn(Bool_t on=kFALSE)
Handling of return/enter key pressing.
UInt_t GetGridStep()
Return the grid step.
Bool_t HandleButton(Event_t *)
Handle button event occured in some ROOT frame.
Bool_t HandleButtonRelease(Event_t *)
Handle button release event.
static TGFontDialog * GetGlobalFontDialog()
Create global font dialog.
void Reset1()
Reset some parameters.
Bool_t HandleDestroyNotify(Event_t *)
Handle destroy notify.
void PlaceFrame(TGFrame *, TGLayoutHints *)
Put created frame at position of the last mouse click.
Bool_t IsFixedLayout(TGWindow *f) const
void SetPropertyEditor(TGuiBldEditor *e)
Helper method.
Bool_t CheckTargetAtPoint(Int_t x, Int_t y)
Helper. Look for the drop target under grabbed/selected frame while moving.
Int_t GetEndDragX() const
Return the current X coordinate of the dragged frame.
void SetEditable(Bool_t on=kTRUE)
Grab server.
TGFrame * GetMovableParent(TGWindow *p)
Find parent frame which can be dragged.
static TGColorDialog * fgGlobalColorDialog
Bool_t HandleConfigureNotify(Event_t *)
Resize events.
Bool_t IsFixedSize(TGWindow *f) const
Bool_t HandleDoubleClick(Event_t *)
Mouse double click handler (never should happen)
void HighlightCompositeFrame(Window_t)
Raise composite frame when mouse is moving over it.
void DoReplace(TGFrame *frame)
Replace frame (doesn't work yet properly)
void HandleGrid()
Switch on/of grid drawn.
Bool_t CanChangeLayout(TGWindow *w) const
kTRUE - if it's possible to switch disable/enable layout
Bool_t Save(const char *file="")
Save an editted frame to the file.
void BreakLayout()
Disable/Enable layout for selected/grabbed composite frame.
Bool_t IsPasteFrameExist()
Return kTRUE if paste frame exist.
void UngrabFrame()
Ungrab/Unselect selected/grabbed frame.
TRootGuiBuilder * fBuilder
void DropCanvas(TGCanvas *canvas)
Drop canvas container.
void ChangeProperties(TGLabel *)
Edit properties via font selection dialog.
Bool_t HandleClientMessage(Event_t *)
Handle client message.
Bool_t IsEventsDisabled(TGWindow *f) const
void AddDialogMethods(TGPopupMenu *menu, TObject *object)
Add DIALOG entries to the selected frame popup menu.
Bool_t IsSelectedVisible()
Return kTRUE if grabbed/selected frame is not overlapped by other windows.
void DeletePropertyEditor()
Delete widget property editor.
static TGColorDialog * GetGlobalColorDialog(Bool_t create=kTRUE)
Return pointer to global color dialog.
TGCompositeFrame * FindLayoutFrame(TGFrame *f)
Helper to find a frame which can be layouted.
TGFrame * GetBtnEnableParent(TGFrame *fr)
Return a parent which can handle button evevents.
TGFrame * GetSelected() const
Return the current grabbed/selected frame.
void HandleUpdateSelected(TGFrame *)
When selected frame was changed by guibuilder editor -> update its appearence.
Bool_t IsGrabDisabled(TGWindow *f) const
void ChangeTextColor(TGGroupFrame *)
Change text color via color selection dialog.
void ChangeSelected(TGFrame *)
Change selected frame.
void RemoveFrame(TGFrame *)
Remove a frame.
Bool_t IsEmbedded() const
TGuiBldAction * GetAction() const
static TGuiBuilder * Instance()
return an instance of TGuiBuilder object
virtual void SetAction(TGuiBldAction *act)
virtual Bool_t IsExecutable() const
An abstract interface to image processing library.
static TImage * Open(const char *file, EImageFileTypes type=kUnknown)
Open a specified image file.
static TImage * Create()
Create an image.
virtual void FromWindow(Drawable_t, Int_t=0, Int_t=0, UInt_t=0, UInt_t=0)
virtual Long_t Calc(const char *line, EErrorCode *error=0)=0
virtual void Add(TObject *obj)
virtual TObject * After(const TObject *obj) const
Returns the object after object obj.
virtual TObject * Remove(TObject *obj)
Remove object from the list.
virtual TObject * Last() const
Return the last object in the list. Returns 0 when list is empty.
virtual void AddAfter(const TObject *after, TObject *obj)
Insert object after object after in the list.
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.
Each ROOT method (see TMethod) has a linked list of its arguments.
const char * GetDefault() const
Get default value of method argument.
const char * GetTypeName() const
Get type of method argument, e.g.: "class TDirectory*" -> "TDirectory" Result needs to be used or cop...
TDataMember * GetDataMember() const
Returns TDataMember pointed by this methodarg.
void Execute(const char *, const char *, int *=0)
Execute method on this object with the given parameter string, e.g.
Each ROOT class (see TClass) has a linked list of methods.
virtual const char * GetCommentString()
Returns a comment string from the class declaration.
virtual TDataMember * FindDataMember()
Tries to guess DataMember from comment string and Method's name <==(only if 1 Argument!...
TClass * GetClass() const
EMenuItemKind IsMenuItem() const
virtual const char * GetTitle() const
Returns title of object.
virtual const char * GetName() const
Returns name of object.
Collectable string class.
const TString & GetString() const
Mother of all ROOT objects.
virtual void Execute(const char *method, const char *params, Int_t *error=0)
Execute method on this object with the given parameter string, e.g.
virtual const char * ClassName() const
Returns name of class to which the object belongs.
virtual Bool_t InheritsFrom(const char *classname) const
Returns kTRUE if object inherits from class "classname".
Long_t fValue
Data member to which this option belongs.
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.
Bool_t Disconnect(const char *signal=0, void *receiver=0, const char *slot=0)
Disconnects signal of this object from slot of receiver.
virtual UInt_t Integer(UInt_t imax)
Returns a random integer uniformly distributed on the interval [ 0, imax-1 ].
virtual void AddMacro(const char *macro, TImage *img)
Add macro to "User's Macros" section Input img must be static - do not delete it.
TGMdiFrame * FindEditableMdiFrame(const TGWindow *win)
Find the editable frame.
TGMdiMainFrame * GetMdiMain() const
virtual void UpdateStatusBar(const char *text=0)
Update information shown on the status bar.
static TGGC * GetPopupHlghtGC()
Return background GC for highlighted popup menu entry.
void EnableEditButtons(Bool_t on=kTRUE)
Enable/disable toolbar buttons according to the selected frame.
static TGPopupMenu * CreatePopup()
Return style popup menu.
virtual void ChangeSelected(TGFrame *f)
Set selected frame.
virtual void CloseWindow()
Close GUI builder via window manager "Close" button.
void EnableLassoButtons(Bool_t on=kTRUE)
Enable toolbar buttons for alignment.
TGuiBldEditor * GetEditor() const
virtual void HandleMenu(Int_t id)
Handle menu items.
TGDockableFrame * GetToolDock() const
virtual Bool_t OpenProject(Event_t *event=0)
Open new gui builder project.
virtual void Update()
Update gui builder.
virtual Bool_t SaveProject(Event_t *event=0)
Save selected project.
virtual TGFrame * ExecuteAction()
Execute an action.
virtual Bool_t NewProject(TString type="")
Create a new project.
Bool_t EndsWith(const char *pat, ECaseCompare cmp=kExact) const
Return true if string ends with the specified string.
const char * Data() const
static TString Format(const char *fmt,...)
Static method which formats a string using a printf style format descriptor and return a TString.
void Form(const char *fmt,...)
Formats a string using a printf style format descriptor.
Bool_t Contains(const char *pat, ECaseCompare cmp=kExact) const
Ssiz_t Index(const char *pat, Ssiz_t i=0, ECaseCompare cmp=kExact) const
virtual int GetPid()
Get process id.
virtual char * ConcatFileName(const char *dir, const char *name)
Concatenate a directory and a file name. User must delete returned string.
virtual TTime Now()
Get current time in milliseconds since 0:00 Jan 1 1995.
virtual Bool_t AccessPathName(const char *path, EAccessMode mode=kFileExists)
Returns FALSE if one can access a file using the specified access mode.
virtual const char * UnixPathName(const char *unixpathname)
Convert from a local pathname to a Unix pathname.
virtual void AddTimer(TTimer *t)
Add timer to list of system timers.
virtual const char * BaseName(const char *pathname)
Base name of a file name. Base name of /user/root is root.
virtual TString GetDirName(const char *pathname)
Return the directory name in pathname.
virtual int Unlink(const char *name)
Unlink, i.e.
virtual const char * TempDirectory() const
Return a user configured or systemwide directory to create temporary files in.
Handles synchronous and a-synchronous timer events.
void Reset()
Reset the timer.
void SetTime(Long_t milliSec)
virtual Bool_t Notify()
Notify when timer times out.
This class defines toggling facility for both - object's method or variables.
virtual void Toggle()
Toggles the Values and State of this object and connected data!
virtual void SetOnValue(Long_t lon)
virtual void SetToggledObject(TObject *obj, TMethod *anymethod)
Initializes it to toggle an object's datamember using this object's method.
virtual Bool_t GetState()
Returns the state of Toggle according to its current value and fOnValue, returns true if they match.
virtual void Init()
Initialization.
virtual void SetEditable(Bool_t)
Py_ssize_t GetBuffer(PyObject *pyobject, char tc, int size, void *&buf, bool check=true)
RooArgList L(const RooAbsArg &v1)
Type GetType(const std::string &Name)
Short_t Max(Short_t a, Short_t b)
Short_t Min(Short_t a, Short_t b)
TMatrixT< Element > & Add(TMatrixT< Element > &target, Element scalar, const TMatrixT< Element > &source)
Modify addition: target += scalar * source.
EGEventType fType
of event (see EGEventType)
Int_t fY
pointer x, y coordinates in event window
Handle_t fHandle
general resource handle (used for atoms or windows)
Int_t fFormat
Next fields only used by kClientMessageEvent.
Int_t fCount
if non-zero, at least this many more exposes
Window_t fWindow
window reported event is relative to
UInt_t fState
key or button mask
Int_t fYRoot
coordinates relative to root
Long_t fUser[5]
5 longs can be used by client message events NOTE: only [0], [1] and [2] may be used.
Time_t fTime
time event event occurred in ms
UInt_t fCode
key or button code
Attributes that can be used when creating or changing a window.
Bool_t fOverrideRedirect
boolean value for override-redirect
Mask_t fMask
bit mask specifying which fields are valid
Bool_t fSaveUnder
should bits under be saved (popups)?