ROOT
6.06/08
Reference Guide
graf2d
gpad
inc
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
16
////////////////////////////////////////////////////////////////////////////////
17
// //
18
// TControlBarButton //
19
// //
20
// This class defines the control bar buttons. //
21
// //
22
// //
23
// //
24
////////////////////////////////////////////////////////////////////////////////
25
26
#ifndef ROOT_Rtypes
27
#include "
Rtypes.h
"
28
#endif
29
30
#ifndef ROOT_TNamed
31
#include "
TNamed.h
"
32
#endif
33
34
35
class
TControlBarButton
:
public
TNamed
{
36
37
protected
:
38
Int_t
fType
;
//button type
39
TString
fAction
;
//action to be executed
40
41
public
:
42
enum
{
kButton
= 1,
kDrawnButton
,
kSeparator
};
43
44
TControlBarButton
();
45
TControlBarButton
(
const
char
*label,
const
char
*
action
=
""
,
const
char
*hint=
""
,
const
char
*
type
=
"button"
);
46
virtual
~TControlBarButton
() { }
47
48
virtual
void
Create
() { }
49
virtual
void
Action
();
50
virtual
const
char
*
GetAction
()
const
{
return
fAction.
Data
(); }
51
virtual
Int_t
GetType
()
const
{
return
fType
; }
52
virtual
void
SetAction
(
const
char
*
action
);
53
virtual
void
SetType
(
const
char
*
type
);
54
virtual
void
SetType
(
Int_t
type);
55
56
ClassDef
(
TControlBarButton
,0)
//The Control bar button
57
};
58
59
#endif
TControlBarButton::GetType
virtual Int_t GetType() const
Definition:
TControlBarButton.h:51
ROOT.action
action
Definition:
ROOT.py:93
Rtypes.h
TControlBarButton::~TControlBarButton
virtual ~TControlBarButton()
Definition:
TControlBarButton.h:46
TControlBarButton::TControlBarButton
TControlBarButton()
Default control bar button ctor.
Definition:
TControlBarButton.cxx:35
TControlBarButton::Create
virtual void Create()
Definition:
TControlBarButton.h:48
TString
Basic string class.
Definition:
TString.h:137
Int_t
int Int_t
Definition:
RtypesCore.h:41
TControlBarButton::SetType
virtual void SetType(const char *type)
Set button type.
Definition:
TControlBarButton.cxx:82
TNamed.h
TControlBarButton::kButton
Definition:
TControlBarButton.h:42
ClassDef
#define ClassDef(name, id)
Definition:
Rtypes.h:254
TNamed
The TNamed class is the base class for all named ROOT classes.
Definition:
TNamed.h:33
TControlBarButton::GetAction
virtual const char * GetAction() const
Definition:
TControlBarButton.h:50
TControlBarButton::fType
Int_t fType
Definition:
TControlBarButton.h:38
TControlBarButton::Action
virtual void Action()
Execute control bar button command.
Definition:
TControlBarButton.cxx:54
TControlBarButton::SetAction
virtual void SetAction(const char *action)
Set action to be executed by this button.
Definition:
TControlBarButton.cxx:67
TControlBarButton::fAction
TString fAction
Definition:
TControlBarButton.h:39
type
int type
Definition:
TGX11.cxx:120
TControlBarButton::kSeparator
Definition:
TControlBarButton.h:42
TControlBarButton
Created by the TControlBar.
Definition:
TControlBarButton.h:35
TControlBarButton::kDrawnButton
Definition:
TControlBarButton.h:42
TString::Data
const char * Data() const
Definition:
TString.h:349