TGLAnnotation Class Reference

#include <TGLAnnotation.h>

Inheritance diagram for TGLAnnotation:

TGLOverlayElement TGLOverlayElement List of all members.

Public Member Functions

 TGLAnnotation (TGLViewerBase *parent, const char *text, Float_t posx, Float_t posy)
 TGLAnnotation (TGLViewerBase *parent, const char *text, Float_t posx, Float_t posy, TGLVector3 ref)
virtual ~TGLAnnotation ()
void SetText (const TString &x)
const TStringGetText () const
void SetTransparency (Char_t x)
Char_t GetTransparency () const
void SetUseColorSet (Bool_t x)
Bool_t GetUseColorSet () const
void SetBackColor (Color_t x)
Color_t GetBackColor () const
void SetTextColor (Color_t x)
Color_t GetTextColor () const
void SetTextSize (Float_t x)
Float_t GetTextSize () const
void SetAllowClose (Bool_t x)
Bool_t GetAllowClose () const
TGLFont::ETextAlignH_e GetTextAlign () const
void SetTextAlign (TGLFont::ETextAlignH_e a)
virtual Bool_t MouseEnter (TGLOvlSelectRecord &selRec)
virtual Bool_t Handle (TGLRnrCtx &rnrCtx, TGLOvlSelectRecord &selRec, Event_t *event)
virtual void MouseLeave ()
void CloseEditor ()
void UpdateText ()
virtual void Render (TGLRnrCtx &rnrCtx)
 ClassDef (TGLAnnotation, 0)
 TGLAnnotation (TGLViewerBase *parent, const char *text, Float_t posx, Float_t posy)
 TGLAnnotation (TGLViewerBase *parent, const char *text, Float_t posx, Float_t posy, TGLVector3 ref)
virtual ~TGLAnnotation ()
void SetText (const TString &x)
const TStringGetText () const
void SetTransparency (Char_t x)
Char_t GetTransparency () const
void SetUseColorSet (Bool_t x)
Bool_t GetUseColorSet () const
void SetBackColor (Color_t x)
Color_t GetBackColor () const
void SetTextColor (Color_t x)
Color_t GetTextColor () const
void SetTextSize (Float_t x)
Float_t GetTextSize () const
void SetAllowClose (Bool_t x)
Bool_t GetAllowClose () const
TGLFont::ETextAlignH_e GetTextAlign () const
void SetTextAlign (TGLFont::ETextAlignH_e a)
virtual Bool_t MouseEnter (TGLOvlSelectRecord &selRec)
virtual Bool_t Handle (TGLRnrCtx &rnrCtx, TGLOvlSelectRecord &selRec, Event_t *event)
virtual void MouseLeave ()
void CloseEditor ()
void UpdateText ()
virtual void Render (TGLRnrCtx &rnrCtx)
 ClassDef (TGLAnnotation, 0)

Protected Types

enum  EDrag
enum  ENameStack
enum  EDrag
enum  ENameStack

Protected Member Functions

void MakeEditor ()
Char_t GetLineTransparency () const
void MakeEditor ()
Char_t GetLineTransparency () const

Protected Attributes

Float_t fPosX
Float_t fPosY
Float_t fWidth
Float_t fHeight
Int_t fMouseX
Int_t fMouseY
EDrag fDrag
 last mouse position
Float_t fDrawW
Float_t fDrawH
Float_t fTextSizeDrag
 width and height when drawing
TGLVector3 fPointer
 text-size at start of drag
Bool_t fActive
TGMainFramefMainFrame
TGTextEditfTextEdit
TGLViewerfParent
TString fText
Float_t fTextSize
TGLFont fFont
TGLFont fMenuFont
TGLFont::ETextAlignH_e fTextAlign
Color_t fBackColor
Color_t fTextColor
Char_t fTransparency
Bool_t fDrawRefLine
Bool_t fUseColorSet
Bool_t fAllowClose
TGMainFramefMainFrame
TGTextEditfTextEdit
TGLViewerfParent

