So first: Sorry you completely right about Form.Font it doesn't complain. ups
so I changed it for your solution.
Yeah I have such a thing in head... Several instances of PApplet... I'm trying to work on Dialog meaning that the parent PApplet will wait for the other. It might be a solution.
Even though I don't use several instance of Form but one, I still usefull to have abstract class you can re-used in other project.
let see my draw in a class which inherits of form.
public void setup()
{
size(500,500);
startButton start = new startButton(10,10,120,30,"Start"); //start button inherits of my class Button
this.addComponent(start);
//Call after setting all components;
this.setupApplet();
}
public void draw()
{
this.update();
}
With this code, I'm able to manage whatever I want on my "Form" with my button with 3 function implements overidable.
onMouseOver, onMouseReleased, onMousePressed
onMouseReleased is executed only once of course
Thanks so much for advice