[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Sc-devel] Pen: bug with fillRect, fillOval and fillColor



hi (jan),

i found a bug in Pen,
fillRect and fillOval (and maybe others?) are using the strokeColor, not the fillColor:

GUI.cocoa;
(
var width= 640, height= 480, w, drawFunc;
w= GUI.window.new("trail test3", Rect(128, 64, width, height), false);
drawFunc= {|v|
GUI.pen.fillColor_(Color.blue);
GUI.pen.strokeColor_(Color.green);
// these should be blue, but in fact they are green
GUI.pen.fillRect(Rect.aboutPoint(Point(100,100), 60, 40));
GUI.pen.fillOval(Rect.aboutPoint(Point(300,100), 60, 40));
};
x = GUI.userView.new(w, Rect(10, 10, width-20,
height-20)).drawFunc_(drawFunc);
w.front;
)


ciao, -sciss-