eXept Software AG Logo

Smalltalk/X Webserver

Documentation of class 'SimpleView':

Home

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

Class: SimpleView


Inheritance:

   Object
   |
   +--GraphicsMedium
      |
      +--DisplaySurface
         |
         +--SimpleView
            |
            +--ClockView
            |
            +--DSVLabelView
            |
            +--DigitalClockView
            |
            +--FilenameWidgetWithHistory
            |
            +--FramedBox
            |
            +--InputView
            |
            +--InspectorView
            |
            +--PanelView
            |
            +--ScrollBar
            |
            +--ScrollableView
            |
            +--Separator
            |
            +--ShadowView
            |
            +--SyncedMultiColumnTextView
            |
            +--SystemStatusMonitor
            |
            +--TabSpecRuler
            |
            +--Tools::CodeView2
            |
            +--Tools::CodeView2::GutterView
            |
            +--VariablePanel
            |
            +--View
            |
            +--ViewScroller
            |
            +--ViewWithAcceptAndCancelBar
            |
            +--ViewWithAcceptAndCancelBar::AcceptAndCancelBar
            |
            +--VisualRegion
            |
            +--XEmbedContainerView
            |
            +--XEmbedContainerView::ClientView
            |
            +--XWorkstation::WindowGroupWindow

Package:
stx:libview
Category:
Views-Basic
Version:
rev: 1.905 date: 2018/05/16 06:35:01
user: stefan
file: SimpleView.st directory: libview
module: stx stc-classLibrary: libview
Author:
Claus Gittinger

Description:


this class implements functions common to all Views which do not work on / show a model.
Previously, all of this functionality used to be in the old View class, but has been
separated into this new SimpleView (which does not know about models) and the new View,
which does so.
I'd prefer to call this class View and the current View class a ModelView,
but for backward compatibility it is better to leave things the way they are
(there are simply too many subclasses of View around...).

Instances of SimpleView are seldom used directly, most views in the system inherit
from this class. However, sometimes a view is needed to create a dummy view for framing
or layout purposes.

