/programs/develop/fasm/1.73/kolibri/equates/box_lib.inc |
---|
0,0 → 1,55 |
;equates for EDIT_BOX |
ED_PASS = 0001h |
ED_FOCUS = 0002h |
ED_SHIFT = 0004h |
ED_SHIFT_ON = 0008h |
ED_SHIFT_BAC = 0010h |
ED_LEFT_FL = 0020h |
ED_OFFSET_FL = 0040h |
ED_INSERT = 0080h |
ED_MOUSE_ON = 0100h |
ED_CTRL_ON = 0200h |
ED_ALT_ON = 0400h |
ED_DISABLED = 0800h |
ED_ALWAYS_FOCUS = 4000h |
ED_FIGURE_ONLY = 8000h |
ED_MOUS_ADN_B = ED_MOUSE_ON or ED_SHIFT_ON or ED_SHIFT_BAC |
ED_SHIFT_OFF = not ED_SHIFT |
ED_SHIFT_MCL = not ED_SHIFT |
ED_SHIFT_ON_OFF = not ED_SHIFT_ON |
ED_SHIFT_BAC_CL = not ED_SHIFT_BAC |
ED_SHIFT_CL = not (ED_SHIFT or ED_SHIFT_ON or ED_SHIFT_BAC) |
ED_RIGHT_FL = not ED_LEFT_FL |
ED_OFFSET_CL = not ED_OFFSET_FL |
ED_INSERT_CL = not ED_INSERT |
ED_MOUSE_ON_OFF = not ED_MOUSE_ON |
ED_CTRL_OFF = not ED_CTRL_ON |
ED_ALT_OFF = not ED_ALT_ON |
;equates for CHECK_BOX2 |
CB_FLAG_TOP = 0 |
CB_FLAG_EN = 2 |
CB_FLAG_MIDDLE = 4 |
CB_FLAG_BOTTOM = 8 |
; equates for TREE_LIST |
TL_KEY_NO_EDIT = 0001h |
TL_DRAW_PAR_LINE = 0002h |
TL_LIST_BOX_MODE = 0004h |
TL_ERR_LOAD_CAPTION = 0001h |
TL_ERR_SAVE_MEMORY_SIZE = 0002h |
TL_ERR_LOAD_INFO_SIZE= 0004h |
TL_LOAD_MODE_ADD =20000h |
TL_SAVE_LOAD_HEDER_SIZE = 26 |
TL_OFFS_BOX = 0 |
; equates for TEXT_EDITOR |
TED_OPT_ED_MOVE_CURSOR = 0001h |
TED_OPT_ED_CHANGE_TIME = 0002h |
/programs/develop/fasm/1.73/kolibri/equates/kernel.inc |
---|
0,0 → 1,39 |
; events |
EV_IDLE = 0 |
EV_TIMER = 0 |
EV_REDRAW = 1 |
EV_KEY = 2 |
EV_BUTTON = 3 |
EV_EXIT = 4 |
EV_BACKGROUND = 5 |
EV_MOUSE = 6 |
EV_IPC = 7 |
EV_STACK = 8 |
; event mask bits for function 40 |
EVM_REDRAW = 1b |
EVM_KEY = 10b |
EVM_BUTTON = 100b |
EVM_EXIT = 1000b |
EVM_BACKGROUND = 10000b |
EVM_MOUSE = 100000b |
EVM_IPC = 1000000b |
EVM_STACK = 10000000b |
EVM_DEBUG = 100000000b |
EVM_STACK2 = 1000000000b |
EVM_MOUSE_FILTER = 0x80000000 |
EVM_CURSOR_FILTER = 0x40000000 |
; create window constants |
CW_CAPTION = $10000000 |
CW_CLIENTRECTCOORDS = $20000000 |
CW_TRANSPARENT = $40000000 |
CW_GRADIENTFILL = $80000000 |
CW_DONTDRAW = $01000000 |
CW_SKINED = $03000000 |
CW_SKINEDFIXED = $04000000 |
CW_UNMOVABLE = $01000000 |
; colors |
CLR_BLACK = $00000000 |
/programs/develop/fasm/1.73/kolibri/equates/proc_lib.inc |
---|
0,0 → 1,12 |
; equates for OpenDialog |
; OpenDialog type |
ODT_OPEN = 0 |
ODT_SAVE = 1 |
ODT_DIR = 2 |
; OpenDialog status |
ODS_CANCEL = 0 |
ODS_OK = 1 |
ODS_ALTER = 2 |
/programs/develop/fasm/1.73/kolibri/equates/syscalls.inc |
---|
0,0 → 1,292 |
; KolibriOS system functions: |
SF_TERMINATE_PROCESS=-1 |
SF_CREATE_WINDOW=0 ; define and draw the window |
SF_PUT_PIXEL=1 ; draw pixel to the window |
SF_GET_KEY=2 ; get code of the pressed key |
SF_GET_SYS_TIME=3 |
SF_DRAW_TEXT=4 |
SF_SLEEP=5 ; pause process |
SF_PUT_IMAGE=7 ; draw image to the window |
SF_DEFINE_BUTTON=8 ; define/delete the button |
SF_THREAD_INFO=9 ; information on execution thread |
SF_WAIT_EVENT=10 ; wait for event |
SF_CHECK_EVENT=11 ; check for event and return |
SF_REDRAW=12 |
SSF_BEGIN_DRAW=1 |
SSF_END_DRAW=2 |
SF_DRAW_RECT=13 ; draw rectangle to the window |
SF_GET_SCREEN_SIZE=14 ; get screen resolution |
SF_BACKGROUND_SET=15 ; work with desktop background graphics |
SSF_SIZE_BG=1 ; set a size of the background image |
SSF_PIXEL_BG=2 ; put pixel on the background image |
SSF_REDRAW_BG=3 ; redraw background |
SSF_MODE_BG=4 ; set drawing mode for the background |
SSF_IMAGE_BG=5 ; put block of pixels on the background image |
SSF_MAP_BG=6 ; map background image to the address space of the process |
SSF_UNMAP_BG=7 ; close mapped background data |
SSF_LAST_DRAW=8 ; get coordinates of the last draw to the background |
SSF_REDRAW_RECT=9 ; redraws a rectangular part of the background |
SF_RD_TO_FLOPPY=16 ; save ramdisk on the floppy |
SF_GET_BUTTON=17 ; get ID of the pressed button |
SF_SYSTEM=18 |
SSF_UNFOCUS_WINDOW=1 ; take focus from the window of the given thread |
SSF_TERMINATE_THREAD=2 ; terminate process/thread by the slot number |
SSF_FOCUS_WINDOW=3 ; give focus to the window of the given thread |
SSF_GET_IDLE_COUNT=4 ; get counter of idle cycles per second |
SSF_GET_CPU_FREQUENCY=5 ; get CPU clock rate |
SSF_RD_TO_HDD=6 ; save ramdisk to the file on hard disk |
SSF_GET_ACTIVE_WINDOW=7 ; get slot number of the active window |
SSF_SPEAKER=8 |
SSSF_GET_STATE=1 |
SSSF_TOGGLE=2 |
SSF_SHUTDOWN=9 ; system shutdown/reboot |
SSF_MINIMIZE_WINDOW=10 ; minimize active window |
SSF_INFO_DISC_SYS=11 ; get disk subsystem information |
SSF_KERNEL_VERSION=13 ; get kernel version |
SSF_WAIT_RETRACE=14 ; wait for screen retrace |
SSF_CURSOR_CENTER=15 ; center mouse cursor on the screen |
SSF_GET_FREE_RAM=16 ; get size of free RAM |
SSF_GET_TOTAL_RAM=17 ; get total amount of RAM |
SSF_TERMINATE_THREAD_ID=18 ; Terminate process/thread by the ID |
SSF_MOUSE_SETTINGS=19 |
SSSF_GET_SPEED=0 |
SSSF_SET_SPEED=1 |
SSSF_GET_SPEEDUP=2 |
SSSF_SET_SPEEDUP=3 ; set mouse acceleration |
SSSF_SET_POS=4 ; set mouse pointer position |
SSSF_SET_BUTTON=5 ; simulate state of mouse buttons |
SSSF_GET_DOUBLE_CLICK_DELAY=6 |
SSSF_SET_DOUBLE_CLICK_DELAY=7 |
SSF_GET_RAM_INFO=20 ; get information on RAM |
SSF_GET_THREAD_SLOT=21 ; get slot number of process/thread by the ID |
SSF_FOREIGN_WINDOW=22 ; operations with window of another thread by slot/ID |
SSSF_MINIMIZE=0 |
SSSF_MINIMIZE_ID=1 |
SSSF_RESTORE=2 |
SSSF_RESTORE_ID=3 |
SSF_MINIMIZE_ALL=23 |
SSF_SET_SCREEN_LIMITS=24 |
SSF_WINDOW_BEHAVIOR=25 ; window focus relation with other windows |
SSSF_GET_WB=1 |
SSSF_SET_WB=2 |
SF_MIDI=20 |
SSF_RESET=1 |
SSF_OUTPUT=2 |
SF_SYSTEM_SET=21 |
SSF_MPU_MIDI_BASE=1 |
SSF_KEYBOARD_LAYOUT=2 |
SSF_SYS_LANG=5 |
SSF_ACCESS_HD_LBA=11 ; setting of low-level access to HD |
SSF_ACCESS_PCI=12 ; setting of low-level access to PCI |
SF_SET_TIME_DATE=22 |
SF_WAIT_EVENT_TIMEOUT=23; wait for event with timeout |
SF_CD=24 |
SSF_EJECT_TRAY=4 |
SSF_INSERT_TRAY=5 |
SF_SCREEN_PUT_IMAGE=25 ; put image on the background layer |
SF_SYSTEM_GET=26 |
; Same as SF_SYSTEM_SET, plus: |
SSF_TIME_COUNT=9 |
SSF_TIME_COUNT_PRO=10 ; get value of the high precision time counter |
SF_GET_SYS_DATE=29 |
SF_CURRENT_FOLDER=30 |
SSF_SET_CF=1 ; set current folder for the thread |
SSF_GET_CF=2 |
SSF_ADD_SYS_FOLDER=3 ; install the add.system directory for the kernel |
SF_GET_PIXEL_OWNER=34 ; get slot number of the screen pixel owner |
SF_GET_PIXEL=35 ; read the screen pixel color |
SF_GET_IMAGE=36 ; read the screen area |
SF_MOUSE_GET=37 |
SSF_SCREEN_POSITION=0 |
SSF_WINDOW_POSITION=1 |
SSF_BUTTON=2 ; states of the mouse buttons |
SSF_BUTTON_EXT=3 ; states and events of the mouse buttons |
SSF_LOAD_CURSOR=4 |
SSF_SET_CURSOR=5 |
SSF_DEL_CURSOR=6 |
SSF_SCROLL_DATA=7 |
SF_DRAW_LINE=38 |
SF_BACKGROUND_GET=39 |
;SSF_SIZE_BG=1 |
;SSF_PIXEL_BG=2 |
;SSF_MODE_BG=4 |
SF_SET_EVENTS_MASK=40 ; turn on/off desired events |
SF_PORT_IN_OUT=43 ; input/output to a port |
SF_SET_PORTS=46 ; reserve/free a group of input/output ports |
SF_DRAW_NUMBER=47 ; draw number to the window |
SF_STYLE_SETTINGS=48 |
SSF_APPLY=0 ; apply screen settings |
SSF_SET_BUTTON_STYLE=1 |
SSF_SET_COLORS=2 |
SSF_GET_COLORS=3 ; get standard window colors |
SSF_GET_SKIN_HEIGHT=4 |
SSF_GET_SCREEN_AREA=5 ; get screen working area |
SSF_SET_SCREEN_AREA=6 |
SSF_GET_SKIN_MARGINS=7 |
SSF_SET_SKIN=8 |
SSF_GET_FONT_SMOOTH=9 |
SSF_SET_FONT_SMOOTH=10 |
SSF_GET_FONT_SIZE=11 |
SSF_SET_FONT_SIZE=12 |
SF_APM=49 |
SF_SET_WINDOW_SHAPE=50 |
SF_CREATE_THREAD=51 |
SF_CLIPBOARD=54 |
SSF_GET_SLOT_COUNT=0 ; get the number of slots in the clipboard |
SSF_READ_CB=1 |
SSF_WRITE_CB=2 |
SSF_DEL_SLOT=3 ; delete the last slot in the clipboard |
SSF_UNLOCK_BUFFER=4 ; emergency buffer unlock |
SF_SPEAKER_PLAY=55 |
SF_PCI_BIOS=57 |
SF_IPC=60 ; Inter Process Communication |
SSF_SET_AREA=1 ; set area for IPC receiving |
SSF_SEND_MESSAGE=2 |
SF_GET_GRAPHICAL_PARAMS=61 |
SSF_SCREEN_SIZE=1 |
SSF_BITS_PER_PIXEL=2 |
SSF_BYTES_PER_LINE=3 |
SF_PCI=62 |
SSF_GET_VERSION=0 ; get version of PCI-interface |
SSF_GET_LAST_BUS=1 ; get number of the last PCI-bus |
SSF_GET_ADRR_MODE=2 ; get addressing mode of the PCI configuration space |
SSF_READ_BYTE=4 |
SSF_READ_WORD=5 |
SSF_READ_DWORD=6 |
SSF_WRITE_BYTE=8 |
SSF_WRITE_WORD=9 |
SSF_WRITE_DWORD=10 |
SF_BOARD=63 |
SSF_DEBUG_WRITE=1 |
SSF_DEBUG_READ=2 |
SF_MEMORY_RESIZE=64 ; resize total application memory |
SF_PUT_IMAGE_EXT=65 ; draw image with palette to the window |
SF_KEYBOARD=66 |
SSF_SET_INPUT_MODE=1 |
SSF_GET_INPUT_MODE=2 |
SSF_GET_CONTROL_KEYS=3; get status of control keys |
SSF_SET_SYS_HOTKEY=4 |
SSF_DEL_SYS_HOTKEY=5 |
SSF_LOCK_INPUT=6 ; block normal input |
SSF_UNLOCK_INPUT=7 ; restore normal input |
SF_CHANGE_WINDOW=67 ; change position/sizes of the window |
SF_SYS_MISC=68 |
SSF_GET_TASK_SWITCH_COUNT=0 |
SSF_SWITCH_TASK=1 |
SSF_PERFORMANCE=2 |
SSSF_ALLOW_RDPMC=0 |
SSSF_CACHE_STATUS=1 |
SSSF_CACHE_ON=2 |
SSSF_CACHE_OFF=3 |
SSF_READ_MSR=3 |
SSF_WRITE_MSR=4 |
SSF_HEAP_INIT=11 |
SSF_MEM_ALLOC=12 |
SSF_MEM_FREE=13 |
SSF_WAIT_SIGNAL=14 ; wait for signal from another program/driver |
SSF_LOAD_DRIVER=16 |
SSF_CONTROL_DRIVER=17 |
SSF_LOAD_DLL=19 |
SSF_MEM_REALLOC=20 |
SSF_LOAD_DRIVER_PE=21 |
SSF_MEM_OPEN=22 ; open named memory area |
SSF_MEM_CLOSE=23 |
SSF_SET_EXCEPTION_HANDLER=24 |
SSF_SET_EXCEPTION_STATE=25 |
SSF_MEM_FREE_EXT=26 |
SSF_LOAD_FILE=27 |
SF_DEBUG=69 |
SSF_SET_MESSAGE_AREA=0 |
SSF_GET_REGISTERS=1 |
SSF_SET_REGISTERS=2 |
SSF_DETACH=3 |
SSF_SUSPEND=4 |
SSF_RESUME=5 |
SSF_READ_MEMORY=6 |
SSF_WRITE_MEMORY=7 |
SSF_TERMINATE=8 |
SSF_DEFINE_BREAKPOINT=9 |
SF_FILE=70 |
SSF_READ_FILE=0 |
SSF_READ_FOLDER=1 |
SSF_CREATE_FILE=2 |
SSF_WRITE_FILE=3 |
SSF_SET_END=4 |
SSF_GET_INFO=5 |
SSF_SET_INFO=6 |
SSF_START_APP=7 |
SSF_DELETE=8 |
SSF_CREATE_FOLDER=9 |
SF_SET_CAPTION=71 |
SF_SEND_MESSAGE=72 |
SF_BLITTER=73 |
SF_NETWORK_GET=74 |
SSF_DEVICE_COUNT=255 ; get number of active network devices |
SSF_DEVICE_TYPE=0 |
SSF_DEVICE_NAME=1 |
SSF_RESET_DEVICE=2 |
SSF_STOP_DEVICE=3 |
SSF_DEVICE_POINER=4 |
SSF_TX_PACKET_COUNT=6 |
SSF_RX_PACKET_COUNT=7 |
SSF_TX_BYTE_COUNT=8 |
SSF_RX_BYTE_COUNT=9 |
SSF_LINK_STATUS=10 |
SF_NETWORK_SOCKET=75 |
SSF_OPEN=0 |
SSF_CLOSE=1 |
SSF_BIND=2 |
SSF_LISTEN=3 |
SSF_CONNECT=4 |
SSF_ACCEPT=5 |
SSF_SEND=6 |
SSF_RECEIVE=7 |
SSF_SET_OPTIONS=8 |
SSF_GET_OPTIONS=9 |
SSF_GET_PAIR=10 |
SF_NETWORK_PROTOCOL=76 |
SSF_ETHERNET_READ_MAC=0 |
SSF_IP4_PACKETS_SENT=10000h |
SSF_IP4_PACKETS_RECEIVED=10001h |
SSF_IP4_READ_IP=10002h |
SSF_IP4_WRITE_IP=10003h |
SSF_IP4_READ_DNS=10004h |
SSF_IP4_WRITE_DNS=10005h |
SSF_IP4_READ_SUBNET=10006h |
SSF_IP4_WRITE_SUBNET=10007h |
SSF_IP4_READ_GATEWAY=10008h |
SSF_IP4_WRITE_GATEWAY=10009h |
SSF_ICMP_PACKETS_SENT=20000h |
SSF_ICMP_PACKETS_RECEIVED=20001h |
SSF_ICMP_ECHO_REPLY=20003h |
SSF_UDP_PACKETS_SENT=30000h |
SSF_UDP_PACKETS_RECEIVED=30001h |
SSF_TCP_PACKETS_SENT=40000h |
SSF_TCP_PACKETS_RECEIVED=40001h |
SSF_ARP_PACKETS_SENT=50000h |
SSF_ARP_PACKETS_RECEIVED=50001h |
SSF_ARP_GET_ENTRY_COUNT=50002h |
SSF_ARP_READ_ENTRY=50003h |
SSF_ARP_ADD_STATIC_ENTRY=50004h |
SSF_ARP_DEL_ENTRY=50005h |
SSF_ARP_SEND_ANNOUNCE=50006h |
SSF_ARP_CONFLICTS_COUNT=50007h |
SF_FUTEX=77 |
SSF_CREATE=0 |
SSF_DESTROY=1 |
SSF_WAIT=2 |
SSF_WAKE=3 |
; File system errors: |
FSERR_SUCCESS=0 |
FSERR_UNSUPPORTED=2 |
FSERR_UNKNOWN=3 |
FSERR_FILE_NOT_FOUND=5 |
FSERR_END_OF_FILE=6 |
FSERR_INVALID_BUFFER=7 |
FSERR_DISK_FULL=8 |
FSERR_FAIL=9 |
FSERR_ACCESS_DENIED=10 |
FSERR_DEVICE_FAIL=11 |
FSERR_OUT_OF_MEMORY=12 |
/programs/develop/fasm/1.73/kolibri/kex/export.inc |
---|
0,0 → 1,13 |
; Macroinstructions for making exports data structure |
macro export [name,sname] |
{ |
forward |
dd __#name#_export_name__,name |
common |
dd 0 |
forward |
align 4 |
__#name#_export_name__ db sname,0 |
} |
/programs/develop/fasm/1.73/kolibri/kex/import.inc |
---|
0,0 → 1,49 |
; Macroinstructions for making import section |
macro library [name,string] |
{ common |
import.data: |
forward |
local _label |
if defined name#.lookup |
if name#.lookup.size |
dd name#.lookup,_label |
end if |
end if |
name#.referred = 1 |
common |
dd 0 |
forward |
if defined name#.lookup |
if name#.lookup.size |
align 4 |
db '/sys/lib/' |
_label db string,0 |
end if |
end if } |
macro import name,[label,string] |
{ common |
align 4 |
if defined name#.referred |
name#.lookup: |
forward |
if used label |
local _label |
label dd _label |
end if |
common |
if $ > name#.lookup |
dd 0 |
end if |
name#.lookup.size=$ - name#.lookup |
forward |
if used label |
align 4 |
_label db string,0 |
end if |
common |
end if } |
macro api [name] {} |
/programs/develop/fasm/1.73/kolibri/macro/config.inc |
---|
0,0 → 1,0 |
__CPU_type fix p5 |
/programs/develop/fasm/1.73/kolibri/macro/proc.inc |
---|
0,0 → 1,48 |
; Macroinstructions for calling procedures (without defining) |
macro stdcall proc,[arg] ; directly call STDCALL procedure |
{ common |
if ~ arg eq |
reverse |
pushd arg |
common |
end if |
call proc } |
macro invoke proc,[arg] ; indirectly call STDCALL procedure |
{ common |
if ~ arg eq |
reverse |
pushd arg |
common |
end if |
call [proc] } |
macro ccall proc,[arg] ; directly call CDECL procedure |
{ common |
size@ccall = 0 |
if ~ arg eq |
reverse |
pushd arg |
size@ccall = size@ccall+4 |
common |
end if |
call proc |
if size@ccall |
add esp,size@ccall |
end if } |
macro cinvoke proc,[arg] ; indirectly call CDECL procedure |
{ common |
size@ccall = 0 |
if ~ arg eq |
reverse |
pushd arg |
size@ccall = size@ccall+4 |
common |
end if |
call [proc] |
if size@ccall |
add esp,size@ccall |
end if } |
/programs/develop/fasm/1.73/kolibri/macro/struct.inc |
---|
0,0 → 1,476 |
; Macroinstructions for defining data structures |
macro struct@overridedefs [datadef] { |
struc datadef [val:?] \{ \common |
match any:no,force@alignment:@rstruct \\{ define field@struct -,align,datadef#.align \\} |
define field@struct .,datadef,<val> \} |
macro datadef [val:?] \{ \common |
match any:no,force@alignment:@rstruct \\{ define field@struct -,align,datadef#.align \\} |
define field@struct -,datadef,<val> \} } |
;============================================================== |
macro struct@overridersvs [datadef] { |
match ddd,def.#datadef \{ |
struc datadef count \\{ \\common |
match any:no,force@alignment:@rstruct \\\{ define field@struct -,align,ddd\#.align \\\} |
define field@struct .,ddd,count dup (?) \\} |
macro datadef count \\{ \\common |
match any:no,force@alignment:@rstruct \\\{ define field@struct -,align,ddd\#.align \\\} |
define field@struct -,ddd,count dup (?) \\} \} } |
;============================================================== |
macro struct@overridealgn [datadef] { |
struc datadef amount:default.#datadef \{ define field@struct -,datadef,amount \} |
macro datadef amount:default.#datadef \{ define field@struct -,datadef,amount \} } |
;============================================================== |
macro struct@restoredefs [datadef] { |
restruc datadef |
purge datadef } |
;============================================================== |
; GLOBAL ASSUMPTIONS FOR THIS MACRO SET |
; THERE IS NO PRACTICAL SENSE TO ENCLOSE IN UNION OR STRUCT NO ONE FIELD |
; THERE IS NO PRACTICAL SENSE TO ENCLOSE IN SUBUNION OR SUBSTRUCT ONLY 1 FIELD OR EVEN NO ONE |
; THERE IS NO PRACTICAL SENSE TO ENCLOSE IN SUBUNION ONLY UNNAMED FIELDS |
;============================================================== |
macro struct definition { |
match name tail, definition: \{ |
virtual |
db \`name |
load initial@struct byte from $$ |
if initial@struct = '.' |
display 'Error: name of structure should not begin with a dot.',0Dh,0Ah |
err |
end if |
end virtual |
macro ends \\{ |
match , sub@struct \\\{ |
if $ |
display 'Error: definition of ',\`name,' contains illegal instructions.',0Dh,0Ah |
err |
end if |
match any,datadef@directives \\\\{ struct@restoredefs any \\\\} |
match any,datarsv@directives \\\\{ struct@restoredefs any \\\\} |
match any,algnmnt@directives \\\\{ struct@restorealgn any \\\\} |
purge union,struct,rstruct,ends |
irpv fields,field@struct \\\\{ |
restore field@struct |
\\\\common |
restore @struct |
make@struct name,fields |
define fields@\#name fields \\\\} |
end virtual \\\} ;end virtual must be after make@struct |
match any, sub@struct \\\{ |
tmp@struct equ field@struct |
restore field@struct |
field@struct equ tmp@struct> \\\} |
restore sub@struct \\} |
;match :,tail \\{ \\} |
match parent:,tail \\{ field@struct equ fields@\\#parent \\} \} |
match any,datadef@directives \{ struct@overridedefs any \} |
match any,datarsv@directives \{ struct@overridersvs any \} |
match any,algnmnt@directives \{ struct@overridealgn any \} |
irp datadef,union,struct,rstruct \{ |
macro datadef \\{ |
field@struct equ ,sub\#datadef,< |
sub@struct equ sub\#datadef \\} \} |
define @struct |
sub@struct equ |
virtual at 0 } |
;============================================================== |
macro union definition { |
struct definition |
define @union } |
;============================================================== |
macro rstruct definition { |
struct definition |
define @rstruct } |
;============================================================== |
macro make@struct name,[field,type,def] { |
common |
local CONVERTED,PREVIOUS,CURRENT |
define CONVERTED name |
define CURRENT 1 |
forward |
PREVIOUS equ CURRENT |
define CURRENT 1 |
local sub |
match , field \{ define CURRENT 2 |
make@substruct type,name,sub def \} |
match -, field \{ define CURRENT 0 \} |
match =1:=0, PREVIOUS:CURRENT \{ CONVERTED equ CONVERTED, < <type def> \} |
match =0:=0, PREVIOUS:CURRENT \{ CONVERTED equ CONVERTED , <type def> \} |
match =1:=1, PREVIOUS:CURRENT \{ CONVERTED equ CONVERTED, , .#field, type, <def> \} |
match =0:=1, PREVIOUS:CURRENT \{ CONVERTED equ CONVERTED >, .#field, type, <def> \} |
match =1:=2, PREVIOUS:CURRENT \{ CONVERTED equ CONVERTED, , ., sub, \} |
match =0:=2, PREVIOUS:CURRENT \{ CONVERTED equ CONVERTED >, ., sub, \} |
match =2, CURRENT \{ define CURRENT 1 \} |
common |
local anonymous |
match =0, CURRENT \{ CONVERTED equ CONVERTED >, anonymous,:, \} |
match converted, CONVERTED \{ |
match no:no, @union:@rstruct \\{ define@struct converted \\} |
match no:, @union:@rstruct \\{ |
restore @rstruct |
define@rstruct converted \\} |
match :no, @union:@rstruct \\{ |
restore @union |
define@union converted \\} \} } |
;============================================================== |
macro define@union name,[anon,field,type,def] { |
forward |
match any, anon \{ |
irp anondef,any \\{ |
\\local anonsize |
virtual at 0 |
anondef |
anonsize = $ |
end virtual |
if anonsize > $ |
rb anonsize - $ |
end if |
\\} \} |
if ~ field eq . |
virtual at 0 |
name#field type def |
sizeof.#name#field = $ - name#field |
end virtual |
if sizeof.#name#field > $ |
rb sizeof.#name#field - $ |
end if |
else |
virtual at 0 |
label name#.#type |
rb sizeof.#type |
end virtual |
if sizeof.#type > $ |
rb sizeof.#type - $ |
end if |
end if |
common |
sizeof.#name = $ |
restruc name |
struc name value \{ |
\local \..base |
match , @struct \\{ define field@struct .,name,value \\} |
match no, @struct \\{ |
label \..base |
last@union equ |
forward |
match any, last@union \\\{ |
virtual at \..base |
field type def |
end virtual \\\} |
match , last@union \\\{ |
match , value \\\\{ field type def \\\\} |
match any, value \\\\{ field type value \\\\} \\\} |
last@union equ field |
common |
if sizeof.#name > $ - \..base |
rb sizeof.#name - ($ - \..base) |
end if |
label . at \..base \\} |
\} |
macro name value \{ |
\local \..base |
match , @struct \\{ define field@struct -,name,value \\} |
match no, @struct \\{ |
label \..base |
last@union equ |
forward |
match , last@union \\\{ match any, value \\\\{ field type value \\\\} \\\} |
last@union equ field |
common |
if sizeof.#name > $ - \..base |
rb sizeof.#name - ($ - \..base) |
end if \\} \} } |
;============================================================== |
macro define@rstruct name,[anon,field,type,def] { |
common |
local list,..start,..size |
list equ |
virtual at -..size |
..start: |
forward |
local anonsize |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
anonsize = $ |
match any, anon \{ irp anondef,any \\{ anondef \\} \} |
anonsize = $-anonsize |
; END OF ASSUMPTION |
if ~ field eq . |
name#field type def |
sizeof.#name#field = $ - name#field |
else |
label name#.#type |
rb sizeof.#type |
end if |
local value |
match any, list \{ list equ list, \} |
list equ list <value> |
common |
..size = $ - ..start |
end virtual |
sizeof.#name = ..size |
restruc name |
match values, list \{ |
struc name value \\{ |
match , @struct \\\{ define field@struct .,name,<values> \\\} |
match no, @struct \\\{ |
forward |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
rb anonsize |
; END of ASSUMPTION |
match , value \\\\{ field type def \\\\} |
match any, value \\\\{ |
field type value |
if ~ field eq . ; MAIN PURPOSE OF THEESE 3 LINES - REALISATION OF LEGACY ALIGNMENT STYLE IN STRUCTURES |
rb sizeof.#name#field - ($-field) ; BECAUSE ALIGNED FIELD PRECIDED WITH ANOTHER SHORTER SIZE FIELD - WE CAN EMULATE ALIGNMENT BY ADDING SEQUENCE OF ",?" TO END OF THAT SHORTER SIZE FIELD |
end if ; 2ND PURPOSE - COMPARISON THAT DATA PASSED TO INITIALIZE STRUCTURE WILL FIT IN ITS MEMBERS; IN COMMON CASE MORE OPTIMAL SUCH COMPARISON FOR WHOLE STRUCTURE NOT PER FIELD |
\\\\} |
common |
;if $-\\..base-sizeof.#name ; IF WE REMOVE 3 LINES ABOVE COMMENTED AS LEGACY |
; err ; THEN WE MUST UNCOMMENT THESE 3 LINES |
;end if ; |
label . \\\} |
\\} |
macro name value \\{ |
\\local anonymous |
match , @struct \\\{ define field@struct -,name,<values> \\\} |
match no, @struct \\\{ anonymous name value \\\} \\} \} } |
;============================================================== |
macro define@struct name,[anon,field,type,def] { |
common |
local list |
list equ |
forward |
local anonsize |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
anonsize = $ |
match any, anon \{ irp anondef,any \\{ anondef \\} \} |
anonsize = $-anonsize |
; END OF ASSUMPTION |
if ~ field eq . |
name#field type def |
sizeof.#name#field = $ - name#field |
else |
label name#.#type |
rb sizeof.#type |
end if |
local value |
match any, list \{ list equ list, \} |
list equ list <value> |
common |
sizeof.#name = $ |
restruc name |
match values, list \{ |
struc name value \\{ |
\\local \\..base |
match , @struct \\\{ define field@struct .,name,<values> \\\} |
match no, @struct \\\{ |
label \\..base |
forward |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
rb anonsize |
; END of ASSUMPTION |
match , value \\\\{ field type def \\\\} |
match any, value \\\\{ |
field type value |
if ~ field eq . ; MAIN PURPOSE OF THEESE 3 LINES - REALISATION OF LEGACY ALIGNMENT STYLE IN STRUCTURES |
rb sizeof.#name#field - ($-field) ; BECAUSE ALIGNED FIELD PRECIDED WITH ANOTHER SHORTER SIZE FIELD - WE CAN EMULATE ALIGNMENT BY ADDING SEQUENCE OF ",?" TO END OF THAT SHORTER SIZE FIELD |
end if ; 2ND PURPOSE - COMPARISON THAT DATA PASSED TO INITIALIZE STRUCTURE WILL FIT IN ITS MEMBERS; IN COMMON CASE MORE OPTIMAL SUCH COMPARISON FOR WHOLE STRUCTURE NOT PER FIELD |
\\\\} |
common |
;if $-\\..base-sizeof.#name ; IF WE REMOVE 3 LINES ABOVE COMMENTED AS LEGACY |
; err ; THEN WE MUST UNCOMMENT THESE 3 LINES |
;end if ; |
label . at \\..base \\\} |
\\} |
macro name value \\{ |
\\local anonymous |
match , @struct \\\{ define field@struct -,name,<values> \\\} |
match no, @struct \\\{ anonymous name value \\\} \\} \} } |
;============================================================== |
macro enable@substruct { |
macro make@substruct substruct,parent,name,[field,type,def] \{ |
\common |
\local CONVERTED,PREVIOUS,CURRENT |
define CONVERTED parent,name |
define CURRENT 1 |
\forward |
PREVIOUS equ CURRENT |
define CURRENT 1 |
\local sub |
match , field \\{ |
match any, type \\\{ |
define CURRENT 2 |
enable@substruct |
make@substruct type,parent,sub def |
purge make@substruct \\\} \\} |
match -, field \\{ define CURRENT 0 \\} |
match =1:=0, PREVIOUS:CURRENT \\{ CONVERTED equ CONVERTED, < <type def> \\} |
match =0:=0, PREVIOUS:CURRENT \\{ CONVERTED equ CONVERTED , <type def> \\} |
match =1:=1, PREVIOUS:CURRENT \\{ CONVERTED equ CONVERTED, , .\#field, type, <def> \\} |
match =0:=1, PREVIOUS:CURRENT \\{ CONVERTED equ CONVERTED >, .\#field, type, <def> \\} |
match =1:=2, PREVIOUS:CURRENT \\{ CONVERTED equ CONVERTED, , ., sub, \\} |
match =0:=2, PREVIOUS:CURRENT \\{ CONVERTED equ CONVERTED >, ., sub, \\} |
match =2, CURRENT \\{ define CURRENT 1 \\} |
\common |
\local anonymous |
match =0, CURRENT \\{ CONVERTED equ CONVERTED >,anonymous, :, \\} |
match converted, CONVERTED \\{ define@\#substruct converted \\} \} } |
;============================================================== |
enable@substruct |
;============================================================== |
macro define@subunion parent,name,[anon,field,type,def] { |
common |
virtual at parent#.#name |
forward |
match any, anon \{ |
irp anondef,any \\{ |
\\local anonsize |
virtual at 0 |
anondef |
anonsize = $ |
end virtual |
if anonsize > $ - parent#.#name |
rb anonsize - ($-$$) |
end if |
\\} \} |
if ~ field eq . |
virtual at parent#.#name |
parent#field type def |
sizeof.#parent#field = $ - parent#field |
end virtual |
if sizeof.#parent#field > $ - parent#.#name |
rb sizeof.#parent#field - ($ - parent#.#name) |
end if |
else |
virtual at parent#.#name |
label parent#.#type |
type def |
end virtual |
label name#.#type at parent#.#name |
if sizeof.#type > $ - parent#.#name |
rb sizeof.#type - ($ - parent#.#name) |
end if |
end if |
common |
sizeof.#name = $ - parent#.#name |
end virtual |
struc name value \{ |
label .\#name |
last@union equ |
forward |
match any, last@union \\{ |
virtual at .\#name |
field type def |
end virtual \\} |
match , last@union \\{ |
match , value \\\{ field type def \\\} |
match any, value \\\{ field type value \\\} \\} |
last@union equ field |
common |
rb sizeof.#name - ($ - .\#name) \} |
macro name value \{ |
label .\#name |
last@union equ |
forward |
match , last@union \\{ match any, value \\\{ field type value \\\} \\} |
last@union equ field |
common |
rb sizeof.#name - ($ - .\#name) \} } |
;============================================================== |
macro define@subrstruct parent,name,[anon,field,type,def] { |
common |
local ..start,..size |
virtual at parent#.#name-..size |
..start: |
forward |
local value,anonsize |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
anonsize = $ |
match any, anon \{ irp anondef,any \\{ anondef \\} \} |
anonsize = $-anonsize |
; END OF ASSUMPTION |
if ~ field eq . |
parent#field type def |
sizeof.#parent#field = $ - parent#field |
else |
label parent#.#type |
rb sizeof.#type |
end if |
common |
..size = $ - ..start |
sizeof.#name = ..size |
end virtual |
struc name value \{ |
label .\#name |
forward |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
rb anonsize |
; END of ASSUMPTION |
match , value \\{ field type def \\} |
match any, value \\{ |
field type value |
if ~ field eq . ; MAIN PURPOSE OF THEESE 3 LINES - REALISATION OF LEGACY ALIGNMENT STYLE IN STRUCTURES |
rb sizeof.#parent#field - ($-field) ; BECAUSE ALIGNED FIELD PRECIDED WITH ANOTHER SHORTER SIZE FIELD - WE CAN EMULATE ALIGNMENT BY ADDING SEQUENCE OF ",?" TO END OF THAT SHORTER SIZE FIELD |
end if \\} ; 2ND PURPOSE - COMPARISON THAT DATA PASSED TO INITIALIZE STRUCTURE WILL FIT IN ITS MEMBERS; IN COMMON CASE MORE OPTIMAL SUCH COMPARISON FOR WHOLE STRUCTURE NOT PER FIELD |
common |
;if $-.\#name-sizeof.#name ; IF WE REMOVE 3 LINES ABOVE COMMENTED AS LEGACY |
; err ; THEN WE MUST UNCOMMENT THESE 3 LINES |
;end if ; |
\} |
macro name value \{ |
\local ..anonymous |
..anonymous name \} } |
;============================================================== |
macro define@substruct parent,name,[anon,field,type,def] { |
common |
virtual at parent#.#name |
forward |
local value,anonsize |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
anonsize = $ |
match any, anon \{ irp anondef,any \\{ anondef \\} \} |
anonsize = $-anonsize |
; END OF ASSUMPTION |
if ~ field eq . |
parent#field type def |
sizeof.#parent#field = $ - parent#field |
else |
label parent#.#type |
rb sizeof.#type |
end if |
common |
sizeof.#name = $ - parent#.#name |
end virtual |
struc name value \{ |
label .\#name |
forward |
;!!! WE MAKING ASSUMPTION THAT UNNAMED FIELDS ARE JUST RESERVE SPACE |
rb anonsize |
; END of ASSUMPTION |
match , value \\{ field type def \\} |
match any, value \\{ |
field type value |
if ~ field eq . ; MAIN PURPOSE OF THEESE 3 LINES - REALISATION OF LEGACY ALIGNMENT STYLE IN STRUCTURES |
rb sizeof.#parent#field - ($-field) ; BECAUSE ALIGNED FIELD PRECIDED WITH ANOTHER SHORTER SIZE FIELD - WE CAN EMULATE ALIGNMENT BY ADDING SEQUENCE OF ",?" TO END OF THAT SHORTER SIZE FIELD |
end if \\} ; 2ND PURPOSE - COMPARISON THAT DATA PASSED TO INITIALIZE STRUCTURE WILL FIT IN ITS MEMBERS; IN COMMON CASE MORE OPTIMAL SUCH COMPARISON FOR WHOLE STRUCTURE NOT PER FIELD |
common |
;if $-.\#name-sizeof.#name ; IF WE REMOVE 3 LINES ABOVE COMMENTED AS LEGACY |
; err ; THEN WE MUST UNCOMMENT THESE 3 LINES |
;end if ; |
\} |
macro name value \{ |
\local ..anonymous |
..anonymous name \} } |
/programs/develop/fasm/1.73/kolibri/macro/syscall.inc |
---|
0,0 → 1,127 |
macro reg_props type,size,[reg] |
{ |
typeof.#reg = type |
sizeof.#reg = size |
} |
?isReg32 equ in <eax,ebx,ecx,edx,esi,edi,ebp,esp> |
?isReg32w8 equ in <eax,ebx,ecx,edx> |
?isReg equ eqtype eax |
?isInteger equ eqtype 0 |
?isFlatMem equ eqtype [] |
?isSegMem equ eqtype fs:[] |
?isString equ eqtype '' |
macro madd reg,a1,a2 { add reg,(a1) shl 16 + (a2) } |
macro msub reg,a1,a2 { sub reg,(a1) shl 16 + (a2) } |
macro mcr_mov arg1*,arg2* |
{ |
if (arg1 ?isReg32) & ((arg2 ?isInteger) | (arg2 ?isString)) |
if ~(arg2) |
xor arg1,arg1 |
else if (arg2) = 1 |
xor arg1,arg1 |
inc arg1 |
else if (arg2) = -1 |
or arg1,-1 |
else |
mov arg1,arg2 |
end if |
else |
mov arg1,arg2 |
end if |
} |
macro mpack dest, hsrc, lsrc |
{ |
if (hsrc ?isInteger) |
if (lsrc ?isReg32) |
lea dest, [(hsrc) shl 16 + lsrc] |
else if (+lsrc ?isInteger) ;everething except memory opnd |
mov dest, (hsrc) shl 16 + lsrc |
else ;if (lsrc ?isFlatMem) | (lsrc ?isSegMem) |
mov dest, lsrc |
add dest, (hsrc) shl 16 |
end if |
else |
mov dest, hsrc |
shl dest, 16 |
add dest, lsrc |
end if |
} |
macro __mov reg,a,b { ; mike.dld |
match any,a \{ |
if (~b eq) |
mpack reg,a,b |
else if ~(a eq reg) |
mcr_mov reg,a |
end if \} |
} |
macro regcall proc,a,b,c,d,e,f,g { |
__mov eax,a |
__mov ebx,b |
__mov ecx,c |
__mov edx,d |
__mov esi,e |
__mov edi,f |
__mov ebp,g |
call proc |
} |
macro reginvk proc,a,b,c,d,e,f,g { |
__mov eax,a |
__mov ebx,b |
__mov ecx,c |
__mov edx,d |
__mov esi,e |
__mov edi,f |
__mov ebp,g |
call [proc] |
} |
include 'config.inc' |
;__CPU_type equ p5 |
SYSENTER_VAR equ 0 |
macro mcallb a,b,c,d,e,f { ; mike.dld, updated by Ghost for Fast System Calls |
local ..ret_point |
__mov ebx,b |
__mov ecx,c |
__mov edx,d |
__mov esi,e |
__mov edi,f |
if __CPU_type eq p5 |
int 0x40 |
else |
if __CPU_type eq p6 |
push ebp |
mov ebp, esp |
push ..ret_point ; it may be 2 or 5 byte |
sysenter |
..ret_point: |
pop edx |
pop ecx |
else |
if __CPU_type eq k6 |
push ecx |
syscall |
pop ecx |
else |
display 'ERROR : unknown CPU type (set to p5)', 10, 13 |
__CPU_type equ p5 |
int 0x40 |
end if |
end if |
end if |
} |
macro mcall a,b& { ; mike.dld, updated by Ghost for Fast System Calls |
__mov eax,a |
mcallb ,b |
} |
/programs/develop/fasm/1.73/kolibri/osloader/osloader.inc |
---|
0,0 → 1,191 |
GetStrLength: |
; string: [in] edi |
; string length: [out] ecx |
; [unchanged] ebx, edx, esi, edi, ebp, esp |
or ecx, -1 |
xor eax, eax |
cld |
repne scasb |
not ecx |
sub edi,ecx |
ret |
GetProcAddress: |
; hInstance (export table): [in] esi |
; proc name: [in] edi |
; proc address: [out] eax |
; [unchanged] ebp, esp |
call GetStrLength |
mov edx, ecx |
mov ebx, edi |
mov eax, esi |
.import_find: |
mov esi, ebx |
mov edi, [eax] |
test edi, edi |
jz .import_not_found |
repe cmpsb |
je .import_found |
mov ecx, edx |
add eax, 8 |
jmp .import_find |
.import_not_found: |
sub eax, 4 |
.import_found: |
mov eax, [eax+4] |
ret |
ResolveImports: |
; hInstance (export table): [in] esi |
; lib.lookup table: [in] ebp |
; ?isResolved: [out] eax |
; [unchanged] esi, esp |
.retFrom = 4 |
.import_loop: |
mov edi, [ebp] |
test edi, edi |
jz .import_done |
push esi |
call GetProcAddress |
pop esi |
test eax, eax |
jz .import_not_found |
mov [ebp],eax |
add ebp,4 |
jmp .import_loop |
.import_not_found: |
mov eax, sz_EPnotFound |
mov ebx, sizeof.sz_EPnotFound |
mov ecx, 3 |
mov edx, [ebp] |
call ShowErrorWindow |
or [LoadLibraries.errStatus+ResolveImports.retFrom],1 |
mcall SF_TERMINATE_PROCESS ;uncomment to stop after 1st error |
jmp .import_loop |
.import_done: |
ret |
@copy_path_wo_pdname: |
; library name: [in] edx |
; library path: [in] esi |
; current directory path: [in] edi |
; [out] no |
; [unchanged] ebx, edx, ebp, esp |
call GetStrLength |
add edi,ecx |
mov al, '/' |
std |
repne scasb |
cld |
sub edi,ecx |
add ecx,2 |
xchg esi, edi |
mov eax, ecx |
shr ecx, 2 |
rep movsd |
mov ecx, eax |
and ecx, 3 |
rep movsb |
mov esi, edx |
xchg esi, edi |
call GetStrLength |
xchg esi, edi |
mov eax, ecx |
shr ecx, 2 |
rep movsd |
mov ecx, eax |
and ecx, 3 |
rep movsb |
ret |
LoadLibrary: |
; library name: [in] edx |
; hInstance (export table): [out] eax |
; [unchanged] edx, ebp, esp |
mov edi, cur_dir_path |
mov esi, library_path |
call @copy_path_wo_pdname |
mcall SF_SYS_MISC,SSF_LOAD_DLL,library_path |
test eax, eax |
jnz .ret |
lea ecx, [edx-9] |
mcall SF_SYS_MISC,SSF_LOAD_DLL,ecx ; load of sys directory |
.ret: |
ret |
LoadLibraries: |
; [in/out] no |
; [unchanged] esp |
push 0 |
push import.data |
virtual at esp+4 |
.errStatus dd ? |
end virtual |
.LoopLibraries: |
mov eax, [esp] |
mov ebp, [eax] |
test ebp, ebp |
jz .done |
mov edx, [eax+4] |
call LoadLibrary;edx=name |
test eax, eax |
jz .onError |
mov esi,eax |
mov eax, [esp] |
call ResolveImports |
add dword[esp],8 |
jmp .LoopLibraries |
.onError: |
mov eax, sz_cantLL |
mov ebx, sizeof.sz_cantLL |
mov ecx, 1 |
or [LoadLibraries.errStatus],1 |
mcall SF_TERMINATE_PROCESS ;uncomment to stop after 1st error |
jmp .LoopLibraries |
.done: |
test [LoadLibraries.errStatus],1 |
jz .exit |
mcall SF_TERMINATE_PROCESS |
.exit: |
add esp,8 |
ret |
ShowErrorWindow: |
; error string: [in] edx |
; [unchanged] edx, ebp, esp |
mov edi, [file_io_notify.flags] |
xor ecx, [import_loader.state] |
test ecx, ecx |
jz .rns.FlagsInited |
cmp ecx, 2 |
jz .rns.FlagsPreInited |
.rns.FlagsPreInit: |
mov esi, sz_system_error |
mov ecx, sizeof.sz_system_error-1 |
cld |
rep movsb |
or [import_loader.state],1 |
jmp .rns.FlagsInit |
.rns.FlagsPreInited: |
add edi, sizeof.sz_system_error-1 |
.rns.FlagsInit: |
mov esi, eax |
xchg esi, edi |
call GetStrLength |
dec ecx |
xchg esi, edi |
rep movsb |
xor [import_loader.state],2 |
jmp .rns.FlagsDone |
.rns.FlagsInited: |
lea edi, [edi+ebx-1+sizeof.sz_system_error-1] |
.rns.FlagsDone: |
mov esi, edx |
xchg esi, edi |
call GetStrLength |
xchg esi, edi |
rep movsb |
mcall SF_FILE,file_io_notify |
ret |
/programs/develop/fasm/1.73/kolibri/structs/box_lib.inc |
---|
0,0 → 1,230 |
struct EDIT_BOX |
width dd ? |
left dd ? |
top dd ? |
color dd ? |
shift_color dd ? |
focus_border_color dd ? |
blur_border_color dd ? |
text_color dd ? |
max dd ? |
text dd ? |
mouse_variable dd ? |
flags dd ? |
size dd ? |
pos dd ? |
offset dd ? |
cl_curs_x dw ? |
cl_curs_y dw ? |
shift dw ? |
shift_old dw ? |
height dd ? |
char_width dd ? |
ends |
struct CHECK_BOX2 |
left_s dd ? |
top_s dd ? |
ch_text_margin dd ? |
color dd ? |
border_color dd ? |
text_color dd ? |
text dd ? |
flags dd ? |
size_of_str dd ? |
ends |
struct OPTION_BOX |
option_group dd ? |
left dw ? |
top dw ? |
ch_text_margin dd ? |
ch_size dd ? |
color dd ? |
border_color dd ? |
text_color dd ? |
text dd ? |
ch_text_length dd ? |
flags dd ? |
ends |
struct TREE_LIST |
box BOX |
data_info dd ? |
info_size dd ? |
info_max_count dd ? |
style dd ? |
data_nodes dd ? |
data_img dd ? |
img_cx dw ? |
img_cy dw ? |
data_img_sys dd ? |
ch_tim dd ? |
tim_undo dd ? |
cur_pos dd ? |
col_bkg dd ? |
col_zag dd ? |
col_txt dd ? |
capt_cy dd ? |
info_capt_offs dw ? |
info_capt_len dw ? |
el_focus dd ? |
p_scroll dd ? |
on_press dd ? |
ends |
struct TEXT_EDITOR |
wnd BOX |
rec BOX |
drag_m db ? |
drag_k db ? |
sel_x0 dd ? |
sel_y0 dd ? |
sel_x1 dd ? |
sel_y1 dd ? |
seln_x0 dd ? |
seln_y0 dd ? |
seln_x1 dd ? |
seln_y1 dd ? |
tex dd ? |
tex_1 dd ? |
tex_end dd ? |
cur_x dd ? |
cur_y dd ? |
max_chars dd ? |
colors_text_count dd ? |
key_words_count dd ? |
color_cursor dd ? |
color_wnd_capt dd ? |
color_wnd_work dd ? |
color_wnd_bord dd ? |
color_select dd ? |
color_cur_text dd ? |
color_wnd_text dd ? |
syntax_file dd ? |
syntax_file_size dd ? |
text_colors dd ? |
help_text_f1 dd ? |
help_id dd ? |
key_words_data dd ? |
tim_ch dd ? |
tim_undo dd ? |
tim_ls dd ? |
tim_co dd ? |
el_focus dd ? |
err_save dd ? |
panel_id dd ? |
key_new dd ? |
symbol_new_line dd ? |
scr_w dd ? |
scr_h dd ? |
arr_key_pos dd ? |
buffer dd ? |
buffer_find dd ? |
cur_ins db ? |
mode_color db ? |
mode_invis db ? |
gp_opt db ? |
fun_on_key_ctrl_o dd ? |
fun_on_key_ctrl_f dd ? |
fun_on_key_ctrl_n dd ? |
fun_on_key_ctrl_s dd ? |
buffer_size dd ? |
fun_find_err dd ? |
fun_init_synt_err dd ? |
fun_draw_panel_buttons dd ? |
fun_draw_panel_find dd ? |
fun_draw_panel_syntax dd ? |
fun_save_err dd ? |
increase_size dd ? |
ptr_free_symb dd ? |
font_size dd ? |
ends |
TED_OFFS_SEL = TEXT_EDITOR.sel_x0 |
TED_OFFS_SELN = TEXT_EDITOR.seln_x0 |
TED_OFFS_COUNT_COLORS = TEXT_EDITOR.colors_text_count |
TED_OFFS_KEY_NEW = TEXT_EDITOR.key_new |
TED_OFFS_SYMBOL_NEW_LINE = TEXT_EDITOR.symbol_new_line |
struct SCROLL_BAR |
x_size dw ? |
x_pos dw ? |
y_size dw ? |
y_pos dw ? |
btn_height dd ? |
type dd ? |
max_area dd ? |
cur_area dd ? |
position dd ? |
bg_color dd ? |
front_color dd ? |
line_color dd ? |
redraw dd ? |
delta dw ? |
delta2 dw ? |
r_size_x dw ? |
r_start_x dw ? |
r_size_y dw ? |
r_start_y dw ? |
m_pos dd ? |
m_pos_2 dd ? |
m_keys dd ? |
run_size dd ? |
position2 dd ? |
work_size dd ? |
all_redraw dd ? |
ar_offset dd ? |
ends |
SB_OFFS_SIZE_X = SCROLL_BAR.x_size |
SB_OFFS_START_X = SCROLL_BAR.x_pos |
SB_OFFS_SIZE_Y = SCROLL_BAR.y_size |
SB_OFFS_START_Y = SCROLL_BAR.y_pos |
SB_OFFS_MAX_AREA = SCROLL_BAR.max_area |
SB_OFFS_CUR_AREA = SCROLL_BAR.cur_area |
SB_OFFS_POSITION = SCROLL_BAR.position |
SB_OFFS_BCKG_COL = SCROLL_BAR.bg_color |
SB_OFFS_FRNT_COL = SCROLL_BAR.front_color |
SB_OFFS_LINE_COL = SCROLL_BAR.line_color |
SB_OFFS_REDRAW = SCROLL_BAR.redraw |
SB_OFFS_DELTA2 = SCROLL_BAR.delta2 |
SB_OFFS_ALL_REDRAW = SCROLL_BAR.all_redraw |
struct TOOLTIP |
txt dd ? |
next dd ? |
zone_y dd ? |
zone_x dd ? |
zone_h dd ? |
zone_w dd ? |
col_txt dd ? |
col_bkg dd ? |
tm_wait dd ? |
font_sz dd ? |
mouse dd ? |
bg_color dd ? |
front_color dd ? |
line_color dd ? |
redraw dd ? |
delta dw ? |
delta2 dw ? |
r_size_x dw ? |
r_start_x dw ? |
r_size_y dw ? |
r_start_y dw ? |
m_pos dd ? |
m_pos_2 dd ? |
m_keys dd ? |
run_size dd ? |
position2 dd ? |
work_size dd ? |
all_redraw dd ? |
ar_offset dd ? |
ends |
/programs/develop/fasm/1.73/kolibri/structs/kernel.inc |
---|
0,0 → 1,69 |
struct BOX |
left dd ? |
top dd ? |
width dd ? |
height dd ? |
ends |
struct process_information |
cpu_usage dd ? ; +0 |
window_stack_position dw ? ; +4 |
window_stack_value dw ? ; +6 |
dw ? ; +8 |
process_name TCHAR 12 dup(?) ; +10 |
memory_start dd ? ; +22 |
used_memory dd ? ; +26 |
PID dd ? ; +30 |
box BOX ; +34 |
slot_state dw ? ; +50 |
dw ? ; +52 |
client_box BOX ; +54 |
wnd_state db ? ; +70 |
align 1024 |
ends |
struct system_colors |
frame dd ? ;nonset1 |
grab dd ? ;nonset2 |
work_3d_dark dd ? |
work_3d_light dd ? |
grab_text dd ? ;window_title |
work dd ? |
work_button dd ? |
work_button_text dd ? |
work_text dd ? |
work_graph dd ? |
ends |
struct FILEIO |
cmd dd ? |
offset dd ? |
flags dd ? |
count dd ? |
buffer dd ? |
; db ? |
;name dd ? |
ends |
struct FILEDATE |
Second db ? |
Minute db ? |
Hour db ? |
db ? |
Day db ? |
Month db ? |
Year dw ? |
ends |
struct FILEINFO |
Attributes dd ? |
IsUnicode db ? |
db 3 dup(?) |
DateCreate FILEDATE |
DateAccess FILEDATE |
DateModify FILEDATE |
size dq ? |
ends |
/programs/develop/fasm/1.73/kolibri/structs/proc_lib.inc |
---|
0,0 → 1,18 |
struct OPEN_DLG |
type dd ? |
procinfo dd ? |
com_area_name dd ? |
com_area dd ? |
opendir_path dd ? |
dir_default_path dd ? |
start_path dd ? |
lp_drawwndproc dd ? |
status dd ? |
openfile_path dd ? |
filename_area dd ? |
filter_area dd ? |
x_size dw ? |
x_pos dw ? |
y_size dw ? |
y_pos dw ? |
ends |