Archived issue #0023633
vdrawtext command modifies the default text parameters
Description
vdrawtext command modifies the default text parameters.
This happens because MyTextClass::Compute() in ViewerTest_ObjectCommands.cxx does not create a new instance of Prs3d_TextAspect but rather modifies the default (global) one returned by myDrawer->TextAspect() call.
The side-effect is changed color of all text labels displayed in the test 3d view after vdrawtext command has been executed, e.g. the trihedron labels.
This happens because MyTextClass::Compute() in ViewerTest_ObjectCommands.cxx does not create a new instance of Prs3d_TextAspect but rather modifies the default (global) one returned by myDrawer->TextAspect() call.
The side-effect is changed color of all text labels displayed in the test 3d view after vdrawtext command has been executed, e.g. the trihedron labels.
Steps to reproduce
pload ALL
vinit
vdrawtext AAA 0 0 0 0 255 255 0 0 0 0 30 0
vtrihedron t
# Enjoy the cyan color of trihedron labels instead of the default yellow
vinit
vdrawtext AAA 0 0 0 0 255 255 0 0 0 0 30 0
vtrihedron t
# Enjoy the cyan color of trihedron labels instead of the default yellow
Public activity
1 archived note
Participants are labeled by their role within this record.
Dear Commenter 1,
please close this issue - the problem has been fixed in scope of #0022785.
Test case is not needed.
please close this issue - the problem has been fixed in scope of #0022785.
Test case is not needed.