Message 1 of 2
Drawing View Label Multiple Fonts
- Mark as New
- Bookmark
- Subscribe
- Mute
- Subscribe to RSS Feed
- Permalink
- Report
Hi All,
see the image below. I would like to set the first line in the view label text "view identifier" & 2nd line description etc. as two different fonts. Currently, there is no way to change this through the standards editor and have to manually change this for each view. Inventor does let you change the font size for each line separately but not the font itself.
anyone have a solution to this, perhaps through i logic where it just takes the first line and formats it as needed
previously, i did find a workaround using ilogic. see below. But i would just like to format the first line without changing the 2nd & 3rd line
the code below would replace the 2nd & 3rd line as well even if you had a manual text in it.
sFont = "Times New Roman" sFont2 = "Tahoma" sFSize1 = 0.2*2.54 'font size in cm sFSize2 = 0.120*2.54 'font size in cm sString1 = "<StyleOverride Font='" & sFont & "' FontSize='" & sFSize1 & "' Underline='False'>" & _ "<DrawingViewName/></StyleOverride>"
'add lines to the view label 'break line using: "<Br/>" oView.Label.FormattedText = _ sString1 & "<Br/>" & _ sString2 & sString3 & sString4 & sString5 & sString6 & sString7 & sString8 & "<Br/>" & _ sString9 & sString10