Fonts displaying incorrectly
in
Programming Questions
•
2 years ago
On any sketch I make, text looks absolutely horrible unless I create something larger than intended size (like 96 for size 48) and use that font, shrunk down, to create text. And if I shrink it down too much, it begins to display incorrectly again.
Characters are not only overly pixelated and blurry, they also clip the top and left sides of the text off.
Am I doing something wrong? It's only sketches that I create, sketches on the website look fine, and I get the same results when I use the same font and the same size as the examples.
The following code produced this image for me:
Any idea what I'm doing wrong?
- void setup(){
- size(100, 100, P2D);
- PFont f = createFont("ArialMT-16", 16, true);
- textFont(f,16);
- fill(0);
- noLoop();
- }
- void draw(){
- background(255);
- text("example",16,16);
- }
- void mousePressed()
- {
- save("failtext.tif");
- }
1