[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Dotgnu-pnet-commits] CVS: pnetlib/samples dotgnu-logo.jpg,NONE,1.1 XHe
From: |
Rhys Weatherley <address@hidden> |
Subject: |
[Dotgnu-pnet-commits] CVS: pnetlib/samples dotgnu-logo.jpg,NONE,1.1 XHello.cs,1.3,1.4 |
Date: |
Sat, 07 Jun 2003 01:40:09 -0400 |
Update of /cvsroot/dotgnu-pnet/pnetlib/samples
In directory subversions:/tmp/cvs-serv31536/samples
Modified Files:
XHello.cs
Added Files:
dotgnu-logo.jpg
Log Message:
Add image loading and drawing facilities, using Imlib to do the loading;
update XHello to display the DotGNU logo instead of crossed lines.
--- NEW FILE ---
ÿØÿà
(1#%(:3=<address@hidden@DWE78PmQW_bghg>Mqypdx\egcÿÛ
Index: XHello.cs
===================================================================
RCS file: /cvsroot/dotgnu-pnet/pnetlib/samples/XHello.cs,v
retrieving revision 1.3
retrieving revision 1.4
diff -C2 -r1.3 -r1.4
*** XHello.cs 6 Jun 2003 10:46:45 -0000 1.3
--- XHello.cs 7 Jun 2003 05:40:07 -0000 1.4
***************
*** 30,34 ****
{
Application app = new Application("XHello", args);
! XHello topLevel = new XHello("Hello World!", 200, 100);
topLevel.Map();
app.Run();
--- 30,36 ----
{
Application app = new Application("XHello", args);
! Image image = new Image("dotgnu-logo.jpg");
! XHello topLevel = new XHello
! ("Hello DotGNU!", image.Width, image.Height, image);
topLevel.Map();
app.Run();
***************
*** 36,48 ****
}
// Constructor.
! public XHello(String title, int width, int height)
! : base(title, width, height) {}
// Handle paint requests.
protected override void OnPaint(Graphics graphics)
{
! graphics.DrawLine(0, 0, Width, Height);
! graphics.DrawLine(0, Height, Width, 0);
}
--- 38,56 ----
}
+ // Internal state.
+ private Image image;
+
// Constructor.
! public XHello(String title, int width, int height, Image image)
! : base(title, width, height)
! {
! this.image = image;
! this.Background = new Color(0, 0, 0);
! }
// Handle paint requests.
protected override void OnPaint(Graphics graphics)
{
! graphics.DrawImage(0, 0, image);
}
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Dotgnu-pnet-commits] CVS: pnetlib/samples dotgnu-logo.jpg,NONE,1.1 XHello.cs,1.3,1.4,
Rhys Weatherley <address@hidden> <=