Main Page | Namespace List | Class Hierarchy | Alphabetical List | Class List | Directories | File List | Namespace Members | Class Members | File Members | Related Pages

QTextFormat Class Reference

#include </home/clem/local/src/opie/qmake/include/private/qrichtext_p.h>

Collaboration diagram for QTextFormat:

Collaboration graph
[legend]
List of all members.

Public Types

enum  Flags {
  NoFlags, Bold = 1, Italic = 2, Underline = 4,
  Family = 8, Size = 16, Color = 32, Misspelled = 64,
  VAlign = 128, StrikeOut = 256, Font = Bold | Italic | Underline | Family | Size | StrikeOut, Format = Font | Color | Misspelled | VAlign
}
enum  VerticalAlignment { AlignNormal, AlignSuperScript, AlignSubScript }

Public Member Functions

 QTextFormat ()
virtual ~QTextFormat ()
 QTextFormat (const QStyleSheetItem *s)
 QTextFormat (const QFont &f, const QColor &c, QTextFormatCollection *parent=0)
 QTextFormat (const QTextFormat &fm)
QTextFormat makeTextFormat (const QStyleSheetItem *style, const QMap< QString, QString > &attr, double scaleFontsFactor) const
QTextFormatoperator= (const QTextFormat &fm)
QColor color () const
QFont font () const
bool isMisspelled () const
VerticalAlignment vAlign () const
int minLeftBearing () const
int minRightBearing () const
int width (const QChar &c) const
int width (const QString &str, int pos) const
int height () const
int ascent () const
int descent () const
int leading () const
bool useLinkColor () const
void setBold (bool b)
void setItalic (bool b)
void setUnderline (bool b)
void setStrikeOut (bool b)
void setFamily (const QString &f)
void setPointSize (int s)
void setFont (const QFont &f)
void setColor (const QColor &c)
void setMisspelled (bool b)
void setVAlign (VerticalAlignment a)
bool operator== (const QTextFormat &f) const
QTextFormatCollectionparent () const
const QStringkey () const
void addRef ()
void removeRef ()
QString makeFormatChangeTags (QTextFormat *defaultFormat, QTextFormat *f, const QString &oldAnchorHref, const QString &anchorHref) const
QString makeFormatEndTags (QTextFormat *defaultFormat, const QString &anchorHref) const
bool fontSizesInPixels ()

Static Public Member Functions

static QString getKey (const QFont &f, const QColor &c, bool misspelled, VerticalAlignment vAlign)
static void setPainter (QPainter *p)
static QPainter * painter ()

Protected Member Functions

virtual void generateKey ()

Private Member Functions

void update ()

Static Private Member Functions

static void applyFont (const QFont &f)

Private Attributes

QFont fn
QColor col
QFontMetrics fm
uint missp: 1
uint linkColor: 1
uint usePixelSizes: 1
int leftBearing
int rightBearing
VerticalAlignment ha
uchar widths [256]
int hei
int asc
int dsc
QTextFormatCollectioncollection
int ref
QString k
int logicalFontSize
int stdSize

Static Private Attributes

static QPainter * pntr
static QFontMetrics * pntr_fm
static int pntr_asc
static int pntr_hei
static int pntr_ldg
static int pntr_dsc

Friends

class QTextFormatCollection
class QTextDocument

Member Enumeration Documentation

enum QTextFormat::Flags
 

Enumeration values:
NoFlags 
Bold 
Italic 
Underline 
Family 
Size 
Color 
Misspelled 
VAlign 
StrikeOut 
Font 
Format 

Definition at line 1478 of file qrichtext_p.h.

enum QTextFormat::VerticalAlignment
 

Enumeration values:
AlignNormal 
AlignSuperScript 
AlignSubScript 

Definition at line 1493 of file qrichtext_p.h.


Constructor & Destructor Documentation

QTextFormat::QTextFormat  ) 
 

virtual QTextFormat::~QTextFormat  )  [virtual]
 

