ROOT
v6-24
Reference Guide
Loading...
Searching...
No Matches
TButton.h
Go to the documentation of this file.
1
// @(#)root/gpad:$Id$
2
// Author: Rene Brun 01/07/96
3
4
/*************************************************************************
5
* Copyright (C) 1995-2021, 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_TButton
13
#define ROOT_TButton
14
15
#include "
TPad.h
"
16
#include "
TAttText.h
"
17
18
class
TButton
:
public
TPad
,
public
TAttText
{
19
20
private
:
21
Bool_t
fFocused
;
///< If cursor is in...
22
Bool_t
fFraming
;
///< True if you want a frame to be painted when pressed
23
24
TButton
(
const
TButton
&) =
delete
;
25
TButton
&
operator=
(
const
TButton
&) =
delete
;
26
27
protected
:
28
TString
fMethod
;
///< Method to be executed by this button
29
30
public
:
31
TButton
();
32
TButton
(
const
char
*title,
const
char
*method,
Double_t
x1
,
Double_t
y1,
Double_t
x2
,
Double_t
y2);
33
virtual
~TButton
();
34
virtual
void
Divide
(
Int_t
nx=1,
Int_t
ny=1,
Float_t
xmargin=0.01,
Float_t
ymargin=0.01,
Int_t
color=0);
35
virtual
void
Draw
(
Option_t
*option=
""
);
36
virtual
void
ExecuteEvent
(
Int_t
event,
Int_t
px,
Int_t
py);
37
virtual
const
char
*
GetMethod
()
const
{
return
fMethod
.
Data
(); }
38
virtual
void
Paint
(
Option_t
*option=
""
);
39
virtual
void
PaintModified
();
40
virtual
void
Range
(
Double_t
x1
,
Double_t
y1,
Double_t
x2
,
Double_t
y2);
41
virtual
void
SavePrimitive
(std::ostream &out,
Option_t
*option =
""
);
42
virtual
void
SetBorderMode
(
Short_t
bordermode) {
fBorderMode
= bordermode; }
43
virtual
void
SetFraming
(
Bool_t
f
=1);
44
virtual
Bool_t
GetFraming
() {
return
fFraming
; };
45
virtual
void
SetGrid
(
Int_t
valuex = 1,
Int_t
valuey = 1);
46
virtual
void
SetLogx
(
Int_t
value = 1);
47
virtual
void
SetLogy
(
Int_t
value = 1);
48
virtual
void
SetMethod
(
const
char
*method) {
fMethod
=method; }
// *MENU*
49
virtual
void
SetName
(
const
char
*
name
) {
fName
=
name
; }
50
virtual
void
x3d
(
Option_t
*option=
""
);
51
52
ClassDef
(
TButton
,0)
//A user interface button.
53
};
54
55
inline
void
TButton::Divide
(
Int_t
,
Int_t
,
Float_t
,
Float_t
,
Int_t
) { }
56
inline
void
TButton::SetGrid
(
Int_t
,
Int_t
) { }
57
inline
void
TButton::SetLogx
(
Int_t
) { }
58
inline
void
TButton::SetLogy
(
Int_t
) { }
59
inline
void
TButton::x3d
(
Option_t
*) { }
60
61
#endif
62
f
#define f(i)
Definition
RSha256.hxx:104
x2
static const double x2[5]
Definition
RooGaussKronrodIntegrator1D.cxx:364
x1
static const double x1[5]
Definition
RooGaussKronrodIntegrator1D.cxx:346
Int_t
int Int_t
Definition
RtypesCore.h:45
Bool_t
bool Bool_t
Definition
RtypesCore.h:63
Short_t
short Short_t
Definition
RtypesCore.h:39
Double_t
double Double_t
Definition
RtypesCore.h:59
Float_t
float Float_t
Definition
RtypesCore.h:57
Option_t
const char Option_t
Definition
RtypesCore.h:66
ClassDef
#define ClassDef(name, id)
Definition
Rtypes.h:325
TAttText.h
name
char name[80]
Definition
TGX11.cxx:110
TPad.h
TAttText
Text Attributes class.
Definition
TAttText.h:18
TButton
A TButton object is a user interface object.
Definition
TButton.h:18
TButton::SetLogx
virtual void SetLogx(Int_t value=1)
Definition
TButton.h:57
TButton::SetLogy
virtual void SetLogy(Int_t value=1)
Definition
TButton.h:58
TButton::SetFraming
virtual void SetFraming(Bool_t f=1)
if framing is set, button will be highlighted
Definition
TButton.cxx:334
TButton::operator=
TButton & operator=(const TButton &)=delete
TButton::SetName
virtual void SetName(const char *name)
Definition
TButton.h:49
TButton::GetFraming
virtual Bool_t GetFraming()
Definition
TButton.h:44
TButton::Range
virtual void Range(Double_t x1, Double_t y1, Double_t x2, Double_t y2)
Set world coordinate system for the pad.
Definition
TButton.cxx:261
TButton::SetMethod
virtual void SetMethod(const char *method)
Definition
TButton.h:48
TButton::Paint
virtual void Paint(Option_t *option="")
Paint this button with its current attributes.
Definition
TButton.cxx:217
TButton::x3d
virtual void x3d(Option_t *option="")
Deprecated: use TPad::GetViewer3D() instead.
Definition
TButton.h:59
TButton::GetMethod
virtual const char * GetMethod() const
Definition
TButton.h:37
TButton::SetGrid
virtual void SetGrid(Int_t valuex=1, Int_t valuey=1)
Definition
TButton.h:56
TButton::TButton
TButton(const TButton &)=delete
TButton::fFraming
Bool_t fFraming
True if you want a frame to be painted when pressed.
Definition
TButton.h:22
TButton::SetBorderMode
virtual void SetBorderMode(Short_t bordermode)
Definition
TButton.h:42
TButton::ExecuteEvent
virtual void ExecuteEvent(Int_t event, Int_t px, Int_t py)
Execute action corresponding to one event.
Definition
TButton.cxx:149
TButton::~TButton
virtual ~TButton()
Button default destructor.
Definition
TButton.cxx:131
TButton::fFocused
Bool_t fFocused
If cursor is in...
Definition
TButton.h:21
TButton::Divide
virtual void Divide(Int_t nx=1, Int_t ny=1, Float_t xmargin=0.01, Float_t ymargin=0.01, Int_t color=0)
Definition
TButton.h:55
TButton::SavePrimitive
virtual void SavePrimitive(std::ostream &out, Option_t *option="")
Save primitive as a C++ statement(s) on output stream out.
Definition
TButton.cxx:269
TButton::PaintModified
virtual void PaintModified()
Paint is modified.
Definition
TButton.cxx:239
TButton::TButton
TButton()
Button default constructor.
Definition
TButton.cxx:96
TButton::fMethod
TString fMethod
Method to be executed by this button.
Definition
TButton.h:28
TPad
The most important graphics class in the ROOT system.
Definition
TPad.h:26
TPad::fName
TString fName
Pad name.
Definition
TPad.h:105
TPad::fBorderMode
Short_t fBorderMode
Bordermode (-1=down, 0 = no border, 1=up)
Definition
TPad.h:94
TString
Basic string class.
Definition
TString.h:136
TString::Data
const char * Data() const
Definition
TString.h:369
bool
int
Draw
th1 Draw()
graf2d
gpad
inc
TButton.h
ROOT v6-24 - Reference Guide Generated on Tue Aug 22 2023 03:06:20 (GVA Time) using Doxygen 1.9.8