Référence de la classe KoParagLayout

#include <KoParagLayout.h>

Graphe de collaboration de KoParagLayout:

[légende]
Liste de tous les membres

Types publics

enum  {
  Alignment = 1, BulletNumber = 2, Margins = 4, LineSpacing = 8,
  Borders = 16, Tabulator = 32, PageBreaking = 64, BackgroundColor = 128,
  All
}
enum  {
  BreakBetweenLines = 0, KeepLinesTogether = 1, HardFrameBreakBefore = 2, HardFrameBreakAfter = 4,
  KeepWithPrevious = 8, KeepWithNext = 16
}
enum  SpacingType {
  LS_SINGLE = 0, LS_ONEANDHALF = -1, LS_DOUBLE = -2, LS_CUSTOM = -3,
  LS_AT_LEAST = -4, LS_MULTIPLE = -5, LS_FIXED = -6
}

Fonctions membres publiques

 KoParagLayout ()
 KoParagLayout (const KoParagLayout &layout)
 ~KoParagLayout ()
double lineSpacingValue () const
void setLineSpacingValue (double _value)
bool hasBorder () const
void setTabList (const KoTabulatorList &tabList)
const KoTabulatorListtabList () const
void operator= (const KoParagLayout &)
 Assignment operator for KoParagLayout.
int compare (const KoParagLayout &layout) const
void saveParagLayout (QDomElement &parentElem, int alignment) const
void saveOasis (KoGenStyle &gs, KoSavingContext &context, bool savingStyle) const

Fonctions membres publiques statiques

static void loadParagLayout (KoParagLayout &layout, const QDomElement &parentElem, int docVersion=2)
static void loadOasisParagLayout (KoParagLayout &layout, KoOasisContext &context)
 Load this parag layout from Oasis XML.
static Qt::AlignmentFlag loadOasisAlignment (const QByteArray &str)
 Convert an alignment string into an alignment flag (load).
static QByteArray saveOasisAlignment (Qt::AlignmentFlag alignment)
 Convert an alignment flag into an alignment string (save).

Attributs publics

enum KoParagLayout:: { ... }  Flags
double margins [5]
SpacingType lineSpacingType
bool joinBorder:1
bool unused:7
char pageBreaking
char direction
char alignment
 Alignment flag (AlignAuto/AlignLeft/AlignRight/AlignJustify).
KoBorder leftBorder
KoBorder rightBorder
KoBorder topBorder
KoBorder bottomBorder
QColor backgroundColor
 The background color of the paragraph.
KoParagCountercounter
KoParagStylestyle

Attributs publics statiques

static QString * shadowCssCompat

Fonctions membres privées

void initialise ()

Fonctions membres privées statiques

static int getAttribute (const QDomElement &element, const char *attributeName, int defaultValue)
static double getAttribute (const QDomElement &element, const char *attributeName, double defaultValue)

Attributs privés

KoTabulatorList m_tabList
double lineSpacing
Private * d

Description détaillée

This class holds the paragraph-specific formatting information It's separated from KoTextParag so that it can be copied in the undo/redo history, and in KoParagStyle.

Définition à la ligne 41 du fichier KoParagLayout.h.


Documentation des énumérations membres

anonymous enum

This enum is used to mark parts of a KoParagLayout as changed (i.e. when changing them in the dialog/stylist)

Valeurs énumérées:
Alignment 
BulletNumber 
Margins 
LineSpacing 
Borders 
Tabulator 
PageBreaking 
BackgroundColor 
All 

Définition à la ligne 51 du fichier KoParagLayout.h.

anonymous enum

Page breaking flags

Valeurs énumérées:
BreakBetweenLines 
KeepLinesTogether 
HardFrameBreakBefore 
HardFrameBreakAfter 
KeepWithPrevious 
KeepWithNext 

Définition à la ligne 65 du fichier KoParagLayout.h.

