TGTextButton


class description - source file - inheritance tree

class TGTextButton : public TGButton


    protected:
virtual void DoRedraw() void Init() public:
TGTextButton TGTextButton(TGWindow* p, TGHotString* s, Int_t id = -1, GContext_t norm = fgDefaultGC, FontStruct_t font = fgDefaultFontStruct, UInt_t option = kRaisedFrame|kDoubleBorder) TGTextButton TGTextButton(TGWindow* p, char* s, Int_t id = -1, GContext_t norm = fgDefaultGC, FontStruct_t font = fgDefaultFontStruct, UInt_t option = kRaisedFrame|kDoubleBorder) TGTextButton TGTextButton(TGWindow* p, char* s, char* cmd, Int_t id = -1, GContext_t norm = fgDefaultGC, FontStruct_t font = fgDefaultFontStruct, UInt_t option = kRaisedFrame|kDoubleBorder) TGTextButton TGTextButton(TGTextButton&) virtual void ~TGTextButton() TClass* Class() virtual TGDimension GetDefaultSize() const TGHotString* GetText() virtual Bool_t HandleKey(Event_t* event) virtual TClass* IsA() void SetText(TGHotString* new_label) void SetTextJustify(Int_t tmode) virtual void ShowMembers(TMemberInspector& insp, char* parent) virtual void Streamer(TBuffer& b)

Data Members

protected:
TGHotString* fLabel button text Int_t fTMode text drawing mode (ETextJustification) Int_t fHKeycode hotkey FontStruct_t fFontStruct font to draw text static FontStruct_t fgDefaultFontStruct

Class Description

                                                                      
 TGButton, TGTextButton, TGPictureButton, TGCheckButton and           
 TGRadioButton                                                        
                                                                      
 This header defines all GUI button widgets.                          
                                                                      
 TGButton is a button abstract base class. It defines general button  
 behaviour.                                                           
                                                                      
 Selecting a text or picture button will generate the event:          
 kC_COMMAND, kCM_BUTTON, button id, user data.                        
                                                                      
 Selecting a check button will generate the event:                    
 kC_COMMAND, kCM_CHECKBUTTON, button id, user data.                   
                                                                      
 Selecting a radio button will generate the event:                    
 kC_COMMAND, kCM_RADIOBUTTON, button id, user data.                   
                                                                      
 If a command string has been specified (via SetCommand()) then this  
 command string will be executed via the interpreter whenever a       
 button is selected. A command string can contain the macros:         
 $MSG   -- kC_COMMAND, kCM[CHECK|RADIO]BUTTON packed message          
           (use GET_MSG() and GET_SUBMSG() to unpack)                 
 $PARM1 -- button id                                                  
 $PARM2 -- user data pointer                                          
 Before executing these macros are expanded into the respective       
 Long_t's                                                             
                                                                      


TGTextButton(const TGWindow *p, TGHotString *s, Int_t id, GContext_t norm, FontStruct_t font, UInt_t options) : TGButton(p, id, norm, options)
 Create a text button widget. The hotstring will be adopted and deleted
 by the text button.

TGTextButton(const TGWindow *p, const char *s, Int_t id, GContext_t norm, FontStruct_t font, UInt_t options) : TGButton(p, id, norm, options)
 Create a text button widget.

TGTextButton(const TGWindow *p, const char *s, const char *cmd, Int_t id, GContext_t norm, FontStruct_t font, UInt_t options) : TGButton(p, id, norm, options)
 Create a text button widget and set cmd string at same time.

void Init()
 Common initialization used by the different ctors.

~TGTextButton()
 Delete a text button widget.

void SetText(TGHotString *new_label)
 Set new button text.

void DoRedraw()
 Draw the text button.

Bool_t HandleKey(Event_t *event)
 Handle key event. This function will be called when the hotkey is hit.



Inline Functions


               TGDimension GetDefaultSize()
        const TGHotString* GetText()
                      void SetTextJustify(Int_t tmode)
                   TClass* Class()
                   TClass* IsA()
                      void ShowMembers(TMemberInspector& insp, char* parent)
                      void Streamer(TBuffer& b)
              TGTextButton TGTextButton(TGTextButton&)


Author: Fons Rademakers 06/01/98
Last update: 2.22/07 29/06/99 13.53.54 by Fons Rademakers
Copyright (c) 1995-1999, The ROOT System, All rights reserved. *


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.