View.draw - what font and size?
-
When you use
view.draw
- is the font and text size always the same? I can't seem to find anything that affects it. -
I changed the Screen Text and the Leader Text in Model Info - but none of that affected the text produced by
view.text
.In a way I hope that it doesn't use the setting of any of these - as calculating the position of text would be completely impossible if it did (as oppose to just difficult if it's fixed.)
-
I think that view draw text uses the Font and Size set for 'Leader Text', as [re]set in your Model Info - this is [disappointingly] not changeable in Ruby...
Try changing your Leader Text to say Webdings and then make some view draw text to see what I mean -
Ok, so the question then is: is it the same font and size on OSX as well? (You'd think "yes", but I've learned not to make such assumptions.)
Can't help but wonder why no API to control this exist though. Did they just call it a day?
-
@thomthom said:
I changed the Screen Text and the Leader Text in Model Info - but none of that affected the text produced by
view.text
.
In a way I hope that it doesn't use the setting of any of these - as calculating the position of text would be completely impossible if it did (as oppose to just difficult if it's fixed.)
You are quite right - I quickly did the test using Chris's Bender Script that puts up 'start' and 'end' text, BUT I now discover that this text isn't view.text at all, as I had thought - it's actually some plain leader-text that is added then deleted ! Sorry for the confusion
Seems that the draw.text IS predetermined and unchangeable after all
Advertisement