Go to the documentation of this file.
   23 #ifndef LIBWPS_INTERNAL_H 
   24 #define LIBWPS_INTERNAL_H 
   39 #include <librevenge-stream/librevenge-stream.h> 
   40 #include <librevenge/librevenge.h> 
   43 #define M_PI 3.14159265358979323846 
   46 #if defined(_MSC_VER) || defined(__DJGPP__) 
   47 typedef signed char int8_t;
 
   48 typedef unsigned char uint8_t;
 
   49 typedef signed short int16_t;
 
   50 typedef unsigned short uint16_t;
 
   51 typedef signed int int32_t;
 
   52 typedef unsigned int uint32_t;
 
   54 #  include <inttypes.h> 
   65 #  define gmtime_r(tp,tmp) (gmtime(tp)?(*(tmp)=*gmtime(tp),(tmp)):0) 
   66 #  define localtime_r(tp,tmp) (localtime(tp)?(*(tmp)=*localtime(tp),(tmp)):0) 
   77 #if defined(HAVE_CLANG_ATTRIBUTE_FALLTHROUGH) 
   78 #  define WPS_FALLTHROUGH [[clang::fallthrough]] 
   79 #elif defined(HAVE_GCC_ATTRIBUTE_FALLTHROUGH) 
   80 #  define WPS_FALLTHROUGH __attribute__((fallthrough)) 
   82 #  define WPS_FALLTHROUGH ((void) 0) 
  118 #if defined(HAVE_FUNC_ATTRIBUTE_FORMAT) 
  119 #  define WPS_ATTRIBUTE_PRINTF(fmt, arg) __attribute__((format(printf, fmt, arg))) 
  121 #  define WPS_ATTRIBUTE_PRINTF(fmt, arg) 
  124 #define WPS_N_ELEMENTS(m) sizeof(m)/sizeof(m[0]) 
  132 #define WPS_DEBUG_MSG(M) libwps::printDebugMsg M 
  134 #define WPS_DEBUG_MSG(M) 
  170 uint8_t 
readU8(librevenge::RVNGInputStream *input);
 
  171 uint16_t 
readU16(librevenge::RVNGInputStream *input);
 
  172 uint32_t 
readU32(librevenge::RVNGInputStream *input);
 
  174 int8_t 
read8(librevenge::RVNGInputStream *input);
 
  175 int16_t 
read16(librevenge::RVNGInputStream *input);
 
  176 int32_t 
read32(librevenge::RVNGInputStream *input);
 
  180         return readU8(input.get());
 
  193         return read8(input.get());
 
  197         return read16(input.get());
 
  201         return read32(input.get());
 
  220 void appendUnicode(uint32_t val, librevenge::RVNGString &buffer);
 
  223 #define WPS_LE_GET_GUINT16(p)                                                                                   \ 
  224         uint16_t(((reinterpret_cast<uint8_t const *>(p))[0] << 0)  |    \ 
  225                   ((reinterpret_cast<uint8_t const *>(p))[1] << 8)) 
  226 #define WPS_LE_GET_GUINT32(p)                                                   \ 
  227         uint32_t(((reinterpret_cast<uint8_t const *>(p))[0] << 0) |                     \ 
  228                   ((reinterpret_cast<uint8_t const *>(p))[1] << 8)  |   \ 
  229                   ((reinterpret_cast<uint8_t const *>(p))[2] << 16) |   \ 
  230                   ((reinterpret_cast<uint8_t const *>(p))[3] << 24)) 
  232 #define WPS_LE_PUT_GUINT16(p, v)                                                                                \ 
  233         *(reinterpret_cast<uint8_t*>(p)) = uint8_t(v);                                          \ 
  234         *((reinterpret_cast<uint8_t*>(p)) + 1) = uint8_t((v) >> 8) 
  236 #define WPS_LE_PUT_GUINT32(p, v)                                                                                \ 
  237         *(reinterpret_cast<uint8_t*>(p)) = uint8_t(v);                                          \ 
  238         *((reinterpret_cast<uint8_t*>(p)) + 1) = uint8_t((v) >> 8);                     \ 
  239         *((reinterpret_cast<uint8_t*>(p)) + 2) = uint8_t((v) >> 16);            \ 
  240         *((reinterpret_cast<uint8_t*>(p)) + 3) = uint8_t((v) >> 24) 
  287         WPSColor(
unsigned char r, 
unsigned char g,  
unsigned char b, 
unsigned char a=255) :
 
  288                 m_value(uint32_t((a<<24)+(r<<16)+(g<<8)+b))
 
  327                 return static_cast<unsigned char>((
m_value>>24)&0xFF);
 
  332                 return static_cast<unsigned char>(
m_value&0xFF);
 
  337                 return static_cast<unsigned char>((
m_value>>16)&0xFF);
 
  342                 return static_cast<unsigned char>((
m_value>>8)&0xFF);
 
  352                 return (
m_value&0xFFFFFF)==0xFFFFFF;
 
  387         std::string 
