lib

#include <KoTextFormat.h>

Public Types

enum  Flags {
  NoFlags , Bold = 1 , Italic = 2 , Underline = 4 ,
  Family = 8 , Size = 16 , Color = 32 , Misspelled = 64 ,
  VAlign = 128 , StrikeOut = 512 , TextBackgroundColor = 1024 , ExtendUnderLine = 2048 ,
  Language = 4096 , ShadowText = 8192 , OffsetFromBaseLine = 16384 , WordByWord = 32768 ,
  Attribute = 65536 , Hyphenation = 131072 , UnderLineWidth = 262144 , Font = Bold | Italic | Underline | Family | Size ,
  Format
}
 
enum  VerticalAlignment { AlignNormal , AlignSubScript , AlignSuperScript , AlignCustom }
 
enum  UnderlineType {
  U_NONE = 0 , U_SIMPLE = 1 , U_DOUBLE = 2 , U_SIMPLE_BOLD = 3 ,
  U_WAVE = 4
}
 
enum  StrikeOutType { S_NONE = 0 , S_SIMPLE = 1 , S_DOUBLE = 2 , S_SIMPLE_BOLD = 3 }
 
enum  UnderlineStyle {
  U_SOLID = 0 , U_DASH = 1 , U_DOT = 2 , U_DASH_DOT = 3 ,
  U_DASH_DOT_DOT = 4
}
 
enum  StrikeOutStyle {
  S_SOLID = 0 , S_DASH = 1 , S_DOT = 2 , S_DASH_DOT = 3 ,
  S_DASH_DOT_DOT = 4
}
 
enum  AttributeStyle { ATT_NONE = 0 , ATT_UPPER = 1 , ATT_LOWER = 2 , ATT_SMALL_CAPS }
 

Public Member Functions

 KoTextFormat (const TQFont &f, const TQColor &c, const TQString &_language, bool hyphenation, KoTextFormatCollection *parent=0)
 
 KoTextFormat (const TQFont &_font, VerticalAlignment _valign, const TQColor &_color, const TQColor &_backGroundColor, const TQColor &_underlineColor, KoTextFormat::UnderlineType _underlineType, KoTextFormat::UnderlineStyle _underlineStyle, KoTextFormat::StrikeOutType _strikeOutType, KoTextFormat::StrikeOutStyle _strikeOutStyle, KoTextFormat::AttributeStyle _fontAttribute, const TQString &_language, double _relativeTextSize, int _offsetFromBaseLine, bool _wordByWord, bool _hyphenation, double _shadowDistanceX, double _shadowDistanceY, const TQColor &shadowColor)
 
 KoTextFormat (const KoTextFormat &fm)
 
KoTextFormat & operator= (const KoTextFormat &fm)
 
void copyFormat (const KoTextFormat &fm, int flags)
 
TQColor color () const
 
TQFont font () const
 
int pointSize () const
 
bool isMisspelled () const
 
VerticalAlignment vAlign () const
 
int width (const TQChar &c) const
 
int width (const TQString &str, int pos) const
 
int height () const
 
int ascent () const
 
int descent () const
 
int offsetX () const
 
int offsetY () const
 
void setBold (bool b)
 
void setItalic (bool b)
 
void setUnderline (bool b)
 
void setFamily (const TQString &f)
 
void setPointSize (int s)
 
void setFont (const TQFont &f)
 
void setColor (const TQColor &c)
 
void setMisspelled (bool b)
 
void setVAlign (VerticalAlignment a)
 
bool operator== (const KoTextFormat &f) const
 
KoTextFormatCollection * parent () const
 
void setCollection (KoTextFormatCollection *parent)
 
TQString key () const
 
void addRef ()
 
void removeRef ()
 
int compare (const KoTextFormat &format) const
 
void setStrikeOutType (StrikeOutType _type)
 
StrikeOutType strikeOutType () const
 
void setStrikeOutStyle (StrikeOutStyle _type)
 
StrikeOutStyle strikeOutStyle () const
 
void setTextBackgroundColor (const TQColor &)
 
TQColor textBackgroundColor () const
 
void setTextUnderlineColor (const TQColor &)
 
TQColor textUnderlineColor () const
 
