<div>Hi, David,</div><div><br></div><div>There is no member method GetTextProperty() for vtkCaptionActor2D. No matter how much the font size is, the display is the same. And I found a similar post http://public.kitware.com/pipermail/vtkusers/2004-June/024902.html which is not answered.<br></div>
<span>
</span>
<br> 在2016-09-20,"David Lonie" <david.lonie@kitware.com> 写道:
<blockquote id="isReplyContent" style="padding-left:1ex; margin: 0px 0px 0px 0.8ex; BORDER-LEFT: #ccc 1px solid">
-----原始邮件-----<br>
<b>发件人:</b>"David Lonie" <david.lonie@kitware.com> <br>
<b>发送时间:</b>2016年09月20日 星期二<br>
<b>收件人:</b>"Liu_tj" <tjlp@netease.com><br>
<b>抄送:</b>"vtkusers" <vtkusers@vtk.org><br>
<b>主题:</b>Re: [vtkusers] Why the vtkTextProperty.SetFontSize() does not take effect?<br>
<br><div dir="ltr"><div class="gmail_extra"><div class="gmail_quote">On Sat, Sep 17, 2016 at 11:26 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:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex"><div>Hi, <br><br>I use vtkCaptionWidget to display text annotation on 3D model. My issue is the font size of the text. Below is my C# code:<br><br>vtkCaptionRepresentation rep = vtkCaptionRepresentation.New()<wbr>;<br>rep.GetCaptionActor2D().<wbr>ThreeDimensionalLeaderOff();<br>rep.GetCaptionActor2D().<wbr>GetTextActor().<wbr>GetTextProperty().SetFontSize(<wbr>100);<br>rep.GetCaptionActor2D().<wbr>GetTextActor().<wbr>GetTextProperty().<wbr>SetFontFamily(4);<br>rep.GetCaptionActor2D().<wbr>GetTextActor().<wbr>GetTextProperty().SetFontFile(<wbr>"simsunb.ttf");<br>rep.GetCaptionActor2D().<wbr>GetCaptionTextProperty().<wbr>SetColor(0.0, 1.0, 0.0);</wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></wbr></div></blockquote><div><br></div><div>Try setting it on rep.GetCaptionActor2D().GetTextProperty() instead of rep.GetCaptionActor2D().GetTextActor().GetTextProperty().</div><div><br></div><div>Dave</div></div></div></div>
</blockquote><br><br><span title="neteasefooter"><p> </p></span>