2014-11-19 16:02 GMT+01:00 Pierre CHANSON <chans.pierre@gmail.com>:Thank you,Apparently the instance variable "strokePaint" of TRShape class, would be Nil when used by TRPolygonShape... But this variable seemed to be initialized in color black earlier so... I don't know what's appenning.For exemple you get an error when executing:Hi,does anyone know how to use RTPolygon shape or is there a real problem inside ?
-=-=-=-=-=-=-=-=-=-=-=-=
v := RTView new.
p := RTPolygon new
������ vertices:{
������ ������ 25 @ 00 .
������ ������ 10 @ 50 .
������ ������ 50 @ 20 }.
������ ������
v add: (p elementOn: 1).
v open
-=-=-=-=-=-=-=-=-=-=-=-=
If someone have a Idea...
PIerreThe color is set on the RTPolygon but it is overriden by the call to #updateFor:trachelShape:this sets the color based on the RTElement. But if no property is there for setting the border color,�� it is just overriden with nil.RTBox does not have this problem, because the TRAbstractBoxShape draw method only draws the stroke
if it is not nil.This has to be fixed in Roassal2, until then, just set the property manually
v := RTView new.
p := RTPolygon new borderColor: Color black;
������ vertices:{
�������������� 25 @ 00 .
�������������� 10 @ 50 .
�������������� 50 @ 20 }.
������������
v add: (p elementOn: 1).
v opennicolai