QTextFormat::QTextFormat const QStyleSheetItem s  ) 
 

QTextFormat::QTextFormat const QFont &  f,
const QColor &  c,
QTextFormatCollection parent = 0
 

QTextFormat::QTextFormat const QTextFormat fm  ) 
 


Member Function Documentation

void QTextFormat::addRef  )  [inline]
 

Definition at line 1886 of file qrichtext_p.h.

References ref.

static void QTextFormat::applyFont const QFont &  f  )  [static, private]
 

int QTextFormat::ascent  )  const
 

QColor QTextFormat::color  )  const [inline]
 

Definition at line 1856 of file qrichtext_p.h.

References col.

int QTextFormat::descent  )  const
 

QFont QTextFormat::font  )  const [inline]
 

Definition at line 1861 of file qrichtext_p.h.

References fn.

bool QTextFormat::fontSizesInPixels  )  [inline]
 

Definition at line 1543 of file qrichtext_p.h.

virtual void QTextFormat::generateKey  )  [protected, virtual]
 

static QString QTextFormat::getKey const QFont &  f,
const QColor &  c,
bool  misspelled,
VerticalAlignment  vAlign
[static]
 

Referenced by Qt3::QTextFormatCollection::format().

int QTextFormat::height  )  const
 

bool QTextFormat::isMisspelled  )  const [inline]
 

Definition at line 1866 of file qrichtext_p.h.

References missp.

const QString & QTextFormat::key  )  const [inline]
 

Definition at line 1902 of file qrichtext_p.h.

References k.

int QTextFormat::leading  )  const
 

QString QTextFormat::makeFormatChangeTags QTextFormat defaultFormat,
QTextFormat f,
const QString oldAnchorHref,
const QString anchorHref
const
 

QString QTextFormat::makeFormatEndTags QTextFormat defaultFormat,
const QString anchorHref
const
 

QTextFormat QTextFormat::makeTextFormat const QStyleSheetItem style,
const QMap< QString, QString > &  attr,
double  scaleFontsFactor
const
 

int QTextFormat::minLeftBearing  )  const
 

int QTextFormat::minRightBearing  )  const
 

QTextFormat& QTextFormat::operator= const QTextFormat fm  ) 
 

bool QTextFormat::operator== const QTextFormat f  )  const [inline]
 

Definition at line 1876 of file qrichtext_p.h.

References k.

static QPainter* QTextFormat::painter  )  [static]
 

Referenced by Qt3::QTextDocument::doLayout(), Qt3::QTextFormatterBreakWords::format(), and Qt3::QTextFormatterBreakInWords::format().

QTextFormatCollection * QTextFormat::parent  )  const [inline]
 

Definition at line 1881 of file qrichtext_p.h.

References collection.

void QTextFormat::removeRef  )  [inline]
 

Definition at line 1891 of file qrichtext_p.h.

References collection, QTextFormatCollection::defFormat, ref, and QTextFormatCollection::remove().

void QTextFormat::setBold bool  b  ) 
 

void QTextFormat::setColor const QColor &  c  ) 
 

void QTextFormat::setFamily const QString f  ) 
 

void QTextFormat::setFont const QFont &  f  ) 
 

void QTextFormat::setItalic bool  b  ) 
 

void QTextFormat::setMisspelled bool  b  ) 
 

static void QTextFormat::setPainter QPainter *  p  )  [static]
 

Referenced by Qt3::QTextDocument::doLayout().

void QTextFormat::setPointSize int  s  ) 
 

void QTextFormat::setStrikeOut bool  b  ) 
 

void QTextFormat::setUnderline bool  b  ) 
 

void QTextFormat::setVAlign VerticalAlignment  a  ) 
 

void QTextFormat::update  )  [private]
 

bool QTextFormat::useLinkColor  )  const [inline]
 

Definition at line 1907 of file qrichtext_p.h.

References linkColor.