Static Protected Attributes

static Color_t fgBackColor
static Color_t fgTextColor

Private Member Functions

 TGLAnnotation (const TGLAnnotation &)
TGLAnnotationoperator= (const TGLAnnotation &)
 TGLAnnotation (const TGLAnnotation &)
TGLAnnotationoperator= (const TGLAnnotation &)

Detailed Description

Definition at line 25 of file TGLAnnotation.h.


Member Enumeration Documentation

enum TGLAnnotation::EDrag [protected]

Definition at line 32 of file TGLAnnotation.h.

enum TGLAnnotation::ENameStack [protected]

Definition at line 33 of file TGLAnnotation.h.

enum TGLAnnotation::EDrag [protected]

Definition at line 32 of file TGLAnnotation.h.

enum TGLAnnotation::ENameStack [protected]

Definition at line 33 of file TGLAnnotation.h.


Constructor & Destructor Documentation

TGLAnnotation::TGLAnnotation ( const TGLAnnotation  )  [private]

TGLAnnotation::TGLAnnotation ( TGLViewerBase parent,
const char *  text,
Float_t  posx,
Float_t  posy 
)

Definition at line 45 of file TGLAnnotation.cxx.

References TGLViewerBase::AddOverlayElement(), and fParent.

TGLAnnotation::TGLAnnotation ( TGLViewerBase parent,
const char *  text,
Float_t  posx,
Float_t  posy,
TGLVector3  ref 
)

Definition at line 75 of file TGLAnnotation.cxx.

References TGLViewerBase::AddOverlayElement(), fParent, and fPointer.

TGLAnnotation::~TGLAnnotation (  )  [virtual]

Definition at line 105 of file TGLAnnotation.cxx.

References fMainFrame, fParent, and TGLViewer::RemoveOverlayElement().

TGLAnnotation::TGLAnnotation ( const TGLAnnotation  )  [private]

TGLAnnotation::TGLAnnotation ( TGLViewerBase parent,
const char *  text,
Float_t  posx,
Float_t  posy 
)

TGLAnnotation::TGLAnnotation ( TGLViewerBase parent,
const char *  text,
Float_t  posx,
Float_t  posy,
TGLVector3  ref 
)

virtual TGLAnnotation::~TGLAnnotation (  )  [virtual]


Member Function Documentation

TGLAnnotation& TGLAnnotation::operator= ( const TGLAnnotation  )  [private]

void TGLAnnotation::MakeEditor (  )  [protected]

Definition at line 485 of file TGLAnnotation.cxx.

References TGCompositeFrame::AddFrame(), TQObject::Connect(), TString::Data(), fMainFrame, fText, fTextEdit, gClient, TGClient::GetRoot(), h, kDeepCleanup, kLHintsBottom, kLHintsExpandX, kLHintsExpandY, kLHintsRight, kSunkenFrame, TGCompositeFrame::Layout(), TGText::LoadBuffer(), TGCompositeFrame::MapSubwindows(), TGFrame::MapWindow(), TMath::Max(), TGFrame::Resize(), TGTextEdit::ReturnLongestLineWidth(), TGText::RowCount(), TGCompositeFrame::SetCleanup(), TGTextView::SetText(), TGMainFrame::SetWindowName(), and w.

Referenced by Handle().

Char_t TGLAnnotation::GetLineTransparency (  )  const [protected]

Definition at line 473 of file TGLAnnotation.cxx.

References fActive, fTransparency, and TMath::Min().

Referenced by Render().

void TGLAnnotation::SetText ( const TString x  )  [inline]

Definition at line 78 of file TGLAnnotation.h.

References fText, and x.

Referenced by MyTimer::Notify().

const TString& TGLAnnotation::GetText (  )  const [inline]

Definition at line 79 of file TGLAnnotation.h.

References fText.

