kramann.info
© Guido Kramann

Login: Passwort:










kramann.info
© Guido Kramann

Login: Passwort:




Textdarstellung bei Processing

(EN google-translate)

(PL google-translate)

PFont p_font;
PFont h1_font;

void setup()
{
    size(500,500);
    stroke(0);
    fill(0);
    p_font = createFont("Courier New",16,true);
    h1_font = createFont("Courier New",24,true);
    textFont(p_font);
}    
  
void draw()
{
   clear();
   background(255);
   translate(10,30);
   textFont(h1_font);
   text("Überschrift",0,0);
   translate(0,30);
   textFont(p_font);
   text("Dies ist ein Textblock",0,0);
   translate(0,20);
   text("über mehrere Zeilen.",0,0);
   translate(0,20);
}  

Code 0-1: Beispiel

Ergebnis.

Bild 0-1: Ergebnis.