00001 // @(#)root/gui:$Id: TGMdiFrame.h 23115 2008-04-10 13:35:37Z rdm $ 00002 // Author: Bertrand Bellenot 20/08/2004 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 /************************************************************************** 00013 00014 This file is part of TGMdi, an extension to the xclass toolkit. 00015 Copyright (C) 1998-2002 by Harald Radke, Hector Peraza. 00016 00017 This application is free software; you can redistribute it and/or 00018 modify it under the terms of the GNU Library General Public 00019 License as published by the Free Software Foundation; either 00020 version 2 of the License, or (at your option) any later version. 00021 00022 This application is distributed in the hope that it will be useful, 00023 but WITHOUT ANY WARRANTY; without even the implied warranty of 00024 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU 00025 Library General Public License for more details. 00026 00027 You should have received a copy of the GNU Library General Public 00028 License along with this library; if not, write to the Free 00029 Software Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA. 00030 00031 **************************************************************************/ 00032 00033 #ifndef ROOT_TGMdiFrame 00034 #define ROOT_TGMdiFrame 00035 00036 ////////////////////////////////////////////////////////////////////////// 00037 // // 00038 // TGMdiFrame. // 00039 // // 00040 // This file contains the TGMdiFrame class. // 00041 // // 00042 ////////////////////////////////////////////////////////////////////////// 00043 00044 #ifndef ROOT_TGFrame 00045 #include "TGFrame.h" 00046 #endif 00047 00048 class TGPicture; 00049 class TGMdiMainFrame; 00050 class TGMdiDecorFrame; 00051 00052 00053 class TGMdiFrame : public TGCompositeFrame { 00054 00055 friend class TGMdiMainFrame; 00056 friend class TGMdiDecorFrame; 00057 00058 protected: 00059 enum { kDontCallClose = BIT(14) }; 00060 00061 TGMdiMainFrame *fMain; // pointer to the MDI main frame 00062 ULong_t fMdiHints; // MDI hints, also used to identify titlebar buttons 00063 00064 TString GetMdiHintsString() const; 00065 00066 public: 00067 TGMdiFrame(TGMdiMainFrame *main, Int_t w, Int_t h, 00068 UInt_t options = 0, 00069 Pixel_t back = GetDefaultFrameBackground()); 00070 virtual ~TGMdiFrame(); 00071 00072 virtual void Move(Int_t x, Int_t y); 00073 virtual Bool_t CloseWindow(); //*SIGNAL* 00074 virtual Bool_t Help() { return kFALSE; } 00075 00076 virtual void SetMdiHints(ULong_t mdihints); 00077 ULong_t GetMdiHints() const { return fMdiHints; } 00078 00079 void DontCallClose(); 00080 void SetWindowName(const char *name); 00081 void SetWindowIcon(const TGPicture *pic); 00082 const char *GetWindowName(); 00083 const TGPicture *GetWindowIcon(); 00084 00085 virtual void SavePrimitive(ostream &out, Option_t *option = ""); 00086 00087 ClassDef(TGMdiFrame, 0) // MDI Frame 00088 }; 00089 00090 #endif