Skip to content

Possible bug in createFont() #248

Closed
Closed
@raft75

Description

@raft75

The following code works correctly in Java mode, but not in Android.
In Java mode the text appears smaller or bigger when I change the size parameter of createFont().
In Android mode the text is always very small. As a workaround to have a consistent behaviour between Java mode and Android mode, I use textSize() with the desired size after createFont().
Tested with Processing 3.2.1 on Galaxy S3 (Android 4.4.2)

PFont f;
void setup() {
  f = createFont("arial.ttf", 32, true);
  textFont(f);
}
void draw() {
  text("Hello", 20, 50);
}

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions