Category : Recently Uploaded Files
Archive   : DOSUIT07.ZIP
Filename : EXAMPLE1.CPP

Output of file : EXAMPLE1.CPP contained in archive : DOSUIT07.ZIP

// The classic "Hello world" application

// The includes for the various toolkit components
#include "applic.hpp" /* The application */
#include "dialog.hpp" /* We will print in a dialog */
#include "cluster.hpp" /* To organise the dialog elements */
#include "button.hpp" /* The "Exit" button */
#include "text.hpp" /* To contain "Hello world" */
#include "event.hpp" /* To make the event queue */

// Every application that uses the toolkit must have one (and only one)
// statically declared EventQueue and Application.
EventQueue eventQueue;
Application example;

// Create a Dialog. Note that all VObjects must be created with new
Dialog *main = new Dialog(
// Lay out the contents in a vertical cluster
new VCluster(ObjectCollection(2)
// The contents - a Text to contain the vital message
+ new Text("Hello world")
// and a CloseButton to let the user exit
+ new CloseButton
// The title of the Dialog
// Place the dialog in the Application
// All set up, call the main event loop
return 0;