Public Member Functions | Private Member Functions | Static Private Member Functions | Private Attributes | Friends

GR_Caret Class Reference

#include <gr_Caret.h>

List of all members.

Public Member Functions

 GR_Caret (GR_Graphics *pG)
 GR_Caret (GR_Graphics *pG, const std::string &sID)
 ~GR_Caret ()
void enable ()
void disable (bool bNoMulti=false)
bool isEnabled () const
void JustErase (UT_sint32 xPoint, UT_sint32 yPoint)
void setBlink (bool bBlink)
 Determines whether Abi is going to blink the caret or not.
void forceDraw (void)
void setCoords (UT_sint32 x, UT_sint32 y, UT_uint32 h, UT_sint32 x2=0, UT_sint32 y2=0, UT_uint32 h2=0, bool bPointDirection=false, const UT_RGBColor *pClr=NULL)
void setWindowSize (UT_uint32 width, UT_uint32 height)
bool getInsertMode ()
void setInsertMode (bool mode)
std::string getID (void) const
void setRemoteColor (UT_RGBColor clrRemote)
void resetBlinkTimeout (void)
void setPendingBlink (void)
bool doBlinkIfNeeded (void)

Private Member Functions

 GR_Caret ()
 GR_Caret (const GR_Caret &rhs)
void operator= (const GR_Caret &rhs)
UT_uint32 _getCursorBlinkTime () const
UT_uint32 _getCursorBlinkTimeout () const
bool _getCanCursorBlink () const
void _erase ()
void _blink (bool bExplicit)

Static Private Member Functions

static void s_work (UT_Worker *w)
static void s_enable (UT_Worker *w)
 One-time enabler.
static void s_blink_timeout (UT_Worker *w)

Private Attributes

UT_sint32 m_xPoint
UT_sint32 m_yPoint
UT_uint32 m_iPointHeight
UT_sint32 m_xPoint2
UT_sint32 m_yPoint2
UT_uint32 m_iPointHeight2
bool m_bPointDirection
const UT_RGBColorm_pClr
UT_uint32 m_iWindowWidth
UT_uint32 m_iWindowHeight
UT_uint32 m_nDisableCount
bool m_bCursorBlink
bool m_bCursorIsOn
bool m_bPositionSet
bool m_bRecursiveDraw
bool m_bSplitCaret
bool m_bCaret1OnScreen
bool m_bCaret2OnScreen
UT_RGBColor m_clrInsert
UT_RGBColor m_clrOverwrite
bool m_insertMode
bool m_bRemote
UT_RGBColor m_clrRemote
std::string m_sID
UT_sint32 m_iCaretNumber
long m_iLastDrawTime
UT_sint32 m_iRetry
bool m_bPendingBlink


class GR_Graphics

Constructor & Destructor Documentation

GR_Caret::GR_Caret ( GR_Graphics pG  )  [explicit]
GR_Caret::GR_Caret ( GR_Graphics pG,
const std::string &  sID 
) [explicit]
GR_Caret::~GR_Caret (  ) 
GR_Caret::GR_Caret (  )  [private]
GR_Caret::GR_Caret ( const GR_Caret rhs  )  [private]

Member Function Documentation

void GR_Caret::_blink ( bool  bExplicit  )  [private]
void GR_Caret::_erase (  )  [private]

References _blink(), and m_bCursorIsOn.

Referenced by disable().

bool GR_Caret::_getCanCursorBlink (  )  const [private]

References m_bCursorBlink.

Referenced by _blink().

UT_uint32 GR_Caret::_getCursorBlinkTime (  )  const [private]

Referenced by _blink(), and GR_Caret().

UT_uint32 GR_Caret::_getCursorBlinkTimeout (  )  const [private]

Referenced by GR_Caret().

void GR_Caret::disable ( bool  bNoMulti = false  ) 
bool GR_Caret::doBlinkIfNeeded ( void   ) 

References _blink(), and m_bPendingBlink.

void GR_Caret::enable (  ) 
void GR_Caret::forceDraw ( void   ) 

Only call this is you are absolutely certain you need it!

References _blink(), and m_nDisableCount.

Referenced by Defun1(), AllCarets::doBlinkIfNeeded(), AllCarets::forceDraw(), sActualMoveLeft(), and sActualMoveRight().

