// @(#)root/base:$Name: $:$Id: TGuiFactory.cxx,v 1.1.1.1 2000/05/16 17:00:39 rdm Exp $
// Author: Fons Rademakers 15/11/95
/*************************************************************************
* Copyright (C) 1995-2000, Rene Brun and Fons Rademakers. *
* All rights reserved. *
* *
* For the licensing terms see $ROOTSYS/LICENSE. *
* For the list of contributors see $ROOTSYS/README/CREDITS. *
*************************************************************************/
//////////////////////////////////////////////////////////////////////////
// //
// TGuiFactory //
// //
// This ABC is a factory for GUI components. Depending on which //
// factory is active one gets either ROOT native (X11 based with Win95 //
// look and feel), Win32 or Mac components. //
// In case there is no platform dependent implementation on can run in //
// batch mode directly using an instance of this base class. //
// //
//////////////////////////////////////////////////////////////////////////
#include "TGuiFactory.h"
#include "TApplicationImp.h"
#include "TCanvasImp.h"
#include "TBrowserImp.h"
#include "TContextMenuImp.h"
#include "TControlBarImp.h"
#include "TInspectorImp.h"
TGuiFactory *gGuiFactory = 0;
TGuiFactory *gBatchGuiFactory = 0;
ClassImp(TGuiFactory)
//______________________________________________________________________________
TGuiFactory::TGuiFactory(const char *name, const char *title)
: TNamed(name, title)
{
// TGuiFactory ctor only called by derived classes.
}
//______________________________________________________________________________
TApplicationImp *TGuiFactory::CreateApplicationImp(const char *classname, int *argc, char **argv, void *options, Int_t numOptions)
{
// Create a batch version of TApplicationImp.
return new TApplicationImp(classname, argc, argv, options, numOptions);
}
//______________________________________________________________________________
TCanvasImp *TGuiFactory::CreateCanvasImp(TCanvas *c, const char *title, UInt_t width, UInt_t height)
{
// Create a batch version of TCanvasImp.
return new TCanvasImp(c, title, width, height);
}
//______________________________________________________________________________
TCanvasImp *TGuiFactory::CreateCanvasImp(TCanvas *c, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height)
{
// Create a batch version of TCanvasImp.
return new TCanvasImp(c, title, x, y, width, height);
}
//______________________________________________________________________________
TBrowserImp *TGuiFactory::CreateBrowserImp(TBrowser *b, const char *title, UInt_t width, UInt_t height)
{
// Create a batch version of TBrowserImp.
return new TBrowserImp(b, title, width, height);
}
//______________________________________________________________________________
TBrowserImp *TGuiFactory::CreateBrowserImp(TBrowser *b, const char *title, Int_t x, Int_t y, UInt_t width, UInt_t height)
{
// Create a batch version of TBrowserImp.
return new TBrowserImp(b, title, x, y, width, height);
}
//______________________________________________________________________________
TContextMenuImp *TGuiFactory::CreateContextMenuImp(TContextMenu *c, const char *, const char *)
{
// Create a batch version of TContextMenuImp.
return new TContextMenuImp(c);
}
//______________________________________________________________________________
TControlBarImp *TGuiFactory::CreateControlBarImp(TControlBar *c, const char *title)
{
// Create a batch version of TControlBarImp.
return new TControlBarImp(c, title);
}
//______________________________________________________________________________
TControlBarImp *TGuiFactory::CreateControlBarImp(TControlBar *c, const char *title, Int_t x, Int_t y)
{
// Create a batch version of TControlBarImp.
return new TControlBarImp(c, title, x, y);
}
//______________________________________________________________________________
TInspectorImp *TGuiFactory::CreateInspectorImp(const TObject *obj, UInt_t width, UInt_t height)
{
// Create a batch version of TInspectorImp.
return new TInspectorImp(obj, width, height);
}
ROOT page - Class index - Top of the page
This page has been automatically generated. If you have any comments or suggestions about the page layout send a mail to ROOT support, or contact the developers with any questions or problems regarding ROOT.