ClarisWksStyleManager.hxx
Go to the documentation of this file.
1 /* -*- Mode: C++; c-default-style: "k&r"; indent-tabs-mode: nil; tab-width: 2; c-basic-offset: 2 -*- */
2 
3 /* libmwaw
4 * Version: MPL 2.0 / LGPLv2+
5 *
6 * The contents of this file are subject to the Mozilla Public License Version
7 * 2.0 (the "License"); you may not use this file except in compliance with
8 * the License or as specified alternatively below. You may obtain a copy of
9 * the License at http://www.mozilla.org/MPL/
10 *
11 * Software distributed under the License is distributed on an "AS IS" basis,
12 * WITHOUT WARRANTY OF ANY KIND, either express or implied. See the License
13 * for the specific language governing rights and limitations under the
14 * License.
15 *
16 * Major Contributor(s):
17 * Copyright (C) 2002 William Lachance (wrlach@gmail.com)
18 * Copyright (C) 2002,2004 Marc Maurer (uwog@uwog.net)
19 * Copyright (C) 2004-2006 Fridrich Strba (fridrich.strba@bluewin.ch)
20 * Copyright (C) 2006, 2007 Andrew Ziem
21 * Copyright (C) 2011, 2012 Alonso Laurent (alonso@loria.fr)
22 *
23 *
24 * All Rights Reserved.
25 *
26 * For minor contributions see the git repository.
27 *
28 * Alternatively, the contents of this file may be used under the terms of
29 * the GNU Lesser General Public License Version 2 or later (the "LGPLv2+"),
30 * in which case the provisions of the LGPLv2+ are applicable
31 * instead of those above.
32 */
33 
34 /*
35  * Class used to read main style by AppleWorks/ClarisWorks parser
36  *
37  */
38 #ifndef CLARIS_WKS_STYLE_MANAGER
39 # define CLARIS_WKS_STYLE_MANAGER
40 
41 #include <iostream>
42 #include <string>
43 #include <vector>
44 
45 #include "libmwaw_internal.hxx"
46 
47 #include "MWAWCell.hxx"
48 #include "MWAWDebug.hxx"
49 #include "MWAWGraphicStyle.hxx"
50 #include "MWAWInputStream.hxx"
51 
52 class ClarisWksDocument;
53 
55 {
56 struct State;
57 }
58 
61 {
62 public:
63  struct CellFormat;
64  struct KSEN;
65  struct Style;
66 public:
68  ClarisWksStyleManager(MWAWParserStatePtr const &parserState, ClarisWksDocument *document=nullptr);
71 
73  bool readColorList(MWAWEntry const &entry);
75  bool readPatternList(long endPos=-1);
77  bool readGradientList(long endPos=-1);
79  bool readStyles(MWAWEntry const &entry);
81  bool readFontNames();
83  bool updateGradient(int grad, MWAWGraphicStyle &style) const;
85  bool updateWallPaper(int wall, MWAWGraphicStyle &style) const;
86 
88  int getFontId(int localId) const;
90  bool getColor(int id, MWAWColor &col) const;
92  bool getPattern(int id, MWAWGraphicStyle::Pattern &pattern, float &percent) const;
94  bool getRulerName(int id, std::string &name) const;
95 
97  bool get(int styleId, Style &style) const;
99  bool get(int fontId, MWAWFont &font) const;
101  bool get(int formatId, CellFormat &format) const;
103  bool get(int ksenId, KSEN &ksen) const;
105  bool get(int graphId, MWAWGraphicStyle &graph) const;
106 
108  bool readFont(int id, int fontSize, MWAWFont &font);
110  bool readFontAndPos(int id, int &posC, MWAWFont &font);
111 
112 protected:
114  int version() const;
115 
117  bool readGenStyle(int id);
118 
120  bool readStylesDef(int N, int fSz);
122  bool readLookUp(int N, int fSz);
123 
124  /* read the STYL CELL sequence */
125  bool readCellStyles(int N, int fSz);
127  bool readFontNames(int N, int fSz);
129  bool readGraphStyles(int N, int fSz);
131  bool readKSEN(int N, int fSz);
133  bool readStyleNames(int N, int fSz);
135  bool readStyleFonts(int N, int fSz);
136 
137 protected:
143  std::shared_ptr<ClarisWksStyleManagerInternal::State> m_state;
144 
145 private:
148 
149 public:
151  struct CellFormat final : public MWAWCell::Format {
153  explicit CellFormat(MWAWCell::Format const &format=MWAWCell::Format())
154  : MWAWCell::Format(format)
155  , m_hAlign(MWAWCell::HALIGN_DEFAULT)
156  , m_fileFormat(-1)
157  , m_borders(0)
158  , m_wrap(false)
159  , m_extra("")
160  {
161  }
162  CellFormat(CellFormat const &)=default;
163  CellFormat &operator=(CellFormat const &)=default;
166  ~CellFormat() final;
168  friend std::ostream &operator<<(std::ostream &o, CellFormat const &form);
170  MWAWCell::HorizontalAlignment m_hAlign;
176  bool m_wrap;
178  std::string m_extra;
179  };
180 
182  struct KSEN {
185  : m_valign(0)
186  , m_lineType(MWAWBorder::Simple)
187  , m_lineRepeat(MWAWBorder::Single)
188  , m_lines(0)
189  , m_extra("")
190  {
191  }
193  friend std::ostream &operator<<(std::ostream &o, KSEN const &ksen);
195  int m_valign;
201  int m_lines;
203  std::string m_extra;
204  };
205 
207  struct Style {
210  : m_fontId(-1)
211  , m_cellFormatId(-1)
212  , m_rulerId(-1)
213  , m_rulerPId(-1)
214  , m_nameId(-1)
215  , m_ksenId(-1), m_graphicId(-1)
216  , m_localStyleId(-1)
217  , m_styleId(-1)
218  , m_extra("")
219  {
220  }
221 
223  friend std::ostream &operator<<(std::ostream &o, Style const &style);
224 
226  int m_fontId;
234  int m_nameId;
236  int m_ksenId;
244  std::string m_extra;
245  };
246 };
247 
248 #endif
MWAWEntry
basic class to store an entry in a file This contained :
Definition: MWAWEntry.hxx:47
MWAWGraphicStyle::Pattern::getUniqueColor
bool getUniqueColor(MWAWColor &col) const
check if the pattern has only one color; if so returns true...
Definition: MWAWGraphicStyle.cxx:86
ClarisWksStyleManagerInternal::Pattern::Pattern
Pattern(uint16_t const *pat=nullptr)
constructor ( 4 int by patterns )
Definition: ClarisWksStyleManager.cxx:58
MWAWInputStreamPtr
std::shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:551
ClarisWksStyleManager::KSEN::m_valign
int m_valign
the vertical alignment
Definition: ClarisWksStyleManager.hxx:195
ClarisWksStyleManager::readGraphStyles
bool readGraphStyles(int N, int fSz)
read a GraphicStyle sequence
Definition: ClarisWksStyleManager.cxx:2638
ClarisWksStyleManager::Style::m_localStyleId
int m_localStyleId
a local style id
Definition: ClarisWksStyleManager.hxx:240
MWAWFont::set
void set(Script const &newscript)
sets the script position
Definition: MWAWFont.hxx:314
MWAWFont::setUnderlineType
void setUnderlineType(Line::Type type=Line::Single)
sets the underline type
Definition: MWAWFont.hxx:474
MWAWBorder::Triple
@ Triple
Definition: libmwaw_internal.hxx:337
ClarisWksStyleManager::CellFormat::CellFormat
CellFormat(CellFormat const &)=default
ClarisWksStyleManagerInternal::State::m_lookupMap
std::map< int, int > m_lookupMap
the style lookupMap
Definition: ClarisWksStyleManager.cxx:243
MWAW_DEBUG_MSG
#define MWAW_DEBUG_MSG(M)
Definition: libmwaw_internal.hxx:129
ClarisWksStyleManager::Style::m_rulerPId
int m_rulerPId
the ruler parent id ( or maybe the style parent)
Definition: ClarisWksStyleManager.hxx:232
ClarisWksStyleManager::CellFormat::operator=
CellFormat & operator=(CellFormat const &)=default
MWAWVec2f
MWAWVec2< float > MWAWVec2f
MWAWVec2 of float.
Definition: libmwaw_internal.hxx:842
ClarisWksStyleManagerInternal::State::setDefaultWallPaperList
void setDefaultWallPaperList(int version)
set the default pattern map
Definition: ClarisWksStyleManager.cxx:512
libmwaw::DebugFile::addDelimiter
void addDelimiter(long pos, char c)
adds a not breaking delimiter in position pos
Definition: MWAWDebug.cxx:73
ClarisWksStyleManagerInternal::State::m_wallpaperList
std::vector< MWAWGraphicStyle::Pattern > m_wallpaperList
a list wallPaperId -> pattern
Definition: ClarisWksStyleManager.cxx:261
ClarisWksStyleManager::CellFormat::operator=
CellFormat & operator=(CellFormat &&)=default
ClarisWksStyleManager::KSEN
the KSEN structure a structure related to paragraph and cell style
Definition: ClarisWksStyleManager.hxx:182
MWAWBorder::Dash
@ Dash
Definition: libmwaw_internal.hxx:335
MWAWGraphicStyle::m_extra
std::string m_extra
extra data
Definition: MWAWGraphicStyle.hxx:568
MWAWGraphicStyle::setSurfaceColor
void setSurfaceColor(MWAWColor const &col, float opacity=1)
set the surface color
Definition: MWAWGraphicStyle.hxx:415
ClarisWksStyleManager::CellFormat::m_fileFormat
int m_fileFormat
the field format: number, string, currency, ..
Definition: ClarisWksStyleManager.hxx:172
ClarisWksStyleManager::getPattern
bool getPattern(int id, MWAWGraphicStyle::Pattern &pattern, float &percent) const
return the pattern which corresponds to an id.
Definition: ClarisWksStyleManager.cxx:1650
ClarisWksStyleManagerInternal::State::setDefaultColorList
void setDefaultColorList(int version)
set the default color map
Definition: ClarisWksStyleManager.cxx:265
ClarisWksStyleManager::ClarisWksStyleManager
ClarisWksStyleManager(ClarisWksStyleManager const &orig)=delete
ClarisWksStyleManagerInternal::State::State
State()
constructor
Definition: ClarisWksStyleManager.cxx:204
ClarisWksStyleManagerInternal::Pattern::m_percent
float m_percent
the percentage
Definition: ClarisWksStyleManager.cxx:88
ClarisWksDocument::checkOrdering
void checkOrdering(std::vector< int16_t > &vec16, std::vector< int32_t > &vec32) const
small fonction used to check unusual endian ordering of a list of int16_t, int32_t
Definition: ClarisWksDocument.cxx:376
ClarisWksStyleManager::KSEN::m_lineType
MWAWBorder::Style m_lineType
the line type
Definition: ClarisWksStyleManager.hxx:197
MWAWBorder::Simple
@ Simple
Definition: libmwaw_internal.hxx:335
operator<<
std::ostream & operator<<(std::ostream &o, ClarisWksStyleManager::KSEN const &ksen)
Definition: ClarisWksStyleManager.cxx:1489
MWAWFont::Script::sub100
static Script sub100()
return a yposition which correspond to a basic subscript100
Definition: MWAWFont.hxx:125
ClarisWksStyleManagerInternal::Gradient::m_type
int m_type
the type
Definition: ClarisWksStyleManager.cxx:148
MWAWFont::boldBit
@ boldBit
Definition: MWAWFont.hxx:190
ClarisWksStyleManager::CellFormat::m_hAlign
MWAWCell::HorizontalAlignment m_hAlign
the cell alignment : by default nothing
Definition: ClarisWksStyleManager.hxx:170
MWAWGraphicStyle::m_surfaceOpacity
float m_surfaceOpacity
true if the surface has some color
Definition: MWAWGraphicStyle.hxx:520
MWAWColor::white
static MWAWColor white()
return the white color
Definition: libmwaw_internal.hxx:250
MWAWFont::setColor
void setColor(MWAWColor color)
sets the font color
Definition: MWAWFont.hxx:341
ClarisWksStyleManagerInternal::Gradient::Gradient
Gradient(int type=0, int nColor=0, int angle=0, float decal=0)
construtor
Definition: ClarisWksStyleManager.cxx:99
ClarisWksStyleManager::CellFormat::CellFormat
CellFormat(MWAWCell::Format const &format=MWAWCell::Format())
constructor from cell
Definition: ClarisWksStyleManager.hxx:153
MWAWEntry.hxx
MWAWFontConverter.hxx
MWAWColor
the class to store a color
Definition: libmwaw_internal.hxx:192
MWAWEmbeddedObject
small class use to define a embedded object
Definition: libmwaw_internal.hxx:467
ClarisWksStyleManagerInternal::Pattern::operator=
Pattern & operator=(Pattern const &)=default
ClarisWksStyleManagerInternal::State::m_colorList
std::vector< MWAWColor > m_colorList
a list colorId -> color
Definition: ClarisWksStyleManager.cxx:255
MWAWEntry::type
std::string const & type() const
returns the type of the entry
Definition: MWAWEntry.hxx:137
ClarisWksStyleManagerInternal::Gradient::m_box
MWAWBox2i m_box
the center bdbox
Definition: ClarisWksStyleManager.cxx:158
MWAWGraphicStyle::Pattern::getAverageColor
bool getAverageColor(MWAWColor &col) const
return the average color
Definition: MWAWGraphicStyle.cxx:101
ClarisWksStyleManager::getFontId
int getFontId(int localId) const
return a mac font id corresponding to a local id
Definition: ClarisWksStyleManager.cxx:1663
MWAWGraphicStyle::Gradient::G_Linear
@ G_Linear
Definition: MWAWGraphicStyle.hxx:177
MWAWFont::Line::Simple
@ Simple
Definition: MWAWFont.hxx:49
MWAWBorder::None
@ None
Definition: libmwaw_internal.hxx:335
ClarisWksStyleManager::CellFormat::~CellFormat
~CellFormat() final
destructor
Definition: ClarisWksStyleManager.cxx:2801
ClarisWksStyleManager::CellFormat::m_wrap
bool m_wrap
true if the cell content is wrapped
Definition: ClarisWksStyleManager.hxx:176
ClarisWksStyleManager::Style::m_ksenId
int m_ksenId
the ksen id
Definition: ClarisWksStyleManager.hxx:236
ClarisWksStyleManager::Style
the structure to store the style in a ClarisWksStyleManager
Definition: ClarisWksStyleManager.hxx:207
ClarisWksDocument
main document information used to create a ClarisWorks file
Definition: ClarisWksDocument.hxx:74
ClarisWksStyleManagerInternal::State::m_ksenList
std::vector< ClarisWksStyleManager::KSEN > m_ksenList
the KSEN list
Definition: ClarisWksStyleManager.cxx:251
ClarisWksStyleManager::Style::Style
Style()
constructor
Definition: ClarisWksStyleManager.hxx:209
libmwaw::DebugFile::addNote
void addNote(char const *note)
adds a note in the file, in actual position
Definition: MWAWDebug.cxx:59
MWAWFont::setDeltaLetterSpacing
void setDeltaLetterSpacing(float d, librevenge::RVNGUnit unit=librevenge::RVNG_POINT)
sets the letter spacing ( delta value in point )
Definition: MWAWFont.hxx:292
ClarisWksStyleManager::CellFormat::m_borders
int m_borders
the borders
Definition: ClarisWksStyleManager.hxx:174
MWAWGraphicStyle
a structure used to define a picture style
Definition: MWAWGraphicStyle.hxx:48
MWAWBorder::Dot
@ Dot
Definition: libmwaw_internal.hxx:335
MWAWBorder::Type
Type
the line repetition
Definition: libmwaw_internal.hxx:337
MWAWGraphicStyle::Pattern::m_data
std::vector< unsigned char > m_data
the pattern data: a sequence of data: p[0..7,0],p[8..15,0]...p[0..7,1],p[8..15,1],...
Definition: MWAWGraphicStyle.hxx:363
ClarisWksStyleManager::Style::m_extra
std::string m_extra
extra data
Definition: ClarisWksStyleManager.hxx:244
MWAWFont::Script::super100
static Script super100()
return a yposition which correspond to a basic superscript100
Definition: MWAWFont.hxx:135
MWAWFont::embossBit
@ embossBit
Definition: MWAWFont.hxx:190
MWAWGraphicStyle::m_lineOpacity
float m_lineOpacity
the line opacity: 0=transparent
Definition: MWAWGraphicStyle.hxx:514
MWAWCell.hxx
Defines MWAWCell (cell content and format)
ClarisWksStyleManager::KSEN::m_lineRepeat
MWAWBorder::Type m_lineRepeat
the line repetition
Definition: ClarisWksStyleManager.hxx:199
MWAWGraphicStyle::Gradient::G_Rectangular
@ G_Rectangular
Definition: MWAWGraphicStyle.hxx:177
MWAWCell::Format::m_digits
int m_digits
the number of digits
Definition: MWAWCell.hxx:99
MWAWFont::setStrikeOutStyle
void setStrikeOutStyle(Line::Style style=Line::None, bool doReset=true)
sets the strikeoutline style ( by default, we also reset the style)
Definition: MWAWFont.hxx:427
MWAWGraphicStyle::Pattern
a basic pattern used in a MWAWGraphicStyle:
Definition: MWAWGraphicStyle.hxx:277
MWAWBorder::Style
Style
the line style
Definition: libmwaw_internal.hxx:335
ClarisWksStyleManager::version
int version() const
return the file version
Definition: ClarisWksStyleManager.cxx:1604
MWAWColor::barycenter
static MWAWColor barycenter(float alpha, MWAWColor const &colA, float beta, MWAWColor const &colB)
return alpha*colA+beta*colB
Definition: libmwaw_internal.cxx:206
ClarisWksStyleManager::operator=
ClarisWksStyleManager & operator=(ClarisWksStyleManager const &orig)=delete
ClarisWksStyleManagerInternal::Pattern::Pattern
Pattern(Pattern const &)=default
ClarisWksStyleManagerInternal::State
Internal: the state of a ClarisWksStyleManager.
Definition: ClarisWksStyleManager.cxx:202
ClarisWksStyleManagerInternal::State::m_stylesMap
std::map< int, ClarisWksStyleManager::Style > m_stylesMap
the styles map id->style
Definition: ClarisWksStyleManager.cxx:241
ClarisWksStyleManager::Style::m_nameId
int m_nameId
the style name id
Definition: ClarisWksStyleManager.hxx:234
MWAWFont::shadowBit
@ shadowBit
Definition: MWAWFont.hxx:191
ClarisWksStyleManager::readStylesDef
bool readStylesDef(int N, int fSz)
try to read the style definition zone
Definition: ClarisWksStyleManager.cxx:2073
ClarisWksStyleManagerInternal::State::m_nameList
std::vector< std::string > m_nameList
the style name list
Definition: ClarisWksStyleManager.cxx:253
ClarisWksStyleManager.hxx
libmwaw_internal.hxx
MWAWGraphicStyle::m_lineWidth
float m_lineWidth
the linewidth
Definition: MWAWGraphicStyle.hxx:508
ClarisWksStyleManager::get
bool get(int styleId, Style &style) const
return the style corresponding to a styleId
Definition: ClarisWksStyleManager.cxx:1668
ClarisWksStyleManagerInternal::State::setDefaultGradientList
void setDefaultGradientList(int version)
set the default pattern map
Definition: ClarisWksStyleManager.cxx:353
ClarisWksStyleManagerInternal::State::m_patternList
std::vector< Pattern > m_patternList
a list patternId -> pattern
Definition: ClarisWksStyleManager.cxx:257
MWAWCell::Format
a structure uses to define the format of a cell content
Definition: MWAWCell.hxx:60
ClarisWksStyleManagerInternal::Gradient::update
bool update(MWAWGraphicStyle &style) const
update the style
Definition: ClarisWksStyleManager.cxx:161
ClarisWksStyleManager::Style::m_graphicId
int m_graphicId
the graphic (checkme)
Definition: ClarisWksStyleManager.hxx:238
MWAWGraphicStyle::Gradient::Stop
a structure used to define the gradient limit in MWAWGraphicStyle
Definition: MWAWGraphicStyle.hxx:141
MWAWBorder
a border
Definition: libmwaw_internal.hxx:333
ClarisWksStyleManagerInternal::Gradient::m_colors
MWAWColor m_colors[4]
the color
Definition: ClarisWksStyleManager.cxx:152
ClarisWksStyleManagerInternal::State::setDefaultPatternList
void setDefaultPatternList(int version)
set the default pattern map
Definition: ClarisWksStyleManager.cxx:327
ClarisWksDocument.hxx
ClarisWksStyleManager::readStyleNames
bool readStyleNames(int N, int fSz)
read a STYL Name sequence
Definition: ClarisWksStyleManager.cxx:2513
MWAWGraphicStyle::Pattern::m_dim
MWAWVec2i m_dim
the dimension width x height
Definition: MWAWGraphicStyle.hxx:358
MWAWEntry::length
long length() const
returns the length of the zone
Definition: MWAWEntry.hxx:93
ClarisWksStruct::Struct::readHeader
bool readHeader(MWAWInputStreamPtr input, bool strict=false)
try to read the header
Definition: ClarisWksStruct.cxx:72
MWAWDebug.hxx
ClarisWksStyleManagerInternal::State::m_fontList
std::vector< MWAWFont > m_fontList
the list of fonts
Definition: ClarisWksStyleManager.cxx:245
ClarisWksStyleManager::m_parserState
MWAWParserStatePtr m_parserState
the parser state
Definition: ClarisWksStyleManager.hxx:141
MWAWFont::getDebugString
std::string getDebugString(std::shared_ptr< MWAWFontConverter > &converter) const
returns a string which can be used for debugging
Definition: MWAWFont.cxx:181
MWAWEntry::begin
long begin() const
returns the begin offset
Definition: MWAWEntry.hxx:83
ClarisWksStyleManager::readGradientList
bool readGradientList(long endPos=-1)
reads a gradient map zone ( v2)
Definition: ClarisWksStyleManager.cxx:1799
MWAWGraphicStyle::setPattern
void setPattern(Pattern const &pat, float opacity=1)
set the pattern
Definition: MWAWGraphicStyle.hxx:426
MWAWCell::Format::Format
Format()
constructor
Definition: MWAWCell.hxx:62
ClarisWksStyleManager::ClarisWksStyleManager
ClarisWksStyleManager(MWAWParserStatePtr const &parserState, ClarisWksDocument *document=nullptr)
constructor
Definition: ClarisWksStyleManager.cxx:1592
ClarisWksStyleManagerInternal::State::m_cellFormatList
std::vector< ClarisWksStyleManager::CellFormat > m_cellFormatList
the list of format
Definition: ClarisWksStyleManager.cxx:247
MWAWColor::black
static MWAWColor black()
return the back color
Definition: libmwaw_internal.hxx:245
MWAWFont::setId
void setId(int newId)
sets the font id
Definition: MWAWFont.hxx:264
ClarisWksStyleManager::readFont
bool readFont(int id, int fontSize, MWAWFont &font)
try to read a named font
Definition: ClarisWksStyleManager.cxx:2305
ClarisWksText.hxx
ClarisWksStyleManagerInternal::Pattern::operator=
Pattern & operator=(Pattern &&)=default
MWAWFont::Script::sub
static Script sub()
return a yposition which correspond to a basic subscript
Definition: MWAWFont.hxx:120
ClarisWksStyleManager::updateGradient
bool updateGradient(int grad, MWAWGraphicStyle &style) const
update a style using a gradiant id
Definition: ClarisWksStyleManager.cxx:1715
ClarisWksStyleManagerInternal::State::m_version
int m_version
the version
Definition: ClarisWksStyleManager.cxx:237
MWAWGraphicStyle::Gradient::G_Axial
@ G_Axial
Definition: MWAWGraphicStyle.hxx:177
ClarisWksStyleManagerInternal::Gradient::m_decal
float m_decal
the decal
Definition: ClarisWksStyleManager.cxx:156
MWAWGraphicStyle::Pattern::m_colors
MWAWColor m_colors[2]
the two indexed colors
Definition: MWAWGraphicStyle.hxx:361
ClarisWksStyleManagerInternal::Gradient::ok
bool ok() const
check if the gradient is valid
Definition: ClarisWksStyleManager.cxx:110
MWAWEntry::end
long end() const
returns the end offset
Definition: MWAWEntry.hxx:88
ClarisWksStyleManager
a structure to store the style list and the lookup zone
Definition: ClarisWksStyleManager.hxx:61
MWAWFont::setSize
void setSize(float sz, bool isRelative=false)
sets the font size
Definition: MWAWFont.hxx:275
MWAWGraphicStyle::m_lineColor
MWAWColor m_lineColor
the line color
Definition: MWAWGraphicStyle.hxx:516
ClarisWksStyleManager::KSEN::m_lines
int m_lines
an int used to add some oblique line ( or cross )
Definition: ClarisWksStyleManager.hxx:201
ClarisWksStyleManagerInternal::State::m_localFIdMap
std::map< int, int > m_localFIdMap
a map local fontId->fontId
Definition: ClarisWksStyleManager.cxx:239
ClarisWksStyleManagerInternal
Internal: the structures of a ClarisWksStyleManagerInternal.
Definition: ClarisWksStyleManager.cxx:53
ClarisWksStyleManager::readColorList
bool readColorList(MWAWEntry const &entry)
reads a color map zone ( v4-v6)
Definition: ClarisWksStyleManager.cxx:1872
MWAWBox2i
MWAWBox2< int > MWAWBox2i
MWAWBox2 of int.
Definition: libmwaw_internal.hxx:1191
ClarisWksStyleManager::readCellStyles
bool readCellStyles(int N, int fSz)
Definition: ClarisWksStyleManager.cxx:2559
MWAWBorder::Double
@ Double
Definition: libmwaw_internal.hxx:337
MWAWGraphicStyle::Pattern::Pattern
Pattern()
constructor
Definition: MWAWGraphicStyle.hxx:279
ClarisWksStruct::Struct::m_size
long m_size
the size of the DSET header
Definition: ClarisWksStruct.hxx:69
MWAWGraphicStyle.hxx
MWAWFont::italicBit
@ italicBit
Definition: MWAWFont.hxx:190
ClarisWksStyleManager::CellFormat::operator<<
friend std::ostream & operator<<(std::ostream &o, CellFormat const &form)
operator<<
Definition: ClarisWksStyleManager.cxx:2805
ClarisWksStyleManager::readGenStyle
bool readGenStyle(int id)
try to read a STYL_ subzone (in v4-6)
Definition: ClarisWksStyleManager.cxx:1970
ClarisWksStyleManagerInternal::Gradient
Internal: the gradient of a ClarisWksStyleManager.
Definition: ClarisWksStyleManager.cxx:97
ClarisWksStyleManager::Style::m_cellFormatId
int m_cellFormatId
the formatId
Definition: ClarisWksStyleManager.hxx:228
MWAWGraphicStyle::m_gradient
Gradient m_gradient
the gradient
Definition: MWAWGraphicStyle.hxx:533
ClarisWksStyleManagerInternal::Gradient::m_numColors
int m_numColors
the number of color
Definition: ClarisWksStyleManager.cxx:150
ClarisWksStyleManager::updateWallPaper
bool updateWallPaper(int wall, MWAWGraphicStyle &style) const
update a style using a wall paper id
Definition: ClarisWksStyleManager.cxx:1736
ClarisWksStyleManager::KSEN::m_extra
std::string m_extra
extra data
Definition: ClarisWksStyleManager.hxx:203
MWAWParserStatePtr
std::shared_ptr< MWAWParserState > MWAWParserStatePtr
a smart pointer of MWAWParserState
Definition: libmwaw_internal.hxx:557
MWAWCell::Format::m_parenthesesForNegative
bool m_parenthesesForNegative
true if we use parenthese to print negative number
Definition: MWAWCell.hxx:109
libmwaw::DebugFile::addPos
void addPos(long pos)
adds a new position in the file
Definition: MWAWDebug.cxx:53
ClarisWksStyleManagerInternal::Pattern::~Pattern
~Pattern() final
destructor
Definition: ClarisWksStyleManager.cxx:91
ClarisWksStruct::Struct::m_dataSize
long m_dataSize
the data size
Definition: ClarisWksStruct.hxx:73
MWAWEntry::valid
bool valid() const
returns true if the zone length is positive
Definition: MWAWEntry.hxx:99
MWAWFont::Script::super
static Script super()
return a yposition which correspond to a basic superscript
Definition: MWAWFont.hxx:130
ClarisWksStyleManagerInternal::Pattern
Internal: the pattern of a ClarisWksStyleManager.
Definition: ClarisWksStyleManager.cxx:56
ClarisWksStyleManager::readFontNames
bool readFontNames()
read the font name style zone (method to store font names in v2/v3 files)
Definition: ClarisWksStyleManager.cxx:2175
MWAWBorder::LargeDot
@ LargeDot
Definition: libmwaw_internal.hxx:335
ClarisWksStyleManager::getRulerName
bool getRulerName(int id, std::string &name) const
return the name corresponding to a styleId
Definition: ClarisWksStyleManager.cxx:1610
ClarisWksStyleManagerInternal::Gradient::operator<<
friend std::ostream & operator<<(std::ostream &o, Gradient const &gr)
operator<<
Definition: ClarisWksStyleManager.cxx:117
libmwaw::DebugFile
an interface used to insert comment in a binary file, written in ascii form (if debug_with_files is n...
Definition: MWAWDebug.hxx:66
ClarisWksStyleManagerInternal::State::getFontId
int getFontId(int localId) const
return a mac font id corresponding to a local id
Definition: ClarisWksStyleManager.cxx:229
ClarisWksStyleManagerInternal::State::m_gradientList
std::vector< Gradient > m_gradientList
a list gradientId -> gradient
Definition: ClarisWksStyleManager.cxx:259
MWAWFont::Line::Double
@ Double
Definition: MWAWFont.hxx:51
ClarisWksStyleManager::getColor
bool getColor(int id, MWAWColor &col) const
return the color which corresponds to an id (if possible)
Definition: ClarisWksStyleManager.cxx:1637
ClarisWksStruct::Struct
a basic structure
Definition: ClarisWksStruct.hxx:53
MWAWBorder::Single
@ Single
Definition: libmwaw_internal.hxx:337
MWAWInputStream.hxx
ClarisWksStyleManager::readPatternList
bool readPatternList(long endPos=-1)
reads a pattern map zone ( v2)
Definition: ClarisWksStyleManager.cxx:1758
ClarisWksStyleManager::readFontAndPos
bool readFontAndPos(int id, int &posC, MWAWFont &font)
try to read a font
Definition: ClarisWksStyleManager.cxx:2381
MWAWCell::HALIGN_LEFT
@ HALIGN_LEFT
Definition: MWAWCell.hxx:128
ClarisWksStyleManager::CellFormat
the CELL structure a structure related to number/date format
Definition: ClarisWksStyleManager.hxx:151
ClarisWksStyleManager::Style::m_rulerId
int m_rulerId
the ruler
Definition: ClarisWksStyleManager.hxx:230
MWAWBox2< int >
MWAWFont
Class to store font.
Definition: MWAWFont.hxx:44
MWAWCell
a structure used to define a cell and its format
Definition: MWAWCell.hxx:53
ClarisWksStyleManagerInternal::Gradient::m_angle
int m_angle
the angle
Definition: ClarisWksStyleManager.cxx:154
MWAWGraphicStyle::Gradient::G_Radial
@ G_Radial
Definition: MWAWGraphicStyle.hxx:177
ClarisWksStyleManager::readStyleFonts
bool readStyleFonts(int N, int fSz)
read a STYL_CHAR Font sequence
Definition: ClarisWksStyleManager.cxx:2484
ClarisWksStyleManager::Style::m_styleId
int m_styleId
the style id
Definition: ClarisWksStyleManager.hxx:242
ClarisWksStyleManagerInternal::State::m_graphList
std::vector< MWAWGraphicStyle > m_graphList
the Graphic list
Definition: ClarisWksStyleManager.cxx:249
ClarisWksStyleManager::readStyles
bool readStyles(MWAWEntry const &entry)
try to read the styles definition (in v4-6)
Definition: ClarisWksStyleManager.cxx:1921
ClarisWksStyleManager::m_document
ClarisWksDocument * m_document
the document
Definition: ClarisWksStyleManager.hxx:139
ClarisWksStyleManager::~ClarisWksStyleManager
~ClarisWksStyleManager()
destructor
Definition: ClarisWksStyleManager.cxx:1600
MWAWCell::HALIGN_RIGHT
@ HALIGN_RIGHT
Definition: MWAWCell.hxx:128
MWAWVec2i
MWAWVec2< int > MWAWVec2i
MWAWVec2 of int.
Definition: libmwaw_internal.hxx:838
libmwaw::DebugStream
std::stringstream DebugStream
a basic stream (if debug_with_files is not defined, does nothing)
Definition: MWAWDebug.hxx:61
ClarisWksStyleManager::m_state
std::shared_ptr< ClarisWksStyleManagerInternal::State > m_state
the state
Definition: ClarisWksStyleManager.hxx:143
MWAWParser.hxx
ClarisWksStyleManager::readKSEN
bool readKSEN(int N, int fSz)
read a KSEN sequence
Definition: ClarisWksStyleManager.cxx:2731
ClarisWksStyleManager::CellFormat::m_extra
std::string m_extra
extra data
Definition: ClarisWksStyleManager.hxx:178
ClarisWksStyleManager::Style::m_fontId
int m_fontId
the char
Definition: ClarisWksStyleManager.hxx:226
MWAWFont::setUnderlineStyle
void setUnderlineStyle(Line::Style style=Line::None, bool doReset=true)
sets the underline style ( by default, we also reset the style)
Definition: MWAWFont.hxx:466
MWAWGraphicStyle::Gradient::m_stopList
std::vector< Stop > m_stopList
the list of gradient limits
Definition: MWAWGraphicStyle.hxx:262
ClarisWksStyleManager::readLookUp
bool readLookUp(int N, int fSz)
try to read the lookup zone
Definition: ClarisWksStyleManager.cxx:2134
MWAWCell::Format::m_thousandHasSeparator
bool m_thousandHasSeparator
true if we must separate the thousand
Definition: MWAWCell.hxx:107
ClarisWksDocument::getTextParser
std::shared_ptr< ClarisWksText > getTextParser()
returns the text parser
Definition: ClarisWksDocument.hxx:164
ClarisWksStyleManager::KSEN::KSEN
KSEN()
constructor
Definition: ClarisWksStyleManager.hxx:184
MWAWCell::HALIGN_CENTER
@ HALIGN_CENTER
Definition: MWAWCell.hxx:128
MWAWFont::setFlags
void setFlags(uint32_t fl)
sets the font attributes bold, ...
Definition: MWAWFont.hxx:325

Generated on Fri Sep 18 2020 18:14:52 for libmwaw by doxygen 1.8.20