libmwaw_internal.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 #ifndef LIBMWAW_INTERNAL_H
35 #define LIBMWAW_INTERNAL_H
36 #ifdef DEBUG
37 #include <stdio.h>
38 #endif
39 
40 #include <math.h>
41 
42 #include <algorithm>
43 #include <cmath>
44 #include <limits>
45 #include <map>
46 #include <memory>
47 #include <ostream>
48 #include <string>
49 #include <vector>
50 
51 #ifndef M_PI
52 #define M_PI 3.14159265358979323846
53 #endif
54 
55 #include <librevenge-stream/librevenge-stream.h>
56 #include <librevenge/librevenge.h>
57 
58 #if defined(_MSC_VER) || defined(__DJGPP__)
59 
60 typedef signed char int8_t;
61 typedef unsigned char uint8_t;
62 typedef signed short int16_t;
63 typedef unsigned short uint16_t;
64 typedef signed int int32_t;
65 typedef unsigned int uint32_t;
66 typedef unsigned __int64 uint64_t;
67 typedef __int64 int64_t;
68 
69 #else /* !_MSC_VER && !__DJGPP__*/
70 
71 # ifdef HAVE_CONFIG_H
72 
73 # include <config.h>
74 # ifdef HAVE_STDINT_H
75 # include <stdint.h>
76 # endif
77 # ifdef HAVE_INTTYPES_H
78 # include <inttypes.h>
79 # endif
80 
81 # else
82 
83 // assume that the headers are there inside LibreOffice build when no HAVE_CONFIG_H is defined
84 # include <stdint.h>
85 # include <inttypes.h>
86 
87 # endif
88 
89 #endif /* _MSC_VER || __DJGPP__ */
90 
91 // define gmtime_r and localtime_r on Windows, so that can use
92 // thread-safe functions on other environments
93 #ifdef _WIN32
94 # define gmtime_r(tp,tmp) (gmtime(tp)?(*(tmp)=*gmtime(tp),(tmp)):0)
95 # define localtime_r(tp,tmp) (localtime(tp)?(*(tmp)=*localtime(tp),(tmp)):0)
96 #endif
97 
98 /* ---------- memory --------------- */
100 template <class T>
102  void operator()(T *) {}
103 };
104 
105 #if defined(HAVE_FUNC_ATTRIBUTE_FORMAT)
106 # define LIBMWAW_ATTRIBUTE_PRINTF(fmt, arg) __attribute__((format(printf, fmt, arg)))
107 #else
108 # define LIBMWAW_ATTRIBUTE_PRINTF(fmt, arg)
109 #endif
110 
111 #define MWAW_N_ELEMENTS(m) sizeof(m)/sizeof(m[0])
112 
113 #if defined(HAVE_CLANG_ATTRIBUTE_FALLTHROUGH)
114 # define MWAW_FALLTHROUGH [[clang::fallthrough]]
115 #elif defined(HAVE_GCC_ATTRIBUTE_FALLTHROUGH)
116 # define MWAW_FALLTHROUGH __attribute__((fallthrough))
117 #else
118 # define MWAW_FALLTHROUGH ((void) 0)
119 #endif
120 
121 /* ---------- debug --------------- */
122 #ifdef DEBUG
123 namespace libmwaw
124 {
125 void printDebugMsg(const char *format, ...) LIBMWAW_ATTRIBUTE_PRINTF(1,2);
126 }
127 #define MWAW_DEBUG_MSG(M) libmwaw::printDebugMsg M
128 #else
129 #define MWAW_DEBUG_MSG(M)
130 #endif
131 
132 namespace libmwaw
133 {
134 // Various exceptions:
136 {
137 };
138 
140 {
141 };
142 
144 {
145 };
146 
148 {
149 };
150 
152 {
153 };
154 }
155 
156 /* ---------- input ----------------- */
157 namespace libmwaw
158 {
159 uint8_t readU8(librevenge::RVNGInputStream *input);
161 void appendUnicode(uint32_t val, librevenge::RVNGString &buffer);
162 
164 template<typename T>
165 bool checkAddOverflow(T x, T y)
166 {
167  return (x < 0 && y < std::numeric_limits<T>::lowest() - x)
168  || (x > 0 && y > std::numeric_limits<T>::max() - x);
169 }
170 }
171 
172 /* ---------- small enum/class ------------- */
173 namespace libmwaw
174 {
176 enum Position { Left = 0, Right = 1, Top = 2, Bottom = 3, HMiddle = 4, VMiddle = 5 };
178 enum { LeftBit = 0x01, RightBit = 0x02, TopBit=0x4, BottomBit = 0x08, HMiddleBit = 0x10, VMiddleBit = 0x20 };
179 
181 std::string numberingTypeToString(NumberingType type);
182 std::string numberingValueToString(NumberingType type, int value);
183 
187 std::string writingModeToString(WritingMode mode);
189 }
190 
192 struct MWAWColor {
194  explicit MWAWColor(uint32_t argb=0)
195  : m_value(argb)
196  {
197  }
199  MWAWColor(unsigned char r, unsigned char g, unsigned char b, unsigned char a=255)
200  : m_value(uint32_t((a<<24)+(r<<16)+(g<<8)+b))
201  {
202  }
204  MWAWColor(MWAWColor const &) = default;
206  MWAWColor(MWAWColor &&) = default;
208  MWAWColor &operator=(MWAWColor const &) = default;
210  MWAWColor &operator=(MWAWColor &&) = default;
212  MWAWColor &operator=(uint32_t argb)
213  {
214  m_value = argb;
215  return *this;
216  }
218  static MWAWColor colorFromCMYK(unsigned char c, unsigned char m, unsigned char y, unsigned char k)
219  {
220  double w=1.-static_cast<double>(k)/255.;
221  return MWAWColor
222  (static_cast<unsigned char>(255 * (1-static_cast<double>(c)/255) * w),
223  static_cast<unsigned char>(255 * (1-static_cast<double>(m)/255) * w),
224  static_cast<unsigned char>(255 * (1-static_cast<double>(y)/255) * w)
225  );
226  }
228  static MWAWColor colorFromHSL(unsigned char H, unsigned char S, unsigned char L)
229  {
230  double c=(1-((L>=128) ? (2*static_cast<double>(L)-255) : (255-2*static_cast<double>(L)))/255)*
231  static_cast<double>(S)/255;
232  double tmp=std::fmod((static_cast<double>(H)*6/255),2)-1;
233  double x=c*(1-(tmp>0 ? tmp : -tmp));
234  auto C=static_cast<unsigned char>(255*c);
235  auto M=static_cast<unsigned char>(static_cast<double>(L)-255*c/2);
236  auto X=static_cast<unsigned char>(255*x);
237  if (H<=42) return MWAWColor(static_cast<unsigned char>(M+C),static_cast<unsigned char>(M+X),static_cast<unsigned char>(M));
238  if (H<=85) return MWAWColor(static_cast<unsigned char>(M+X),static_cast<unsigned char>(M+C),static_cast<unsigned char>(M));
239  if (H<=127) return MWAWColor(static_cast<unsigned char>(M),static_cast<unsigned char>(M+C),static_cast<unsigned char>(M+X));
240  if (H<=170) return MWAWColor(static_cast<unsigned char>(M),static_cast<unsigned char>(M+X),static_cast<unsigned char>(M+C));
241  if (H<=212) return MWAWColor(static_cast<unsigned char>(M+X),static_cast<unsigned char>(M),static_cast<unsigned char>(M+C));
242  return MWAWColor(static_cast<unsigned char>(M+C),static_cast<unsigned char>(M),static_cast<unsigned char>(M+X));
243  }
245  static MWAWColor black()
246  {
247  return MWAWColor(0,0,0);
248  }
250  static MWAWColor white()
251  {
252  return MWAWColor(255,255,255);
253  }
254 
256  static MWAWColor barycenter(float alpha, MWAWColor const &colA,
257  float beta, MWAWColor const &colB);
259  uint32_t value() const
260  {
261  return m_value;
262  }
264  unsigned char getAlpha() const
265  {
266  return static_cast<unsigned char>((m_value>>24)&0xFF);
267  }
269  unsigned char getBlue() const
270  {
271  return static_cast<unsigned char>(m_value&0xFF);
272  }
274  unsigned char getRed() const
275  {
276  return static_cast<unsigned char>((m_value>>16)&0xFF);
277  }
279  unsigned char getGreen() const
280  {
281  return static_cast<unsigned char>((m_value>>8)&0xFF);
282  }
284  bool isBlack() const
285  {
286  return (m_value&0xFFFFFF)==0;
287  }
289  bool isWhite() const
290  {
291  return (m_value&0xFFFFFF)==0xFFFFFF;
292  }
294  bool operator==(MWAWColor const &c) const
295  {
296  return (c.m_value&0xFFFFFF)==(m_value&0xFFFFFF);
297  }
299  bool operator!=(MWAWColor const &c) const
300  {
301  return !operator==(c);
302  }
304  bool operator<(MWAWColor const &c) const
305  {
306  return (c.m_value&0xFFFFFF)<(m_value&0xFFFFFF);
307  }
309  bool operator<=(MWAWColor const &c) const
310  {
311  return (c.m_value&0xFFFFFF)<=(m_value&0xFFFFFF);
312  }
314  bool operator>(MWAWColor const &c) const
315  {
316  return !operator<=(c);
317  }
319  bool operator>=(MWAWColor const &c) const
320  {
321  return !operator<(c);
322  }
324  friend std::ostream &operator<< (std::ostream &o, MWAWColor const &c);
326  std::string str() const;
327 protected:
329  uint32_t m_value;
330 };
331 
333 struct MWAWBorder {
337  enum Type { Single, Double, Triple };
338 
341  : m_style(Simple)
342  , m_type(Single)
343  , m_width(1)
344  , m_widthsList()
345  , m_color(MWAWColor::black())
346  , m_extra("") { }
347  MWAWBorder(MWAWBorder const &) = default;
348  MWAWBorder(MWAWBorder &&) = default;
349  MWAWBorder &operator=(MWAWBorder const &) = default;
350  MWAWBorder &operator=(MWAWBorder &&) = default;
354  bool addTo(librevenge::RVNGPropertyList &propList, std::string which="") const;
356  bool isEmpty() const
357  {
358  return m_style==None || m_width <= 0;
359  }
361  bool operator==(MWAWBorder const &orig) const
362  {
363  return !operator!=(orig);
364  }
366  bool operator!=(MWAWBorder const &orig) const
367  {
368  return m_style != orig.m_style || m_type != orig.m_type ||
369  m_width < orig.m_width || m_width > orig.m_width || m_color != orig.m_color ||
370  m_widthsList != orig.m_widthsList;
371  }
373  int compare(MWAWBorder const &orig) const;
374 
376  friend std::ostream &operator<< (std::ostream &o, MWAWBorder const &border);
378  friend std::ostream &operator<< (std::ostream &o, MWAWBorder::Style const &style);
381 
382  // multiple borders
383 
387  double m_width;
391  std::vector<double> m_widthsList;
395  std::string m_extra;
396 };
397 
399 struct MWAWField {
402 
404  explicit MWAWField(Type type)
405  : m_type(type)
407  , m_DTFormat("")
408  , m_data("")
409  {
410  }
411  MWAWField(MWAWField &&) = default;
412  MWAWField(MWAWField const &) = default;
413  MWAWField &operator=(MWAWField const &) = default;
414  MWAWField &operator=(MWAWField &&) = default;
416  bool addTo(librevenge::RVNGPropertyList &propList) const;
418  librevenge::RVNGString getString() const;
424  std::string m_DTFormat;
426  std::string m_data;
427 };
428 
430 struct MWAWLink {
433  : m_HRef("")
434  {
435  }
436 
438  bool addTo(librevenge::RVNGPropertyList &propList) const;
439 
441  std::string m_HRef;
442 };
443 
445 struct MWAWNote {
447  enum Type { FootNote, EndNote };
449  explicit MWAWNote(Type type)
450  : m_type(type)
451  , m_label("")
452  , m_number(-1)
453  {
454  }
458  librevenge::RVNGString m_label;
460  int m_number;
461 };
462 
470  : m_dataList()
471  , m_typeList()
472  {
473  }
475  MWAWEmbeddedObject(librevenge::RVNGBinaryData const &binaryData,
476  std::string const &type="image/pict") : m_dataList(), m_typeList()
477  {
478  add(binaryData, type);
479  }
480  MWAWEmbeddedObject(MWAWEmbeddedObject const &)=default;
485  bool isEmpty() const
486  {
487  for (auto const &data : m_dataList) {
488  if (!data.empty())
489  return false;
490  }
491  return true;
492  }
494  void add(librevenge::RVNGBinaryData const &binaryData, std::string const &type="image/pict")
495  {
496  size_t pos=m_dataList.size();
497  if (pos<m_typeList.size()) pos=m_typeList.size();
498  m_dataList.resize(pos+1);
499  m_dataList[pos]=binaryData;
500  m_typeList.resize(pos+1);
501  m_typeList[pos]=type;
502  }
504  bool addTo(librevenge::RVNGPropertyList &propList) const;
506  friend std::ostream &operator<<(std::ostream &o, MWAWEmbeddedObject const &pict);
508  int cmp(MWAWEmbeddedObject const &pict) const;
509 
511  std::vector<librevenge::RVNGBinaryData> m_dataList;
513  std::vector<std::string> m_typeList;
514 };
515 
516 // forward declarations of basic classes and smart pointers
517 class MWAWEntry;
518 class MWAWFont;
519 class MWAWGraphicEncoder;
520 class MWAWGraphicShape;
521 class MWAWGraphicStyle;
522 class MWAWHeader;
523 class MWAWList;
524 class MWAWPageSpan;
525 class MWAWParagraph;
526 class MWAWParser;
527 class MWAWPosition;
528 class MWAWSection;
529 
530 class MWAWFontConverter;
531 class MWAWFontManager;
532 class MWAWGraphicListener;
533 class MWAWInputStream;
534 class MWAWListener;
535 class MWAWListManager;
536 class MWAWParserState;
538 class MWAWRSRCParser;
540 class MWAWSubDocument;
543 typedef std::shared_ptr<MWAWFontConverter> MWAWFontConverterPtr;
545 typedef std::shared_ptr<MWAWFontManager> MWAWFontManagerPtr;
547 typedef std::shared_ptr<MWAWGraphicListener> MWAWGraphicListenerPtr;
549 typedef std::shared_ptr<MWAWInputStream> MWAWInputStreamPtr;
551 typedef std::shared_ptr<MWAWListener> MWAWListenerPtr;
553 typedef std::shared_ptr<MWAWListManager> MWAWListManagerPtr;
555 typedef std::shared_ptr<MWAWParserState> MWAWParserStatePtr;
557 typedef std::shared_ptr<MWAWPresentationListener> MWAWPresentationListenerPtr;
559 typedef std::shared_ptr<MWAWRSRCParser> MWAWRSRCParserPtr;
561 typedef std::shared_ptr<MWAWSpreadsheetListener> MWAWSpreadsheetListenerPtr;
563 typedef std::shared_ptr<MWAWSubDocument> MWAWSubDocumentPtr;
565 typedef std::shared_ptr<MWAWTextListener> MWAWTextListenerPtr;
566 
575 template <class T> struct MWAWVariable {
578  : m_data()
579  , m_set(false) {}
581  explicit MWAWVariable(T const &def)
582  : m_data(def)
583  , m_set(false) {}
586  : m_data(orig.m_data)
587  , m_set(orig.m_set) {}
589  MWAWVariable &operator=(MWAWVariable const &) = default;
591  MWAWVariable &operator=(T const &val)
592  {
593  m_data = val;
594  m_set = true;
595  return std::forward<MWAWVariable &>(*this);
596  }
598  void insert(MWAWVariable const &orig)
599  {
600  if (orig.m_set) {
601  m_data = orig.m_data;
602  m_set = orig.m_set;
603  }
604  }
606  T const *operator->() const
607  {
608  return &m_data;
609  }
612  {
613  m_set = true;
614  return &m_data;
615  }
617  T const &operator*() const
618  {
619  return m_data;
620  }
623  {
624  m_set = true;
625  return m_data;
626  }
628  T const &get() const
629  {
630  return m_data;
631  }
633  bool isSet() const
634  {
635  return m_set;
636  }
638  void setSet(bool newVal)
639  {
640  m_set=newVal;
641  }
642 protected:
646  bool m_set;
647 };
648 
649 /* ---------- vec2/box2f ------------- */
653 template <class T> class MWAWVec2
654 {
655 public:
657  explicit MWAWVec2(T xx=0,T yy=0)
658  : m_x(xx)
659  , m_y(yy) { }
661  template <class U> explicit MWAWVec2(MWAWVec2<U> const &p)
662  : m_x(T(p.x()))
663  , m_y(T(p.y())) {}
664 
666  T x() const
667  {
668  return m_x;
669  }
671  T y() const
672  {
673  return m_y;
674  }
676  T operator[](int c) const
677  {
678  if (c<0 || c>1) throw libmwaw::GenericException();
679  return (c==0) ? m_x : m_y;
680  }
682  T &operator[](int c)
683  {
684  if (c<0 || c>1) throw libmwaw::GenericException();
685  return (c==0) ? m_x : m_y;
686  }
687 
689  void set(T xx, T yy)
690  {
691  m_x = xx;
692  m_y = yy;
693  }
695  void setX(T xx)
696  {
697  m_x = xx;
698  }
700  void setY(T yy)
701  {
702  m_y = yy;
703  }
704 
706  void add(T dx, T dy)
707  {
710  m_x += dx;
711  m_y += dy;
712  }
713 
716  {
717  add(p.m_x, p.m_y);
718  return *this;
719  }
722  {
723  // check if negation of either of the coords will cause overflow
724  const T diff = std::numeric_limits<T>::min() + std::numeric_limits<T>::max();
727  add(-p.m_x, -p.m_y);
728  return *this;
729  }
731  template <class U>
733  {
734  m_x = T(m_x*scale);
735  m_y = T(m_y*scale);
736  return *this;
737  }
738 
740  friend MWAWVec2<T> operator+(MWAWVec2<T> const &p1, MWAWVec2<T> const &p2)
741  {
742  MWAWVec2<T> p(p1);
743  return p+=p2;
744  }
746  friend MWAWVec2<T> operator-(MWAWVec2<T> const &p1, MWAWVec2<T> const &p2)
747  {
748  MWAWVec2<T> p(p1);
749  return p-=p2;
750  }
752  template <class U>
753  friend MWAWVec2<T> operator*(U scale, MWAWVec2<T> const &p1)
754  {
755  MWAWVec2<T> p(p1);
756  return p *= scale;
757  }
758 
760  bool operator==(MWAWVec2<T> const &p) const
761  {
762  return cmpY(p) == 0;
763  }
765  bool operator!=(MWAWVec2<T> const &p) const
766  {
767  return cmpY(p) != 0;
768  }
770  bool operator<(MWAWVec2<T> const &p) const
771  {
772  return cmpY(p) < 0;
773  }
775  int cmp(MWAWVec2<T> const &p) const
776  {
777  if (m_x < p.m_x) return -1;
778  if (m_x > p.m_x) return 1;
779  if (m_y < p.m_y) return -1;
780  if (m_y > p.m_y) return 1;
781  return 0;
782  }
784  int cmpY(MWAWVec2<T> const &p) const
785  {
786  if (m_y < p.m_y) return -1;
787  if (m_y > p.m_y) return 1;
788  if (m_x < p.m_x) return -1;
789  if (m_x > p.m_x) return 1;
790  return 0;
791  }
792 
794  friend std::ostream &operator<< (std::ostream &o, MWAWVec2<T> const &f)
795  {
796  o << f.m_x << "x" << f.m_y;
797  return o;
798  }
799 
803  struct PosSizeLtX {
805  bool operator()(MWAWVec2<T> const &s1, MWAWVec2<T> const &s2) const
806  {
807  return s1.cmp(s2) < 0;
808  }
809  };
813  typedef std::map<MWAWVec2<T>, T,struct PosSizeLtX> MapX;
814 
818  struct PosSizeLtY {
820  bool operator()(MWAWVec2<T> const &s1, MWAWVec2<T> const &s2) const
821  {
822  return s1.cmpY(s2) < 0;
823  }
824  };
828  typedef std::map<MWAWVec2<T>, T,struct PosSizeLtY> MapY;
829 protected:
830  T m_x, m_y;
831 };
832 
841 
845 template <class T> class MWAWVec3
846 {
847 public:
849  explicit MWAWVec3(T xx=0,T yy=0,T zz=0)
850  {
851  m_val[0] = xx;
852  m_val[1] = yy;
853  m_val[2] = zz;
854  }
856  template <class U> explicit MWAWVec3(MWAWVec3<U> const &p)
857  {
858  for (int c = 0; c < 3; c++) m_val[c] = T(p[c]);
859  }
860 
862  T x() const
863  {
864  return m_val[0];
865  }
867  T y() const
868  {
869  return m_val[1];
870  }
872  T z() const
873  {
874  return m_val[2];
875  }
877  T operator[](int c) const
878  {
879  if (c<0 || c>2) throw libmwaw::GenericException();
880  return m_val[c];
881  }
883  T &operator[](int c)
884  {
885  if (c<0 || c>2) throw libmwaw::GenericException();
886  return m_val[c];
887  }
888 
890  void set(T xx, T yy, T zz)
891  {
892  m_val[0] = xx;
893  m_val[1] = yy;
894  m_val[2] = zz;
895  }
897  void setX(T xx)
898  {
899  m_val[0] = xx;
900  }
902  void setY(T yy)
903  {
904  m_val[1] = yy;
905  }
907  void setZ(T zz)
908  {
909  m_val[2] = zz;
910  }
911 
913  void add(T dx, T dy, T dz)
914  {
915  m_val[0] += dx;
916  m_val[1] += dy;
917  m_val[2] += dz;
918  }
919 
922  {
923  for (int c = 0; c < 3; c++) m_val[c] = T(m_val[c]+p.m_val[c]);
924  return *this;
925  }
928  {
929  for (int c = 0; c < 3; c++) m_val[c] = T(m_val[c]-p.m_val[c]);
930  return *this;
931  }
933  template <class U>
935  {
936  for (auto &c : m_val) c = T(c*scale);
937  return *this;
938  }
939 
941  friend MWAWVec3<T> operator+(MWAWVec3<T> const &p1, MWAWVec3<T> const &p2)
942  {
943  MWAWVec3<T> p(p1);
944  return p+=p2;
945  }
947  friend MWAWVec3<T> operator-(MWAWVec3<T> const &p1, MWAWVec3<T> const &p2)
948  {
949  MWAWVec3<T> p(p1);
950  return p-=p2;
951  }
953  template <class U>
954  friend MWAWVec3<T> operator*(U scale, MWAWVec3<T> const &p1)
955  {
956  MWAWVec3<T> p(p1);
957  return p *= scale;
958  }
959 
961  bool operator==(MWAWVec3<T> const &p) const
962  {
963  return cmp(p) == 0;
964  }
966  bool operator!=(MWAWVec3<T> const &p) const
967  {
968  return cmp(p) != 0;
969  }
971  bool operator<(MWAWVec3<T> const &p) const
972  {
973  return cmp(p) < 0;
974  }
976  int cmp(MWAWVec3<T> const &p) const
977  {
978  for (int c = 0; c < 3; c++) {
979  if (m_val[c]<p.m_val[c]) return -1;
980  if (m_val[c]>p.m_val[c]) return 1;
981  }
982  return 0;
983  }
984 
986  friend std::ostream &operator<< (std::ostream &o, MWAWVec3<T> const &f)
987  {
988  o << f.m_val[0] << "x" << f.m_val[1] << "x" << f.m_val[2];
989  return o;
990  }
991 
995  struct PosSizeLt {
997  bool operator()(MWAWVec3<T> const &s1, MWAWVec3<T> const &s2) const
998  {
999  return s1.cmp(s2) < 0;
1000  }
1001  };
1005  typedef std::map<MWAWVec3<T>, T,struct PosSizeLt> Map;
1006 
1007 protected:
1009  T m_val[3];
1010 };
1011 
1018 
1022 template <class T> class MWAWBox2
1023 {
1024 public:
1027  : m_data(minPt, maxPt)
1028  {
1029  }
1031  template <class U> explicit MWAWBox2(MWAWBox2<U> const &p)
1032  : m_data(MWAWVec2<T>(p.min()), MWAWVec2<T>(p.max()))
1033  {
1034  }
1035 
1037  MWAWVec2<T> const &min() const
1038  {
1039  return m_data.first;
1040  }
1042  MWAWVec2<T> const &max() const
1043  {
1044  return m_data.second;
1045  }
1048  {
1049  return m_data.first;
1050  }
1053  {
1054  return m_data.second;
1055  }
1059  MWAWVec2<T> const &operator[](int c) const
1060  {
1061  if (c<0 || c>1) throw libmwaw::GenericException();
1062  return c==0 ? m_data.first : m_data.second;
1063  }
1066  {
1067  return m_data.second-m_data.first;
1068  }
1071  {
1072  return MWAWVec2<T>((m_data.first.x()+m_data.second.x())/2,
1073  (m_data.first.y()+m_data.second.y())/2);
1074  }
1075 
1077  void set(MWAWVec2<T> const &x, MWAWVec2<T> const &y)
1078  {
1079  m_data.first = x;
1080  m_data.second = y;
1081  }
1083  void setMin(MWAWVec2<T> const &x)
1084  {
1085  m_data.first = x;
1086  }
1088  void setMax(MWAWVec2<T> const &y)
1089  {
1090  m_data.second = y;
1091  }
1092 
1094  void resizeFromMin(MWAWVec2<T> const &sz)
1095  {
1096  m_data.second = m_data.first+sz;
1097  }
1099  void resizeFromMax(MWAWVec2<T> const &sz)
1100  {
1101  m_data.first = m_data.second-sz;
1102  }
1105  {
1106  MWAWVec2<T> centerPt = center();
1107  MWAWVec2<T> decal(sz.x()/2,sz.y()/2);
1108  m_data.first = centerPt - decal;
1109  m_data.second = centerPt + (sz - decal);
1110  }
1111 
1113  template <class U> void scale(U factor)
1114  {
1115  m_data.first *= factor;
1116  m_data.second *= factor;
1117  }
1118 
1120  void extend(T val)
1121  {
1122  m_data.first -= MWAWVec2<T>(val/2,val/2);
1123  m_data.second += MWAWVec2<T>(val-(val/2),val-(val/2));
1124  }
1125 
1128  {
1129  MWAWBox2<T> res;
1130  res.m_data.first=MWAWVec2<T>(m_data.first[0]<box.m_data.first[0]?m_data.first[0] : box.m_data.first[0],
1131  m_data.first[1]<box.m_data.first[1]?m_data.first[1] : box.m_data.first[1]);
1132  res.m_data.second=MWAWVec2<T>(m_data.second[0]>box.m_data.second[0]?m_data.second[0] : box.m_data.second[0],
1133  m_data.second[1]>box.m_data.second[1]?m_data.second[1] : box.m_data.second[1]);
1134  return res;
1135  }
1138  {
1139  MWAWBox2<T> res;
1140  res.m_data.first=MWAWVec2<T>(m_data.first[0]>box.m_data.first[0]?m_data.first[0] : box.m_data.first[0],
1141  m_data.first[1]>box.m_data.first[1]?m_data.first[1] : box.m_data.first[1]);
1142  res.m_data.second=MWAWVec2<T>(m_data.second[0]<box.m_data.second[0]?m_data.second[0] : box.m_data.second[0],
1143  m_data.second[1]<box.m_data.second[1]?m_data.second[1] : box.m_data.second[1]);
1144  return res;
1145  }
1147  bool operator==(MWAWBox2<T> const &mat) const
1148  {
1149  return m_data==mat.m_data;
1150  }
1152  bool operator!=(MWAWBox2<T> const &mat) const
1153  {
1154  return m_data!=mat.m_data;
1155  }
1157  bool operator<(MWAWBox2<T> const &mat) const
1158  {
1159  return m_data<mat.m_data;
1160  }
1162  bool operator<=(MWAWBox2<T> const &mat) const
1163  {
1164  return m_data<=mat.m_data;
1165  }
1167  bool operator>(MWAWBox2<T> const &mat) const
1168  {
1169  return m_data>mat.m_data;
1170  }
1172  bool operator>=(MWAWBox2<T> const &mat) const
1173  {
1174  return m_data>=mat.m_data;
1175  }
1177  friend std::ostream &operator<< (std::ostream &o, MWAWBox2<T> const &f)
1178  {
1179  o << "(" << f.min() << "<->" << f.max() << ")";
1180  return o;
1181  }
1182 
1183 protected:
1185  std::pair<MWAWVec2<T>, MWAWVec2<T> > m_data;
1186 };
1187 
1194 
1197 {
1198 public:
1200  explicit MWAWTransformation(MWAWVec3f const &xRow=MWAWVec3f(1,0,0), MWAWVec3f const &yRow=MWAWVec3f(0,1,0))
1201  : m_data(xRow, yRow)
1202  , m_isIdentity(false)
1203  {
1204  checkIdentity();
1205  }
1207  bool isIdentity() const
1208  {
1209  return m_isIdentity;
1210  }
1212  void checkIdentity() const
1213  {
1214  m_isIdentity= m_data.first==MWAWVec3f(1,0,0) && m_data.second==MWAWVec3f(0,1,0);
1215  }
1219  MWAWVec3f const &operator[](int c) const
1220  {
1221  if (c<0 || c>1) throw libmwaw::GenericException();
1222  return c==0 ? m_data.first : m_data.second;
1223  }
1225  MWAWVec2f operator*(MWAWVec2f const &pt) const
1226  {
1227  if (m_isIdentity) return pt;
1228  return multiplyDirection(pt)+MWAWVec2f(m_data.first[2],m_data.second[2]);
1229  }
1232  {
1233  if (m_isIdentity) return dir;
1234  MWAWVec2f res;
1235  for (int coord=0; coord<2; ++coord) {
1236  MWAWVec3f const &row=coord==0 ? m_data.first : m_data.second;
1237  float value=0;
1238  for (int i=0; i<2; ++i)
1239  value+=row[i]*dir[i];
1240  res[coord]=value;
1241  }
1242  return res;
1243  }
1245  MWAWBox2f operator*(MWAWBox2f const &box) const
1246  {
1247  if (m_isIdentity) return box;
1248  return MWAWBox2f(operator*(box.min()), operator*(box.max()));
1249  }
1252  {
1253  if (mat.m_isIdentity) return *this;
1254  MWAWTransformation res;
1255  for (int row=0; row<2; ++row) {
1256  MWAWVec3f &resRow=row==0 ? res.m_data.first : res.m_data.second;
1257  for (int col=0; col<3; ++col) {
1258  float value=0;
1259  for (int i=0; i<3; ++i)
1260  value+=(*this)[row][i]*(i==2 ? (col==2 ? 1.f : 0.f) : mat[i][col]);
1261  resRow[col]=value;
1262  }
1263  }
1264  res.checkIdentity();
1265  return res;
1266  }
1269  {
1270  if (!mat.m_isIdentity)
1271  *this=(*this)*mat;
1272  return *this;
1273  }
1275  bool operator==(MWAWTransformation const &mat) const
1276  {
1277  return m_data==mat.m_data;
1278  }
1280  bool operator!=(MWAWTransformation const &mat) const
1281  {
1282  return m_data!=mat.m_data;
1283  }
1285  bool operator<(MWAWTransformation const &mat) const
1286  {
1287  return m_data<mat.m_data;
1288  }
1290  bool operator<=(MWAWTransformation const &mat) const
1291  {
1292  return m_data<=mat.m_data;
1293  }
1295  bool operator>(MWAWTransformation const &mat) const
1296  {
1297  return m_data>mat.m_data;
1298  }
1300  bool operator>=(MWAWTransformation const &mat) const
1301  {
1302  return m_data>=mat.m_data;
1303  }
1307  bool decompose(float &rotation, MWAWVec2f &shearing, MWAWTransformation &transform, MWAWVec2f const &center) const;
1308 
1311  {
1312  return MWAWTransformation(MWAWVec3f(1, 0, trans[0]), MWAWVec3f(0, 1, trans[1]));
1313  }
1315  static MWAWTransformation scale(MWAWVec2f const &trans)
1316  {
1317  return MWAWTransformation(MWAWVec3f(trans[0], 0, 0), MWAWVec3f(0, trans[1], 0));
1318  }
1322  static MWAWTransformation rotation(float angle, MWAWVec2f const &center=MWAWVec2f(0,0));
1326  static MWAWTransformation shear(MWAWVec2f s, MWAWVec2f const &center=MWAWVec2f(0,0))
1327  {
1328  return MWAWTransformation(MWAWVec3f(1, s[0], -s[0]*center[1]), MWAWVec3f(s[1], 1, -s[1]*center[0]));
1329  }
1330 protected:
1332  std::pair<MWAWVec3f, MWAWVec3f > m_data;
1334  mutable bool m_isIdentity;
1335 };
1336 
1337 // some format function
1338 namespace libmwaw
1339 {
1341 bool convertDTFormat(std::string const &dtFormat, librevenge::RVNGPropertyListVector &propVect);
1342 }
1343 
1344 // some geometrical function
1345 namespace libmwaw
1346 {
1348 MWAWVec2f rotatePointAroundCenter(MWAWVec2f const &point, MWAWVec2f const &center, float angle);
1350 MWAWBox2f rotateBoxFromCenter(MWAWBox2f const &box, float angle);
1351 }
1352 #endif /* LIBMWAW_INTERNAL_H */
1353 // vim: set filetype=cpp tabstop=2 shiftwidth=2 cindent autoindent smartindent noexpandtab:
MWAWEmbeddedObject::addTo
bool addTo(librevenge::RVNGPropertyList &propList) const
add the link property to proplist
Definition: libmwaw_internal.cxx:571
MWAWVec3i
MWAWVec3< int > MWAWVec3i
MWAWVec3 of int.
Definition: libmwaw_internal.hxx:1015
MWAWTextListenerPtr
std::shared_ptr< MWAWTextListener > MWAWTextListenerPtr
a smart pointer of MWAWTextListener
Definition: libmwaw_internal.hxx:565
MWAWEntry
basic class to store an entry in a file This contained :
Definition: MWAWEntry.hxx:46
MWAWField::Time
Definition: libmwaw_internal.hxx:401
MWAWInputStreamPtr
std::shared_ptr< MWAWInputStream > MWAWInputStreamPtr
a smart pointer of MWAWInputStream
Definition: libmwaw_internal.hxx:549
MWAWBox2::m_data
std::pair< MWAWVec2< T >, MWAWVec2< T > > m_data
the data
Definition: libmwaw_internal.hxx:1185
MWAWTransformation::operator<
bool operator<(MWAWTransformation const &mat) const
operator<
Definition: libmwaw_internal.hxx:1285
MWAWTransformation::multiplyDirection
MWAWVec2f multiplyDirection(MWAWVec2f const &dir) const
operator* for direction
Definition: libmwaw_internal.hxx:1231
MWAW_shared_ptr_noop_deleter
an noop deleter used to transform a libwpd pointer in a false std::shared_ptr
Definition: libmwaw_internal.hxx:101
MWAWBorder::Triple
Definition: libmwaw_internal.hxx:337
MWAWFontManagerPtr
std::shared_ptr< MWAWFontManager > MWAWFontManagerPtr
a smart pointer of MWAWFontManager
Definition: libmwaw_internal.hxx:545
MWAWGraphicListenerPtr
std::shared_ptr< MWAWGraphicListener > MWAWGraphicListenerPtr
a smart pointer of MWAWGraphicListener
Definition: libmwaw_internal.hxx:547
MWAWNote
a note
Definition: libmwaw_internal.hxx:445
MWAWVec2::MWAWVec2
MWAWVec2(T xx=0, T yy=0)
constructor
Definition: libmwaw_internal.hxx:657
MWAWVariable::m_set
bool m_set
a flag to know if the variable is set or not
Definition: libmwaw_internal.hxx:646
libmwaw::NONE
Definition: libmwaw_internal.hxx:180
MWAWField::m_type
Type m_type
the type
Definition: libmwaw_internal.hxx:420
MWAWBox2::operator>
bool operator>(MWAWBox2< T > const &mat) const
operator>
Definition: libmwaw_internal.hxx:1167
MWAWFontConverterPtr
std::shared_ptr< MWAWFontConverter > MWAWFontConverterPtr
a smart pointer of MWAWFontConverter
Definition: libmwaw_internal.hxx:541
MWAWVec2::setY
void setY(T yy)
resets the second element
Definition: libmwaw_internal.hxx:700
MWAWBox2::min
MWAWVec2< T > & min()
the minimum 2D point (in x and in y)
Definition: libmwaw_internal.hxx:1047
MWAW_DEBUG_MSG
#define MWAW_DEBUG_MSG(M)
Definition: libmwaw_internal.hxx:129
MWAWVec2f
MWAWVec2< float > MWAWVec2f
MWAWVec2 of float.
Definition: libmwaw_internal.hxx:840
libmwaw::numberingValueToString
std::string numberingValueToString(NumberingType type, int value)
Definition: libmwaw_internal.cxx:130
MWAWVec2::operator==
bool operator==(MWAWVec2< T > const &p) const
comparison==
Definition: libmwaw_internal.hxx:760
MWAWVariable
a generic variable template: value + flag to know if the variable is set
Definition: libmwaw_internal.hxx:575
libmwaw::rotateBoxFromCenter
MWAWBox2f rotateBoxFromCenter(MWAWBox2f const &box, float angle)
rotate a bdox and returns the final bdbox, angle is given in degree
Definition: libmwaw_internal.cxx:700
MWAWBox2::set
void set(MWAWVec2< T > const &x, MWAWVec2< T > const &y)
resets the data to minimum x and maximum y
Definition: libmwaw_internal.hxx:1077
MWAWBox2::max
const MWAWVec2< T > & max() const
the maximum 2D point (in x and in y)
Definition: libmwaw_internal.hxx:1042
MWAWBorder::m_type
Type m_type
the border repetition
Definition: libmwaw_internal.hxx:385
MWAWBox2::operator>=
bool operator>=(MWAWBox2< T > const &mat) const
operator>=
Definition: libmwaw_internal.hxx:1172
MWAWBorder::Dash
Definition: libmwaw_internal.hxx:335
MWAWVec3::operator*=
MWAWVec3< T > & operator*=(U scale)
generic operator*=
Definition: libmwaw_internal.hxx:934
MWAWVec3::operator+
friend MWAWVec3< T > operator+(MWAWVec3< T > const &p1, MWAWVec3< T > const &p2)
operator+
Definition: libmwaw_internal.hxx:941
libmwaw::NumberingType
NumberingType
Definition: libmwaw_internal.hxx:180
MWAWVec3::operator<<
friend std::ostream & operator<<(std::ostream &o, MWAWVec3< T > const &f)
operator<<: prints data in form "XxYxZ"
Definition: libmwaw_internal.hxx:986
MWAWBorder::isEmpty
bool isEmpty() const
returns true if the border is empty
Definition: libmwaw_internal.hxx:356
MWAWTransformation::MWAWTransformation
MWAWTransformation(MWAWVec3f const &xRow=MWAWVec3f(1, 0, 0), MWAWVec3f const &yRow=MWAWVec3f(0, 1, 0))
constructor
Definition: libmwaw_internal.hxx:1200
MWAWBox2::max
MWAWVec2< T > & max()
the maximum 2D point (in x and in y)
Definition: libmwaw_internal.hxx:1052
MWAWTransformation::operator>=
bool operator>=(MWAWTransformation const &mat) const
operator>=
Definition: libmwaw_internal.hxx:1300
MWAWVec2::operator[]
T & operator[](int c)
operator[]
Definition: libmwaw_internal.hxx:682
MWAWVec3::operator!=
bool operator!=(MWAWVec3< T > const &p) const
comparison!=
Definition: libmwaw_internal.hxx:966
MWAWVec2< bool >::MapX
std::map< MWAWVec2< bool >, bool, struct PosSizeLtX > MapX
map of MWAWVec2
Definition: libmwaw_internal.hxx:813
MWAWTransformation::operator*
MWAWTransformation operator*(MWAWTransformation const &mat) const
operator* for transform
Definition: libmwaw_internal.hxx:1251
libmwaw::Position
Position
basic position enum
Definition: libmwaw_internal.hxx:176
MWAWBorder::compare
int compare(MWAWBorder const &orig) const
compare two borders
Definition: libmwaw_internal.cxx:424
libmwaw::DOC_COMMENT_ANNOTATION
Definition: libmwaw_internal.hxx:188
MWAWEmbeddedObject::~MWAWEmbeddedObject
~MWAWEmbeddedObject()
destructor
Definition: libmwaw_internal.cxx:567
MWAWBorder::Simple
Definition: libmwaw_internal.hxx:335
MWAWField::m_DTFormat
std::string m_DTFormat
the date/time format using strftime format if defined
Definition: libmwaw_internal.hxx:424
MWAWVec2::operator*=
MWAWVec2< T > & operator*=(U scale)
generic operator*=
Definition: libmwaw_internal.hxx:732
MWAWInputStream
Internal class used to read the file stream Internal class used to read the file stream,...
Definition: MWAWInputStream.hxx:53
MWAWTextListener
This class contents the main functions needed to create a Word processing Document.
Definition: MWAWTextListener.hxx:64
MWAWVec3::z
T z() const
third element
Definition: libmwaw_internal.hxx:872
MWAWFontManager
a font manager which can be used to store fonts, ...
Definition: MWAWFont.hxx:582
MWAWEmbeddedObject::m_dataList
std::vector< librevenge::RVNGBinaryData > m_dataList
the picture content: one data by representation
Definition: libmwaw_internal.hxx:511
MWAWColor::white
static MWAWColor white()
return the white color
Definition: libmwaw_internal.hxx:250
libmwaw::BULLET
Definition: libmwaw_internal.hxx:180
MWAWColor::operator==
bool operator==(MWAWColor const &c) const
operator==
Definition: libmwaw_internal.hxx:294
MWAWBox2::min
const MWAWVec2< T > & min() const
the minimum 2D point (in x and in y)
Definition: libmwaw_internal.hxx:1037
libmwaw::DOC_CHART
Definition: libmwaw_internal.hxx:188
libmwaw::BottomBit
Definition: libmwaw_internal.hxx:178
MWAWTransformation::operator*
MWAWVec2f operator*(MWAWVec2f const &pt) const
operator* for vec2f
Definition: libmwaw_internal.hxx:1225
libmwaw::DOC_CHART_ZONE
Definition: libmwaw_internal.hxx:188
MWAWVariable::operator*
const T & operator*() const
operator*
Definition: libmwaw_internal.hxx:617
MWAWVec2::cmpY
int cmpY(MWAWVec2< T > const &p) const
a comparison function: which first compares y then x
Definition: libmwaw_internal.hxx:784
MWAWNote::Type
Type
enum to define note type
Definition: libmwaw_internal.hxx:447
MWAWColor::operator=
MWAWColor & operator=(uint32_t argb)
operator=
Definition: libmwaw_internal.hxx:212
MWAWEmbeddedObject::operator=
MWAWEmbeddedObject & operator=(MWAWEmbeddedObject const &)=default
libmwaw::WritingLeftTop
Definition: libmwaw_internal.hxx:185
libmwaw::UPPERCASE
Definition: libmwaw_internal.hxx:180
MWAWEmbeddedObject::add
void add(librevenge::RVNGBinaryData const &binaryData, std::string const &type="image/pict")
add a picture
Definition: libmwaw_internal.hxx:494
MWAWGraphicShape
a structure used to define a picture shape
Definition: MWAWGraphicShape.hxx:45
MWAWVec3::x
T x() const
first element
Definition: libmwaw_internal.hxx:862
MWAWColor
the class to store a color
Definition: libmwaw_internal.hxx:192
libmwaw::appendUnicode
void appendUnicode(uint32_t val, librevenge::RVNGString &buffer)
adds an unicode character to a string
Definition: libmwaw_internal.cxx:63
libmwaw::numberingTypeToString
std::string numberingTypeToString(NumberingType type)
Definition: libmwaw_internal.cxx:106
MWAWEmbeddedObject
small class use to define a embedded object
Definition: libmwaw_internal.hxx:467
MWAWVec3uc
MWAWVec3< unsigned char > MWAWVec3uc
MWAWVec3 of unsigned char.
Definition: libmwaw_internal.hxx:1013
MWAWField::Type
Type
Defines some basic type for field.
Definition: libmwaw_internal.hxx:401
MWAWField::operator=
MWAWField & operator=(MWAWField const &)=default
MWAWSubDocumentPtr
std::shared_ptr< MWAWSubDocument > MWAWSubDocumentPtr
a smart pointer of MWAWSubDocument
Definition: libmwaw_internal.hxx:563
libmwaw::WritingRightBottom
Definition: libmwaw_internal.hxx:185
MWAWVariable::operator->
const T * operator->() const
operator*
Definition: libmwaw_internal.hxx:606
MWAWField::getString
librevenge::RVNGString getString() const
returns a string corresponding to the field (if possible) *‍/
Definition: libmwaw_internal.cxx:288
libmwaw::VersionException
Definition: libmwaw_internal.hxx:135
libmwaw::LOWERCASE_ROMAN
Definition: libmwaw_internal.hxx:180
MWAWBox2::extend
void extend(T val)
extends the bdbox by (val, val) keeping the center
Definition: libmwaw_internal.hxx:1120
libmwaw::convertDTFormat
bool convertDTFormat(std::string const &dtFormat, librevenge::RVNGPropertyListVector &propVect)
convert a DTFormat in a propertyList
Definition: libmwaw_internal.cxx:316
MWAWVec3< int >::Map
std::map< MWAWVec3< int >, int, struct PosSizeLt > Map
map of MWAWVec3
Definition: libmwaw_internal.hxx:1005
MWAWBox2l
MWAWBox2< long > MWAWBox2l
MWAWBox2 of long.
Definition: libmwaw_internal.hxx:1193
MWAWBox2::operator<
bool operator<(MWAWBox2< T > const &mat) const
operator<
Definition: libmwaw_internal.hxx:1157
MWAWParagraph
class to store the paragraph properties
Definition: MWAWParagraph.hxx:84
MWAWColor::str
std::string str() const
print the color in the form #rrggbb
Definition: libmwaw_internal.cxx:232
MWAWNote::m_number
int m_number
the note number if defined
Definition: libmwaw_internal.hxx:460
MWAWVec2::operator-=
MWAWVec2< T > & operator-=(MWAWVec2< T > const &p)
operator-=
Definition: libmwaw_internal.hxx:721
MWAWBorder::None
Definition: libmwaw_internal.hxx:335
MWAWTransformation::m_data
std::pair< MWAWVec3f, MWAWVec3f > m_data
the data
Definition: libmwaw_internal.hxx:1332
MWAW_FALLTHROUGH
#define MWAW_FALLTHROUGH
Definition: libmwaw_internal.hxx:118
libmwaw::HMiddle
Definition: libmwaw_internal.hxx:176
MWAWBorder::m_width
double m_width
the border total width in point
Definition: libmwaw_internal.hxx:387
libmwaw::rotatePointAroundCenter
MWAWVec2f rotatePointAroundCenter(MWAWVec2f const &point, MWAWVec2f const &center, float angle)
rotate a point around center, angle is given in degree
Definition: libmwaw_internal.cxx:692
MWAWVec3::MWAWVec3
MWAWVec3(MWAWVec3< U > const &p)
generic copy constructor
Definition: libmwaw_internal.hxx:856
MWAWTransformation::shear
static MWAWTransformation shear(MWAWVec2f s, MWAWVec2f const &center=MWAWVec2f(0, 0))
returns a shear transformation letting center invariant, ie.
Definition: libmwaw_internal.hxx:1326
MWAWVec2::operator!=
bool operator!=(MWAWVec2< T > const &p) const
comparison!=
Definition: libmwaw_internal.hxx:765
MWAWBox2::getIntersection
MWAWBox2< T > getIntersection(MWAWBox2< T > const &box) const
returns the intersection between this and box
Definition: libmwaw_internal.hxx:1137
MWAWBox2::setMin
void setMin(MWAWVec2< T > const &x)
resets the minimum point
Definition: libmwaw_internal.hxx:1083
libmwaw::UPPERCASE_ROMAN
Definition: libmwaw_internal.hxx:180
MWAWSubDocument
abstract class used to store a subdocument (with a comparison function)
Definition: MWAWSubDocument.hxx:41
MWAWGraphicStyle
a structure used to define a picture style
Definition: MWAWGraphicStyle.hxx:47
MWAWBorder::Dot
Definition: libmwaw_internal.hxx:335
MWAWBorder::Type
Type
the line repetition
Definition: libmwaw_internal.hxx:337
MWAWBorder::operator<<
friend std::ostream & operator<<(std::ostream &o, MWAWBorder const &border)
operator<<
Definition: libmwaw_internal.cxx:533
MWAWVec3::operator[]
T operator[](int c) const
operator[]
Definition: libmwaw_internal.hxx:877
MWAWVec3::setX
void setX(T xx)
resets the first element
Definition: libmwaw_internal.hxx:897
MWAWVariable::operator=
MWAWVariable & operator=(MWAWVariable const &)=default
copy operator
MWAWVec2::operator-
friend MWAWVec2< T > operator-(MWAWVec2< T > const &p1, MWAWVec2< T > const &p2)
operator-
Definition: libmwaw_internal.hxx:746
MWAWColor::operator!=
bool operator!=(MWAWColor const &c) const
operator!=
Definition: libmwaw_internal.hxx:299
MWAWField::PageCount
Definition: libmwaw_internal.hxx:401
MWAWPresentationListenerPtr
std::shared_ptr< MWAWPresentationListener > MWAWPresentationListenerPtr
a smart pointer of MWAWPresentationListener
Definition: libmwaw_internal.hxx:557
MWAWField::Date
Definition: libmwaw_internal.hxx:401
MWAWTransformation::operator==
bool operator==(MWAWTransformation const &mat) const
operator==
Definition: libmwaw_internal.hxx:1275
MWAWVec3::add
void add(T dx, T dy, T dz)
increases the actuals values by dx, dy, dz
Definition: libmwaw_internal.hxx:913
MWAWField::m_numberingType
libmwaw::NumberingType m_numberingType
the number type ( for number field )
Definition: libmwaw_internal.hxx:422
MWAWVariable::isSet
bool isSet() const
return true if the variable is set
Definition: libmwaw_internal.hxx:633
MWAWBorder::Style
Style
the line style
Definition: libmwaw_internal.hxx:335
libmwaw::checkAddOverflow
bool checkAddOverflow(T x, T y)
checks whether addition of x and y would overflow
Definition: libmwaw_internal.hxx:165
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
MWAWBox2::getUnion
MWAWBox2< T > getUnion(MWAWBox2< T > const &box) const
returns the union between this and box
Definition: libmwaw_internal.hxx:1127
libmwaw::SubDocumentType
SubDocumentType
Definition: libmwaw_internal.hxx:188
MWAWBorder::operator=
MWAWBorder & operator=(MWAWBorder const &)=default
MWAWEmbeddedObject::cmp
int cmp(MWAWEmbeddedObject const &pict) const
a comparison function
Definition: libmwaw_internal.cxx:598
MWAWBorder::m_widthsList
std::vector< double > m_widthsList
the different length used for each line/sep (if defined)
Definition: libmwaw_internal.hxx:391
MWAWEmbeddedObject::MWAWEmbeddedObject
MWAWEmbeddedObject(librevenge::RVNGBinaryData const &binaryData, std::string const &type="image/pict")
constructor
Definition: libmwaw_internal.hxx:475
MWAWSpreadsheetListenerPtr
std::shared_ptr< MWAWSpreadsheetListener > MWAWSpreadsheetListenerPtr
a smart pointer of MWAWSpreadsheetListener
Definition: libmwaw_internal.hxx:561
MWAWSpreadsheetListener
This class contents the main functions needed to create a spreadsheet processing Document.
Definition: MWAWSpreadsheetListener.hxx:65
MWAWVec2::cmp
int cmp(MWAWVec2< T > const &p) const
a comparison function: which first compares x then y
Definition: libmwaw_internal.hxx:775
MWAWList
a small structure used to store the informations about a list
Definition: MWAWList.hxx:121
MWAWRSRCParser
the main class to read a Mac resource fork
Definition: MWAWRSRCParser.hxx:46
MWAWVec2::y
T y() const
second element
Definition: libmwaw_internal.hxx:671
MWAWField::Database
Definition: libmwaw_internal.hxx:401
MWAWVec2::MWAWVec2
MWAWVec2(MWAWVec2< U > const &p)
generic copy constructor
Definition: libmwaw_internal.hxx:661
libmwaw::Bottom
Definition: libmwaw_internal.hxx:176
libmwaw_internal.hxx
MWAWListener
This class contains a virtual interface to all listener.
Definition: MWAWListener.hxx:49
MWAWEmbeddedObject::isEmpty
bool isEmpty() const
return true if the picture contains no data
Definition: libmwaw_internal.hxx:485
MWAWField::m_data
std::string m_data
the database/link field ( if defined )
Definition: libmwaw_internal.hxx:426
MWAWTransformation::operator>
bool operator>(MWAWTransformation const &mat) const
operator>
Definition: libmwaw_internal.hxx:1295
MWAWVec3::m_val
T m_val[3]
the values
Definition: libmwaw_internal.hxx:1009
MWAWColor::MWAWColor
MWAWColor(unsigned char r, unsigned char g, unsigned char b, unsigned char a=255)
constructor from color
Definition: libmwaw_internal.hxx:199
MWAWVec2::x
T x() const
first element
Definition: libmwaw_internal.hxx:666
MWAWVariable::MWAWVariable
MWAWVariable(MWAWVariable const &orig)
copy constructor
Definition: libmwaw_internal.hxx:585
MWAWVec3::operator==
bool operator==(MWAWVec3< T > const &p) const
comparison==
Definition: libmwaw_internal.hxx:961
MWAWColor::getBlue
unsigned char getBlue() const
returns the green value
Definition: libmwaw_internal.hxx:269
libmwaw::FileException
Definition: libmwaw_internal.hxx:139
MWAWListManagerPtr
std::shared_ptr< MWAWListManager > MWAWListManagerPtr
a smart pointer of MWAWListManager
Definition: libmwaw_internal.hxx:553
MWAWPosition
Class to define the position of an object (textbox, picture, ..) in the document.
Definition: MWAWPosition.hxx:47
MWAWVec2::operator+
friend MWAWVec2< T > operator+(MWAWVec2< T > const &p1, MWAWVec2< T > const &p2)
operator+
Definition: libmwaw_internal.hxx:740
libmwaw::VMiddleBit
Definition: libmwaw_internal.hxx:178
MWAWBorder
a border
Definition: libmwaw_internal.hxx:333
MWAWColor::isBlack
bool isBlack() const
return true if the color is black
Definition: libmwaw_internal.hxx:284
MWAWVec2::operator<<
friend std::ostream & operator<<(std::ostream &o, MWAWVec2< T > const &f)
operator<<: prints data in form "XxY"
Definition: libmwaw_internal.hxx:794
libmwaw::VMiddle
Definition: libmwaw_internal.hxx:176
MWAWBorder::addTo
bool addTo(librevenge::RVNGPropertyList &propList, std::string which="") const
add the border property to proplist (if needed )
Definition: libmwaw_internal.cxx:436
MWAWEmbeddedObject::MWAWEmbeddedObject
MWAWEmbeddedObject()
empty constructor
Definition: libmwaw_internal.hxx:469
libmwaw::writingModeToString
std::string writingModeToString(WritingMode mode)
a function to convert a writing mode in string lt-rb, ...
Definition: libmwaw_internal.cxx:184
M_PI
#define M_PI
Definition: libmwaw_internal.hxx:52
MWAWRSRCParserPtr
std::shared_ptr< MWAWRSRCParser > MWAWRSRCParserPtr
a smart pointer of MWAWRSRCParser
Definition: libmwaw_internal.hxx:559
libmwaw::DOC_HEADER_FOOTER
Definition: libmwaw_internal.hxx:188
libmwaw::DOC_GRAPHIC_GROUP
Definition: libmwaw_internal.hxx:188
MWAWBox2::operator<=
bool operator<=(MWAWBox2< T > const &mat) const
operator<=
Definition: libmwaw_internal.hxx:1162
MWAWField::None
Definition: libmwaw_internal.hxx:401
libmwaw::RightBit
Definition: libmwaw_internal.hxx:178
MWAWVec2< float >
MWAWBox2::setMax
void setMax(MWAWVec2< T > const &y)
resets the maximum point
Definition: libmwaw_internal.hxx:1088
MWAWSection
a class which stores section properties
Definition: MWAWSection.hxx:45
MWAWBox2::resizeFromMin
void resizeFromMin(MWAWVec2< T > const &sz)
resize the box keeping the minimum
Definition: libmwaw_internal.hxx:1094
libmwaw::ARABIC
Definition: libmwaw_internal.hxx:180
libmwaw::ParseException
Definition: libmwaw_internal.hxx:143
MWAWVariable::operator*
T & operator*()
operator*
Definition: libmwaw_internal.hxx:622
MWAWHeader
a function used by MWAWDocument to store the version of document
Definition: MWAWHeader.hxx:56
MWAWTransformation::rotation
static MWAWTransformation rotation(float angle, MWAWVec2f const &center=MWAWVec2f(0, 0))
returns a rotation transformation around center.
Definition: libmwaw_internal.cxx:638
MWAWVariable::insert
void insert(MWAWVariable const &orig)
update the current value if orig is set
Definition: libmwaw_internal.hxx:598
MWAWVec3::setZ
void setZ(T zz)
resets the third element
Definition: libmwaw_internal.hxx:907
MWAWVariable::get
const T & get() const
return the current value
Definition: libmwaw_internal.hxx:628
MWAWVec3::operator<
bool operator<(MWAWVec3< T > const &p) const
comparison<: which first compares x values, then y values then z values.
Definition: libmwaw_internal.hxx:971
MWAWBox2::operator==
bool operator==(MWAWBox2< T > const &mat) const
operator==
Definition: libmwaw_internal.hxx:1147
MWAWTransformation::operator[]
const MWAWVec3f & operator[](int c) const
the two extremum points which defined the box
Definition: libmwaw_internal.hxx:1219
MWAWVec3::operator*
friend MWAWVec3< T > operator*(U scale, MWAWVec3< T > const &p1)
generic operator*
Definition: libmwaw_internal.hxx:954
MWAWNote::MWAWNote
MWAWNote(Type type)
constructor
Definition: libmwaw_internal.hxx:449
MWAWColor::black
static MWAWColor black()
return the back color
Definition: libmwaw_internal.hxx:245
MWAWBox2f
MWAWBox2< float > MWAWBox2f
MWAWBox2 of float.
Definition: libmwaw_internal.hxx:1191
MWAWColor::operator>
bool operator>(MWAWColor const &c) const
operator>
Definition: libmwaw_internal.hxx:314
MWAWVec2::operator<
bool operator<(MWAWVec2< T > const &p) const
comparison<: sort by y
Definition: libmwaw_internal.hxx:770
libmwaw::DOC_SHEET
Definition: libmwaw_internal.hxx:188
MWAWVec3::setY
void setY(T yy)
resets the second element
Definition: libmwaw_internal.hxx:902
libmwaw::WritingLeftBottom
Definition: libmwaw_internal.hxx:185
MWAWField
a field
Definition: libmwaw_internal.hxx:399
MWAWField::PageNumber
Definition: libmwaw_internal.hxx:401
MWAWBox2::MWAWBox2
MWAWBox2(MWAWBox2< U > const &p)
generic constructor
Definition: libmwaw_internal.hxx:1031
MWAWVariable::MWAWVariable
MWAWVariable()
constructor
Definition: libmwaw_internal.hxx:577
MWAWVec3::MWAWVec3
MWAWVec3(T xx=0, T yy=0, T zz=0)
constructor
Definition: libmwaw_internal.hxx:849
MWAWVariable::MWAWVariable
MWAWVariable(T const &def)
constructor with a default value
Definition: libmwaw_internal.hxx:581
MWAWVec3::operator-
friend MWAWVec3< T > operator-(MWAWVec3< T > const &p1, MWAWVec3< T > const &p2)
operator-
Definition: libmwaw_internal.hxx:947
libmwaw::HMiddleBit
Definition: libmwaw_internal.hxx:178
MWAWColor::MWAWColor
MWAWColor(uint32_t argb=0)
constructor
Definition: libmwaw_internal.hxx:194
MWAWTransformation::decompose
bool decompose(float &rotation, MWAWVec2f &shearing, MWAWTransformation &transform, MWAWVec2f const &center) const
try to decompose the matrix in a rotation + scaling/translation matrix.
Definition: libmwaw_internal.cxx:647
libmwaw::DOC_TABLE
Definition: libmwaw_internal.hxx:188
libmwaw::Top
Definition: libmwaw_internal.hxx:176
MWAWVec3::set
void set(T xx, T yy, T zz)
resets the three elements
Definition: libmwaw_internal.hxx:890
operator<<
std::ostream & operator<<(std::ostream &o, MWAWColor const &c)
Definition: libmwaw_internal.cxx:220
MWAWBorder::m_style
Style m_style
the border style
Definition: libmwaw_internal.hxx:380
MWAWTransformation::operator<=
bool operator<=(MWAWTransformation const &mat) const
operator<=
Definition: libmwaw_internal.hxx:1290
MWAWVec2::add
void add(T dx, T dy)
increases the actuals values by dx and dy
Definition: libmwaw_internal.hxx:706
libmwaw::DOC_TEXT_BOX
Definition: libmwaw_internal.hxx:188
MWAWColor::getAlpha
unsigned char getAlpha() const
returns the alpha value
Definition: libmwaw_internal.hxx:264
MWAWGraphicEncoder
main class used to define store librevenge::RVNGDrawingInterface lists of command in a librevenge::RV...
Definition: MWAWGraphicEncoder.hxx:55
libmwaw::DOC_NOTE
Definition: libmwaw_internal.hxx:188
MWAWBox2i
MWAWBox2< int > MWAWBox2i
MWAWBox2 of int.
Definition: libmwaw_internal.hxx:1189
MWAWColor::operator<<
friend std::ostream & operator<<(std::ostream &o, MWAWColor const &c)
operator<< in the form #rrggbb
Definition: libmwaw_internal.cxx:220
libmwaw::LeftBit
Definition: libmwaw_internal.hxx:178
MWAWBorder::Double
Definition: libmwaw_internal.hxx:337
MWAWColor::operator>=
bool operator>=(MWAWColor const &c) const
operator>=
Definition: libmwaw_internal.hxx:319
MWAWNote::m_type
Type m_type
the note type
Definition: libmwaw_internal.hxx:456
MWAWVec3::operator[]
T & operator[](int c)
operator[]
Definition: libmwaw_internal.hxx:883
MWAWTransformation::translation
static MWAWTransformation translation(MWAWVec2f const &trans)
returns a translation transformation
Definition: libmwaw_internal.hxx:1310
MWAWParser
virtual class which defines the ancestor of all main zone parser
Definition: MWAWParser.hxx:99
MWAWBox2::operator<<
friend std::ostream & operator<<(std::ostream &o, MWAWBox2< T > const &f)
print data in form X0xY0<->X1xY1
Definition: libmwaw_internal.hxx:1177
MWAWBox2::center
MWAWVec2< T > center() const
the box center
Definition: libmwaw_internal.hxx:1070
MWAWEmbeddedObject::m_typeList
std::vector< std::string > m_typeList
the picture type: one type by representation
Definition: libmwaw_internal.hxx:513
MWAWParserState
a class to define the parser state
Definition: MWAWParser.hxx:49
MWAWPresentationListener
This class contains code needed to write a presention document.
Definition: MWAWPresentationListener.hxx:59
MWAWVec3::y
T y() const
second element
Definition: libmwaw_internal.hxx:867
MWAWVec3::operator-=
MWAWVec3< T > & operator-=(MWAWVec3< T > const &p)
operator-=
Definition: libmwaw_internal.hxx:927
MWAWVec2::operator[]
T operator[](int c) const
operator[]
Definition: libmwaw_internal.hxx:676
MWAWVec2::m_x
T m_x
first element
Definition: libmwaw_internal.hxx:830
MWAWBox2::operator[]
const MWAWVec2< T > & operator[](int c) const
the two extremum points which defined the box
Definition: libmwaw_internal.hxx:1059
libmwaw::WritingMode
WritingMode
the different writing mode
Definition: libmwaw_internal.hxx:185
libmwaw::Right
Definition: libmwaw_internal.hxx:176
MWAWColor::getRed
unsigned char getRed() const
returns the red value
Definition: libmwaw_internal.hxx:274
MWAWTransformation::isIdentity
bool isIdentity() const
returns true if the matrix is an identity matrix
Definition: libmwaw_internal.hxx:1207
MWAWVec2l
MWAWVec2< long > MWAWVec2l
MWAWVec2 of long.
Definition: libmwaw_internal.hxx:838
libmwaw::LOWERCASE
Definition: libmwaw_internal.hxx:180
MWAWParserStatePtr
std::shared_ptr< MWAWParserState > MWAWParserStatePtr
a smart pointer of MWAWParserState
Definition: libmwaw_internal.hxx:555
MWAWTransformation
a transformation which stored the first row of a 3x3 perspective matrix
Definition: libmwaw_internal.hxx:1196
MWAWTransformation::m_isIdentity
bool m_isIdentity
flag to know if this matrix is an identity matrix
Definition: libmwaw_internal.hxx:1334
MWAWVariable::m_data
T m_data
the value
Definition: libmwaw_internal.hxx:644
libmwaw::TopBit
Definition: libmwaw_internal.hxx:178
MWAWTransformation::operator!=
bool operator!=(MWAWTransformation const &mat) const
operator!=
Definition: libmwaw_internal.hxx:1280
MWAWNote::m_label
librevenge::RVNGString m_label
the note label
Definition: libmwaw_internal.hxx:458
MWAWVec2::PosSizeLtY
internal struct used to create sorted map, sorted by Y
Definition: libmwaw_internal.hxx:818
libmwaw::WrongPasswordException
Definition: libmwaw_internal.hxx:151
MWAWBox2::resizeFromCenter
void resizeFromCenter(MWAWVec2< T > const &sz)
resize the box keeping the center
Definition: libmwaw_internal.hxx:1104
MWAWTransformation::operator*
MWAWBox2f operator*(MWAWBox2f const &box) const
operator* for box2f
Definition: libmwaw_internal.hxx:1245
MWAWTransformation::scale
static MWAWTransformation scale(MWAWVec2f const &trans)
returns a scaling transformation
Definition: libmwaw_internal.hxx:1315
MWAWBorder::m_extra
std::string m_extra
extra data ( if needed)
Definition: libmwaw_internal.hxx:395
MWAWBox2::resizeFromMax
void resizeFromMax(MWAWVec2< T > const &sz)
resize the box keeping the maximum
Definition: libmwaw_internal.hxx:1099
MWAWTransformation::operator*=
MWAWTransformation & operator*=(MWAWTransformation const &mat)
operator*=
Definition: libmwaw_internal.hxx:1268
MWAWVec3::PosSizeLt::operator()
bool operator()(MWAWVec3< T > const &s1, MWAWVec3< T > const &s2) const
comparaison function
Definition: libmwaw_internal.hxx:997
MWAWVec3f
MWAWVec3< float > MWAWVec3f
MWAWVec3 of float.
Definition: libmwaw_internal.hxx:1017
MWAWVariable::operator->
T * operator->()
operator*
Definition: libmwaw_internal.hxx:611
MWAWVec2::PosSizeLtY::operator()
bool operator()(MWAWVec2< T > const &s1, MWAWVec2< T > const &s2) const
comparaison function
Definition: libmwaw_internal.hxx:820
MWAWBorder::operator==
bool operator==(MWAWBorder const &orig) const
operator==
Definition: libmwaw_internal.hxx:361
MWAWFontConverter
a namespace used to convert Mac font characters in unicode
Definition: MWAWFontConverter.hxx:62
MWAWVec3::PosSizeLt
internal struct used to create sorted map, sorted by X, Y, Z
Definition: libmwaw_internal.hxx:995
MWAWBorder::LargeDot
Definition: libmwaw_internal.hxx:335
MWAWField::MWAWField
MWAWField(Type type)
basic constructor
Definition: libmwaw_internal.hxx:404
libmwaw::Left
Definition: libmwaw_internal.hxx:176
MWAWBox2::size
MWAWVec2< T > size() const
the box size
Definition: libmwaw_internal.hxx:1065
MWAWColor::m_value
uint32_t m_value
the argb color
Definition: libmwaw_internal.hxx:329
MWAWVec2< bool >::MapY
std::map< MWAWVec2< bool >, bool, struct PosSizeLtY > MapY
map of MWAWVec2
Definition: libmwaw_internal.hxx:828
MWAWColor::operator=
MWAWColor & operator=(MWAWColor const &)=default
operator=
MWAWVec2::m_y
T m_y
second element
Definition: libmwaw_internal.hxx:830
MWAWVec2::setX
void setX(T xx)
resets the first element
Definition: libmwaw_internal.hxx:695
MWAWNote::FootNote
Definition: libmwaw_internal.hxx:447
MWAWVec2::set
void set(T xx, T yy)
resets the two elements
Definition: libmwaw_internal.hxx:689
MWAWVec2::operator+=
MWAWVec2< T > & operator+=(MWAWVec2< T > const &p)
operator+=
Definition: libmwaw_internal.hxx:715
MWAWListManager
a manager which manages the lists, keeps the different kind of lists, to assure the unicity of each l...
Definition: MWAWList.hxx:214
libmwaw
namespace used to regroup all libwpd functions, enumerations which we have redefined for internal usa...
Definition: libmwaw_internal.cxx:50
MWAWBorder::Single
Definition: libmwaw_internal.hxx:337
MWAWVec3::cmp
int cmp(MWAWVec3< T > const &p) const
a comparison function: which first compares x values, then y values then z values.
Definition: libmwaw_internal.hxx:976
MWAWVec2::PosSizeLtX::operator()
bool operator()(MWAWVec2< T > const &s1, MWAWVec2< T > const &s2) const
comparaison function
Definition: libmwaw_internal.hxx:805
MWAWColor::isWhite
bool isWhite() const
return true if the color is white
Definition: libmwaw_internal.hxx:289
MWAWVariable::operator=
MWAWVariable & operator=(T const &val)
set a value
Definition: libmwaw_internal.hxx:591
MWAWListenerPtr
std::shared_ptr< MWAWListener > MWAWListenerPtr
a smart pointer of MWAWListener
Definition: libmwaw_internal.hxx:551
MWAWColor::operator<=
bool operator<=(MWAWColor const &c) const
operator<=
Definition: libmwaw_internal.hxx:309
MWAWBorder::MWAWBorder
MWAWBorder()
constructor
Definition: libmwaw_internal.hxx:340
MWAWEmbeddedObject::operator<<
friend std::ostream & operator<<(std::ostream &o, MWAWEmbeddedObject const &pict)
operator<<
Definition: libmwaw_internal.cxx:623
MWAWVec3
small class which defines a vector with 3 elements
Definition: libmwaw_internal.hxx:845
MWAWBox2
small class which defines a 2D Box
Definition: libmwaw_internal.hxx:1022
MWAWBox2::MWAWBox2
MWAWBox2(MWAWVec2< T > minPt=MWAWVec2< T >(), MWAWVec2< T > maxPt=MWAWVec2< T >())
constructor
Definition: libmwaw_internal.hxx:1026
MWAWFont
Class to store font.
Definition: MWAWFont.hxx:43
MWAWNote::EndNote
Definition: libmwaw_internal.hxx:447
MWAWField::addTo
bool addTo(librevenge::RVNGPropertyList &propList) const
add the link property to proplist (if possible)
Definition: libmwaw_internal.cxx:240
MWAWColor::getGreen
unsigned char getGreen() const
returns the green value
Definition: libmwaw_internal.hxx:279
libmwaw::WritingRightTop
Definition: libmwaw_internal.hxx:185
MWAWField::Title
Definition: libmwaw_internal.hxx:401
MWAWColor::colorFromHSL
static MWAWColor colorFromHSL(unsigned char H, unsigned char S, unsigned char L)
return a color from a hsl color (basic)
Definition: libmwaw_internal.hxx:228
libmwaw::DOC_NONE
Definition: libmwaw_internal.hxx:188
MWAWBox2::scale
void scale(U factor)
scales all points of the box by factor
Definition: libmwaw_internal.hxx:1113
MWAWColor::operator<
bool operator<(MWAWColor const &c) const
operator<
Definition: libmwaw_internal.hxx:304
MWAWVec2b
MWAWVec2< bool > MWAWVec2b
MWAWVec2 of bool.
Definition: libmwaw_internal.hxx:834
MWAWBorder::m_color
MWAWColor m_color
the border color
Definition: libmwaw_internal.hxx:393
libmwaw::GenericException
Definition: libmwaw_internal.hxx:147
libmwaw::readU8
uint8_t readU8(librevenge::RVNGInputStream *input)
Definition: libmwaw_internal.cxx:52
MWAWVec2i
MWAWVec2< int > MWAWVec2i
MWAWVec2 of int.
Definition: libmwaw_internal.hxx:836
libmwaw::WritingInherited
Definition: libmwaw_internal.hxx:185
MWAWPageSpan
A class which defines the page properties.
Definition: MWAWPageSpan.hxx:97
MWAWColor::value
uint32_t value() const
return the rgba value
Definition: libmwaw_internal.hxx:259
MWAWVec3::operator+=
MWAWVec3< T > & operator+=(MWAWVec3< T > const &p)
operator+=
Definition: libmwaw_internal.hxx:921
MWAWColor::colorFromCMYK
static MWAWColor colorFromCMYK(unsigned char c, unsigned char m, unsigned char y, unsigned char k)
return a color from a cmyk color ( basic)
Definition: libmwaw_internal.hxx:218
MWAWBorder::operator!=
bool operator!=(MWAWBorder const &orig) const
operator!=
Definition: libmwaw_internal.hxx:366
MWAWBox2::operator!=
bool operator!=(MWAWBox2< T > const &mat) const
operator!=
Definition: libmwaw_internal.hxx:1152
MWAWGraphicListener
This class contains the code needed to create Graphic document.
Definition: MWAWGraphicListener.hxx:59
MWAWTransformation::checkIdentity
void checkIdentity() const
check if a matrix is the identity matrix
Definition: libmwaw_internal.hxx:1212
MWAWVec2::operator*
friend MWAWVec2< T > operator*(U scale, MWAWVec2< T > const &p1)
generic operator*
Definition: libmwaw_internal.hxx:753
MWAWVariable::setSet
void setSet(bool newVal)
define if the variable is set
Definition: libmwaw_internal.hxx:638
MWAWVec2::PosSizeLtX
internal struct used to create sorted map, sorted by X
Definition: libmwaw_internal.hxx:803
LIBMWAW_ATTRIBUTE_PRINTF
#define LIBMWAW_ATTRIBUTE_PRINTF(fmt, arg)
Definition: libmwaw_internal.hxx:108
MWAW_shared_ptr_noop_deleter::operator()
void operator()(T *)
Definition: libmwaw_internal.hxx:102

Generated on Sun Aug 18 2019 09:48:29 for libmwaw by doxygen 1.8.16