QTextFormat::VerticalAlignment QTextFormat::vAlign  )  const [inline]
 

Definition at line 1871 of file qrichtext_p.h.

References ha.

int QTextFormat::width const QString str,
int  pos
const
 

int QTextFormat::width const QChar c  )  const
 


Friends And Related Function Documentation

friend class QTextDocument [friend]
 

Definition at line 1475 of file qrichtext_p.h.

friend class QTextFormatCollection [friend]
 

Definition at line 1474 of file qrichtext_p.h.


Member Data Documentation

int QTextFormat::asc [private]
 

Definition at line 1562 of file qrichtext_p.h.

QColor QTextFormat::col [private]
 

Definition at line 1554 of file qrichtext_p.h.

Referenced by color(), and Qt3::QTextFormat::color().

QTextFormatCollection* QTextFormat::collection [private]
 

Definition at line 1563 of file qrichtext_p.h.

Referenced by parent(), Qt3::QTextFormat::parent(), removeRef(), and Qt3::QTextFormat::removeRef().

int QTextFormat::dsc [private]
 

Definition at line 1562 of file qrichtext_p.h.

QFontMetrics QTextFormat::fm [private]
 

Definition at line 1555 of file qrichtext_p.h.

QFont QTextFormat::fn [private]
 

Definition at line 1553 of file qrichtext_p.h.

Referenced by font(), and Qt3::QTextFormat::font().

VerticalAlignment QTextFormat::ha [private]
 

Definition at line 1560 of file qrichtext_p.h.

Referenced by vAlign(), and Qt3::QTextFormat::vAlign().

int QTextFormat::hei [private]
 

Definition at line 1562 of file qrichtext_p.h.

QString QTextFormat::k [private]
 

Definition at line 1565 of file qrichtext_p.h.

Referenced by key(), Qt3::QTextFormat::key(), operator==(), and Qt3::QTextFormat::operator==().

int QTextFormat::leftBearing [private]
 

Definition at line 1559 of file qrichtext_p.h.

uint QTextFormat::linkColor [private]
 

Definition at line 1557 of file qrichtext_p.h.

Referenced by useLinkColor(), and Qt3::QTextFormat::useLinkColor().

int QTextFormat::logicalFontSize [private]
 

Definition at line 1566 of file qrichtext_p.h.

uint QTextFormat::missp [private]
 

Definition at line 1556 of file qrichtext_p.h.

Referenced by isMisspelled(), and Qt3::QTextFormat::isMisspelled().

QPainter* QTextFormat::pntr [static, private]
 

Definition at line 1568 of file qrichtext_p.h.

int QTextFormat::pntr_asc [static, private]
 

Definition at line 1570 of file qrichtext_p.h.

int QTextFormat::pntr_dsc [static, private]
 

Definition at line 1573 of file qrichtext_p.h.

QFontMetrics* QTextFormat::pntr_fm [static, private]
 

Definition at line 1569 of file qrichtext_p.h.

int QTextFormat::pntr_hei [static, private]
 

Definition at line 1571 of file qrichtext_p.h.

int QTextFormat::pntr_ldg [static, private]
 

Definition at line 1572 of file qrichtext_p.h.

int QTextFormat::ref [private]
 

Definition at line 1564 of file qrichtext_p.h.

Referenced by addRef(), Qt3::QTextFormat::addRef(), removeRef(), and Qt3::QTextFormat::removeRef().

int QTextFormat::rightBearing [private]
 

Definition at line 1559 of file qrichtext_p.h.

int QTextFormat::stdSize [private]
 

Definition at line 1567 of file qrichtext_p.h.

uint QTextFormat::usePixelSizes [private]
 

Definition at line 1558 of file qrichtext_p.h.

uchar QTextFormat::widths[256] [private]
 

Definition at line 1561 of file qrichtext_p.h.


The documentation for this class was generated from the following file:
Generated on Sat Nov 5 17:49:28 2005 for OPIE by  doxygen 1.4.2