|
Class: TabSpecRuler
Object
|
+--GraphicsMedium
|
+--DisplaySurface
|
+--SimpleView
|
+--TabSpecRuler
- Package:
- stx:libwidg2
- Category:
- Views-Misc
- Version:
- rev:
1.23
date: 2016/07/20 09:36:30
- user: stefan
- file: TabSpecRuler.st directory: libwidg2
- module: stx stc-classLibrary: libwidg2
It shows the tabulator positions of a TabulatorSpecification
and allows its tab positions to be manipulated.
(as shown in a FileBrowser, when the longList is enabled).
[author]
Claus Gittinger
TabulatorSpecification
Ruler
ListView
defaults
-
updateStyleCache
-
(comment from inherited method)
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.
accessing
-
beAsynchronous
-
clear synchronousOperation mode;
if on, a move is immediately forwarded to dependents;
of off, its forwarded when the mouse button is released.
-
beSynchronous
-
set synchronousOperation mode;
if on, a move is immediately forwarded to dependents;
of off, its forwarded when the mouse button is released.
-
fixedTabs
-
return the collection of tabIndices which are fixed;
or nil, if all are variable
-
fixedTabs: something
-
set the collection of tabIndices which are fixed;
nil, if all are to be variable
-
hiddenTabs
-
return the collection of tabs which are to be hidden
(or nil if all are to be shown)
-
hiddenTabs: something
-
set the collection of tabs which are to be hidden
(or nil if all are to be shown)
-
isSynchronous
-
return the synchronousOperation mode settings value
-
masterView: aView
-
set my master view - if non-nil, I will follow the masters scroll-offset
-
synchronousOperation
-
return the synchronousOperation mode settings value
** This is an obsolete interface - do not use it (it may vanish in future versions) **
-
synchronousOperation: something
-
set/clear synchronousOperation mode;
if on, a move is immediately forwarded to dependents;
of off, its forwarded when the mouse button is released.
** This is an obsolete interface - do not use it (it may vanish in future versions) **
-
tabsAreVariable
-
return the value of the instance variable 'tabsAreVariable' (automatically generated)
-
tabsAreVariable: something
-
set/clear movability of tabs. If false, tab positions are only
displayed - but cannot be moved by the user.
The default is true.
-
tabulatorSpecification: aTabSpec
-
set my tabulator specification
-
titles: aCollectionOfStrings
-
event handling
-
buttonMotion: state x: x y: y
-
mouse-button was moved while pressed;
redraw thumb at its new position and, if scroll-mode is asynchronous,
the scroll action is performed
-
buttonPress: button x: x y: y
-
mouse-button was pressed;
start moving the tab
-
buttonRelease: button x: x y: y
-
mouse-button was pressed;
start moving the tab
-
pointerLeave: state
-
mouse left view - restore cursor.
-
update: something with: aParameter from: changedObject
-
initialization
-
initStyle
-
(comment from inherited method)
this method sets up all style dependent things
-
initialize
-
TabSpecRuler new open
private
-
canMoveTabAtX: x
-
-
indexOfTabAtX: x
-
-
moveTabAtIndex: idx toX: movedTabX
-
queries
-
widthOfContents
-
redrawing
-
drawHandleAtX: x type: handleType
-
redraw a tabulator handle
-
positionOfTabAtIndex: idx
-
-
redraw
-
redraw the handles from by tabSpec
-
redrawTabAtIndex: idx
-
redraw a single handle
-
redrawTitleAtIndex: idx
-
redraw a single handle
|top head spec|
top := View new.
top extent:300@100.
head := TabSpecRuler in:top.
head width:1.0.
head level:1.
spec := TabulatorSpecification new.
spec unit:#inch.
spec positions:#(0 1 2.5 3.5 4 5 ).
spec align: #(#left #left #right #right #center #decimal ).
head tabulatorSpecification:spec.
top open.
|
|top head spec|
top := View new.
top extent:300@100.
head := TabSpecRuler in:top.
head width:1.0.
head level:1.
head titles:#('col1' 'col2' 'col3' 'col4' 'col5' 'col6').
spec := TabulatorSpecification new.
spec unit:#inch.
spec positions:#(0 1 2.5 3.5 4 5 ).
spec align: #(#left #left #right #right #center #decimal ).
head tabulatorSpecification:spec.
top open.
|
|