X-Git-Url: https://git.tokkee.org/?a=blobdiff_plain;f=src%2Fdisplay%2Fnr-arena-glyphs.cpp;h=05b513e52b8c9cfc253350fa4ae5cb38a97f3c85;hb=f5c0236a5cad739899ead1b24864c3c8654ab078;hp=861b8baf8f53b74191f103fd7c87328f77ba8cda;hpb=6b15695578f07a3f72c4c9475c1a261a3021472a;p=inkscape.git diff --git a/src/display/nr-arena-glyphs.cpp b/src/display/nr-arena-glyphs.cpp index 861b8baf8..05b513e52 100644 --- a/src/display/nr-arena-glyphs.cpp +++ b/src/display/nr-arena-glyphs.cpp @@ -147,6 +147,8 @@ nr_arena_glyphs_update (NRArenaItem *item, NRRectL *area, NRGC *gc, guint state, bbox.x0 = bbox.y0 = NR_HUGE; bbox.x1 = bbox.y1 = -NR_HUGE; + const float scale = NR_MATRIX_DF_EXPANSION (&gc->transform); + if (glyphs->style->fill.type != SP_PAINT_TYPE_NONE) { NRMatrix t; nr_matrix_multiply (&t, &glyphs->g_transform, &gc->transform); @@ -158,7 +160,7 @@ nr_arena_glyphs_update (NRArenaItem *item, NRRectL *area, NRGC *gc, guint state, if (glyphs->rfont) glyphs->rfont->Unref(); glyphs->rfont = rfont; - if (glyphs->style->stroke.type == SP_PAINT_TYPE_NONE) { // Optimization: do fill bbox only if there's no stroke + if (glyphs->style->stroke.type == SP_PAINT_TYPE_NONE || fabs(glyphs->style->stroke_width.computed * scale) <= 0.01) { // Optimization: do fill bbox only if there's no stroke NRRect narea; if ( glyphs->rfont ) glyphs->rfont->BBox(glyphs->glyph, &narea); bbox.x0 = narea.x0 + glyphs->x; @@ -177,7 +179,6 @@ nr_arena_glyphs_update (NRArenaItem *item, NRRectL *area, NRGC *gc, guint state, t.c[4]=0; t.c[5]=0; - const float scale = NR_MATRIX_DF_EXPANSION (&gc->transform); if ( fabs(glyphs->style->stroke_width.computed * scale) > 0.01 ) { // sinon c'est 0=oon veut pas de bord font_style nstyl; nstyl.transform = t;