Code

No more NRMatrix or NRPoint.
[inkscape.git] / src / libnrtype / Layout-TNG.h
index 48b01eae5f14ff10e5a7a0c50b12ad639bdf34f4..ec12ddff59e12051b8340082428cb7329b9895e3 100755 (executable)
@@ -17,6 +17,7 @@
 #include "libnr/nr-rotate-ops.h"
 #include <glibmm/ustring.h>
 #include <pango/pango-break.h>
+#include <algorithm>
 #include <vector>
 
 #ifdef HAVE_CAIRO_PDF
@@ -336,7 +337,7 @@ public:
      \param bbox  parameters
      \param ctm   do yet
     */
-    void print(SPPrintContext *ctx, NRRect const *pbox, NRRect const *dbox, NRRect const *bbox, NRMatrix const &ctm) const;
+    void print(SPPrintContext *ctx, NRRect const *pbox, NRRect const *dbox, NRRect const *bbox, NR::Matrix const &ctm) const;
 
 #ifdef HAVE_CAIRO_PDF    
     /** Renders all the glyphs to the given Cairo rendering context.
@@ -443,7 +444,7 @@ public:
     /** Returns the bounding box of the given glyph, and its rotation.
     The centre of rotation is the horizontal centre of the box at the
     text baseline. */
-    NR::Rect glyphBoundingBox(iterator const &it, double *rotation) const;
+    NR::Maybe<NR::Rect> glyphBoundingBox(iterator const &it, double *rotation) const;
 
     /** Returns the zero-based line number of the character pointed to by
     \a it. */
@@ -732,7 +733,7 @@ private:
 
     /** gets the overall matrix that transforms the given glyph from local
     space to world space. */
-    void _getGlyphTransformMatrix(int glyph_index, NRMatrix *matrix) const;
+    void _getGlyphTransformMatrix(int glyph_index, NR::Matrix *matrix) const;
 
     // loads of functions to drill down the object tree, all of them
     // annoyingly similar and all of them requiring predicate functors.