void setUnderlineType (UnderlineType _type)
 
UnderlineType underlineType () const
 
void setUnderlineStyle (UnderlineStyle _type)
 
UnderlineStyle underlineStyle () const
 
void setLanguage (const TQString &_lang)
 
TQString language () const
 
void setHyphenation (bool b)
 
bool hyphenation () const
 
void setUnderLineWidth (double ulw)
 
double underLineWidth () const
 
void setAttributeFont (KoTextFormat::AttributeStyle _att)
 
KoTextFormat::AttributeStyle attributeFont () const
 
double shadowDistanceX () const
 
double shadowDistanceY () const
 
TQColor shadowColor () const
 
int shadowX (KoTextZoomHandler *zh) const
 
int shadowY (KoTextZoomHandler *zh) const
 
void setShadow (double shadowDistanceX, double shadowDistanceY, const TQColor &shadowColor)
 
TQString shadowAsCss () const
 
void parseShadowFromCss (const TQString &css)
 
double relativeTextSize () const
 
void setRelativeTextSize (double _size)
 
int offsetFromBaseLine () const
 
void setOffsetFromBaseLine (int _offset)
 
bool wordByWord () const
 
void setWordByWord (bool _b)
 
bool doubleUnderline () const
 
bool waveUnderline () const
 
bool underline () const
 
bool strikeOut () const
 
bool doubleStrikeOut () const
 
bool isStrikedOrUnderlined () const
 
float refPointSize () const
 
float screenPointSize (const KoTextZoomHandler *zh) const
 
const TQFontMetrics & refFontMetrics () const
 
const TQFontMetrics & screenFontMetrics (const KoTextZoomHandler *zh) const
 
TQFont refFont () const
 
TQFont screenFont (const KoTextZoomHandler *zh) const
 
TQFont smallCapsFont (const KoTextZoomHandler *zh, bool applyZoom) const
 
int charWidth (const KoTextZoomHandler *zh, bool applyZoom, const KoTextStringChar *c, const KoTextParag *parag, int i) const
 
int charWidthLU (const KoTextStringChar *c, const KoTextParag *parag, int i) const
 
void applyCharStyle (KoCharStyle *_style)
 
KoCharStyle * style () const
 
TQString displayedString (const TQString &c) const
 
void load (KoOasisContext &context)
 
void save (KoGenStyle &gs, KoSavingContext &context, KoTextFormat *refFormat=0) const
 
void printDebug ()
 
void zoomChanged ()
 

Static Public Member Functions

static TQString getKey (const TQFont &f, const TQColor &c, bool misspelled, VerticalAlignment vAlign)
 
static TQColor defaultTextColor (TQPainter *painter)
 
static TQString shadowAsCss (double shadowDistanceX, double shadowDistanceY, const TQColor &shadowColor)
 
static TQString underlineStyleToString (UnderlineStyle _lineType)
 
static TQString strikeOutStyleToString (StrikeOutStyle _lineType)
 
static UnderlineStyle stringToUnderlineStyle (const TQString &_str)
 
static StrikeOutStyle stringToStrikeOutStyle (const TQString &_str)
 
static TQString attributeFontToString (KoTextFormat::AttributeStyle _attr)
 
static AttributeStyle stringToAttributeFont (const TQString &_str)
 
static TQStringList underlineTypeList ()
 
static TQStringList strikeOutTypeList ()
 
static TQStringList fontAttributeList ()
 
static TQStringList underlineStyleList ()
 
static TQStringList strikeOutStyleList ()
 

Protected Member Functions

TQChar displayedChar (TQChar c) const
 
void generateKey ()
 

Friends

class KoTextFormatCollection
 

Detailed Description

Each character (KoTextStringChar) points to a KoTextFormat that defines the formatting of that character (font, bold, italic, underline, misspelled etc.).

Formats are stored in KoTextFormatCollection and are shared for all characters with the same format. The API rule is that a const KoTextFormat* is a temporary format (out of collection) and a KoTextFormat* is a format from the collection.

Definition at line 52 of file KoTextFormat.h.

Member Enumeration Documentation

◆ AttributeStyle

enum KoTextFormat::AttributeStyle

