You need to set scalarvisibilityOff() for the mapper, else by default the mapper controls the colour. I came across this problem before too, and made an entry in my blog, where I say what I want to do, what problem I met, and how I solved it.<div>
<br></div><div>You need something like this: <span class="Apple-style-span" style="font-family: 'courier new'; color: rgb(51, 51, 51); line-height: 19px; ">map.ScalarVisibilityOff()</span><br><div><br></div><div>
<a href="http://learnwithhelvin.blogspot.com/2009/08/actor-color-colour-change.html">http://learnwithhelvin.blogspot.com/2009/08/actor-color-colour-change.html</a></div>
<div><br></div><div><a href="http://learnwithhelvin.blogspot.com/2009/08/actor-color-colour-change.html"></a>Helvin<br><br><div class="gmail_quote">On Fri, Sep 4, 2009 at 1:04 PM, Venkattraman A <span dir="ltr"><<a href="mailto:venkattraman04@gmail.com">venkattraman04@gmail.com</a>></span> wrote:<br>
<blockquote class="gmail_quote" style="margin:0 0 0 .8ex;border-left:1px #ccc solid;padding-left:1ex;">Hi,<br><br>I have been trying to change the properties of the y-axis label in one of my xy plots obtained in VTK. I use the following piece of code<br>
<br> self.xyplot.GetYAxisActor2D().GetTitleTextProperty().SetOrientation(45.0)<br>
self.xyplot.GetYAxisActor2D().GetTitleTextProperty().ItalicOn()<br> self.xyplot.GetYAxisActor2D().GetTitleTextProperty().BoldOn()<br> self.xyplot.GetYAxisActor2D().GetTitleTextProperty().SetColor(1.0,0.0,0.0)<br>
print self.xyplot.GetYAxisActor2D().GetTitleTextProperty().GetColor()<br> print self.xyplot.GetYAxisActor2D().GetTitleTextProperty().GetOrientation()<br><br>I notice that the print statements do reflect the changes I made but there is absolutely no change in the plot itself. Is there some kind of an Update() like method I need to call ? My main aim is to rotate the Y axis label by 90 degrees but none of the text property changes are reflected and so I was wondering if I was overlooking something very silly.<br>
<br>Thanks in advance!<br>Venkat<br>-- <br><font color="#888888">Venkattraman<br>
</font><br>_______________________________________________<br>
Powered by <a href="http://www.kitware.com" target="_blank">www.kitware.com</a><br>
<br>
Visit other Kitware open-source projects at <a href="http://www.kitware.com/opensource/opensource.html" target="_blank">http://www.kitware.com/opensource/opensource.html</a><br>
<br>
Please keep messages on-topic and check the VTK FAQ at: <a href="http://www.vtk.org/Wiki/VTK_FAQ" target="_blank">http://www.vtk.org/Wiki/VTK_FAQ</a><br>
<br>
Follow this link to subscribe/unsubscribe:<br>
<a href="http://www.vtk.org/mailman/listinfo/vtkusers" target="_blank">http://www.vtk.org/mailman/listinfo/vtkusers</a><br>
<br></blockquote></div><br><br clear="all"><br>-- <br>Helvin <br><br>"Though the world may promise me more, I'm just made to be filled with the Lord."<br>
</div></div>