Some
Details
Here are some technical details explaining what's going on
inside phat.C, phatic.C, phatset.C & typical user macros for the benefit
of those writing user scripts or even making additions and changes to phat.C.
-
There seems to be no alternative to requiring the use
of "standard" global names det, data, ev, v1, iev as defined in phat.C
in all user macros. These are used in "common" initialization spanning
user macros.
-
Integers rather than booleans are used because they
allow expansion to other uses. Strings may be used eventually for
even more flexibility.
-
gSystem->ProcessEvents(), introduced in ROOT 2.10, was extremely
valuable in allowing an interruptable delay loop for interactive parameter
setting without the much more complicated setup involved with the TTimer
class.
-
Obviously, the "user macros" must be findable so they must
be in phat.C's directory or on the search path set by .rootrc
-
It seemed easiest to "hard code" button locations in phatic.C
by reading coordinates off a gridpaper sketch of the desired GUI rather
than getting clever with indexed increments. These would be useful
of course for rows of many identical buttons.
-
The button functions call a separate macro, phatset.C.
This avoids the problem of very long command lines within the button definition,
a lesson learned from my earlier "toy model" event display demonstration.
The button functions can then occupy many lines, such as for the "GO" button.