Definition at line 133 of file KoTextFormat.h.

◆ Flags

enum KoTextFormat::Flags

Definition at line 98 of file KoTextFormat.h.

◆ StrikeOutStyle

enum KoTextFormat::StrikeOutStyle

Definition at line 131 of file KoTextFormat.h.

◆ StrikeOutType

enum KoTextFormat::StrikeOutType

Definition at line 129 of file KoTextFormat.h.

◆ UnderlineStyle

enum KoTextFormat::UnderlineStyle

Definition at line 130 of file KoTextFormat.h.

◆ UnderlineType

enum KoTextFormat::UnderlineType

Definition at line 128 of file KoTextFormat.h.

◆ VerticalAlignment

enum KoTextFormat::VerticalAlignment

Definition at line 127 of file KoTextFormat.h.

Constructor & Destructor Documentation

◆ KoTextFormat() [1/4]

KoTextFormat::KoTextFormat ( )

Definition at line 55 of file KoTextFormat.cpp.

◆ ~KoTextFormat()

KoTextFormat::~KoTextFormat ( )

Definition at line 185 of file KoTextFormat.cpp.

◆ KoTextFormat() [2/4]

KoTextFormat::KoTextFormat ( const TQFont &  f,
const TQColor &  c,
const TQString &  _language,
bool  hyphenation,
KoTextFormatCollection *  parent = 0 
)

A simple text format with some default settings Only used for the default format.

Definition at line 85 of file KoTextFormat.cpp.

◆ KoTextFormat() [3/4]

KoTextFormat::KoTextFormat ( const TQFont &  _font,
VerticalAlignment  _valign,
const TQColor &  _color,
const TQColor &  _backGroundColor,
const TQColor &  _underlineColor,
KoTextFormat::UnderlineType  _underlineType,
KoTextFormat::UnderlineStyle  _underlineStyle,
KoTextFormat::StrikeOutType  _strikeOutType,
KoTextFormat::StrikeOutStyle  _strikeOutStyle,
KoTextFormat::AttributeStyle  _fontAttribute,
const TQString &  _language,
double  _relativeTextSize,
int  _offsetFromBaseLine,
bool  _wordByWord,
bool  _hyphenation,
double  _shadowDistanceX,
double  _shadowDistanceY,
const TQColor &  shadowColor 
)

A complete text format (used by KoFontDia)

Definition at line 130 of file KoTextFormat.cpp.

◆ KoTextFormat() [4/4]

KoTextFormat::KoTextFormat ( const KoTextFormat &  fm)

Definition at line 179 of file KoTextFormat.cpp.

Member Function Documentation

◆ addRef()

void KoTextFormat::addRef ( )

Definition at line 926 of file KoTextFormat.cpp.

◆ applyCharStyle()

void KoTextFormat::applyCharStyle ( KoCharStyle *  _style)

Definition at line 1383 of file KoTextFormat.cpp.

◆ ascent()

int KoTextFormat::ascent ( ) const

Definition at line 1338 of file KoTextFormat.cpp.

◆ attributeFont()

KoTextFormat::AttributeStyle KoTextFormat::attributeFont ( ) const
inline

Definition at line 248 of file KoTextFormat.h.

◆ attributeFontToString()

TQString KoTextFormat::attributeFontToString ( KoTextFormat::AttributeStyle  _attr)
static

Definition at line 1554 of file KoTextFormat.cpp.

◆ charWidth()

int KoTextFormat::charWidth ( const KoTextZoomHandler *  zh,
bool  applyZoom,
const KoTextStringChar *  c,
const KoTextParag *  parag,
int  i 
) const

Return the width of one char in one paragraph.

Used by KoTextFormatter twice: once for the 100% zoom pointsize (via charWidthLU), and once for the current zoom pointsize.

Definition at line 1179 of file KoTextFormat.cpp.

◆ charWidthLU()

int KoTextFormat::charWidthLU ( const KoTextStringChar *  c,
const KoTextParag *  parag,
int  i 
) const

Return the width of one char in LU pixels.

Equivalent to ptToLayoutUnitPt( charWidth( 0L, false, c, parag, i ) )

Definition at line 1370 of file KoTextFormat.cpp.