enum KoParagLayout::SpacingType

Line spacing values Assuming h is the height of the biggest char in the line, and v is the linespacing value, the total line height is:

Single: h 1.5/2/multiple: v*h Custom (aka "line distance"): h + v At least: >= v Fixed: v

Valeurs énumérées:
LS_SINGLE 
LS_ONEANDHALF 
LS_DOUBLE 
LS_CUSTOM 
LS_AT_LEAST 
LS_MULTIPLE 
LS_FIXED 

Définition à la ligne 88 du fichier KoParagLayout.h.


Documentation des contructeurs et destructeur

KoParagLayout::KoParagLayout (  ) 

Définition à la ligne 46 du fichier KoParagLayout.cpp.

Références initialise().

Voici le graphe d'appel pour cette fonction :

KoParagLayout::KoParagLayout ( const KoParagLayout layout  )  [inline]

Définition à la ligne 45 du fichier KoParagLayout.h.

KoParagLayout::~KoParagLayout (  ) 

Définition à la ligne 143 du fichier KoParagLayout.cpp.


Documentation des fonctions membres

double KoParagLayout::lineSpacingValue (  )  const [inline]

Définition à la ligne 91 du fichier KoParagLayout.h.

Référencé par KoTextParag::calculateLineSpacing(), KoIndentSpacingWidget::display(), KoParagStyle::propagateChanges(), et KoTextParag::setParagLayout().

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::setLineSpacingValue ( double  _value  )  [inline]

Définition à la ligne 92 du fichier KoParagLayout.h.

Référencé par KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoIndentSpacingWidget::save(), KoTextParag::setLineSpacing(), et KoTextObject::setLineSpacingCommand().

Voici le graphe d'appel pour cette fonction :

bool KoParagLayout::hasBorder (  )  const [inline]

Définition à la ligne 118 du fichier KoParagLayout.h.

Référencé par KoTextParag::paint().

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::setTabList ( const KoTabulatorList tabList  )  [inline]

Définition à la ligne 123 du fichier KoParagLayout.h.