void TGLAnnotation::SetTransparency ( Char_t  x  )  [inline]

Definition at line 81 of file TGLAnnotation.h.

References fTransparency.

Char_t TGLAnnotation::GetTransparency (  )  const [inline]

Definition at line 82 of file TGLAnnotation.h.

References fTransparency.

void TGLAnnotation::SetUseColorSet ( Bool_t  x  )  [inline]

Definition at line 84 of file TGLAnnotation.h.

References fUseColorSet.

Bool_t TGLAnnotation::GetUseColorSet (  )  const [inline]

Definition at line 85 of file TGLAnnotation.h.

References fUseColorSet.

void TGLAnnotation::SetBackColor ( Color_t  x  )  [inline]

Definition at line 87 of file TGLAnnotation.h.

References fBackColor.

Color_t TGLAnnotation::GetBackColor (  )  const [inline]

Definition at line 88 of file TGLAnnotation.h.

References fBackColor.

void TGLAnnotation::SetTextColor ( Color_t  x  )  [inline]

Definition at line 90 of file TGLAnnotation.h.

References fTextColor.

Color_t TGLAnnotation::GetTextColor (  )  const [inline]

Definition at line 91 of file TGLAnnotation.h.

References fTextColor.

void TGLAnnotation::SetTextSize ( Float_t  x  )  [inline]

Definition at line 93 of file TGLAnnotation.h.

References fTextSize.

Referenced by annotation().

Float_t TGLAnnotation::GetTextSize (  )  const [inline]

Definition at line 94 of file TGLAnnotation.h.

References fTextSize.

void TGLAnnotation::SetAllowClose ( Bool_t  x  )  [inline]

Definition at line 96 of file TGLAnnotation.h.

References fAllowClose.

Bool_t TGLAnnotation::GetAllowClose (  )  const [inline]

Definition at line 97 of file TGLAnnotation.h.

References fAllowClose.

TGLFont::ETextAlignH_e TGLAnnotation::GetTextAlign (  )  const [inline]

Definition at line 99 of file TGLAnnotation.h.

References fTextAlign.

void TGLAnnotation::SetTextAlign ( TGLFont::ETextAlignH_e  a  )  [inline]

Definition at line 100 of file TGLAnnotation.h.

References fTextAlign.

Bool_t TGLAnnotation::MouseEnter ( TGLOvlSelectRecord selRec  )  [virtual]

Reimplemented from TGLOverlayElement.

Definition at line 192 of file TGLAnnotation.cxx.

References fActive, and kTRUE.

Bool_t TGLAnnotation::Handle ( TGLRnrCtx rnrCtx,
TGLOvlSelectRecord selRec,
Event_t event 
) [virtual]

Reimplemented from TGLOverlayElement.

Definition at line 114 of file TGLAnnotation.cxx.

References fDrag, fDrawH, fDrawW, fMouseX, fMouseY, fParent, fPosX, fPosY, fTextSize, fTextSizeDrag, Event_t::fType, Event_t::fX, Event_t::fY, TGLSelectRecordBase::GetItem(), TGLSelectRecordBase::GetN(), kButtonPress, kButtonRelease, kDeleteID, kEditID, kFALSE, kMotionNotify, kMove, kNone, kResize, kResizeID, kTRUE, MakeEditor(), Max, TMath::Min(), TGLRnrCtx::RefCamera(), TGLCamera::RefViewport(), TGLRnrCtx::ViewerLOD(), and vp.

void TGLAnnotation::MouseLeave (  )  [virtual]

Reimplemented from TGLOverlayElement.

Definition at line 201 of file TGLAnnotation.cxx.

References fActive, and kFALSE.

void TGLAnnotation::CloseEditor (  ) 

Definition at line 531 of file TGLAnnotation.cxx.

References fMainFrame, and TGFrame::UnmapWindow().

void TGLAnnotation::UpdateText (  ) 

