TQtRootGuiFactory.h

Go to the documentation of this file.
00001 // Author: Valeri Fine   13/05/2003
00002 /****************************************************************************
00003 ** $Id: TQtRootGuiFactory.h,v 1.3 2007/11/02 17:08:10 fine Exp $
00004 **
00005 ** Copyright (C) 2002 by Valeri Fine.  All rights reserved.
00006 **
00007 ** This file may be distributed under the terms of the Q Public License
00008 ** as defined by Trolltech AS of Norway and appearing in the file
00009 ** LICENSE.QPL included in the packaging of this file.
00010 *****************************************************************************/
00011 
00012 #ifndef ROOT_TQtRootGuiFactory
00013 #define ROOT_TQtRootGuiFactory
00014 
00015 //////////////////////////////////////////////////////////////////////////
00016 //                                                                      //
00017 // TQtRootGuiFactory                                                    //
00018 //                                                                      //
00019 // This class is a proxy-factory for Qt-base ROOT GUI components.       //
00020 // It overrides the member functions of the X11/win32gdk-based          //
00021 // TRootGuiFactory.                                                     //
00022 //                                                                      //
00023 //////////////////////////////////////////////////////////////////////////
00024 
00025 #include "TGuiFactory.h"
00026 
00027 class TQtApplication;
00028 class TVirtualX;
00029 class TGClient;
00030 
00031 class TQtRootGuiFactory : public  TGuiFactory {
00032 
00033 private:
00034    TGuiFactory *fGuiProxy;
00035    
00036 protected:
00037   static void CreateQClient();
00038   static TGClient *gfQtClient;
00039 
00040 public:
00041    TQtRootGuiFactory();
00042    TQtRootGuiFactory(const char *name, const char *title= "Qt-based ROOT GUI Factory");
00043    virtual ~TQtRootGuiFactory() { delete fGuiProxy; }
00044 
00045    virtual TApplicationImp *CreateApplicationImp(const char *classname, int *argc, char **argv);
00046 
00047    virtual TCanvasImp *CreateCanvasImp(TCanvas *c, const char *title, UInt_t width, UInt_t height);
00048    virtual TCanvasImp *CreateCanvasImp(TCanvas *c, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height);
00049 
00050    virtual TBrowserImp *CreateBrowserImp(TBrowser *b, const char *title, UInt_t width, UInt_t height);
00051    virtual TBrowserImp *CreateBrowserImp(TBrowser *b, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height);
00052 
00053    virtual TBrowserImp *CreateBrowserImp(TBrowser *b, const char *title, UInt_t width, UInt_t height, Option_t *opt);
00054    virtual TBrowserImp *CreateBrowserImp(TBrowser *b, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height, Option_t *opt);
00055 
00056    virtual TContextMenuImp *CreateContextMenuImp(TContextMenu *c, const char *name, const char *title);
00057 
00058    virtual TControlBarImp *CreateControlBarImp(TControlBar *c, const char *title);
00059    virtual TControlBarImp *CreateControlBarImp(TControlBar *c, const char *title, Int_t x, Int_t y);
00060 
00061    virtual TInspectorImp *CreateInspectorImp(const TObject *obj, UInt_t width, UInt_t height);
00062 
00063    static TGClient *GetRootClient();
00064    ClassDef(TQtRootGuiFactory,0)  //Factory for Qt-based ROOT GUI components
00065 };
00066 
00067 inline TGClient *TQtRootGuiFactory::GetRootClient(){ return gfQtClient; }
00068 
00069 
00070 #endif

Generated on Tue Jul 5 14:22:21 2011 for ROOT_528-00b_version by  doxygen 1.5.1