Topic: 如何在swt程序中设置composite的背景图片

  Print this page

1.如何在swt程序中设置composite的背景图片 Copy to clipboard
Posted by: chzh112
Posted on: 2004-12-28 16:44

如何在swt程序中设置composite的背景图片,其他组件如button等都有setimage方法,那该如何设置composite的背景图片呢?

2.Re:如何在swt程序中设置composite的背景图片 [Re: chzh112] Copy to clipboard
Posted by: Jay
Posted on: 2004-12-29 23:09

你可以使用Label或CLable
另一种方法是用GC画出背景图
shell.addPaintListener(new PaintListener() {
public void paintControl(PaintEvent e) {
e.gc.drawImage(...);//参数见javadoc
}
});


   Powered by Jute Powerful Forum® Version Jute 1.5.6 Ent
Copyright © 2002-2021 Cjsdn Team. All Righits Reserved. 闽ICP备05005120号-1
客服电话 18559299278    客服信箱 714923@qq.com    客服QQ 714923