Subversion Repositories Kolibri OS

Rev

Rev 1102 | Rev 3014 | Go to most recent revision | Blame | Compare with Previous | Last modification | View Log | Download | RSS feed

  1. ;-----------------------------------------------------------------------------
  2. ; project name:      TINYPAD
  3. ; compiler:          flat assembler 1.67.21
  4. ; memory to compile: 3.0/9.0 MBytes (without/with size optimizations)
  5. ; version:           SVN (4.0.5)
  6. ; last update:       2008-07-18 (Jul 18, 2008)
  7. ; minimal kernel:    revision #823 (svn://kolibrios.org/kernel/trunk)
  8. ;-----------------------------------------------------------------------------
  9. ; originally by:     Ville Michael Turjanmaa >> villemt@aton.co.jyu.fi
  10. ; maintained by:     Mike Semenyako          >> mike.dld@gmail.com
  11. ;                    Ivan Poddubny           >> ivan-yar@bk.ru
  12. ;-----------------------------------------------------------------------------
  13. ; TODO (4.1.0):
  14. ;   - add vertical selection, undo, goto position, overwrite mode, smart tabulation
  15. ;   - improve window drawing with small dimensions
  16. ;   - save/load settings to/from ini file, not executable
  17. ;   - path autocompletion for open/save dialogs
  18. ;   - other bug-fixes and speed/size optimizations
  19. ;-----------------------------------------------------------------------------
  20. ; See history.txt for complete changelog
  21. ;-----------------------------------------------------------------------------
  22.  
  23. include 'lang.inc'
  24.  
  25. include '../../../macros.inc' ; useful stuff
  26. include '../../../struct.inc'
  27. include '../../../proc32.inc'
  28.  
  29. include 'external/libio.inc'
  30.  
  31. include 'tinypad.inc'
  32.  
  33. ;purge mov,add,sub            ;  SPEED
  34.  
  35. header '01',1,@CODE,TINYPAD_END,STATIC_MEM_END,MAIN_STACK,@PARAMS,ini_path
  36.  
  37. APP_VERSION equ 'SVN (4.0.6)'
  38.  
  39. TRUE = 1
  40. FALSE = 0
  41.  
  42. ;include 'debug.inc'
  43. ;define __DEBUG__ 1
  44. ;define __DEBUG_LEVEL__ 1
  45. ;include 'debug-fdo.inc'
  46.  
  47. ; compiled-in options
  48.  
  49. ASEPC = '-'  ; separator character (char)
  50. ATOPH = 19   ; menu bar height (pixels)
  51. SCRLW = 16   ; scrollbar widht/height (pixels)
  52. ATABW = 8    ; tab key indent width (chars)
  53. LINEH = 10   ; line height (pixels)
  54. PATHL = 256  ; maximum path length (chars) !!! don't change !!!
  55. AMINS = 8    ; minimal scroll thumb size (pixels)
  56. LCHGW = 3    ; changed/saved marker width (pixels)
  57.  
  58. STATH = 16   ; status bar height (pixels)
  59. TBARH = 18   ; tab bar height (pixels)
  60.  
  61. INI_SEC_PREFIX equ ''
  62.  
  63. ;-----------------------------------------------------------------------------
  64. section @CODE ;:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  65. ;-----------------------------------------------------------------------------
  66.  
  67.         cld
  68.         mov     edi,@UDATA
  69.         mov     ecx,@PARAMS-@UDATA
  70.         mov     al,0
  71.         rep     stosb
  72.  
  73.         mcall   68,11
  74.         or      eax,eax
  75.         jz      key.alt_x.close
  76.  
  77.         stdcall dll.Load,@IMPORT
  78.         or      eax,eax
  79.         jnz     key.alt_x.close
  80.  
  81.         mov     edi,ini_path
  82.         xor     al,al
  83.         mov     ecx,PATHL
  84.         repne   scasb
  85.         mov     dword[edi-1],'.ini'
  86.         mov     byte[edi+3],0
  87.  
  88.         stdcall load_settings
  89.  
  90.         stdcall mem.Alloc,65536
  91.         mov     [temp_buf],eax
  92.  
  93.         inc     [do_not_draw]
  94.  
  95.         mov     dword[app_start],7
  96.  
  97.         mov     esi,s_example
  98.         mov     edi,tb_opensave.text
  99.         mov     ecx,s_example.size
  100.         mov     [tb_opensave.length],cl
  101.         rep     movsb
  102.  
  103.         mov     esi,s_still
  104.         mov     edi,s_search
  105.         mov     ecx,s_still.size
  106.         mov     [s_search.size],ecx
  107.         rep     movsb
  108.  
  109.         cmp     byte[@PARAMS],0
  110.         jz      no_params
  111.  
  112. ;// Willow's code to support DOCPAK [
  113.  
  114.         cmp     byte[@PARAMS],'*'
  115.         jne     .noipc
  116.  
  117. ;// diamond [ (convert size from decimal representation to dword)
  118. ;--     mov     edx,dword[@PARAMS+1]
  119.         mov     esi,@PARAMS+1
  120.         xor     edx,edx
  121.         xor     eax,eax
  122.     @@: lodsb
  123.         test    al,al
  124.         jz      @f
  125.         lea     edx,[edx*4+edx]
  126.         lea     edx,[edx*2+eax-'0']
  127.         jmp     @b
  128.     @@:
  129. ;// diamond ]
  130.  
  131.         add     edx,20
  132.  
  133.         stdcall mem.Alloc,edx
  134.         mov     ebp,eax
  135.         push    eax
  136.  
  137.         mov     dword[ebp+0],0
  138.         mov     dword[ebp+4],8
  139.         mcall   60,1,ebp
  140.         mcall   40,1000000b
  141.  
  142.         mcall   23,200
  143.  
  144.         cmp     eax,7
  145.         jne     key.alt_x.close
  146.         mov     byte[ebp],1
  147.  
  148.         mov     ecx,[ebp+12]
  149.         lea     esi,[ebp+16]
  150.         call    create_tab
  151.         call    load_from_memory
  152.  
  153.         pop     ebp
  154.         stdcall mem.Free,ebp
  155.  
  156.         jmp     @f
  157.   .noipc:
  158.  
  159. ;// Willow's code to support DOCPAK ]
  160.  
  161.         mov     esi,@PARAMS
  162.         mov     edi,tb_opensave.text
  163.         mov     ecx,PATHL
  164.         rep     movsb
  165.         mov     edi,tb_opensave.text
  166.         mov     ecx,PATHL
  167.         xor     al,al
  168.         repne   scasb
  169.         jne     key.alt_x.close
  170.         lea     eax,[edi-tb_opensave.text-1]
  171.         mov     [tb_opensave.length],al
  172.         call    load_file
  173.         jnc     @f
  174.  
  175.   no_params:
  176.         call    create_tab
  177.  
  178.     @@:
  179.         mov     [s_status],0
  180.         dec     [do_not_draw]
  181.  
  182.         mov     al,[tabs_pos]
  183.         mov     [tab_bar.Style],al
  184.  
  185. ;---------------------------------------------------------------------
  186.         mov     edi,filename_area
  187.         mov     esi,s_example+5
  188.         call    copy_str_1
  189.  
  190.         mov     esi,tb_opensave.text
  191.         mov     edi,fname_Info
  192.         call    copy_str_1
  193.         xor     eax,eax
  194.         mov     [edi],al
  195. ;---------------------------------------------------------------------
  196. ;OpenDialog     initialisation
  197.         push    dword OpenDialog_data
  198.         call    [OpenDialog_Init]
  199. ;---------------------------------------------------------------------
  200.  
  201.  
  202.         mcall   66,1,1
  203.         mcall   40,00100111b
  204. red:
  205.         call    drawwindow
  206.  
  207. ;-----------------------------------------------------------------------------
  208.  
  209. still:
  210.         call    draw_statusbar ; write current position & number of strings
  211.  
  212.   .skip_write:
  213.         cmp     [open_dialog],1
  214.         je      .open_dialog
  215.         mcall   10      ; wait here until event
  216.         cmp     [main_closed],0
  217.         jne     key.alt_x
  218.         dec     eax     ; redraw ?
  219.         jz      red
  220.         dec     eax     ; key ?
  221.         jz      key
  222.         dec     eax     ; button ?
  223.         jz      button
  224.         sub     eax,3   ; mouse ?
  225.         jz      mouse
  226.  
  227.         jmp     still.skip_write
  228. ;---------------------------------------------------------------------
  229. .open_dialog:
  230.         pusha
  231.  
  232.         call    btn.bot.cancel
  233.  
  234.         mov     esi,tb_opensave.text
  235.         mov     edi,[OpenDialog_data.openfile_pach]
  236.         movzx   ecx,[tb_opensave.length]
  237.         mov     edx,[OpenDialog_data.filename_area]
  238.         mov     ebx,[OpenDialog_data.opendir_pach]
  239.         call    copy_str_2
  240.         movzx   eax,byte [bot_mode2]
  241.         mov     [OpenDialog_data.type],eax
  242.         popa
  243. ; invoke OpenDialog
  244.         push    dword OpenDialog_data
  245.         call    [OpenDialog_Start]
  246.  
  247.         cmp     [OpenDialog_data.status],1
  248.         jne     .3
  249.  
  250.         pusha
  251.         mov     edi,tb_opensave.text
  252.         mov     esi,[OpenDialog_data.openfile_pach]
  253.         call    copy_str_1
  254.         sub     edi,tb_opensave.text
  255.         dec     edi
  256.         mov     eax,edi
  257.         mov     [tb_opensave.length],al
  258.         popa
  259.        
  260.         cmp     [bot_mode2],0
  261.         je      .2
  262.         call    save_file
  263.         jmp     .3
  264. .2:
  265.         call    load_file
  266. .3:
  267.         mov     [open_dialog],0
  268.         jmp     red
  269. ;-----------------------------------------------------------------------------
  270. draw_window_for_OD:
  271.         call    drawwindow
  272.         call    draw_statusbar
  273.         ret
  274. ;-----------------------------------------------------------------------------
  275. copy_str_2:
  276.         cld
  277.         push    esi ecx
  278.         rep     movsb   ; edi  openfile_pach
  279.         xor     eax,eax
  280.         mov     [edi],al
  281.         pop     ecx esi
  282.         mov     edi,ebx
  283.         rep     movsb   ; edi opendir_pach
  284.         mov     [edi],al
  285.         mov     esi,edi
  286.         std
  287. @@:
  288.         lodsb
  289.         cmp     al,byte '/'
  290.         jne     @b
  291.         inc     esi
  292.         xor     eax,eax
  293.         mov     [esi],al
  294.         inc     esi
  295.         mov     edi,edx ; edi filename_area
  296.         call    copy_str_1
  297.         ret
  298. ;-----------------------------------------------------------------------------
  299. copy_str_1:
  300.         xor     eax,eax
  301.         cld
  302. @@:
  303.         lodsb
  304.         stosb
  305.         test    eax,eax
  306.         jnz     @b
  307.         ret
  308. ;-----------------------------------------------------------------------------
  309. proc get_event ctx ;//////////////////////////////////////////////////////////
  310. ;-----------------------------------------------------------------------------
  311.         mcall   10
  312.         dec     eax     ; redraw ?
  313.         jz      .redraw
  314.         dec     eax     ; key ?
  315.         jz      .key
  316.         dec     eax     ; button ?
  317.         jz      .button
  318.         sub     eax,2   ; background ?
  319.         jz      .background
  320.         dec     eax     ; mouse ?
  321.         jz      .mouse
  322.         dec     eax     ; ipc ?
  323.         jz      .ipc
  324.         dec     eax     ; network ?
  325.         jz      .network
  326.         dec     eax     ; debug ?
  327.         jz      .debug
  328.         sub     eax,7   ; irq ?
  329.         js      .nothing
  330.         cmp     eax,15
  331.         jg      .nothing
  332.         jmp     .irq
  333.  
  334.   .nothing:
  335.         mov     eax,EV_IDLE
  336.         ret
  337.  
  338.   .redraw:
  339.         mov     eax,EV_REDRAW
  340.         ret
  341.  
  342.   .key:
  343.         mov     eax,EV_KEY
  344.         ret
  345.  
  346.   .button:
  347.         mov     eax,EV_BUTTON
  348.         ret
  349.  
  350.   .background:
  351.         mov     eax,EV_BACKGROUND
  352.         ret
  353.  
  354.   .mouse:
  355.         mov     eax,EV_MOUSE
  356.         ret
  357.  
  358.   .ipc:
  359.         mov     eax,EV_IPC
  360.         ret
  361.  
  362.   .network:
  363.         mov     eax,EV_NETWORK
  364.         ret
  365.  
  366.   .debug:
  367.         mov     eax,EV_DEBUG
  368.         ret
  369. endp
  370.  
  371. ;-----------------------------------------------------------------------------
  372. proc load_settings ;//////////////////////////////////////////////////////////
  373. ;-----------------------------------------------------------------------------
  374.         pushad
  375.  
  376.         invoke  ini.get_int,ini_path,ini_sec_options,ini_options_tabs_pos,2
  377.         mov     [tabs_pos],al
  378.         invoke  ini.get_int,ini_path,ini_sec_options,ini_options_secure_sel,0
  379.         mov     [secure_sel],al
  380.         invoke  ini.get_int,ini_path,ini_sec_options,ini_options_auto_braces,0
  381.         mov     [auto_braces],al
  382.         invoke  ini.get_int,ini_path,ini_sec_options,ini_options_auto_indent,1
  383.         mov     [auto_indent],al
  384.         invoke  ini.get_int,ini_path,ini_sec_options,ini_options_smart_tab,1
  385.         mov     [smart_tab],al
  386.         invoke  ini.get_int,ini_path,ini_sec_options,ini_options_optim_save,1
  387.         mov     [optim_save],al
  388.         invoke  ini.get_int,ini_path,ini_sec_options,ini_options_line_nums,0
  389.         mov     [line_nums],al
  390.  
  391.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_text,0x00000000
  392.         mov     [color_tbl.text],eax
  393.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_back,0x00ffffff
  394.         mov     [color_tbl.back],eax
  395.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_text_sel,0x00ffffff
  396.         mov     [color_tbl.text.sel],eax
  397.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_back_sel,0x000a246a
  398.         mov     [color_tbl.back.sel],eax
  399.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_symbol,0x003030f0
  400.         mov     [color_tbl.symbol],eax
  401.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_number,0x00009000
  402.         mov     [color_tbl.number],eax
  403.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_string,0x00b00000
  404.         mov     [color_tbl.string],eax
  405.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_comment,0x00808080
  406.         mov     [color_tbl.comment],eax
  407.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_line_moded,0x00ffee62
  408.         mov     [color_tbl.line.moded],eax
  409.         invoke  ini.get_color,ini_path,ini_sec_colors,ini_colors_line_saved,0x006ce26c
  410.         mov     [color_tbl.line.saved],eax
  411.  
  412.         invoke  ini.get_int,ini_path,ini_sec_window,ini_window_left,250
  413.         mov     [mainwnd_pos.x],eax
  414.         invoke  ini.get_int,ini_path,ini_sec_window,ini_window_top,75
  415.         mov     [mainwnd_pos.y],eax
  416.         invoke  ini.get_int,ini_path,ini_sec_window,ini_window_width,6*80+6+SCRLW+5
  417.         mov     [mainwnd_pos.w],eax
  418.         invoke  ini.get_int,ini_path,ini_sec_window,ini_window_height,402
  419.         mov     [mainwnd_pos.h],eax
  420.  
  421.         popad
  422.         ret
  423. endp
  424.  
  425. ;-----------------------------------------------------------------------------
  426. proc save_settings ;//////////////////////////////////////////////////////////
  427. ;-----------------------------------------------------------------------------
  428.         pushad
  429.  
  430.         movzx   eax,[tabs_pos]
  431.         invoke  ini.set_int,ini_path,ini_sec_options,ini_options_tabs_pos,eax
  432.         movzx   eax,[secure_sel]
  433.         invoke  ini.set_int,ini_path,ini_sec_options,ini_options_secure_sel,eax
  434.         movzx   eax,[auto_braces]
  435.         invoke  ini.set_int,ini_path,ini_sec_options,ini_options_auto_braces,eax
  436.         movzx   eax,[auto_indent]
  437.         invoke  ini.set_int,ini_path,ini_sec_options,ini_options_auto_indent,eax
  438.         movzx   eax,[smart_tab]
  439.         invoke  ini.set_int,ini_path,ini_sec_options,ini_options_smart_tab,eax
  440.         movzx   eax,[optim_save]
  441.         invoke  ini.set_int,ini_path,ini_sec_options,ini_options_optim_save,eax
  442.         movzx   eax,[line_nums]
  443.         invoke  ini.set_int,ini_path,ini_sec_options,ini_options_line_nums,eax
  444.  
  445.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_text,[color_tbl.text]
  446.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_back,[color_tbl.back]
  447.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_text_sel,[color_tbl.text.sel]
  448.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_back_sel,[color_tbl.back.sel]
  449.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_symbol,[color_tbl.symbol]
  450.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_number,[color_tbl.number]
  451.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_string,[color_tbl.string]
  452.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_comment,[color_tbl.comment]
  453.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_line_moded,[color_tbl.line.moded]
  454.         invoke  ini.set_color,ini_path,ini_sec_colors,ini_colors_line_saved,[color_tbl.line.saved]
  455.  
  456.         invoke  ini.set_int,ini_path,ini_sec_window,ini_window_left,[mainwnd_pos.x]
  457.         invoke  ini.set_int,ini_path,ini_sec_window,ini_window_top,[mainwnd_pos.y]
  458.         invoke  ini.set_int,ini_path,ini_sec_window,ini_window_width,[mainwnd_pos.w]
  459.         invoke  ini.set_int,ini_path,ini_sec_window,ini_window_height,[mainwnd_pos.h]
  460.  
  461.         popad
  462.         ret
  463. endp
  464.  
  465. ;-----------------------------------------------------------------------------
  466. proc start_fasm ;/////////////////////////////////////////////////////////////
  467. ;-----------------------------------------------------------------------------
  468. ; BL = run after compile
  469. ;-----------------------------------------------------------------------------
  470. ; FASM infile,outfile,/path/to/files[,run]
  471. ;-----------------------------------------------------------------------------
  472.         cmp     [cur_editor.AsmMode],0
  473.         jne     @f
  474.         ret
  475.     @@:
  476.         mov     eax,[tab_bar.Default.Ptr]
  477.         or      eax,eax
  478.         jnz     @f
  479.         mov     eax,[tab_bar.Current.Ptr]
  480.     @@: cmp     byte[eax+TABITEM.Editor.FilePath],'/'
  481.         je      @f
  482.         ret
  483.     @@:
  484.         mov     edi,fasm_parameters
  485.         push    eax
  486.  
  487.         cld
  488.  
  489.         lea     esi,[eax+TABITEM.Editor.FilePath]
  490.         add     esi,[eax+TABITEM.Editor.FileName]
  491.         push    esi esi
  492.     @@: lodsb
  493.         cmp     al,0
  494.         je      @f
  495.         stosb
  496.         cmp     al,'.'
  497.         jne     @b
  498.         mov     ecx,esi
  499.         jmp     @b
  500.     @@:
  501.         mov     al,','
  502.         stosb
  503.  
  504.         pop     esi
  505.         sub     ecx,esi
  506.         dec     ecx
  507.         jz      @f
  508.         rep     movsb
  509.     @@:
  510.         mov     al,','
  511.         stosb
  512.  
  513.         pop     ecx esi
  514.         add     esi,TABITEM.Editor.FilePath
  515.         sub     ecx,esi
  516.         rep     movsb
  517.  
  518.         cmp     bl,0 ; run outfile ?
  519.         je      @f
  520.         mov     dword[edi],',run'
  521.         add     edi,4
  522.     @@:
  523.         mov     al,0
  524.         stosb
  525.  
  526.         mov     [app_start.filename],app_fasm
  527.         mov     [app_start.params],fasm_parameters
  528. start_ret:
  529.         mcall   70,app_start
  530.         ret
  531. endp
  532.  
  533. ;-----------------------------------------------------------------------------
  534. proc open_debug_board ;///////////////////////////////////////////////////////
  535. ;-----------------------------------------------------------------------------
  536.         mov     [app_start.filename],app_board
  537.         mov     [app_start.params],0
  538.         jmp     start_ret
  539. endp
  540.  
  541. ;-----------------------------------------------------------------------------
  542. proc open_sysfuncs_txt ;//////////////////////////////////////////////////////
  543. ;-----------------------------------------------------------------------------
  544.         mov     [app_start.filename],app_docpak
  545.         mov     [app_start.params],sysfuncs_param
  546.         call    start_ret
  547.         cmp     eax,0xfffffff0
  548.         jb      @f
  549.         mov     [app_start.filename],app_tinypad
  550.         mov     [app_start.params],sysfuncs_filename
  551.         call    start_ret
  552.     @@: ret
  553. endp
  554.  
  555. set_opt:
  556.  
  557.   .dialog:
  558.         mov     [bot_mode],1
  559.         mov     [bot_dlg_height],128
  560.         mov     [bot_dlg_handler],optsdlg_handler
  561.         mov     [focused_tb],tb_color
  562.         mov     al,[tb_color.length]
  563.         mov     [tb_color.pos.x],al
  564.         mov     [tb_color.sel.x],0
  565.         mov     [tb_casesen],1
  566.         mov     [cur_part],0
  567.         m2m     [cur_color],dword[color_tbl.text]
  568.         mov     esi,color_tbl
  569.         mov     edi,cur_colors
  570.         mov     ecx,10
  571.         cld
  572.         rep     movsd
  573.         call    drawwindow
  574.         ret
  575.  
  576.   .line_numbers:
  577.         xor     [line_nums],1
  578.         ret
  579.   .optimal_fill:
  580.         xor     [optim_save],1
  581.         ret
  582.   .auto_indents:
  583.         xor     [auto_indent],1
  584.         ret
  585.   .auto_braces:
  586.         xor     [auto_braces],1
  587.         ret
  588.   .secure_sel:
  589.         xor     [secure_sel],1
  590.         ret
  591.  
  592. ;-----------------------------------------------------------------------------
  593.  
  594. include 'data/tp-defines.inc'
  595.  
  596. include 'tp-draw.asm'
  597. include 'tp-key.asm'
  598. include 'tp-button.asm'
  599. include 'tp-mouse.asm'
  600. include 'tp-files.asm'
  601. include 'tp-common.asm'
  602. include 'tp-dialog.asm'
  603. include 'tp-popup.asm'
  604. include 'tp-tbox.asm'
  605. include 'tp-tabctl.asm'
  606. include 'tp-editor.asm'
  607. include 'tp-recode.asm'
  608.  
  609. include 'external/dll.inc'
  610.  
  611. ;-----------------------------------------------------------------------------
  612. section @DATA ;:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  613. ;-----------------------------------------------------------------------------
  614.  
  615. ;include_debug_strings
  616.  
  617. include 'data/tp-idata.inc'
  618.  
  619. ;-----------------------------------------------------------------------------
  620. section @IMPORT ;:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  621. ;-----------------------------------------------------------------------------
  622.  
  623. library \
  624.         libini,'libini.obj',\
  625.         libio,'libio.obj',\
  626.         libgfx,'libgfx.obj',\
  627.         proc_lib,'proc_lib.obj'
  628.  
  629. import  libini, \
  630.         ini.get_str  ,'ini_get_str',\
  631.         ini.set_str  ,'ini_set_str',\
  632.         ini.get_int  ,'ini_get_int',\
  633.         ini.set_int  ,'ini_set_int',\
  634.         ini.get_color,'ini_get_color',\
  635.         ini.set_color,'ini_set_color'
  636.  
  637. import  libio, \
  638.         file.find_first,'file_find_first',\
  639.         file.find_next ,'file_find_next',\
  640.         file.find_close,'file_find_close',\
  641.         file.size      ,'file_size',\
  642.         file.open      ,'file_open',\
  643.         file.read      ,'file_read',\
  644.         file.write     ,'file_write',\
  645.         file.seek      ,'file_seek',\
  646.         file.tell      ,'file_tell',\
  647.         file.eof?      ,'file_iseof',\
  648.         file.truncate  ,'file_truncate',\
  649.         file.close     ,'file_close'
  650.  
  651. import  libgfx, \
  652.         gfx.open        ,'gfx_open',\
  653.         gfx.close       ,'gfx_close',\
  654.         gfx.pen.color   ,'gfx_pen_color',\
  655.         gfx.brush.color ,'gfx_brush_color',\
  656.         gfx.pixel       ,'gfx_pixel',\
  657.         gfx.move.to     ,'gfx_move_to',\
  658.         gfx.line.to     ,'gfx_line_to',\
  659.         gfx.line        ,'gfx_line',\
  660.         gfx.polyline    ,'gfx_polyline',\
  661.         gfx.polyline.to ,'gfx_polyline_to',\
  662.         gfx.fillrect    ,'gfx_fillrect',\
  663.         gfx.fillrect.ex ,'gfx_fillrect_ex',\
  664.         gfx.framerect   ,'gfx_framerect',\
  665.         gfx.framerect.ex,'gfx_framerect_ex',\
  666.         gfx.rectangle   ,'gfx_rectangle',\
  667.         gfx.rectangle.ex,'gfx_rectangle_ex'
  668.  
  669. import  proc_lib, \
  670.         OpenDialog_Init  ,'OpenDialog_init',\
  671.         OpenDialog_Start  ,'OpenDialog_start'
  672.  
  673. TINYPAD_END:     ; end of file
  674.  
  675. ;-----------------------------------------------------------------------------
  676. section @UDATA ;::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  677. ;-----------------------------------------------------------------------------
  678.  
  679. include 'data/tp-udata.inc'
  680.  
  681. ;-----------------------------------------------------------------------------
  682. section @PARAMS ;:::::::::::::::::::::::::::::::::::::::::::::::::::::::::::::
  683. ;-----------------------------------------------------------------------------
  684.  
  685. fasm_parameters:
  686.  
  687. p_info  process_information
  688. p_info2 process_information
  689. sc      system_colors
  690.  
  691. ini_path rb PATHL
  692.  
  693. ;---------------------------------------------------------------------
  694. temp_dir_pach:
  695.         rb 4096
  696. ;---------------------------------------------------------------------
  697. fname_Info:
  698.         rb 4096            ; filename
  699. ;---------------------------------------------------------------------
  700. filename_area:
  701.         rb 256
  702. ;---------------------------------------------------------------------
  703. rb 1024*4
  704. MAIN_STACK:
  705. rb 1024*4
  706. POPUP_STACK:
  707.  
  708. STATIC_MEM_END:
  709.  
  710. diff10 'Main memory size',0,$
  711.