How to set the area of interest

Create a new openMap4u instance (with the default settings).
OpenMap4u oM4u = new OpenMap4u();
Optional override the default settings.

Create a rectangular drawing canvas with the given width (=4 cm) and height (=2 cm).
OverrideDrawOrWriteable myCanvas = oM4u.getCanvas(4.0, 4.0);
Set zero or more of the following (The order of the function call is irelevant): The draw a primitive
  myCanvas.draw(om4u.get(Text.class).text("Hello world!").center(2.0,2.0);
 
Write the result
myCanvas.write("myText.png");


But wait you can do it much faster and simpler with the fluent builder pattern
new OpenMap4u().canvas(4.0,4.0).center(1.0,1.5).scale(0.5).rotate(30).draw(
    om4u.get(Text.class).text("Hello world").center(0.5,0.25)
  ).write("myText.png");