mirror of
https://gitlab.com/freepascal.org/fpc/source.git
synced 2025-04-07 15:07:56 +02:00
96 lines
2.7 KiB
PHP
96 lines
2.7 KiB
PHP
{
|
|
This file is part of the Free Pascal run time library.
|
|
Copyright (c) 1999-2000 by the Free Pascal development team.
|
|
|
|
Borland Pascal 7 Compatible CRT Unit - Interface section
|
|
|
|
See the file COPYING.FPC, included in this distribution,
|
|
for details about the copyright.
|
|
|
|
This program is distributed in the hope that it will be useful,
|
|
but WITHOUT ANY WARRANTY; without even the implied warranty of
|
|
MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.
|
|
|
|
**********************************************************************}
|
|
|
|
Const
|
|
{ CRT modes }
|
|
BW40 = 0; { 40x25 B/W on Color Adapter }
|
|
CO40 = 1; { 40x25 Color on Color Adapter }
|
|
BW80 = 2; { 80x25 B/W on Color Adapter }
|
|
CO80 = 3; { 80x25 Color on Color Adapter }
|
|
Mono = 7; { 80x25 on Monochrome Adapter }
|
|
Font8x8 = 256; { Add-in for ROM font }
|
|
|
|
{ Mode constants for 3.0 compatibility }
|
|
C40 = CO40;
|
|
C80 = CO80;
|
|
|
|
{ Foreground and background color constants }
|
|
Black = 0;
|
|
Blue = 1;
|
|
Green = 2;
|
|
Cyan = 3;
|
|
Red = 4;
|
|
Magenta = 5;
|
|
Brown = 6;
|
|
LightGray = 7;
|
|
|
|
{ Foreground color constants }
|
|
DarkGray = 8;
|
|
LightBlue = 9;
|
|
LightGreen = 10;
|
|
LightCyan = 11;
|
|
LightRed = 12;
|
|
LightMagenta = 13;
|
|
Yellow = 14;
|
|
White = 15;
|
|
|
|
{ Add-in for blinking }
|
|
Blink = 128;
|
|
|
|
var
|
|
|
|
{ Interface variables }
|
|
CheckBreak: Boolean; { Enable Ctrl-Break }
|
|
CheckEOF: Boolean; { Enable Ctrl-Z }
|
|
DirectVideo: Boolean; { Enable direct video addressing }
|
|
CheckSnow: Boolean; { Enable snow filtering }
|
|
LastMode: Word = 3; { Current text mode }
|
|
TextAttr: Byte = $07; { Current text attribute }
|
|
WindMin: Word = $0; { Window upper left coordinates }
|
|
WindMax: Word = $184f; { Window lower right coordinates }
|
|
{ FPC Specific for large screen support }
|
|
WindMinX : DWord;
|
|
WindMaxX : DWord;
|
|
WindMinY : DWord;
|
|
WindMaxY : DWord ;
|
|
|
|
{ Interface procedures }
|
|
procedure AssignCrt(var F: Text);
|
|
function KeyPressed: Boolean;
|
|
function ReadKey: Char;
|
|
procedure TextMode (Mode: word);
|
|
procedure Window(X1,Y1,X2,Y2: Byte);
|
|
procedure GotoXY(X,Y: Byte);
|
|
function WhereX: Byte;
|
|
function WhereY: Byte;
|
|
procedure ClrScr;
|
|
procedure ClrEol;
|
|
procedure InsLine;
|
|
procedure DelLine;
|
|
procedure TextColor(Color: Byte);
|
|
procedure TextBackground(Color: Byte);
|
|
procedure LowVideo;
|
|
procedure HighVideo;
|
|
procedure NormVideo;
|
|
procedure Delay(MS: Word);
|
|
procedure Sound(Hz: Word);
|
|
procedure NoSound;
|
|
|
|
{Extra Functions}
|
|
procedure cursoron;
|
|
procedure cursoroff;
|
|
procedure cursorbig;
|
|
|