Function 48
and its subfunctions (0-13)
Subfunction 0 - apply screen settings.
Options:
·
eax =
48 - function number
·
ebx =
0 - number of subfunction
·
ecx =
0 - reserved
Return value:
·
function does not return value
Remarks:
·
The function redraws the screen after changing
parameters with subfunctions 1 and 2.
·
Calling a function without preceding calls to
specified subfunctions is ignored.
·
A function call with non-zero ecx
is ignored.
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_APPLY (0)
Subfunction 1 - set button style
Options:
·
eax =
48 - function number
·
ebx =
1 - number of subfunction
·
ecx =
type of buttons:
o
0 = flat
o
1 = volume
Return value:
·
function does not return value
Remarks:
·
After
calling the described function should redraw the screen subfunction
0.
·
The
type of buttons affects only their drawing function 8.
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_SET_BUTTON_STYLE (1)
Subfunction 2 - set standard window colors
Options:
·
eax =
48 - function number
·
ebx =
2 - subfunction number
·
ecx =
pointer to color table
·
edx =
size of color table (must be 40 bytes for future compatibility) The format of
the color table is specified in the description of subfunction
3.
Return value:
·
function does not return value
Remarks:
·
After
calling the described function, you should redraw the screen with subfunction 0.
·
The
standard color table affects only applications that explicitly receive this
table (subfunction 3) and use it (indicating colors
from it when calling drawing functions).
·
The
standard color table is included in the skin and is reinstalled when the skin
is installed (subfunction 8).
·
The
color chart can be viewed / modified interactively using the desktop
application.
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_SET_COLORS (2)
Subfunction 3 - get standard window colors
Options:
·
eax =
48 - function number
·
ebx =
3 - subfunction number
·
ecx =
pointer to buffer of size edx bytes, where the table
will be written
·
edx =
color table size (must be 40 bytes for future compatibility)
Return value:
·
function does not return value
Color table format: each element - dword color
value 0x00RRGGBB
·
+0: dword: frames - frame
color
·
+4: dword: grab - header
color
·
+8: dword: grab_button - the color of the button on the title bar
·
+12 = + 0xC: dword: grab_button_text - the text color on the button on the
title bar
·
+16 = + 0x10: dword: grab_text - the color of the text on the title
·
+20 = + 0x14: dword: work -
the color of the workspace
·
+24 = + 0x18: dword: work_button - color of the button in the workspace
·
+28 = + 0x1C: dword: work_button_text - the text color on the button in the work
area
·
+32 = + 0x20: dword: work_text - text color in the workspace
·
+36 = + 0x24: dword: work_graph - color of graphics in the workspace
Remarks:
·
The
color table structure is described in the standard included file macros.inc
called system_colors; for example, you can write:
o
sc system_colors ;
variable declaration
o
... ; somewhere you need to call the
function being described with ecx = sc
o
mov ecx, [sc.work_button_text] ;
read the text color on the button in the workspace
·
The
use / non-use of these colors is the business of the
program itself. To use, you just need to specify the color taken from this
table when calling paint functions.
·
When
changing the table of standard colors (subfunction 2
and then applying the changes to subfunction 0 or
when installing the skin with subfunction 8) a
message is sent to all windows about the need for redrawing (event with code
1).
·
Standard
colors can be viewed / modified interactively using the desktop application.
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_GET_COLORS (3)
Subfunction 4 - get skin height
Options:
·
eax =
48 - function number
·
ebx =
4 - subfunction number
Return value:
·
eax =
skin height
Remarks:
·
Skin
height, by definition, is considered to be the height of the header of windows
that use skin.
·
See
also the general structure of the window in the description of the function 0.
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_GET_SKIN_HEIGHT (4)
Subfunction 5 - get the working area of the screen
Options:
·
eax =
48 - function number
·
ebx =
5 - subfunction number
Return value:
·
eax =
[left] * 65536 + [right]
·
ebx =
[top] * 65536 + [bottom]
Remarks:
·
The
working area of the screen determines the position and
coordinates of the maximized window.
·
The
working area of the screen during normal operation is the entire
screen minus the panel (@taskbar).
·
(left,
top) - coordinates of the upper left corner, (right,
bottom) - coordinates of the lower right. Thus, the size of the working area
along the x axis is determined by the formula right-left + 1, along the y axis
by the formula bottom-right + 1.
·
See
also function 14, which allows you to determine the size of the entire screen.
·
There
is a pair function of setting the workspace - subfunction
6.
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_GET_SCREEN_AREA (5)
Subfunction 6 - set the working area of the screen
Options:
·
eax =
48 - function number
·
ebx =
6 - subfunction number
·
ecx =
[left] * 65536 + [right]
·
edx =
[top] * 65536 + [bottom]
Return value:
·
function does not return value
Remarks:
·
The
working area of the screen determines the position and
coordinates of the maximized window.
·
This
function is used only by the @taskbar application, which sets the working area
to the entire screen minus the panel.
·
(left,
top) - coordinates of the upper left corner, (right,
bottom) - coordinates of the lower right. Thus, the size of the working area
along the x axis is determined by the formula right-left + 1, along the y axis
by the formula bottom-right + 1.
·
If
left> = right, then the x-coordinates of the working area do not change. If
left <0, then left is not set. If right> = screen width, then right is
not set. Similarly on the y axis.
·
See
also function 14, which allows you to determine the size of the entire screen.
·
There
is a pair function of receiving the working area - subfunction
5.
·
This
feature automatically redraws the screen, along the way updates the coordinates
and dimensions of the maximized windows. All windows are notified of the need
to redraw (event 1).
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_SET_SCREEN_AREA (6)
Subfunction 7 - Get skin area for header text.
Returns the title pane of the skin window for
displaying the title text.
Options:
·
eax =
48 - function number
·
ebx =
7 - subfunction number
Return value:
·
eax =
[left] * 65536 + [right]
·
ebx =
[top] * 65536 + [bottom]
Remarks:
·
Using
/ not using this function is a personal file of the application.
·
It
is recommended to take into account the values returned by this
function when choosing a place to draw the title text (function 4) or some kind
of title text substitute (at the discretion of the application).
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_GET_SKIN_MARGINS (7)
Subfunction 8 - set the used window skin
Options:
·
eax =
48 - function number
·
ebx =
8 - number of subfunction
·
ecx =
pointer to the name of the skin file
Return value:
·
eax =
0 - successful
·
eax =
1 - failed to load file
·
eax =
2 - the file is not a skin file
Remarks:
·
Upon
successful loading of the skin, all windows are informed about the need to
redraw (event 1).
·
When
loading, the system reads the skin from the default.skn
file on the ramdisk.
·
The
user can change the skin statically by creating his default.skn,
or dynamically using the desktop application.
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_SET_SKIN (8)
Subfunction 9 - get font
smoothing setting
Options:
·
eax =
48 - function number
·
ebx =
9 - subfunction number
Return value:
·
eax =
2 - subpixel, 1 - normal, 0 - off
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_GET_FONT_SMOOTH (9)
Subfunction 10 - configure font
smoothing
Options:
·
eax =
48 - function number
·
ebx =
10 - subfunction number
·
cl = 2 - subpixel, 1 -
normal, 0 - off
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_SET_FONT_SMOOTH (10)
Subfunction 11 - get font size
Options:
·
eax =
48 - function number
·
ebx =
9 - subfunction number
Return value:
·
eax =
current font height in pixels
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_GET_FONT_SIZE (11)
Subfunction 12 - set the font
size
Options:
·
eax =
48 - function number
·
ebx =
10 - subfunction number
·
cl = new font height in pixels
Constants for registers:
eax -
SF_STYLE_SETTINGS (48)
ebx -
SSF_SET_FONT_SIZE (12)
Subfunction 13 - install skin
with encoding indication
Options:
·
eax =
48 - function number
·
ebx =
13 - number of subfunction
·
ecx =
pointer to the string with the path to the skin file
·
edx =
string encoding, details are provided in function 80 description.
Return value:
·
eax =
0 - successful
·
eax =
1 - failed to load file
·
eax =
2 - the file is not a skin file
Remarks:
·
Upon
successful loading of the skin, all windows are informed about the need to
redraw (event 1).
·
When
loading, the system reads the skin from the default.skn
file on the ramdisk.
·
The
user can change the skin statically by creating his default.skn,
or dynamically using the desktop application.