Warning: file_get_contents(/data/phpspider/zhask/data//catemap/7/user-interface/2.json): failed to open stream: No such file or directory in /data/phpspider/zhask/libs/function.php on line 167

Warning: Invalid argument supplied for foreach() in /data/phpspider/zhask/libs/tag.function.php on line 1116

Notice: Undefined index: in /data/phpspider/zhask/libs/function.php on line 180

Warning: array_chunk() expects parameter 1 to be array, null given in /data/phpspider/zhask/libs/function.php on line 181
User interface 如何在Blackberry Storm中设置抗锯齿?_User Interface_Graphics_Blackberry_Blackberry Storm_Rim 4.7 - Fatal编程技术网

User interface 如何在Blackberry Storm中设置抗锯齿?

User interface 如何在Blackberry Storm中设置抗锯齿?,user-interface,graphics,blackberry,blackberry-storm,rim-4.7,User Interface,Graphics,Blackberry,Blackberry Storm,Rim 4.7,我正在用位图绘制,如 bitmap[i] = new Bitmap(60, 60); Graphics g = new Graphics(bitmap[i]); g.setColor(Color.BLACK); g.drawLine(....); 现在如何在g.drawLine()之前设置抗锯齿 用于抗锯齿模式使用 供线路使用 graphics.setDrawingStyle(Graphics.DRAWSTYLE_AALINES, true); graphics.drawLine(x1,

我正在用位图绘制,如

bitmap[i] = new Bitmap(60, 60);  
Graphics g = new Graphics(bitmap[i]);
g.setColor(Color.BLACK);
g.drawLine(....);
现在如何在g.drawLine()之前设置抗锯齿

用于抗锯齿模式使用

供线路使用

graphics.setDrawingStyle(Graphics.DRAWSTYLE_AALINES, true);
graphics.drawLine(x1, y1, x2, y2);
graphics.setDrawingStyle(Graphics.DRAWSTYLE_AALINES, false);
供警察使用

graphics.setDrawingStyle(Graphics.DRAWSTYLE_AAPOLYGONS, true);
graphics.drawRect(x, y, width, height);
graphics.setDrawingStyle(Graphics.DRAWSTYLE_AAPOLYGONS, false);

谢谢我在模拟器里看不到它的效果。我将在Storm上测试它。标志
DRAWSTYLE\u AAPOLYGONS
也适用于圆和椭圆。它的效果在模拟器中是可以感知的,但您可能需要将缩放增加到4倍。