int w = 20; int h = 20; int w2 = 20; int h2 = 20; String input = "reaktype"; String input_upper = ""; void setup() { size(700,300); background(255); PFont font; font = loadFont("Avenir-Light-8.vlw"); textFont(font, 100); } void draw() { //background(100); // cells for (int i = 700; i >0; i = i - w) { for (int j = 700; j >0; j = j - h) { stroke(255); noFill(); rect(700-i,700-j,w,h); } } w = mouseX; h = mouseY; if(w < 15) { w = 100; } if(h < 10) { h = 20; } for (int i2 = 0; i2 < width; i2 = i2 + w2) { for (int j2 = 0; j2 < height; j2 = j2 + h2) { stroke(1); noFill(); rect(i2,j2,w2,h2); } } w2 = width-mouseX; h2 = height-mouseY; if(w2 < 5) { w2 = 5; } if(h2 < 5) { h2 = 5; } input_upper=input.toUpperCase(); fill(255); text(input_upper, 100, 180); textSize(100); h2 = width-mouseX ; w2 = height-mouseY; } void keyPressed(){ if (key == BACKSPACE){ println(input); input = ""; println(input_upper); input_upper = ""; }else{ input += (char) key; } }