@cyl wrote:
Hi,
In order to render text, one can build text objects using cmd as
cmd = []
cmd.Add('-_TextObject')
cmd.Add('_GroupOutput=Yes')
cmd.Add('_FontName=Arial')
cmd.Add('_Italic=No')
cmd.Add('_Bold=Yes')
cmd.Add('_Height=50')
cmd.Add('_Output=Solids')
cmd.Add('_Thickness=1')
cmd.Add('_AddSpacing=No')
cmd.Add('"Text"')
cmd.Add('0,0,0')
cmd.Add('Enter')
sendCmd = ' '.join(cmd)
rs.Command(sendCmd,False)ido=rs.LastCreatedObjects()
rs.RotateObject(ido,(0,0,0),90,(1,0,0))
rs.MoveObject(ido,(0,-3,50))
for i in ido:
rs.MatchMaterial(MyMaterialIndex,i)This however does not work properly, for instance when there are several text objects with different fonts.
Is there a more effective way to script the construction of a text object ?
Any hint will be help !
Posts: 3
Participants: 2