<div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sun, Oct 23, 2016 at 11:13 AM, Liu_tj <span dir="ltr"><<a href="mailto:tjlp@netease.com" target="_blank">tjlp@netease.com</a>></span> wrote:<br><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div>Hi, VTK guys,<br><br>When I display a vtkCaptionWidget, I want to set the position of the text. So I call the vtkActor2D:;SetPostion() and SetPosition2(), but when the widget is displayed, the text is alway at the left bottom corner, why? Below is my C# code:<br>[snip]<br>rep.GetCaptionActor2D().<wbr>GetTextActor().SetPosition(<wbr>textPos1[0], textPos1[1]);<br>rep.GetCaptionActor2D().<wbr>GetTextActor().SetPosition2(<wbr>textPos2[0], textPos2[1]);<br></div></blockquote><div><br></div><div>Try just setting the position of the caption actor itself. When the caption actor renders, it sets the text actor's position. So,</div><div><br></div><div>rep.GetCaptionActor2D().SetPosition(<wbr>textPos1[0], textPos1[1]);</div><div>rep.GetCaptionActor2D().SetPosition2(<wbr>textPos2[0], textPos2[1]);</div><div><br></div><div>should get you what you want.</div><div><br></div><div>HTH,</div><div>Dave</div></div></div></div>