Logo ROOT   6.08/07
Reference Guide
TGuiFactory.h
Go to the documentation of this file.
1 // @(#)root/base:$Id$
2 // Author: Fons Rademakers 15/11/95
3 
4 /*************************************************************************
5  * Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
6  * All rights reserved. *
7  * *
8  * For the licensing terms see $ROOTSYS/LICENSE. *
9  * For the list of contributors see $ROOTSYS/README/CREDITS. *
10  *************************************************************************/
11 
12 
13 #ifndef ROOT_TGuiFactory
14 #define ROOT_TGuiFactory
15 
16 //////////////////////////////////////////////////////////////////////////
17 // //
18 // TGuiFactory //
19 // //
20 // This ABC is a factory for GUI components. Depending on which //
21 // factory is active one gets either ROOT native (X11 based with Win95 //
22 // look and feel), Win32 or Mac components. //
23 // In case there is no platform dependent implementation on can run in //
24 // batch mode directly using an instance of this base class. //
25 // //
26 //////////////////////////////////////////////////////////////////////////
27 
28 #ifndef ROOT_TNamed
29 #include "TNamed.h"
30 #endif
31 
32 class TApplicationImp;
33 class TCanvasImp;
34 class TCanvas;
35 class TBrowserImp;
36 class TBrowser;
37 class TContextMenuImp;
38 class TContextMenu;
39 class TControlBarImp;
40 class TControlBar;
41 class TInspectorImp;
42 
43 
44 class TGuiFactory : public TNamed {
45 
46 public:
47  TGuiFactory(const char *name = "Batch", const char *title = "Batch GUI Factory");
48  virtual ~TGuiFactory() { }
49 
50  virtual TApplicationImp *CreateApplicationImp(const char *classname, int *argc, char **argv);
51 
52  virtual TCanvasImp *CreateCanvasImp(TCanvas *c, const char *title, UInt_t width, UInt_t height);
53  virtual TCanvasImp *CreateCanvasImp(TCanvas *c, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height);
54 
55  virtual TBrowserImp *CreateBrowserImp(TBrowser *b, const char *title, UInt_t width, UInt_t height, Option_t *opt="");
56  virtual TBrowserImp *CreateBrowserImp(TBrowser *b, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height, Option_t *opt="");
57 
58  virtual TContextMenuImp *CreateContextMenuImp(TContextMenu *c, const char *name, const char *title);
59 
60  virtual TControlBarImp *CreateControlBarImp(TControlBar *c, const char *title);
61  virtual TControlBarImp *CreateControlBarImp(TControlBar *c, const char *title, Int_t x, Int_t y);
62 
63  virtual TInspectorImp *CreateInspectorImp(const TObject *obj, UInt_t width, UInt_t height);
64 
65  ClassDef(TGuiFactory,0) //Abstract factory for GUI components
66 };
67 
70 
71 #endif
virtual TBrowserImp * CreateBrowserImp(TBrowser *b, const char *title, UInt_t width, UInt_t height, Option_t *opt="")
Create a batch version of TBrowserImp.
Definition: TGuiFactory.cxx:72
R__EXTERN TGuiFactory * gBatchGuiFactory
Definition: TGuiFactory.h:69
virtual ~TGuiFactory()
Definition: TGuiFactory.h:48
A Control Bar is a fully user configurable tool which provides fast access to frequently used operati...
Definition: TControlBar.h:26
ABC describing GUI independent main window (with menubar, scrollbars and a drawing area)...
Definition: TCanvasImp.h:32
This class provides an interface to GUI independent context sensitive popup menus.
return c
const char Option_t
Definition: RtypesCore.h:62
ABC describing GUI independent control bar.
int Int_t
Definition: RtypesCore.h:41
virtual TContextMenuImp * CreateContextMenuImp(TContextMenu *c, const char *name, const char *title)
Create a batch version of TContextMenuImp.
Definition: TGuiFactory.cxx:88
ABC describing GUI independent application implementation protocol.
Double_t x[n]
Definition: legend1.C:17
#define ClassDef(name, id)
Definition: Rtypes.h:254
virtual TApplicationImp * CreateApplicationImp(const char *classname, int *argc, char **argv)
Create a batch version of TApplicationImp.
Definition: TGuiFactory.cxx:48
The TNamed class is the base class for all named ROOT classes.
Definition: TNamed.h:33
R__EXTERN TGuiFactory * gGuiFactory
Definition: TGuiFactory.h:68
Using a TBrowser one can browse all ROOT objects.
Definition: TBrowser.h:41
This class provides an interface to context sensitive popup menus.
Definition: TContextMenu.h:44
unsigned int UInt_t
Definition: RtypesCore.h:42
virtual TInspectorImp * CreateInspectorImp(const TObject *obj, UInt_t width, UInt_t height)
Create a batch version of TInspectorImp.
TGuiFactory(const char *name="Batch", const char *title="Batch GUI Factory")
TGuiFactory ctor only called by derived classes.
Definition: TGuiFactory.cxx:40
The Canvas class.
Definition: TCanvas.h:41
Double_t y[n]
Definition: legend1.C:17
virtual TCanvasImp * CreateCanvasImp(TCanvas *c, const char *title, UInt_t width, UInt_t height)
Create a batch version of TCanvasImp.
Definition: TGuiFactory.cxx:56
Mother of all ROOT objects.
Definition: TObject.h:37
This ABC is a factory for GUI components.
Definition: TGuiFactory.h:44
#define R__EXTERN
Definition: DllImport.h:27
you should not use this method at all Int_t Int_t Double_t Double_t Double_t Int_t Double_t Double_t Double_t Double_t b
Definition: TRolke.cxx:630
ABC describing GUI independent object inspector (abstraction mainly needed for Win32.
Definition: TInspectorImp.h:32
virtual TControlBarImp * CreateControlBarImp(TControlBar *c, const char *title)
Create a batch version of TControlBarImp.
Definition: TGuiFactory.cxx:96
char name[80]
Definition: TGX11.cxx:109
ABC describing GUI independent browser implementation protocol.
Definition: TBrowserImp.h:31