Humble Framework for SkyOS


Main Page | Modules | Class Hierarchy | Alphabetical List | Data Structures | Directories | File List | Data Fields | Globals | Related Pages

HTextEdit Class Reference
[Graphical User Interface]

#include <HTextEdit.h>

Inheritance diagram for HTextEdit:

HWidget HObjNoCopy HObj

Public Member Functions

ErrCode AddText (StringPtr pstr, bool bRedraw=true)
 Adds text to the text edit control.
ErrCode Create (HANDLE hParent, StringPtr pstrName, HRect *prBounds=NULL, uint32 uStyle=0)
 Creates the textedit widget.
ErrCode DeleteAllText (void)
 Adds text to the text edit control.
uint32 GetLineCount (void) const
 Returns the current line count.
ErrCode SetLineBackColor (uint32 uLine, const HColor &color)
 Sets the back color for a given line.
ErrCode SetReadOnly (bool bReadOnly)
 Makes the textedit control read only.
bool IsReadOnly (void) const
 Returns true if textedit control is read only.

Protected Member Functions

ErrCode redrawText (void) const
 Redraws the text.
bool isValidLine (uint32 uLine) const

Protected Attributes

bool m_bReadOnly
 Read-only flag.
uint32 m_uTextLines
 Count of output lines.

Member Function Documentation

ErrCode HTextEdit::AddText StringPtr  pstr,
bool  bRedraw = true
 

Returns:
NO_ERROR on success, error code otherwise
Parameters:
pstr Ptr to text to add
bRedraw True to redraw text, false to defer

Definition at line 63 of file HTextEdit.h.

ErrCode HTextEdit::Create HANDLE  hParent,
StringPtr  pstrName,
HRect prBounds = NULL,
uint32  uStyle = 0
 

Returns:
NO_ERROR on success, error code otherwise
Parameters:
hParent Handle of parent window (must be non-NULL)
pstrName Name of textedit
prBounds [optional] Ptr to bounds rectangle
uStyle Style flags (WGF_* constants)

Definition at line 101 of file HTextEdit.h.

ErrCode HTextEdit::DeleteAllText void   ) 
 

Returns:
NO_ERROR on success, error code otherwise

Definition at line 147 of file HTextEdit.h.

ErrCode HTextEdit::redrawText void   )  const [protected]
 

Returns:
NO_ERROR on success, error code otherwise

Definition at line 173 of file HTextEdit.h.

uint32 HTextEdit::GetLineCount void   )  const
 

Returns:
Number of lines

Definition at line 195 of file HTextEdit.h.

ErrCode HTextEdit::SetLineBackColor uint32  uLine,
const HColor color
 

This method sets the background color for a specific line of text. The lines are numbered from 1...GetLineCount(), inclusive.

Returns:
NO_ERROR on success, error code otherwise
Parameters:
uLine Line number (1 <= x <= m_uTextLines)
color Desired color

Definition at line 207 of file HTextEdit.h.

ErrCode HTextEdit::SetReadOnly bool  bReadOnly  ) 
 

Parameters:
bReadOnly True for read-only, false for writeable

Definition at line 231 of file HTextEdit.h.

bool HTextEdit::IsReadOnly void   )  const
 

Returns:
True of read-only, false otherwise

Definition at line 250 of file HTextEdit.h.


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

2006.01.09-16:37