Thread: Subscript
View Single Post
  #2  
Old 04-11-2011, 09:46 AM
farshizzo farshizzo is offline
WorldViz Team Member
 
Join Date: Mar 2003
Posts: 2,849
I'm not sure why it's not showing up in the editor. I'll look into that.

To display subscript characters in the text object, you will need to change the font to one that supports it. For example, Cambria Math seems to support subscript:
Code:
import viz
viz.go()

text = viz.addText('C₁C₂C²C³',parent=viz.ORTHO,fontSize=30)
text.font('cambria.ttc')
viz.link(viz.CenterCenter,text)
The Cambria Math font is included with Windows Vista and up. There are other free math fonts available, like Asana-Math.
Reply With Quote