klaas.holwerda
2015-07-08 09:46:20 UTC
Hi,
SetContourWidth is not for setting the stroke witdh. It is for making donut shapes from a circle and
for other shapes simular effects,
Better leave it to zero.
If you have it set to zero, and the stroke width is m_stroke_width, do the colors work then for the
Polyline?
Also be aware that stroke width can be in pixels or in world size.
Let me know if this solves anything,
Via the mailinglist please ;-)
Regards,
Klaas
SetContourWidth is not for setting the stroke witdh. It is for making donut shapes from a circle and
for other shapes simular effects,
Better leave it to zero.
If you have it set to zero, and the stroke width is m_stroke_width, do the colors work then for the
Polyline?
Also be aware that stroke width can be in pixels or in world size.
Let me know if this solves anything,
Via the mailinglist please ;-)
Regards,
Klaas
Hello Klaas,
the fillcolour and strokecolour doesn't work with a2dDrawPolylineLTool.
a2dDrawPolylineLTool *winkel = new a2dDrawPolylineLTool (m_toolctrl);
winkel->SetEvtHandler( new a2dStToolFixedToolStyleEvtHandler( m_toolctrl ) );
a2dFill fill = a2dFill (m_tool_fill_color, a2dFILL_SOLID);
winkel->SetFill (fill);
winkel->SetContourWidth (m_contour_width);
a2dStroke stroke = a2dStroke (m_stroke_color, m_stroke_width, a2dSTROKE_SOLID);
winkel->SetStroke (stroke);
m_toolctrl->PushTool (winkel);
Colour for a2dDrawLineTool works fine
a2dDrawLineTool *line = new a2dDrawLineTool (m_toolctrl);
line->SetEvtHandler( new a2dStToolFixedToolStyleEvtHandler( m_toolctrl ) );
a2dFill fill = a2dFill (m_tool_fill_color, a2dFILL_SOLID);
line->SetFill (fill);
line->SetContourWidth (m_contour_width);
a2dStroke stroke = a2dStroke (m_stroke_color, m_stroke_width, a2dSTROKE_SOLID);
line->SetStroke (stroke);
m_toolctrl->PushTool (line);
Polyline and Line
Regards
Demir
the fillcolour and strokecolour doesn't work with a2dDrawPolylineLTool.
a2dDrawPolylineLTool *winkel = new a2dDrawPolylineLTool (m_toolctrl);
winkel->SetEvtHandler( new a2dStToolFixedToolStyleEvtHandler( m_toolctrl ) );
a2dFill fill = a2dFill (m_tool_fill_color, a2dFILL_SOLID);
winkel->SetFill (fill);
winkel->SetContourWidth (m_contour_width);
a2dStroke stroke = a2dStroke (m_stroke_color, m_stroke_width, a2dSTROKE_SOLID);
winkel->SetStroke (stroke);
m_toolctrl->PushTool (winkel);
Colour for a2dDrawLineTool works fine
a2dDrawLineTool *line = new a2dDrawLineTool (m_toolctrl);
line->SetEvtHandler( new a2dStToolFixedToolStyleEvtHandler( m_toolctrl ) );
a2dFill fill = a2dFill (m_tool_fill_color, a2dFILL_SOLID);
line->SetFill (fill);
line->SetContourWidth (m_contour_width);
a2dStroke stroke = a2dStroke (m_stroke_color, m_stroke_width, a2dSTROKE_SOLID);
line->SetStroke (stroke);
m_toolctrl->PushTool (line);
Polyline and Line
Regards
Demir