str() 
const;
 
  420         bool addTo(librevenge::RVNGPropertyList &propList, std::string which=
"") 
const;
 
  480         bool addTo(librevenge::RVNGPropertyList &propList) 
const;
 
  482         librevenge::RVNGString 
getString() 
const;
 
  494 #define WPS_EXTRA_LARGE_BIT 1 
  495 #define WPS_VERY_LARGE_BIT 2 
  496 #define WPS_LARGE_BIT 4 
  497 #define WPS_SMALL_PRINT_BIT 8 
  498 #define WPS_FINE_PRINT_BIT 0x10 
  499 #define WPS_SUPERSCRIPT_BIT 0x20 
  500 #define WPS_SUBSCRIPT_BIT 0x40 
  501 #define WPS_OUTLINE_BIT 0x80 
  502 #define WPS_ITALICS_BIT 0x100 
  503 #define WPS_SHADOW_BIT 0x200 
  504 #define WPS_REDLINE_BIT 0x400 
  505 #define WPS_DOUBLE_UNDERLINE_BIT 0x800 
  506 #define WPS_BOLD_BIT 0x1000 
  507 #define WPS_STRIKEOUT_BIT 0x2000 
  508 #define WPS_UNDERLINE_BIT 0x4000 
  509 #define WPS_SMALL_CAPS_BIT 0x8000 
  510 #define WPS_BLINK_BIT 0x10000L 
  511 #define WPS_REVERSEVIDEO_BIT 0x20000L 
  512 #define WPS_ALL_CAPS_BIT 0x40000L 
  513 #define WPS_EMBOSS_BIT 0x80000L 
  514 #define WPS_ENGRAVE_BIT 0x100000L 
  515 #define WPS_OVERLINE_BIT 0x400000L 
  516 #define WPS_HIDDEN_BIT 0x800000L 
  519 #define WPS_PAGE_BREAK 0x00 
  520 #define WPS_SOFT_PAGE_BREAK 0x01 
  521 #define WPS_COLUMN_BREAK 0x02 
  524 #define WPS_LEFT 0x00 
  525 #define WPS_RIGHT 0x01 
  526 #define WPS_CENTER 0x02 
  528 #define WPS_BOTTOM 0x04 
  555                 return (c==0) ? 
m_x : 
m_y;
 
  561                 return (c==0) ? 
m_x : 
m_y;
 
  668                 o << f.
m_x << 
"x" << f.
m_y;
 
  680                         return s1.
cmp(s2) < 0;
 
  692                         return s1.
cmpY(s2) < 0;
 
  721                 for (
int c=0; c < 2; c++) m_pt[c] = Vec2<T>(p[c]);
 
  795                 m_pt[0] = ctr - 0.5*sz;
 
  796                 m_pt[1] = ctr + (sz - 0.5*sz);
 
  800         template <
class U> 
void scale(U factor)
 
  853                 if (diff) 
return diff;
 
  855                 if (diff) 
return diff;
 
  862                 o << 
"(" << f.
m_pt[0] << 
"<->" << f.
m_pt[1] << 
")";
 
  874                         return s1.
cmp(s2) < 0;
 
  880         typedef std::map<WPSBox2<T>, T,
struct PosSizeLt> 
Map;
 
  908                 for (
int c = 0; c < 3; c++) 
m_val[c] = T(p[c]);
 
  940         void set(T xx, T yy, T zz)
 
  963         void add(T dx, T dy, T dz)
 
  986                 for (
auto &c : 
m_val) c = T(c*scale);
 
 1028                 for (
int c = 0; c < 3; c++)
 
 1051                         return s1.
cmp(s2) < 0;
 
 1057         typedef std::map<WPSVec3<T>, T,