[Instance variables:]

    superView               <View>                  my superview i.e. the view I am in

    subViews                <Collection>            the collection of subviews
                                                    These are the views proper.

    components              <Collection>            collection of gadgets (will be merged with subViews, soon)
                                                    These are lightweight gadgets (not seen by windows/x11).

    styleSheet              <ResourcePack>          contains widget attributes (see libview/styles/*.style)

    resources               <ResourcePack>          contains national language translations (see lib*/resources/*.rs)

    border                  <Border>                color and width of border

    unused                  <nil>                   to keep the instVar size constant

    viewShape               <Form>                  shape of view & border (if device supports it)

    top                     <Number>                actual top coordinate (pixels) in superview

    left                    <Number>                actual left coordinate (pixels) in superview

    flagBits                <Integer>               flag bits (used to be individual booleans)
        extendChanged                                   true if extend changed during setup
        originChanged                                   true if origin changed during setup

    relativeOrigin          <Number>                relative origin in percent within superview

    relativeExtent          <Number>                relative extent in percent within superview

    relativeCorner          <Number>                relative corner in percent within superview

    originRule              <Block>                 rule to compute origin if superview changes size

    extentRule              <Block>                 rule to compute extent if superview changes size

    cornerRule              <Block>                 rule to compute corner if superview changes size

    insets                  <Array>                 array with top, left, bottom & right insets (or nil)

    layout                  <LayoutObject>          not yet implemented - will replace the above layout
                                                    variables.

    shown                   <Boolean>               true if visible (false if iconified, unmapped or covered)

    unused_hiddenOnRealize  <Boolean>               don't show automatically when superview is realized.
                                                    now encoded in the flags.
                                                    (kept to keep the instVar size constant)

    name                    <String>                my name (future use for resources)

    level (**)              <Number>                3D level relative to superview

    margin                  <Number>                convenient margin; that is the number of pixels
                                                    which are taken up by border plus 3D level
                                                    (i.e. borderWidth + level abs)

    innerClipRect           <Rectangle>             convenient inner clip (minus margin)

    shadowColor (**)        <Color>                 color used to draw 3D shadowed edges

    lightColor (**)         <Color>                 color used to draw 3D lighted edges

    bitGravity              <nil | Symbol>          gravity of contents (if device supports it)

    viewGravity             <nil | Symbol>          gravity of view (if device supports it)

    controller              <nil | Controller>      the controller (if any)

    windowGroup             <WindowGroup>           the windowGroup

    preferredExtent(*)      <nil | Point>           preferredExtent overWrite
                                                    if nonNil, the widget will not compute
                                                    its pref-extent, but use that value.

    explicitExtent(*)       <nil | Point>           preferredExtent overWrite
                                                    if nonNil, the widget will not compute
                                                    its pref-extent, but use that value.

    dependents              <nil | Collection>      who depends on me

    layoutManager                                   currently unused; will be responsible for
                                                    child layout management

    visibilityChannel                               valueHolder to control the visiblity

    helpKey                                         for tooltips

    dropTarget                                      for drag&drop

(*) about to be changed to use preferredExtent as a cache and explicitExtent as
    an overwrite value.

(**) We have recently started to change the system to use borders instead of separate
     borderWidth, borderColor, level, shadow- and lightColors.
     Expect more changes here in the near future..

[Class variables:]

    Grey                    <Color>                 the color grey - its used so often

    ViewSpacing             <Number>                preferred spacing between views; 1mm

    CentPoint               <Point>                 100 @ 100 - its used so often

    StyleSheet              <ResourcePack>          contains all view-style specifics

    ReturnFocusWhenClosingModalBoxes                if true, a closing modalBox returns
                            <Boolean>               the keyboard focus to the view which was
                                                    active when the box was opened.
                                                    If false (the default), it is left to
                                                    window manager to assign a new focus.
                                                    If running on olwm/olvwm (which requires an
                                                    explicit click to reassign a focus), it is
                                                    better to turn this on in a private.rc file.

[styleSheet parameters:]

    popupShadow             <Boolean>               if true, popupViews show a shadow below

    popupLevel              <nil | Integer>         3D level

    borderWidth             <nil | Integer>         borderWidth (ignored in 3D styles)

    borderColor             <nil | Color>           borderColor (ignored in 3D styles)

    viewBackground          <nil | Color>           views background

    shadowColor             <nil | Color>           color for shadow edges (ignored in 2D styles)

    lightColor              <nil | Color>           color for light edges (ignored in 2D styles)

    font                    <nil | Font>            font to use


TODO:
    get rid of relativeOrigin, relativeCorner, originRule, extentRule,
    and insets; replace by a single object which defines the size
    (mhmh - ST-80 seems to call this LayoutFrame ?)
    -> be prepared for a change here in the near future and ONLY use
       access methods to get those instance variables' values

    get rid of 3D level & margin, move it to extra wrappers
    (although this will make view setup more complicated, it will remove
     complexity from the internals of view. Also, it will allow for more
     varieties of borders.)

    add components (could also call them gadgets or lightweight views)
    - views are expensive in terms of X resources. This would make all
    framing/edge and panel helper views become cheap ST objects, instead
    of views.


Related information:

    StandardSystemView
    DialogBox
    WindowGroup
    WindowEvent
    Layout
    [introduction to view programming]

Class protocol:

Signal constants
o  aboutToOpenBoxNotificationSignal
the following allows for knowledgable programmers to suppress dialog boxes,
(by proceeding with #abort) or to patch common controls right before opening...

o  boxClosedNotificationSignal
the following allows for knowledgable programmers to handle closed dialog boxes,
this is raised right after closing...

change & update
o  update: something with: aParameter from: changedObject
flush resources on language changes

defaults
o  defaultBackgroundColor
return the default background color for drawing - usually,
that is the same as the viewBackgroundColor.
usage example(s):
     View defaultBackgroundColor

o  defaultExtent
return the default extent of my instances.
The value returned here is usually ignored, and
the value from preferredExtent taken instead.

o  defaultFont
(comment from inherited method)
get the default font used for drawing

o  defaultFont: aFont
set the default font used for drawing

o  defaultStyle
return the default view style
usage example(s):
     View defaultStyle

o  defaultStyle: aStyle
set the view style for new views
usage example(s):
     View defaultStyle:#next. SystemBrowser start
     View defaultStyle:#motif. SystemBrowser start
     View defaultStyle:#iris. SystemBrowser start
     View defaultStyle:#st80. SystemBrowser start
     View defaultStyle:#normal. SystemBrowser start

o  defaultViewBackgroundColor
return the default view background
usage example(s):
     View defaultViewBackgroundColor

o  readStyleSheet
(re)load the styleSheet.

o  readStyleSheetAndUpdateAllStyleCaches
reload all style caches in all view classes.
Needed after a style change or when a style file has been changed

o  returnFocusWhenClosingModalBoxes
return the current focus-return behavior.
See #returnFocusWhenClosingModalBoxes: for a description.

o  returnFocusWhenClosingModalBoxes: aBoolean
control the keyboard-focus behavior when a modal dialog
is closed. The default (true) is to return the focus to the view
which was active when the dialog was opened.
If false, it is left up to the display to set the focus.
For owm / ovwm (which requires an explicit click for the focus),
it is better to return the focus automatically.
For managers which assign the focus according the pointer position,
it may be better to turn the focus-return off.
You should add a corresponding expression into your private.rc or
display.rc file.
usage example(s):
     Dialog returnFocusWhenClosingModalBoxes:false
     Dialog returnFocusWhenClosingModalBoxes:true

o  setDefaultStyle
set a default style as appropriate for the underlying system.
This is used if no setting is coming from a startup file or a preferences,
i.e. for standalone apps (with no .rc file)

o  styleSheet
return the view style sheet information (a dictionary)
usage example(s):
     View styleSheet

o  styleSheet: aViewStyle
set the view style from a style-sheet

o  updateAllStyleCaches
reload all style caches in all view classes.
Needed after a style change or when a style file has been changed
usage example(s):
     View updateAllStyleCaches

o  updateStyleCache
this method gets some heavily used style stuff and keeps
it in class-variables for faster access.
Subclasses should redefine this to load any cached style-values
into faster class variables as well. These should NOT do a
super updateStyleCache, since this method is called for all view-classes
anyway.

o  viewSpacing
return a convenient number of pixels used to separate views (usually 1mm).
Having this value here at a common place makes certain that all views
get a common look

initialization
o  initialize
to get language changes

o  postAutoload

instance creation
o  extent: extent
create a new view with given extent

o  extent: extent in: aView
create a new view as a subview of aView with given extent

o  extent: extent label: label
create a new view with given extent and label

o  in: aView
return a new view as a subview of aView.
If aView is nil, it is left unspecified, in which superview
the new view will be placed. The view can later be assigned
by adding it to the superview via #addSubView:.
If it's later realized and no superview has ever been set,
it will come up as a topview.

o  label: label
create a new view with given label

o  label: label in: aView
create a new view as subview of aView with given label

o  model: aModel
st-80 style view creation: create a new view and set its model.
Notice, that simpleViews do not understand #model:; however,
subclasses may.

o  on: aModel
create a new drawable on aModel
usage example(s):
although this one does not know about models,
     it can still send the model-assign message. This was done
     to catch obsolete calls to on:aDevice.

o  onSameDeviceAs: anotherView
create a view on the same device as anotherView.
Used with popUpMenus, which should be created on the device of
its masterView.

o  origin: origin corner: corner
create a new view with given origin and extent

o  origin: anOrigin corner: aCorner borderWidth: bw font: aFont label: aLabel in: aView

o  origin: origin corner: corner borderWidth: bw in: aView
create a new view as a subview of aView with given origin and extent

o  origin: origin corner: corner in: aView
create a new view as a subview of aView with given origin and extent

o  origin: origin extent: extent
create a new view with given origin and extent

o  origin: origin extent: extent borderWidth: bw
create a new view with given origin, extent and borderWidth

o  origin: anOrigin extent: anExtent borderWidth: bw font: aFont label: aLabel in: aView

o  origin: origin extent: extent borderWidth: bw in: aView
create a new view as a subview of aView with given origin, extent
and borderWidth

o  origin: origin extent: extent font: aFont label: label

o  origin: origin extent: extent font: aFont label: label in: aView

o  origin: origin extent: extent in: aView
create a new view as a subview of aView with given origin and extent

o  origin: origin extent: extent label: label
create a new view with given origin, extent and label

o  origin: anOrigin extent: anExtent label: aLabel icon: aForm minExtent: minExtent maxExtent: maxExtent
onDevice:Screen current.

o  origin: origin in: aView
create a new view as a subview of aView with given origin

misc ui support
o  iconInBrowserSymbol
( an extension from the stx:libtool package )
the browser will use this as index into the toolbariconlibrary

resources
o  classResources
if not already loaded, get the classes resourcePack and return it

o  classResources: aResourcePack
allow setting of the classResources

o  flushAllClassResources
flush all classes resource translations.
Needed after a resource file has changed.
usage example(s):
     View flushAllClassResources
usage example(s):
to change the language:
	Language := #en.
	Smalltalk changed:#Language.
	View flushAllClassResources
     or:
	Language := #de.
	Smalltalk changed:#Language.
	View flushAllClassResources

o  flushClassResources
flush classes resource string translations.
Needed whenever a resource file or language has changed

o  resources
return the view's resources -
that's a ResourcePack containing national language strings

o  updateClassResources
flush classes resource string translations and reload them.
Needed whenever a resource file or language has changed

startup
o  open
create, realize the view - this topview and all its subviews will
run as a separate process with its own windowGroup

o  openOnXScreenNamed: aScreenName
create an instance of the view and open it
on some X display screen. The argument aScreenName must be
a valid x-display name (i.e. of the form '<host>:<screenNr>' as in 'foo:0').
For more info, read the document on multiple display
support and the documentation of the DeviceWorkstation class.
usage example(s):
     FileBrowser openOnXScreenNamed:'bitsy:0'
     FileBrowser openOnXScreenNamed:':0'
     View openOnXScreenNamed:'bitsy:0'


Instance protocol:

Compatibility-ST80
o  checkForEvents
ST-80 compatibility:
check for any pending events and process them

o  closeAndUnschedule
actually sent to a controller in VW...
however, #open returns the view in ST/X, so we respond here

o  displayOn: aGCOrStream
ST-80 compatibility: (re-)display myself

o  displayPendingInvalidation
dummy - for ST-80 compatibility

o  invalidateRectangle: aRectangle repairNow: doRepairNow

o  isEnabled
return true, if this view is enabled (i.e. accepts user interaction).
Most views are enabled - only a few (buttons, SelectionInList etc.) can
be disabled.
#isEnabled is ST-80's equivalent of #enabled

o  isOpen
ST80 compatibility

o  lookPreferences: prefs
ignored - but required for some apps

o  newLayout: aLayoutObject
set the layout object which controls my geometry.
ST80-compatibility.

o  refresh

o  takeKeyboardFocus

Compatibility-Squeak
o  insetDisplayBox
Squeak mimicri: return my bounds

accessing
o  client: anApplicationModel
release existing components and generate new components from
the applications windowSpec.
ATTENTION: this is a low level interface; postBuild is NOT invoked

o  client: anApplication spec: aWindowSpecOrSelector
release existing components and generate new components from
the applications windowSpec.
ATTENTION: this is a low level interface; postBuild is NOT invoked

o  client: anApplication spec: aWindowSpecOrSpecSymbol builder: aBuilder
release existing components and generate new components from
the given windowSpec, using the given builder.

o  client: anApplication spec: aWindowSpecOrSpecSymbol builder: aBuilder withMenu: withMenuBoolean
release existing components and generate new components from
the given windowSpec, using the given builder.
ATTENTION: this is a low level interface.
TODO: this code is so ugly and badly designed - it must be redesigned
or at least well documented.

o  helpKey
The helpKey (symbol) or nil.
This can be set programatically, in views which are constructed
'by hand' - i.e. not via the UI painter.
When constructed from a UI-spec, this key is typically specified there (activeHelpKey)
(however, special apps may change it dynamically, if a component changes
its semantic meaning dynamically)

o  helpKey: aSymbolOrNil
The helpKey (symbol) or nil.
This can be set programatically, in views which are constructed
'by hand' - i.e. not via the UI painter.
When constructed from a UI-spec, this key is typically specified there
(however, special apps may change it dynamically, if a component changes
its semantic meaning dynamically)

o  helpText
Any optional, dynamically assigned helptext.
If it was never set (via helpText:), then the normal mechanism
(using a helpKey and asking the app for the corresponding text) is used.

o  helpText: aString
Any optional, dynamically assigned helptext.
If it is never set (via helpText:), then the normal mechanism
(using a helpKey and asking the app for the corresponding text) is used.
Warning:
Only use explicit helpTexts for very dynamic tooltips, which cannot be generated via
the regular (language-xlated) helpKey mechanism.

o  helpTextAt: srcPoint
fallback to avoid DNU for those which do a super (which they should not)

o  keyboardProcessor
return my keyboard processor.
If non-nil, that one gets a chance to intercept and deal with things like
escape or return in modal boxes.

accessing-behavior
o  disable
alternative method; redirected to basic mechanism

o  enable
alternative method; redirected to basic mechanism

o  enabled
views are enabled by default

o  enabled: bool
this is the basic machanism to enable/disable a view.
empty in this class; may be redefined by subclasses

o  isEnabled: aBoolean
ST-80 compatibility; set enabled state

o  preferFirstInputFieldWhenAssigningInitialFocus
define the focus behavior for dialogs.
If true is returned, input fields take precedence over other keyboard consumers.
This used to return true, but the behavior is somewhat ugly.

o  readOnly: aBoolean
ignored here; present for compatibility with some textView subclasses,
so that UIPainter can handle it in its TextView spec (which contains a
readOnly field)

accessing-bg & border
o  allSubViewsBackground: something
set the viewBackground to something, a color, image or form,
recursively in all of my subviews

o  allSubViewsBackground: something if: condition
set the viewBackground to something, a color, image or form,
recursively in all of my subviews

o  allSubViewsForeground: something
set the foreground to something, a color, image or form,
recursively in all of my subviews

o  allViewBackground: something
set the viewBackground to something, a color, image or form,
in myself and recursively in all of my subviews

o  allViewBackground: something if: condition
set the viewBackground to something, a color, image or form,
in myself and recursively in all of my subviews

o  allViewForeground: something
set the foreground to something, a color, image or form,
in myself and recursively in all of my subviews

o  backgroundColor
return the background color of the contents -
here, (since there is no contents), the viewBackground is returned.

o  backgroundColor: aColor
set the background color of the contents -
here, (since there is no contents), the viewBackground is changed.

o  border
return my border

o  border: aBorder
set my border

o  borderColor
return my borderColor
usage example(s):
^ borderColor

o  borderColor: aColor
set my borderColor

o  borderShape: aForm
set the borderShape to aForm

o  borderWidth
return my borderWidth

o  borderWidth: aNumberOrNil
set my borderWidth

o  computeMargin

o  fillFormWithBorderShape: aForm
fill aForm with my borderShape

o  foregroundColor
return the foreground color of the contents -
here, (since there is no contents), some default is returned.

o  foregroundColor: aColor
set the foreground color of the contents -
ignored here, since there is no contents.

o  foregroundColor: fgColor backgroundColor: bgColor
set both the foreground and background colors of the contents

o  level
return my level relative to superView (3D)

o  level: aNumber
set my level relative to superView (3D)

o  lightColor
return the color to be used for lighted edges (3D only)

o  lightColor: aColorOrImage
set the color to be used for lighted edges (3D only)

o  margin
return my inner margin - this is usually the level,
but can be more for some views
(textViews which add more margin between the border and the text)

o  setBorderWidth
set my borderWidth in the devices physical view

o  setBorderWidth: aNumber
set my borderWidth without affecting the real view (private only)

o  shadowColor
return the color to be used for shadowed edges (3D only)

o  shadowColor: aColorOrImage
set the color to be used for shadowed edges (3D only)

o  viewBackground: aColorOrFormOrViewBackground
set the viewBackground to something, a color, image or form.
If it's a color and we run on a color display, also set shadow and light
colors - this means, that a red view will get light-red and dark-red
edges.

o  viewBackground: something if: condition
set the viewBackground to something, a color, image or form,
in myself and recursively in all of my subviews

o  viewShape: aForm
set the viewShape to aForm

accessing-channels
o  setupChannel: newChannel for: changeSelector withOld: oldChannel
common code to change a channel.
If changeSelector is non-nil, arrange for it to be sent when
the channel changes its value; otherwise, arrange for a simple update.
This is so common, that it's worth a helper method:
release any old channel (if non-nil),
arrange for changeSelector (or #update) to be sent for the new channel.

accessing-contents
o  heightOfContents
return the height of the contents in logical units
- defaults to view's visible area here.
This method MUST be redefined in all view classess which are
going to be scrolled AND show data which has different size than
the view. For example, a view showing A4-size documents should return
the number of vertical pixels such a document has on this device.
A view showing a bitmap of height 1000 should return 1000.
If not redefined, scrollbars have no way of knowing the actual size
of the contents being shown. This is called by scrollBars to compute
the relative height of the document vs. the views actual size.
The value returned here must be based on a scale of 1, since users
of this will scale as appropriate.

o  heightOfContentsDependsOnWidth
a very special which is only used by the scrollableView,
to check if it should NOT automatically hide scrollbars, when the
pointer leaves the view.
Currently, there are only a small number of views which return true here,
one being the HTML view, which rearranges its text depending on the width,
and therefore, it is a bad idea to hide/show scrollbars dynamically

o  widthOfContents
return the width of the contents in logical units
- defaults to views visible area here.
This method MUST be redefined in all view classess which are
going to be scrolled AND show data which has different size than
the view. For example, a view showing A4-size documents should return
the number of horizontal pixels such a document has on this device.
A view showing a bitmap of width 500 should return 500.
If not redefined, scrollbars have no way of knowing the actual size
of the contents being shown. This is called by scrollBars to compute
the relative width of the document vs. the view's actual width.
The value returned here must be based on a scale of 1, since users
of this will scale as appropriate.

o  widthOfContentsDependsOnHeight
a very special query which is only used by the scrollableView,
to check if it should NOT automatically hide scrollbars, when the
pointer leaves the view.
Currently, there is no view, which returns true
(maybe if we ever support chinese writing top to bottom...

accessing-dimensions
o  allInset: aNumber
set all insets; positive makes the view smaller,
negative makes it larger..
Obsolete: please use a layout object.

o  bottom
return the y position of the actual bottom edge (in pixels)

o  bottom: aNumber
set the corners y position

o  bottomInset
return the inset of the bottom edge; positive is to the top,
negative to the bottom.
Obsolete: please use a layout object.

o  bottomInset: aNumber
set the inset of the bottom edge;
positive is to the top (view becomes smaller),
negative to the bottom (becomes larger).
Obsolete: please use a layout object.

o  bounds
ST-80 compatibility: return my bounds

o  bounds: aRectangle
ST-80 compatibility: change my bounds

o  center
return the point at the center of the receiver (in pixels)

o  center: newCenter
move the receiver so that newCenter, aPoint becomes the center point

o  computeCorner
compute my corner; if I have a layoutObject,
relative origins or blocks to evaluate, compute it now ..
Blocks may return relative values or nil; nil means: take current value.
Returns the corner point in device coordinates (pixels).

o  computeExtent
compute my extent; if I have a layoutObject, a relative extent
or blocks to evaluate, compute it now ..
There is one catch here, if the dimension was defined
by origin/corner, compute them here and take that value.
I.e. origin/corner definition has precedence over extent definition.
Returns the extent in device coordinates (pixels).

o  computeOrigin
compute my origin; if I have a layoutObject, a relative origin
or blocks to evaluate, compute it now ..
Blocks may return relative values or nil; nil means: take current value.
Returns the origin point in device coordinates (pixels).

o  corner
return the lower right corner-point (in pixels)

o  corner: corner
set the view's corner;
the corner argument may be:
a point
where integer fields mean 'pixel-values'
and float values mean 'relative-to-superview'
and nil means 'take current value';
or a block returning a point which is interpreted as above.
Please migrate to use layoutObjects, if possible.

o  cornerRule
return the corner block - non public; this will vanish without notice

o  extent: extent
set the view's extent;
extent may be:
a point
where integer fields mean 'pixel-values'
and float values mean 'relative-to-superview'
and nil means 'leave current value';
or a block returning a point which is interpreted as above.
Be careful when using relative extents: rounding errors may
accumulate. Better use origin/corner.
Best: migrate to use layour objects.

Notice: this sets the views explicitExtent flag, which prevents it normally
from resizing itself to its preferredExtent.
See initialExtent: for a variation.

o  extentRule
return the extent block - non public; this will vanish without notice

o  frame
compatibility with displayObjects: returns my bounds

o  geometryLayout
this method will vanish, as soon as all implementations of
#layout: are removed ...
(conflict for example in label>>layout:).
DO NOT USE #geometryLayout: in your code; it will be removed without
notice.

o  geometryLayout: aLayoutObject
this method will vanish, as soon as all implementations of
#layout: are removed ...
(conflict for example in label>>layout:).
DO NOT USE #geometryLayout: in your code; it will be removed without
notice.

o  hasExplicitExtent
^ explicitExtent.

o  height: aNumber
set the view's height in pixels

o  heightIncludingBorder
return my height including border
(this is my height as seen from the outside view;
while #height returns the height as seen by myself)

o  horizontalInset: aNumber
set the insets of the left/right edge;
positive makes it smaller, negative makes it larger.
Obsolete: please use a layout object.

o  initialExtent: extent
set the view's extent, but don't change its explicitExtent setting.
a variant of #extent.

o  initialHeight: aNumber
set the view's height in pixels, but don't change its explicitExtent setting

o  initialWidth: aNumber
set the view's width in pixels, but don't change its explicitExtent setting

o  innerHeight
return the height of the view minus any 3D-shadow-borders

o  innerHeight: pixels
set the height of the view plus any 3D-shadow-borders.
This does not work with a relative size.

o  innerHorizontalMargin
return any additional inner margin (i.e. contents margin).
This should be redefined by views which do add margins
(for example: textViews do this)

o  innerVerticalMargin
return any additional inner margin (i.e. contents margin).
This should be redefined by views which do add margins
(for example: textViews do this)

o  innerWidth
return the width of the view minus any 3D-shadow-borders

o  innerWidth: pixels
set the width of the view plus any 3D-shadow-borders.
This does not work with a relative size.

o  inset: aNumber
set all insets; positive makes the view smaller,
negative makes it larger..
Obsolete: please use a layout object.

o  layout
return the layout object which controls my geometry.
Currently, this is nil in most cases, and my geometry is
defined by relativeOrigin/relativeCorner/relativeExtent,
originRule/extentRule/cornerRule and inset.
Applications should be changed to use layoutObjects,
since the above listed instance variables will vanish.

o  layout: aLayoutObject
set the layout object which controls my geometry.

o  layoutChanged

o  left
return the x position of the left border (in pixels)

o  left: aNumber
set the x position

o  left: newLeft top: newTop width: newWidth height: newHeight
another way of specifying origin and extent

o  leftInset
return the inset of the left edge; positive is to the right,
negative to the left.
Obsolete: please use a layout object.

o  leftInset: aNumber
set the inset of the left edge;
positive is to the right (view becomes smaller),
negative to the left (becomes larger).
Obsolete: please use a layout object.

o  makeFullyVisible
make sure that the view is fully visible by shifting it
into the visible screen area if necessary.

o  makeRoundViewShapeWithBorder: bw
setup my window for a round shaped view;
this is not supported by all devices

o  makeRoundViewShapeWithBorder: bw opaque: opaque
setup my window for a round shaped view;
this is not supported by all devices

o  makeTransparentRectangularViewShapeWithBorder: bw
setup my window for a rectangluar transparent shaped view;
this is not supported by all devices

o  maxExtent

o  maxExtent: aPoint

o  minExtent

o  minExtent: aPoint

o  origin
return the origin (in pixels)

o  origin: origin
set the view's origin;
origin may be:
a point
where integer fields mean 'pixel-values'
and float values mean 'relative-to-superview'
and nil means 'take current value';
or a block returning a point which is interpreted as above.
Please migrate to use layout objects.

o  origin: origin corner: corner
set both origin and extent

o  origin: origin extent: extent
set both origin and extent

o  originRelativeTo: aView
return the origin (in pixels) relative to a superView,
or relative to the rootView (if the aView argument is nil).
If the receiver is nonNil and not a subview of aView, return nil.

o  originRule
return the origin block - non public; this will vanish without notice

o  preferredExtent: anExtentPoint
override the view's own preferredExtent computation,
and let it prefer the size given by the argument.

o  relativeCorner
return the relative corner or nil

o  relativeCorner: aPoint
set the relative corner

o  relativeExtent
return the relative extent or nil.
Obsolete: please use a layout object.

o  relativeExtent: aPoint
set the relative extent.
Obsolete: please use a layout object.

o  relativeOrigin
return the relative corner or nil

o  relativeOrigin: aPoint
set the relative origin

o  right
return the x position of the right edge (in pixels)

o  right: aNumber
set the corners x position

o  rightInset
return the inset of the right edge; positive is to the left,
negative to the right.
Obsolete: please use a layout object.

o  rightInset: aNumber
set the inset of the right edge;
positive is to the left (view becomes smaller),
negative to the right (becomes larger).
Obsolete: please use a layout object.

o  screenBounds
return my bounds on the screen

o  setHeight: aNumber
set the view's height in pixels

o  setOrigin: aPoint
set the origin only

o  setWidth: aNumber
set the view's width in pixels

o  sizeFixed: aBoolean
set/clear the fix-size attribute, if supported by concrete subclasses.
Views which want to resize themselfes as appropriate to their contents
should cease to do so and take their current size if sizeFixed is set to
true. Currently, only supported by Labels.
This does NOT prevent the window manager from resizing the view,
instead it tell the view to NOT resize ITSELF.
Added here to provide a common protocol for all views.

o  superViewRectangle
return the inside area of the superView.

o  top
return the y position of the top border

o  top: aNumber
set the y position

o  topInset
return the inset of the top edge; positive is to the bottom,
negative to the top.
Obsolete: please use a layout object.

o  topInset: aNumber
set the inset of the top edge;
positive is to the bottom (view becomes smaller),
negative to the top (becomes larger).
Obsolete: please use a layout object.

o  verticalInset: aNumber
set the insets of the top/bottom edge;
positive makes it smaller, negative makes it larger.
Obsolete: please use a layout object.

o  viewRectangle
return the inside area.
This is used by relative sized subviews and layout-computations
to base relative coordinates on.
For most views, the value returned here (actual extent minus any
margins required for 3D levels) is ok.
However, views which want some extra area around (for example: FramedBox)
may redefine this method to return a rectangle without this area
(thus, a relative sized subviews coordinates will be based on this net area)

o  width: aNumber
set the view's width in pixels

o  widthIncludingBorder
return my width including border
(this is my width as seen from the outside view;
while #width returns the width as seen by myself)

accessing-display attributes
o  beMDIChildView

o  beNativeWidget

o  beNonNativeWidget

o  isMDIChildView

o  isMarkedAsUnmappedModalBox

o  isNativeWidget

o  markAsUnmappedModalBox

o  unmarkAsUnmappedModalBox

accessing-hierarchy
o  components
return the collection of non-view components

o  container
return my container

o  container: aContainer
set my container (i.e. superView) to be aContainer

o  hierarchicalIndex

o  hierarchicalIndexInList: aViewCollection
no conflict

o  hierarchicalIndexOfChild: aView

o  hierarchicalUUID

o  lower
bring to back
usage example(s):
     Transcript topView lower

o  raise
bring to front
usage example(s):
     Transcript topView raise

o  scrolledView
for compatibility with scrolledView, return myself.
So you can ignore the scrollability of a component when accessing it,
without a need to ask for being a scrollwrapper first.
Eg, you can send someView scrolledView to get the underlying view,
without a danger of a DNU, if the component is not scrolled.

o  setContainer: aContainer
set my container (i.e. superView) to be aContainer

o  subViews
return the collection of subviews

o  subViews: aListOfViews
set the collection of subviews

** This is an obsolete interface - do not use it (it may vanish in future versions) **

o  superView
return my superView

o  superView: aView
set my superView to be aView

** This is an obsolete interface - do not use it (it may vanish in future versions) **

o  topComponent
return the topmost component - that's the one with no superview.
For ST-80 compatibility.

o  topView
return the topView - that's the one with no superview

o  uuidStringOrName

o  view
return my view - for real views, that's the receiver.
For wrappers, its the real view that contains it

accessing-menus
o  menuHolder
who has the menu ?
By default, I have it.

o  menuMessage
Return the symbol sent to myself to acquire the menu

o  menuPerformer
who should perform the menu actions ?
By default, I do it.

o  yellowButtonMenu
actually, this should be called 'middleButtonMenu'.
But for ST-80 compatibility ....
This method will vanish, once all views have controllers
associated with them; for now, duplicate some code also found in
controller.

accessing-misc
o  bitGravity
return the bitGravity - that's the direction where the contents will move
when the view is resized.

o  bitGravity: gravity
set the bitGravity - that's the direction where the contents will move
when the view is resized.

o  clippingBounds: aRectangleOrNil
set the clipping rectangle for drawing (in logical coordinates);
a nil argument turns off clipping (i.e. whole view is drawable).
Redefined to care for any margin.

o  fullName
return my full name to be used for resource-access

o  name
return my name component to be used for resource-access

o  name: aString
set my name component to be used for resource-access

o  processName
return a string to be shown in the process monitor

o  reverseOrderIfOKAtLeft: aBoolean
for compatibility with PanelView - so this message can be sent to any view

o  styleSheet
return the styleSheet. This is set at early view-creation time,
from the defaultStyleSheet which is valid at that time.
It is not affected by later defaultStyle changes

o  styleSheet: aStyleSheet
change the styleSheet. Knowledgable users only, please.

o  viewGravity
return the viewGravity - that's the direction where the view will move
when the superView is resized.

o  viewGravity: gravity
set the viewGravity - that's the direction where the view will move
when the superView is resized.

accessing-mvc
o  application
return the application, under which this view was opened,
or nil, if there is no application

o  aspect: aspectSymbol
ST-80 style updating: If a view's aspectSymbol is nonNil,
it will respond to changes of this aspect from the model.
Alias for aspectMessage: for ST-80 compatibility.

o  controller
return the controller. For views which implement the controller
functionality themself, return the receiver itself

o  controller: aController
set the controller - that's the one handling user events

o  model
return nil - simpleViews have no model (only providing geometric)

o  sensor
return the view's sensor

o  setController: aController
set the controller but do not affect the model/view releationship

o  setWindowGroup: aGroup
set the window group.

o  windowGroup
return the window group. For old style views, return nil

o  windowGroup: newGroup
set the window group of myself and recursively of any children.
If I am currently in a group, remove me from it it.

accessing-transformation
o  maxComponentBottom
return the maximum of all components bottoms

o  maxComponentRight
return the maximum of all components rights

o  maxSubViewBottom
subViews isNil ifTrue:[^ 0].

o  maxSubViewRight
subViews isNil ifTrue:[^ 0].

o  scale: aPoint
set the scale factor of the transformation

o  setViewOrigin: aPoint
set the viewOrigin - i.e. virtually scroll without redrawing

o  viewOrigin
return the viewOrigin; that's the coordinate of the contents
which is shown topLeft in the view
(i.e. the origin of the visible part of the contents).

o  visibleArea
return the rectangle that contains the visible part
of the view in user coordinates.

o  xOriginOfContents
return the x coordinate of the viewOrigin in pixels;
used by scrollBars to compute thumb position within the document.

o  yOriginOfContents
return the y coordinate of the viewOrigin in pixels;
used by scrollBars to compute thumb position within the document.

accessing-visibility
o  beInvisible
make the view invisible; if my container is visible,
change visibility immediately;
otherwise, arrange for the receiver to be not realized,
when the container is made visible.

o  beVisible
make the view visible; if my container is already visible,
change visibility immediately; otherwise, arrange for the receiver
to be made visible when the container is made visible.
Notice, that the command may not be sent immediately to the display,
and that ST/X considers the view to be still invisible until a
visibility event arrives from the display.
Thus, the view may remain logically invisible
for a while. (see #beVisibleNow for more on this)

o  beVisibleNow
make the view visible immediately.
In contrast to #beVisible, this waits until the view is really
visible.

o  hidden
return true, if the view does not want to be realized
automatically when superview is realized

** This is an obsolete interface - do not use it (it may vanish in future versions) **

o  hidden: aBoolean
if the argument is true, the receiver view will not
be realized automatically when superview is realized

** This is an obsolete interface - do not use it (it may vanish in future versions) **

o  hiddenOnRealize: aBoolean
if the argument is true, the receiver view will not
be mapped (i.e. shown) automatically when the superview is realized.
The hiddenOnRealize flag is useful to create views which are
to be made visible conditionally or later.
Notice: if there is a visibilityChanne, this static flag is ignored.
For ST-80 compatibility, please use #beVisible / #beInvisible.

o  isBeingDestroyed
a flag which is set, when the view is being destroyed.
Can be checked to avoid some resizing and other layout reorganizations
(especially in panels), which otherwise occur while subviews are removed.

o  isBeingDestroyed: aBoolean
a flag which is set, when the view is being destroyed.
Can be checked to avoid some resizing and other layout reorganizations
(especially in panels), which otherwise occur while subviews are removed.

o  isHiddenOnRealize
return true, if the receiver will NOT be mapped when realized.
False otherwise.
The hiddenOnRealize flag is useful to create views which are
to be made visible conditionally or later.
Notice: if there is a visibilityChanne, the static flag is ignored.

o  isReallyShown
return true, if the view is visible AND all of its containers are

o  isVisible
return true, if the view is visible

o  isVisible: aBoolean
make the view visible or invisible

o  setVisibilityChannel: aValueHolder
set the valueHolder, which holds the visible boolean value

o  shown
return true if the view is shown; false if not.
Shown means: the view is mapped and is not completely covered.

o  visibilityChannel
return a valueHolder for visible/invisible

o  visibilityChannel: aValueHolder
set the valueHolder, which holds the visible boolean value

adding & removing components
o  add: aComponent
add a component (either a view or gadget) to the collection of
subComponents.

o  add: aComponent at: anOrigin
for ST-80 compatibility.
add a component at some origin

o  add: aComponentOrCollection in: aRectangleOrLayoutFrame
for ST-80 compatibility.
add a component in some frame; the argument may be either a rectangle
with relative coordinates, or an instance of LayoutFrame, specifying
both relative coordinates and the insets.

o  addComponent: aComponent
components (i.e. gadgets or lightweight views) are being prepared.
Don't use this right now for non-views

o  addSubView: newView
add a view to the collection of subviews

o  addSubView: newView after: aViewOrNil
add a view to the collection of subviews after another view.
If the argument aViewOrNil is nil, the newView is added at the end.
This makes sense, in Panels and other layout views, to enter a new
element at some defined place.

o  addSubView: newView before: aViewOrNil
add a view to the collection of subviews before another view.
If the argument aViewOrNil is nil, the newView is added at the end.
This makes sense, in Panels and other layout views, to enter a new
element at some defined place.

o  addSubView: aView in: bounds borderWidth: bw
for ST-80 V2.x compatibility

o  addSubViewFirst: newView
add a view to the front of the collection of subviews

o  component: aComponent
components (i.e. gadgets or lightweight views) are being prepared.
Don't use this right now for non-views

o  destroySubViews
remove all subviews

o  removeComponent: aComponent
components (i.e. gadgets or lightweight views) are being prepared.
Don't use this right now for non-views

o  removeSubView: aView
remove a view from the collection of subviews

o  setContainerIn: aView
common code for addSubView* methods

change & update
o  changedPreferredBounds: someArgument
tell any dependents, that I have changed my preferred bounds;
Interface is provided mostly provided for ST80 compatibility;
here, translate into ST/X's mechanism for telling others about this.

o  languageChanged

o  update: aspect with: aParameter from: changedObject
an update request

cursor animation
o  showBusyWhile: aBlock
evaluate some time consuming block, while doing this,
show a spinning wheel cursor. If those bitmaps are not found,
fallback to the standard busy cursor.
Experimental.
usage example(s):
     View new realize showBusyWhile:[ Delay waitForSeconds:5 ]
     Transcript showBusyWhile:[ Delay waitForSeconds:5 ]

dependents access
o  addDependent: anObject
make the argument, anObject be a dependent of the receiver

o  breakDependents
remove all dependencies from the receiver

o  dependents
return a Collection of dependents.
Views keep them in an instance variable to avoid overhead.

o  dependents: aCollectionOrNil
set the collection of dependents.
Views keep them in an instance variable to avoid overhead.

o  dependentsDo: aBlock
evaluate aBlock for all of my dependents.
Views keep them in an instance variable to avoid overhead.

o  removeDependent: anObject
make the argument, anObject be independent of the receiver

dependents access (non weak)
o  addNonWeakDependent: anObject
make the argument, anObject be a dependent of the receiver.
Since all dependencies are nonWeak in Model, this is simply
forwarded to addDependent:

o  interests
return a Collection of interests - empty if there is none.
Here, we use the normal dependents collection for interests.

o  nonWeakDependents
return a Collection of dependents - empty if there is none.
Since all dependencies are nonWeak in Model, this is a dummy.

o  removeNonWeakDependent: anObject
make the argument, anObject be independent of the receiver.
Since all dependencies are nonWeak in Model, this is simply
forwarded to removeDependent:

drag & drop
o  canDrop: aDropContext
return true, if we can drop using a dropContexts information (the new drop interface).
This method should be redefined in views which can take objects

o  canDrop: aDropContext at: positionInView
return true, if we can drop using a dropContexts information (the new drop interface).
This method should be redefined in views which can take objects

o  canDropObjects: aCollectionOfDropObjects
return true, if we can drop aCollectionOfDropObjects (the OLD drop interface).
This method should be redefined in views which can take objects

o  canDropObjects: aCollectionOfDropObjects at: positionInView
return true, if we can drop aCollectionOfDropObjects (the OLD drop interface).
This method should be redefined in views which can take objects

o  dragAutoScroll: aContext
called by the DragAndDropManager to scroll during a drag/drop operation
if necassery (decided by the widget itself);
If a scroll is done, return true otherwise false (used to restore the background).
By default false is returned.

o  drop: aDropContext
drop manager wants to drop using info in aDropContext (the new drop interface).
An error here, because this is only sent, if #canDrop: returned true;
if you redefined #canDrop: in a subclass, #drop: must also be redefined.

** This method raises an error - it must be redefined in concrete classes **

o  drop: aDropContext at: aPoint
drop manager wants to drop using info in aDropContext (the new drop interface).
If I have an application, forward the request.
Otherwise, ignore it. This is only sent, if #canDrop: returned true;
if you redefined #canDrop: in a subclass, #drop:at: must also be redefined.

o  dropObjects: aCollectionOfDropObjects
someone wants to drop aCollectionOfDropObjects (the OLD drop interface).
An error here, because this is only sent, if #canDrop: returned true;
if you redefined #canDropObjects: in a subclass, #dropObjects: must also be redefined.

** This method raises an error - it must be redefined in concrete classes **

o  dropObjects: aCollectionOfDropObjects at: aPoint
someone wants to drop aCollectionOfDropObjects (the OLD drop interface).
An error here, because this is only sent, if #canDrop: returned true;
if you redefined #canDropObjects: in a subclass, #dropObjects: must also be redefined.

o  dropTarget
returns the dropTarget or nil

o  dropTarget: aDropTragetOrNil
set the dropTarget

edge drawing
o  drawBottomEdge
draw bottom 3D edge into window frame

o  drawBottomEdgeLevel: level shadow: shadowColor light: lightColor halfShadow: halfShadowColor halfLight: halfLightColor style: edgeStyle

o  drawEdges
draw all of my 3D edges

o  drawEdgesForX: x y: y width: w height: h level: l
draw 3D edges into a rectangle

o  drawLeftEdge
draw left 3D edge into window frame

o  drawLeftEdgeLevel: level shadow: shadowColor light: lightColor halfShadow: halfShadowColor halfLight: halfLightColor style: edgeStyle

o  drawRightEdge
draw right 3D edge into window frame

o  drawRightEdgeLevel: level shadow: shadowColor light: lightColor halfShadow: halfShadowColor halfLight: halfLightColor style: edgeStyle

o  drawTopEdge
draw top 3D edge into window frame

o  drawTopEdgeLevel: level atY: y shadow: shadowColor light: lightColor halfShadow: halfShadowColor halfLight: halfLightColor style: edgeStyle

o  drawTopEdgeLevel: level shadow: shadowColor light: lightColor halfShadow: halfShadowColor halfLight: halfLightColor style: edgeStyle

o  drawTopEdgeLevel: level y: y shadow: shadowColor light: lightColor halfShadow: halfShadowColor halfLight: halfLightColor style: edgeStyle

o  redrawEdges
redraw my edges (if any)

enumerating view hierarchy
o  allSubViewsDetect: aBlock ifNone: exceptionValue
find a subview for which aBlock returns true (recursively).
If there is none, return the value from exceptionValue

o  allSubViewsDo: aBlock
evaluate aBlock for all subviews (recursively)

o  allSuperViewsDetect: aBlock ifNone: exceptionValue
find a container for which aBlock returns true (recursively).
If there is none, return the value from exceptionValue

o  allSuperViewsDo: aBlock
evaluate aBlock for all superviews (recursively)

o  allVisibleSubViewsDetect: aBlock ifNone: exceptionBlock
find a visible subview for which aBlock returns true (recursively)

o  changeSequenceOrderFor: aSubViewOrComponent to: anIndex
change a subview's position in the subviews collection.
Usually, this only affects the order of components in a panelView,
unless they overlap. In that case, the later view is placed above the earlier.

o  changeSequenceOrderForComponent: aComponent to: anIndex
change a components's position in the components collection.
The later components is drawn above the earlier.

o  changeSequenceOrderForView: aSubView to: anIndex
change a subview's position in the subviews collection.
Usually, this only affects the order of components in a panelView,
unless they overlap. In that case, the later view is placed above the earlier.

o  withAllSubViewsDo: aBlock
evaluate aBlock for the receiver and all subviews (recursively)

event handling
o  alienDrop: aCollectionOfDropObjects position: positionOrNil
a drop from some other non-ST/X application.

o  buttonMotion: state x: x y: y
button was moved

o  buttonMultiPress: button x: x y: y
button was pressed quickly again - check my components for a hit.

o  buttonPress: button x: x y: y
button was pressed - check my components for a hit.

o  buttonRelease: button x: x y: y
button was released - check my components for a hit.

o  changeScaleForMouseWheelZoom: amount
CTRL-wheel action.
ignored here - redefined in views which can zoom

o  clientMessage: msgType format: msgFormat eventData: msgData
a client message - very X-specific and only useful for special applications.
Forwarded to my application (if I have one)

o  closeRequest
programmatic close request

o  configureX: x y: y width: newWidth height: newHeight
my size has changed by window manager action

o  containerChangedSize
my container has changed size; if I have relative
origin/extent or blocks to evaluate, do it now ..

o  containerMapped
my container was mapped (became visible).
If I was previously realized, this implies that I myself
am now mapped as well.
usage example(s):
v containerMapped

o  containerUnmapped
my container was unmapped
- this implies that the receiver is now also unmapped.

o  copyDataEvent: parameter eventData: msgData
a copyData message - very Win32-specific and only useful for special applications.
Forwarded to my application (If I have one)

o  createWindowX: x y: y width: w height: h
A window has been created in myself, nothing to do here.
Note, that SubstructureNotify events must be enabled to get
this event. To enable, do:

self enableEvent: #substructureNotify


o  destroyed
view has been destroyed by someone else (usually window system)

o  dropMessage: dropTypeSymbol data: dropValue position: dropPosition handle: dropHandle
a drop from some other window (X: DND or Win32 drag&drop).
Convert to the ST/X drag and drop protocol here.

o  exposeX: x y: y width: w height: h
a low level redraw event from device
- let subclass handle the redraw and take care of edges here

o  focusIn
got keyboard focus (via the window manager).
Nothing done here

o  focusOut
lost keyboard focus (via the window manager).
Nothing done here

o  hasKeyboardFocus: aBoolean
notification from the windowGroup that I got the keyboardFocus.

o  keyPress: key x: x y: y
a key has been pressed. If there are components,
pass it to the corresponding one.
Otherwise, forward it to the superview, if there is any.

o  keyRelease: key x: x y: y
a key has been released. If there are components,
pass it to the corresponding one.
Otherwise, do whatever my superclass would do.

o  keyboardZoom: largerBoolean
CTRL+/- action.
ignored here - redefined in views which can zoom

o  keyboardZoomInAllViews: largerBoolean
CTRL+/- zoom action global.
Sent to all windows; some may ignore it.

o  mapped
the view has been mapped (by some outside
action - i.e. window manager de-iconified me)
usage example(s):
     the old code was:

	realized := true.
	shown := true.
	...

     this created a race condition, if the view was
     realized and shortly after unrealized - before the mapped event
     arrived. This lead to realized being set to true even thought the
     view was not.
     Boy - that was a bad one (hard to reproduce and hard to find).
usage example(s):
Also, when remapped, X11 only sends a mapped event for the topView.

o  mouseWheelMotion: buttonState x: x y: y amount: amount deltaTime: dTime
the mouseWheel was turned - handle as a scroll operation.
Specialized application windows may redefine this for any other operation.
Here, we scroll some amount which depends upon the view's contents (but never too much);

If ctrl is pressed, always scroll one page;
this can be changed to zoom in/out with ctrl (as in OSX)
by:
UserPreferences current allowMouseWheelZoom:false
UserPreferences current allowMouseWheelZoom:true

If shift is pressed, always scroll a single scroll-step;
this can be changed to scroll horizontally with shift (as in OSX)
by:
UserPreferences current shiftMouseWheelScrollsHorizontally:false
UserPreferences current shiftMouseWheelScrollsHorizontally:true

o  mouseWheelZoom: amount
CTRL-wheel action.
ignored here - redefined in views which can zoom

o  pointerEnter: state x: x y: y
mouse pointer entered - request the keyboard focus (sometimes)

o  pointerLeave: buttonState
mouse pointer left

o  propertyChange: propertyId state: state
A property has changed, nothing to do here.
Note:
This is very X specific. PropertyChange events must be enabled
to get this event. To enable, do:

self enableEvent: #propertyChange


o  reparented
the view has changed its parent by some outside
action - i.e. window manager has added a frame.
nothing done here

o  requestAutoAccept
request to accept: this is invoked when a dialog closes via accept or cancel.
This forces my value to be accepted into my model.
Any widget may suppress the ok/cancel, by returning false.

o  saveAndTerminate
window manager wants me to save and go away;
- notice, that not all window managers are nice enough to
send this event, but simply destroy the view instead.
Can be redefined in subclasses to do whatever is required
to prepare for restart.

o  scaleMouseWheelHorizontalScrollAmount: amountToScroll
test whether innerWidth == 0

o  scaleMouseWheelScrollAmount: amountToScroll
test whether innerHeight == 0

o  sizeChanged: how
tell subviews that I changed size.
How is either #smaller, #larger or nil, and is used to control the order,
in which subviews are notified (possibly reducing redraw activity)

o  sizeChanged: how from: oldExtent
tell subviews that I changed size.
How is either #smaller, #larger or nil, and is used to control the order,
in which subviews are notified (possibly reducing redraw activity).

In previous versions, there was only one argument, how,
which was either #smaller or #larger or nil (if not known).
This argument was used in some widgets to optimize (avoid) some recomputations.
However, it was too unspecific on which dimension changed;
therefore, now this method is called.
For backward compatibility, it calls the old sizeChanged: method.
If you redefine this, make sure to call super sizeChanged:, not super sizeChanged:from:,
to avoid an endless recursion.

o  subViewChangedSize
some subview has changed its size; we are not interested
in that here, but some geometry managers redefine this, to reorganize
components if that happens.

o  terminate
window manager wants me to go away;
- notice, that not all window managers are nice enough to
send this event, but simply destroy the view instead.
Can be redefined in subclasses to do whatever cleanup is
required.

o  unmapped
the view has been unmapped
(either by some outside action - i.e. window manager iconified me,
or due to unmapping of my parentView).

o  visibilityChange: how
the visibility of the view has changed (by some outside
action - i.e. window manager rearranged things).
Using this knowledge avoids useless redraw in obscured views.

o  visibilityStateChanged
this is called when our visibilityChannel changes

o  win32NativeScroll: scrollCode position: newPosition
this is generated by a native scrollBar widget.
We should never arrive here, as its only supposed to be
sent to scrollableViews...

event simulation
o  pushEvent: aSelector
push some messageSend into my event queue -
I will perform the corresponding method when its time
to handle events (useful to update low-prio views from
a higher prio process, to avoid blocking in the high prio one)

o  pushEvent: aSelector with: arg
push some 1-arg messageSend into my event queue -
I will perform the corresponding method when its time
to handle events (useful to update low-prio views from
a higher prio process, to avoid blocking in the high prio one)

o  pushEvent: aSelector with: arg1 with: arg2
push some 1-arg messageSend into my event queue -
I will perform the corresponding method when its time
to handle events (useful to update low-prio views from
a higher prio process, to avoid blocking in the high prio one)

o  pushEvent: aSelector withArguments: args
push some messageSend into my event queue -
I will perform the corresponding method when its time
to handle events (useful to update low-prio views from
a higher prio process, to avoid blocking in the high prio one)

o  simulateButtonPress: button at: aPoint
simulate a button press by determining which sub-view is affected and
synthetically generating a buttonPressEvent for whatever view is underneath.
Returns the view which precessed the event or nil.

o  simulateButtonPress: button at: aPoint sendDisplayEvent: sendDisplayEvent
simulate a button press by determining which sub-view is affected and
synthetically generating a buttonPressEvent for whatever view is underneath.
Returns the view which precessed the event or nil.

o  simulateButtonRelease: button at: aPoint
simulate a button release by determining which sub-view is affected and
synthetically generating a buttonPressEvent for whatever view is underneath.
Returns the view which precessed the event or nil.

o  simulateButtonRelease: button at: aPoint sendDisplayEvent: sendDisplayEvent
simulate a button release by determining which sub-view is affected and
synthetically generating a buttonPressEvent for whatever view is underneath.
Returns the view which precessed the event or nil.

o  simulateKeyPress: keyOrStringOrSymbol at: aPoint
simulate a key press by determining which sub-view is affected and
synthetically generating a keyPressEvent for whatever view is underneath.
Returns the view which processed the event or nil.

o  simulateKeyPress: keyOrStringOrSymbol at: aPoint sendDisplayEvent: sendDisplayEvent
simulate a key press by determining which sub-view is affected and
synthetically generating a keyPressEvent for whatever view is underneath.
Returns the view which processed the event or nil.

o  simulateKeyPressRelease: keyOrStringOrSymbol at: aPoint
simulate a key release by determining which sub-view is affected and
synthetically generating a keyPressEvent for whatever view is underneath.
Returns the view which processed the event or nil.

o  simulateKeyPressRelease: keyOrStringOrSymbol at: aPoint sendDisplayEvent: sendDisplayEvent
simulate a key release by determining which sub-view is affected and
synthetically generating a keyPressEvent for whatever view is underneath.
Returns the view which processed the event or nil.

o  simulateKeyRelease: keyOrStringOrSymbol at: aPoint
simulate a key release by determining which sub-view is affected and
synthetically generating a keyPressEvent for whatever view is underneath.
Returns the view which processed the event or nil.

o  simulateKeyRelease: keyOrStringOrSymbol at: aPoint sendDisplayEvent: sendDisplayEvent
simulate a key release by determining which sub-view is affected and
synthetically generating a keyPressEvent for whatever view is underneath.
Returns the view which processed the event or nil.

o  simulateUserEvent: ev at: aPoint
simulate a button press by determining which sub-view is affected and
synthetically generating a buttonPressEvent for whatever view is underneath.
Cares for any active grab - i.e. if some other view has grabbed the pointer or keyboard
the event is sent to the grabView with pointer coordinate translated as required
(typically these are popup views like menus)
Returns the view which precessed the event or nil.

o  simulateUserEvent: ev at: aPoint sendDisplayEvent: sendDisplayEvent
simulate a button press by determining which sub-view is affected and
synthetically generating a buttonPressEvent for whatever view is underneath.

If sendDisplayEvent is true, a real physical event is generated via sendEvent,
from the Display (xserver). Otherwise, the event is pushed into the widget's event
queue, without a roundtrip through the display.

Otherwise, care for any active grab - i.e. if some other view has grabbed the pointer or keyboard
the event is sent to the grabView with pointer coordinate translated as required
(typically these are popup views like menus)

Returns the view which processed the event or nil. For displayEvent sending,
always return the receiver, as we do not know how the grab processing came out at the end

o  startButtonLongPressedHandlerProcess
start a process, which simulates a right-button press if the left-button
has been pressed, but not released, and stayed pressed for a while.
This is very handy for single-button-mice, as used with the MAC

o  stopButtonLongPressedHandlerProcess
stop any long-button-pressed process

focus handling
o  assignKeyboardFocusTo: aConsumer
consumer requestFocus. - could be denied; but we force it here

o  assignKeyboardFocusToFirstKeyboardConsumer
assign the keyboard focus to the first first keyboardConsumer.
(in older versions, this used to favour inputfields over editFields;
see (or redefine) preferFirstInputFieldWhenAssigningInitialFocus)

o  canTab
returns true if the widget is tabable
usage example(s):
^ canTab == true

o  canTab: aBoolean
set widget tabable or not

o  doNotRequestFocusOnPointerEnter
returns true if widget SHOULD NOT request the focus on pointer enter;
if false is returned, the behavior depends upon the settings.

o  doNotRequestFocusOnPointerEnter: aBoolean
if true, setup that the widget SHOULD NOT request the focus on pointer enter;
if false, the behavior depends upon the settings.

o  focusNext
get next focus view to self
Skip invisible, disabled or widgets the extent is to small

o  focusNextChildAfter: aChildView
get the next focus view after aChildView in mySelf or nil,
if there is none.
Skip invisible or disabled widgets

o  focusNextForWhich: aCondition
get next focus view to self
Skip invisible, disabled or widgets the extent is to small

o  focusPrevious
get previous focus view to self
Skip invisible & disabled widgets.

o  focusPreviousChildBefore: aChildView
get the previous focus view before aChildView in mySelf or nil, if there is none.
Skip invisible or disabled widgets

o  requestDoNotFocusOnPointerEnter

** This is an obsolete interface - do not use it (it may vanish in future versions) **

o  requestDoNotFocusOnPointerEnter: aBoolean
very bad naming - wrong english

** This is an obsolete interface - do not use it (it may vanish in future versions) **

o  requestFocus
request focus from my windowGroup;
typically, this is invoked when the mouse pointer enters a
widget. The request may or may not be ignored by the wGroup
(it will be ignored, if an explicit focus-change is currently
active - i.e. if the user tabbed into a widget)

o  requestFocusOnPointerEnter
returns true if widget SHOULD request the focus on pointer enter;
if false is returned, the behavior depends upon the settings.

o  requestFocusOnPointerEnter: aBoolean
if true, setup that the widget SHOULD request the focus on pointer enter;
if false, the behavior depends upon the settings.

o  showFocus: explicit
highlight myself somehow to tell user that I have the focus.
If explicit is true, the focus came via focusStepping (i.e. tabbing);
if false, it came via the window manager (i.e. pointer entering).
Only change my border, if this is an explicit focusChange.

o  showNoFocus: explicit
undo the effect of showFocus.
Explicit tells if the focus came via focusStepping (i.e. tabbing)
or via the window manager (i.e. pointer entering).
Only change my border, if this is an explicit focusChange.

o  subviewsInFocusOrder

o  takeFocus
Unconditionally take the focus from my windowGroup

o  takeFocusWhenMapped

o  takeFocusWhenMapped: aBoolean

o  topViewWasMapped
invoked when my topView is mapped

o  wantsFocusWithButtonPress
views which do not like to take the keyboard focus
with buttonPress can do so by redefining this
to return false
(actually: they should, because it is quite annoying
in the UI, if a menuPanel or button takes my keyboard focus.
So we should consider making the default false here, so every
widget writer has to think twice...
Can we do such a major change?)

o  wantsFocusWithPointerEnter
views which like to take the keyboard focus
when the pointer enters can do so by redefining this
to return true

grabbing
o  forceUngrabKeyboard
force a keyboard ungrab - even if was not the grabber

o  forceUngrabPointer
force a pointer ungrab - even if was not the grabber

o  grabKeyboard
grab the keyboard - that is: report all keyboard events to myself,
even if the mouse moved out of myself.
Returns true if the grab was successful (could fail, if some other
application has a grab - but that is very unlikely).

o  grabPointer
grab the pointer - that is: report all motion events relative to
myself, even if moved out of myself.
Returns true if the grab was successful (could fail, if some other
application has a grab - but that is very unlikely).

o  grabPointerWithCursor: aCursorOrNil
grab the pointer - that is: report all motion events relative to
myself, even if moved out of myself.
Show aCursor during the grab, if the cursor argument is not nil.
Returns true if the grab was successful (could fail, if some other
application has a grab - but that is very unlikely).

o  ungrabKeyboard
ungrab the keyboard - but only if I was the grabber

o  ungrabPointer
ungrab the pointer - but only if I was the grabber

informing others of changes
o  contentsChanged
this one is sent, whenever contents changes its size -
tell dependents about the change (i.e. scrollers).

o  noticeOfWindowClose

o  noticeOfWindowOpen

o  originChanged: delta
this one is sent, after the origin of my contents has changed -
tell dependents (i.e. scrollers) about this

o  originWillChange
this one is sent, just before viewOrigin changes -
gives subclasses a chance to catch scrolls easily
(for example to hide cursor before scroll)

initialization & release
o  defaultControllerClass
Controller

o  defaultExtent
return the default extent of my instances.

o  defaultFont

o  destroy
unmap & destroy - make me invisible, destroy subviews then
make me unknown to the device

o  initEvents
will be sent by create - can be redefined by subclasses to enable
view events

o  initStyle
this method sets up all style dependent things

o  initStyleSheet
this method gets the styleSheet

o  initialize
initialize all state of the view - usually redefined in subclasses,
but always doing a 'super initialize'. Each class should setup its
locals - and not forget the others.
View setup is separated into two parts, the general setup done here
and the style specific setup in initStyle. Each view should be prepared
for a stylechange by being sent another initStyle with a new style value.
(in this case, it should set all of its style-dependent things, but
leave the state and contents as-is)
usage example(s):
fill in some defaults - some of them are usually redefined in subclasses
     initialize methods

o  initializeMiddleButtonMenu
a place to initialize menu - this one is sent once when the view-object is initialized.
usually redefined in subclasses; default here is no menu.
Notice, that static middleButtonmenus are a historic thing in ST/X;
you may prefer to create the menu dynamically.

o  prepareForReinit

o  reinitStyle
this method is called for a style change

o  reinitialize
this is called right after snapIn

o  release
remove all dependencies from the receiver

o  restarted
sent by my windowGroup, when restarted from an image.
Nothing done here, but can be redefined to perform any actions
required to reset some state after an image-restart.

Only top views (usually instances of TopView) get this message sent.
Since SimpleViews can act as a top view, too this message is implemented
in SimpleView

o  subViewsHaveBeenReparented

inspecting
o  inspectorExtraAttributes
( an extension from the stx:libtool package )
(comment from inherited method)
extra (pseudo instvar) entries to be shown in an inspector.
Answers a dictionary of aString -> aBlock.
aString is name of extra attribute and MUST start with minus ($-).
aBlock returns the object representing extra attribute.

keyboard control
o  defineShortcutAndTranslateLabelStringFrom: aString

o  mnemonicKey
get the mnemonic key or nil if undefined

o  mnemonicKey: aSymbolOrNil
set or clear the mnemonic key

o  mnemonicViewNext: aKeyEvent
a mnemonicKey event as forwarded from the keyboardProcessor - if there
is the mnemonic-key defined for a subView return the view otherwise nil.

o  performShortcutAction
perform my shortcutKey action.

o  processShortcut: aKeyEvent
a shortcutKey event as forwarded from the keyboardProcessor - if there is the
shortcut-key defined process the shortcut and return true otherwise false.

o  shortcutAndTranslatedStringFrom: aString
return an array filled with an extracted shortcut key and a translated string;
looks for and reemoves any ampercent character from aString, and adds underline emphasis to the
following character
usage example(s):
     Transcript showCR:(self basicNew shortcutAndTranslatedStringFrom:'hello'        ) last
     Transcript showCR:(self basicNew shortcutAndTranslatedStringFrom:'he&llo'       ) last
     Transcript showCR:(self basicNew shortcutAndTranslatedStringFrom:'he&&llo'      ) last
     Transcript showCR:(self basicNew shortcutAndTranslatedStringFrom:'he& llo'      ) last
     Transcript showCR:(self basicNew shortcutAndTranslatedStringFrom:'he&123llo'    ) last
     Transcript showCR:(self basicNew shortcutAndTranslatedStringFrom:'hello &'      ) last
     Transcript showCR:(self basicNew shortcutAndTranslatedStringFrom:'hello &&'     ) last

o  shortcutKey
get the shortcut key

o  shortcutKey: aSymbolOrNil
set or clear the shortcut key

menu & menu actions
o  fontLargerOrSmaller: largerBoolean
sent via the CTRL+/CTRL- or SHIFT-CTRL+ / SHIFT-CTRL- keys.
Make my font larger or smaller (within a reasonable range)

menu handling
o  activateMenu
activate my menu.
This code will move into the controller ASAP
If there is a static middleButtonMenu, that one is taken,
and handled in the superClass (static menus are a historic leftOver).
Otherwise, the following steps are performed:

- ask the receiver for the menu (via #yellowButtonMenu)
- ask the receiver for the menuPerformer.
- startUp the menu - it is supposed to return an actionSelector
- if the menuPerformer responds to the selector,
send it to the performer;
otherwise send it to the view (the receiver)
This is funny, it allows additional menuItems to be added
AND still get the view's copy/cut/paste functionality.
Without this, you had to redefine and forward all of those
messages in the performer.

o  dispatchMenuSelection: menuSelection to: aMenuPerformerOrNil
dispatch a menu message.
This code will move into the controller ASAP

o  menuFromSpec: aMenuOrMenuSpec
create a menu for the receiver from a spec

o  startUpMenu: aMenu

native widget support
o  nativeWindowType
return a symbol describing my native window type - here, nil is returned
(may be used internally by the device as a native window creation hint,
iff native windows are enabled AND the device supports it)

private
o  componentsContainingX: x y: y do: aBlock
delegated

o  computeInnerClip
compute, but do not set the inside clip-area, in device coordinates

o  cornerFromRelativeCorner
compute & return pixel corner from relativeCorner

o  cornerFromRelativeCorner: aPoint
compute & return pixel corner from a relativeCorner, aPoint

o  detectViewAt: aPoint
find the subView which contains aPoint - invisible components are ignored.
This is almost the same as #componentContainingX:y: (if that existed)

o  detectViewAt: aPoint ignoreInvisible: ignoreInvisible
find the subView which contains aPoint - invisible components are ignored if
the ignoreInvisible argument is true.
This is almost the same as #componentContainingX:y: (if that existed)

o  explicitExtent: aBoolean
set the exeplicit extent flag to aBoolean.

o  extentFromRelativeExtent
compute & return pixel extent from relativeExtent

o  extentFromRelativeExtent: aPoint
compute & return pixel extent from relativeExtent, aPoint

o  originFromRelativeOrigin
compute & return pixel origin from relativeOrigin

o  originFromRelativeOrigin: aPoint
compute & return pixel origin from relativeOrigin, aPoint

o  pixelCorner: corner
set the view's corner in pixels

o  pixelExtent: extent
set the view's extent in pixels

o  pixelOrigin
return the view's origin in pixels. For subviews. the origin is relative
to the superview's top-left. For topViews, it's the screen origin.

o  pixelOrigin: origin
set the view's origin in pixels. For subviews. the origin is relative
to the superview's top-left. For topViews, it's the screen origin.

o  pixelOrigin: origin corner: corner
set the view's origin and corner in pixels

o  pixelOrigin: origin extent: extent
set the view's origin and extent in pixels

o  pointFromRelative: p
compute absolute coordinate from p

o  setBorderColor
set my borderColor in the physical view (if supported by the device)

o  setInnerClip
compute, and set the inside clip-area

o  setShown: aBoolean
Modified (format): / 04-02-2017 / 21:34:42 / cg

o  setViewShape

o  windowGroupClass

queries
o  anyComponentHasFocus
return true, if the receiver or any of my components has the keyboard focus
(either via the focusView mechanism in the windowGroup,
or via delegation)

o  canHandle: aKey
return true, if I like to handle the key (from a keyPress event).
OBSOLETE: do not use & depend on this method, it is a historic
leftOver and will be removed. Use the delegation mechanism for this.

o  canHandle: aKey from: aView
return true, if I like to handle the key (from a keyPress event)
in aView.
OBSOLETE: do not use & depend on this method, it is a historic
leftOver and will be removed. Use the delegation mechanism for this.

o  computePreferredExtent
compute answer the preferred extent, disregarding
an explicit or cached preferred extent for the computation

o  cornerChangedFlag
^ cornerChangedFlag == true

o  cornerChangedFlag: aBoolean
cornerChangedFlag := aBoolean

o  delegatesTo: someone
return true, if I delegate events to someone

o  escapeIsCancel
return the escapeIsCancel setting - defaults to true for popupViews here.

o  extentChangedBeforeCreatedFlag

o  extentChangedBeforeCreatedFlag: aBoolean

o  extentChangedFlag
^ extentChangedFlag == true

o  extentChangedFlag: aBoolean
extentChangedFlag := aBoolean

o  hasExplicitFocus
return true, if the receiver has the keyboard focus
via the focusView mechanism in the windowGroup

o  hasFocus
return true, if the receiver has the keyboard focus
(either via the focusView mechanism in the windowGroup,
or via delegation)

o  is3D
return true, if my style is some kind of 3D style
This is OBSOLETE and will be removed.

o  isActive
true, if I have the focus (w.r.t the windowing system);
i.e. if one of my subViews actually has the real focus.
With click-to-focus behavior, this is obviously the current application.
Use this query with caution, for example, to suppress tooltips for inactive apps.

o  isBorderedWrapper

o  isComponentOf: aViewOrComponent
return true, if I am a (direct or indirect) component of aViewOrComponent

o  isCursorKeyConsumer
return true, if the receiver can be controlled by cursor keys;
i.e. it can handle some keyboard input,
isCursorKeyConsumer are potential candidates for getting the keyboard
focus initially within dialogBoxes, or when the focus-follows-pointer
mode is off.
Return false here, this is redefined in SelectionInListView.

o  isDefault
return true, if I am a default widget;
Used with autoAccept. Currently only default buttons are supposed to return
true here

o  isExternalTopView
return true, if this is an external topView - always false here

o  isICCCWindowGroupWindow
needed for checkForEndOfDispatch

o  isInputField
return true, if the receiver is some kind of input view,
i.e. it should (can) be part of an enterGroup.
Return false here, this is redefined in EnterField.

o  isJavaView

o  isKeyboardConsumer
return true, if the receiver is a keyboard consumer;
i.e. it can handle (non-shortkey) keyboard input,
keyboardConsumer are potential candidates for getting the keyboard
focus initially within dialogBoxes, or when the focus-follows-pointer
mode is off.
Return false here, this is redefined in EditTextView and EditField.

o  isLayoutWrapper
answer true, if this view defines the layout of it's subviews

o  isMDIClientView

o  isModal
return true, if the receiver has been opened modal.
For compatibility with topView (if regular views are the window of an application),
return false here.

o  isSameOrComponentOf: aView
return true, if I am aView or a (direct or indirect) component of aView

o  isScrollWrapper
answer true if this view wraps a possibly larger view and has scroll bars

o  isSubViewOf: aView
return true, if I am a (direct or indirect) subview of aView

** This is an obsolete interface - do not use it (it may vanish in future versions) **

o  isTextView
Returns true, if the view displays text

o  isTransparentBox

o  isWrapper

o  originChangedFlag
^ originChangedFlag == true

o  originChangedFlag: aBoolean
originChangedFlag := aBoolean

o  originChangedFlag: originChanged extentChangedFlag: extentChanged

o  originChangedFlag: originChanged extentChangedFlag: extentChanged cornerChangedFlag: cornerChanged

o  originOrExtentChanged
^ originChanged or:[extentChanged].

o  originOrExtentOrCornerChanged
^ originChanged or:[extentChanged or:[cornerChanged]].

o  preferredBounds
ST-80 compatibility.

o  preferredExtent
return my preferred extent - this is the minimum size I would like to have.
If the preferredExtent has been set, that one is returned.
Otherwise, if there are any components, a rectangle enclosing them
is returned. Otherwise, the actual extent is returned.
usage example(s):
If I have an explicit preferredExtent..
usage example(s):
If I have a cached preferredExtent value..

o  preferredHeight

o  preferredWidth

o  reallyRealized
return true, if the receiver is realized and all containers are realized.
Realized means that it has been mapped (i.e. made visible) on
the display (as opposed to being only created and possibly invisible)

o  resources
return the view's resources -
that's a ResourcePack containing national language strings

o  sizeFixed
return true, if this view wants its size to remain unchanged.
Used by panels, to check if their components want to keep their size.

o  startWindowMoveOnButtonPress
if another view is used as topView

o  tabRequiresControl
returns true, if a focus tabbing requires a control-key to be pressed.
The default is true for editTextView, false for other widgets,
to allow for easier text entry

o  window
for compatibility with applicationModels ... return the receiver

queries-delegation
o  handlesMouseWheelMotion: event inView: aView
we do not handle delegated mousewheel events - subclasses may handle them

queries-events
o  buttonMotionEventPending
return true, if a button motion event is pending.
Normally, you don't want to use this, since no polling is needed
(not even for mouse-tracking).
Actually, its a historical leftover

queries-internal
o  specClass
fallback - heuristics to get a specClass for some viewClass.
Based upon my className, look for a corresponding Spec-class.
If there is none, return ArbiraryComponentSpec as a fallBack
usage example(s):
     FramedBox new specClass

o  windowStyle
return a symbol describing my style (one of: #dialog, #popUp or #normal)

o  windowType
return a symbol describing my type (one of: #mdichild or nil)

realization
o  activate
noop for protocol compatibility with TopViews (in case you do a Button new open)

o  closeCancel
for protocol compatibility with modal dialogs

o  create
create (i.e. tell my device about me) if not already created.
This does not make the view visible (needs a #map for that)
usage example(s):
	 make certain that superview is created also
usage example(s):
this view was created (and therefore, no sizeChangeEvent
usage example(s):
	 this is the first create,
	 force sizechange messages to be sent to the view

o  createWithAllSubViews
create, then create all subviews

o  fetchDeviceResources
fetch all device specific resources. This is invoked,
when the view is made visible on some device for the very first
time, to allocate device specific colors, fonts, bitmaps etc.
The view may keep those in instance variables, to avoid reallocating
those with every redraw.
If you omit to do this, the views will still be able to display themself,
but possibly slower, since resources are reallocated over and over.
If you redefine this method, make certain that 'super fetchDeviceResources'
is always sent.

o  fixSize
This is called right before the view is made visible.
Adjust the size of the view according to either relative/abs or
block extent; also set origin. Also, subclasses may redefine this
method to adjust the size based on some extent (for example, PopUpMenus
do so to take care of changed number of menu entries).

o  forceResize
force resizing - even if already done

o  hide
only useful with modal views: hide the view and return control
back to the suspended main view. Ignored for non-modal views.
usage example(s):
	 this is a kludge for IRIS and others which do not provide backingstore:
	 when we hide a modalbox (such as a searchbox) which covered
	 a scrollbar, the scrollbars bitblt-method will copy from the
	 not-yet redrawn area - effectively clearing the scroller.
	 We need a short delay here, since at this time, the expose event has
	 not yet arrived.

o  hideForAction
for popUpMenu compatibility;
this is invoked to hide a when it is going to perform its action
(in contrast to the generic hide).

o  hideRequest
for protocol compatibility with modal dialogs;
ignored here.

o  map
make the view visible on the screen.
For topViews, the windowManager will choose (or ask for) the
views position on the screen.
Notice:
Actually, this method is only valid for topViews;
however, it is defined here to allow things like 'Button new realize'

o  mapAt: aPoint
make the view visible on the screen.
For topViews, if aPoint is nonNil, the view's origin is located there
(unless you have a dictator as windowManager ;-)
Notice:
Actually, this method is only valid for topViews;
however, it is defined here to allow things like 'Button new realize'

o  mapAt: aPoint iconified: iconified
make the view visible on the screen.
For topViews, if aPoint is nonNil, the view's origin is located there
(unless you have a dictator as windowManager ;-).
If the iconified argument is true, the window is created as icon initially.
Notice:
Actually, this method is only valid for topViews;
however, it is defined here to allow things like 'Button new realize'

o  mapIconified
make the view visible on the screen.
For topViews, the view is created in iconified state

o  physicalCreate
common code for create & recreate:
physically create (but do not map) the view on the device.

o  postRealize
invoked after a view was realized.
Can be redefined in subclasses to perform delayed actions.

o  preRealize
invoked right before a view is realized.
Can be redefined in subclasses to perform delayed actions.

o  realize
realize - make visible;
realizing is done very late (after layout is fixed) to avoid
visible rearranging of windows on the screen
usage example(s):
in case a view gets rerealized

o  realizeAllSubViews
realize all my subviews - but not myself.

o  realizeAt: aPoint
realize - make visible;
realizing is done very late (after layout is fixed) to avoid
visible rearranging of windows on the screen

o  realizeInGroup
special realize - leave windowgroup as is;
This allows a view to be realized in any windowgroup;
for special applications, like the kill button in the Filebrowser which has
a windowGroup different from its superview's and is handled as a separate process.

o  realizeKeepingGroup: keepGroupAsIs at: position iconified: iconified
common helper for realize and realizeInGroup.
Create the view; if the keepGroupAsIs argument is not true,
assign my windowGroup.

o  recreate
recreate (i.e. tell X about me) after a snapin or a migration

o  recursiveRealizeAllSubViews
realize all my subviews and all of their subviews - but not myself.

o  remap
make the view visible on the screen at its previous position.
In contrast to map, this asks the windowManager to show the view
immediately (instead of asking for a frame). However, some windowManagers
are known to ignore this ...

o  rerealize
rerealize at old position in (a possibly different) windowGroup.

o  rerealizeInGroup: aWindowGroup
rerealize at old position in (a possibly different) windowGroup.

o  rerealizeWithAllSubViews
rerealize myself with all subviews

o  resize
resize myself to make everything fit into me.
Here, nothing special is done (except for setting my extent to the
preferredExtent), but may be redefined in some subclasses.

o  setForegroundWindow
noop for protocol compatibility with TopViews (in case you do a Button new open)

o  unmap
unmap the view - the view stays created (but invisible), and can be remapped again later.
usage example(s):
unmap is an asynchronous operation.
usage example(s):
(shown is cleared also in unmapped event)

o  unrealize
alias for unmap, for historic reasons

** This is an obsolete interface - do not use it (it may vanish in future versions) **

redrawing
o  clearExposedAreaInRedraw
return true here, if the exposed area should be cleared here
or not. In almost every situation, it makes sense to do so...

o  drawFocusFrame

o  flash
flash the view - fill it black, then white, finally
redraw completely.
Can be used to wakeup the user :-)
when problem or warning conditions arise.
Someone may redefine this to flash its contents (instead of black/white).

o  flash: messageOrNil
flash the view - fill it black, then white, finally
redraw completely.
Can be used to wakeup the user :-)
when problem or warning conditions arise.
Someone may redefine this to flash its contents (instead of black/white).

o  flash: messageOrNil withColor: flashColor
flash the view - fill it flashColor, then white,
finally redraw completely.
Can be used to wakeup the user :-)
when problem or warning conditions arise.
Someone may redefine this to flash its contents (instead of black/white).

o  flashReadOnly
flash the view and show 'Read Only' for a moment.

o  flashRectangle: rect withColor: flashColor
flash part of the view - fill it flashColor, then white,
finally redraw.
Can be used to bring attention to some line/part of view

o  invalidate
add a damage to redraw the receiver to its input event queue.
This is preferable to calling redraw directly, in that the drawing is done by
the view's process itself, and there is a possibilty to merge
multiple damage rectangles into single redraws.
However, be aware, that the redrawing may be delayed for some time,
until the receiver's windowGroupProcess gets rescheduled.

o  invalidate: aRectangle
add a damage to redraw part of the receiver, to its input event queue.
This is preferable to calling redraw directly,
in that the drawing is done by the view's process itself,
and there is a possibilty to merge multiple damage rectangles into
single redraws.
However, be aware, that the redrawing may be delayed for some time,
intil the receiver's windowGroupProcess gets rescheduled.

o  invalidate: aRectangle repairNow: doRepairNow
add a damage to redraw part of the receiver, to its input event queue.
and (if repairNow is true), force the receiver to repair all of its
damaged areas right now.
The given rectangle is in logical coordinate space.

o  invalidateDeviceRectangle: aRectangle repairNow: doRepairNow
add a damage to redraw part of the receiver, to its input event queue.
and (if repairNow is true), force the receiver to repair all of its
damaged areas right now.
The given rectangle is in device coordinate space.

o  invalidateRepairNow: doRepair
add a damage to redraw all of the receiver, to its input event queue.
and (if repairNow is true), force the receiver to repair all of its
damaged areas right now.

o  invalidateX: x y: y width: w height: h
add a damage to redraw all of the receiver, to its input event queue.

o  invalidateX: x y: y width: w height: h repairNow: doRepair
add a damage to redraw all of the receiver, to its input event queue.
and (if repairNow is true), force the receiver to repair all of its
damaged areas right now.

o  redraw
redraw myself completely - this is sent by redrawX:y:width:height:
as a fallback.
Cannot do much here - is redefined in subclasses which don't care for
updating regions but instead update everything.

o  redraw: aRectangle
redraw a part of the view immediately.

o  redrawComponentsIn: aRectangle

o  redrawDeviceX: x y: y width: w height: h
have to redraw part of the view.
The coordinates are in device space - if there is a transformation,
must inverse-transform back to logical coordinates. (since the view thinks
in its coordinate space)

o  redrawX: x y: y width: w height: h
redraw part of myself immediately, given logical coordinates
(if transformation is nonNil)
The default here is to redraw everything
- subclasses usually redefine this, adding more intelligence

o  renderOrRedraw
experimental feature

o  repairDamage
force the receiver to repair all of its
damaged areas right now.

o  showActive
redraw myself as active (i.e. busy).
Nothing done here, but redefined in some classes.

o  showPassive
redraw myself as inactive (i.e. nonbusy).
Nothing done here, but redefined in some classes.

scrolling
o  halfPageDown
scroll down half a page

o  halfPageUp
scroll up half a page

o  horizontalScrollStep
return the amount to scroll when stepping left/right.
Subclasses may want to redefine this.

o  pageDown

o  pageLeft

o  pageRight

o  pageUp

o  scrollDown
scroll down by some amount; this is called when the scrollbars
scroll-step down button is pressed.

o  scrollDown: nPixels
change origin to scroll down some pixels

o  scrollHorizontalTo: aPixelOffset
change origin to make aPixelOffset be the left col

o  scrollHorizontalToPercent: percent
scroll to a position given in percent of total

o  scrollLeft
scroll left by some amount; this is called when the scrollbars
scroll-step left button is pressed.

o  scrollLeft: nPixels
change origin to scroll left some pixels

o  scrollRelative: nPixels
change origin to scroll up (nPixels < 0) or down (nPixels > 0)

o  scrollRight
scroll right by some amount; this is called when the scrollbars
scroll-step right button is pressed.

o  scrollRight: nPixels
change origin to scroll right some pixels

o  scrollToBottom

o  scrollToLeft
move viewOrigin to the left

o  scrollToPercent: originAsPercent
scroll to a position given in percent of total (x and y as a Point)

o  scrollToRight
move viewOrigin to the right

o  scrollToTop
move viewOrigin to top

o  scrollToTopLeft
move viewOrigin to top/left

o  scrollUp
scroll up by some amount; this is called when the scrollbars
scroll-step up button is pressed.

o  scrollUp: nPixels
change origin to scroll up (towards the origin) by some pixels

o  scrollVerticalTo: aPixelOffset
change origin to make aPixelOffset be the top line

o  scrollVerticalToPercent: percent
scroll to a position given in percent of total

o  verticalScrollStep
return the amount to scroll when stepping up/down (also used for mouseWheel).
Subclasses may want to redefine this.

o  widthForScrollBetween: yStart and: yEnd
return the width in pixels for a scroll between yStart and yEnd
- return full width here since we do not know how wide contents is.
Views which only use part of their space (short lists, text) may redefine
this method and return the number of pixels that have to be scrolled.
On slow displays, this may make a difference; on fast ones you will probably
not notice any difference.

scrolling-basic
o  scrollTo: newOrigin
change origin to have newOrigin be visible at the top-left.
The argument defines the integer device coordinates of the new top-left
point.

o  scrollTo: newOrigin redraw: doRedraw
change origin to have newOrigin be visible at the top-left.
The argument defines the integer device coordinates of the new top-left
point.
If doRedraw is true, and any new areas are exposed, these are invalidated
(i.e. there may be pending redraw events in the event queue).

o  scrollTo: newOrigin redraw: doRedraw allowScrollBeyondContents: allowScrollBeyondContents
change origin to have newOrigin be visible at the top-left.
The argument defines the integer device coordinates of the new top-left
point.
If doRedraw is true, and any new areas are exposed, these are invalidated
(i.e. there may be pending redraw events in the event queue).

o  scrollTo: newOrigin waitForDrawingFinished: doWait
change origin to have newOrigin be visible at the top-left.
The argument defines the integer device coordinates of the new top-left
point.
If any new areas are exposed, invalidate them.
If doWait is true, wait until all draws are completed,
otherwise, possible redraws may still be in the event queue.

startup
o  open
open up the view - for normal views, this is a modeless open
(i.e. the new view comes up as independent process).
Although #open is only to be sent to topviews (i.e. it could have been
implemented in TopView), it is implemented here - therefore, every view
can be opened as a topView.
This is redefined in ModalBox, which comes up modal (i.e.
control is under the current process, so that interaction with the
current group is blocked while the modalBox is active).

Notice: after the open, you cannot be sure that the view is really open and
visible, since #open forks a new process, which does the actual window opening.
To ensure visibility, use #openAndWait or waitUntilVisible after the open.
usage example(s):
     View new open
usage example(s):
     (Button label:'hello') open
usage example(s):
     YesNoBox new open

o  openAndWait
open up the view - wait until it is visible.
In normal applications, you do not need to wait till the view is
open - it should do all of its drawing itself when it gets the
first expose event.
However, if you want to 'manually' draw into the view (for example,
in doIt expressions) the view must be visible (realized) before doing so.
Use this open in those situations.

o  openAt: aPoint
open up the view modeless - positions the view
usage example(s):
     (Button label:'hello') open

     (Button label:'hello') openAt:(100@100)

o  openAtCenter
open up the view modeless - positions the view
usage example(s):
     (Button label:'hello') open

     (Button label:'hello') openAtCenter

o  openAutonomous
create and schedule a new windowgroup for me and open the view.
The view will be handled by its own process, effectively running in
parallel.
Notice:
This entry is for NON-topviews, which want to be served
autonomous from their real topview.
(see the fileBrowsers kill-button
when executing unix commands as an example)

o  openInGroup: aGroup
special open within another windowGroup.
This allows a view to be realized in any windowgroup;
for applications where multiple views act as a group
(i.e. close and iconify together).

o  openModal
create a new windowgroup, but start processing in the current process
actually suspending event processing for the currently active group.
Stay in the modalLoop while the view is visible.
(i.e. control is returned to the sender when the receiver is closed)
usage example(s):
     the same:
	 YesNoBox new open

	 YesNoBox new openModal

     different:
	 (Button label:'hello') open

	 (Button label:'hello') openModal

o  openModal: aBlock
create a new windowgroup, but start processing in the current process -
actually suspending event processing for the currently active group.
Stay in this modal loop while aBlock evaluates to true AND the receiver is
visible.
(i.e. control is returned to the sender when the receiver is closed)
This makes any interaction with the current window impossible -
however, other views (in other windowgroups) still work.

o  openModal: aBlock inGroup: activeWindowGroup
create a new windowgroup, but start processing in the current process -
actually suspending event processing for the main group.
Stay in this modal loop while aBlock evaluates to true AND the receiver is
visible.
(i.e. control is returned to the sender when the receiver is closed)
This makes any interaction with the current window impossible -
however, other views (in other windowgroups) still work.

o  openModalAt: aPoint
open up the view modeless - positions the view
(i.e. circumvents window managers positioning)
usage example(s):
     View new openModalAt:100@100

o  openModalAtCenter
open up the view modeless - positions the view
(i.e. circumvents window managers positioning)
usage example(s):
     View new openModalAtCenter

o  openModalAtPointer
View new openModalAtPointer

o  openModeless
create and schedule a new windowgroup for me and open the view.
The view will be handled by its own process, effectively running in
parallel (i.e. control is returned to the sender immediately).
usage example(s):
     the same:
	 (Button label:'hello') open

	 (Button label:'hello') openModeless

     different:
	 YesNoBox new open

	 YesNoBox new openModeless

o  openModelessAt: aPoint
open up the view modeless - positions the view
(i.e. tries to circumvent the window managers positioning)
Notice: some windowManagers seem to ignore this and always
ask the user to position the view.
usage example(s):
     View new openModeless

     View new openModelessAt:100@100

o  openModelessAt: aPoint iconified: iconified
open up the view modeless - positions the view
(i.e. tries to circumvent the window managers positioning)
Notice: some windowManagers seem to ignore this and always
ask the user to position the view.
usage example(s):
     StandardSystemView new openModeless

     StandardSystemView new openModelessAt:100@100

     StandardSystemView new openModelessAt:100@100 iconified:true

o  openModelessAtCenter
open up the view modeless - positions the view
(i.e. circumvents window managers positioning)
usage example(s):
     View new openModeless

     View new openModelessAtCenter

o  openModelessAtPointer
create and schedule a new windowgroup for me and open the view.
The view will be handled by its own process, effectively running in
parallel (i.e. control is returned to the sender immediately).
usage example(s):
     (Button label:'hello') openModelessAtPointer

o  waitUntilVisible
wait until the receiver visible.
In normal applications, you do not need to wait till a view is
open - it should do all of its drawing itself when it gets the
first expose event.
However, if you want to 'manually' draw into the view (for example,
in doIt expressions), or subsequent views depend on some state of
another view (which is only available once visible),
use this to suspend the current process until the receiver is shown.
Caveat:
we poll here for the view to be shown - we need a semaphore
which is raised by the view in order to do it right.
usage example(s):
does not work (the view is in its opening phase,
     when we attempt to draw a line - this gives an error, since
     its internals are not yet correctly setup):

        |v|

        v := View new open.
        v displayLineFrom:0@0 to:50@50

     does work (since we wait until the view has completely finished
     its startup phase):

        |v|

        v := View new open.
        v waitUntilVisible.
        v displayLineFrom:0@0 to:50@50

testing
o  hasOwnScrollbars
a hack for codeView2, which behaves like a TextView, but has its own
scrollbars embedded - sigh (an extra load one).
This allows for the UIBuilder to avoid creating an extra set around such
a view (as is the case with TextSpec with scrollbars when using CodeView2)

o  isApplicationSubView

o  isCodeView2
( an extension from the stx:libtool package )
codeview2 seems to require some extra hacks

o  isComboView

o  isPopUpList

user interaction & notifications
o  showNotFound
something was not found - tell user by beeping and changing
cursor for a while (sometimes I work with a headset :-)
(used to be: tell user by changing cursor for a while).
Beep can be disabled via the settings

o  warn: aString
like Objects warn, but translates the string via the
resourcePack, thus giving a translated string automatically

o  warn: aString with: argument
like Objects warn, but translates the string via the
resourcePack, thus giving a translated string automatically

o  warn: aString with: arg1 with: arg2
like Objects warn, but translates the string via the
resourcePack, thus giving a translated string automatically

o  warn: aString with: arg1 with: arg2 with: arg3
like Objects warn, but translates the string via the
resourcePack, thus giving a translated string automatically


Private classes:

    AboutToOpenBoxNotificationSignal
    ArbitraryViewShape
    BoxClosedNotificationSignal
    RoundViewShape
    ViewShape

Examples:


(all examples below use different viewBackgrounds, to make the individual subviews visible) a subView in a topView:
    |top v|

    top := StandardSystemView new.
    v := View new.
    v origin:0.25 @ 0.25 corner:0.75 @ 0.75.
    top addSubView:v.
    top open
the same, a bit more compact:
    |top v|

    top := StandardSystemView new.
    v := View origin:0.25 @ 0.25 corner:0.75 @ 0.75 in:top.
    top open
fixed position/size:
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View origin:10@10
              corner:50@50
                  in:top.
   v2 := View origin:60@10
              corner:150@100
                  in:top.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top open
same, using ST-80 way of bulding up view hierarchies (recommended, if you plan to port applications later)
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v1 origin:10@10 corner:50@50.

   v2 := View new.
   v2 origin:60@10 corner:150@100.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1.
   top add:v2.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top open
fixed origin, variable size:
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v1 origin:10@10 corner:50@0.5.

   v2 := View new.
   v2 origin:60@10 corner:150@0.5.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1.
   top add:v2.

   top open
fixed origin, variable size, bottomInset for constant distance from bottom:
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v1 origin:10@10 corner:50@1.0.
   v1 bottomInset:10.

   v2 := View new.
   v2 origin:60@10 corner:150@1.0.
   v2 bottomInset:10.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1.
   top add:v2.

   top open
variable origin, variable size,
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v1 origin:0.0@0.0 corner:0.5@0.5.

   v2 := View new.
   v2 origin:0.5@0.0 corner:1.0@0.5.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1.
   top add:v2.

   top open
variable origin, variable size, insets for some constant distance
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v1 origin:0.0@0.0 corner:0.5@0.5.
   v1 rightInset:5.

   v2 := View new.
   v2 origin:0.5@0.0 corner:1.0@0.5.
   v2 leftInset:5.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1.
   top add:v2.

   top open
using layout objects (ST-80 style): fully specifying the frame
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v2 := View new.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1 in:(LayoutFrame new
                    leftFraction:0.25;
                    rightFraction:0.75;
                    topFraction:0.0;
                    bottomFraction:0.5).
   top add:v2 in:(LayoutFrame new
                    leftFraction:0.5;
                    rightFraction:1.0;
                    topFraction:0.5;
                    bottomFraction:0.75).

   top open
another one, with offsets:
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v2 := View new.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1 in:(LayoutFrame new
                    leftFraction:0.0 offset:10;
                    rightFraction:1.0 offset:-10;
                    topFraction:0.0 offset:10;
                    bottomFraction:0.5).
   top add:v2 in:(LayoutFrame new
                    leftFraction:0.0 offset:30;
                    rightFraction:1.0 offset:-30;
                    topFraction:0.5 offset:10;
                    bottomFraction:0.75).

   top open
specifying origin only. Extent is views preferred (notice, that plain views have some defaultExtent of 100@100)
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   v2 := View new.

   v1 viewBackground:(Color red).
   v2 viewBackground:(Color yellow).

   top add:v1 in:(LayoutOrigin new
                    leftFraction:0.25;
                    topFraction:0.0).
   top add:v2 in:(LayoutOrigin new
                    leftFraction:0.5;
                    topFraction:0.5).

   top open
same example, using buttons which compute their preferredBounds:
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := Button label:'foo'.
   v2 := Button label:'a very long buttonLabel'.

   v1 backgroundColor:(Color red).
   v2 backgroundColor:(Color yellow).

   top add:v1 in:(LayoutOrigin new
                    leftFraction:0.25;
                    topFraction:0.0).
   top add:v2 in:(LayoutOrigin new
                    leftFraction:0.5;
                    topFraction:0.5).

   top open
border:
   |top v1 v2|

   top := StandardSystemView new.
   top extent:300@300.

   v1 := View new.
   top add:v1 in:(10@10 corner: 30@30).
   v2 := View new.
   top add:v2 in:(30@30 corner: 50@50).

   v1 border:(SimpleBorder width:1 color:Color red).
   v2 border:(SimpleBorder width:1 color:Color blue).
   top open


ST/X 7.1.0.0; WebServer 1.663 at exept.de:8081; Wed, 12 Dec 2018 09:57:20 GMT