Re: JSUI-MGraphics patch-a-day

Forums > Javascript > JSUI-MGraphics patch-a-day
Nov 30 2011 | 7:08 pm

Here is the patch for November 30, 2011:

Alas, we hit the end of the road. In this ditty, we do a bit of javascript coding to perform a word-wrap on my heartfelt goodbye. Change the font or the font size and the text should wrap accordingly. This uses the text_measure() function to get the width of a string, then back-pedal if we’ve gone too far.

Not the most elegant wordwrap function ever written, but you get the idea.

I hope you’ve enjoyed the series, and find the mgraphics system to your liking!

Subscribe to the Cycling ’74 Weekly Newsletter

Let us tell you about notable Max projects, obscure facts, and creative media artists of all kinds.

* indicates required