(void) ParseAbsoluteGeometry(image_info->page,&page);
if (image->columns == 0)
{
- pango_layout_get_pixel_extents(layout,NULL,&extent);
- image->columns=(extent.x+extent.width)/PANGO_SCALE+2*page.x;
+ pango_layout_get_extents(layout,NULL,&extent);
+ image->columns=(extent.x+extent.width+PANGO_SCALE/2)/PANGO_SCALE+2*page.x;
}
else
{
image->columns-=2*page.x;
pango_layout_set_width(layout,(int) ((PANGO_SCALE*image->columns*
- (image->resolution.x == 0.0 : 90.0 : image->resolution.x)+45.0)/90.0+
+ (image->resolution.x == 0.0 ? 90.0 : image->resolution.x)+45.0)/90.0+
0.5));
}
if (image->rows == 0)
{
- pango_layout_get_pixel_extents(layout,NULL,&extent);
- image->rows=(extent.y+extent.height)/PANGO_SCALE+2*page.y;
+ pango_layout_get_extents(layout,NULL,&extent);
+ image->rows=(extent.y+extent.height+PANGO_SCALE/2)/PANGO_SCALE+2*page.y;
}
else
{
image->rows-=2*page.y;
pango_layout_set_height(layout,(int) ((PANGO_SCALE*image->rows*
- (image->resolution.y == 0.0 : 90.0 : image->resolution.y)+45.0)/90.0+
+ (image->resolution.y == 0.0 ? 90.0 : image->resolution.y)+45.0)/90.0+
0.5));
}
/*