struct PosSizeLt> 
Map;
 
 1090                 add(binaryData, type);
 
 1105         void add(librevenge::RVNGBinaryData 
const &binaryData, std::string 
const &type=
"image/pict")
 
 1115         bool addTo(librevenge::RVNGPropertyList &propList) 
const;
 
 1173                 for (
int coord=0; coord<2; ++coord)
 
 1177                         for (
int i=0; i<2; ++i)
 
 1178                                 value+=row[i]*dir[i];
 
 1194                 for (
int row=0; row<2; ++row)
 
 1197                         for (
int col=0; col<3; ++col)
 
 1200                                 for (
int i=0; i<3; ++i)
 
 1201                                         value+=(*
this)[row][i]*(i==2 ? (col==2 ? 1.f : 0.f) : mat[i][col]);
 
 1287 bool encodeLotusPassword(
char const *password, uint16_t &key, std::vector<uint8_t> &keys, uint8_t 
const(&defValues)[16]);
 
  
 
bool operator()(Vec2< T > const &s1, Vec2< T > const &s2) const
comparaison function
Definition: libwps_internal.h:678
void setX(T xx)
resets the first element
Definition: libwps_internal.h:947
Vec2< T > center() const
the box center
Definition: libwps_internal.h:759
WPSBox2(WPSBox2< U > const &p)
generic constructor
Definition: libwps_internal.h:719
virtual class to define a sub document
Definition: WPSSubDocument.h:33
WPSBox2(Vec2< T > minPt=Vec2< T >(), Vec2< T > maxPt=Vec2< T >())
constructor
Definition: libwps_internal.h:713
static WPSColor white()
return the white color
Definition: libwps_internal.h:311
WPSBox2< T > getIntersection(WPSBox2< T > const &box) const
returns the intersection between this and box
Definition: libwps_internal.h:823
T m_val[3]
the values
Definition: libwps_internal.h:1061
std::map< WPSBox2< int >, int, struct PosSizeLt > Map
map of WPSBox2
Definition: libwps_internal.h:880
std::string numberingTypeToString(NumberingType type)
Definition: libwps_internal.cpp:357
a field
Definition: libwps_internal.h:462
bool operator!=(WPSBox2< T > const &p) const
comparison operator!=
Definition: libwps_internal.h:839
Style
the line style
Definition: libwps_internal.h:397
Definition: libwps_internal.h:141
@ UPPERCASE_ROMAN
Definition: libwps_internal.h:246
bool operator==(Vec2< T > const &p) const
comparison==
Definition: libwps_internal.h:632
Vec2(Vec2< U > const &p)
generic copy constructor
Definition: libwps_internal.h:540
static bool convertDTFormat(std::string const &dtFormat, librevenge::RVNGPropertyListVector &propVect)
Definition: libwps_internal.cpp:426
@ PageNumber
Definition: libwps_internal.h:465
internal struct used to create sorted map, sorted by X
Definition: libwps_internal.h:675
@ Simple
Definition: libwps_internal.h:397
Vec2< T > & operator*=(U scale)
generic operator*=
Definition: libwps_internal.h:604
friend std::ostream & operator<<(std::ostream &o, WPSVec3< T > const &f)
operator<<: prints data in form "XxYxZ"
Definition: libwps_internal.h:1037
bool operator==(WPSColor const &c) const
operator==
Definition: libwps_internal.h:355
bool encodeLotusPassword(char const *password, uint16_t &key, std::vector< uint8_t > &keys, uint8_t const(&defValues)[16])
returns the checksum and the keys (to encode a lotus file) given a password file
Definition: libwps_internal.cpp:977
WPSBox2< float > WPSBox2f
WPSBox2 of float.
Definition: libwps_internal.h:890
unsigned char getBlue() const
returns the green value
Definition: libwps_internal.h:330
bool operator<(WPSVec3< T > const &p) const
comparison<: which first compares x values, then y values then z values.
Definition: libwps_internal.h:1021
@ Top
Definition: libwps_internal.h:400
WPSVec3(WPSVec3< U > const &p)
generic copy constructor
Definition: libwps_internal.h:906
void setMin(Vec2< T > const &x)
resets the minimum point
Definition: libwps_internal.h:771
bool operator!=(WPSVec3< T > const &p) const
comparison!=
Definition: libwps_internal.h:1016
bool operator()(WPSBox2< T > const &s1, WPSBox2< T > const &s2) const
comparaison function
Definition: libwps_internal.h:872
libwps::NumberingType m_numberingType
the number type ( for number field )
Definition: libwps_internal.h:488
void setY(T yy)
resets the second element
Definition: libwps_internal.h:952
WPSColor & operator=(uint32_t argb)
operator=
Definition: libwps_internal.h:296
WPSEmbeddedObject(librevenge::RVNGBinaryData const &binaryData, std::string const &type="image/pict")
constructor
Definition: libwps_internal.h:1087
bool readDouble2Inv(RVNGInputStreamPtr &input, double &res, bool &isNaN)
read a double store with 2 bytes: exponent 1.5 bytes, kind of mantisse 0.5 bytes
Definition: libwps_internal.cpp:273
@ PageNumberNext
Definition: libwps_internal.h:465
@ Title
Definition: libwps_internal.h:465
WPSVec3(T xx=0, T yy=0, T zz=0)
constructor
Definition: libwps_internal.h:899
const Vec2< T > & operator[](int c) const
the two extremum points which defined the box
Definition: libwps_internal.h:748
bool operator()(Vec2< T > const &s1, Vec2< T > const &s2) const
comparaison function
Definition: libwps_internal.h:690
void resizeFromMin(Vec2< T > const &sz)
resize the box keeping the minimum
Definition: libwps_internal.h:782
#define M_PI
Definition: libwps_internal.h:43
std::shared_ptr< WPSContentListener > WPSContentListenerPtr
shared pointer to WPSContentListener
Definition: libwps_internal.h:107
Definition: libwps_internal.cpp:38
@ Single
Definition: libwps_internal.h:399
@ BULLET
Definition: libwps_internal.h:246
@ BottomBit
Definition: libwps_internal.h:401
small structure use to store a stream and it debug file
Definition: WPSStream.h:29
Vec2< T > & min()
the minimum 2D point (in x and in y)
Definition: libwps_internal.h:735
uint32_t value() const
return the rgba value
Definition: libwps_internal.h:320
WPSEmbeddedObject & operator=(WPSEmbeddedObject const &)=default
std::vector< librevenge::RVNGBinaryData > m_dataList
the picture content: one data by representation
Definition: libwps_internal.h:1122
int cmp(Vec2< T > const &p) const
a comparison function: which first compares x then y
Definition: libwps_internal.h:647
@ Right
Definition: libwps_internal.h:400
void add(T dx, T dy)
increases the actuals values by dx and dy
Definition: libwps_internal.h:582
int m_width
the border width
Definition: libwps_internal.h:450
uint8_t m_alignment
Definition: libwps_internal.h:276
Vec2< T > & operator-=(Vec2< T > const &p)
operator-=
Definition: libwps_internal.h:596
const Vec2< T > & min() const
the minimum 2D point (in x and in y)
Definition: libwps_internal.h:725
std::shared_ptr< WKSSubDocument > WKSSubDocumentPtr
shared pointer to WKSSubDocument
Definition: libwps_internal.h:116
@ JustificationFullAllLines
Definition: libwps_internal.h:250
@ ARABIC
Definition: libwps_internal.h:246
bool isWhite() const
return true if the color is white
Definition: libwps_internal.h:350
uint32_t m_attributes
Definition: libwps_internal.h:275
NumberingType
Definition: libwps_internal.h:246
int cmp(WPSVec3< T > const &p) const
a comparison function: which first compares x values, then y values then z values.
Definition: libwps_internal.h:1026
Definition: WPSContentListener.h:44
define the font properties
Definition: WPSFont.h:36
@ Triple
Definition: libwps_internal.h:399
static WPSColor barycenter(float alpha, WPSColor const &colA, float beta, WPSColor const &colB)
return alpha*colA+beta*colB
Definition: libwps_internal.cpp:386
bool operator()(WPSVec3< T > const &s1, WPSVec3< T > const &s2) const
comparaison function
Definition: libwps_internal.h:1049
void operator()(T *)
Definition: libwps_internal.h:73
internal struct used to create sorted map, sorted by X, Y, Z
Definition: libwps_internal.h:1046
Type
Defines some basic type for field.
Definition: libwps_internal.h:465
bool operator==(WPSBorder const &orig) const
operator==
Definition: libwps_internal.h:428
friend std::ostream & operator<<(std::ostream &o, WPSBox2< T > const &f)
print data in form X0xY0<->X1xY1
Definition: libwps_internal.h:860
basic class to store an entry in a file This contained :
Definition: WPSEntry.h:38
Vec2< int > Vec2i
Vec2 of int.
Definition: libwps_internal.h:702
bool operator!=(WPSColor const &c) const
operator!=
Definition: libwps_internal.h:360
Definition: libwps_internal.h:255
T x() const
first element
Definition: libwps_internal.h:912
unsigned char getGreen() const
returns the green value
Definition: libwps_internal.h:340
std::vector< std::string > m_typeList
the picture type: one type by representation
Definition: libwps_internal.h:1124
@ DOC_TEXT_BOX
Definition: libwps_internal.h:248
std::string m_data
the database/link field ( if defined )
Definition: libwps_internal.h:490
bool readDouble10(RVNGInputStreamPtr &input, double &res, bool &isNaN)
read a double store with 10 bytes: mantisse 8 bytes, exponent 2 bytes
Definition: libwps_internal.cpp:224
bool operator<=(WPSColor const &c) const
operator<=
Definition: libwps_internal.h:370
T m_y
second element
Definition: libwps_internal.h:696
std::shared_ptr< WPSListener > WPSListenerPtr
shared pointer to WPSListener
Definition: libwps_internal.h:105
bool operator!=(WPSBorder const &orig) const
operator!=
Definition: libwps_internal.h:434
WPSColor m_color
the border color
Definition: libwps_internal.h:456
WPSBorder & operator=(WPSBorder const &)=default
double m_leftGutter
Definition: libwps_internal.h:264
WPSVec3< float > WPSVec3f
WPSVec3 of float.
Definition: libwps_internal.h:1069
bool addTo(librevenge::RVNGPropertyList &propList) const
add the link property to proplist (if possible)
Definition: libwps_internal.cpp:530
Vec2f m_size
the picture size in inches(if known)
Definition: libwps_internal.h:1120
friend WPSVec3< T > operator+(WPSVec3< T > const &p1, WPSVec3< T > const &p2)
operator+
Definition: libwps_internal.h:991
@ Left
Definition: libwps_internal.h:400
Vec2< float > Vec2f
Vec2 of float.
Definition: libwps_internal.h:704
bool operator<(Vec2< T > const &p) const
comparison<: sort by y
Definition: libwps_internal.h:642
Vec2< T > m_pt[2]
the two extremities
Definition: libwps_internal.h:884
T z() const
third element
Definition: libwps_internal.h:922
friend WPSVec3< T > operator-(WPSVec3< T > const &p1, WPSVec3< T > const &p2)
operator-
Definition: libwps_internal.h:997
WPSColumnProperties()
Definition: libwps_internal.h:270
Definition: libwps_internal.h:151
Definition: libwps_internal.h:156
Type m_type
the type
Definition: libwps_internal.h:484
small class which defines a vector with 3 elements
Definition: libwps_internal.h:895
@ TopBit
Definition: libwps_internal.h:401
void set(T xx, T yy, T zz)
resets the three elements
Definition: libwps_internal.h:940
#define WPS_DEBUG_MSG(M)
Definition: libwps_internal.h:134
uint32_t readU32(librevenge::RVNGInputStream *input)
Definition: libwps_internal.cpp:76
std::ostream & operator<<(std::ostream &o, WPSColor const &c)
Definition: libwps_internal.cpp:401
bool m_sent
a mutable flag which can be used to know if the picture was send to a listener
Definition: libwps_internal.h:1126
@ LOWERCASE_ROMAN
Definition: libwps_internal.h:246
#define WPS_FALLTHROUGH
fall through attributes
Definition: libwps_internal.h:82
WPSEmbeddedObject()
empty constructor
Definition: libwps_internal.h:1079
T x() const
first element
Definition: libwps_internal.h:542
internal struct used to create sorted map, sorted first min then max
Definition: libwps_internal.h:869
std::shared_ptr< WKSContentListener > WKSContentListenerPtr
shared pointer to WKSContentListener
Definition: libwps_internal.h:114
@ DOC_COMMENT_ANNOTATION
Definition: libwps_internal.h:248
Definition: libwps_internal.h:161
void appendUnicode(uint32_t val, librevenge::RVNGString &buffer)
adds an unicode character to a string ( with correct encoding ).
Definition: libwps_internal.cpp:836
friend Vec2< T > operator-(Vec2< T > const &p1, Vec2< T > const &p2)
operator-
Definition: libwps_internal.h:618
int32_t read32(librevenge::RVNGInputStream *input)
Definition: libwps_internal.cpp:85
@ UPPERCASE
Definition: libwps_internal.h:246
internal struct used to create sorted map, sorted by Y
Definition: libwps_internal.h:687
SubDocumentType
Definition: libwps_internal.h:248
T & operator[](int c)
operator[]
Definition: libwps_internal.h:558
virtual class for content listener
Definition: WPSListener.h:36
void setY(T yy)
resets the second element
Definition: libwps_internal.h:576
@ Date
Definition: libwps_internal.h:465
@ Bottom
Definition: libwps_internal.h:400
@ Dot
Definition: libwps_internal.h:397
WPSColor(unsigned char r, unsigned char g, unsigned char b, unsigned char a=255)
constructor from color
Definition: libwps_internal.h:287
T operator[](int c) const
operator[]
Definition: libwps_internal.h:927
librevenge::RVNGString getString() const
returns a string corresponding to the field (if possible) */
Definition: libwps_internal.cpp:584
WPSVec3< T > & operator-=(WPSVec3< T > const &p)
operator-=
Definition: libwps_internal.h:977
@ None
Definition: libwps_internal.h:465
@ RightBit
Definition: libwps_internal.h:401
friend std::ostream & operator<<(std::ostream &o, WPSBorder const &border)
operator<<
Definition: libwps_internal.cpp:743
friend Vec2< T > operator*(U scale, Vec2< T > const &p1)
generic operator*
Definition: libwps_internal.h:625
virtual ~WPSEmbeddedObject()
destructor
Definition: libwps_internal.cpp:780
bool readDouble4(RVNGInputStreamPtr &input, double &res, bool &isNaN)
read a double store with 4 bytes: mantisse 2.5 bytes, exponent 1.5 bytes
Definition: libwps_internal.cpp:90
@ DOC_HEADER_FOOTER
Definition: libwps_internal.h:248
bool readDouble4Inv(RVNGInputStreamPtr &input, double &res, bool &isNaN)
read a double store with 4 bytes: exponent 3.5 bytes, mantisse 0.5 bytes
Definition: libwps_internal.cpp:303
void set(Vec2< T > const &x, Vec2< T > const &y)
resets the data to minimum x and maximum y
Definition: libwps_internal.h:765
int cmpY(Vec2< T > const &p) const
a comparison function: which first compares y then x
Definition: libwps_internal.h:656
@ DOC_CHART_ZONE
Definition: libwps_internal.h:248
int8_t read8(librevenge::RVNGInputStream *input)
Definition: libwps_internal.cpp:59
bool isEmpty() const
return true if the picture contains no data
Definition: libwps_internal.h:1095
void add(librevenge::RVNGBinaryData const &binaryData, std::string const &type="image/pict")
add a picture
Definition: libwps_internal.h:1105
Style m_style
the border style
Definition: libwps_internal.h:446
friend WPSVec3< T > operator*(U scale, WPSVec3< T > const &p1)
generic operator*
Definition: libwps_internal.h:1004
std::shared_ptr< WPSSubDocument > WPSSubDocumentPtr
shared pointer to WPSSubDocument
Definition: libwps_internal.h:111
friend std::ostream & operator<<(std::ostream &o, Vec2< T > const &f)
operator<<: prints data in form "XxY"
Definition: libwps_internal.h:666
small class use to define a embedded object
Definition: libwps_internal.h:1076
std::string m_DTFormat
the date/time format using strftime format if defined (see strftime)
Definition: libwps_internal.h:486
WPSVec3< T > & operator*=(U scale)
generic operator*=
Definition: libwps_internal.h:984
bool readDouble8(RVNGInputStreamPtr &input, double &res, bool &isNaN)
read a double store with 8 bytes: mantisse 6.5 bytes, exponent 1.5 bytes
Definition: libwps_internal.cpp:173
WPSColumnDefinition()
Definition: libwps_internal.h:257
@ Dash
Definition: libwps_internal.h:397
std::shared_ptr< WPSHeader > WPSHeaderPtr
shared pointer to WPSHeader
Definition: libwps_internal.h:109
@ DOC_NOTE
Definition: libwps_internal.h:248
Vec2< T > & max()
the maximum 2D point (in x and in y)
Definition: libwps_internal.h:740
a structure used to defined the cell position, and a format
Definition: WPSCell.h:290
friend Vec2< T > operator+(Vec2< T > const &p1, Vec2< T > const &p2)
operator+
Definition: libwps_internal.h:612
bool isEmpty() const
returns true if the border is empty
Definition: libwps_internal.h:422
const Vec2< T > & max() const
the maximum 2D point (in x and in y)
Definition: libwps_internal.h:730
Basic class used to store a spreadsheet sub document.
Definition: WKSSubDocument.h:35
WPSField(Type type)
basic constructor
Definition: libwps_internal.h:468
bool operator!=(Vec2< T > const &p) const
comparison!=
Definition: libwps_internal.h:637
uint8_t readU8(librevenge::RVNGInputStream *input)
Definition: libwps_internal.cpp:40
a border list
Definition: libwps_internal.h:394
Definition: libwps_internal.h:268
Type
the line repetition
Definition: libwps_internal.h:399
@ DOC_NONE
Definition: libwps_internal.h:248
T & operator[](int c)
operator[]
Definition: libwps_internal.h:933
@ Link
Definition: libwps_internal.h:465
Justification
Definition: libwps_internal.h:249
bool operator>=(WPSColor const &c) const
operator>=
Definition: libwps_internal.h:380
@ PageCount
Definition: libwps_internal.h:465
WPSVec3< int > WPSVec3i
WPSVec3 of int.
Definition: libwps_internal.h:1067
void resizeFromCenter(Vec2< T > const &sz)
resize the box keeping the center
Definition: libwps_internal.h:792
int compare(WPSBorder const &orig) const
compare two cell
Definition: libwps_internal.cpp:623
bool readData(RVNGInputStreamPtr &input, unsigned long size, librevenge::RVNGBinaryData &data)
try to read sz bytes from input and store them in a librevenge::RVNGBinaryData
Definition: libwps_internal.cpp:332
double m_width
Definition: libwps_internal.h:263
void scale(U factor)
scales all points of the box by factor
Definition: libwps_internal.h:800
T m_x
first element
Definition: libwps_internal.h:696
WPSBorder()
constructor
Definition: libwps_internal.h:404
@ Time
Definition: libwps_internal.h:465
uint16_t readU16(librevenge::RVNGInputStream *input)
Definition: libwps_internal.cpp:64
void extend(T val)
extends the bdbox by (val, val) keeping the center
Definition: libwps_internal.h:807
void setMax(Vec2< T > const &y)
resets the maximum point
Definition: libwps_internal.h:776
void resizeFromMax(Vec2< T > const &sz)
resize the box keeping the maximum
Definition: libwps_internal.h:787
@ DOC_TABLE
Definition: libwps_internal.h:248
@ Double
Definition: libwps_internal.h:399
std::shared_ptr< librevenge::RVNGInputStream > RVNGInputStreamPtr
shared pointer to librevenge::RVNGInputStream
Definition: libwps_internal.h:87
void setZ(T zz)
resets the third element
Definition: libwps_internal.h:957
std::vector< double > m_widthsList
the different length used for each line/sep (if defined)
Definition: libwps_internal.h:454
Class to define the position of an object (textbox, picture, ..) in the document.
Definition: WPSPosition.h:39
@ LeftBit
Definition: libwps_internal.h:401
Type m_type
the border repetition
Definition: libwps_internal.h:448
bool addTo(librevenge::RVNGPropertyList &propList) const
add the link property to proplist
Definition: libwps_internal.cpp:784
Pos
Definition: libwps_internal.h:400
Vec2< T > size() const
the box size
Definition: libwps_internal.h:754
bool readDataToEnd(RVNGInputStreamPtr &input, librevenge::RVNGBinaryData &data)
try to read the last bytes from input and store them in a librevenge::RVNGBinaryData
Definition: libwps_internal.cpp:346
bool operator>(WPSColor const &c) const
operator>
Definition: libwps_internal.h:375
@ None
Definition: libwps_internal.h:397
std::shared_ptr< WPSCell > WPSCellPtr
shared pointer to WPSCell
Definition: libwps_internal.h:100
Vec2< T > & operator+=(Vec2< T > const &p)
operator+=
Definition: libwps_internal.h:589
double m_rightGutter
Definition: libwps_internal.h:265
bool addTo(librevenge::RVNGPropertyList &propList, std::string which="") const
add the border property to proplist (if needed )
Definition: libwps_internal.cpp:641
WPSField & operator=(WPSField const &)=default
@ LOWERCASE
Definition: libwps_internal.h:246
int16_t read16(librevenge::RVNGInputStream *input)
Definition: libwps_internal.cpp:71
#define WPS_ATTRIBUTE_PRINTF(fmt, arg)
Definition: libwps_internal.h:121
@ Database
Definition: libwps_internal.h:465
void set(T xx, T yy)
resets the two elements
Definition: libwps_internal.h:565
@ JustificationFull
Definition: libwps_internal.h:249
@ NoBreakWithNextBit
Definition: libwps_internal.h:252
uint32_t m_value
the argb color
Definition: libwps_internal.h:390
@ JustificationLeft
Definition: libwps_internal.h:249
WPSVec3< unsigned char > WPSVec3uc
WPSVec3 of unsigned char.
Definition: libwps_internal.h:1065
std::string str() const
print the color in the form #rrggbb
Definition: libwps_internal.cpp:413
unsigned char getRed() const
returns the red value
Definition: libwps_internal.h:335
the class to store a color
Definition: libwps_internal.h:280
WPSBox2< int > WPSBox2i
WPSBox2 of int.
Definition: libwps_internal.h:888
@ NoBreakBit
Definition: libwps_internal.h:252
int cmp(WPSBox2< T > const &p) const
comparison function : fist sorts min by Y,X values then max extremity
Definition: libwps_internal.h:850
small class which defines a 2D WPSBox
Definition: libwps_internal.h:709
WPSBox2< T > getUnion(WPSBox2< T > const &box) const
returns the union between this and box
Definition: libwps_internal.h:813
T y() const
second element
Definition: libwps_internal.h:917
bool operator==(WPSVec3< T > const &p) const
comparison==
Definition: libwps_internal.h:1011
Vec2< bool > Vec2b
Vec2 of bool.
Definition: libwps_internal.h:700
void setX(T xx)
resets the first element
Definition: libwps_internal.h:571
Definition: WKSContentListener.h:53
@ NONE
Definition: libwps_internal.h:246
@ LargeDot
Definition: libwps_internal.h:397
friend std::ostream & operator<<(std::ostream &o, WPSColor const &c)
operator<< in the form #rrggbb
Definition: libwps_internal.cpp:401
WPSColor(uint32_t argb=0)
constructor
Definition: libwps_internal.h:283
@ JustificationCenter
Definition: libwps_internal.h:249
WPSVec3< T > & operator+=(WPSVec3< T > const &p)
operator+=
Definition: libwps_internal.h:971
@ JustificationRight
Definition: libwps_internal.h:250
std::string m_extra
extra data ( if needed)
Definition: libwps_internal.h:458
a noop deleter used to transform a librevenge pointer in a false std::shared_ptr
Definition: libwps_internal.h:71
void add(T dx, T dy, T dz)
increases the actuals values by dx, dy, dz
Definition: libwps_internal.h:963
unsigned char getAlpha() const
returns the alpha value
Definition: libwps_internal.h:325
Definition: libwps_internal.h:146
bool operator<(WPSBox2< T > const &p) const
comparison operator< : fist sorts min by Y,X values then max extremity
Definition: libwps_internal.h:844
T y() const
second element
Definition: libwps_internal.h:547
static WPSColor black()
return the back color
Definition: libwps_internal.h:306
friend std::ostream & operator<<(std::ostream &o, WPSEmbeddedObject const &pict)
operator<<
Definition: libwps_internal.cpp:814
bool operator<(WPSColor const &c) const
operator<
Definition: libwps_internal.h:365
std::string getCellName(Vec2i const &cellPos, Vec2b const &relative)
returns the cell name corresponding to a cell's position
Definition: libwps_internal.cpp:953
Vec2(T xx=0, T yy=0)
constructor
Definition: libwps_internal.h:538
bool isBlack() const
return true if the color is black
Definition: libwps_internal.h:345
std::map< WPSVec3< int >, int, struct PosSizeLt > Map
map of WPSVec3
Definition: libwps_internal.h:1057
T operator[](int c) const
operator[]
Definition: libwps_internal.h:552
bool operator==(WPSBox2< T > const &p) const
comparison operator==
Definition: libwps_internal.h:834
Generated on Sat Apr 4 2020 09:17:11 for libwps by 
doxygen 1.8.17