[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Dotgnu-pnet-commits] pnetlib/System.Drawing.Xsharp DrawingGraphics.cs,
From: |
Rhys Weatherley <address@hidden> |
Subject: |
[Dotgnu-pnet-commits] pnetlib/System.Drawing.Xsharp DrawingGraphics.cs, 1.16, 1.17 |
Date: |
Sun, 30 Nov 2003 05:00:23 +0000 |
Update of /cvsroot/dotgnu-pnet/pnetlib/System.Drawing.Xsharp
In directory subversions:/tmp/cvs-serv10791/System.Drawing.Xsharp
Modified Files:
DrawingGraphics.cs
Log Message:
Shift "MeasureString", "DrawString", and "GetFontExtents" into the
"Xsharp.Font" class so that we can subclass it for different font
rendering systems.
Index: DrawingGraphics.cs
===================================================================
RCS file:
/cvsroot/dotgnu-pnet/pnetlib/System.Drawing.Xsharp/DrawingGraphics.cs,v
retrieving revision 1.16
retrieving revision 1.17
diff -C2 -d -r1.16 -r1.17
*** DrawingGraphics.cs 20 Nov 2003 07:42:20 -0000 1.16
--- DrawingGraphics.cs 30 Nov 2003 05:00:21 -0000 1.17
***************
*** 167,172 ****
{
Xsharp.Font xfont = (font as DrawingFont).xfont;
! FontExtents extents =
graphics.GetFontExtents(xfont);
! graphics.DrawString(RestrictXY(x),
RestrictXY(y) + extents.Ascent, s, xfont);
}
--- 167,174 ----
{
Xsharp.Font xfont = (font as DrawingFont).xfont;
! FontExtents extents =
xfont.GetFontExtents(graphics);
! xfont.DrawString(graphics, RestrictXY(x),
! RestrictXY(y)
+ extents.Ascent,
! s, 0,
s.Length);
}
***************
*** 182,187 ****
linesFilled = 0;
Xsharp.Font xfont = (font as DrawingFont).xfont;
! graphics.MeasureString
! (s, xfont, out width, out ascent, out
descent);
if(!ascentOnly)
{
--- 184,190 ----
linesFilled = 0;
Xsharp.Font xfont = (font as DrawingFont).xfont;
! xfont.MeasureString
! (graphics, s, 0, s.Length,
! out width, out ascent, out descent);
if(!ascentOnly)
{
***************
*** 266,270 ****
{
Xsharp.Font xfont = (font as DrawingFont).xfont;
! FontExtents extents =
graphics.GetFontExtents(xfont);
return extents.Ascent + extents.Descent;
}
--- 269,273 ----
{
Xsharp.Font xfont = (font as DrawingFont).xfont;
! FontExtents extents =
xfont.GetFontExtents(graphics);
return extents.Ascent + extents.Descent;
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Dotgnu-pnet-commits] pnetlib/System.Drawing.Xsharp DrawingGraphics.cs, 1.16, 1.17,
Rhys Weatherley <address@hidden> <=
- Prev by Date:
[Dotgnu-pnet-commits] pnetlib/Xsharp Font.cs, 1.3, 1.4 Graphics.cs, 1.12, 1.13
- Next by Date:
[Dotgnu-pnet-commits] pnetlib ChangeLog,1.1559,1.1560
- Previous by thread:
[Dotgnu-pnet-commits] pnetlib/Xsharp Font.cs, 1.3, 1.4 Graphics.cs, 1.12, 1.13
- Next by thread:
[Dotgnu-pnet-commits] pnetlib ChangeLog,1.1559,1.1560
- Index(es):