◆ color()

TQColor KoTextFormat::color ( ) const
inline

Definition at line 454 of file KoTextFormat.h.

◆ compare()

int KoTextFormat::compare ( const KoTextFormat &  format) const

Return a set of flags showing the differences between this and 'format'.

Definition at line 1040 of file KoTextFormat.cpp.

◆ copyFormat()

void KoTextFormat::copyFormat ( const KoTextFormat &  fm,
int  flags 
)

Definition at line 683 of file KoTextFormat.cpp.

◆ defaultTextColor()

TQColor KoTextFormat::defaultTextColor ( TQPainter *  painter)
static

Call this when a text color is set to 'invalid', meaning 'whatever the default for the color scheme is'.

Definition at line 1084 of file KoTextFormat.cpp.

◆ descent()

int KoTextFormat::descent ( ) const

Definition at line 1355 of file KoTextFormat.cpp.

◆ displayedChar()

TQChar KoTextFormat::displayedChar ( TQChar  c) const
protected

Definition at line 1320 of file KoTextFormat.cpp.

◆ displayedString()

TQString KoTextFormat::displayedString ( const TQString &  c) const

Definition at line 1304 of file KoTextFormat.cpp.

◆ doubleStrikeOut()

bool KoTextFormat::doubleStrikeOut ( ) const
inline

Definition at line 279 of file KoTextFormat.h.

◆ doubleUnderline()

bool KoTextFormat::doubleUnderline ( ) const
inline

Definition at line 275 of file KoTextFormat.h.

◆ font()

TQFont KoTextFormat::font ( ) const
inline

Definition at line 459 of file KoTextFormat.h.

◆ fontAttributeList()

TQStringList KoTextFormat::fontAttributeList ( )
static

Definition at line 1630 of file KoTextFormat.cpp.

◆ generateKey()

void KoTextFormat::generateKey ( )
protected

Definition at line 831 of file KoTextFormat.cpp.

◆ getKey()

TQString KoTextFormat::getKey ( const TQFont &  f,
const TQColor &  c,
bool  misspelled,
VerticalAlignment  vAlign 
)
static

Definition at line 880 of file KoTextFormat.cpp.

◆ height()

int KoTextFormat::height ( ) const

Definition at line 1250 of file KoTextFormat.cpp.

◆ hyphenation()

bool KoTextFormat::hyphenation ( ) const
inline

Definition at line 239 of file KoTextFormat.h.

◆ isMisspelled()

bool KoTextFormat::isMisspelled ( ) const
inline

Definition at line 464 of file KoTextFormat.h.

◆ isStrikedOrUnderlined()

bool KoTextFormat::isStrikedOrUnderlined ( ) const
inline

Definition at line 280 of file KoTextFormat.h.

◆ key()

TQString KoTextFormat::key ( ) const

Definition at line 919 of file KoTextFormat.cpp.

◆ language()

TQString KoTextFormat::language ( ) const
inline

Definition at line 236 of file KoTextFormat.h.

◆ load()

void KoTextFormat::load ( KoOasisContext &  context)

Load a text format from OASIS XML.

Definition at line 375 of file KoTextFormat.cpp.

◆ offsetFromBaseLine()

int KoTextFormat::offsetFromBaseLine ( ) const
inline

Definition at line 269 of file KoTextFormat.h.

◆ offsetX()

int KoTextFormat::offsetX ( ) const

Definition at line 1274 of file KoTextFormat.cpp.

◆ offsetY()

int KoTextFormat::offsetY ( ) const

Definition at line 1290 of file KoTextFormat.cpp.

◆ operator=()

KoTextFormat & KoTextFormat::operator= ( const KoTextFormat &  fm)

Definition at line 199 of file KoTextFormat.cpp.

◆ operator==()

bool KoTextFormat::operator== ( const KoTextFormat &  f) const
inline

Definition at line 474 of file KoTextFormat.h.

◆ parent()

KoTextFormatCollection * KoTextFormat::parent ( ) const
inline

Definition at line 479 of file KoTextFormat.h.

◆ parseShadowFromCss()

void KoTextFormat::parseShadowFromCss ( const TQString &  css)

Load shadow attributes from a css string, used when loading.

