crt.pp 18 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895
  1. {
  2. $Id$
  3. This file is part of the Free Pascal run time library.
  4. Copyright (c) 1998-2000 by the Free Pascal development team.
  5. Borland Pascal 7 Compatible CRT Unit for Go32V2
  6. See the file COPYING.FPC, included in this distribution,
  7. for details about the copyright.
  8. This program is distributed in the hope that it will be useful,
  9. but WITHOUT ANY WARRANTY; without even the implied warranty of
  10. MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
  11. **********************************************************************}
  12. unit crt;
  13. interface
  14. const
  15. { CRT modes }
  16. BW40 = 0; { 40x25 B/W on Color Adapter }
  17. CO40 = 1; { 40x25 Color on Color Adapter }
  18. BW80 = 2; { 80x25 B/W on Color Adapter }
  19. CO80 = 3; { 80x25 Color on Color Adapter }
  20. Mono = 7; { 80x25 on Monochrome Adapter }
  21. Font8x8 = 256; { Add-in for ROM font }
  22. { Mode constants for 3.0 compatibility }
  23. C40 = CO40;
  24. C80 = CO80;
  25. { Foreground and background color constants }
  26. Black = 0;
  27. Blue = 1;
  28. Green = 2;
  29. Cyan = 3;
  30. Red = 4;
  31. Magenta = 5;
  32. Brown = 6;
  33. LightGray = 7;
  34. { Foreground color constants }
  35. DarkGray = 8;
  36. LightBlue = 9;
  37. LightGreen = 10;
  38. LightCyan = 11;
  39. LightRed = 12;
  40. LightMagenta = 13;
  41. Yellow = 14;
  42. White = 15;
  43. { Add-in for blinking }
  44. Blink = 128;
  45. var
  46. { Interface variables }
  47. CheckBreak: Boolean; { Enable Ctrl-Break }
  48. CheckEOF: Boolean; { Enable Ctrl-Z }
  49. DirectVideo: Boolean; { Enable direct video addressing }
  50. CheckSnow: Boolean; { Enable snow filtering }
  51. LastMode: Word; { Current text mode }
  52. TextAttr: Byte; { Current text attribute }
  53. WindMin: Word; { Window upper left coordinates }
  54. WindMax: Word; { Window lower right coordinates }
  55. { Interface procedures }
  56. procedure AssignCrt(var F: Text);
  57. function KeyPressed: Boolean;
  58. function ReadKey: Char;
  59. procedure TextMode(Mode: Integer);
  60. procedure Window(X1,Y1,X2,Y2: Byte);
  61. procedure GotoXY(X,Y: Byte);
  62. function WhereX: Byte;
  63. function WhereY: Byte;
  64. procedure ClrScr;
  65. procedure ClrEol;
  66. procedure InsLine;
  67. procedure DelLine;
  68. procedure TextColor(Color: Byte);
  69. procedure TextBackground(Color: Byte);
  70. procedure LowVideo;
  71. procedure HighVideo;
  72. procedure NormVideo;
  73. procedure Delay(MS: Word);
  74. procedure Sound(Hz: Word);
  75. procedure NoSound;
  76. {Extra Functions}
  77. procedure cursoron;
  78. procedure cursoroff;
  79. procedure cursorbig;
  80. implementation
  81. uses
  82. go32;
  83. {$ASMMODE ATT}
  84. var
  85. DelayCnt,
  86. ScreenWidth,
  87. ScreenHeight : longint;
  88. VidSeg : Word;
  89. {
  90. definition of textrec is in textrec.inc
  91. }
  92. {$i textrec.inc}
  93. {****************************************************************************
  94. Low level Routines
  95. ****************************************************************************}
  96. procedure setscreenmode(mode : byte);
  97. var
  98. regs : trealregs;
  99. begin
  100. regs.realeax:=mode;
  101. realintr($10,regs);
  102. end;
  103. function GetScreenHeight : longint;
  104. begin
  105. getscreenheight:=mem[$40:$84]+1;
  106. If mem[$40:$84]=0 then
  107. getscreenheight := 25;
  108. end;
  109. function GetScreenWidth : longint;
  110. begin
  111. getscreenwidth:=memw[$40:$4a];
  112. end;
  113. procedure SetScreenCursor(x,y : longint);
  114. var
  115. regs : trealregs;
  116. begin
  117. regs.realeax:=$0200;
  118. regs.realebx:=0;
  119. regs.realedx:=(y-1) shl 8+(x-1);
  120. realintr($10,regs);
  121. end;
  122. procedure GetScreenCursor(var x,y : longint);
  123. begin
  124. x:=mem[$40:$50]+1;
  125. y:=mem[$40:$51]+1;
  126. end;
  127. {****************************************************************************
  128. Helper Routines
  129. ****************************************************************************}
  130. Function WinMinX: Byte;
  131. {
  132. Current Minimum X coordinate
  133. }
  134. Begin
  135. WinMinX:=(WindMin and $ff)+1;
  136. End;
  137. Function WinMinY: Byte;
  138. {
  139. Current Minimum Y Coordinate
  140. }
  141. Begin
  142. WinMinY:=(WindMin shr 8)+1;
  143. End;
  144. Function WinMaxX: Byte;
  145. {
  146. Current Maximum X coordinate
  147. }
  148. Begin
  149. WinMaxX:=(WindMax and $ff)+1;
  150. End;
  151. Function WinMaxY: Byte;
  152. {
  153. Current Maximum Y coordinate;
  154. }
  155. Begin
  156. WinMaxY:=(WindMax shr 8) + 1;
  157. End;
  158. Function FullWin:boolean;
  159. {
  160. Full Screen 80x25? Window(1,1,80,25) is used, allows faster routines
  161. }
  162. begin
  163. FullWin:=(WinMinX=1) and (WinMinY=1) and
  164. (WinMaxX=ScreenWidth) and (WinMaxY=ScreenHeight);
  165. end;
  166. {****************************************************************************
  167. Public Crt Functions
  168. ****************************************************************************}
  169. procedure textmode(mode : integer);
  170. var
  171. regs : trealregs;
  172. begin
  173. lastmode:=mode;
  174. mode:=mode and $ff;
  175. setscreenmode(mode);
  176. { set 8x8 font }
  177. if (lastmode and $100)<>0 then
  178. begin
  179. regs.realeax:=$1112;
  180. regs.realebx:=$0;
  181. realintr($10,regs);
  182. end;
  183. screenwidth:=getscreenwidth;
  184. screenheight:=getscreenheight;
  185. windmin:=0;
  186. windmax:=(screenwidth-1) or ((screenheight-1) shl 8);
  187. end;
  188. Procedure TextColor(Color: Byte);
  189. {
  190. Switch foregroundcolor
  191. }
  192. Begin
  193. TextAttr:=(Color and $8f) or (TextAttr and $70);
  194. End;
  195. Procedure TextBackground(Color: Byte);
  196. {
  197. Switch backgroundcolor
  198. }
  199. Begin
  200. TextAttr:=((Color shl 4) and ($f0 and not Blink)) or (TextAttr and ($0f OR Blink) );
  201. End;
  202. Procedure HighVideo;
  203. {
  204. Set highlighted output.
  205. }
  206. Begin
  207. TextColor(TextAttr Or $08);
  208. End;
  209. Procedure LowVideo;
  210. {
  211. Set normal output
  212. }
  213. Begin
  214. TextColor(TextAttr And $77);
  215. End;
  216. Procedure NormVideo;
  217. {
  218. Set normal back and foregroundcolors.
  219. }
  220. Begin
  221. TextColor(7);
  222. TextBackGround(0);
  223. End;
  224. Procedure GotoXy(X: Byte; Y: Byte);
  225. {
  226. Go to coordinates X,Y in the current window.
  227. }
  228. Begin
  229. If (X>0) and (X<=WinMaxX- WinMinX+1) and
  230. (Y>0) and (Y<=WinMaxY-WinMinY+1) Then
  231. Begin
  232. Inc(X,WinMinX-1);
  233. Inc(Y,WinMinY-1);
  234. SetScreenCursor(x,y);
  235. End;
  236. End;
  237. Procedure Window(X1, Y1, X2, Y2: Byte);
  238. {
  239. Set screen window to the specified coordinates.
  240. }
  241. Begin
  242. if (X1>X2) or (X2>ScreenWidth) or
  243. (Y1>Y2) or (Y2>ScreenHeight) then
  244. exit;
  245. WindMin:=((Y1-1) Shl 8)+(X1-1);
  246. WindMax:=((Y2-1) Shl 8)+(X2-1);
  247. GoToXY(1,1);
  248. End;
  249. Procedure ClrScr;
  250. {
  251. Clear the current window, and set the cursor on 1,1
  252. }
  253. var
  254. fil : word;
  255. y : longint;
  256. begin
  257. fil:=32 or (textattr shl 8);
  258. if FullWin then
  259. DosmemFillWord(VidSeg,0,ScreenHeight*ScreenWidth,fil)
  260. else
  261. begin
  262. for y:=WinMinY to WinMaxY do
  263. DosmemFillWord(VidSeg,((y-1)*ScreenWidth+(WinMinX-1))*2,WinMaxX-WinMinX+1,fil);
  264. end;
  265. Gotoxy(1,1);
  266. end;
  267. Procedure ClrEol;
  268. {
  269. Clear from current position to end of line.
  270. }
  271. var
  272. x,y : longint;
  273. fil : word;
  274. Begin
  275. GetScreenCursor(x,y);
  276. fil:=32 or (textattr shl 8);
  277. if x<WinMaxX then
  278. DosmemFillword(VidSeg,((y-1)*ScreenWidth+(x-1))*2,WinMaxX-x+1,fil);
  279. End;
  280. Function WhereX: Byte;
  281. {
  282. Return current X-position of cursor.
  283. }
  284. var
  285. x,y : longint;
  286. Begin
  287. GetScreenCursor(x,y);
  288. WhereX:=x-WinMinX+1;
  289. End;
  290. Function WhereY: Byte;
  291. {
  292. Return current Y-position of cursor.
  293. }
  294. var
  295. x,y : longint;
  296. Begin
  297. GetScreenCursor(x,y);
  298. WhereY:=y-WinMinY+1;
  299. End;
  300. {*************************************************************************
  301. KeyBoard
  302. *************************************************************************}
  303. var
  304. is_last : boolean;
  305. last : char;
  306. function readkey : char;
  307. var
  308. char2 : char;
  309. char1 : char;
  310. regs : trealregs;
  311. begin
  312. if is_last then
  313. begin
  314. is_last:=false;
  315. readkey:=last;
  316. end
  317. else
  318. begin
  319. regs.ah:=$10;
  320. realintr($16,regs);
  321. if (regs.al=$e0) and (regs.ah<>0) then
  322. regs.al:=0;
  323. char1:=chr(regs.al);
  324. char2:=chr(regs.ah);
  325. if char1=#0 then
  326. begin
  327. is_last:=true;
  328. last:=char2;
  329. end;
  330. readkey:=char1;
  331. end;
  332. end;
  333. function keypressed : boolean;
  334. var
  335. regs : trealregs;
  336. begin
  337. if is_last then
  338. begin
  339. keypressed:=true;
  340. exit;
  341. end
  342. else
  343. begin
  344. regs.ah:=$11;
  345. realintr($16,regs);
  346. keypressed:=((regs.realflags and zeroflag) = 0);
  347. end;
  348. end;
  349. {*************************************************************************
  350. Delay
  351. *************************************************************************}
  352. procedure Delayloop;assembler;
  353. asm
  354. .LDelayLoop1:
  355. subl $1,%eax
  356. jc .LDelayLoop2
  357. cmpl %fs:(%edi),%ebx
  358. je .LDelayLoop1
  359. .LDelayLoop2:
  360. end;
  361. procedure initdelay;assembler;
  362. asm
  363. movl $0x46c,%edi
  364. movl $-28,%edx
  365. movl %fs:(%edi),%ebx
  366. .LInitDel1:
  367. cmpl %fs:(%edi),%ebx
  368. je .LInitDel1
  369. movl %fs:(%edi),%ebx
  370. movl %edx,%eax
  371. call DelayLoop
  372. notl %eax
  373. xorl %edx,%edx
  374. movl $55,%ecx
  375. divl %ecx
  376. movl %eax,DelayCnt
  377. end;
  378. procedure Delay(MS: Word);assembler;
  379. asm
  380. movzwl MS,%ecx
  381. jecxz .LDelay2
  382. movl $0x400,%edi
  383. movl DelayCnt,%edx
  384. movl %fs:(%edi),%ebx
  385. .LDelay1:
  386. movl %edx,%eax
  387. call DelayLoop
  388. loop .LDelay1
  389. .LDelay2:
  390. end;
  391. procedure sound(hz : word);
  392. begin
  393. if hz=0 then
  394. begin
  395. nosound;
  396. exit;
  397. end;
  398. asm
  399. movzwl hz,%ecx
  400. movl $1193046,%eax
  401. cltd
  402. divl %ecx
  403. movl %eax,%ecx
  404. inb $0x61,%al
  405. testb $0x3,%al
  406. jnz .Lsound_next
  407. orb $0x3,%al
  408. outb %al,$0x61
  409. movb $0xb6,%al
  410. outb %al,$0x43
  411. .Lsound_next:
  412. movb %cl,%al
  413. outb %al,$0x42
  414. movb %ch,%al
  415. outb %al,$0x42
  416. end ['EAX','ECX','EDX'];
  417. end;
  418. procedure nosound;
  419. begin
  420. asm
  421. inb $0x61,%al
  422. andb $0xfc,%al
  423. outb %al,$0x61
  424. end ['EAX'];
  425. end;
  426. {****************************************************************************
  427. HighLevel Crt Functions
  428. ****************************************************************************}
  429. procedure removeline(y : longint);
  430. var
  431. fil : word;
  432. begin
  433. fil:=32 or (textattr shl 8);
  434. y:=WinMinY+y-1;
  435. While (y<WinMaxY) do
  436. begin
  437. dosmemmove(VidSeg,(y*ScreenWidth+(WinMinX-1))*2,
  438. VidSeg,((y-1)*ScreenWidth+(WinMinX-1))*2,(WinMaxX-WinMinX+1)*2);
  439. inc(y);
  440. end;
  441. dosmemfillword(VidSeg,((WinMaxY-1)*ScreenWidth+(WinMinX-1))*2,(WinMaxX-WinMinX+1),fil);
  442. end;
  443. procedure delline;
  444. begin
  445. removeline(wherey);
  446. end;
  447. procedure insline;
  448. var
  449. my,y : longint;
  450. fil : word;
  451. begin
  452. fil:=32 or (textattr shl 8);
  453. y:=WhereY;
  454. my:=WinMaxY-WinMinY;
  455. while (my>=y) do
  456. begin
  457. dosmemmove(VidSeg,(((WinMinY+my-1)-1)*ScreenWidth+(WinMinX-1))*2,
  458. VidSeg,(((WinMinY+my)-1)*ScreenWidth+(WinMinX-1))*2,(WinMaxX-WinMinX+1)*2);
  459. dec(my);
  460. end;
  461. dosmemfillword(VidSeg,(((WinMinY+y-1)-1)*ScreenWidth+(WinMinX-1))*2,(WinMaxX-WinMinX+1),fil);
  462. end;
  463. {****************************************************************************
  464. Extra Crt Functions
  465. ****************************************************************************}
  466. procedure cursoron;
  467. var
  468. regs : trealregs;
  469. begin
  470. regs.realeax:=$0100;
  471. regs.realecx:=$90A;
  472. If VidSeg=$b800 then
  473. regs.realecx:=$90A
  474. else
  475. regs.realecx:=$b0d;
  476. realintr($10,regs);
  477. end;
  478. procedure cursoroff;
  479. var
  480. regs : trealregs;
  481. begin
  482. regs.realeax:=$0100;
  483. regs.realecx:=$ffff;
  484. realintr($10,regs);
  485. end;
  486. procedure cursorbig;
  487. var
  488. regs : trealregs;
  489. begin
  490. regs.realeax:=$0100;
  491. regs.realecx:=$10A;
  492. realintr($10,regs);
  493. end;
  494. {*****************************************************************************
  495. Read and Write routines
  496. *****************************************************************************}
  497. var
  498. CurrX,CurrY : longint;
  499. Procedure WriteChar(c:char);
  500. var
  501. regs : trealregs;
  502. begin
  503. case c of
  504. #10 : inc(CurrY);
  505. #13 : CurrX:=WinMinX;
  506. #8 : begin
  507. if CurrX>WinMinX then
  508. dec(CurrX);
  509. end;
  510. #7 : begin { beep }
  511. regs.dl:=7;
  512. regs.ah:=2;
  513. realintr($21,regs);
  514. end;
  515. else
  516. begin
  517. memw[VidSeg:((CurrY-1)*ScreenWidth+(CurrX-1))*2]:=(textattr shl 8) or byte(c);
  518. inc(CurrX);
  519. end;
  520. end;
  521. if CurrX>WinMaxX then
  522. begin
  523. CurrX:=WinMinX;
  524. inc(CurrY);
  525. end;
  526. while CurrY>WinMaxY do
  527. begin
  528. removeline(1);
  529. dec(CurrY);
  530. end;
  531. end;
  532. Function CrtWrite(var f : textrec):integer;
  533. var
  534. i : longint;
  535. begin
  536. GetScreenCursor(CurrX,CurrY);
  537. for i:=0 to f.bufpos-1 do
  538. WriteChar(f.buffer[i]);
  539. SetScreenCursor(CurrX,CurrY);
  540. f.bufpos:=0;
  541. CrtWrite:=0;
  542. end;
  543. Function CrtRead(Var F: TextRec): Integer;
  544. procedure BackSpace;
  545. begin
  546. if (f.bufpos>0) and (f.bufpos=f.bufend) then
  547. begin
  548. WriteChar(#8);
  549. WriteChar(' ');
  550. WriteChar(#8);
  551. dec(f.bufpos);
  552. dec(f.bufend);
  553. end;
  554. end;
  555. var
  556. ch : Char;
  557. Begin
  558. GetScreenCursor(CurrX,CurrY);
  559. f.bufpos:=0;
  560. f.bufend:=0;
  561. repeat
  562. if f.bufpos>f.bufend then
  563. f.bufend:=f.bufpos;
  564. SetScreenCursor(CurrX,CurrY);
  565. ch:=readkey;
  566. case ch of
  567. #0 : case readkey of
  568. #71 : while f.bufpos>0 do
  569. begin
  570. dec(f.bufpos);
  571. WriteChar(#8);
  572. end;
  573. #75 : if f.bufpos>0 then
  574. begin
  575. dec(f.bufpos);
  576. WriteChar(#8);
  577. end;
  578. #77 : if f.bufpos<f.bufend then
  579. begin
  580. WriteChar(f.bufptr^[f.bufpos]);
  581. inc(f.bufpos);
  582. end;
  583. #79 : while f.bufpos<f.bufend do
  584. begin
  585. WriteChar(f.bufptr^[f.bufpos]);
  586. inc(f.bufpos);
  587. end;
  588. end;
  589. ^S,
  590. #8 : BackSpace;
  591. ^Y,
  592. #27 : begin
  593. f.bufpos:=f.bufend;
  594. while f.bufend>0 do
  595. BackSpace;
  596. end;
  597. #13 : begin
  598. WriteChar(#13);
  599. WriteChar(#10);
  600. f.bufptr^[f.bufend]:=#13;
  601. f.bufptr^[f.bufend+1]:=#10;
  602. inc(f.bufend,2);
  603. break;
  604. end;
  605. #26 : if CheckEOF then
  606. begin
  607. f.bufptr^[f.bufend]:=#26;
  608. inc(f.bufend);
  609. break;
  610. end;
  611. else
  612. begin
  613. if f.bufpos<f.bufsize-2 then
  614. begin
  615. f.buffer[f.bufpos]:=ch;
  616. inc(f.bufpos);
  617. WriteChar(ch);
  618. end;
  619. end;
  620. end;
  621. until false;
  622. f.bufpos:=0;
  623. SetScreenCursor(CurrX,CurrY);
  624. CrtRead:=0;
  625. End;
  626. Function CrtReturn(Var F: TextRec): Integer;
  627. Begin
  628. CrtReturn:=0;
  629. end;
  630. Function CrtClose(Var F: TextRec): Integer;
  631. Begin
  632. F.Mode:=fmClosed;
  633. CrtClose:=0;
  634. End;
  635. Function CrtOpen(Var F: TextRec): Integer;
  636. Begin
  637. If F.Mode=fmOutput Then
  638. begin
  639. TextRec(F).InOutFunc:=@CrtWrite;
  640. TextRec(F).FlushFunc:=@CrtWrite;
  641. end
  642. Else
  643. begin
  644. F.Mode:=fmInput;
  645. TextRec(F).InOutFunc:=@CrtRead;
  646. TextRec(F).FlushFunc:=@CrtReturn;
  647. end;
  648. TextRec(F).CloseFunc:=@CrtClose;
  649. CrtOpen:=0;
  650. End;
  651. procedure AssignCrt(var F: Text);
  652. begin
  653. Assign(F,'');
  654. TextRec(F).OpenFunc:=@CrtOpen;
  655. end;
  656. var
  657. x,y : longint;
  658. begin
  659. { Load startup values }
  660. ScreenWidth:=GetScreenWidth;
  661. ScreenHeight:=GetScreenHeight;
  662. WindMax:=(ScreenWidth-1) or ((ScreenHeight-1) shl 8);
  663. { Load TextAttr }
  664. GetScreenCursor(x,y);
  665. lastmode := mem[$40:$49];
  666. if screenheight>25 then
  667. lastmode:=lastmode or $100;
  668. If not(lastmode=Mono) then
  669. VidSeg := $b800
  670. else
  671. VidSeg := $b000;
  672. TextAttr:=mem[VidSeg:((y-1)*ScreenWidth+(x-1))*2+1];
  673. { Redirect the standard output }
  674. assigncrt(Output);
  675. Rewrite(Output);
  676. TextRec(Output).Handle:=StdOutputHandle;
  677. assigncrt(Input);
  678. Reset(Input);
  679. TextRec(Input).Handle:=StdInputHandle;
  680. { Calculates delay calibration }
  681. initdelay;
  682. end.
  683. {
  684. $Log$
  685. Revision 1.10 2000-01-07 16:32:23 daniel
  686. * copyright 2000 added
  687. Revision 1.9 2000/01/07 14:55:47 pierre
  688. * bad sound if changing frequency solved
  689. Revision 1.8 1999/11/06 14:38:23 peter
  690. * truncated log
  691. Revision 1.7 1999/11/03 23:47:34 peter
  692. * support extended keys
  693. Revision 1.6 1999/10/22 14:36:20 peter
  694. * crtreturn also needs f:textrec as parameter
  695. Revision 1.5 1999/06/09 16:46:09 peter
  696. * fixed fullwin,textbackground
  697. Revision 1.4 1999/03/26 00:00:17 peter
  698. * fixed lastmode at startup for > 25 lines
  699. Revision 1.3 1999/02/03 09:56:17 florian
  700. + added simple support for monochrome video cards (not cursors yet),
  701. thanks to Jeff Patterson
  702. Revision 1.2 1999/01/22 11:12:09 florian
  703. + support of font8x8 added
  704. Revision 1.1 1998/12/21 13:07:02 peter
  705. * use -FE
  706. Revision 1.17 1998/12/15 22:42:49 peter
  707. * removed temp symbols
  708. Revision 1.16 1998/12/09 23:04:36 jonas
  709. * fixed bug in InsLine (changed "my" from "WinMaxY -1" to "WinMaxY - WinMinY")
  710. Revision 1.15 1998/11/28 14:09:48 peter
  711. * NOATTCDQ define
  712. Revision 1.14 1998/11/26 23:14:52 jonas
  713. * changed cdq to cltd in AT&T assembler block
  714. Revision 1.13 1998/08/26 10:01:54 peter
  715. * fixed readln cursor position
  716. Revision 1.12 1998/08/19 17:57:55 peter
  717. * fixed crtread with wrong cursor position
  718. Revision 1.11 1998/08/19 14:55:44 peter
  719. * fixed removeline which scrolled too much lines
  720. Revision 1.10 1998/08/18 13:32:46 carl
  721. * bugfix to make it work with FPC 0.99.5 (Delayloop is not correctly
  722. converted by ATT parser)
  723. Revision 1.9 1998/08/15 17:00:10 peter
  724. * moved delaycnt from interface to implementation
  725. Revision 1.8 1998/08/08 21:56:45 peter
  726. * updated crt with new delay, almost like bp7 routine
  727. Revision 1.5 1998/05/31 14:18:12 peter
  728. * force att or direct assembling
  729. * cleanup of some files
  730. Revision 1.4 1998/05/28 10:21:38 pierre
  731. * Handles of input and output restored
  732. Revision 1.3 1998/05/27 00:19:16 peter
  733. * fixed crt input
  734. }