Logo ROOT  
Reference Guide
 
Loading...
Searching...
No Matches
TControlBarButton.h
Go to the documentation of this file.
1// @(#)root/gpad:$Id$
2// Author: Nenad Buncic 20/02/96
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#ifndef ROOT_TControlBarButton
13#define ROOT_TControlBarButton
14
15#include "TNamed.h"
16
17class TControlBarButton : public TNamed {
18
19protected:
20 Int_t fType; ///< button type
21 TString fAction; ///< action to be executed
22
23public:
25
27 TControlBarButton(const char *label, const char *action="", const char *hint="", const char *type="button");
28 ~TControlBarButton() override {}
29
30 virtual void Create() {}
31 virtual void Action();
32 virtual const char *GetAction() const { return fAction.Data(); }
33 virtual Int_t GetType() const { return fType; }
34 virtual void SetAction(const char *action);
35 virtual void SetType(const char *type);
36 virtual void SetType(Int_t type);
37
38 ClassDefOverride(TControlBarButton,0) //The Control bar button
39};
40
41#endif
int Int_t
Definition RtypesCore.h:45
#define ClassDefOverride(name, id)
Definition Rtypes.h:341
Option_t Option_t TPoint TPoint const char GetTextMagnitude GetFillStyle GetLineColor GetLineWidth GetMarkerStyle GetTextAlign GetTextColor GetTextSize void char Point_t Rectangle_t WindowAttributes_t Float_t Float_t Float_t Int_t Int_t UInt_t UInt_t Rectangle_t Int_t Int_t Window_t TString Int_t GCValues_t GetPrimarySelectionOwner GetDisplay GetScreen GetColormap GetNativeEvent const char const char dpyName wid window const char font_name cursor keysym reg const char only_if_exist regb h Point_t winding char text const char depth char const char Int_t count const char ColorStruct_t color const char Pixmap_t Pixmap_t PictureAttributes_t attr const char char ret_data h unsigned char height h Atom_t Int_t ULong_t ULong_t unsigned char prop_list Atom_t Atom_t Atom_t Time_t type
This class defines the control bar buttons.
virtual Int_t GetType() const
virtual const char * GetAction() const
virtual void Create()
virtual void SetType(const char *type)
Set button type.
~TControlBarButton() override
virtual void SetAction(const char *action)
Set action to be executed by this button.
Int_t fType
button type
TControlBarButton()
Default control bar button ctor.
TString fAction
action to be executed
virtual void Action()
Execute control bar button command.
The TNamed class is the base class for all named ROOT classes.
Definition TNamed.h:29
Basic string class.
Definition TString.h:139
const char * Data() const
Definition TString.h:376