Definition at line 539 of file TGLAnnotation.cxx.

References TGText::AsString(), fMainFrame, fParent, fText, fTextEdit, TGTextView::GetText(), TGLViewer::RequestDraw(), and TGFrame::UnmapWindow().

void TGLAnnotation::Render ( TGLRnrCtx rnrCtx  )  [virtual]

Implements TGLOverlayElement.

Definition at line 209 of file TGLAnnotation.cxx.

References TGLColorSet::Background(), TGLFont::BBox(), c1, TGLUtil::Color(), TGLRnrCtx::ColorSet(), TGLUtil::ColorTransparency(), TString::Data(), f2, fActive, fAllowClose, fBackColor, fDrawH, fDrawRefLine, fDrawW, fFont, fPointer, fPosX, fPosY, fText, fTextAlign, fTextColor, fTextSize, fTransparency, fUseColorSet, TColor::GetBlue(), TROOT::GetColor(), TColor::GetColor(), TGLColor::GetColorIndex(), TGLFont::GetDescent(), TGLFontManager::GetFontSize(), TColor::GetGreen(), TGLFont::GetLineHeight(), GetLineTransparency(), TColor::GetRed(), TObjString::GetString(), GL_BLEND, GL_CULL_FACE, GL_DEPTH_RANGE, GL_ENABLE_BIT, GL_FILL, GL_FRONT_AND_BACK, GL_LIGHTING, GL_LINE_BIT, GL_LINE_LOOP, GL_LINES, GL_ONE_MINUS_SRC_ALPHA, GL_POLYGON_BIT, GL_POLYGON_OFFSET_FILL, GL_QUADS, GL_SRC_ALPHA, glBegin(), glBlendFunc(), glDepthRange(), glDisable(), glEnable(), glEnd(), glGetFloatv(), glLoadIdentity(), glLoadName(), glPolygonMode(), glPolygonOffset(), glPopAttrib(), glPopMatrix(), glPopName(), glPushAttrib(), glPushMatrix(), glPushName(), glScalef(), glTranslatef(), glVertex3f(), gROOT, TGLFont::kCenterH, kDeleteID, kEditID, kFALSE, TGLFont::kLeft, kMoveID, kResizeID, TGLFont::kTexture, TGLFont::kTop, TGLUtil::LineWidth(), TGLColorSet::Markup(), TMath::Max(), TMath::Nint(), TGLFont::PostRender(), TGLFont::PreRender(), TGLRnrCtx::ProjectionMatrixPop(), TGLRnrCtx::ProjectionMatrixPushIdentity(), TGLRnrCtx::RefCamera(), TGLCamera::RefViewport(), TGLRnrCtx::RegisterFontNoScale(), TGLFont::Render(), TIter::Reset(), sx, TString::Tokenize(), vp, TGLCamera::WorldToViewport(), x1, and x2.

TGLAnnotation::ClassDef ( TGLAnnotation  ,
 
)

TGLAnnotation& TGLAnnotation::operator= ( const TGLAnnotation  )  [private]

void TGLAnnotation::MakeEditor (  )  [protected]

Char_t TGLAnnotation::GetLineTransparency (  )  const [protected]

void TGLAnnotation::SetText ( const TString x  )  [inline]

Definition at line 78 of file TGLAnnotation.h.

References fText, and x.

const TString& TGLAnnotation::GetText (  )  const [inline]

Definition at line 79 of file TGLAnnotation.h.

References fText.

void TGLAnnotation::SetTransparency ( Char_t  x  )  [inline]

Definition at line 81 of file TGLAnnotation.h.

References fTransparency.

Char_t TGLAnnotation::GetTransparency (  )  const [inline]

Definition at line 82 of file TGLAnnotation.h.

References fTransparency.

void TGLAnnotation::SetUseColorSet ( Bool_t  x  )  [inline]

Definition at line 84 of file TGLAnnotation.h.

References fUseColorSet.

