|
struct | CONSOLE |
| Internal structure. You should not call it directly, use API instead ! More...
|
|
|
| console_clear (csl) |
| Clear a console. More...
|
|
| console_create (chn, x, y, w, h, flag) |
| Initialize the console and create the graphical user interface. More...
|
|
| console_destroy (csl) |
| Destroy a console. More...
|
|
| console_getContent (csl) |
| Return the content of a console. More...
|
|
| console_getMessageNumber (csl) |
| Return the total message number. More...
|
|
| console_gotoline (csl, line) |
| Scroll the graphical interface to a line. More...
|
|
| console_print (csl, msg) |
| Add (print) a message in the given console. More...
|
|
| console_printtxt (csl) |
| Try to print (on the default printer) the content of a console This function should NOT be used ! More...
|
|
| console_save (csl, w) |
| Save the content of a console in a file. If the file will be overwritten, if any. More...
|
|
| console_setTitle (csl, title) |
| Change the title of a console. More...
|
|
This API provides a simple window interface to display any message to the user. This API provides an high level method to easily include a console. Create and manage a simple text window (console) to display any message. Several Console can be used in a same application.
For the application users, a contextual menu is available by right clicking in the bottom of the graphical user interface (below the text field).
Package to load : lib/console/console.pkg
console_getContent |
( |
csl |
| ) |
|
Return the content of a console.
Prototype: fun [CONSOLE] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
- Returns
- S : the content (can be empty)
console_gotoline |
( |
csl |
, |
|
|
line |
|
|
) |
| |
Scroll the graphical interface to a line.
Prototype: fun [CONSOLE I] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
I | : line number (the line number is not necessary equal to the message number) |
- Returns
- I : always 0
Save the content of a console in a file. If the file will be overwritten, if any.
Prototype: fun [CONSOLE W] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
W | : a write-reference file |
- Returns
- I : always 0
Try to print (on the default printer) the content of a console This function should NOT be used !
Prototype: fun [CONSOLE] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
- Returns
- I : always 0
Destroy a console.
Prototype: fun [CONSOLE] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
- Returns
- I : always 0
console_getMessageNumber |
( |
csl |
| ) |
|
Return the total message number.
Prototype: fun [CONSOLE] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
- Returns
- I : always 0
console_setTitle |
( |
csl |
, |
|
|
title |
|
|
) |
| |
Change the title of a console.
Prototype: fun [CONSOLE S] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
S | : a new title |
- Returns
- I : always 0
Clear a console.
Prototype: fun [CONSOLE] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
- Returns
- I : always 0
console_print |
( |
csl |
, |
|
|
msg |
|
|
) |
| |
Add (print) a message in the given console.
Prototype: fun [CONSOLE S] I
- Parameters
-
CONSOLE | : a console. if nil, the last created console is used |
S | : a message |
- Returns
- I : always 0
console_create |
( |
chn |
, |
|
|
x |
, |
|
|
y |
, |
|
|
w |
, |
|
|
h |
, |
|
|
flag |
|
|
) |
| |
Initialize the console and create the graphical user interface.
Prototype: fun [Chn I I I I I] CONSOLE
- Parameters
-
Chn | : a channel (typically, the current channel (_channel)) |
I | : the X position on the screen |
I | : the Y position on the screen |
I | : the width |
I | : the height |
I | : a flag : CONSOLE_SHOW_LINENUM = Display the number (nth) message CONSOLE_HIDE_LINENUM = Hide the number (nth) message |
- Returns
- CONSOLE : the new CONSOLE object