Board index » delphi » TP7.0 Drivers Unit drivers.tpu

TP7.0 Drivers Unit drivers.tpu

Hello Group
I was wondering what procedures, and functions etc. Does the drivers.tpu

unit provide?? I can't find nothing in Borland TP 7.0 Books.
Found a function 'formatstr' in help file. I could really use a function
like 'sprint'.
Any info would be great.
Thank you!!
Don Biederman
g...@ripco.com

 

Re:TP7.0 Drivers Unit drivers.tpu


Don & Traci Biederman <g...@ripco.com> wrote:

Quote
> Hello Group
> I was wondering what procedures, and functions etc. Does the drivers.tpu
> unit provide?? I can't find nothing in Borland TP 7.0 Books.

It's used by Turbo Vision. It provides mouse drivers, event handling
routines, extended keyboard stuff, etc. Essentially every TV program
will use it.

Quote
> Found a function 'formatstr' in help file. I could really use a function

Can't find one here...

Quote
> like 'sprint'.

Er, I take it you mean printf/sprintf? For 'sprint', I think Str() will do.

I don't think there is one. Some of that functionality is built into
write, though.

--
______________________________________________________________________
     The Scarlet Manuka,      |        Nitpickers' Party motto:
  Pratchett Quoter At Large,  |  "He who guards his lips guards his
 First Prophet of Bonni, is:  |  soul, but he who speaks rashly will
   sa...@maths.uwa.edu.au     |    come to ruin." -- Proverbs 13:3
______________________________|_______________________________________

Re:TP7.0 Drivers Unit drivers.tpu


JRS:  In article <3A67921F.3F3CA...@ripco.com>, seen in
news:comp.lang.pascal.borland, Don & Traci Biederman <g...@ripco.com>
wrote at Thu, 18 Jan 2001 19:02:23 :-

Quote
>Hello Group
>I was wondering what procedures, and functions etc. Does the drivers.tpu

>unit provide?? I can't find nothing in Borland TP 7.0 Books.
>Found a function 'formatstr' in help file. I could really use a function
>like 'sprint'.

If you have Borland Pascal 7 installed, you should have a copy of
drivers.pas; I don't know whether it comes with Turbo Pascal 6/7.

procedure InitEvents;
procedure DoneEvents;
procedure ShowMouse;
procedure HideMouse;
procedure GetMouseEvent(var Event: TEvent);
procedure GetKeyEvent(var Event: TEvent);
function GetShiftState: Byte;
procedure InitVideo;
procedure DoneVideo;
procedure SetVideoMode(Mode: Word);
procedure ClearScreen;
function SystemError(ErrorCode: Integer; Drive: Byte): Integer;
procedure InitSysError;
procedure DoneSysError;
function GetAltChar(KeyCode: Word): Char;
function GetAltCode(Ch: Char): Word;
function GetCtrlChar(KeyCode: Word): Char;
function GetCtrlCode(Ch: Char): Word;
function CtrlToArrow(KeyCode: Word): Word;
procedure FormatStr(var Result: String; const Format: String; var Params);
procedure PrintStr(const S: String);
procedure MoveBuf(var Dest; var Source; Attr: Byte; Count: Word);
procedure MoveChar(var Dest; C: Char; Attr: Byte; Count: Word);
procedure MoveCStr(var Dest; const Str: String; Attrs: Word);
procedure MoveStr(var Dest; const Str: String; Attr: Byte);
function CStrLen(const S: String): Integer;
procedure DetectMouse; near; assembler;
procedure StoreEvent; near; assembler;
procedure GetMouseState; near; assembler;
procedure MouseInt; far; assembler;
procedure InitEvents; assembler;
procedure DoneEvents; assembler;
procedure ShowMouse; assembler;
procedure HideMouse; assembler;
procedure GetMouseEvent(var Event: TEvent); assembler;
procedure GetKeyEvent(var Event: TEvent); assembler;
function GetShiftState: Byte; assembler;
procedure VideoInt; near; assembler;
procedure GetCrtMode; near; assembler;
procedure SetCrtMode; near; assembler;
procedure FixCrtMode; near; assembler;
procedure SetCrtData; near; assembler;
procedure DetectVideo; assembler;
procedure InitVideo; assembler;
procedure DoneVideo; assembler;
procedure SetVideoMode(Mode: Word); assembler;
procedure ClearScreen; assembler;
procedure InitSysError; external;
procedure DoneSysError; external;
procedure SwapStatusLine(var Buffer); near; assembler;
function SelectKey: Integer; near; assembler;
function SystemError(ErrorCode: Integer; Drive: Byte): Integer;
function GetAltChar(KeyCode: Word): Char;
function GetAltCode(Ch: Char): Word;
function GetCtrlChar(KeyCode: Word): Char;
function GetCtrlCode(Ch: Char): Word;
function CtrlToArrow(KeyCode: Word): Word;
procedure FormatStr(var Result: String; const Format: String; var Params);
procedure PrintStr(const S: String); assembler;
procedure MoveBuf(var Dest; var Source; Attr: Byte; Count: Word); assembler;
procedure MoveChar(var Dest; C: Char; Attr: Byte; Count: Word); assembler;
procedure MoveCStr(var Dest; const Str: String; Attrs: Word); assembler;
procedure MoveStr(var Dest; const Str: String; Attr: Byte); assembler;
function CStrLen(const S: String): Integer; assembler;
procedure ExitDrivers; far;

--
? John Stockton, Surrey, UK.  j...@merlyn.demon.co.uk   Turnpike v4.00   MIME. ?
 <URL: http://www.merlyn.demon.co.uk/> TP/BP/Delphi/&c., FAQqy topics & links;
 <URL: http://www.merlyn.demon.co.uk/clpb-faq.txt> Pedt Scragg: c.l.p.b. mFAQ;
 <URL: ftp://garbo.uwasa.fi/pc/link/tsfaqp.zip> Timo Salmi's Turbo Pascal FAQ.

Re:TP7.0 Drivers Unit drivers.tpu


Don & Traci Biederman <g...@ripco.com> wrote in message
news:3A67921F.3F3CAB3C@ripco.com...

Quote
> Hello Group
> I was wondering what procedures, and functions etc. Does the drivers.tpu

> unit provide?? I can't find nothing in Borland TP 7.0 Books.
> Found a function 'formatstr' in help file. I could really use a function
> like 'sprint'.

Drivers.pas contains a function called FormatStr that works in a similar way
to the C sprintf function.

--
Jay

Jason Burgon - Author of "Graphic Vision"  GUI for DOS/DPMI
=== Free LFN capable Dos/WinDos replacement and ===
=== New Graphic Vision  version 2.11 available from:  ===
http://www.jayman.demon.co.uk

Other Threads