Bool_t TGLAnnotation::GetUseColorSet (  )  const [inline]

Definition at line 85 of file TGLAnnotation.h.

References fUseColorSet.

void TGLAnnotation::SetBackColor ( Color_t  x  )  [inline]

Definition at line 87 of file TGLAnnotation.h.

References fBackColor.

Color_t TGLAnnotation::GetBackColor (  )  const [inline]

Definition at line 88 of file TGLAnnotation.h.

References fBackColor.

void TGLAnnotation::SetTextColor ( Color_t  x  )  [inline]

Definition at line 90 of file TGLAnnotation.h.

References fTextColor.

Color_t TGLAnnotation::GetTextColor (  )  const [inline]

Definition at line 91 of file TGLAnnotation.h.

References fTextColor.

void TGLAnnotation::SetTextSize ( Float_t  x  )  [inline]

Definition at line 93 of file TGLAnnotation.h.

References fTextSize.

Float_t TGLAnnotation::GetTextSize (  )  const [inline]

Definition at line 94 of file TGLAnnotation.h.

References fTextSize.

void TGLAnnotation::SetAllowClose ( Bool_t  x  )  [inline]

Definition at line 96 of file TGLAnnotation.h.

References fAllowClose.

Bool_t TGLAnnotation::GetAllowClose (  )  const [inline]

Definition at line 97 of file TGLAnnotation.h.

References fAllowClose.

TGLFont::ETextAlignH_e TGLAnnotation::GetTextAlign (  )  const [inline]

Definition at line 99 of file TGLAnnotation.h.

References fTextAlign.

void TGLAnnotation::SetTextAlign ( TGLFont::ETextAlignH_e  a  )  [inline]

Definition at line 100 of file TGLAnnotation.h.

References fTextAlign.

virtual Bool_t TGLAnnotation::MouseEnter ( TGLOvlSelectRecord selRec  )  [virtual]

Reimplemented from TGLOverlayElement.

virtual Bool_t TGLAnnotation::Handle ( TGLRnrCtx rnrCtx,
TGLOvlSelectRecord selRec,
Event_t event 
) [virtual]

Reimplemented from TGLOverlayElement.

virtual void TGLAnnotation::MouseLeave (  )  [virtual]

Reimplemented from TGLOverlayElement.

void TGLAnnotation::CloseEditor (  ) 

void TGLAnnotation::UpdateText (  ) 

virtual void TGLAnnotation::Render ( TGLRnrCtx rnrCtx  )  [virtual]

Implements TGLOverlayElement.

TGLAnnotation::ClassDef ( TGLAnnotation  ,
 
)


Member Data Documentation

Float_t TGLAnnotation::fPosX [protected]

Definition at line 38 of file TGLAnnotation.h.

Referenced by Handle(), and Render().

Float_t TGLAnnotation::fPosY [protected]

Definition at line 39 of file TGLAnnotation.h.

Referenced by Handle(), and Render().

Float_t TGLAnnotation::fWidth [protected]

Definition at line 40 of file TGLAnnotation.h.

Float_t TGLAnnotation::fHeight [protected]

Definition at line 41 of file TGLAnnotation.h.

Int_t TGLAnnotation::fMouseX [protected]

Definition at line 43 of file TGLAnnotation.h.

Referenced by Handle().

Int_t TGLAnnotation::fMouseY [protected]

Definition at line 43 of file TGLAnnotation.h.

Referenced by Handle().

EDrag TGLAnnotation::fDrag [protected]

last mouse position

Definition at line 44 of file TGLAnnotation.h.

Referenced by Handle().

Float_t TGLAnnotation::fDrawW [protected]

Definition at line 45 of file TGLAnnotation.h.

Referenced by Handle(), and Render().

Float_t TGLAnnotation::fDrawH [protected]

Definition at line 45 of file TGLAnnotation.h.

Referenced by Handle(), and Render().

