use*_*967 1 eclipse-plugin eclipse-rcp draw2d eclipse-gef
我RectangleFigure在draw2d中使用了一个矩形.我可以通过调用为矩形图形着色rectangleFigure.setBackgroundColor.现在我也想以同样的方式为图像着色.为此我ImageFigure在
draw2d中使用,我通过调用给出了背景颜色ImageFigure.setBackgroundColor().但它并没有给我任何颜色.那么我如何为draw2d中的图像赋予背景色?
RectangleFigure扩展Shape,默认情况下绘制自己的背景.ImageFigure直接扩展图形,如果将其设置为不透明,它将仅绘制背景:
imageFigure.setOpaque(true);
Run Code Online (Sandbox Code Playgroud)
| 归档时间: |
|
| 查看次数: |
885 次 |
| 最近记录: |