eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'UIBuilder':

Home

Documentation
www.exept.de
Everywhere
for:
[back]

Class: UIBuilder


Inheritance:

   Object
   |
   +--WindowBuilder
      |
      +--UIBuilder

Package:
stx:libview2
Category:
Interface-Framework
Version:
rev: 1.68 date: 2017/03/18 15:43:31
user: stefan
file: UIBuilder.st directory: libview2
module: stx stc-classLibrary: libview2
Author:
Claus Gittinger

Description:


this class allows parsing windowSpecs as created by ST/X's
UIPainter and should be able to handle most of ST-80's specs.
(and thereby allow to run applications built with this tool).
However, it is not guaranteed that all of ST-80's winSpecs are understood.

It also provides some rudimentary support for building interfaces
programatically, by using #newComposite .. #add: .. #endComposite.
This has been added for ST80-compatibility - we do not recommend using
that for new ST/X programs.
Those were added to allow execution of some PD applications.
The programatic building protocol is not complete and certainly not bug free.

Notice: 
    some of this class was implemented using protocol information
    from alpha testers, literature and by reading public domain code
    - it may not be complete or compatible to
    the corresponding ST-80 class. 
    If you encounter any incompatibilities, please forward a note 
    describing the incompatibility verbal (i.e. no code) to the ST/X team.

[instance variables:]
    view                    <View>  
                                    temporary - holds the view being built
                                    when creating components using the 
                                    programmatic building interface.

    currentMenuSelector             not yet used

    spec                    <UISpec>        
                                    temporary - holds the spec being parsed
                                    when creating components using the 
                                    programmatic building interface.

    specStack               <Collection>
                                    temporary - holds the spec-stack when
                                    creating composites using newComposite/
                                    endComposite,
                                    while creating components using the 
                                    programmatic building interface.

    composite               <SpecCollection>
                                    temporary - holds the current composite
                                    when using newComposite/ endComposite,
                                    while creating components using the 
                                    programmatic building interface.

    lastComponent           <View>
                                    temporary - holds the last component
                                    being built,
                                    when creating components using the 
                                    programmatic building interface.

    compositeView           <View>
                                    temporary - holds the current composites
                                    view, when creating components using the 
                                    programmatic building interface.

    menuBar                         not yet used

    isEditing               <Boolean>
                                    flag which is set when an interface is built
                                    by the UIPainter (as opposed to being built
                                    for the application).
                                    Changes the way aspects are acquired,
                                    (actually, no models are created/set)
                                    to prevent false building when no
                                    real applicationModel is present.
                                    (as is the case when the painter builds
                                    components).


Class protocol:

initialization
o  initialize
debugging flag


Instance protocol:

Compatibility-VW
o  wrapper
ST/X has no wrappers - return the view here

accessing
o  isEditing
true if building from a GUI builder resource ( UIPainter, ... ),
false if building for the real thing.
If true, no models or actions should be set (no application is running)

o  isEditing: aBoolean
true if build from a GUI builder resource ( UIPainter, ... ); if true, no
models or actions should be set (no application is running)

o  isSubBuilder
return true, if this uiBuilder is for a subCanvas (i.e. a subApp)
as opposed to a topApp builder

o  isSubBuilder: aBoolean
set/clear the flag, which states that this uiBuilder is for a subCanvas (i.e. a subApp)
as opposed to a topApp builder. The default is false.

o  menuBar
return the value of the instance variable 'menuBar' (automatically generated)

o  menuBar: something
set the value of the instance variable 'menuBar' (automatically generated)

o  showDefaults
returns true if the builder is in editing mode and the building
components will build a default contents

o  showDefaults: aBool
true if the builder is in editing mode and the building
components will build a default contents

o  spec
return the current spec

o  spec: aSpec
set the current spec

o  view

o  view: something

o  view: viewArg spec: specArg
set instance variables (automatically generated)

building
o  buildFromSpec: aSpecOrSpecArray

o  buildFromSpec: aSpecArray in: aView
build a window hierarchy according to my spec into an existing view

o  buildViewForSpec: aSpecOrSpecArray in: aView
used when building a subSpec; moved from the UISPec class to here,
to allow different behavior in WebBuilder...

o  buildWindowFromSpec: aSpecOrSpecArray

o  doFinalHookup

o  newSubBuilder
builder applicationClass:applicationClass.

o  rebuildFromSpec: aSpecOrSpecArray
remove what I have and rebuild from a possibily different spec

building-programatically
o  add: aSpec
builder window displayBox

o  endComposite
pop

o  endCompositeLayout: layout

o  endCompositeLayout: layout properties: props

o  newComposite
push the composite being built ...

initialization
o  setupWindowFor: aView



ST/X 7.1.0.0; WebServer 1.663 at exept.de:8081; Fri, 22 Mar 2019 10:07:37 GMT