*PdfDraw: Fixed issue with negative font height

git-svn-id: svn://ultimatepp.org/upp/trunk@5945 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
cxl 2013-04-02 17:43:14 +00:00
parent c364130d59
commit 900f9f6b42

View file

@ -280,9 +280,13 @@ enum { FONTHEIGHT_TTF = -9999 };
void PdfDraw::DrawTextOp(int x, int y, int angle, const wchar *s, Font fnt,
Color ink, int n, const int *dx)
{
LLOG("DrawTextOp " << x << ", " << y << "angle: " << angle << ", text: " << s << ", font " << fnt);
if(!n) return;
if(fnt.GetHeight() == 0)
int h = fnt.GetHeight();
if(h == 0)
fnt.Height(100);
if(h < 0)
fnt.Height(-h);
Font ff = fnt;
int fh = fnt.GetHeight();
OutlineInfo of = GetOutlineInfo(fnt);