Last night a strange thing happened with a program I am developing in Processing 2.0.2 on Mac OS X 10.6.8. I use the sequence in setup()
hint(ENABLE_NATIVE_FONTS);
font = createFont("Helvetica", 32, true);
textFont(font, 32);
In other places I use the font in different sizes, using textSize(theSize) in various methods, where theSize is a method argument. This has worked well until yesterday afternoon, and it works fine this afternoon.
But last night, with no change in the code, nor as far as I know in the Processing application, which still says it is 2.0.2 in the "About" dialogue, I got a red console message saying that " hint(ENABLE_NATIVE_FONTS);" was not supported in Processing 2.0.4, and to use createFont() instead. All my text outputs were distorted, with irregular baselines, some fuzzy letters, some letters faded to near invisibility. This afternoon everything again works as it had been, with crisp text (I had originally put the "hint" in the code because without it I had been unable to get crisp text).
Two questions: (1) Where did this message come from and why was my text output distorted, when so far as I know, absolutely nothing changed between when I went for dinner and when I came back a couple of hours later?
(2) If the "hint" is indeed going to be not supported, how is one supposed to produce nice-looking text?
hint(ENABLE_NATIVE_FONTS);
font = createFont("Helvetica", 32, true);
textFont(font, 32);
In other places I use the font in different sizes, using textSize(theSize) in various methods, where theSize is a method argument. This has worked well until yesterday afternoon, and it works fine this afternoon.
But last night, with no change in the code, nor as far as I know in the Processing application, which still says it is 2.0.2 in the "About" dialogue, I got a red console message saying that " hint(ENABLE_NATIVE_FONTS);" was not supported in Processing 2.0.4, and to use createFont() instead. All my text outputs were distorted, with irregular baselines, some fuzzy letters, some letters faded to near invisibility. This afternoon everything again works as it had been, with crisp text (I had originally put the "hint" in the code because without it I had been unable to get crisp text).
Two questions: (1) Where did this message come from and why was my text output distorted, when so far as I know, absolutely nothing changed between when I went for dinner and when I came back a couple of hours later?
(2) If the "hint" is indeed going to be not supported, how is one supposed to produce nice-looking text?
1