Logo ROOT   6.14/05
Reference Guide
TTextEditor.h
Go to the documentation of this file.
1 // Author: Olivier Couet 22/12/2013
2 
3 /*************************************************************************
4  * Copyright (C) 1995-2002, Rene Brun and Fons Rademakers. *
5  * All rights reserved. *
6  * *
7  * For the licensing terms see $ROOTSYS/LICENSE. *
8  * For the list of contributors see $ROOTSYS/README/CREDITS. *
9  *************************************************************************/
10 
11 
12 //////////////////////////////////////////////////////////////////////////
13 // //
14 // TTextEditor //
15 // //
16 // Editor for changing TText's and TLatex's attributes. //
17 // //
18 //////////////////////////////////////////////////////////////////////////
19 
20 #ifndef ROOT_TTextEditor
21 #define ROOT_TTextEditor
22 #include "TGedFrame.h"
23 
24 class TText;
25 class TGTextEntry;
26 class TGNumberEntry;
27 
28 class TTextEditor : public TGedFrame {
29 
30 private:
32 
33 protected:
34  TGTextEntry *fText; // Text
35  TGNumberEntry *fAngle; // Text's angle
36  TGNumberEntry *fSize; // Text's angle
37  TGNumberEntry *fXpos; // Text's X position
38  TGNumberEntry *fYpos; // Text's Y position
39 
40  void ConnectSignals2Slots();
41 
42 public:
43  TTextEditor(const TGWindow *p = 0,
44  Int_t width = 140, Int_t height = 30,
45  UInt_t options = kChildFrame,
47  ~TTextEditor();
48 
49  void SetModel(TObject *);
50 
51  void DoAngle();
52  void DoSize();
53  void DoText(const char*);
54  void DoXpos();
55  void DoYpos();
56 
57  ClassDef(TTextEditor,0) // text editor
58 };
59 
60 #endif // ROOT_TTextEditor
61 
void ConnectSignals2Slots()
Connect signals to slots.
image html pict1_TGaxis_012 png width
Define new text attributes for the label number "labNum".
Definition: TGaxis.cxx:2551
int Int_t
Definition: RtypesCore.h:41
void DoText(const char *)
Slot for setting the text string.
void DoAngle()
Slot for setting the text Angle.
TText * fEditedText
Definition: TTextEditor.h:31
TGNumberEntry * fXpos
Definition: TTextEditor.h:37
#define ClassDef(name, id)
Definition: Rtypes.h:320
ULong_t Pixel_t
Definition: GuiTypes.h:39
static Pixel_t GetDefaultFrameBackground()
Get default frame background.
Definition: TGFrame.cxx:665
void SetModel(TObject *)
Set model.
Definition: TTextEditor.cxx:82
Base class for several text objects.
Definition: TText.h:23
void DoYpos()
Slot for setting the text Y position.
unsigned int UInt_t
Definition: RtypesCore.h:42
void DoXpos()
Slot for setting the text X position.
TTextEditor(const TGWindow *p=0, Int_t width=140, Int_t height=30, UInt_t options=kChildFrame, Pixel_t back=GetDefaultFrameBackground())
TTextEditor constructor.
Definition: TTextEditor.cxx:18
TGNumberEntry * fAngle
Definition: TTextEditor.h:35
~TTextEditor()
TTextEditor destructor.
Definition: TTextEditor.cxx:74
Mother of all ROOT objects.
Definition: TObject.h:37
void DoSize()
Slot for setting the text Size.
TGNumberEntry * fYpos
Definition: TTextEditor.h:38
TGTextEntry * fText
Definition: TTextEditor.h:34
TGNumberEntry * fSize
Definition: TTextEditor.h:36