home *** CD-ROM | disk | FTP | other *** search
/ World of Shareware - Software Farm 2 / wosw_2.zip / wosw_2 / CPROG / BOSS_SUP.ZIP / REV.HST < prev    next >
Text File  |  1992-03-05  |  38KB  |  808 lines

  1. /*
  2. ** WINDOWS - Simple but Elegant Window Functions 
  3. **           (Datalight, Lattice, CI86, Microsoft, Borland
  4. **            Zortech, Mix PowerC, Manx AZTEC C, WATCOM)
  5. **
  6. ** Copyright (c) 1984 - 1991 - Philip A. Mongelluzzo
  7. ** All rights reserved.
  8. **
  9. ** Revision History in reverse order:
  10. **
  11. **  The following changes were incorporated in the 03/15/92 release:
  12. **
  13. **              Added wns_gfrm2 to workaround problems Topspeed C had
  14. **              in compiling wn_frmget.
  15. **              (wn_frmget.c)                           (V7.02)
  16. **
  17. **              Added pulldown functions.  This is actually a replacement
  18. **              for wn_popup but adding it in this way will protect
  19. **              existing users software investment.
  20. **              (wn_pdown.c)                            (V7.01)
  21. **
  22. **              Certified Borland C++ 3.0 and TC++ for Windows
  23. **              (no code changes)                       (V7.00)
  24. **
  25. **              Certified Microsoft Quick C for Windows.
  26. **              (no code changes)                       (V6.16)
  27. **       
  28. **              wn_frmget was not BACK TABBING over display text.
  29. **              Thanks to Rick Brown for reporting the problem and
  30. **              the fix.
  31. **              (wn_frmget.c)                           (V6.15)
  32. **
  33. **        wn_getca was calling wns_err with an incorrect parameter.
  34. **        (wn_puts.c)                (V6.14)
  35. **
  36. **  The following changes were incorporated in the 10/31/91 release:
  37. **
  38. **              Certified WATCOM 8.5, MIX Power C 2.10
  39. **              Borland TC++ 1.01, Borland TC 2.01, Borland C 2.0
  40. **
  41. **              Dropped formal support of CI86, Datalight,
  42. **              Aztec, and Watcom's EXPRESS C.
  43. **              DO NOT CONFUSE EXPRESS C WITH WATCOM'S OPTIMIZING
  44. **              C COMPILER.
  45. **                      
  46. **              Added wn_getca (get char and atrib from window).
  47. **              (wn_puts)                               (V6.13)
  48. **
  49. **              Added wn_gmltext (get multiline text)
  50. **              (wn_gtext, winboss.h)                   (V6.12)
  51. **
  52. **              Taught wn_input about ^RightArrow and ^LeftArrow.
  53. **              AKA word right and word left.  Ground work for
  54. **              wn_gtxbuf (get text buffer).
  55. **              (wn_input, winboss.h)                   (V6.11)
  56. **
  57. **              Added wn_gssn - get social security number
  58. **              (wn_gssn, wn_frmget, winboss.h)         (V6.10)
  59. **
  60. **              Added wn_clreol - Clear to end of line
  61. **              Added wn_clreow - Clear to end of window
  62. **              (wn_clrfns)                             (V6.09)
  63. **
  64. **              Added wn_gedate - get European date.
  65. **              (winboss.h, wn_frmget, wn_gedate)       (V6.08)
  66. **
  67. **              v_setatr & v_setrev are no longer macros, they are
  68. **              now functions.
  69. **              (winboss.h, wn_bios)                    (V6.07)
  70. **
  71. **              New shadow window type 510 which provides transparrent
  72. **              shadow (dimly lit characters). NOTE: windows with
  73. **              transparrent shadows can be moved freely, however,
  74. **              once they have been covered by another window and
  75. **              are moved the shadow area will loose sync with
  76. **              the underlying text.  This is not a bug it is a
  77. **              restriction.
  78. **              (wn_open, wn_move, wn_activ)            (V6.06)
  79. **
  80. **              Added v_gctype - get cursor type.  Ya all asked for it
  81. **              so ya all got it.
  82. **              (wn_bios)                               (V6.05)
  83. **
  84. **              wn_popup was not handling BACKSPACE correctly. Thanks
  85. **              to Harold Jackson for reporting the problem. 
  86. **              (wn_popup.c, winboss.h)                 (V6.04)
  87. **
  88. **              WN_SBIT's definition changed in TCVLIB.ASM
  89. **              (tcvlib.asm)                            (V6.03)
  90. **
  91. **              "windows.h"   renamed to "winboss.h"
  92. **              "windows.ext" renamed to "winboss.ext"
  93. **              "windows.fns" renamed to "winboss.fns"
  94. **              These changes were made to eliminate the pontential
  95. **              conflict between Borland C++ (2.X) and The Window BOSS.
  96. **              (various)                               (V6.02)        
  97. **
  98. **  The following changes were incorporated in the 01/07/91 release:
  99. **
  100. **  12.26.90 -  wn_hlinit was allocating more memory than was needed.
  101. **              (wn_help.c)                             (V6.01)
  102. **
  103. **              TopSpeed "C" support added.
  104. **              (windows.h, windows.fnt)
  105. **
  106. **              wn_gulong was short 1 byte on the mask it passes 
  107. **              to wn_input.c.  Thanks to the TopSpeed Compiler for
  108. **              finding this.
  109. **
  110. **              Moved v_getchm() to "wn_mouse.c" to eliminate including
  111. **              ANY mouse code from applications that do not call
  112. **              any of the mouse functions.  v_getchm() was previously
  113. **              located in "wn_bios.c".
  114. **
  115. **              Microsoft 6.00A certification.
  116. **
  117. **  12.14.90 -  wn_close was not setting wn->shadow to FALSE when
  118. **              closing shadowed windows.  This was causing wn_activate
  119. **              to do potentially foolish things.       (V6.00)        
  120. **
  121. **  (11.01.90)  ** [Limited distribution release]
  122. **
  123. **  09.14.90 -  Watcom 8.0 Support                      (V5.22)
  124. **
  125. **  08.25.90 -  Added v_getchm() - get character or mouse press.
  126. **              (wn_mouse, wn_bios, windows.c, 
  127. **              windows.ext)                            (V5.21)
  128. **
  129. **  07.25.90 -  Zortech 2.10 Support.                   (V5.20)
  130. **
  131. **  07.23.90 -  Mix Power C 2.00 Support.               (V5.19)
  132. **
  133. **  07.18.90 -  Turbo C++ Support.  Created TCVLIB.ASM to get around
  134. **              Borland's oversight with regard to "CONST".
  135. **              (wn_print.c, tcvlib.asm)                (V5.18)
  136. **
  137. **  The following changes were incorporated in the 07.01.90 release:
  138. **
  139. **  06.16.90 -  Cosmetic and misc changes: (BOSSDEMO.C,
  140. **              MAKELIB.BAT (LC6), include memory model directives
  141. **              for Lattice 6.XX batch files).           
  142. **              Thanks again to Bill Hinkle.            (V5.17)
  143. **
  144. **              QuickC 2.5 Support.                            
  145. **
  146. **              MSC 6.0 Support.  Changed "windows.h" to CAST
  147. **              NULL as an int.
  148. **              (windows.h)                                    
  149. **
  150. **  04.04.90 -  wn_help was taught to use wn_putsa to enforce user
  151. **              specified help screen attributes.  Tip of the hat
  152. **              to Chris Madsen.
  153. **              (wn_help.c)                             (V5.16)
  154. **
  155. **  03.23.90 -  Added "wns_escape". This is set to TRUE by wn_input
  156. **              whenever ESCAPE has terimated the input.  ESCAPE
  157. **              now terminates input for all input field types.
  158. **              (wn_gbool, wn_gdate, wn_double, wn_gfloat, wn_gphone)
  159. **              (wn_gtime, wn_guint, wn_gulong, wn_gint)
  160. **              Thanks Dexter!!                         (V5.15)
  161. **
  162. **  03.12.90 -  Due to popular request, wn_open now range checks
  163. **              the window parameters to make sure that the window
  164. **              will actually fit on the screen.  NULL is returned
  165. **              if not.  This will prevent some cockpit "bad handle"
  166. **              error exits.
  167. **              (wn_open.c)                             (V5.14)
  168. **
  169. **  03.08.90 -  Added wn_hlinit, wn_help, wn_popup, and wn_qpopup.
  170. **              These functions are close clones to the old sample
  171. **              code provided in help.c and popup.c.  HELP.C and
  172. **              POPUP.C will no longer be distributed.
  173. **              (wn_help.c, wn_popup.c, windows.h)
  174. **              (genindex.c)                            (V5.13)
  175. **
  176. **  03.07.90 -  Placed all "externals" in "windows.ext".  This is
  177. **              being done to ease the burden of making changes
  178. **              to both global and external data.  This will also
  179. **              keep all the constants in one place.
  180. **              (windows.c, windows.h, windows.ext)     (V5.12)
  181. **
  182. **  03.06.90 -  HELP Key is now user definable.  The global wns_hkey
  183. **              has been added and defaults to F1.  This global
  184. **              can be set directly of via the wn_shkey() function.
  185. **              (windows.c, wn_init.c)                  (V5.11)
  186. **
  187. **  03.04.90 -  Added wn_stitle (Supertitle).  wn_stitle provides
  188. **              (top, bottom) (centered, left, right) titles!
  189. **              wn_stitle.c                             (V5.10)
  190. **
  191. **  03.03.90 -  Added wn_gatext - get ascii (ANY ascii text).
  192. **              Now you can input graphics characters!
  193. **              Tnx to Werner Schonber for the suggestion.
  194. **              wn_gtext.c                              (V5.09)
  195. **
  196. **  03.01.90 -  Fine tuned overlap detection to improve performance.
  197. **              wn_activ.c                              (V5.08)
  198. **
  199. **  02.25.90 -  Shadow window support. wn_activ.c, wn_close.c,
  200. **              wn_move.c, windows.h, windows.c, wn_open.c 
  201. **                                                      (V5.07) 
  202. **
  203. **  02.24.90 -  Eliminated most of the assembler functions.  This
  204. **              was done to provide better support for the HUGE
  205. **              memory model.
  206. **              (c:{wn_bios, wn_mouse, wn_sup}, *.asm)  (V5.06)
  207. **
  208. **  02.04.90 -  Linked exploding windows to time of day clock.
  209. **              Added wns_gticks() in wn_open.c.
  210. **              nap() in BOSSDEMO now uses wns_gticks.
  211. **              (wn_open.c)                             (V5.05)
  212. **
  213. **  02.03.90 -  wn_sdelspc was not handling requests to delete 
  214. **              trailing and leading spaces from strings that were
  215. **              only spaces!  Tnx es a tip-o-de-hat to Pat Elam,
  216. **              M. G. F. Gilliland, M.D., and Harold Jackson.
  217. **              (wn_string.c)                           (V5.04)
  218. **
  219. **  01.28.90 -  wns_movscr was not allowing for 132 column or
  220. **              wider screens.  It was taught how to allocate memory 
  221. **              for user defined physical screen sizes.  Thanks to the
  222. **              folks at Atomic Energy of Canada LTD. 
  223. **              (wn_sup.c)                              (V5.03)
  224. **
  225. **           -  v_cls() in "wn_bios" was taught about wni_mxrows 
  226. **              and wni_mxcols. 
  227. **              (wn_bios.c)                             (V5.02)
  228. **
  229. **  01.20.90 -  Pulldown code in BOSSDEMO would not work if called
  230. **              twice.  The problem was traced to the "winopn" member
  231. **              of the static structure mainbar.  Setting "mainbar.winopn"
  232. **              to FALSE before "wn_close(mainbar.wpsave)" in "pddemo()"
  233. **              solves the potential problem.  Thanks to Russ Brown for
  234. **              reporting the problem. 
  235. **              (bossdemo.c)                            (V5.01)
  236. **
  237. **              Version conversion table:
  238. **              
  239. **                   Base Release    Base Version
  240. **                      ??.??.86        1.00
  241. **                      ??.??.87        2.00
  242. **                      ??.??.88        3.00
  243. **                      ??.??.89        4.00
  244. **                      ??.??.90        5.00        
  245. **
  246. **  The following changes were incorporated in the 02.15.90 release:
  247. **                         AKA Version 5.00
  248. **
  249. **  01.10.90 -  WCVLIB.ASM created.  This file contains the assembly 
  250. **              language routines for WATCOM 7.0.  Previous versions of
  251. **              WATCOM should use MSVLIB.ASM.  
  252. **
  253. **  01.05.89 -  Physical windows wider than 80 columns were not 
  254. **              working correctly.  Thanks to all who reported this
  255. **              problem. (wn_actic.c, wn_sup.c, windows.c, wn_init.c).
  256. **              The constant "4096" was not removed in wn_savres. It
  257. **              does not impact the physical sceen size logic but does 
  258. **              allow the code of those who have "tinkered" with video 
  259. **              pages to continue to work.
  260. **
  261. **  12.22.89 -  Re-assembled all assembly language routines to insure
  262. **              that wni_mxcols, wni_mxrows, and wni_mxneed were being
  263. **              used correctly.
  264. **
  265. **  11.30.89 -  ZORTECH 2.0 Support.  Please note that ZORLIB version
  266. **              2.0 can not create a usable LWIN.LIB.  Microsoft's LIB
  267. **              works fine and should be used.  ZORTECH has been notified
  268. **              of the problem.
  269. **
  270. **  11.24.89 -  jeesh... One line exploding windows exploded again!
  271. **              This time we got the gremlin!! Tnx to Michael Canfield
  272. **              for suppling the test case.
  273. **
  274. **  (11.15.89)  ** [Limited distribution release]
  275. **
  276. **  10.28.89 -  Modified wn_title to insure ALL compiliers process
  277. **              hex values that are imbedded into the title properly.
  278. **              (e.g. "Hello \xcd There!")
  279. **              Thanks to Don Wahl for pointing out the discrepancy.
  280. **
  281. **  10.25.89 -  It would appear that the PC/PC_CLONE BIOS can not deal 
  282. **              with scrolling single line windows.  wn_insrow() was taught 
  283. **              to erase single line windows and avoid using the 
  284. **              BIOS for this special case.  This problem does not exist
  285. **              on AT or PC/2 class machines.  Thanks to Harold Jackson
  286. **              for reporting the problem.
  287. **
  288. **  10.24.89 -  Eliminated a potential multiple cursor problem with
  289. **              the mouse cursor when a window is being saved/restored
  290. **              with an active mouse.  Tip of the hat to Steve Thatcher
  291. **              of Attachmate.
  292. **
  293. **  10.20.89 -  Corrected a bug in wn_open to allow 1 line exploding 
  294. **              windows to function properly.  Thanks to John F. La Fleur 
  295. **              for reporting the problem.
  296. **
  297. **              wn_puts was not handling borderless windows properly.
  298. **              Thanks to Tim Keane for reporting the problem.
  299. **
  300. **              Lattice Version 6.0 Support
  301. **
  302. **  09.27.89 -  Logic was added to wn_input to insure that user supplied
  303. **              non null editing buffers are the same lenth as their masks!
  304. **              This logic will prevent garbage from appearing when 
  305. **              wn_input is called to peform data entry with a prefilled
  306. **              value in the user buffer (ubuff).
  307. **
  308. **  09.05.89 -  The forms package now treats the ESCcape
  309. **              like most common applications do.  That is to say that it 
  310. **              causes the current operation to cease.  Current 
  311. **              Window BOSS users please note that this feature can
  312. **              be disabled by removing the code in wn_frmget that contains
  313. **              "ESC.001" as part of the comments.
  314. **
  315. **  09.05.89 -  Added 1st character sensitivity to the sample popup menu
  316. **              code. ** NOTE ** -> For menu's that have different 1st
  317. **              character picks.  
  318. **              
  319. **  (08.25.89)  ** [Limited distribution release]
  320. **
  321. **  08.23.89 -  Exploding window opens were failing on SOME 
  322. **              adapters.  Even size exploding windows were
  323. **              failing. Corrected!
  324. **              Thanks to Richard Allen for his assistance.
  325. **
  326. **  The following changes were incorporated in the 07.01.89 release:
  327. **
  328. **  06.17.89 -  Lattice 3.41!! ... The version release race is on!
  329. **
  330. **  05.29.89 -  Mix Power C 1.30 Support.  
  331. **
  332. **  05.25.89 -  Added wn_gutext and wn_gltext.  Get upper case only
  333. **              and lower case only text functions.  Thanks to
  334. **              Charlie Munao for the suggestion.  Improved code 6/6/89.
  335. **
  336. **  05.23.89 -  wn_frmcls now sets the form pointer to the form being
  337. **              closed to NFRM and the individual field pointers to
  338. **              NFLD. This should help those who attempt to dectect
  339. **              if a form/field is active.        
  340. **
  341. **  05.10.89 -  wn_close now sets the window pointer to the window 
  342. **              being closed to WNLPTR.  This should help those who
  343. **              attempt to detect if a window is open.
  344. **
  345. **           -  Moved definition of FAR MEMORY marcos from "wn_sup.c"
  346. **              and "wn_activ.c" to "windows.h".
  347. **
  348. **  05.06.89 -  By popular request... WN_FRMGET now displays both the
  349. **              field prompt and data entry mask for all fields prior
  350. **              to accepting input for the 1st field.  Accomplished by
  351. **              introducing "wni_frmflg" which is used/tested by
  352. **              all the data entry functions, wn_input, and wn_frmget.
  353. **
  354. **  05.05.89 -  Exploding window logic was tweeked to provide smoother
  355. **              explosions.  
  356. **
  357. **  05.04.89 -  Incorporated support for user defined PHYSICAL screen
  358. **              size.  New globals: wni_mxrows, wni_mxcols, wni_mxneed.
  359. **              Globals are defined in "windows.c" and are referenced in
  360. **              "windows.h".  The globals are max rows, max cols, and max
  361. **              memory required to save a *complete* screen image (rows *
  362. **              col * 2).  A new version of wn_init, wn_psinit has be
  363. **              provided to properly set the globals.  Refer to the manual
  364. **              for a complete discussion.  The defaults are 25, 80, and 
  365. **              4000.  Usefull for applications and/or systems that run
  366. **              in 43 line EGA or 50 line VGA mode.  Since The BOSS
  367. **              assumes the screen size to be fixed, wn_psinit must be
  368. **              called before ANY windows are opened.
  369. **
  370. **  04.30.89 -  v_kstat now returns TRUE rather than (-1). This conforms
  371. **              to the constant in "windows.h".  Thanks to Clive Basson
  372. **              at Infostat!
  373. **
  374. **           -  wns_dput (internal routine) was modified to call
  375. **              wns_savres for all writes.  This will improve
  376. **              normal screen output (speed) in most cases.
  377. **
  378. **           -  wns_drow (internal routine) now calls wns_savres 
  379. **              for all writes. This will improve normal screen 
  380. **              output (speed) in most cases.
  381. **
  382. **           -  wn_title now calls wn_dput to write title for 
  383. **              faster title writes.
  384. **
  385. **  04.15.89 -  wn_gulong corrected to use common "%lu" .vs. "%U"
  386. **
  387. **  04.05.89 -  Watcom 7.0 Support.  Tip of the hat to the folks at
  388. **              the Watcom Compiler factory... Once again, they proved
  389. **              that you can release a MAJOR upgrade without breaking
  390. **              anybody's hard work (code).
  391. **
  392. **  04.04.89 -  Lattice 3.4X support. (LC3) Tip of the hat to
  393. **              William Hinkle & Jon Martin (UNISYS) for thier comments,
  394. **              suggestions and support.
  395. **
  396. **           -  Float/Double promotion & demotion caused wn_gfloat 
  397. **              trouble.  Resolved with #if LC3 in wn_gfloat. (LC3)
  398. **
  399. **           -  windows.h was modified to eliminate warnings 
  400. **              about undefined control blocks and include
  401. **              stdlib.h for proper memory allocation
  402. **              prototypes. (LC3)
  403. **
  404. **           -  Fixed LCP.BAT, APMODEL.BAT, and ADMODE.BAT (LC3)
  405. **
  406. **           -  Eliminated *true* unreferenced variables. (LC3)
  407. **
  408. **  03.11.89 -  Quick C Version 2.0 support. 
  409. **
  410. **  03.10.89 -  wn_frmopn/cls was tweeked to be a bit smarter about
  411. **              memory allocation & deallocation.  Tip of the hat
  412. **              to Barry Roomberg & Peter Spreadborough.  This 
  413. **              solves the *very* random "NULL POINTER" message
  414. **              on exit. 
  415. **
  416. **  The following changes were incorporated in the 02.01.89 release:
  417. **
  418. **  02.01.89 -  Mouse support, get double, get unsigned long,
  419. **              get password, left justify string, right justify string
  420. **              center string, delete leading and/or trailing blanks.
  421. **              Files: wn_mouse.c, wn_string.c, wn_gpword.c
  422. **              Files: wn_gdouble.c, wn_gulong.c
  423. **
  424. **  12.26.88 -  wn_restore was modified to allow for those who like to
  425. **              diddle with a "wn_save"d screen image.  This also 
  426. **              corrected a potential problem with restoring saved 
  427. **              images.  Thanks to Mike Blaszczak for reporting the
  428. **              conflict.
  429. **
  430. **  08.01.88 -  added #if __TURBOC__ to windows.c
  431. **
  432. **  The following changes were incorporated in the 08.15.88 release:
  433. **
  434. **  07.24.88 -  wn_puts() was not fixing up color attributes on mono
  435. **              systems - corrected.
  436. **
  437. **  07.10.88 -  AZTEC "C" support.  Thanks to Dexter McCloud for his
  438. **              assistance.
  439. **
  440. **           -  help() has been modified to be compatiable with
  441. **              AZTEC.  Please take note as format of the ".hlp" file
  442. **              has changed. Refer to Intelc.hlp for examples.
  443. **
  444. **  07.03.88 -  WATCOM "C" support.
  445. **
  446. **           -  smartened up wn_frmopn() & wn_frmcls() to avoid
  447. **              possible NULL Pointer Assignments.
  448. **
  449. **           -  cleaned up pointer conversion warnings in wn_activate,
  450. **              wn_close, wn_open, wn_restore, wn_save. defined
  451. **              WNLPTR in windows.h.
  452. **            
  453. **           -  eliminated various warning messages during compilation,
  454. **              Lattice still complains for no valid reason on a few
  455. **              modules.
  456. **
  457. **           -  wns_alloc now use runtime routines allocating memory
  458. **              in the large model, dos routines in small code models.        
  459. **
  460. **           -  wns_alloc allocates and immediately frees all available 
  461. **              memory in the small data memory models before allocating far 
  462. **              memory. This eliminates memory mgmt clashes for some
  463. **              compilers.  
  464. **
  465. **           -  eliminated the need for "peek.c"
  466. **
  467. **  06.29.88 -  Corrected wn_activate to always fixup the cursor
  468. **              display for the activated window.  Thanks to
  469. **              John P. Toscano for reporting the problem.
  470. **
  471. **  06.12.88 -  Functions in wn_activate & wn_sup that call _vidblt
  472. **              and xferdata were taught how to deal with variable
  473. **              offsets from wns_alloc.  
  474. **
  475. **  The following changes were incorporated in the 06.01.88 release:
  476. **
  477. **  06.01.88 -  Incoporated data entry routines!
  478. **
  479. **              Smartened up wn_puts on border detection.
  480. **
  481. **  05.14.88 -  Added: wn_putc  (window put character)
  482. **                     wn_putca (window put character & attribute)
  483. **              Both can be found in the WN_PUTS.C file.          
  484. **
  485. **  05.10.88 -  wn_dmode was now properly sets PAINT & FLASH modes for
  486. **              EGA video adapters - Thanks to Mike Gross from
  487. **              West Germany
  488. **
  489. **  The following changes were incorporated in the 05.06.88 release:
  490. **
  491. **  05.06.88  - Support for MIX Power C added. - Tip of the hat to
  492. **              Bob Lewis for his assistance.
  493. **
  494. **  04.27.88  - The declaration of _stklen was removed from BOSSDEMO.C,
  495. **              this will keep Turbo C happy.
  496. **
  497. **  03.22.88  - wn_activate ability to detect window overlap and
  498. **              handle borderless windows was improved.
  499. **
  500. **  03.22.88  - popup was taught how to handle text on the 0th line.
  501. **
  502. **  03.19.88  - v_spage was loading BH instead of AL. Thanks to
  503. **              Ross Schaach (TRAX, Corp.)
  504. **
  505. **  02.10.88  - wn_gets was modified to insure that charcters being
  506. **              echoed stay within the window borders.  Thanks to
  507. **              Dave McCracken for the suggestion.
  508. **
  509. **  01.14.88  - static declarations of filbuf and showpage were removed
  510. **              in help.c
  511. **
  512. **  The following changes were incorporated in the 11.20.87 release:
  513. **
  514. **  11.13.87  - Microsoft Ver 5.0 & Quick C Support
  515. **
  516. **  09.21.87 - wn_activate was occasionally incorrectly determining
  517. **             window overlap.  Thanks to the folks at Datalight
  518. **             and Marden Marshall for reporting the problem and supplying
  519. **             test cases.
  520. **
  521. **  09.17.87 - wn_init() and wn_exit() were modified to work around
  522. **             Turbo C's inability to handing allocating far memory
  523. **             in the large model.
  524. **
  525. **  09.07.87 - wns_push(), wns_pop(), wn_activate(), wn_move(),
  526. **             wns_image(), and wns_blt() were modified to use a table
  527. **             of global segments, offsets, and pointers.
  528. **             This was done to support the wn_init() and wn_exit()
  529. **             functions.  
  530. **
  531. **             wn_init() and wn_exit() added.  wn_init() must be the
  532. **             first window fucntion called and it must only be called
  533. **             once.  It works in conjucntion with wn_exit() to insure
  534. **             that the screen image on application entry is restored
  535. **             to the "T" on application exit.  wn_exit() must be the 
  536. **             last window function called.  One can not be used without
  537. **             the other.  Both should be used but are neither are
  538. **             required.
  539. **
  540. **  09.05.87 - wn_delrow was calling v_locate with args reversed
  541. **             causing the wrong section of the screen to be cleared
  542. **             on single line borderless windows.  Thanks to Paul
  543. **             Stephenson of Rockwell International for reporting both
  544. **             the problem and the cure.
  545. **
  546. **  09.03.87 - All assembler routines in DLVLIB.ASM now save/restore
  547. **             the SI & DI registers.  Datalight 3.10 and later 
  548. **             specific. The -w and -p command line parameters must
  549. **             be used when compiling The Window BOSS source code
  550. **             under Datalight 3.10 and later.
  551. **
  552. **  The following changes were incorporated in the 08.22.87 release:
  553. **
  554. **  08.10.87 - Added wns_dmode() to set the display mode.  
  555. **             wns_dmode(PAINT) sets the window display mode to paint
  556. **             style, wn_dmode(FLASH) sets the display mode to 
  557. **             flash style.  This function eliminates the need to set
  558. **             wn_sbit and wns_mtflg to produce the desired effects.
  559. **
  560. **  07.17.87 - wn_puts() & wn_putsa() perform simple range checking to
  561. **             insure that the string being displayed is/stays within
  562. **             the target window.
  563. **
  564. **  06.22.87 - Let's "C" specific code removed. Support will continue
  565. **             for previous versions but Mark William's products will
  566. **             not be supported in this or future releases.  This
  567. **             action is being as the result of compiler limitations.
  568. **
  569. **  06.17.87 - wn_activate now does INSTANT screen updates. Ditto
  570. **             for wn_move.  wn_mtype() returns 1 for EGA.  
  571. **             BLAZING screen updates on EGAs.
  572. **
  573. **  06.07.87 - wns_wtext() was incorrectely computing the offset for
  574. **             windows with wn_wrap enabled!
  575. **
  576. **  The following changes were incorporated in the 06.04.87 release:
  577. **
  578. **  06.03.87  - Support for BORLAND Turbo C!!
  579. **
  580. **  The following changes were incorporated in the 05.12.87 release:
  581. **
  582. **  05.12.87  - wns_text was incorrectly compensating for single line
  583. **              borderless windows (Attachmate follow up).
  584. **
  585. **  05.04.87  - EXPLODING windows are now supported!! Simply add 800 to
  586. **              the video page when calling wn_open()!
  587. **
  588. **            - Calls of the form wn_insrow(wn,0) and wn_delrow(wn,0) 
  589. **              caused the border to be klobbered.  wn_insrow() and
  590. **              wn_delrow() were taught about borders.
  591. **
  592. **  03.31.87  - wn_printf [wns_wtext()] was incorrectly displaying graphics 
  593. **              characters. Thanks to Mark MacGee for reporting the problem.
  594. **
  595. **  03.23.87  - Attachmate reported that wn_gets was doing funny things
  596. **              on single line bordered windows on PCs and PC clones but
  597. **              was fine on ATs and AT clones!  It would appear that the
  598. **              PC/PC_CLONE BIOS can not deal with scrolling single line
  599. **              windows.  wn_delrow() was taught to erase single line
  600. **              windows and avoid using the BIOS for this special case.
  601. **
  602. **  03.19.87  - Argh!! Datalight elected to use M_I86 as a predefined
  603. **              equate.  References to M_I86 were changed to 
  604. **              MSCV3 | MSCV4. (Datalight 3.XX)
  605. **
  606. **  The following changes were incorporated in the 03.15.87 release:
  607. **
  608. **  03.01.87  - wn_activate was incorrectly computing the coordinates of
  609. **              unbordered windows.  Thanks to Peter Fletcher for reporting
  610. **              the problem and supplying a solution.
  611. **
  612. **  01.22.87  - wn_dborder() was using the wrong attribute (wn-style,
  613. **              instead of wn->bstyle). Thanks to Peter Partch for
  614. **              reporting the problem and supplying a solution.
  615. **
  616. **  01.06.87  - wn_activate was not walking through the current linked 
  617. **              list of windows. In rare cases this would cause two
  618. **              windows to be considered non-overlapping when in fact
  619. **              they were.  Thanks to Robert Klotz for reporting the
  620. **              problem.
  621. **
  622. **  The following changes were incorporated in the 01.01.87 release:
  623. **
  624. **  12.19.86  - Removed a needless call to wn_err(wn,"wn_printf") in
  625. **              wn_title().
  626. **
  627. **  12.16.86  - Improved centering logic for window titles.
  628. **              Thanks to Steve Liberty for suggesting the change.
  629. **
  630. **  12.14.86  - Incorporated compiler specific equates in windows.h.
  631. **
  632. **  12.13.86  - wns_mtype() returns 0 for mode 3, 2 for mode 0 or 2,
  633. **              and 7 for mode 7. (Internal Use - This change allowed
  634. **              for the prevention of blue on black characters when
  635. **              the video mode is 2 and a color monitor is in use.
  636. **              (wns_fixc & wns_mtype).
  637. **
  638. **            - BASIC support for Mark Williams "Lets C".
  639. **
  640. **            - Tightend free() checks in wn_activate, wn_close, and
  641. **              wn_restore.
  642. **
  643. **  12.12.86  - wn_puts() was not adding the original physical cursor
  644. **              location to the logical cursor location. 
  645. **              Thanks to Marek Glowacki for reporting the problem.
  646. **
  647. **  12.10.86  - Allow v_locate() to position the cursor slightly off
  648. **              the screen.  Previous limit was (24,79) current limit
  649. **              is (25,80) which is just beyond the edge of the screen.
  650. **              This was done to insure that hidden cursors remain out
  651. **              of view.
  652. **
  653. **            - Improved cursor handling when wn_dmaflg = FALSE.
  654. **
  655. **  12.09.86  - Taught wn_activate to honor cursor position of window
  656. **              being activated. This will insure the cursor is always
  657. **              in the right logical and physical position. 
  658. **              More cosmetic enhancement than logic error correction.
  659. **
  660. **  The following changes were incorporated in the 12.01.86 release:
  661. **
  662. **  11.28.86  - Reverse video attribute was not being set correctly
  663. **              on MGAs - corrected.
  664. **
  665. **  11.19.86  - wn_dborder was incorrectly computing the row offset.
  666. **              Thanks to Steve Thatcher for reporting the problem.
  667. **              
  668. **  11.16.86  - Added ".smeth" member to window control block. This 
  669. **              member defines the scrolling method to be used in
  670. **              the window. It can be set to BIOS or DMAS, the default
  671. **              is DMAS.  
  672. **
  673. **            - All routines that reference wn_activate will return
  674. **              NULL if the window could not be activated.  This is 
  675. **              usually due to a lack of free memory.
  676. **
  677. **  The following changes were incorporated in the 11.14.86 release:
  678. **
  679. **  11.13.86  - Closing windows in random order when exiting "sometimes"
  680. **              produced null pointer assignment error messages or 
  681. **              incorrect screen images - corrected.
  682. **
  683. **            - wn_natrib() was not storing the newly defined window
  684. **              attribute in the window control block - corrected.
  685. **
  686. **  11.09.86  - Support for Datalight C added.
  687. **
  688. **  11.02.86  - v_border() added.  Allows color of border area to be
  689. **              set on CGAs with color monitors.
  690. **
  691. **  11.01.86  - wn_fixcsr was not adding the original physical cursor
  692. **              location to the logical cursor location. 
  693. **              Thanks to Bill Harts for reporting the problem.
  694. **
  695. **            - wn_puts was computing the virtual cursor location
  696. **              incorrectly. Thanks to Eric Lundstrom!
  697. **
  698. **            - Logic to dectect null strings was incorporated into
  699. **              _vidblt.  This will prevent 64k worth of trash from
  700. **              being blitted to the video ram.
  701. **
  702. **  10.30.86  - All references to MSC in "windows.h" were changed
  703. **              to M_I86.  This forces "windows.fns" to be included
  704. **              under Microsoft C.  This change was also applied to
  705. **              "windows.c".
  706. **
  707. **  10.26.86  - Full float, long, etc. support for wn_printf in
  708. **              all Lattice versions.  Microsoft 3.XX is the only
  709. **              one in the dark ages.
  710. **
  711. **  10.23.86  - Tip of the hat to Russ Thackson for the improved
  712. **              overlaping window detection technique incorporated
  713. **              in wn_activate().
  714. **
  715. **  The following changes were incorporated in the 10.22.86 release:
  716. **
  717. **  10.22.86  - wn_activate() was causing unnecessary window 
  718. **              thrashing on non-overlapping windows. Corrected.
  719. **
  720. **  The following changes were incorporated in the 10.10.86 release:
  721. **
  722. **  09.27.86  - Tiled windows are now supported! wn_activate() added.
  723. **
  724. **            - wn_gets() was not calling wns_err - corrected.  This
  725. **              was not a bug, just continued support for wild pointer
  726. **              checks.
  727. **
  728. **  09.25.86  - New logic for vidblt(). Fast mode now works on color
  729. **              without causing snow or flicker!!  Video updates now 
  730. **              occur at the fastest possible speed!  The effect of
  731. **              wn_sbit now conforms exactly to the description in the
  732. **              manual.
  733. **
  734. **            - wn_printf (CI86) now has full float support. Thanks
  735. **              to Rob Sullivan for reporting the CI86 problem. Lattice
  736. **              and MSC Version 3.0 are the only hold outs for full
  737. **              wn_print support.  MSC Version 3.0 support will never
  738. **              be incorporated. If you are using MSC Version 3.00 
  739. **              you will have to upgrade to Version 4.XX.  The price
  740. **              of the update is well worth it. Version 4.00 is a
  741. **              work of art! Lattice support will be delayed until
  742. **              Lattice gets around to supporting vsprintf() as
  743. **              defined by the evolving ANSI standard.
  744. **
  745. **  09.17.86  - seperate modules to decrease memory overhead.
  746. **
  747. **            - link list support (wn_open,wn_close,WINDOWPTR struct)
  748. **              This is the ground work for tiled window support.
  749. **
  750. **  09.02.86  - use registers in wns_savres() for speed (MSC).
  751. **
  752. **  The following changes were incorporated in the 08.30.86 release:
  753. **
  754. **  08.28.86  - wn_gets was delclared as (char *) but returning
  755. **              (void).  Corrected to return (char *).
  756. **
  757. **  08.27.86  - wns_wtext() was not correctly handling borderless
  758. **              windows. Corrected.
  759. **
  760. **            - wn_printf() was not correctly handing cases such as:
  761. **              wn_printf(wn,"%s %d %f %d\n", "text", 2, 2.2, 5);
  762. **              The window boss now supports a complete implementation
  763. **              of printf formatting under Microsoft C Version 4.00.
  764. **              All other compilers and versions support an INTEGER only
  765. **              wn_printf.  This will be corrected in a future release.
  766. **
  767. **  08.16.86  - Added wn_gets(). Get string in window with validation.
  768. **
  769. **  The following chages were incorporated in the 06.02.86 release.
  770. **
  771. **  06.02.86  - v_smode was using bh instead of ah. Corrected.
  772. **              Thanks to Rob Rainwater!!
  773. **
  774. **  05.26.86  - Added wn_natrib. Set new window attribute NOW!
  775. **
  776. **  05.25.86  - Corrected a potential problem with a couple of the routies
  777. **              in MSVLIB.ASM. Registers SI & DI were being used but not
  778. **              being saved. This "may" cause spurious probles with "C"
  779. **              programs that use register variables.  Microsoft C 3.0 only.
  780. **
  781. **            - wn_titla was not calling wns_fixc. Corrected.
  782. **
  783. **  05.24.86  - Added wn_titla. write window title with attributes.
  784. **
  785. **  05.10.86  - wn_putsa was not calling wns_fixc.  This caused problems
  786. **              when CGA was in mode bw80 but putsa was called with a
  787. **              valid color atrib.
  788. **
  789. **  The following changes were incororated in the 05.08.86 release.
  790. **
  791. **  05.07.86  - Additions for Microsoft "C" version 3.0
  792. **
  793. **  05.05.86  - wn_printf fix for lattice version 3.0.
  794. **
  795. **  04.25.86  - Added support for handling backspace, delete, & BELL
  796. **              characters correctly (wns_wtext).
  797. **
  798. **              Incorporated v_wtty in vlib.asm.
  799. **
  800. **  Initial Release..
  801. **
  802. **  01.24.86  - Initial release with a bit of a false start thanks to
  803. **              Microsoft's Lib.
  804. **
  805. */
  806.  
  807. 
  808.