OBSOLETE GUIKIT PACKAGE TUTORIAL
The functionality provided by GUIKit has been superseded by the interface construction and controls functions native to the built-in Wolfram Language.

GUIKit Example: Hello World

Code
In[3]:=
Click for copyable input
In[2]:=
Click for copyable input

Example

This example displays the classic simple "Hello World" application using the GUIKit framework.

In[4]:=
Click for copyable input
Optional Additional Forms Achieving the Same Result

The following are other variants on the basic theme of specifying the user interface definition.

Here you choose to pass arguments to the constructor of the label widget instead of setting the "text" property.

In[5]:=
Click for copyable input

Technically, even this version will work since frame and content panes will be automatically wrapped if not included.

In[6]:=
Click for copyable input

You could add extra layout options to center the text.

In[7]:=
Click for copyable input

The "Panel" and "Label" widget controls simply wrap the Java Swing controls, which you can also call directly through either the Swing or AWT versions.

In[8]:=
Click for copyable input
In[8]:=
Click for copyable input

Here we also try this using an XML definition equivalent.

In[9]:=
Click for copyable input
Translate this page: