home *** CD-ROM | disk | FTP | other *** search
/ PC World 2000 August / PCWorld_2000-08_cd.bin / Software / TemaCD / xbasic / xbpro.exe / xb / new.hlp < prev    next >
Text File  |  2000-01-15  |  32KB  |  880 lines

  1. '
  2. '
  3. ' ####################  Max Reason
  4. ' #####  XBasic  #####  copyright 1988-2000
  5. ' ####################  features not in documentation
  6. '
  7. ' subject to GPL and GPLL licenses - see gpl.txt, gpll.txt
  8. '
  9. ' http://www.maxreason.com/software/xbasic/xbasic.html
  10. ' http://www.egroups.com/group/xbasic
  11. ' maxreason@maxreason.com
  12. '
  13. ' for Windows XBasic
  14. ' for Linux XBasic
  15. '
  16. '
  17. ' The following information may or may not be included
  18. ' in the printed documentation or other documentation.
  19. '
  20. '
  21. ' #####################
  22. ' #####  v6.0000  #####  20000115
  23. ' #####################
  24. '
  25. '
  26. ' #####  v6.0000  #####  20000115
  27. '
  28. ' Linux XBasic brought into sync with Windows XBasic
  29. ' and both are released under GPL and GPLL licenses.
  30. '
  31. '
  32. ' #####  v5.0023  #####  20000111
  33. '
  34. ' The last two arguments to the XgrDrawImage() functions
  35. ' were supposed to specify x,y indent - which is how far
  36. ' left,down from the top-left corner of the target grid
  37. ' to draw the image.  But the XgrDrawImage() functions
  38. ' were ignoring those arguments, and drawing the image
  39. ' at the current "drawpoint" - which should have no
  40. ' effect on those function.
  41. '
  42. ' These functions are now fixed - the drawpoint is
  43. ' ignored and the last two arguments are x,y indent.
  44. '
  45. '
  46. ' #####  v5.0022  #####  19991230
  47. '
  48. ' The LTRIM$(), RTRIM$(), TRIM$() intrinsics trim
  49. ' all characters with values <= 0x20 and >= 0x80 .
  50. '
  51. ' This usually produces the appropriate and desired
  52. ' result on English language text.  But most other
  53. ' languages have more characters than English, and
  54. ' those extra characters are often put in the range
  55. ' >= 0x80 and occasionally in the range <= 0x20 .
  56. '
  57. ' Functions XstLTRIM(), XstRTRIM(), XstTRIM() were
  58. ' added to the "xst" library as alternatives to the
  59. ' intrinsic trim functions.  These functions require
  60. ' two arguments, the string to trim, and a 256 element
  61. ' XLONG array that contains zero in every location
  62. ' corresponding to a character that should be trimmed.
  63. '
  64. ' XstLTRIM (@string$, @array[])
  65. ' XstRTRIM (@string$, @array[])
  66. ' XstTRIM (@string$, @array[])
  67. '
  68. ' IMPORTANT NOTE:  These functions return 0 = success
  69. ' and -1 = failure, NOT a result string.  For efficiency,
  70. ' these functions work on the first argument in place,
  71. ' so the string argument must be passed by reference,
  72. ' or the string will not be modified.  The second
  73. ' argument must be passed by reference because arrays
  74. ' must always be passed by reference in XBasic.
  75. '
  76. ' The new "atrim.x" sample program illustrates and
  77. ' contrasts the intrinsics and the new functions.
  78. '
  79. '
  80. ' #####  v5.0022  #####  19991225
  81. '
  82. ' Added ROTATEL() "rotate left" intrinsic for symmetry with
  83. ' the ROTATER() intrinsic - at request of XBasic programmer.
  84. ' The new "arotate.x" sample program illustrates rotates.
  85. '
  86. '
  87. ' #####  v5.0021  #####  19991220
  88. '
  89. ' The following line in sample program "acrc32.x" worked
  90. ' in the development environment, but not in executables.
  91. '
  92. ' sum = (sum >> 1) XOR 0xEDB88320
  93. '
  94. ' The problem was in the XBasic "spasm.exe" assembler,
  95. ' which generated improper binary for "xor" instructions
  96. ' when the second operand was a literal number instead
  97. ' of a register or memory.
  98. '
  99. ' This problem is fixed in the "spasm.exe" assembler.
  100. '
  101. '
  102. ' #####  v5.0021  #####  19991220
  103. '
  104. ' XBasic programs containing the ROTATER() intrinsic
  105. ' worked correctly in the development environment, but
  106. ' not in executables.  In the assembly language XBasic
  107. ' generated for ROTATER, the shift-count register for
  108. ' the "ror" opcode was "ecx".  The "spasm.exe" assembler
  109. ' expected "cl" and therefore reported an error and did
  110. ' not emit the necessary "ror" machine instruction.
  111. '
  112. ' This problem is now fixed in the XBasic compiler,
  113. ' which now calls the shift-count register "cl".
  114. '
  115. '
  116. ' #####  v5.0021  #####  19991220
  117. '
  118. ' Though disfavored because the readability is much
  119. ' worse than the RETURN statement, functions have
  120. ' been able to return values as follows:
  121. '
  122. ' END FUNCTION  value_or_expression
  123. '
  124. ' But when XBasic programs were loaded into the development
  125. ' environment everything following END FUNCTION was lost.
  126. '
  127. ' This problem is now fixed.
  128. '
  129. '
  130. ' #####  v5.0020  #####  19991214
  131. '
  132. ' A minor problem with XgrGetClipboard() was fixed.
  133. '
  134. '
  135. ' #####  v5.0019  #####  19991213
  136. '
  137. ' A minor problem with ULONG type conversion was fixed.
  138. '
  139. '
  140. ' #####  v5.0018  #####  19991212
  141. '
  142. ' A new sample program was added, called "aspread.x".
  143. ' This program illustrates the case where you want to
  144. ' create a window containing a huge number of grids.
  145. '
  146. ' This sample program contains a 40x40 "spreadsheet"
  147. ' or array containing 1600 grids.  Even with the
  148. ' "another" button on the GuiDesigner toolkit, the
  149. ' time and effort required to create and position
  150. ' 1600 grids is substantial.
  151. '
  152. ' This program shows how to create and position the
  153. ' grids in a loop within the Resize subroutine, which
  154. ' is called at the end of the Create subroutine anyway.
  155. '
  156. ' This program also shows how individual elements can
  157. ' be conveniently selected, moved and highlighted with
  158. ' mouse-clicks and arrow-keys.  When a string is entered
  159. ' in the XuiTextLine grid, the first character is drawn
  160. ' in the selected spreadsheet grid.
  161. '
  162. ' This program toggles the keyboard focus back and forth
  163. ' between the XuiTextLine grid and the selected grid in
  164. ' the spreadsheet whenever an escape-key is pressed.
  165. '
  166. ' Windows with many display-fields but only one input-field
  167. ' are very convenient in a wide variety of applications.
  168. ' This sample program illustrates some reasonable ways
  169. ' to implement and operate such windows.
  170. '
  171. '
  172. ' #####  v5.0018  #####  19991212
  173. '
  174. ' Composite variables and arrays whose scope was specified
  175. ' to be SHARED by its # prefix caused compile-time errors.
  176. ' These errors did not occur for composite variables and
  177. ' arrays declared in SHARED statments.
  178. '
  179. ' This problem is now fixed.
  180. '
  181. '
  182. ' #####  v5.0018  #####  19991212
  183. '
  184. ' The XstStringToNumber() function returned the wrong
  185. ' datatype on numbers with the most-significant-bit set.
  186. ' For example, the following assignment to a GIANT variable
  187. ' did not work correctly, as the PRINT illustrated.
  188. '
  189. '    giant$$ = 2147483648 : PRINT g;; HEX$(g,16)
  190. '
  191. ' This problem is now fixed.
  192. '
  193. '
  194. ' #####  v5.0018  #####  19991212
  195. '
  196. ' In certain situation, the first floating-point value
  197. ' in a semi-colon separated list of print arguments
  198. ' would not be printed, for example:
  199. '
  200. '   PRINT INT(a); INT(b)
  201. '
  202. ' This rarely encountered problem is now fixed.
  203. '
  204. '
  205. ' #####  v5.0017  #####  19991125
  206. '
  207. ' Some people without TCP/IP networking on Windows95/98/NT
  208. ' have startup problems caused by some kind of problem with
  209. ' initialization of the "xin" function library.  Apparently
  210. ' these people can start XBasic when dial-up networking is
  211. ' currently connected, but not otherwise.
  212. '
  213. ' By default, the file "c:/windows/xb.ini" now contains
  214. ' the line "xin=false" which disables "xin" initialization.
  215. ' To program with the "xin" library, add a comment character
  216. ' to that line to enable the "xin" library - "' xin = false".
  217. '
  218. '
  219. ' #####  v5.0017  #####  19991125
  220. '
  221. ' Added #GetCharacterMapEntry and #SetCharacterMapEntry
  222. ' messages and tested them in XuiTextArea grids.  Without
  223. ' these messages it was impossible to change character maps
  224. ' of grids in "/xb/xxx/property.xxx".
  225. '
  226. '
  227. ' #####  v5.0016  #####  19991120
  228. '
  229. ' Added two more standard cursors to the sequence of
  230. ' XgrRegisterCursor() lines in the InitGui() function
  231. ' of GuiDesigner programs.  These two new cursors are
  232. '
  233. '   XgrRegisterCursor (@"hand",         @#cursorHand)
  234. '   XgrRegisterCursor (@"help",         @#cursorHelp)
  235. '
  236. ' Note that #cursorHand is not supported in versions
  237. ' of Windows prior to 5.0 - which means WindowsNT 5.0
  238. ' and maybe Windows2000.
  239. '
  240. '
  241. ' #####  v5.0015  #####  19991115
  242. '
  243. ' XBasic has a new main window.  Now XBasic looks "more modern"
  244. ' and more like some of those brand-X development environments.
  245. '
  246. ' Some of you will now complain, "Hey, I just learned how to
  247. ' operate the XBasic environment efficiently and you have to
  248. ' go and change it".  What's worse, the hot buttons have no
  249. ' writing on them anymore.  Will this start a riot?
  250. '
  251. ' Hopefully not.  All the hot buttons and other grids on
  252. ' the main window have "hint strings".  When you pause
  253. ' the mouse cursor over any grid, a little "hint window"
  254. ' will appear just above the upper-left corner of the grid,
  255. ' with a few words that describe what that grid is and does.
  256. '
  257. ' If you want more elaboration information, remember the
  258. ' built-in InstantHelp that has always been there - just
  259. ' click the right mouse button on any grid to display
  260. ' the InstantHelp window with more elaborate information
  261. ' on that grid.  You can add/delete/modify the contents of
  262. ' the InstantHelp window, then click the "update" button.
  263. ' This updates the help-text for that grid, so from then on
  264. ' you'll see the modified text for that grid whenever you
  265. ' request InstantHelp for that grid again.
  266. '
  267. ' You can still execute "dot commands", but now you enter
  268. ' them in the command grid instead of the upper TextArea.
  269. ' The command grid has a pulldown list of previous commands
  270. ' you executed so you can recover and repeat them easily.
  271. ' XBasic sometimes puts information in the command grid,
  272. ' for example the steps of compilation as they progress.
  273. '
  274. ' Escape keystrokes still toggle the text cursor back
  275. ' and forth between the lower TextArea and command grid.
  276. '
  277. ' The sample program "anewlook.x" is nearly identical to
  278. ' the new XBasic main window, so you can examine the code.
  279. ' You can load "anewlook.x" into the environment and run it.
  280. '
  281. ' All the icons for "anewlook.x" and the new main window
  282. ' are in the "\xb\xxx" directory - all have .BMP extents.
  283. ' If you dislike some of the icons, all you have to do is
  284. ' make new ones you like, name them the same as the ones
  285. ' you want to replace in the XBasic main window, and put
  286. ' them in the "\xb\xxx" directory (overwrite the old one).
  287. ' Maybe you should back up all the .BMP files in "\xb\xxx"
  288. ' first - just in case your icons look even worse!  :-O
  289. '
  290. ' You can see what your new icons will look like in XBasic
  291. ' without changing XBasic.  Just change the icon names in
  292. ' the XuiSendMessage (g, #SetImage, ...) functions in the
  293. ' MainWindow() function in the "anewlook.x" sample program.
  294. ' Change the existing icon names to new icon names.  Perhaps
  295. ' the easiest technique is to make a \xb\xxx\xxx subdirectory,
  296. ' copy all the existing .BMP files to that directory, then
  297. ' replace every occurrence of "D:\\xb\\xxx\\" in MainWindow()
  298. ' to "D:\\xb\\xxx\\xxx\\".  Then you can do your icon work
  299. ' in "D:\\xb\\xxx\\xxx\\" and freely test with "anewlook.x"
  300. ' without changing the XBasic main window --- until later.
  301. ' To do this, view MainWindow(), then enter this dot command:
  302. '
  303. '  .r D:\\\\xb\\\\xxx    D:\\\\xb\\\\xxx\\\\xxx
  304. '
  305. ' Make all your replacement icons exactly 16x16 pixels.
  306. ' If you're totally convinced you have more recognizable
  307. ' and/or attractive replacement icons, send them to me.
  308. ' If I agree, I'll put them in future XBasic releases.
  309. '
  310. '
  311. ' #####  v5.0015  #####  19991115
  312. '
  313. ' The XuiDropButton and XuiListButton generate a #Notify
  314. ' callback message when the button is clicked.  This lets
  315. ' programs update the XuiPullDown or XuiList grid that
  316. ' drops below the button.  This generally useful feature
  317. ' had to be added to support the convenient FUNCTION list
  318. ' in the new XBasic main window.  When the function button
  319. ' is clicked, XBasic sends a #SetTextArray message to the
  320. ' XuiListButton grid with a sorted list of function names.
  321. '
  322. ' The #Notify message was not previous defined, so you
  323. ' need add a line to your InitGui() function to register
  324. ' that message in any program you want to process #Notify.
  325. '
  326. '
  327. ' #####  v5.0015  #####  19991115
  328. '
  329. ' The XuiListButton grid sizes more intelligently and
  330. ' decides whether to display the list above or below
  331. ' more intelligently.  The XuiListBox has not been
  332. ' similarly updated yet.
  333. '
  334. '
  335. ' #####  v5.0014  #####  19991110
  336. '
  337. ' Several people have asked for a sample program that
  338. ' shows how to create a window and draw simple graphics
  339. ' with only GraphicsDesigner AKA "xgr" functions - and
  340. ' no GuiDesigner AKA "xui".
  341. '
  342. ' A new sample program called "agraphic.x" is now
  343. ' included in the XBasic distribution to demonstrate
  344. ' simple GraphicsDesigner capabilities.
  345. '
  346. '
  347. ' #####  v5.0014  #####  19991110
  348. '
  349. ' All three versions of the XgrDrawCircle() function
  350. ' cleared the area inside the circle after drawing it.
  351. ' That is now fixed.
  352. '
  353. '
  354. ' #####  v5.0012  #####  19991001
  355. '
  356. ' Several GuiDesigner grid-types have been enhanced,
  357. ' modified or tweaked, including:
  358. '
  359. ' XuiProgress - supports styles 0 to 2
  360. ' XuiScrollBarH - supports styles 0 to 3
  361. ' XuiScrollBarV - supports styles 0 to 3
  362. ' XuiDropBox - pulldown is now an accessible kid grid
  363. ' XuiDropButton - pulldown is now an accessible kid grid
  364. ' XuiListBox - pulldown is now an accessible kid grid
  365. ' XuiListButton - pulldown is now an accessible kid grid
  366. ' XuiList - supports styles 0 to 3 (passes to scroll-bars)
  367. ' XuiTextArea - supports styles 0 to 3 (passes to scroll-bars)
  368. ' XuiCheckBox - supports styles 0 to 3
  369. ' XuiRadioBox - supports styles 0 to 3
  370. '
  371. ' None of the above are extensively tested.
  372. ' Please report any bugs or peculiarities.
  373. '
  374. '
  375. ' #####  v5.0011  #####  19990925
  376. '
  377. ' When a new font is set in XuiPullDown, XuiList, XuiTextArea,
  378. ' and XuiTextLine grids, the interline spacing is now correct.
  379. ' Previously the interline spacing would not always adjust in
  380. ' the appropriate manner.
  381. '
  382. ' #####  v5.0011  #####  19990925
  383. '
  384. ' When programs set the font of XuiDropBox and XuiDropButton
  385. ' grids with #SetFont or #SetFontNumber, the font propogates
  386. ' to the pulldown list.  Previously programs were not able to
  387. ' set the font in the pulldown list.
  388. '
  389. ' Another change has been made on a provisional basis, but
  390. ' may be made permanent if no adverse consequences occur.
  391. ' The pulldown list is now accessible as an additional kid
  392. ' of the XuiDropBox and XuiDropButton grids.  Because the
  393. ' pulldown list is in a separate window, this violates one
  394. ' GuiDesigner convention - that kid grids must be in the
  395. ' same window as their parents.  This makes it possible
  396. ' to set font and other properties on the pulldown list
  397. ' of these grids in the Appearance Window - by selecting
  398. ' the pulldown list kid and setting the desired properties.
  399. ' If undesired consequences or problems are found with this
  400. ' approach, this aspect may be changed, in which case the
  401. ' pulldown list will probably share at least color and font
  402. ' properties with the XuiDropBox or XuiDropButton grid.
  403. '
  404. '
  405. ' #####  v5.0011  #####  19990925
  406. '
  407. ' XBasic and executables created from XBasic programs
  408. ' do not work [properly] on some computers that do not
  409. ' have networking configured or enabled.  Now you can
  410. ' stop the "xin" function library from initializing
  411. ' [and potentially failing or locking-up] by putting
  412. ' a "xin=false" line in text file "c:/windows/xb.ini".
  413. ' If "xb.ini" does not already exist on your system,
  414. ' go ahead and create it and add the line.
  415. '
  416. '
  417. ' #####  v5.0010  #####  19990902
  418. '
  419. ' XgrGrabPoint() was not fixed properly in v5.0009,
  420. ' but hopefully is correct now.
  421. '
  422. '
  423. ' #####  v5.0009  #####  19990821
  424. '
  425. ' XgrGrabPoint() was not working properly, always
  426. ' returning 0, 0, 0, 0 for red, green, blue, color.
  427. ' This is now fixed.  NOTE:  Not every video card
  428. ' supports reading the color of arbitrary pixels.
  429. '
  430. '
  431. ' #####  v5.0007  #####  19990725
  432. '
  433. ' Support for two new border styles has been added to
  434. ' GraphicsDesigner - $$BorderRise2 and $$BorderSink2.
  435. ' These styles are simple 2-pixel wide raise and lower
  436. ' borders like $$BorderRaise2 and $$BorderLower2, but
  437. ' the 2 adjacent lines are drawn in different colors.
  438. ' One line is drawn in lowlight and lowtext color,
  439. ' and the other in highlight and hightext color.
  440. '
  441. ' The GuiDesigner AppearanceWindow does not support
  442. ' these new styles yet, so you'll need to set the
  443. ' border style to something else, then change the
  444. ' arguments of the #SetBorder message appropriately.
  445. '
  446. '
  447. ' #####  v5.0007  #####  19990725
  448. '
  449. ' The XstGetCommand(@line$) function was added
  450. ' to the XBasic standard function library.
  451. '
  452. ' This function returns the entire command line
  453. ' in a single string argument.  This makes cgibin
  454. ' programs slightly easier to write in XBasic.
  455. '
  456. '
  457. ' #####  v5.0006  #####  19990715
  458. '
  459. ' GuiDesigner grids have always had a HintString property,
  460. ' but previously it had no effect on program operation.
  461. ' Now the HintString is active.
  462. '
  463. ' When the mouse cursor pauses for about 1 second over
  464. ' a grid that has a HintString property, a "hint window"
  465. ' containing the HintString is displayed just above the
  466. ' upper-left corner of the grid.  The hint window is
  467. ' hidden when the mouse moves or 4 seconds expires.
  468. '
  469. '
  470. ' #####  v5.0005  #####  19990611
  471. '
  472. ' XuiPushButton grids can now be configured as "flat buttons"
  473. ' by setting the style attribute to 2, which can be done with:
  474. '
  475. '   XuiSendMessage (grid, #SetStyle, 2, 0, 0, 0, $Kid, 0)
  476. '
  477. ' where $Kid is the kid-number of the button grid you want
  478. ' to change.
  479. '
  480. '
  481. ' #####  v5.0005  #####  19990611
  482. '
  483. ' The XuiMenu and XuiMenuBar now highlight the menubar entry
  484. ' the mouse is above, even when no mouse button is not down.
  485. '
  486. '
  487. ' #####  v5.0005  #####  19990611
  488. '
  489. ' A new sample application is included called "anewlook.x".
  490. ' This is a new look for the XBasic development environment
  491. ' that you can improve upon and submit for review.  The look
  492. ' selected as the best new design will become the new look
  493. ' of XBasic for future releases.  Submit your "anewlook.x"
  494. ' files to maxreason@maxreason.com before 1999/07/31.
  495. '
  496. '
  497. ' #####  v5.0004  #####  19990522
  498. '
  499. ' XBasic GuiDesigner now has two new messages that affect
  500. ' character and line spacing of [multi-line] text in grids.
  501. '
  502. ' new message : #GetTextSpacing
  503. ' new message : #SetTextSpacing
  504. '
  505. ' XBasic GuiDesigner programs send these messages as usual:
  506. '
  507. ' XuiSendMessage (grid, #GetTextSpacing, @xgap, @ygap, 0, 0, kid, 0)
  508. ' XuiSendMessage (grid, #SetTextSpacing, @xgap, @ygap, 0, 0, kid, 0)
  509. '
  510. ' xgap : positive or negative to increase or decrease character spacing.
  511. ' ygap : positive or negative to increase or decrease line spacing.
  512. '
  513. ' xgap currently has no effect of text drawing
  514. ' ygap currently does effect text drawing
  515. '
  516. ' As a simple demonstration, #SetTextSpacing currently reduces
  517. ' the line spacing of the XBasic startup window by 4 pixels.
  518. '
  519. '
  520. ' #####  v5.0002  #####  19990513
  521. '
  522. ' XBasic now recognizes two new command line arguments:
  523. '
  524. '  -ft filename.ext
  525. '  -fl filename.ext
  526. '
  527. ' -ft means "File TextLoad"
  528. ' -fl means "File Load"
  529. '
  530. ' This means you can now associate files with a .x extent
  531. ' to XBasic.  Once you do this, selecting any file with a
  532. ' .x extent will start XBasic and have XBasic load the file.
  533. '
  534. ' To associate an extent with XBasic, start Windows Explorer,
  535. ' select "View FolderOptions FileTypes NewType", then enter
  536. ' the following information:
  537. '
  538. '   description of file : XBasic program
  539. '   associated extension : .x
  540. '
  541. ' Then click the "New" button and enter:
  542. '
  543. '   action : open
  544. '   application to perform action : c:\xb\xb.exe -fl
  545. '
  546. ' If you want to have XBasic load .x files as text-files
  547. ' instead of programs, enter "c:\xb\xb.exe -ft" instead.
  548. ' If you want to associate any other type of file with
  549. ' XBasic, you must have XBasic load them as text-files.
  550. '
  551. ' If XBasic is not installed on your "c:" drive, change
  552. ' "c:" in the above examples to the appropriate drive.
  553. '
  554. '
  555. ' #####  v5.0001  #####  19990512
  556. '
  557. ' On some Windows98 systems, some button images in the
  558. ' XBasic main window would sometimes appear solid black
  559. ' with no image.  This Windows98 bug is worked around
  560. ' in v5.0001 and should no longer occur.
  561. '
  562. '
  563. ' #####  v4.0020  #####
  564. '
  565. ' A "sockets" function library has been added to provide
  566. ' a portable interface to sockets and networks in general
  567. ' and the internet in particular.  This is not documented
  568. ' currently, but you can look at "xin.dec" for function
  569. ' prototypes and demo programs "aclient.x" and "aserver.x"
  570. ' for examples of how simple clients and servers call the
  571. ' the "xin" library functions.
  572. '
  573. '
  574. ' #####  v4.0018  #####
  575. '
  576. ' Before v4.0018, a bug would sometimes occur when
  577. ' a function argument is both passed by @reference
  578. ' AND of a different data type than the declared
  579. ' type that requires reconversion to the argument
  580. ' type after the function returns.
  581. '
  582. '
  583. ' #####  v4.0017  #####
  584. '
  585. ' Before v4.0017, intrinsic a$ = CHR$(byte,length)
  586. ' will sometimes return a string in a$ that is not
  587. ' terminated by a zero byte aka null terminator.
  588. '
  589. '
  590. ' #####  v4.0017  #####
  591. '
  592. ' Before v4.0017, the following three standard library
  593. ' functions take and return the year argument in 1900
  594. ' relative form, as in 97 instead of 1997.  Since these
  595. ' functions all treat the year the same, programs that
  596. ' call these functions may work properly, but probably
  597. ' will produce errors when run on other implementations.
  598. '
  599. ' XstGetDateAndTime ()
  600. ' XstDateAndTimeToFileTime ()
  601. ' XstFileTimeToDateAndTime ()
  602. '
  603. ' XstGetDateAndTime (@year, @month, @day, ... )
  604. ' returned (year-1900) in the year argument instead
  605. ' of the year.  In other words, if the date today is
  606. ' 1997 March 15, the year argument would return a
  607. ' value of 97 instead of 1997.  This error has been
  608. ' fixed as of v4.0017.
  609. '
  610. ' XstDateAndTimeToFileTime (@year, @month, ... )
  611. ' expected (year-1900) in the year argument instead
  612. ' of year.  This error has been fixed as of v4.0017.
  613. '
  614. ' XstFileTimeToDateAndTime (filetime$$, @year, ... )
  615. ' returned (year-1900) in the year argument instead
  616. ' of year.  This error has been fixed as of v4.0017.
  617. '
  618. '
  619. ' #####  v4.0016  #####
  620. '
  621. ' A few of the math library routines have been rewritten
  622. ' in assembly language for increased speed and precision.
  623. ' Since most of the other math functions functions call
  624. ' these rewritten functions, almost every function in the
  625. ' math library is faster and/or slightly more accurate.
  626. ' Some functions are 3x to 4x faster than before.
  627. '
  628. ' The functions moved into assembly language include:
  629. '
  630. ' SIN()  :  COS()  :  TAN()  :  ATAN()
  631. ' SQRT() :  EXP()  :  EXP2() :  EXP10()  :  POWER()
  632. '
  633. ' POWER() is called whenever a number is raised to
  634. ' a power by the ** operator, as in "a# = b# ** c#",
  635. ' which means "raise b# to the c# power".
  636. '
  637. '
  638. ' #####  v4.0015  #####
  639. '
  640. ' The initial properties of grids are the defaults for
  641. ' the grids or those set by the program.  A feature was
  642. ' added recently that lets users change the properties
  643. ' of grids after a program is running.  Now a new feature
  644. ' lets users specify initial values for specific grids,
  645. ' or whole classes of grids.
  646. '
  647. ' The initial properties of a specific grid or group of
  648. ' grids can be specified in "$XBDIR/xxx/property.xxx".
  649. ' After a program creates a new window and all the grids
  650. ' in that window, it will now send a #SetGridProperties
  651. ' message to the main window grid.  The window grid will
  652. ' then propogate the message to its kids and so forth if
  653. ' the v0 argument is -1, which it will generally be.
  654. '
  655. ' The default message processing function function for
  656. ' #SetGridProperties is XuiSetGridProperties().  This
  657. ' function looks for matches between entries in the
  658. ' "default property database" and the grid.  Each entry
  659. ' that matches the grid and has valid syntax "executes"
  660. ' the entry to change properties of that grid.
  661. '
  662. ' Entries match on the basis of program, gridtype, and
  663. ' gridname.  Since the program, gridtype, and gridname
  664. ' fields can be "wildcarded" with "*", properties of
  665. ' every grid of a given gridtype can be specified in
  666. ' a single entry.  For example, it takes only one line
  667. ' to change the border of all XuiLabel grids in one,
  668. ' or even all programs.
  669. '
  670. ' The "$XBDIR/xxx/property.xxx" file contains examples
  671. ' and more information.  This feature is new and still
  672. ' under development.
  673. '
  674. '
  675. ' #####  v4.0013  #####
  676. '
  677. ' The following feature is "work in progress" that
  678. ' does not operate properly in every circumstance.
  679. ' This feature is described here so you may sample
  680. ' it and have an early chance to report bugs and
  681. ' annoying aspects so we can fix them soon.
  682. '
  683. ' The appearance properties of ANY GuiDesigner grid
  684. ' can be interactively modified at any time by means
  685. ' of the Appearance Window.  This includes any grid
  686. ' in programs you are running in the environment, any
  687. ' grid in the development environment itself, and any
  688. ' grid created by .EXE and .DLL programs and libraries
  689. ' you create from XBasic programs.  In other words,
  690. ' this capability is fully available to people who
  691. ' use your programs.  If you want, you can disable
  692. ' this feature in programs you distribute as follows:
  693. '
  694. ' XgrGridTypeNameToNumber (@"Appearance", @gridType)
  695. ' XuiGetGridTypeGrids (gridType, @g[])
  696. ' IF g[] THEN Appearance (g[0], #SetStyle, 0x01, 0, 0, 0, 0, 0)
  697. '
  698. ' Certain problems exist when you set properties of
  699. ' XuiTextArea and XuiTextLine grids unless you set
  700. ' the attributes on the "outer" parent grid.  These
  701. ' grid types contain a featureless grid that fills
  702. ' the innards of the XuiTextArea and XuiTextLine
  703. ' grid and displays the text.  Thus if you click
  704. ' anywhere in the body of the grid you will select
  705. ' the "innard" grid and set the properties of that
  706. ' grid without the knowledge of its parent.  This
  707. ' can cause problems in certain situations, which
  708. ' you may see.  If you click on the pixel in the
  709. ' bottom right corner of these grids you can select
  710. ' the XuiTextArea or XuiTextLine grid itself and
  711. ' setting appearance properties should work okay.
  712. '
  713. ' Not implemented at this time, but intended for
  714. ' the final release of this feature is the ability
  715. ' to set the appearance attributes of any grid TYPE.
  716. ' Once grid TYPE attributes are changed, all grids
  717. ' of that grid type are created with the new values.
  718. '
  719. '
  720. ' #####  v4.0013  #####
  721. '
  722. ' Previous implementations of XBasic padded fixed
  723. ' length strings in composite variables differently.
  724. ' Furthermore, the documentation was inconsistent.
  725. '
  726. ' When a normal string was assigned to a longer fixed
  727. ' length string in a composite variable, the extra bytes
  728. ' in the fixed length string were filled with 0x00 in
  729. ' some implementations and with 0x20 in others.
  730. '
  731. ' This difference caused a different behavior when the
  732. ' fixed length composite string was assigned to a normal
  733. ' string.  When the extra bytes in fixed length strings
  734. ' were filled with 0x20 bytes, then those 0x20 bytes were
  735. ' also assigned to the normal string and thus the length
  736. ' of the normal string was always the same as the fixed
  737. ' length string that was assigned to it.  When the extra
  738. ' bytes in fixed length strings were filled with 0x00,
  739. ' only the bytes before the first 0x00 were assigned to
  740. ' the normal string, and the normal string could be any
  741. ' length from zero bytes up to the size of the composite
  742. ' fixed length string.
  743. '
  744. ' From v4.0013 onward, all versions and implementations
  745. ' of XBasic fill extra bytes in composites with a 0x00.
  746. ' In the other method, it was usually necessary to apply
  747. ' the TRIM$() intrinsic to a normal variable after a
  748. ' fixed length string was assigned to it.  Now this is
  749. ' generally not necessary.
  750. '
  751. '
  752. ' #####  v4.0012  #####
  753. '
  754. ' Each time XBasic or an XBasic program is started, a
  755. ' "fonts.xxx" file is built in the "xxx" subdirectory.
  756. ' This file contains a list of non-scalable fonts.
  757. '
  758. ' If you do not like the default font for some reason,
  759. ' you can specify a new "default font" by putting any
  760. ' name you find in the "fonts.xxx" file in a "font.xxx"
  761. ' file in the same "xxx" subdirectory.  Henceforth the
  762. ' default font for all grids is initialized to the font
  763. ' you specified.
  764. '
  765. ' If the character mapping is wrong on your system, it
  766. ' may be that the default font is intended for another
  767. ' locale or country.  You should be able to solve this
  768. ' problem by creating a "font.xxx" file.  If "font.xxx"
  769. ' does not exist, the normal default font is selected.
  770. '
  771. ' The "font.xxx" file may contain more than one line
  772. ' and more than one font name.  Lines that begin with
  773. ' a ' comment character are ignored.  The first line
  774. ' that is not empty and not commented out is assumed
  775. ' to be the specified default font.  If the specified
  776. ' default font cannot be created, the normal default
  777. ' font is selected.
  778. '
  779. '
  780. ' #####  v4.0011  #####
  781. '
  782. ' Add : XgrGetKeystateModify (state, @modify, @edit)
  783. '
  784. ' Programs can pass the v2 aka state argument in #KeyDown
  785. ' messages to XgrGetKeystateModify() to find out whether
  786. ' the #KeyDown message will modify text by inserting or
  787. ' deleting one or more characters.
  788. '
  789. ' Currently this function treats Cntl+Insert as an edit
  790. ' keystroke that modifies the text, even though the usual
  791. ' action for this keystroke combination is to copy the
  792. ' selected text to the clipboard without modifying the
  793. ' text itself in any way.  Cntl+Insert may cease to
  794. ' claim a modify in the future, so programs that need
  795. ' to be precise about this issue should check for this
  796. ' case separately.
  797. '
  798. ' XgrGetKeystateModify() reports modify for keystrokes
  799. ' that normally have the POTENTIAL to modify text without
  800. ' consideration of whether the keystroke will modify text
  801. ' in any particular grid.  For example, if the text cursor
  802. ' is at the start of text when a Backspace key is entered,
  803. ' there is no "previous" character to delete.  Likewise,
  804. ' if the text cursor is at the end of text when a Delete
  805. ' key is entered, there is no "next" character to delete.
  806. ' If the clipboard is empty when the Insert key is entered,
  807. ' there is no text to insert at the text cursor position.
  808. ' In all these cases text is not modified, but the modify
  809. ' argument is returned TRUE aka non-zero.
  810. '
  811. ' This function is provided as a "normal case" convenience
  812. ' function, but cannot be relied upon by all programs in
  813. ' all situations.  Where precise information is required,
  814. ' or when non-standard keyboards or keystroke combinations
  815. ' will occur, programmers must determine the degree of
  816. ' applicability of this function and suppliment or replace
  817. ' it as appropriate.
  818. '
  819. '
  820. ' #####  v4.0011  #####
  821. '
  822. ' Add : XgrGetGridCharacterMapArray (grid, @map[])
  823. ' Add : XgrSetGridCharacterMapArray (grid, @map[])
  824. '
  825. ' Programs can now install and examine a "character map"
  826. ' for each grid to change the character printed for any
  827. ' character value.  map[] must be an XLONG array and must
  828. ' contain at least elements 0x00 to 0xFF.  When a program
  829. ' calls any GraphicsDesigner function that draws text in
  830. ' a grid, the map array converts every character in the
  831. ' text string to the corresponding character in the array
  832. ' before it displays the string.  The following code makes
  833. ' lower case characters display as upper case equivalents:
  834. '
  835. '   DIM map[255]
  836. '   FOR i = 0 TO 255
  837. '     SELECT CASE TRUE
  838. '       CASE (i < 'a') : map[i] = i
  839. '       CASE (i > 'z') : map[i] = i
  840. '       CASE ELSE      : map[i] = i - 0x20
  841. '   NEXT i 
  842. '   XgrSetCharacterMapArray (grid, @map[])
  843. '
  844. ' acharmap.x is a sample character map program included
  845. ' with all XBasic releases of v4.0011 and higher.
  846. '
  847. '
  848. ' #####  v4.0011  #####
  849. '
  850. ' Mod : XgrGetCommandLineArguments (@argc, @argv$[])
  851. ' Add : XgrSetCommandLineArguments ( argc, @argv$[])
  852. '
  853. ' Programs can now alter the command line arguments with
  854. ' XgrSetCommandLineArguments().  This is convenient for
  855. ' debugging programs in the development environment where
  856. ' the command line arguments are not appropriate to the
  857. ' program begin debugged.
  858. '
  859. ' Even after the command line arguments are changed,
  860. ' programs can get the original values of the command
  861. ' line arguments by passing a negative value as the
  862. ' first argument to XgrGetCommandLineArguments().
  863. '
  864. '   argc = 3
  865. '   DIM argv$[2]
  866. '   argv$[0] = "zap"
  867. '   argv$[1] = "zap.x"
  868. '   argv$[2] = "zap.zap"
  869. '   XstSetCommandLineArguments ( argc, @argv$[])
  870. ' '
  871. ' ' get original command line arguments : argc < 0
  872. ' '
  873. '   argc = -1
  874. '   XstGetCommandLineArguments (@argc, @argv$[])
  875. ' '
  876. ' ' get current command line arguments : argc >= 0
  877. ' '
  878. '   argc = 0
  879. '   XstGetCommandLineArguments (@argc, @argv$[])