зеркало из https://github.com/mozilla/pjs.git
Bug 358032 - SVG text too big when minimum font size set. r=tor, sr=roc
This commit is contained in:
Родитель
50f7b0fe8c
Коммит
dee5c24eeb
|
@ -1249,7 +1249,8 @@ void nsSVGGlyphFrame::SelectFont(gfxContext *aContext)
|
||||||
{
|
{
|
||||||
cairo_t *ctx = aContext->GetCairo();
|
cairo_t *ctx = aContext->GetCairo();
|
||||||
|
|
||||||
nsFont font = GetStyleFont()->mFont;
|
const nsStyleFont* fontData = GetStyleFont();
|
||||||
|
nsFont font = fontData->mFont;
|
||||||
|
|
||||||
// XXX eventually we will have to treat decorations separately from
|
// XXX eventually we will have to treat decorations separately from
|
||||||
// fonts, because they can have a different color than the current
|
// fonts, because they can have a different color than the current
|
||||||
|
@ -1306,7 +1307,7 @@ void nsSVGGlyphFrame::SelectFont(gfxContext *aContext)
|
||||||
presContext->DeviceContext()->GetCanonicalPixelScale(pixelScale);
|
presContext->DeviceContext()->GetCanonicalPixelScale(pixelScale);
|
||||||
float textZoom = presContext->TextZoom();
|
float textZoom = presContext->TextZoom();
|
||||||
|
|
||||||
cairo_set_font_size(ctx, font.size * pxPerTwips / pixelScale / textZoom);
|
cairo_set_font_size(ctx, fontData->mSize * pxPerTwips / pixelScale / textZoom);
|
||||||
}
|
}
|
||||||
|
|
||||||
void nsSVGGlyphFrame::UpdateGeometry(PRBool bRedraw,
|
void nsSVGGlyphFrame::UpdateGeometry(PRBool bRedraw,
|
||||||
|
|
Загрузка…
Ссылка в новой задаче