wwWidgets Home · All Classes · Main Classes · Grouped Classes · Functions

QwwRichTextEdit Class Reference
[wwWidgets module]

The QwwRichTextEdit widget provides a drop-in replacement for QTextEdit that contains a toolbar for editing rich text data. More...

 #include <QwwRichTextEdit>

This class is not part of the Qt GUI Framework Edition.

Inherits QTextEdit.

Public Types

enum Action { BoldAction, ItalicAction, UnderlineAction, LeftAlignAction, ..., FontSizeAction }
enum Option { NoOptions, Style, Alignment, FontFamily, FontSize, Color }
flags Options


Public Functions

QwwRichTextEdit ( QWidget * parent = 0 )
Options options () const
QAction * toolBarAction ( Action act ) const

Public Slots

void changeAlignment ( QAction * a )
void setBold ( bool v )
void setColor ( const QColor & c )
void setFont ( const QFont & f )
void setItalic ( bool v )
void setList ( bool v )
void setOptions ( Options opt )
void setUnderline ( bool v )
void updateCurrentBlockFormat ()
void updateCurrentCharFormat ( const QTextCharFormat & fmt )

Additional Inherited Members

Detailed Description

The QwwRichTextEdit widget provides a drop-in replacement for QTextEdit that contains a toolbar for editing rich text data.

Member Type Documentation

enum QwwRichTextEdit::Action

QwwRichTextEdit::BoldAction0Makes the text bold
QwwRichTextEdit::ItalicAction1Makes the text italic
QwwRichTextEdit::UnderlineAction2Makes the text underlined
QwwRichTextEdit::LeftAlignAction3Makes the text left aligned
QwwRichTextEdit::RightAlignAction4Makes the text right aligned
QwwRichTextEdit::AlignCenterAction5Makes the text aligned to the centre
QwwRichTextEdit::JustifyAction6Makes the text justified
QwwRichTextEdit::ColorAction7Changes the color of the text
QwwRichTextEdit::FontFamilyAction8Changes the font family of the text
QwwRichTextEdit::FontSizeAction9Changes the font size of the text

enum QwwRichTextEdit::Option
flags QwwRichTextEdit::Options

QwwRichTextEdit::NoOptions0x0No options are set
QwwRichTextEdit::Style0x01Text style
QwwRichTextEdit::Alignment0x02Item alignment
QwwRichTextEdit::FontFamily0x04Font family
QwwRichTextEdit::FontSize0x08Font size
QwwRichTextEdit::Color0x10Text color

The Options type is a typedef for QFlags<Option>. It stores an OR combination of Option values.

Property Documentation

options : Options

This property holds this property holds the active set of options.

Access functions:

Options options () const
void setOptions ( Options opt )

Member Function Documentation

QwwRichTextEdit::QwwRichTextEdit ( QWidget * parent = 0 )

Constructs a rich text edit with a given parent

void QwwRichTextEdit::changeAlignment ( QAction * a )   [slot]

Changes alignment of the text to the one specified by action a

void QwwRichTextEdit::setBold ( bool v )   [slot]

Changes the bold attribute of the selected text to v

void QwwRichTextEdit::setColor ( const QColor & c )   [slot]

Changes the color of the selected text to c

void QwwRichTextEdit::setFont ( const QFont & f )   [slot]

Changes the font of the selected text to f

void QwwRichTextEdit::setItalic ( bool v )   [slot]

Changes the italic attribute of the selected text to v

void QwwRichTextEdit::setList ( bool v )   [slot]

Changes the list attribute of the selected text to v

void QwwRichTextEdit::setUnderline ( bool v )   [slot]

Changes the underline attribute of the selected text to v

QAction * QwwRichTextEdit::toolBarAction ( Action act ) const

Returns the QAction object associated with action act

void QwwRichTextEdit::updateCurrentBlockFormat ()   [slot]

Updates the format of the selected text

void QwwRichTextEdit::updateCurrentCharFormat ( const QTextCharFormat & fmt )   [slot]

Updates actions to reflect the format specified by fmt

Copyright © 2007-2010 Witold Wysota Trademarks
wwWidgets 1.0.0