home *** CD-ROM | disk | FTP | other *** search
/ OS/2 Shareware BBS: Science / Science.zip / goat006.zip / SRC.ZIP / goatsrc / Main / Form.1 < prev    next >
Text File  |  2002-08-13  |  3KB  |  108 lines

  1. /* Form events - Opened */
  2. Arg window 
  3.  
  4. /* load rexxutil functions */
  5. call RxFuncAdd 'SysLoadFuncs', 'RexxUtil', 'SysLoadFuncs'
  6. call SysLoadFuncs
  7. call RxFuncAdd 'VputilLoadFuncs', 'VPutil', 'VputilLoadFuncs'
  8. call VputilLoadFuncs
  9.  
  10. convertimage=0
  11. textfilename=''
  12. subtitle=''
  13. footer=''
  14. fontname=''
  15. filetypes='*.PNM;*.BMP;*.VGA;*.RLE;*.DIB;*.RL4;*.RL8;*.GIF;*.PCX;*.TIF;*.TGA;*.VST;*.AFI;*.IFF;*.LBM;*.VID;*.KPS;*.IAX;*.XBM;*.SPR;*.SPRITE;*.PSE;*.PSEG;*.PSEG38PP;*.PSEG3820'
  16. extensions='PNM BMP VGA RLE DIB RL4 RL8 GIF PCX TIF TGA VST AFI IFF LBM VID KPS IAX XBM SPR SPRITE PSE PSEG PSEG38PP PSEG3820'
  17. truesize=65536
  18. rotate=0
  19. defocrval.1=0        /* spacewidth         */
  20. defocrval.2=0        /* graylevel          */
  21. defocrval.3=10        /* dustsize           */
  22. defocrval.4=0        /* use database       */
  23. defocrval.5=0        /* layout analysis    */
  24. defocrval.6=1        /* compare mode       */
  25. defocrval.7=1        /* divide mode        */
  26. defocrval.8=1        /* context correction */
  27. defocrval.9=0        /* char packing       */
  28. defocrval.10=0        /* numeric only       */
  29. defocrval.11=0        /* more info          */
  30. defocrval.12=0        /* list chapes        */
  31. defocrval.13=0        /* list pattern       */
  32. defocrval.14=0        /* list all pattern   */
  33. defocrval.15=0        /* line infos         */
  34. defocrval.16=0        /* debug mode         */
  35. do i = 1 to 16
  36.   curocrval.i=''
  37. end
  38. drop i
  39. imageeditor=''
  40. imageparameters=''
  41. texteditor=''
  42. textparameters=''
  43. do i=0 to 2
  44.   texteditor.i=''
  45.   textparameters.i=''
  46. end /* end do */
  47. drop i
  48. textautorun=0
  49. imageautorun=0
  50. j=0
  51. inisize=0
  52. iniloc=SYSSEARCHPATH('PATH', 'goat.ini')
  53. goatloc=SYSSEARCHPATH('PATH', 'goat.exe')
  54. gocrconfigopen=0
  55. view='STANDARD'
  56. /* Select item ~Standard282 Menu Item */
  57. CALL VpSelect window,282
  58.  
  59. /* Add several items to end 1017 Spin Button */
  60. index=VpAddItem(window, 1017, 'END', '100', '75', '50', '25', '150')
  61.  
  62. /* Add several items to end 1018 Spin Button */
  63. index=VpAddItem(window, 1018, 'END', 'ISO', 'TeX', 'HTML')
  64.  
  65. mainwindow=window
  66. xsizeysize='600 400'
  67.  
  68. call centerwindow
  69.  
  70. if length(iniloc) > 0 then
  71.   do
  72.     /* get the number of lines in the inifile */
  73.     do until lines(iniloc)=0
  74.       z=LINEIN(iniloc)
  75.       inisize=inisize+1
  76.     end /* end do */
  77.     drop z
  78.     rc=stream(iniloc,'C','CLOSE')
  79.   end
  80. else
  81.   iniloc=filespec("path",goatloc)||"goat.ini"
  82.  
  83. if inisize=26 then
  84.   call readini
  85. else
  86.   do
  87.     call setini
  88.     call saveini
  89.   end
  90.   
  91. /* load the button bitmaps */
  92. do i = 1000 to 1015
  93.   value=VpLoadPicture('RESBMP',i)
  94.   /* Set item value text1002 Push Button */
  95.   CALL VpSetItemValue window,(i+2),value
  96. end
  97. drop i
  98. /*
  99.  
  100. /* Set item value 1018 Bitmap */
  101. CALL VpSetItemValue window,1018,value
  102. */
  103. /* load the program icon */
  104. value=VpLoadPicture('RESICON',3000)
  105.  
  106. /* Reset DISABLEUNDO style 1000 Image Editor */
  107. call VpImgEdt window, 1000, 'RESETDISABLEUNDO'
  108.