Online Eiffel Documentation
EiffelStudio

Hello World

hello

Compiling

To compile the example:

Running

After you launch the sample, You should see a window displayed as illustrated above. You will have full control over the window, and the program will quit when you close the window.

Under the Hood

MAIN_WINDOW inherits WEL_FRAME_WINDOW. In this example, we have redefined on_paint as shown below:

on_paint (paint_dc: WEL_PAINT_DC; invalid_rect: WEL_RECT) is      
		--Draw a centered text 
	is
	      paint_dc.draw_centered_text("Hello, World!", client_rect)   
	end 
	

Note: If you look at MAIN_WINDOW, you will see that it contains many features. However, nearly all of these are features are inherited from WEL_FRAME_WINDOW.

This sample contains the following classes:

See Also
Tutorial Step3
Common message hooks