Scol standard library package
0.3.1
Common and usefull functions for all Scol applications
|
Functions | |
lib2d_statusChange (level) | |
Change the current level. More... | |
lib2d_statusDestroy () | |
Destroy the 'status' ''object. More... | |
lib2d_statusGetLevel (list) | |
Get the current level. More... | |
lib2d_statusGetRsc (list) | |
Get the current graphical resources and its level list. More... | |
lib2d_statusNew (oMother, posx, posy) | |
Create a new 'status' ''object. More... | |
lib2d_statusSetRsc (list) | |
Set graphical resources and its level for a 'status'. More... | |
lib2d_workingDestroy () | |
Destroy the object. More... | |
lib2d_workingGetNStep () | |
Get the number of steps. More... | |
lib2d_workingGetPath () | |
Get the 2d resources filename. More... | |
lib2d_workingGetPeriod () | |
Get the period between steps. More... | |
lib2d_workingGetSize () | |
Get the 2d resources element size. More... | |
lib2d_workingGetTransColor () | |
Get the transparency color. More... | |
lib2d_workingGetWindow () | |
Get the child window. More... | |
lib2d_workingNew (oMother, posx, posy) | |
Create a new object. More... | |
lib2d_workingSetCallback (cb) | |
Set the callback. More... | |
lib2d_workingSetNStep (iNstep) | |
Set the number of steps. More... | |
lib2d_workingSetPath (szPath) | |
Set the 2d resources filename. More... | |
lib2d_workingSetPeriod (iPeriod) | |
Set the period between steps. More... | |
lib2d_workingSetSize (iSize) | |
Set the 2d resources element size. More... | |
lib2d_workingSetTransColor (iColor) | |
Set the transparency color. More... | |
Variables | |
var | L2D_STATUS_lRSC |
List of graphical resources and levels. More... | |
typeof | L2D_WORKING_iCOLORTRANSP =I |
Transparency color, if any (default : no transparency color set) | |
var | L2D_WORKING_iNSTEP =10 |
The number of steps. Default : 1. | |
var | L2D_WORKING_iPERIOD =100 |
The period (the time bteween each step). Default : 100 ms. | |
var | L2D_WORKING_iSIZE =36 |
Graphical resource element size, in pixels. | |
var | L2D_WORKING_szPATH ="lib/2dos/rsc/process-working.png" |
Graphical resource filename for show the activity. | |
Package to load : lib/2dos/working.pkg
Dependancies :
lib2d_workingSetPath | ( | szPath | ) |
Set the 2d resources filename.
By default, it is "lib/2dos/rsc/process-working.png"
Prototype : fun [S] I
S | : the new filename to set. |
lib2d_workingGetPath | ( | ) |
Get the 2d resources filename.
Prototype : fun [] S
lib2d_workingSetSize | ( | iSize | ) |
Set the 2d resources element size.
By default, it is 36
Prototype : fun [I] I
I | : the new size to set. |
lib2d_workingGetSize | ( | ) |
Get the 2d resources element size.
Prototype : fun [] I
lib2d_workingSetTransColor | ( | iColor | ) |
Set the transparency color.
By default, it is 36
Prototype : fun [I] I
I | : the new transparency color to set. It can be nil if no transparency to set |
lib2d_workingGetTransColor | ( | ) |
Get the transparency color.
Prototype : fun [] I
lib2d_workingSetNStep | ( | iNstep | ) |
Set the number of steps.
By default, it is 11
Prototype : fun [I] I
I | : the new number to set. |
lib2d_workingGetNStep | ( | ) |
Get the number of steps.
Prototype : fun [] I
lib2d_workingSetPeriod | ( | iPeriod | ) |
Set the period between steps.
By default, it is 11
Prototype : fun [I] I
I | : the new period to set. |
lib2d_workingGetPeriod | ( | ) |
Get the period between steps.
Prototype : fun [] I
lib2d_workingSetCallback | ( | cb | ) |
Set the callback.
This function will be called when a new step is done.
Prototype : fun [fun [I] I] I
fun | [I] I : the callback to set (can be nil (default). Its argument is the step number. |
lib2d_workingGetWindow | ( | ) |
Get the child window.
Prototype : fun [] ObjWin
lib2d_workingNew | ( | oMother | , |
posx | , | ||
posy | |||
) |
Create a new object.
This function should be called AFTER the parameter's setting.
Prototype : fun [ObjWin I I] I
ObjWin | : the mother window |
I | : the x cordinate, relative to the mother |
I | : the y cordinate, relative to the mother |
lib2d_workingDestroy | ( | ) |
Destroy the object.
You should destroy a such object when no longer needed.
All parameters keep available to a next creation. To change them, this API is here !
Prototype : fun [] I
lib2d_statusSetRsc | ( | list | ) |
Set graphical resources and its level for a 'status'.
Each resource should have the same size.
Prototype : fun [[[S I I] r1]] I
[[S | I I] r1] : a list : a resource and a level (min and max) for this resource |
lib2d_statusGetRsc | ( | list | ) |
Get the current graphical resources and its level list.
Prototype : fun [] [[S I] r1]
lib2d_statusGetLevel | ( | list | ) |
Get the current level.
Prototype : fun [] I
lib2d_statusChange | ( | level | ) |
Change the current level.
Prototype : fun [I] I
I | : the level to set |
lib2d_statusNew | ( | oMother | , |
posx | , | ||
posy | |||
) |
Create a new 'status' ''object.
Prototype : fun [ObjWin I I] I
ObjWin | : the mother window |
I | : the x cordinate, relative to the mother |
I | : the y cordinate, relative to the mother |
lib2d_statusDestroy | ( | ) |
Destroy the 'status' ''object.
You should destroy a such object when no longer needed.
All parameters keep available to a next creation. To change them, the API is here !
Prototype : fun [] I
L2D_STATUS_lRSC |
List of graphical resources and levels.