M meson_options.txt => meson_options.txt +1 -1
@@ 55,4 55,4 @@ option('use-fontconfig',
value : 'disabled',
yield : true)
-option('version', type : 'string', value : '0.1.1327')
+option('version', type : 'string', value : '0.1.1329')
M src/backend_nanovg.c => src/backend_nanovg.c +3 -5
@@ 371,20 371,18 @@ _d2tk_nanovg_surf_draw(NVGcontext *ctx, int img, d2tk_coord_t xo,
d2tk_coord_t w = W;
d2tk_coord_t h = H;
- float scale = 1.f;
if(h != rect->h)
{
- scale = (float)rect->h / h;
+ const float scale = (float)rect->h / h;
w *= scale;
h = rect->h;
}
if(w > rect->w)
{
- const float scale_t = (float)rect->w / w;
- scale *= scale_t;
- h *= scale_t;
+ const float scale = (float)rect->w / w;
+ h *= scale;
w = rect->w;
}