QXPTypes.h
Go to the documentation of this file.
/* -*- Mode: C++; tab-width: 2; indent-tabs-mode: nil; c-basic-offset: 2 -*- */
/*
* This file is part of the libqxp project.
*
* This Source Code Form is subject to the terms of the Mozilla Public
* License, v. 2.0. If a copy of the MPL was not distributed with this
* file, You can obtain one at http://mozilla.org/MPL/2.0/.
*/
#ifndef QXPTYPES_H_INCLUDED
#define QXPTYPES_H_INCLUDED
#include "libqxp_utils.h"
#include <boost/optional.hpp>
#include <boost/variant.hpp>
#include <memory>
#include <vector>
#include <utility>
namespace libqxp
{
struct Point
{
double x;
double y;
Point()
: x(0.0), y(0.0)
{ }
Point(double xVal, double yVal)
: x(xVal), y(yVal)
{ }
Point move(double dx, double dy) const;
Point rotateDeg(double rotationDeg, const Point &center) const;
double distance(const Point &p2) const;
};
bool operator==(const Point &lhs, const Point &rhs);
bool operator!=(const Point &lhs, const Point &rhs);
struct Rect
{
double top;
double right;
double bottom;
double left;
Rect();
Rect(double t, double r, double b, double l);
double width() const;
double height() const;
Point center() const;
Point topLeft() const;
Point topRight() const;
Point bottomRight() const;
Point bottomLeft() const;
Rect shrink(const double diff) const;
};
struct Color
{
uint8_t red;
uint8_t green;
uint8_t blue;
Color()
: red(0), green(0), blue(0)
{ }
Color(uint8_t r, uint8_t g, uint8_t b)
: red(r), green(g), blue(b)
{ }
librevenge::RVNGString toString() const;
Color applyShade(double shade) const;
};
enum class GradientType
{
LINEAR,
MIDLINEAR,
RECTANGULAR,
DIAMOND,
CIRCULAR,
FULLCIRCULAR
};
struct Gradient
{
GradientType type;
Color color1;
Color color2;
double angle;
Gradient()
: type(), color1(), color2(), angle(0.0)
{ }
};
typedef boost::variant<Color, Gradient> Fill;
enum class LineCapType
{
BUTT,
ROUND,
RECT,
STRETCH
};
enum class LineJoinType
{
MITER,
ROUND,
BEVEL
};
struct LineStyle
{
std::vector<double> segmentLengths;
bool isStripe;
bool isProportional;
double patternLength;
LineCapType endcapType;
LineJoinType joinType;
LineStyle()
: segmentLengths(), isStripe(false), isProportional(true), patternLength(6.0), endcapType(LineCapType::BUTT), joinType(LineJoinType::MITER)
{ }
LineStyle(std::vector<double> segments, bool proportional, double pattern, LineCapType endcap, LineJoinType join)
: segmentLengths(std::move(segments)), isStripe(false), isProportional(proportional), patternLength(pattern), endcapType(endcap), joinType(join)
{ }
};
struct CharFormat
{
librevenge::RVNGString fontName;
double fontSize;
double baselineShift;
Color color;
bool bold;
bool italic;
bool underline;
bool outline;
bool shadow;
bool superscript;
bool subscript;
bool superior;
bool strike;
bool allCaps;
bool smallCaps;
bool wordUnderline;
bool isControlChars;
CharFormat()
: fontName("Arial"), fontSize(12.0), baselineShift(0.0), color(0, 0, 0),
bold(false), italic(false), underline(false), outline(false), shadow(false), superscript(false), subscript(false), superior(false),
strike(false), allCaps(false), smallCaps(false), wordUnderline(false),
isControlChars(false)
{ }
};
struct HJ
{
HJ()
: hyphenate(true)
, minBefore(3)
, minAfter(2)
, maxInRow(0)
, singleWordJustify(true)
{
}
bool hyphenate;
unsigned minBefore;
unsigned minAfter;
unsigned maxInRow;
bool singleWordJustify;
};
enum class HorizontalAlignment
{
LEFT,
CENTER,
RIGHT,
JUSTIFIED,
FORCED
};
enum class VerticalAlignment
{
TOP,
CENTER,
BOTTOM,
JUSTIFIED
};
enum class TabStopType
{
LEFT,
CENTER,
RIGHT,
ALIGN
};
struct TabStop
{
TabStopType type;
double position;
librevenge::RVNGString fillChar;
librevenge::RVNGString alignChar;
bool isDefined() const
{
return position >= 0;
}
TabStop()
: type(TabStopType::LEFT), position(0.0), fillChar(), alignChar()
{ }
};
struct ParagraphRule
{
double width;
Color color;
const LineStyle *lineStyle;
double leftMargin;
double rightMargin;
double offset;
ParagraphRule()
: width(1.0), color(0, 0, 0), lineStyle(nullptr), leftMargin(0), rightMargin(0), offset(0)
{ }
};
struct ParagraphFormat
{
HorizontalAlignment alignment;
Rect margin;
double firstLineIndent;
double leading;
bool incrementalLeading;
std::shared_ptr<ParagraphRule> ruleAbove;
std::shared_ptr<ParagraphRule> ruleBelow;
std::vector<TabStop> tabStops;
std::shared_ptr<HJ> hj;
ParagraphFormat()
: alignment(HorizontalAlignment::LEFT), margin(), firstLineIndent(0), leading(0), incrementalLeading(false),
ruleAbove(nullptr), ruleBelow(nullptr), tabStops(), hj(nullptr)
{ }
};
enum class ContentType
{
UNKNOWN,
OBJECTS, // group
NONE,
TEXT,
PICTURE
};
struct TextSpec
{
const unsigned startIndex;
const unsigned length;
unsigned endIndex() const
{
return startIndex + length - 1;
}
unsigned afterEndIndex() const
{
return startIndex + length;
}
bool overlaps(const TextSpec &other) const;
protected:
TextSpec(unsigned start, unsigned len)
: startIndex(start), length(len)
{ }
};
struct CharFormatSpec : public TextSpec
{
std::shared_ptr<CharFormat> format;
CharFormatSpec(const std::shared_ptr<CharFormat> &f, unsigned start, unsigned len)
: TextSpec(start, len), format(f)
{ }
};
struct ParagraphSpec : public TextSpec
{
std::shared_ptr<ParagraphFormat> format;
ParagraphSpec(const std::shared_ptr<ParagraphFormat> &f, unsigned start, unsigned len)
: TextSpec(start, len), format(f)
{ }
};
struct Text
{
std::string text;
const char *encoding;
std::vector<ParagraphSpec> paragraphs;
std::vector<CharFormatSpec> charFormats;
double maxFontSize() const;
double maxFontSize(const ParagraphSpec &paragraph) const;
Text()
: text(), encoding("cp1252"), paragraphs(), charFormats()
{ }
Text(const Text &other) = default;
Text &operator=(const Text &other) = default;
};
struct Arrow
{
const std::string path;
const std::string viewbox;
const double scale;
explicit Arrow(const std::string &d, const std::string &vbox = "0 0 10 10", double s = 3)
: path(d), viewbox(vbox), scale(s)
{ }
};
struct Frame
{
double width;
boost::optional<Color> color;
boost::optional<Color> gapColor;
const LineStyle *lineStyle;
const Arrow *startArrow;
const Arrow *endArrow;
Frame()
: width(1.0), color(), gapColor(), lineStyle(nullptr), startArrow(nullptr), endArrow(nullptr)
{ }
Frame(const Frame &other) = default;
Frame &operator=(const Frame &other) = default;
};
struct LinkedTextSettings
{
unsigned linkId;
unsigned offsetIntoText;
unsigned linkedIndex;
unsigned nextLinkedIndex;
boost::optional<unsigned> textLength;
LinkedTextSettings()
: linkId(0), offsetIntoText(0), linkedIndex(0), nextLinkedIndex(0), textLength()
{ }
};
struct TextObject
{
LinkedTextSettings linkSettings;
boost::optional<std::shared_ptr<Text>> text;
TextObject()
: linkSettings(), text()
{ }
bool isLinked() const;
};
struct TextSettings
{
unsigned columnsCount;
double gutterWidth;
VerticalAlignment verticalAlignment;
Rect inset;
double rotation;
double skew;
TextSettings()
: columnsCount(1), gutterWidth(12.0), verticalAlignment(VerticalAlignment::TOP), inset(), rotation(0), skew(0)
{ }
};
enum class TextPathAlignment
{
ASCENT,
CENTER,
BASELINE,
DESCENT
};
enum class TextPathLineAlignment
{
TOP,
CENTER,
BOTTOM
};
struct TextPathSettings
{
bool rotate;
bool skew;
TextPathAlignment alignment;
TextPathLineAlignment lineAlignment;
TextPathSettings()
: rotate(false), skew(false), alignment(TextPathAlignment::BASELINE), lineAlignment(TextPathLineAlignment::TOP)
{ }
};
struct CurveComponent
{
Rect boundingBox;
std::vector<Point> points;
CurveComponent()
: boundingBox(), points()
{ }
};
struct Object
{
Rect boundingBox;
bool runaround; // we probably don't need other runaround properties because ODF doesn't support them
unsigned zIndex;
protected:
Object()
: boundingBox(), runaround(false), zIndex(0)
{ }
};
struct Line : Object
{
double rotation;
Frame style;
std::vector<CurveComponent> curveComponents;
Line()
: rotation(0), style(), curveComponents()
{ }
};
struct TextPath : Line, TextObject
{
TextPathSettings settings;
TextPath()
: settings()
{ }
};
enum class CornerType
{
DEFAULT,
ROUNDED,
BEVELED,
CONCAVE
};
enum class BoxType
{
UNKNOWN,
RECTANGLE,
OVAL,
POLYGON,
BEZIER
};
struct Box : Object
{
boost::optional<Fill> fill;
Frame frame;
BoxType boxType;
CornerType cornerType;
double cornerRadius;
double rotation;
std::vector<Point> customPoints;
std::vector<CurveComponent> curveComponents;
Box()
: fill(), frame(), boxType(BoxType::UNKNOWN), cornerType(CornerType::DEFAULT), cornerRadius(0.0), rotation(0),
customPoints(), curveComponents()
{ }
};
struct TextBox : Box, TextObject
{
TextSettings settings;
TextBox()
: settings()
{ }
};
struct PictureBox : Box
{
double pictureRotation;
double pictureSkew;
double offsetLeft;
double offsetTop;
double scaleHor;
double scaleVert;
PictureBox()
: pictureRotation(0.0), pictureSkew(0.0),
offsetLeft(0.0), offsetTop(0.0), scaleHor(0.0), scaleVert(0.0)
{ }
};
struct Group : Object
{
std::vector<unsigned> objectsIndexes;
Group()
: objectsIndexes()
{ }
};
struct PageSettings
{
Rect offset;
PageSettings()
: offset()
{ }
};
struct Page
{
std::vector<PageSettings> pageSettings;
unsigned objectsCount;
Page()
: pageSettings(), objectsCount(0)
{ }
bool isFacing() const
{
return pageSettings.size() == 2;
}
};
struct QXPDocumentProperties
{
QXPDocumentProperties()
: superscriptOffset(1.0 / 3)
, superscriptHScale(1.0)
, superscriptVScale(1.0)
, subscriptOffset(-1.0 / 3)
, subscriptHScale(1.0)
, subscriptVScale(1.0)
, superiorHScale(0.5)
, superiorVScale(0.5)
, m_autoLeading(0.2)
{
}
double superscriptOffset;
double superscriptHScale;
double superscriptVScale;
double subscriptOffset;
double subscriptHScale;
double subscriptVScale;
double superiorHScale;
double superiorVScale;
void setAutoLeading(const double val);
double autoLeading() const;
// there should be a flag to detect this...
bool isIncrementalAutoLeading() const
{
return autoLeading() < 0 || autoLeading() > 1;
}
private:
double m_autoLeading;
};
}
#endif // QXPTYPES_H_INCLUDED
/* vim:set shiftwidth=2 softtabstop=2 expandtab: */
libqxp_utils.h
libqxp
Definition libqxp_utils.cpp:25
libqxp::VerticalAlignment
VerticalAlignment
Definition QXPTypes.h:201
libqxp::VerticalAlignment::BOTTOM
@ BOTTOM
Definition QXPTypes.h:204
libqxp::VerticalAlignment::TOP
@ TOP
Definition QXPTypes.h:202
libqxp::LineJoinType
LineJoinType
Definition QXPTypes.h:120
libqxp::LineJoinType::MITER
@ MITER
Definition QXPTypes.h:121
libqxp::LineJoinType::BEVEL
@ BEVEL
Definition QXPTypes.h:123
libqxp::TextPathLineAlignment
TextPathLineAlignment
Definition QXPTypes.h:409
libqxp::operator!=
bool operator!=(const Point &lhs, const Point &rhs)
Definition QXPTypes.cpp:23
libqxp::TextPathAlignment
TextPathAlignment
Definition QXPTypes.h:401
libqxp::TextPathAlignment::DESCENT
@ DESCENT
Definition QXPTypes.h:405
libqxp::TextPathAlignment::BASELINE
@ BASELINE
Definition QXPTypes.h:404
libqxp::TextPathAlignment::ASCENT
@ ASCENT
Definition QXPTypes.h:402
libqxp::CornerType
CornerType
Definition QXPTypes.h:470
libqxp::CornerType::DEFAULT
@ DEFAULT
Definition QXPTypes.h:471
libqxp::CornerType::BEVELED
@ BEVELED
Definition QXPTypes.h:473
libqxp::CornerType::CONCAVE
@ CONCAVE
Definition QXPTypes.h:474
libqxp::CornerType::ROUNDED
@ ROUNDED
Definition QXPTypes.h:472
libqxp::Fill
boost::variant< Color, Gradient > Fill
Definition QXPTypes.h:109
libqxp::BoxType
BoxType
Definition QXPTypes.h:478
libqxp::BoxType::RECTANGLE
@ RECTANGLE
Definition QXPTypes.h:480
libqxp::BoxType::OVAL
@ OVAL
Definition QXPTypes.h:481
libqxp::BoxType::POLYGON
@ POLYGON
Definition QXPTypes.h:482
libqxp::BoxType::BEZIER
@ BEZIER
Definition QXPTypes.h:483
libqxp::UNKNOWN
@ UNKNOWN
Definition QXPHeader.h:24
libqxp::operator==
bool operator==(const Point &lhs, const Point &rhs)
Definition QXPTypes.cpp:18
libqxp::LineCapType
LineCapType
Definition QXPTypes.h:112
libqxp::LineCapType::RECT
@ RECT
Definition QXPTypes.h:115
libqxp::LineCapType::ROUND
@ ROUND
Definition QXPTypes.h:114
libqxp::LineCapType::STRETCH
@ STRETCH
Definition QXPTypes.h:116
libqxp::LineCapType::BUTT
@ BUTT
Definition QXPTypes.h:113
libqxp::ContentType
ContentType
Definition QXPTypes.h:266
libqxp::ContentType::PICTURE
@ PICTURE
Definition QXPTypes.h:271
libqxp::ContentType::OBJECTS
@ OBJECTS
Definition QXPTypes.h:268
libqxp::ContentType::TEXT
@ TEXT
Definition QXPTypes.h:270
libqxp::ContentType::NONE
@ NONE
Definition QXPTypes.h:269
libqxp::HorizontalAlignment
HorizontalAlignment
Definition QXPTypes.h:192
libqxp::HorizontalAlignment::RIGHT
@ RIGHT
Definition QXPTypes.h:195
libqxp::HorizontalAlignment::JUSTIFIED
@ JUSTIFIED
Definition QXPTypes.h:196
libqxp::HorizontalAlignment::LEFT
@ LEFT
Definition QXPTypes.h:193
libqxp::HorizontalAlignment::FORCED
@ FORCED
Definition QXPTypes.h:197
libqxp::HorizontalAlignment::CENTER
@ CENTER
Definition QXPTypes.h:194
libqxp::GradientType
GradientType
Definition QXPTypes.h:88
libqxp::GradientType::FULLCIRCULAR
@ FULLCIRCULAR
Definition QXPTypes.h:94
libqxp::GradientType::MIDLINEAR
@ MIDLINEAR
Definition QXPTypes.h:90
libqxp::GradientType::DIAMOND
@ DIAMOND
Definition QXPTypes.h:92
libqxp::GradientType::RECTANGULAR
@ RECTANGULAR
Definition QXPTypes.h:91
libqxp::GradientType::CIRCULAR
@ CIRCULAR
Definition QXPTypes.h:93
libqxp::GradientType::LINEAR
@ LINEAR
Definition QXPTypes.h:89
libqxp::TabStopType
TabStopType
Definition QXPTypes.h:209
libqxp::TabStopType::ALIGN
@ ALIGN
Definition QXPTypes.h:213
libqxp::Arrow
Definition QXPTypes.h:334
libqxp::Arrow::path
const std::string path
Definition QXPTypes.h:335
libqxp::Arrow::viewbox
const std::string viewbox
Definition QXPTypes.h:336
libqxp::Arrow::scale
const double scale
Definition QXPTypes.h:337
libqxp::Arrow::Arrow
Arrow(const std::string &d, const std::string &vbox="0 0 10 10", double s=3)
Definition QXPTypes.h:339
libqxp::Box::curveComponents
std::vector< CurveComponent > curveComponents
Definition QXPTypes.h:495
libqxp::Box::rotation
double rotation
Definition QXPTypes.h:493
libqxp::Box::fill
boost::optional< Fill > fill
Definition QXPTypes.h:488
libqxp::Box::frame
Frame frame
Definition QXPTypes.h:489
libqxp::Box::customPoints
std::vector< Point > customPoints
Definition QXPTypes.h:494
libqxp::Box::cornerType
CornerType cornerType
Definition QXPTypes.h:491
libqxp::Box::Box
Box()
Definition QXPTypes.h:497
libqxp::Box::boxType
BoxType boxType
Definition QXPTypes.h:490
libqxp::Box::cornerRadius
double cornerRadius
Definition QXPTypes.h:492
libqxp::CharFormatSpec::CharFormatSpec
CharFormatSpec(const std::shared_ptr< CharFormat > &f, unsigned start, unsigned len)
Definition QXPTypes.h:301
libqxp::CharFormatSpec::format
std::shared_ptr< CharFormat > format
Definition QXPTypes.h:299
libqxp::CharFormat::strike
bool strike
Definition QXPTypes.h:158
libqxp::CharFormat::allCaps
bool allCaps
Definition QXPTypes.h:159
libqxp::CharFormat::color
Color color
Definition QXPTypes.h:149
libqxp::CharFormat::shadow
bool shadow
Definition QXPTypes.h:154
libqxp::CharFormat::italic
bool italic
Definition QXPTypes.h:151
libqxp::CharFormat::underline
bool underline
Definition QXPTypes.h:152
libqxp::CharFormat::bold
bool bold
Definition QXPTypes.h:150
libqxp::CharFormat::fontName
librevenge::RVNGString fontName
Definition QXPTypes.h:146
libqxp::CharFormat::wordUnderline
bool wordUnderline
Definition QXPTypes.h:161
libqxp::CharFormat::baselineShift
double baselineShift
Definition QXPTypes.h:148
libqxp::CharFormat::CharFormat
CharFormat()
Definition QXPTypes.h:165
libqxp::CharFormat::fontSize
double fontSize
Definition QXPTypes.h:147
libqxp::CharFormat::outline
bool outline
Definition QXPTypes.h:153
libqxp::CharFormat::smallCaps
bool smallCaps
Definition QXPTypes.h:160
libqxp::CharFormat::subscript
bool subscript
Definition QXPTypes.h:156
libqxp::CharFormat::isControlChars
bool isControlChars
Definition QXPTypes.h:163
libqxp::CharFormat::superior
bool superior
Definition QXPTypes.h:157
libqxp::CharFormat::superscript
bool superscript
Definition QXPTypes.h:155
libqxp::Color
Definition QXPTypes.h:69
libqxp::Color::toString
librevenge::RVNGString toString() const
Definition QXPTypes.cpp:98
libqxp::Color::red
uint8_t red
Definition QXPTypes.h:70
libqxp::Color::Color
Color(uint8_t r, uint8_t g, uint8_t b)
Definition QXPTypes.h:78
libqxp::Color::blue
uint8_t blue
Definition QXPTypes.h:72
libqxp::Color::green
uint8_t green
Definition QXPTypes.h:71
libqxp::Color::Color
Color()
Definition QXPTypes.h:74
libqxp::Color::applyShade
Color applyShade(double shade) const
Definition QXPTypes.cpp:105
libqxp::CurveComponent::CurveComponent
CurveComponent()
Definition QXPTypes.h:432
libqxp::CurveComponent::points
std::vector< Point > points
Definition QXPTypes.h:430
libqxp::CurveComponent::boundingBox
Rect boundingBox
Definition QXPTypes.h:429
libqxp::Frame
Definition QXPTypes.h:345
libqxp::Frame::width
double width
Definition QXPTypes.h:346
libqxp::Frame::lineStyle
const LineStyle * lineStyle
Definition QXPTypes.h:349
libqxp::Frame::startArrow
const Arrow * startArrow
Definition QXPTypes.h:350
libqxp::Frame::color
boost::optional< Color > color
Definition QXPTypes.h:347
libqxp::Frame::operator=
Frame & operator=(const Frame &other)=default
libqxp::Frame::Frame
Frame()
Definition QXPTypes.h:353
libqxp::Frame::endArrow
const Arrow * endArrow
Definition QXPTypes.h:351
libqxp::Frame::gapColor
boost::optional< Color > gapColor
Definition QXPTypes.h:348
libqxp::Frame::Frame
Frame(const Frame &other)=default
libqxp::Gradient::color1
Color color1
Definition QXPTypes.h:100
libqxp::Gradient::color2
Color color2
Definition QXPTypes.h:101
libqxp::Gradient::Gradient
Gradient()
Definition QXPTypes.h:104
libqxp::Gradient::type
GradientType type
Definition QXPTypes.h:99
libqxp::Gradient::angle
double angle
Definition QXPTypes.h:102
libqxp::Group::objectsIndexes
std::vector< unsigned > objectsIndexes
Definition QXPTypes.h:529
libqxp::Group::Group
Group()
Definition QXPTypes.h:531
libqxp::HJ::HJ
HJ()
Definition QXPTypes.h:175
libqxp::HJ::minBefore
unsigned minBefore
Definition QXPTypes.h:185
libqxp::HJ::minAfter
unsigned minAfter
Definition QXPTypes.h:186
libqxp::HJ::singleWordJustify
bool singleWordJustify
Definition QXPTypes.h:188
libqxp::HJ::maxInRow
unsigned maxInRow
Definition QXPTypes.h:187
libqxp::HJ::hyphenate
bool hyphenate
Definition QXPTypes.h:184
libqxp::LineStyle
Definition QXPTypes.h:127
libqxp::LineStyle::joinType
LineJoinType joinType
Definition QXPTypes.h:133
libqxp::LineStyle::endcapType
LineCapType endcapType
Definition QXPTypes.h:132
libqxp::LineStyle::LineStyle
LineStyle()
Definition QXPTypes.h:135
libqxp::LineStyle::patternLength
double patternLength
Definition QXPTypes.h:131
libqxp::LineStyle::LineStyle
LineStyle(std::vector< double > segments, bool proportional, double pattern, LineCapType endcap, LineJoinType join)
Definition QXPTypes.h:139
libqxp::LineStyle::isStripe
bool isStripe
Definition QXPTypes.h:129
libqxp::LineStyle::isProportional
bool isProportional
Definition QXPTypes.h:130
libqxp::LineStyle::segmentLengths
std::vector< double > segmentLengths
Definition QXPTypes.h:128
libqxp::Line::style
Frame style
Definition QXPTypes.h:452
libqxp::Line::rotation
double rotation
Definition QXPTypes.h:451
libqxp::Line::curveComponents
std::vector< CurveComponent > curveComponents
Definition QXPTypes.h:453
libqxp::Line::Line
Line()
Definition QXPTypes.h:455
libqxp::LinkedTextSettings
Definition QXPTypes.h:362
libqxp::LinkedTextSettings::textLength
boost::optional< unsigned > textLength
Definition QXPTypes.h:367
libqxp::LinkedTextSettings::nextLinkedIndex
unsigned nextLinkedIndex
Definition QXPTypes.h:366
libqxp::LinkedTextSettings::offsetIntoText
unsigned offsetIntoText
Definition QXPTypes.h:364
libqxp::LinkedTextSettings::LinkedTextSettings
LinkedTextSettings()
Definition QXPTypes.h:369
libqxp::LinkedTextSettings::linkId
unsigned linkId
Definition QXPTypes.h:363
libqxp::LinkedTextSettings::linkedIndex
unsigned linkedIndex
Definition QXPTypes.h:365
libqxp::Object::boundingBox
Rect boundingBox
Definition QXPTypes.h:439
libqxp::Object::runaround
bool runaround
Definition QXPTypes.h:440
libqxp::Object::zIndex
unsigned zIndex
Definition QXPTypes.h:441
libqxp::Object::Object
Object()
Definition QXPTypes.h:444
libqxp::PageSettings::PageSettings
PageSettings()
Definition QXPTypes.h:540
libqxp::PageSettings::offset
Rect offset
Definition QXPTypes.h:538
libqxp::Page::pageSettings
std::vector< PageSettings > pageSettings
Definition QXPTypes.h:547
libqxp::Page::isFacing
bool isFacing() const
Definition QXPTypes.h:554
libqxp::Page::objectsCount
unsigned objectsCount
Definition QXPTypes.h:548
libqxp::Page::Page
Page()
Definition QXPTypes.h:550
libqxp::ParagraphFormat::ruleBelow
std::shared_ptr< ParagraphRule > ruleBelow
Definition QXPTypes.h:255
libqxp::ParagraphFormat::ParagraphFormat
ParagraphFormat()
Definition QXPTypes.h:259
libqxp::ParagraphFormat::margin
Rect margin
Definition QXPTypes.h:250
libqxp::ParagraphFormat::firstLineIndent
double firstLineIndent
Definition QXPTypes.h:251
libqxp::ParagraphFormat::alignment
HorizontalAlignment alignment
Definition QXPTypes.h:249
libqxp::ParagraphFormat::incrementalLeading
bool incrementalLeading
Definition QXPTypes.h:253
libqxp::ParagraphFormat::leading
double leading
Definition QXPTypes.h:252
libqxp::ParagraphFormat::hj
std::shared_ptr< HJ > hj
Definition QXPTypes.h:257
libqxp::ParagraphFormat::tabStops
std::vector< TabStop > tabStops
Definition QXPTypes.h:256
libqxp::ParagraphFormat::ruleAbove
std::shared_ptr< ParagraphRule > ruleAbove
Definition QXPTypes.h:254
libqxp::ParagraphRule::color
Color color
Definition QXPTypes.h:236
libqxp::ParagraphRule::offset
double offset
Definition QXPTypes.h:240
libqxp::ParagraphRule::ParagraphRule
ParagraphRule()
Definition QXPTypes.h:242
libqxp::ParagraphRule::leftMargin
double leftMargin
Definition QXPTypes.h:238
libqxp::ParagraphRule::rightMargin
double rightMargin
Definition QXPTypes.h:239
libqxp::ParagraphRule::width
double width
Definition QXPTypes.h:235
libqxp::ParagraphRule::lineStyle
const LineStyle * lineStyle
Definition QXPTypes.h:237
libqxp::ParagraphSpec
Definition QXPTypes.h:307
libqxp::ParagraphSpec::ParagraphSpec
ParagraphSpec(const std::shared_ptr< ParagraphFormat > &f, unsigned start, unsigned len)
Definition QXPTypes.h:310
libqxp::ParagraphSpec::format
std::shared_ptr< ParagraphFormat > format
Definition QXPTypes.h:308
libqxp::PictureBox::scaleVert
double scaleVert
Definition QXPTypes.h:519
libqxp::PictureBox::offsetTop
double offsetTop
Definition QXPTypes.h:517
libqxp::PictureBox::PictureBox
PictureBox()
Definition QXPTypes.h:521
libqxp::PictureBox::offsetLeft
double offsetLeft
Definition QXPTypes.h:516
libqxp::PictureBox::pictureSkew
double pictureSkew
Definition QXPTypes.h:515
libqxp::PictureBox::scaleHor
double scaleHor
Definition QXPTypes.h:518
libqxp::PictureBox::pictureRotation
double pictureRotation
Definition QXPTypes.h:514
libqxp::Point
Definition QXPTypes.h:25
libqxp::Point::y
double y
Definition QXPTypes.h:27
libqxp::Point::move
Point move(double dx, double dy) const
Definition QXPTypes.cpp:28
libqxp::Point::x
double x
Definition QXPTypes.h:26
libqxp::Point::rotateDeg
Point rotateDeg(double rotationDeg, const Point &center) const
Definition QXPTypes.cpp:33
libqxp::Point::Point
Point()
Definition QXPTypes.h:29
libqxp::Point::Point
Point(double xVal, double yVal)
Definition QXPTypes.h:33
libqxp::Point::distance
double distance(const Point &p2) const
Definition QXPTypes.cpp:45
libqxp::QXPDocumentProperties::superscriptOffset
double superscriptOffset
Definition QXPTypes.h:575
libqxp::QXPDocumentProperties::isIncrementalAutoLeading
bool isIncrementalAutoLeading() const
Definition QXPTypes.h:588
libqxp::QXPDocumentProperties::autoLeading
double autoLeading() const
Definition QXPTypes.cpp:171
libqxp::QXPDocumentProperties::QXPDocumentProperties
QXPDocumentProperties()
Definition QXPTypes.h:562
libqxp::QXPDocumentProperties::m_autoLeading
double m_autoLeading
Definition QXPTypes.h:594
libqxp::QXPDocumentProperties::superiorVScale
double superiorVScale
Definition QXPTypes.h:582
libqxp::QXPDocumentProperties::superscriptHScale
double superscriptHScale
Definition QXPTypes.h:576
libqxp::QXPDocumentProperties::superiorHScale
double superiorHScale
Definition QXPTypes.h:581
libqxp::QXPDocumentProperties::subscriptHScale
double subscriptHScale
Definition QXPTypes.h:579
libqxp::QXPDocumentProperties::subscriptVScale
double subscriptVScale
Definition QXPTypes.h:580
libqxp::QXPDocumentProperties::setAutoLeading
void setAutoLeading(const double val)
Definition QXPTypes.cpp:159
libqxp::QXPDocumentProperties::subscriptOffset
double subscriptOffset
Definition QXPTypes.h:578
libqxp::QXPDocumentProperties::superscriptVScale
double superscriptVScale
Definition QXPTypes.h:577
libqxp::Rect
Definition QXPTypes.h:47
libqxp::Rect::topLeft
Point topLeft() const
Definition QXPTypes.cpp:73
libqxp::Rect::bottomRight
Point bottomRight() const
Definition QXPTypes.cpp:83
libqxp::Rect::center
Point center() const
Definition QXPTypes.cpp:68
libqxp::Rect::topRight
Point topRight() const
Definition QXPTypes.cpp:78
libqxp::Rect::right
double right
Definition QXPTypes.h:49
libqxp::Rect::shrink
Rect shrink(const double diff) const
Definition QXPTypes.cpp:93
libqxp::Rect::height
double height() const
Definition QXPTypes.cpp:63
libqxp::Rect::bottomLeft
Point bottomLeft() const
Definition QXPTypes.cpp:88
libqxp::Rect::bottom
double bottom
Definition QXPTypes.h:50
libqxp::Rect::left
double left
Definition QXPTypes.h:51
libqxp::Rect::top
double top
Definition QXPTypes.h:48
libqxp::Rect::Rect
Rect()
Definition QXPTypes.cpp:50
libqxp::Rect::width
double width() const
Definition QXPTypes.cpp:58
libqxp::TabStop::isDefined
bool isDefined() const
Definition QXPTypes.h:223
libqxp::TabStop::type
TabStopType type
Definition QXPTypes.h:218
libqxp::TabStop::TabStop
TabStop()
Definition QXPTypes.h:228
libqxp::TabStop::alignChar
librevenge::RVNGString alignChar
Definition QXPTypes.h:221
libqxp::TabStop::position
double position
Definition QXPTypes.h:219
libqxp::TabStop::fillChar
librevenge::RVNGString fillChar
Definition QXPTypes.h:220
libqxp::TextBox::settings
TextSettings settings
Definition QXPTypes.h:505
libqxp::TextBox::TextBox
TextBox()
Definition QXPTypes.h:507
libqxp::TextObject::text
boost::optional< std::shared_ptr< Text > > text
Definition QXPTypes.h:377
libqxp::TextObject::TextObject
TextObject()
Definition QXPTypes.h:379
libqxp::TextObject::linkSettings
LinkedTextSettings linkSettings
Definition QXPTypes.h:376
libqxp::TextObject::isLinked
bool isLinked() const
Definition QXPTypes.cpp:154
libqxp::TextPathSettings
Definition QXPTypes.h:416
libqxp::TextPathSettings::TextPathSettings
TextPathSettings()
Definition QXPTypes.h:422
libqxp::TextPathSettings::alignment
TextPathAlignment alignment
Definition QXPTypes.h:419
libqxp::TextPathSettings::rotate
bool rotate
Definition QXPTypes.h:417
libqxp::TextPathSettings::skew
bool skew
Definition QXPTypes.h:418
libqxp::TextPathSettings::lineAlignment
TextPathLineAlignment lineAlignment
Definition QXPTypes.h:420
libqxp::TextPath::TextPath
TextPath()
Definition QXPTypes.h:464
libqxp::TextPath::settings
TextPathSettings settings
Definition QXPTypes.h:462
libqxp::TextSettings
Definition QXPTypes.h:387
libqxp::TextSettings::inset
Rect inset
Definition QXPTypes.h:391
libqxp::TextSettings::columnsCount
unsigned columnsCount
Definition QXPTypes.h:388
libqxp::TextSettings::rotation
double rotation
Definition QXPTypes.h:392
libqxp::TextSettings::verticalAlignment
VerticalAlignment verticalAlignment
Definition QXPTypes.h:390
libqxp::TextSettings::skew
double skew
Definition QXPTypes.h:393
libqxp::TextSettings::gutterWidth
double gutterWidth
Definition QXPTypes.h:389
libqxp::TextSettings::TextSettings
TextSettings()
Definition QXPTypes.h:395
libqxp::TextSpec
Definition QXPTypes.h:275
libqxp::TextSpec::overlaps
bool overlaps(const TextSpec &other) const
Definition QXPTypes.cpp:118
libqxp::TextSpec::endIndex
unsigned endIndex() const
Definition QXPTypes.h:279
libqxp::TextSpec::startIndex
const unsigned startIndex
Definition QXPTypes.h:276
libqxp::TextSpec::length
const unsigned length
Definition QXPTypes.h:277
libqxp::TextSpec::TextSpec
TextSpec(unsigned start, unsigned len)
Definition QXPTypes.h:292
libqxp::TextSpec::afterEndIndex
unsigned afterEndIndex() const
Definition QXPTypes.h:284
libqxp::Text::encoding
const char * encoding
Definition QXPTypes.h:318
libqxp::Text::paragraphs
std::vector< ParagraphSpec > paragraphs
Definition QXPTypes.h:319
libqxp::Text::Text
Text(const Text &other)=default
libqxp::Text::maxFontSize
double maxFontSize() const
Definition QXPTypes.cpp:123
libqxp::Text::text
std::string text
Definition QXPTypes.h:317
libqxp::Text::Text
Text()
Definition QXPTypes.h:325
libqxp::Text::charFormats
std::vector< CharFormatSpec > charFormats
Definition QXPTypes.h:320
libqxp::Text::operator=
Text & operator=(const Text &other)=default