option (see also
DLG) |
name can be either a disk file with preceeding
OPEN, a string, a vector, or a matrix. This is controlled by the choice of Format. |
CALLback |
to extend MatrixExplorer features
- DLG(Edit=filename, Format="4A4", CALLback="mysub", RowTitle="Button:,", ReturnCode=rc, ROW=row, COL=col, RowSel=rs, ColSel=cs)
! numbered buttons as row headers
mysub is a user written subroutine that is called when
- a column or row header control is activated
- an Edit or CHeckbox matrix element is changed
- Button matrix element is hit
-
subroutine mysub
! without arguments and
USE all symbols are global
- USE calling_procedure : rc, row, col, rs, cs
! only needed if the calling procedure is local (with arguments or
USE)
- .......
! do whatever needs to be done
- END
options |
to tell mysub the triggering action |
ColSel |
- cs has the last activated Button/CHeckbox/RADiobutton column number:
- scalar cs: column# for Button and RADio, bitpattern for CHeck-columns 1..32
- vector cs: 0 is not selected, /= 0: selected
|
RowSel |
- rs has the last activated Button/CHeckbox/RADiobutton row number:
- scalar cs: row# for Button and RADio, bitpattern for CHeck-rows 1..32
- vector cs: 0 row is not selected, /= 0: row is selected
|
COL |
col is the column number of the most recently visited matrix element |
ROW |
row is the row number of the most recently visited matrix element |
ReturnCode |
rc = displayed (n rows, m columns)
DLG sequence number of matrix :
- 1001: the OK button
- 1002: the More button
- 1002+1...1002+n: the displayed column headers
- 1002+n+1...1002+n+m: the displayed row headers
- 1002+n+m+1...1002+n+m+n*m: the displayed matrix elements row by row
| |
ColTitle |
-
DLG(..., ColTitle="CNTL:COL:TITLE,",
ColSel=cs)
- CNTL (optional): is either of Text, Button-, CHeckbox-, or RADiobutton (default: Text for arrays, Button for disk files)
⇾ RADio example
- COL (optional): column numbers to rearrange columns (default: natural order),
⇾ column order
- TITLE (optional), define the column titles displayed (default: column numbers),
⇾ title only
|
CoNtrols |
- DLG(Edit=name, Format="F9.2,i12,i4", DNum, cntr="2:TrackBar,MAx=100,DNum=20, 3:Text", ColTitle="Edit+ spinner,TrackBar,Text,")
(Edit) for selected columns (2: and 3:) to a new control (TrackBar and Text)
- Possible modifications for all types: Edit, Text, Button
- for numerical columns:
- ProgressBar, TrackBar, ScrollBar, UpDown
-
MIn,
MAx,
DNum
|
DefHeight |
-
DLG(DefHeight=newH, Edit=..., ...)
change default height of all controls in multiples of default height. For newH >= 2 this will make Edit fields vertically scrollable. |
DNum |
edit spinner change digit number n. For n=0 the edited value is changed by +- 1 |
Format |
-
DLG(...=string_or_array, Format=fmt)
!
|
Height |
displays h rows, default is 10, more can be scrolled with vertical scrollbar |
Line |
-
DLG(..., Line[=delta], ...)
skip delta lines in the
DLG design for preceeding control |
MAx |
upper bound for edit spinners, progressbars, trackbars, scrollbars, updowns |
MIn |
lower bound for edit spinners, progressbars, trackbars, scrollbars, updowns |
RowTitle |
- CNTL (optional): is either of Text, Button-, CHeckbox-, or RADiobutton (default: Text)
⇾ CHeckbox example
- TITLE (optional), define the row titles displayed (default: row numbers)
|
TItle |
dialog caption |
UPDAte |
update
DLG controls
- DLG(TrackBar=xy, Text=xy, UPDAte)
! update Text when TrackBar causes a change
|
Width |
displays w columns, more can be scrolled with horizontal scrollbar |
WINdowhandle |
to continue program execution after opening the dialog. Without WIN: the script waits until
DLG is closed (Note: MatrixExplorer dialogs are always modeless) |
ZeroBlank |
to blank out zeros for better readability in a numerical matrix display |