Definition at line 1413 of file KoTextFormat.cpp.

◆ pointSize()

int KoTextFormat::pointSize ( ) const
inline

Definition at line 170 of file KoTextFormat.h.

◆ printDebug()

void KoTextFormat::printDebug ( )

Definition at line 1663 of file KoTextFormat.cpp.

◆ refFont()

TQFont KoTextFormat::refFont ( ) const
Returns
the reference font, i.e. with the size specified by the user. This is used at text layout time (e.g. kotextformatter)

Definition at line 1108 of file KoTextFormat.cpp.

◆ refFontMetrics()

const TQFontMetrics & KoTextFormat::refFontMetrics ( ) const
Returns
the metrics for the reference font, i.e. with the size specified by the user. This is the one used during formatting, independently from the zoom level. This method takes care of superscript and subscript (smaller font).

Definition at line 1157 of file KoTextFormat.cpp.

◆ refPointSize()

float KoTextFormat::refPointSize ( ) const
Returns
the reference point size, i.e. the size specified by the user. This is the one used during formatting, independently from the zoom level. This method takes care of superscript and subscript (smaller font).

Definition at line 1100 of file KoTextFormat.cpp.

◆ relativeTextSize()

double KoTextFormat::relativeTextSize ( ) const
inline

Definition at line 265 of file KoTextFormat.h.

◆ removeRef()

void KoTextFormat::removeRef ( )

Definition at line 935 of file KoTextFormat.cpp.

◆ save()

void KoTextFormat::save ( KoGenStyle &  gs,
KoSavingContext &  context,
KoTextFormat *  refFormat = 0 
) const

Save a text format to OASIS XML Only saves what differs from @refFormat, if set.

Definition at line 541 of file KoTextFormat.cpp.

◆ screenFont()

TQFont KoTextFormat::screenFont ( const KoTextZoomHandler *  zh) const

Returns the font to be used at the zoom & resolution given by 'zh'.

Despite the name, this is probably valid for printing too. This method takes care of superscript and subscript (smaller font).

Definition at line 1123 of file KoTextFormat.cpp.

◆ screenFontMetrics()

const TQFontMetrics & KoTextFormat::screenFontMetrics ( const KoTextZoomHandler *  zh) const

Returns the font metrics for the font used at the zoom & resolution given by 'zh'.

Despite the name, this is probably valid for printing too. This method takes care of superscript and subscript (smaller font).

Definition at line 1144 of file KoTextFormat.cpp.

◆ screenPointSize()

float KoTextFormat::screenPointSize ( const KoTextZoomHandler *  zh) const
Returns
the point size to use on screen, given zh This method takes care of superscript and subscript (smaller font).

Definition at line 1091 of file KoTextFormat.cpp.

◆ setAttributeFont()

void KoTextFormat::setAttributeFont ( KoTextFormat::AttributeStyle  _att)

Definition at line 1031 of file KoTextFormat.cpp.

◆ setBold()

void KoTextFormat::setBold ( bool  b)

Definition at line 738 of file KoTextFormat.cpp.

◆ setCollection()

void KoTextFormat::setCollection ( KoTextFormatCollection *  parent)
inline

Definition at line 201 of file KoTextFormat.h.

◆ setColor()

void KoTextFormat::setColor ( const TQColor &  c)

Definition at line 803 of file KoTextFormat.cpp.

◆ setFamily()

void KoTextFormat::setFamily ( const TQString &  f)

Definition at line 778 of file KoTextFormat.cpp.

◆ setFont()

void KoTextFormat::setFont ( const TQFont &  f)

Definition at line 794 of file KoTextFormat.cpp.

◆ setHyphenation()

void KoTextFormat::setHyphenation ( bool  b)

Definition at line 1583 of file KoTextFormat.cpp.

◆ setItalic()

void KoTextFormat::setItalic ( bool  b)

Definition at line 762 of file KoTextFormat.cpp.

◆ setLanguage()

void KoTextFormat::setLanguage ( const TQString &  _lang)

Definition at line 1601 of file KoTextFormat.cpp.

◆ setMisspelled()

void KoTextFormat::setMisspelled ( bool  b)

