home *** CD-ROM | disk | FTP | other *** search
/ Black Box 4 / BlackBox.cdr / progbas / gfa.arj / GFA1 / VGADEMO1.GFA (.txt) < prev    next >
GFA-BASIC MS-DOS  |  1990-12-09  |  5KB  |  196 lines

  1. GFA-BASIC MS-DOS
  2. xalt_
  3. yalt_
  4. xpos_
  5. ypos_=$P$G
  6. COMSPEC=C:\COMMAND.COM
  7. PATH=.;C:\;C:\DOS;C:\BATCNC
  8. a_desktop
  9. =SUB(_Y,20)
  10. height
  11. desktop
  12. do_popup
  13. draw_figuremove_verticM
  14. ve_horizont//
  15. GFA-BASIC
  16. DemNN
  17.  GFA-BASIC Fenster 
  18. GFA-BASIC
  19. Demo-Program
  20. VGA-Resolution//
  21. demo-program
  22. creates
  23. GFA-BASIC
  24. window
  25. pop-up
  26. menu.
  27. Selecting
  28. entry
  29. pop-up
  30. causes
  31. drawing
  32. figure
  33. inside
  34. the//
  35. window.
  36. pop-up
  37. re-appears
  38. after
  39. pressing
  40. right
  41. mouse-button
  42. 'Tab'-key.
  43. program,
  44. position
  45. mouse-curser
  46. closer
  47. the//
  48. window
  49. press
  50. mouse-button
  51. press
  52. 'Esc'-key.SCREEN
  53. OPENW
  54. desktop
  55. =SUB(_X,10)
  56. width
  57. desktop
  58. =SUB(_Y,20)
  59. height
  60. desktop
  61. TITLEW
  62. GFA-BASIC
  63. Fenster
  64. window-title
  65. OPENW
  66. #1,10,10,
  67. /2,-1
  68. window
  69. subroutine
  70. pop-up
  71. menuDO
  72. event
  73. checkGETEVENT
  74. event
  75. MENU(1)=4
  76. closer
  77. event
  78. MENU(1)=1
  79. MENU(5)=$11B
  80. 'Esc'-key
  81. pressedIF
  82. MENU(4)=2
  83. right
  84. mouse-button
  85. pressed
  86. subroutine
  87. pop-up
  88. menuELSE
  89. MENU(1)=1
  90. MENU(5)=$F09
  91. 'Tab'-key
  92. pressed
  93. subroutine
  94. pop-up
  95. menuENDIF
  96. LISSAJOUS|figure _1|figure _22
  97. |figure _3|figure _4
  98.  figure Y
  99.  no entry selected 
  100. PROCEDURE
  101. pop-up
  102. subroutine
  103. LOCAL
  104. define
  105. local
  106. variables
  107. WINDGET
  108. outside
  109. coordinates
  110. window//
  111. specified
  112. upper
  113. corner,
  114. width
  115. height
  116. ="LISSAJOUS|figure
  117. _1|figure
  118. entries
  119. pop-up
  120. +"|figure
  121. _3|figure
  122. _4"WIN
  123. direct
  124. output
  125. desktop
  126. =POPUP(
  127. ,ADD(
  128. create
  129. pop-up
  130. right
  131. windowWIN
  132. direct
  133. output
  134. windowIF
  135. selected
  136. entryINFOW
  137. figure
  138. "+STR$(
  139. write
  140. info-line
  141. figure
  142. entry
  143. selected
  144. INFOW
  145. entry
  146. selected
  147. write
  148. info-line
  149. ENDIF
  150. RETURN
  151. buPR!
  152. PROCEDURE
  153. subroutine
  154. figure
  155. drawingsLOCAL
  156. define
  157. local
  158. variables
  159. LOCAL
  160. COLOR
  161. redPBOX
  162. 0,0,9999,9999
  163. clear
  164. windowCOLOR
  165. yellowSWITCH
  166. selected
  167. figure
  168. figure
  169. figure
  170. parameters
  171. figure
  172. figure
  173. parameters
  174. figure
  175. figure
  176. parameterCASE
  177. figure
  178. figure
  179. parameterENDSWITCH
  180. figure
  181. offset
  182. figure
  183. width/height
  184. >>=1,
  185. /*-------------------
  186. drawing
  187. algorithm
  188. --------------*/
  189. =ADD(ADD(
  190. =ADD(
  191. =ADD(ADD(
  192. *COSQ(
  193. =ADD(ADD(
  194. *SINQ(
  195. RETURN
  196.