VCF::TextPeer Class Reference
This is the basic text peer interface for storing and displaying text on the screen. More...
#include <vcf/ApplicationKit/TextPeer.h>
Inheritance diagram for VCF::TextPeer:

Public Member Functions | |
| virtual OSHandleID | getTextObjectHandle ()=0 |
| Return the native text object handle. | |
| virtual void | insertText (unsigned int start, const String &text)=0 |
| virtual void | deleteText (unsigned int start, unsigned int length)=0 |
| virtual unsigned int | getTextLength ()=0 |
| virtual String | getText (unsigned int start, unsigned int length)=0 |
| virtual void | paint (GraphicsContext *context, const Rect &paintRect)=0 |
| virtual void | setRightMargin (const double &rightMargin)=0 |
| virtual void | setLeftMargin (const double &leftMargin)=0 |
| virtual void | setTopMargin (const double &topMargin)=0 |
| virtual void | setBottomMargin (const double &bottomMargin)=0 |
| virtual double | getLeftMargin ()=0 |
| virtual double | getRightMargin ()=0 |
| virtual double | getTopMargin ()=0 |
| virtual double | getBottomMargin ()=0 |
| virtual uint32 | getLineCount ()=0 |
| virtual Rect | getContentBoundsForWidth (const double &width)=0 |
| virtual void | setStyle (unsigned int start, unsigned int length, Dictionary &styles)=0 |
| This sets the style for the text. | |
| virtual void | getStyle (unsigned int start, unsigned int length, VCF::Dictionary &styles)=0 |
| gets the current style of the text. | |
| virtual void | setDefaultStyle (Dictionary &styles)=0 |
| call this to set the defaults for the text peer. | |
Detailed Description
This is the basic text peer interface for storing and displaying text on the screen.Printing and editing are left to the TextEditPeer interface. You can insert and remove text with this class, as well as set the various styles of the text. You can use this instance wherever you would like to draw basic styled text.
Member Function Documentation
|
||||||||||||
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
||||||||||||||||
|
gets the current style of the text.
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
||||||||||||
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Return the native text object handle. For Win32 systems this will be an IUnknown interface that may be queried for either ITextServices or ITextDocument. For OSX this will be a TXNObject instance. Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
||||||||||||
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
||||||||||||
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
call this to set the defaults for the text peer. If this is not called, then the default font is that used for label controls and the defaul paragraph alignment is left aligned. Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
||||||||||||||||
|
This sets the style for the text. Pass in a Dictionary with a set of values for each style attribute. Example: TextPeer* textPeer = .... Dictionary styles; style [Text::fsFontName] = "Arial"; style [Text::fsPointSize] = 15.0; style [Text::fsBold] = true; textPeer->setStyle( 5, 10, styles ); this changes the font at position 5, for a length of 10, to be "arial", bold and a point size of 15. Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
|
|
Implemented in VCF::OSXTextEditPeer, VCF::OSXTextPeer, VCF::Win32Edit, and VCF::Win32TextPeer. |
The documentation for this class was generated from the following file:
- vcf/ApplicationKit/TextPeer.h
