summaryrefslogtreecommitdiffstats
path: root/src/display/drawing-text.cpp
diff options
context:
space:
mode:
authorRichard White <rwhite8282@gmail.com>2016-05-19 01:17:29 +0000
committerRichard White <rwhite8282@gmail.com>2016-05-19 01:17:29 +0000
commit1fe9c2603c33fddcd9f2688b30e843f91e1a86fa (patch)
tree13289cbe033a46a40eb829437e115b5393e2ca84 /src/display/drawing-text.cpp
parentCorrected frame extension stroke and fill values on 64 bit machine. (diff)
parentGTK3: Another widget named. (diff)
downloadinkscape-1fe9c2603c33fddcd9f2688b30e843f91e1a86fa.tar.gz
inkscape-1fe9c2603c33fddcd9f2688b30e843f91e1a86fa.zip
Merge from Inkscape trunk.
(bzr r14668.1.3)
Diffstat (limited to 'src/display/drawing-text.cpp')
-rw-r--r--src/display/drawing-text.cpp16
1 files changed, 9 insertions, 7 deletions
diff --git a/src/display/drawing-text.cpp b/src/display/drawing-text.cpp
index a3ca7173a..f0d83abfd 100644
--- a/src/display/drawing-text.cpp
+++ b/src/display/drawing-text.cpp
@@ -100,14 +100,16 @@ unsigned DrawingGlyphs::_updateItem(Geom::IntRect const &/*area*/, UpdateContext
above and below the max/min y positions of the letters to place the text decorations.*/
Geom::Rect b;
- if(_drawable){
- Geom::OptRect tiltb = bounds_exact(*_font->PathVector(_glyph));
- Geom::Rect bigbox(Geom::Point(tiltb->left(),-_dsc*scale_bigbox*1.1),Geom::Point(tiltb->right(),_asc*scale_bigbox*1.1));
- b = bigbox * ctx.ctm;
+ if (_drawable) {
+ Geom::OptRect tiltb = bounds_exact(*_font->PathVector(_glyph));
+ if (tiltb) {
+ Geom::Rect bigbox(Geom::Point(tiltb->left(),-_dsc*scale_bigbox*1.1),Geom::Point(tiltb->right(),_asc*scale_bigbox*1.1));
+ b = bigbox * ctx.ctm;
+ }
}
- else { // Fallback, spaces mostly
- Geom::Rect bigbox(Geom::Point(0.0, -_dsc*scale_bigbox*1.1),Geom::Point(_width*scale_bigbox, _asc*scale_bigbox*1.1));
- b = bigbox * ctx.ctm;
+ if (b.hasZeroArea()) { // Fallback, spaces mostly
+ Geom::Rect bigbox(Geom::Point(0.0, -_dsc*scale_bigbox*1.1),Geom::Point(_width*scale_bigbox, _asc*scale_bigbox*1.1));
+ b = bigbox * ctx.ctm;
}
/*