Definition at line 746 of file KoTextFormat.cpp.

◆ setOffsetFromBaseLine()

void KoTextFormat::setOffsetFromBaseLine ( int  _offset)

Definition at line 1014 of file KoTextFormat.cpp.

◆ setPointSize()

void KoTextFormat::setPointSize ( int  s)

Definition at line 786 of file KoTextFormat.cpp.

◆ setRelativeTextSize()

void KoTextFormat::setRelativeTextSize ( double  _size)

Definition at line 1006 of file KoTextFormat.cpp.

◆ setShadow()

void KoTextFormat::setShadow ( double  shadowDistanceX,
double  shadowDistanceY,
const TQColor &  shadowColor 
)

Definition at line 994 of file KoTextFormat.cpp.

◆ setStrikeOutStyle()

void KoTextFormat::setStrikeOutStyle ( StrikeOutStyle  _type)

Definition at line 971 of file KoTextFormat.cpp.

◆ setStrikeOutType()

void KoTextFormat::setStrikeOutType ( StrikeOutType  _type)

Definition at line 947 of file KoTextFormat.cpp.

◆ setTextBackgroundColor()

void KoTextFormat::setTextBackgroundColor ( const TQColor &  _col)

Definition at line 979 of file KoTextFormat.cpp.

◆ setTextUnderlineColor()

void KoTextFormat::setTextUnderlineColor ( const TQColor &  _col)

Definition at line 986 of file KoTextFormat.cpp.

◆ setUnderline()

void KoTextFormat::setUnderline ( bool  b)

Definition at line 770 of file KoTextFormat.cpp.

◆ setUnderlineStyle()

void KoTextFormat::setUnderlineStyle ( UnderlineStyle  _type)

Definition at line 963 of file KoTextFormat.cpp.

◆ setUnderlineType()

void KoTextFormat::setUnderlineType ( UnderlineType  _type)

Definition at line 955 of file KoTextFormat.cpp.

◆ setUnderLineWidth()

void KoTextFormat::setUnderLineWidth ( double  ulw)

Definition at line 1592 of file KoTextFormat.cpp.

◆ setVAlign()

void KoTextFormat::setVAlign ( VerticalAlignment  a)

Definition at line 754 of file KoTextFormat.cpp.

◆ setWordByWord()

void KoTextFormat::setWordByWord ( bool  _b)

Definition at line 1022 of file KoTextFormat.cpp.

◆ shadowAsCss() [1/2]

TQString KoTextFormat::shadowAsCss ( ) const

Return css string for the shadow, used when saving.

Definition at line 1408 of file KoTextFormat.cpp.

◆ shadowAsCss() [2/2]

TQString KoTextFormat::shadowAsCss ( double  shadowDistanceX,
double  shadowDistanceY,
const TQColor &  shadowColor 
)
static

Definition at line 1393 of file KoTextFormat.cpp.

◆ shadowColor()

TQColor KoTextFormat::shadowColor ( ) const

Definition at line 1455 of file KoTextFormat.cpp.

◆ shadowDistanceX()

double KoTextFormat::shadowDistanceX ( ) const
inline

Definition at line 251 of file KoTextFormat.h.

◆ shadowDistanceY()

double KoTextFormat::shadowDistanceY ( ) const
inline

Definition at line 252 of file KoTextFormat.h.

◆ shadowX()

int KoTextFormat::shadowX ( KoTextZoomHandler *  zh) const

Return the amount of pixels for the horizontal shadow distance at a given zoom level.

Definition at line 1463 of file KoTextFormat.cpp.

◆ shadowY()

int KoTextFormat::shadowY ( KoTextZoomHandler *  zh) const

Return the amount of pixels for the vertical shadow distance at a given zoom level.

Definition at line 1468 of file KoTextFormat.cpp.

◆ smallCapsFont()

TQFont KoTextFormat::smallCapsFont ( const KoTextZoomHandler *  zh,
bool  applyZoom 
) const

Definition at line 1170 of file KoTextFormat.cpp.

◆ strikeOut()

bool KoTextFormat::strikeOut ( ) const
inline

Definition at line 278 of file KoTextFormat.h.

◆ strikeOutStyle()