Référencé par loadOasisParagLayout(), loadParagLayout(), operator=(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoParagTabulatorsWidget::save(), KoTextParag::setTabList(), KoTextFormatInterface::setTabListCommand(), et KoTextObject::setTabListCommand().

Voici le graphe d'appel pour cette fonction :

const KoTabulatorList& KoParagLayout::tabList (  )  const [inline]

Définition à la ligne 124 du fichier KoParagLayout.h.

Référencé par KoParagTabulatorsWidget::display(), KoTextParag::drawParagStringInternal(), loadOasisParagLayout(), loadParagLayout(), KoTextParag::nextTab(), operator=(), KoTextParag::printRTDebug(), KoParagStyle::propagateChanges(), saveParagLayout(), et KoTextParag::setParagLayout().

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::operator= ( const KoParagLayout  ) 

Assignment operator for KoParagLayout.

Copy a paragraph layout.

If you're modifying this, you might also need to modify KoTextParag::setParagLayout

Définition à la ligne 51 du fichier KoParagLayout.cpp.

Références alignment, backgroundColor, bottomBorder, counter, direction, joinBorder, leftBorder, lineSpacing, lineSpacingType, margins, pageBreaking, rightBorder, setTabList(), style, tabList(), et topBorder.

Voici le graphe d'appel pour cette fonction :

int KoParagLayout::compare ( const KoParagLayout layout  )  const

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

Définition à la ligne 74 du fichier KoParagLayout.cpp.

Références Alignment, alignment, Margins, et margins.

Référencé par KoStyleDialog::apply(), et KoParagDia::changedFlags().

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::saveParagLayout ( QDomElement &  parentElem,
int  alignment 
) const

Save this parag layout to XML. This format is used by KWord for paragraphs, and by KPresenter+KWord for styles.

Définition à la ligne 665 du fichier KoParagLayout.cpp.

Références bottomBorder, counter, direction, KoUserStyle::displayName(), HardFrameBreakAfter, HardFrameBreakBefore, KeepLinesTogether, leftBorder, lineSpacing, lineSpacingType, LS_AT_LEAST, LS_CUSTOM, LS_DOUBLE, LS_FIXED, LS_MULTIPLE, LS_ONEANDHALF, LS_SINGLE, margins, KoParagCounter::NUM_NONE, KoParagCounter::numbering(), pageBreaking, KoBorder::penWidth(), rightBorder, KoParagCounter::save(), KoBorder::save(), style, T_DEC_PNT, tabList(), TF_BLANK, et topBorder.

Référencé par KoParagStyle::saveStyle().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::loadParagLayout ( KoParagLayout layout,
const QDomElement &  parentElem,
int  docVersion = 2 
) [static]

Load this parag layout from XML. This format is used by KWord for paragraphs, and by KPresenter+KWord for styles.

Définition à la ligne 148 du fichier KoParagLayout.cpp.

Références alignment, bottomBorder, counter, direction, getAttribute(), HardFrameBreakAfter, HardFrameBreakBefore, KeepLinesTogether, leftBorder, lineSpacing, lineSpacingType, KoParagCounter::load(), KoBorder::loadBorder(), LS_AT_LEAST, LS_CUSTOM, LS_DOUBLE, LS_FIXED, LS_MULTIPLE, LS_ONEANDHALF, LS_SINGLE, margins, pageBreaking, rightBorder, KoBorder::setPenWidth(), setTabList(), KoTextFormat::shadowAsCss(), shadowCssCompat, T_LEFT, tabList(), TF_BLANK, topBorder, Py::type(), et Py::value().

Référencé par KoParagStyle::loadStyle().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::loadOasisParagLayout ( KoParagLayout layout,
KoOasisContext context 
) [static]

Load this parag layout from Oasis XML.

Définition à la ligne 441 du fichier KoParagLayout.cpp.

Références KoTabulator::alignChar, alignment, KoStyleStack::attributeNS(), backgroundColor, bottomBorder, KoStyleStack::childNodeNS(), direction, KoTabulator::filling, KoXmlNS::fo, forEachElement, HardFrameBreakAfter, HardFrameBreakBefore, KoStyleStack::hasAttributeNS(), KoStyleStack::hasChildNodeNS(), joinBorder, KeepLinesTogether, KeepWithNext, leftBorder, lineSpacing, lineSpacingType, KoBorder::loadFoBorder(), loadOasisAlignment(), LS_AT_LEAST, LS_CUSTOM, LS_DOUBLE, LS_FIXED, LS_MULTIPLE, LS_ONEANDHALF, LS_SINGLE, margins, pageBreaking, KoUnit::parseValue(), KoTabulator::ptPos, KoTabulator::ptWidth, rightBorder, KoBorder::setPenWidth(), setTabList(), KoStyleStack::setTypeProperties(), KoXmlNS::style, KoOasisLoadingContext::styleStack(), T_CENTER, T_DEC_PNT, T_LEFT, T_RIGHT, tabList(), TF_BLANK, TF_DASH, TF_DASH_DOT, TF_DASH_DOT_DOT, TF_DOTS, TF_LINE, topBorder, KoTabulator::type, Py::type(), et Py::value().

Référencé par KoTextParag::loadParagLayout(), et KoParagStyle::loadStyle().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::saveOasis ( KoGenStyle gs,
KoSavingContext context,
bool  savingStyle 
) const

Save this parag layout to Oasis XML

Paramètres:
savingStyle true if this is saved as part of a user style, false when saving a paragraph
gs the style where all the properties will be saved to
context the current context

Définition à la ligne 811 du fichier KoParagLayout.cpp.

Références KoXmlWriter::addAttribute(), KoXmlWriter::addAttributePt(), KoGenStyle::addChildElement(), KoGenStyle::addProperty(), KoGenStyle::addPropertyPt(), alignment, backgroundColor, bottomBorder, direction, KoXmlWriter::endElement(), HardFrameBreakAfter, HardFrameBreakBefore, KoSavingContext::hasColumns(), joinBorder, KeepLinesTogether, KeepWithNext, leftBorder, lineSpacing, lineSpacingType, LS_AT_LEAST, LS_CUSTOM, LS_DOUBLE, LS_FIXED, LS_MULTIPLE, LS_ONEANDHALF, LS_SINGLE, m_tabList, margins, pageBreaking, KoBorder::penWidth(), gensymbolfontmap::pos, rightBorder, KoBorder::saveFoBorder(), saveOasisAlignment(), KoXmlWriter::startElement(), T_CENTER, T_DEC_PNT, T_INVALID, T_LEFT, T_RIGHT, TF_BLANK, TF_DASH, TF_DASH_DOT, TF_DASH_DOT_DOT, TF_DOTS, TF_LINE, et topBorder.

Référencé par KoTextParag::saveOasis(), et KoParagStyle::saveStyle().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

Qt::AlignmentFlag KoParagLayout::loadOasisAlignment ( const QByteArray &  str  )  [static]

Convert an alignment string into an alignment flag (load).

Définition à la ligne 418 du fichier KoParagLayout.cpp.

Référencé par loadOasisParagLayout().

Voici le graphe d'appel pour cette fonction :

QByteArray KoParagLayout::saveOasisAlignment ( Qt::AlignmentFlag  alignment  )  [static]

Convert an alignment flag into an alignment string (save).

Définition à la ligne 432 du fichier KoParagLayout.cpp.

Référencé par saveOasis(), et KoParagCounter::saveOasisListLevel().

Voici le graphe d'appel pour cette fonction :

static int KoParagLayout::getAttribute ( const QDomElement &  element,
const char *  attributeName,
int  defaultValue 
) [inline, static, private]

Définition à la ligne 162 du fichier KoParagLayout.h.

Références Py::value().

Référencé par loadParagLayout().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :

static double KoParagLayout::getAttribute ( const QDomElement &  element,
const char *  attributeName,
double  defaultValue 
) [inline, static, private]

Définition à la ligne 167 du fichier KoParagLayout.h.

Références Py::value().

Voici le graphe d'appel pour cette fonction :

void KoParagLayout::initialise (  )  [private]

Common setup.

Définition à la ligne 124 du fichier KoParagLayout.cpp.

Références alignment, bottomBorder, direction, joinBorder, leftBorder, lineSpacing, lineSpacingType, LS_SINGLE, m_tabList, margins, pageBreaking, rightBorder, KoBorder::setPenWidth(), style, et topBorder.

Référencé par KoParagLayout().

Voici le graphe d'appel pour cette fonction :

Voici le graphe d'appel pour cette fonction :


Documentation des données membres

enum { ... } KoParagLayout::Flags

This enum is used to mark parts of a KoParagLayout as changed (i.e. when changing them in the dialog/stylist)

double KoParagLayout::margins[5]

left, right, top, bottom, firstLineSpacing - in pt

Définition à la ligne 76 du fichier KoParagLayout.h.

Référencé par KoTextParag::applyListStyle(), KoTextParag::bottomMargin(), KoTextParag::breakableTopMargin(), compare(), KoIndentSpacingWidget::display(), KoTextParagCommand::execute(), KoTextParag::firstLineMargin(), initialise(), KoTextParag::leftMargin(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoTextParag::rightMargin(), KoIndentSpacingWidget::save(), saveOasis(), saveParagLayout(), KoTextParag::setMargin(), KoTextFormatInterface::setMarginCommand(), KoTextObject::setMarginCommand(), KoTextParag::setMargins(), KoTextParag::setParagLayout(), et KoTextParag::topMargin().

SpacingType KoParagLayout::lineSpacingType

Définition à la ligne 90 du fichier KoParagLayout.h.

Référencé par KoTextParag::calculateLineSpacing(), KoIndentSpacingWidget::display(), initialise(), KoTextParag::lineSpacing(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoIndentSpacingWidget::save(), saveOasis(), saveParagLayout(), KoTextObject::setLineSpacingCommand(), KoTextParag::setLineSpacingType(), et KoTextParag::setParagLayout().

QString * KoParagLayout::shadowCssCompat [static]

Définition à la ligne 94 du fichier KoParagLayout.h.

Référencé par loadParagLayout().

bool KoParagLayout::joinBorder

Définition à la ligne 96 du fichier KoParagLayout.h.

Référencé par KoParagDecorationWidget::display(), initialise(), loadOasisParagLayout(), operator=(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoParagDecorationWidget::save(), saveOasis(), KoTextParag::setJoinBorder(), KoTextObject::setJoinBordersCommand(), et KoTextParag::setParagLayout().

bool KoParagLayout::unused

Définition à la ligne 97 du fichier KoParagLayout.h.

char KoParagLayout::pageBreaking

Définition à la ligne 98 du fichier KoParagLayout.h.

Référencé par KoTextParag::copyParagData(), KoParagAlignWidget::display(), initialise(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoParagDia::paragLayout(), KoTextParag::printRTDebug(), KoParagAlignWidget::save(), saveOasis(), et saveParagLayout().

char KoParagLayout::direction

Définition à la ligne 99 du fichier KoParagLayout.h.

Référencé par initialise(), loadOasisParagLayout(), loadParagLayout(), operator=(), saveOasis(), saveParagLayout(), KoTextParag::setDirection(), KoTextObject::setParagDirectionCommand(), et KoTextParag::setParagLayout().

char KoParagLayout::alignment

Alignment flag (AlignAuto/AlignLeft/AlignRight/AlignJustify).

Définition à la ligne 101 du fichier KoParagLayout.h.

Référencé par compare(), KoParagAlignWidget::display(), initialise(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoParagDia::paragLayout(), KoStyleCollection::printDebug(), KoParagStyle::propagateChanges(), KoTextParag::resolveAlignment(), KoParagAlignWidget::save(), saveOasis(), KoParagStyle::saveStyle(), KoTextParag::setAlign(), KoTextFormatInterface::setAlignCommand(), KoTextObject::setAlignCommand(), et KoTextParag::setParagLayout().

KoBorder KoParagLayout::leftBorder

Définition à la ligne 102 du fichier KoParagLayout.h.

Référencé par KoTextParag::bottomMargin(), KoParagDecorationWidget::display(), initialise(), KoTextParag::leftMargin(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoTextParag::paint(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoParagDecorationWidget::save(), saveOasis(), saveParagLayout(), KoTextObject::setBordersCommand(), KoTextParag::setParagLayout(), et KoTextParag::topMargin().

KoBorder KoParagLayout::rightBorder

Définition à la ligne 102 du fichier KoParagLayout.h.

Référencé par KoTextParag::bottomMargin(), KoParagDecorationWidget::display(), initialise(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoTextParag::paint(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoTextParag::rightMargin(), KoParagDecorationWidget::save(), saveOasis(), saveParagLayout(), KoTextObject::setBordersCommand(), KoTextParag::setParagLayout(), et KoTextParag::topMargin().

KoBorder KoParagLayout::topBorder

Définition à la ligne 102 du fichier KoParagLayout.h.

Référencé par KoTextParag::bottomMargin(), KoParagDecorationWidget::display(), KoTextParagCommand::execute(), initialise(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoTextParag::paint(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoParagDecorationWidget::save(), saveOasis(), saveParagLayout(), KoTextObject::setBordersCommand(), KoTextParag::setParagLayout(), KoTextParag::setTopBorder(), et KoTextParag::topMargin().

KoBorder KoParagLayout::bottomBorder

Définition à la ligne 102 du fichier KoParagLayout.h.

Référencé par KoTextParag::bottomMargin(), KoParagDecorationWidget::display(), KoTextParagCommand::execute(), initialise(), loadOasisParagLayout(), loadParagLayout(), operator=(), KoTextParag::paint(), KoParagDia::paragLayout(), KoParagStyle::propagateChanges(), KoParagDecorationWidget::save(), saveOasis(), saveParagLayout(), KoTextObject::setBordersCommand(), KoTextParag::setBottomBorder(), KoTextParag::setParagLayout(), et KoTextParag::topMargin().

QColor KoParagLayout::backgroundColor

The background color of the paragraph.

The background color is used for text that has no background color set, and for parts of the paragraph that are not covered by text. In theory anyway: the background color isn't used in rendering text yet, but it's nice to preserve the value.

Définition à la ligne 111 du fichier KoParagLayout.h.

Référencé par KoParagDecorationWidget::display(), loadOasisParagLayout(), operator=(), KoParagDia::paragLayout(), KoParagDecorationWidget::save(), saveOasis(), KoTextParag::setBackgroundColor(), KoTextObject::setBackgroundColorCommand(), et KoTextParag::setParagLayout().

KoParagCounter* KoParagLayout::counter

can be 0 if no counter set

Définition à la ligne 114 du fichier KoParagLayout.h.

Référencé par KoTextParag::applyListStyle(), KoTextParag::copyParagData(), KoTextParag::counter(), KoTextParag::counterWidth(), KoParagCounterWidget::display(), KoCounterStyleWidget::display(), KoTextParag::drawLabel(), KoTextParag::invalidateCounters(), KoParagDia::isCounterChanged(), loadParagLayout(), KoParagStyle::loadStyle(), KoStyleCollection::numberedStyleForLevel(), operator=(), KoStyleCollection::outlineStyleForLevel(), KoTextParag::paint(), KoParagDia::paragLayout(), KoStyleCollection::printDebug(), KoTextParag::printRTDebug(), KoParagStyle::propagateChanges(), KoTextDocument::removeSelectedText(), KoTextParag::rightMargin(), KoParagCounterWidget::save(), KoTextParag::saveOasis(), saveParagLayout(), KoParagStyle::saveStyle(), KoTextParag::setCounter(), KoTextFormatInterface::setCounterCommand(), KoTextObject::setCounterCommand(), KoTextParag::setNoCounter(), KoTextParag::setParagLayout(), et KoTextParag::toString().

KoParagStyle* KoParagLayout::style

Définition à la ligne 116 du fichier KoParagLayout.h.

Référencé par KoTextParag::counter(), KoParagCounterWidget::display(), KoTextParag::drawLabel(), initialise(), KoParagStyle::KoParagStyle(), KoTextParag::loadParagLayout(), KoParagStyle::loadStyle(), KoParagStyle::operator=(), operator=(), KoTextParag::saveOasis(), saveParagLayout(), KoTextParag::setCounter(), KoTextParag::setParagLayout(), et KoTextView::updateStyleFromSelection().

KoTabulatorList KoParagLayout::m_tabList [private]

Définition à la ligne 173 du fichier KoParagLayout.h.

Référencé par initialise(), et saveOasis().

double KoParagLayout::lineSpacing [private]

Définition à la ligne 174 du fichier KoParagLayout.h.

Référencé par initialise(), loadOasisParagLayout(), loadParagLayout(), operator=(), saveOasis(), et saveParagLayout().

Private* KoParagLayout::d [private]

Définition à la ligne 175 du fichier KoParagLayout.h.


La documentation de cette classe a été générée à partir des fichiers suivants :
Généré le Wed Nov 22 23:47:19 2006 pour KPlato par  doxygen 1.5.1-p1