summaryrefslogtreecommitdiffstats
path: root/hotnews
blob: 323a2ff81544605f868602211a31078ecd074519 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
See "Introduction" below.

The most recent version of the Gtk Demos scripts is an update of the
January 17 version.  The following changes have been made since January 17:


It's no longer necessary to install sbcl to run the scripts.  They're
invoked by a new script named demos.  A file named sanssbcl has to be
with the scripts.  See "Info about sanssbcl" below.

The demo scripts have minor changes whose purpose is for them to be
invoked differently than before.  See "Invoke the demo scripts" below.

Some of the object names in the demos have been changed to make them
unique, because all the demos now get loaded into one name space.

The menu was demo4, but is now named menu.  All the demos have been
combined into one Gtk application, which is established by the gapp in
menu.

Six de minimis demos have been added, so you can easily make your own
demos by editing de minimis demos.  The de minimis demos are demo4 through
demo9.  You should also edit the menu to give your demos appropriate
names.  The button name doesn't matter, and only has to be unique.
The label text is what will show as the button label.  Also change the
window title in your demo, to no longer indicate it's a de minimis demo.

The syntax of the Gtk function prototypes has been changed again, to make
them shorter and neater.  If you need more Gtk functions than are presently
in the list, simply add them to the list, using the same syntax.


The demos are here:   https://github.com/mifpasoti/Gtk-Demos


Invoke the demo scripts:

If the script named demos is not executable, do this:   chmod +x demos
To invoke the demo scripts, do this:                    ./demos


Info about sanssbcl:

If sbcl is not installed, and you don't want to install it, you can copy
or download sanssbcl.  Put it in the same directory with the demo scripts.

If sbcl is installed, you can make sanssbcl by running the makesans script.

The makesans script is short and easy to understand.  And sanssbcl is easy
to understand, by understanding makesans.


The January 17 version of the demos had the following changes from the
original version:

Added a menu of the other demos.  It was demo4 in the January 17 version,
but is now named menu.

The syntax for the list of Gtk function prototypes in demostuff was
changed, but has been changed again.

Loading the Gtk shared object file by name only, without specifying
the path, but using SBCL's built-in path logic, to be compatible
with more Linux distros.


Introduction

These demos demonstrate using Gtk directly from a higher level language.
None of the demos have any low level code in them.  There is no need for
any makefiles, C compilers, or any other low level stuff.  There is
probably no need to install Gtk, because it's probably already used by
your Linux.

You don't need to install sbcl if you have the sanssbcl file.  But, if you
want to install sbcl, you can usually install it via the Linux distro.  In
the rare circumstance that a particular Linux distro doesn't have sbcl, you
could install, via sbcl.org, either a binary version, or the sources to
compile.

To use a different high level language for these demos, it is of course
necessary to edit them to change the language.  But they aren't very long
and that might not take very long.  It's strongly advised to run the
present demos first, and make some minor changes to them, to see the
differences, to make sure to understand how they work, before starting to
change them to a different language.