StrikeOutStyle KoTextFormat::strikeOutStyle ( ) const
inline

Definition at line 220 of file KoTextFormat.h.

◆ strikeOutStyleList()

TQStringList KoTextFormat::strikeOutStyleList ( )
static

Definition at line 1651 of file KoTextFormat.cpp.

◆ strikeOutStyleToString()

TQString KoTextFormat::strikeOutStyleToString ( KoTextFormat::StrikeOutStyle  _lineType)
static

Definition at line 1498 of file KoTextFormat.cpp.

◆ strikeOutType()

StrikeOutType KoTextFormat::strikeOutType ( ) const
inline

Definition at line 217 of file KoTextFormat.h.

◆ strikeOutTypeList()

TQStringList KoTextFormat::strikeOutTypeList ( )
static

Definition at line 1620 of file KoTextFormat.cpp.

◆ stringToAttributeFont()

KoTextFormat::AttributeStyle KoTextFormat::stringToAttributeFont ( const TQString &  _str)
static

Definition at line 1568 of file KoTextFormat.cpp.

◆ stringToStrikeOutStyle()

KoTextFormat::StrikeOutStyle KoTextFormat::stringToStrikeOutStyle ( const TQString &  _str)
static

Definition at line 1538 of file KoTextFormat.cpp.

◆ stringToUnderlineStyle()

KoTextFormat::UnderlineStyle KoTextFormat::stringToUnderlineStyle ( const TQString &  _str)
static

Definition at line 1522 of file KoTextFormat.cpp.

◆ style()

KoCharStyle * KoTextFormat::style ( ) const

Definition at line 1388 of file KoTextFormat.cpp.

◆ textBackgroundColor()

TQColor KoTextFormat::textBackgroundColor ( ) const
inline

Definition at line 224 of file KoTextFormat.h.

◆ textUnderlineColor()

TQColor KoTextFormat::textUnderlineColor ( ) const
inline

Definition at line 227 of file KoTextFormat.h.

◆ underline()

bool KoTextFormat::underline ( ) const
inline

Definition at line 277 of file KoTextFormat.h.

◆ underlineStyle()

UnderlineStyle KoTextFormat::underlineStyle ( ) const
inline

Definition at line 233 of file KoTextFormat.h.

◆ underlineStyleList()

TQStringList KoTextFormat::underlineStyleList ( )
static

Definition at line 1640 of file KoTextFormat.cpp.

◆ underlineStyleToString()

TQString KoTextFormat::underlineStyleToString ( KoTextFormat::UnderlineStyle  _lineType)
static

Definition at line 1474 of file KoTextFormat.cpp.

◆ underlineType()

UnderlineType KoTextFormat::underlineType ( ) const
inline

Definition at line 230 of file KoTextFormat.h.

◆ underlineTypeList()

TQStringList KoTextFormat::underlineTypeList ( )
static

Definition at line 1609 of file KoTextFormat.cpp.

◆ underLineWidth()

double KoTextFormat::underLineWidth ( ) const
inline

Definition at line 244 of file KoTextFormat.h.

◆ vAlign()

KoTextFormat::VerticalAlignment KoTextFormat::vAlign ( ) const
inline

Definition at line 469 of file KoTextFormat.h.

◆ waveUnderline()

bool KoTextFormat::waveUnderline ( ) const
inline

Definition at line 276 of file KoTextFormat.h.

◆ width()

int KoTextFormat::width ( const TQChar &  c) const

Return the width of one char (from a string, not necessarily from a paragraph) in LU pixels.

Do not call this for custom items, or for complex glyphs. But this can still be used for ' ' (for parag counters), 'x' (for tabs) etc.

Definition at line 1377 of file KoTextFormat.cpp.

◆ wordByWord()

bool KoTextFormat::wordByWord ( ) const
inline

Definition at line 272 of file KoTextFormat.h.

◆ zoomChanged()

void KoTextFormat::zoomChanged ( )

Called when the zoom or resolution changes.

Definition at line 48 of file KoTextFormat.cpp.

Friends And Related Symbol Documentation

◆ KoTextFormatCollection

friend class KoTextFormatCollection
friend

Definition at line 54 of file KoTextFormat.h.


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