|
Class: GraphColumnView2D
Object
|
+--GraphicsMedium
|
+--DisplaySurface
|
+--SimpleView
|
+--View
|
+--GraphColumnView
|
+--GraphColumnView2D
- Package:
- stx:libwidg2
- Category:
- Views-Graphs
- Version:
- rev:
1.22
date: 2024/04/11 10:02:39
- user: matilk
- file: GraphColumnView2D.st directory: libwidg2
- module: stx stc-classLibrary: libwidg2
- Author:
- Claus Atzkern
The class provides all the functionality for showing, scrolling and manipulating graphs
described through to a GraphColumn description. Each change in a graph description
immediately take affect.
GraphColumn
GraphColumnView
GraphColumnView3D
defaults
-
gridStep
-
examples
-
test0
-
testing references and actions
start with:
self test0
-
test0b
-
testing references and actions
start with:
self test0b
-
test1
-
testing references and actions
start with:
self test1
-
test2
-
testing models and change notifications
start with:
self test2
-
test3
-
testing models and change notifications
start with:
self test3
-
testRun
-
running view
start with:
self testRun
menu
-
defaultMenu
-
This resource specification was automatically generated
by the MenuEditor of ST/X.
Usage example(s):
MenuEditor new openOnClass:GraphColumnView2D andSelector:#defaultMenu
(Menu new fromLiteralArrayEncoding:(GraphColumnView2D defaultMenu)) startUp
|
-
gridStepMenuSelector: aSelector
-
(self styleMenuSelector:#lineStyle) startUp
plugIn spec
-
aspectSelectors
-
Return a description of exported aspects;
these can be connected to aspects of an embedding application
(if this app is embedded in a subCanvas).
accessing actions
-
action
-
action block which is performed on a single button click.
Number of arguments to the block can be 0 upto 4.
argument 1: nearest column to the click point
argument 2: the logical index (X)
argument 3: the distance y from the click point to the columns's graph
argument 4: physical y value
-
action: aBlockUpTo4Args
-
action block which is performed on a single button click.
Number of arguments to the block can be 0 upto 4.
argument 1: nearest column to the click point
argument 2: the logical index (X)
argument 3: the distance y from the click point to the columns's graph
argument 4: physical y value
-
buttonReleaseBlock
-
action block which is performed if the button is released; the number
of arguments to the block can be 0 upto 3.
argument 1: physical x value
argument 2: physical y value
argument 3: the logical index (X)
-
buttonReleaseBlock: aThreeArgAction
-
action block which is performed if the button is released; the number
of arguments to the block can be 0 upto 3.
argument 1: physical x value
argument 2: physical x value
argument 3: the logical index (X)
-
doubleClickAction
-
action block which is performed on a double button click.
Number of arguments to the block can be 0 upto 4.
argument 1: nearest column to the click point
argument 2: the logical index (X)
argument 3: the distance y from the click point to the columns's graph
argument 4: physical y value
-
doubleClickAction: aBlockUpTo4Args
-
action block which is performed on a double button click.
Number of arguments to the block can be 0 upto 4.
argument 1: nearest column to the click point
argument 2: the logical index (X)
argument 3: the distance y from the click point to the columns's graph
argument 4: physical y value
-
menuAccessBlock
-
action block which is performed if a menu is required; if the block returns
nil, the default middlebutton menu is evaluated.
Number of arguments to the block can be 0 upto 4.
argument 1: nearest column to the click point
argument 2: the logical index (X)
argument 3: the distance y from the click point to the columns's graph
argument 4: physical y value
-
menuAccessBlock: aBlockUpTo4Args
-
action block which is performed if a menu is required; if the block returns
nil, the default middlebutton menu is evaluated.
Number of arguments to the block can be 0 upto 4.
argument 1: nearest column to the click point
argument 2: the logical index (X)
argument 3: the distance y from the click point to the columns's graph
argument 4: physical y value
accessing dimensions
-
gridExtent
-
returns the x/y extent of the grid
-
gridExtent: anExtent
-
set the x/y extent of the grid
-
gridX
-
returns the horizontal size of the grid or 0 if the horizontal grid is disabled
-
gridX: aValue
-
set the horizontal size of the grid or 0 if the horizontal grid should be invisible
-
gridY
-
returns the vertical size of the grid or 0 if the vertical grid is disabled
-
gridY: aValue
-
set the vertical size of the grid or 0 if the vertical grid should be invisible
change & update
-
changedGraphIn: aColumn what: what from: oldValue
-
the graph assigned to the column description changed
-
changedHLineIn: aColumn what: what from: oldValue
-
the horizontal lines assigned to the column description changed
displaying
-
displayOn: aGC
-
ST-80 Compatibility
display the receiver in a graphicsContext at 0@0
- this method allows for any object to be displayed in some view
or on a printer
(although the fallBack is to display its printString ...)
-
displayOn: aGC at: aPoint
-
ST-80 Compatibility
display the receiver in a graphicsContext - this method allows
for any object to be displayed on a Printer - for example.
-
displayOn: aGC x: x y: y
-
ST-80 Compatibility
display the receiver in a graphicsContext - this method allows
for any object to be displayed on a Printer - for example.
-
displayOn: aGC x: x y: y w: w h: h
-
-
image
-
retrieve the current visible contents as bitmap image
drawing
-
clearColumnAndRedraw: aColumn
-
undraw a column and redraw the view without clearing the background
-
redrawColumn: aColumn
-
redraw a column including the horizontal lines
and the graph of the column
-
redrawColumnAt: anIndex
-
redraw a column at an index including the horizontal lines
and the graph of the column
-
redrawX: x y: y width: w height: h
-
clear and redraw
drawing basics
-
drawGRC: aColumn x: xStart step: xStep scaleY: yScale transY: yTrans ydata: yData
-
draw a graph
-
drawGRX: xStart step: xStep scaleY: yScale transY: yTrans ydata: ydata with: aColor style: aStyle width: aWidth
-
draw a graph
-
drawHLC: aColumn x: x y: y toX: xMax y: yMax scaleY: yScale transY: yTrans
-
draw horizontal lines derived from column
-
drawHLN: aList x: x y: y toX: xMax y: yMax scaleY: yScale transY: yTrans with: aColor style: aStyle width: aWidth
-
draw horizontal lines derived from list
-
drawReferencesFromX: x0 y: y0 to: x1 y: y1
-
redraw visible references
-
drawX: x y: y width: w height: h
-
redraw without clearing the background
-
undrawColumn: aColumn scaleY: scaleY transY: transY
-
undraw a column, than redraw all without clearing the background
event handling
-
buttonMultiPress: button x: x y: y
-
handle a button double click event
-
buttonPress: button x: x y: y
-
handle a button press event
-
buttonPressBlock: aBlock x: x y: y
-
evaluate the user defined block if not nil dependent on its required
arguments; the result of the block is returned
-
buttonRelease: button x: x y: y
-
handle a button release event
initialization
-
initialize
-
setup default values
-
unrealize
-
clear colorMap
menu
-
doPrint
-
print the current visible contents on the printer
private
-
mapColor: aColor
-
get the same color on the device. If the argument is
nil, the foreground color is returned.
-
yDataForColumn: aColumn
-
returns collection of visible Y-data for a column
protocol
-
doRecomputeGraph
-
called to recompute drawable objects and to set the graph to invalidate
-
updateColumns: what with: oldValue from: aColumn
-
called if the list of columns changed
#size the size of the columns
#color: color changed
or a specific column:( aColumn notNil )
#insert: insert a new column
#remove: remove a column
or a specific attribute derived from the
changed column.
-
updateOriginX: nIndices
-
scroll left or right n x-steps. A positive value scrolls to the right
a negative value to the left.
-
updateReferences: what atRelX: relX
-
called when the list of references changed.
#remove: the reference at the relative X index is removed
#insert: a reference is inserted at the relative X index
#size the list of references changed
#state visibility state changed
#color the foreground color changed
queries
-
absoluteIndexOfX: x
-
returns the absolute X value for a visible x
-
nearestColumnAtX: x y: y
-
returns an association containing the nearest column as key and the absolute y-distance
to the point x/y. If no columns exists nil is returned
transformations
-
absScaleY: aNumber zoomY: aZoomY
-
returns y-scale for a scale Y and a zoom factor
-
absTransY: aNumber relativeTo: xAxis zoomY: aZoomY
-
returns absolute translation Y for a number relative
to a x-axis
-
scaleYofColumn: aColumn
-
returns current y-scale of a column on my view
-
stepX
-
returns width of X measured in pixels; no fraction returned
-
transYofColumn: aColumn
-
returns current y-translation of a column on my view
user interaction & notifications
-
doGridExtent: what
-
change the grid extent factorial 2 (larger or smaller)
-
doGridStepX: aNumberOrSymbol
-
change the grid step X
-
doGridStepY: aNumberOrSymbol
-
change the grid step Y
|