[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Dotgnu-pnet-commits] CVS: pnetlib/System.Windows.Forms Label.cs,1.2,1.3
From: |
Rhys Weatherley <address@hidden> |
Subject: |
[Dotgnu-pnet-commits] CVS: pnetlib/System.Windows.Forms Label.cs,1.2,1.3 |
Date: |
Thu, 12 Jun 2003 21:35:53 -0400 |
Update of /cvsroot/dotgnu-pnet/pnetlib/System.Windows.Forms
In directory subversions:/tmp/cvs-serv31774/System.Windows.Forms
Modified Files:
Label.cs
Log Message:
OnPaint: adjust the text position to account for the border;
fill with the background color if "RenderTransparent" is not set.
Index: Label.cs
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnetlib/System.Windows.Forms/Label.cs,v
retrieving revision 1.2
retrieving revision 1.3
diff -C2 -r1.2 -r1.3
*** Label.cs 13 Jun 2003 01:30:23 -0000 1.2
--- Label.cs 13 Jun 2003 01:35:51 -0000 1.3
***************
*** 440,443 ****
--- 440,447 ----
(graphics, rect,
ForeColor,
ButtonBorderStyle.Solid);
+ rect.X += 1;
+ rect.Width -= 2;
+ rect.Y += 1;
+ rect.Height -= 2;
}
break;
***************
*** 448,453 ****
--- 452,469 ----
(graphics, rect,
BackColor,
ButtonBorderStyle.Inset);
+ rect.X += 1;
+ rect.Width -= 2;
+ rect.Y += 1;
+ rect.Height -= 2;
}
break;
+ }
+
+ // Fill the background if we aren't transparent.
+ if(!RenderTransparent)
+ {
+ Brush brush = CreateBackgroundBrush();
+ graphics.FillRectangle(brush, rect);
+ brush.Dispose();
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Dotgnu-pnet-commits] CVS: pnetlib/System.Windows.Forms Label.cs,1.2,1.3,
Rhys Weatherley <address@hidden> <=