std::string GR_Caret::getID ( void   )  const [inline]
bool GR_Caret::getInsertMode (  )  [inline]
bool GR_Caret::isEnabled (  )  const [inline]

Referenced by resetBlinkTimeout().

void GR_Caret::JustErase ( UT_sint32  xPoint,
UT_sint32  yPoint 

Erase the current caret if it's Position overlaps calling value. This prevents remote carets saving a drawn caret in the saveRectange() call

References m_bCursorIsOn, m_bRecursiveDraw, m_bSplitCaret, m_iCaretNumber, m_nDisableCount, m_pG, m_xPoint, m_yPoint, GR_Graphics::restoreRectangle(), GR_Graphics::tlu(), and xxx_UT_DEBUGMSG.

Referenced by AllCarets::JustErase().

void GR_Caret::operator= ( const GR_Caret rhs  )  [private]
void GR_Caret::resetBlinkTimeout ( void   ) 
void GR_Caret::s_blink_timeout ( UT_Worker w  )  [static, private]

Referenced by GR_Caret().

void GR_Caret::s_enable ( UT_Worker _w  )  [static, private]
void GR_Caret::s_work ( UT_Worker w  )  [static, private]
void GR_Caret::setBlink ( bool  bBlink  ) 

Determines whether Abi is going to blink the caret or not.

If not, then _blink() won't actually clear the caret; it'll only draw.

References m_bCursorBlink, and UT_UNUSED.

Referenced by FV_View::addCaret(), GR_Caret(), and AllCarets::setBlink().

void GR_Caret::setCoords ( UT_sint32  x,
UT_sint32  y,
UT_uint32  h,
UT_sint32  x2 = 0,
UT_sint32  y2 = 0,
UT_uint32  h2 = 0,
bool  bPointDirection = false,
const UT_RGBColor pClr = NULL 
void GR_Caret::setInsertMode ( bool  mode  )  [inline]
void GR_Caret::setPendingBlink ( void   ) 

References m_bPendingBlink, and xxx_UT_DEBUGMSG.

Referenced by s_work().

void GR_Caret::setRemoteColor ( UT_RGBColor  clrRemote  ) 

References m_clrRemote.

Referenced by FV_View::addCaret().

void GR_Caret::setWindowSize ( UT_uint32  width,
UT_uint32  height 

Friends And Related Function Documentation

friend class GR_Graphics [friend]

Member Data Documentation

Referenced by _blink(), setCoords(), and setWindowSize().

Referenced by _blink(), setCoords(), and setWindowSize().

bool GR_Caret::m_bCursorBlink [private]

Referenced by _getCanCursorBlink(), and setBlink().

bool GR_Caret::m_bCursorIsOn [private]
bool GR_Caret::m_bPendingBlink [private]

Referenced by _blink(), and setCoords().

bool GR_Caret::m_bPositionSet [private]

Referenced by _blink(), and setCoords().

Referenced by _blink(), disable(), enable(), and JustErase().

bool GR_Caret::m_bRemote [private]

Referenced by _blink(), and setCoords().

bool GR_Caret::m_bSplitCaret [private]

Referenced by _blink(), and JustErase().

Referenced by _blink().

Referenced by _blink().

Referenced by _blink(), and setRemoteColor().

Referenced by _blink(), GR_Caret(), and JustErase().

long GR_Caret::m_iLastDrawTime [private]

Referenced by _blink().

bool GR_Caret::m_insertMode [private]

Referenced by _blink().

Referenced by _blink(), and setCoords().

Referenced by setCoords().

Referenced by _blink().

Referenced by setCoords(), and setWindowSize().

Referenced by setCoords(), and setWindowSize().

const UT_RGBColor* GR_Caret::m_pClr [private]

Referenced by setCoords().

Referenced by _blink(), JustErase(), and s_work().

std::string GR_Caret::m_sID [private]

Referenced by disable(), GR_Caret(), s_enable(), and ~GR_Caret().

Referenced by _blink(), JustErase(), and setCoords().

Referenced by _blink(), and setCoords().

Referenced by _blink(), setCoords(), and setWindowSize().

The documentation for this class was generated from the following files: