00001 // @(#)root/guibuilder:$Id: TGuiBldNameFrame.h 30063 2009-09-08 12:15:59Z bellenot $ 00002 // Author: Valeriy Onuchin 12/09/04 00003 00004 /************************************************************************* 00005 * Copyright (C) 1995-2004, Rene Brun and Fons Rademakers. * 00006 * All rights reserved. * 00007 * * 00008 * For the licensing terms see $ROOTSYS/LICENSE. * 00009 * For the list of contributors see $ROOTSYS/README/CREDITS. * 00010 *************************************************************************/ 00011 00012 #ifndef ROOT_TGuiBldNameFrame 00013 #define ROOT_TGuiBldNameFrame 00014 00015 ////////////////////////////////////////////////////////////////////////// 00016 // // 00017 // TGuiBldNameFrame - frame sdisplaying the class name of frame // 00018 // and the name of frame // 00019 // // 00020 // // 00021 ////////////////////////////////////////////////////////////////////////// 00022 00023 00024 #ifndef ROOT_TGFrame 00025 #include "TGFrame.h" 00026 #endif 00027 00028 class TGLabel; 00029 class TGTextEntry; 00030 class TGuiBldEditor; 00031 class TGuiBldEditor; 00032 class TRootGuiBuilder; 00033 class TGListTree; 00034 class TGFrame; 00035 class TGCanvas; 00036 class TGListTreeItem; 00037 class TGuiBldDragManager; 00038 00039 00040 ////////////////////////////////////////////////////////////////////////// 00041 class TGuiBldNameFrame : public TGCompositeFrame { 00042 00043 private: 00044 TGLabel *fLabel; // label of frame class name 00045 TGTextEntry *fFrameName; // name of the frame 00046 TGuiBldEditor *fEditor; // pointer to main editor 00047 TGCompositeFrame *fTitleFrame; // frame saying that it's "Name Frame" 00048 TRootGuiBuilder *fBuilder; // pointer to builder 00049 TGuiBldDragManager *fManager; // main manager 00050 TGListTree *fListTree; // list tree containing frames hierarchy 00051 TGCanvas *fCanvas; 00052 00053 protected: 00054 void DoRedraw(); 00055 00056 public: 00057 TGuiBldNameFrame(const TGWindow *p, TGuiBldEditor *editor); 00058 virtual ~TGuiBldNameFrame() { } 00059 00060 void ChangeSelected(TGFrame *frame); 00061 Bool_t CheckItems(TGCompositeFrame *main); 00062 TGListTreeItem *FindItemByName(TGListTree *tree, const char* name, TGListTreeItem *item = 0); 00063 TGCompositeFrame *GetMdi(TGFrame *frame); 00064 void MapItems(TGCompositeFrame *main); 00065 void RemoveFrame(TGFrame *frame); 00066 void Reset(); 00067 void SelectFrameByItem(TGListTreeItem* item, Int_t i = 0); 00068 void UpdateName(); 00069 00070 ClassDef(TGuiBldNameFrame, 0) // frame name editor 00071 }; 00072 00073 00074 #endif