pageitem_textframe.cpp File Reference
#include <QPolygon>#include <QList>#include <QMatrix>#include <QPoint>#include <QRegion>#include <QPalette>#include <cmath>#include <cassert>#include "canvas.h"#include "commonstrings.h"#include "guidemanager.h"#include "hyphenator.h"#include "page.h"#include "pageitem.h"#include "pageitem_textframe.h"#include "prefsmanager.h"#include "scconfig.h"#include "scpainter.h"#include "scpaths.h"#include "scraction.h"#include "scribus.h"#include "scribusdoc.h"#include "scribusstructs.h"#include "selection.h"#include "text/nlsconfig.h"#include "undomanager.h"#include "undostate.h"#include "util.h"#include "util_math.h"

Go to the source code of this file.
Classes | |
| struct | TabControl |
| struct | LineControl |
Enumerations | |
| enum | TabStatus { TabNONE = 0, TabLEFT = TabNONE, TabRIGHT = 1, TabPOINT = 2, TabCOMMA = 3, TabCENTER = 4 } |
Functions | |
| static QRegion | itemShape (PageItem *docItem, double xOffset, double yOffset) |
| static void | dumpIt (const ParagraphStyle &pstyle, QString indent=QString("->")) |
| static void | fillInTabLeaders (StoryText &itemText, LineSpec &curLine) |
| static void | justifyLine (StoryText &itemText, LineSpec &line) |
| called when line length is known and line is to be justified | |
| static void | indentLine (StoryText &itemText, LineSpec &line, double leftIndent) |
| called when linelength is known and line is not justified | |
| static double | opticalLeftMargin (const StoryText &itemText, const LineSpec &line) |
| calculate how much the first char should stick out to the left | |
| static double | opticalRightMargin (const StoryText &itemText, const LineSpec &line) |
| calculate how much the last char should stick out to the right | |
Variables | |
| static const bool | legacy = true |
Enumeration Type Documentation
| enum TabStatus |
Definition at line 289 of file pageitem_textframe.cpp.
Function Documentation
| static void dumpIt | ( | const ParagraphStyle & | pstyle, | |
| QString | indent = QString("->") | |||
| ) | [static] |
Definition at line 222 of file pageitem_textframe.cpp.
References Style::hasParent(), Style::name(), Style::parent(), and Style::parentStyle().
Clones the tab fill char as often as necssary after all distances are known
Definition at line 252 of file pageitem_textframe.cpp.
References ScText::ch, StoryText::charStyle(), LineSpec::firstItem, GlyphLayout::glyph, ScText::glyph, GlyphLayout::grow(), StoryText::item(), LineSpec::lastItem, GlyphLayout::more, GlyphLayout::scaleV, SpecialChars::TAB, GlyphLayout::wide(), LineSpec::x, GlyphLayout::xadvance, GlyphLayout::xoffset, and PageItem::xPos().
Referenced by PageItem_TextFrame::layout().
called when linelength is known and line is not justified
Definition at line 641 of file pageitem_textframe.cpp.
References justifyLine(), LineSpec::naturalWidth, LineSpec::width, and LineSpec::x.
Referenced by PageItem_TextFrame::layout().
| static QRegion itemShape | ( | PageItem * | docItem, | |
| double | xOffset, | |||
| double | yOffset | |||
| ) | [static] |
Definition at line 70 of file pageitem_textframe.cpp.
References PageItem::Clip, PageItem::ContourLine, FlattenPath(), PageItem::height, PageItem::imageClip, PageItem::rotation, FPointArray::size(), PageItem::textFlowUsesBoundingBox(), PageItem::textFlowUsesContourLine(), PageItem::textFlowUsesImageClipping(), PageItem::width, PageItem::xPos, and PageItem::yPos.
Referenced by PageItem_TextFrame::availableRegion().
called when line length is known and line is to be justified
Definition at line 564 of file pageitem_textframe.cpp.
References CharStyle::effects(), LineSpec::firstItem, ScText::glyph, SpecialChars::isExpandingSpace(), StoryText::item(), GlyphLayout::last(), LineSpec::lastItem, GlyphLayout::more, StoryText::paragraphStyle(), GlyphLayout::scaleH, ScStyle_SuppressSpace, StoryText::text(), GlyphLayout::wide(), LineSpec::width, GlyphLayout::xadvance, and GlyphLayout::xoffset.
Referenced by indentLine(), and PageItem_TextFrame::layout().
calculate how much the first char should stick out to the left
Definition at line 655 of file pageitem_textframe.cpp.
References StoryText::charStyle(), CharStyle::effects(), LineSpec::firstItem, CharStyle::font, StoryText::item(), LineSpec::lastItem, ScStyle_SuppressSpace, and StoryText::text().
Referenced by PageItem_TextFrame::layout().
calculate how much the last char should stick out to the right
Definition at line 695 of file pageitem_textframe.cpp.
References StoryText::charStyle(), CharStyle::effects(), LineSpec::firstItem, CharStyle::font, SpecialChars::isBreak(), SpecialChars::isBreakingSpace(), StoryText::item(), LineSpec::lastItem, ScStyle_SmartHyphenVisible, and StoryText::text().
Referenced by PageItem_TextFrame::layout().
Variable Documentation
const bool legacy = true [static] |
Definition at line 241 of file pageitem_textframe.cpp.