Float_t TGLAnnotation::fTextSizeDrag [protected]

width and height when drawing

Definition at line 46 of file TGLAnnotation.h.

Referenced by Handle().

TGLVector3 TGLAnnotation::fPointer [protected]

text-size at start of drag

Definition at line 48 of file TGLAnnotation.h.

Referenced by Render(), and TGLAnnotation().

Bool_t TGLAnnotation::fActive [protected]

Definition at line 49 of file TGLAnnotation.h.

Referenced by GetLineTransparency(), MouseEnter(), MouseLeave(), and Render().

TGMainFrame* TGLAnnotation::fMainFrame [protected]

Definition at line 51 of file TGLAnnotation.h.

Referenced by CloseEditor(), MakeEditor(), UpdateText(), and ~TGLAnnotation().

TGTextEdit* TGLAnnotation::fTextEdit [protected]

Definition at line 52 of file TGLAnnotation.h.

Referenced by MakeEditor(), and UpdateText().

static Color_t TGLAnnotation::fgBackColor [static, protected]

Definition at line 54 of file TGLAnnotation.h.

static Color_t TGLAnnotation::fgTextColor [static, protected]

Definition at line 55 of file TGLAnnotation.h.

TGLViewer* TGLAnnotation::fParent [protected]

Definition at line 57 of file TGLAnnotation.h.

Referenced by Handle(), TGLAnnotation(), UpdateText(), and ~TGLAnnotation().

TString TGLAnnotation::fText [protected]

Definition at line 59 of file TGLAnnotation.h.

Referenced by GetText(), MakeEditor(), Render(), SetText(), and UpdateText().

Float_t TGLAnnotation::fTextSize [protected]

Definition at line 60 of file TGLAnnotation.h.

Referenced by GetTextSize(), Handle(), Render(), and SetTextSize().

TGLFont TGLAnnotation::fFont [protected]

Definition at line 61 of file TGLAnnotation.h.

Referenced by Render().

TGLFont TGLAnnotation::fMenuFont [protected]

Definition at line 62 of file TGLAnnotation.h.

TGLFont::ETextAlignH_e TGLAnnotation::fTextAlign [protected]

Definition at line 63 of file TGLAnnotation.h.

Referenced by GetTextAlign(), Render(), and SetTextAlign().

Color_t TGLAnnotation::fBackColor [protected]

Definition at line 65 of file TGLAnnotation.h.

Referenced by GetBackColor(), Render(), and SetBackColor().

Color_t TGLAnnotation::fTextColor [protected]

Definition at line 66 of file TGLAnnotation.h.

Referenced by GetTextColor(), Render(), and SetTextColor().

Char_t TGLAnnotation::fTransparency [protected]

Definition at line 67 of file TGLAnnotation.h.

Referenced by GetLineTransparency(), GetTransparency(), Render(), and SetTransparency().

Bool_t TGLAnnotation::fDrawRefLine [protected]

Definition at line 69 of file TGLAnnotation.h.

Referenced by Render().

Bool_t TGLAnnotation::fUseColorSet [protected]

Definition at line 70 of file TGLAnnotation.h.

Referenced by GetUseColorSet(), Render(), and SetUseColorSet().

Bool_t TGLAnnotation::fAllowClose [protected]

Definition at line 71 of file TGLAnnotation.h.

Referenced by GetAllowClose(), Render(), and SetAllowClose().

TGMainFrame* TGLAnnotation::fMainFrame [protected]

Definition at line 51 of file TGLAnnotation.h.

TGTextEdit* TGLAnnotation::fTextEdit [protected]

Definition at line 52 of file TGLAnnotation.h.

TGLViewer* TGLAnnotation::fParent [protected]

Definition at line 57 of file TGLAnnotation.h.


The documentation for this class was generated from the following files:
Generated on Tue Jul 5 16:39:56 2011 for ROOT_528-00b_version by  doxygen 1.5.1