Hi guys, thanks for your help. Much appreciated. Howard's addition does help a little, but if you type eight '1's and eight '0's the size will be the same with the above expression. Somehow I need to feed in the resulting width of the text (in pixels) as a mutiplier for the size of the font. Now this creates a feedback loop. But there must be a way to do that. Essentially, what I need, is to tell the Text node I want the text to be a certain width (in pixels) and for the size to be adjusted accordingly.
Ron Ganbar email: [email protected] tel: +44 (0)7968 007 309 [UK] +972 (0)54 255 9765 [Israel] url: http://ronganbar.wordpress.com/ On 5 March 2013 12:11, Holger Hummel|Celluloid VFX <[email protected] > wrote: > yeah. like i said it would probably need to be a little more sophisticated > depending on the use-case. > bringing the text box dimensions into the equation like Howard did > definitely makes sense. > i wasn't really up for going too deep into this late last night, so i was > just able to give kind of a hint > into the (hopfully) right direction ;) > @Rich: the number '5000' was trial and error and needs to be adjusted to > one's needs. > it should be replaced by some more sophisticated solution like Howard's > suggesting. > this still doesn't take multiple lines into account, though. for the > perfect setup it needs a bit more > thinking put into it, i'm afraid... > > cheers, > Holger > > > Howard Jones wrote: > >> This will resize as you adjust the box but the arbitary scale factor at >> the end seems to vary depending on letter size (i vs o) as Ron mentions. >> So it's probably worth breaking it out as a new knob >> >> (box.r-box.x)/[string length [value message]]*2 >> >> Howard >> >> ------------------------------**------------------------------** >> ------------ >> *From:* Ron Ganbar <[email protected]> >> *To:* Nuke user discussion >> <nuke-users@support.**thefoundry.co.uk<[email protected]> >> > >> *Sent:* Tuesday, 5 March 2013, 8:26 >> *Subject:* Re: [Nuke-users] Automatically control Text size >> >> >> Hi Holger, >> thanks for this. >> I've been using this for a while now, but it quickly >> becomes apparent that a word with a lot of 'l's and 'i's will need >> to be bigger than a word with a lot of 'o's and 'c's. >> >> >> Thanks, >> Ron Ganbar >> email: [email protected] <mailto:[email protected]> >> >> tel: +44 (0)7968 007 309 [UK] >> +972 (0)54 255 9765 [Israel] >> url: http://ronganbar.wordpress.**com/<http://ronganbar.wordpress.com/> >> >> >> On 5 March 2013 05:17, Richard Bobo <[email protected] >> <mailto:[email protected]>> wrote: >> >> Hi Holger, >> >> I've been trying out your suggestion and I am wondering where >> the number 5000 came from? Is it somehow related to the >> project's full size format setting or something else…? >> >> Thanks, >> Rich >> >> Rich Bobo >> Senior VFX Compositor >> Armstrong-White >> http://armstrong-white.com/ >> >> Email: [email protected] <mailto:[email protected]> >> >> Mobile: (248) 840-2665 >> Web: http://richbobo.com/ >> >> "Your beliefs become your thoughts. Your thoughts become your >> words. Your words become your actions. Your actions become >> your habits. Your habits become your values. Your >> values become your destiny." >> >> - Mahatma Ghandi >> >> >> On Mar 4, 2013, at 5:05 PM, Holger Hummel|Celluloid VFX >> <[email protected] >> <mailto:holger@celluloid-vfx.**com<[email protected]> >> >> >> wrote: >> >> hi Ron, >>> >>> not 100% exactly what you're looking for, i guess, but maybe >>> a starting point. >>> put this expression into the size knob of the Text node: >>> >>> 5000/[string length [value message]] >>> >>> works ok for one-liners (sometimes needs an additional >>> whitespace at the end). >>> needs a bit of playing with the value that suits your needs >>> best instead of '5000'. >>> and, of course, if you have line breaks in your text that >>> makes things more difficult. >>> in the worst case maybe you'd need a python function to >>> return the size value based >>> on more factors than just the number of characters. >>> >>> cheers, >>> Holger >>> >>> >>> Am 04.03.2013 22:02, schrieb Ron Ganbar: >>> >>>> That would be good. Yes. >>>> The only way I can think to do this is by calling up the >>>> bounding box (don't confuse this with the Text node's box >>>> property, I mean the dotted line bounding box - the >>>> proverbial DOD) but that creates a feedback loop currently, >>>> it seems. >>>> >>>> >>>> Ron Ganbar >>>> email: [email protected] <mailto:[email protected]> >>>> >>>> tel: +44 (0)7968 007 309 [UK] >>>> +972 (0)54 255 9765 [Israel] >>>> url: >>>> http://ronganbar.wordpress.**com/<http://ronganbar.wordpress.com/> >>>> >>>> >>>> On 4 March 2013 22:57, Rich Bobo <[email protected] >>>> <mailto:[email protected]>> wrote: >>>> >>>> Ron, >>>> >>>> I'd love that, too. And, I'd add the ability for it to >>>> scale up to fit. Essentially, a scale-to-fit would be great… >>>> >>>> >>>> Rich >>>> >>>> Rich Bobo >>>> Senior VFX Compositor >>>> Armstrong-White >>>> http://armstrong-white.com/ >>>> >>>> Email: [email protected] <mailto:[email protected]> >>>> >>>> Mobile: (248) 840-2665 >>>> Web: http://richbobo.com/ >>>> >>>> "What you can do, or dream you can do, begin it; >>>> boldness has genius, power and magic in it." >>>> - Johann von Goethe >>>> >>>> >>>> >>>> >>>> >>>> On Mar 4, 2013, at 3:03 PM, Ron Ganbar <[email protected] >>>> <mailto:[email protected]>> wrote: >>>> >>>> Hi guys, >>>>> can anyone think of a way to automatically control the >>>>> font size of text in the Text node so a line of text >>>>> always remains in the text box? >>>>> At the moment, if some text is longer than the box it >>>>> splits itself up and continues in another line. I want >>>>> the text to become smaller instead. >>>>> Any ideas? >>>>> >>>>> Ron Ganbar >>>>> email: [email protected] <mailto:[email protected]> >>>>> >>>>> tel: +44 (0)7968 007 309 [UK] >>>>> +972 (0)54 255 9765 [Israel] >>>>> url: >>>>> http://ronganbar.wordpress.**com/<http://ronganbar.wordpress.com/> >>>>> ______________________________**_________________ >>>>> Nuke-users mailing list >>>>> >>>>> [email protected].**co.uk<[email protected]> >>>>> >>>>> <mailto:Nuke-users@support.**thefoundry.co.uk<[email protected]> >>>>> >, >>>>> >>>>> http://forums.thefoundry.co.**uk/<http://forums.thefoundry.co.uk/> >>>>> http://support.thefoundry.co.** >>>>> uk/cgi-bin/mailman/listinfo/**nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >>>>> >>>> >>>> >>>> ______________________________**_________________ >>>> Nuke-users mailing list >>>> >>>> [email protected].**co.uk<[email protected]> >>>> >>>> <mailto:Nuke-users@support.**thefoundry.co.uk<[email protected]> >>>> >, >>>> >>>> >>>> http://forums.thefoundry.co.**uk/<http://forums.thefoundry.co.uk/> >>>> http://support.thefoundry.co.**uk/cgi-bin/mailman/listinfo/ >>>> **nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >>>> >>>> >>>> >>>> >>>> ______________________________**_________________ >>>> Nuke-users mailing list >>>> >>>> [email protected].**co.uk<[email protected]><mailto: >>>> Nuke-users@support.**thefoundry.co.uk<[email protected]>>, >>>> http://forums.thefoundry.co.**uk/ <http://forums.thefoundry.co.uk/> >>>> http://support.thefoundry.co.**uk/cgi-bin/mailman/listinfo/** >>>> nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >>>> >>> >>> ______________________________**_________________ >>> Nuke-users mailing list >>> >>> [email protected].**co.uk<[email protected]> >>> >>> <mailto:Nuke-users@support.**thefoundry.co.uk<[email protected]> >>> >, >>> http://forums.thefoundry.co.**uk/<http://forums.thefoundry.co.uk/> >>> http://support.thefoundry.co.**uk/cgi-bin/mailman/listinfo/** >>> nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >>> >> >> >> ______________________________**_________________ >> Nuke-users mailing list >> >> [email protected].**co.uk<[email protected]> >> >> <mailto:Nuke-users@support.**thefoundry.co.uk<[email protected]> >> >, >> >> http://forums.thefoundry.co.**uk/<http://forums.thefoundry.co.uk/> >> http://support.thefoundry.co.**uk/cgi-bin/mailman/listinfo/** >> nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >> >> >> >> ______________________________**_________________ >> Nuke-users mailing list >> >> [email protected].**co.uk<[email protected]> >> >> <mailto:Nuke-users@support.**thefoundry.co.uk<[email protected]> >> >, >> http://forums.thefoundry.co.**uk/ <http://forums.thefoundry.co.uk/> >> http://support.thefoundry.co.**uk/cgi-bin/mailman/listinfo/** >> nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >> >> ------------------------------**------------------------------** >> ------------ >> >> >> ______________________________**_________________ >> Nuke-users mailing list >> [email protected].**co.uk<[email protected]>, >> http://forums.thefoundry.co.**uk/ <http://forums.thefoundry.co.uk/> >> http://support.thefoundry.co.**uk/cgi-bin/mailman/listinfo/**nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >> > > -- > Holger Hummel - [email protected] > > Celluloid Visual Effects GmbH & Co. KG > Paul-Lincke-Ufer 39/40, 10999 Berlin > phone +49 (0)30 / 54 735 220 - [email protected] > > > ______________________________**_________________ > Nuke-users mailing list > [email protected].**co.uk<[email protected]>, > http://forums.thefoundry.co.**uk/ <http://forums.thefoundry.co.uk/> > http://support.thefoundry.co.**uk/cgi-bin/mailman/listinfo/**nuke-users<http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users> >
_______________________________________________ Nuke-users mailing list [email protected], http://forums.thefoundry.co.uk/ http://support.thefoundry.co.uk/cgi-bin/mailman/listinfo/nuke-users
