Ecere SDK/eC Forums

Ecere Developers Community

加载背景图片loadBackgroudImage

来自中国的朋友,欢迎您在本版面使用中文讨论问题。请注意,如果您想得到不懂中文的人的帮助,请同时提供英文译文。
Help and discussions in Chinese.

加载背景图片loadBackgroudImage

Postby liqi98136 » Wed Mar 10, 2010 8:53 am

Code: Select all
import "ecere"

class Image : Window
{
   text = "加载背景图片";
   background = black;
   borderStyle = fixed;
   hasMinimize = true;
   hasClose = true;
   size = { 500, 400 };

   isActiveClient = true;

   BitmapResource boardBMP { ":back.jpg", window = this };

   void OnRedraw(Surface surface)
   {
      surface.SetForeground(white);
      surface.Blit(boardBMP.bitmap, 0,0, 0,0, boardBMP.bitmap.width, boardBMP.bitmap.height);
   }
}

Image form1 {};
liqi98136
 
Posts: 53
Joined: Sun Jan 17, 2010 11:37 pm

Return to 欢迎使用中文讨论

Who is online

Users browsing this forum: No registered users and 1 guest

cron