Here a real simple example of loading and drawing a bitmap.<br><br>#lang scheme/gui<br><br>(define the-bitmap<br> (make-object bitmap% "225px-Charles_Darwin_seated.jpg"))<br><br>(define frame<br> (instantiate frame%<br>
("Display a bitmap")))<br><br>(define canvas<br> (instantiate canvas%<br> (frame)<br> (paint-callback<br> (lambda (canvas dc)<br> (send dc draw-bitmap the-bitmap 0 0)))<br> (min-width (send the-bitmap get-width))<br>
(min-height (send the-bitmap get-height))))<br><br>(send frame show #t)<br><br>Doug<br><br><div class="gmail_quote">On Fri, Sep 4, 2009 at 9:36 AM, Zach Brown <span dir="ltr"><<a href="mailto:growingupright@yahoo.com">growingupright@yahoo.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="border-left: 1px solid rgb(204, 204, 204); margin: 0pt 0pt 0pt 0.8ex; padding-left: 1ex;"><div><div style="font-family: times new roman,new york,times,serif; font-size: 10pt; color: rgb(34, 34, 68);">
<table align="center" cellpadding="0" cellspacing="0" width="100%"><tbody><tr><td background="?ui=2&ik=67ed27b52b&view=att&th=12385b9ed98eafeb&attid=0.0.1.1&disp=emb&zw" bgcolor="#a7b9e1" height="110">
</td></tr><tr><td bgcolor="#a7b9e1" height="100%" valign="top" width="100%"><table style="table-layout: fixed;" align="center" cellpadding="0" cellspacing="0" height="100%" width="100%"><tbody><tr><td width="10"> </td><td style="overflow: hidden; white-space: nowrap;" valign="top">
<table style="white-space: normal;" cellpadding="0" cellspacing="0" width="100%"><tbody><tr><td height="10"> </td></tr><tr><td><font style="font-family: Arial,Sans-serif; font-size: 13px; color: rgb(34, 34, 68);" size="2" color="#222244" face="Arial,Sans-serif"><div style="">
<div>Hello,</div>
<div> </div>
<div> I need to find out how to display an image ( im1.gif ) on a PLT Scheme frame. I think I need to make a bitmap object, but I am not sure. Any help would be wonderful.</div>
<div> </div>
<div>Thanks,</div>
<div> </div>
<div>Zach Brown</div>
<div><a href="http://www.zbtech.tk" target="_blank">http://www.zbtech.tk</a></div></div></font></td></tr><tr><td height="10"> </td></tr></tbody></table></td><td width="10"> </td></tr></tbody></table></td></tr></tbody></table>
</div><br>
</div><br>_________________________________________________<br>
For list-related administrative tasks:<br>
<a href="http://list.cs.brown.edu/mailman/listinfo/plt-scheme" target="_blank">http://list.cs.brown.edu/mailman/listinfo/plt-scheme</a><br>
<br></blockquote></div><br>