// display the message, first as a single string, // and then one character at a time size(600,300); float pad = 20; String msg = "This is a test"; textSize(80); textAlign(LEFT, CENTER); fill(0); text(msg, pad, 100); float x=pad; for (int k=0; k < msg.length(); k++) { noFill(); rect(x,160,textWidth(msg.charAt(k)),80); fill(0); text(msg.charAt(k), x, 200); x += textWidth(msg.charAt(k)); }