Browse Source

- Removed

daniel 27 years ago
parent
commit
010d2a6bed
6 changed files with 0 additions and 226 deletions
  1. 0 15
      rtl/os2/calc_e.pas
  2. 0 27
      rtl/os2/code2.so2
  3. 0 16
      rtl/os2/code3.so2
  4. 0 136
      rtl/os2/crtdemo.pas
  5. 0 8
      rtl/os2/extest.pas
  6. 0 24
      rtl/os2/helloos2.pas

+ 0 - 15
rtl/os2/calc_e.pas

@@ -1,15 +0,0 @@
-program calc_e;
-
-{Calculate the number e.}
-
-const   fac:array[0..7] of word=(1,1,2,6,24,120,720,5040);
-
-var e:fixed;
-    i:byte;
-
-begin
-    e:=0;
-    for i:=0 to 7 do
-        e:=e+fixed(1)/fac[i];
-    writeln(e);
-end.

+ 0 - 27
rtl/os2/code2.so2

@@ -1,27 +0,0 @@
-/ code2.s (emx+fpk) -- Copyright (c) 1992-1996 by Eberhard Mattes
-/                      Changed for FPK-Pascal in 1998 by Dani‰l Mantione.
-/					   This code is _not_ under the Library GNU Public
-/ 					   License, because the original is not. See copying.emx
-/	 				   for details. You should have received it with this
-/		 			   product, write the author if you haven't.
-
-		.globl  DosGetMessage
-		.globl  _msgseg32
-
-_msgseg32:
-		.byte   0xff
-		.asciz  "MSGSEG32"
-		.byte   0x01, 0x80, 0x00, 0x00
-		.long   L_tab
-
-		.align  2, 0x90
-
-DosGetMessage:
-		PROFILE_NOFRAME
-		popl    %ecx                    /* return address */
-		pushl   $_msgseg32
-		pushl   %ecx
-		jmp     _DOSCALLS$$_DOSTRUEGETMESSAGE$POINTER$PINSERTTABLE$LONGINT$PCHAR$LONGINT$LONGINT$PCHAR$LONGINT
-
-L_tab:  .short  0x0000
-        .short  0xffff

+ 0 - 16
rtl/os2/code3.so2

@@ -1,16 +0,0 @@
-/ code3.s (emx+gcc) -- Copyright (c) 1992-1996 by Eberhard Mattes
-
-#include <emx/asm386.h>
-
-        .globl  _DosQueryMessageCP
-
-_DosQueryMessageCP:
-        PROFILE_NOFRAME
-        pushl   0(%esp)
-        movl    $__msgseg32, %eax
-        xchgl   20(%esp), %eax
-        xchgl   16(%esp), %eax
-        xchgl   12(%esp), %eax
-        xchgl   8(%esp), %eax
-        movl    %eax, 4(%esp)
-        jmp     _DosIQueryMessageCP

+ 0 - 136
rtl/os2/crtdemo.pas

@@ -1,136 +0,0 @@
-{************************************************}
-{                                                }
-{ CRT Unit Demo                                  }
-{ Copyright (c) 1985,90 by Borland International }
-{                                                }
-{************************************************}
-
-program CrtDemo;
-{ Example program that uses the Crt unit. Uses the following routines
-  from the Crt unit:
-
-    ClrScr
-    DelLine
-    GoToXY
-    InsLine
-    KeyPressed
-    ReadKey
-    TextBackground
-    TextColor
-    TextMode
-    WhereX
-    WhereY
-    Window
-    Write
-    WriteLn;
-
-  Also uses LastMode and WindMax variables from Crt unit.
-
-    1. Init routine:
-       - Save original video mode. On an EGA or VGA, use the 8x8 font
-         (43 lines on an EGA, 50 on VGA).
-       - Setup LastRow to preserve last line on screen for messages
-         (preserves last 2 lines in 40-column mode). Setup LastCol.
-       - Initialize the random number generator.
-    2. MakeWindow routine:
-       - Puts up random-sized, random-colored windows on screen.
-    3. Program body:
-       - Call Init
-       - Loop until Contrl-C is typed:
-         - Echo keystrokes (Turbo Pascal windows automatically wrap
-           and scroll).
-         - Support special keys:
-             <Ins>    inserts a line at the cursor
-             <Del>    deletes a line at the cursor
-             <Up>,
-             <Dn>,
-             <Right>,
-             <Left>   position the cursor in the window
-             <Alt-R>  generate random text until a key is pressed
-             <Alt-W>  creates another random window
-             <ESC>    exits the program
-}
-
-uses Crt;
-
-var
-  OrigMode,LastCol,LastRow: Word;
-  Ch: Char;
-  Done: Boolean;
-
-procedure Initialize;
-{ Initialize the video mode, LastCol, LastRow, and the random number }
-{ generator. Paint the help line. }
-begin
-  OrigMode:=LastMode;                  { Remember original video mode }
-  TextMode(_80cols+_50rows);           { use 43 or 50 lines on EGA/VGA }
-  LastCol:=Lo(WindMax)+1;              { get last column, row }
-  LastRow:=Hi(WindMax)+1;
-  GoToXY(1,LastRow);                   { put message line on screen }
-  TextBackground(Black);
-  TextColor(White);
-  Write(' Ins-InsLine  '+
-        'Del-DelLine  '+
-        #27#24#25#26'-Cursor  '+
-        'Alt-W-Window  '+
-        'Alt-R-Random  '+
-        'Esc-Exit');
-  LastRow:=lastrow-80 div LastCol;     { don't write on message line }
-  Randomize;                           { init random number generator }
-end; { Init }
-
-procedure MakeWindow;
-{ Make a random window, with random background and foreground colors }
-var
-  X,Y,Width,Height: Word;
-begin
-  Width:=Random(LastCol-2)+2;               { random window size }
-  Height:=Random(LastRow-2)+2;
-  X:=Random(LastCol-Width)+1;           { random position on screen }
-  Y:=Random(LastRow-Height)+1;
-  Window(X,Y,X+Width,Y+Height);
-  TextBackground(Random(8));
-  TextColor(Random(7)+9);
-  ClrScr;
-end; { MakeWindow }
-
-procedure RandomText;
-{ Generate random text until a key is pressed. Filter out }
-{ control characters. }
-begin
-  repeat
-    Write(Chr(Random(256-32)+32));
-  until KeyPressed;
-end; { RandomText }
-
-begin { program body }
-  Initialize;
-  MakeWindow;
-  Done:=False;
-  repeat
-    Ch:=ReadKey;
-    case Ch of
-      #0:                               { Function keys }
-      begin
-        Ch:=ReadKey;
-        case Ch of
-          #17: MakeWindow;              { Alt-W }
-          #19: RandomText;              { Alt-R }
-          #45: Done:=True;              { Alt-X }
-          #72: GotoXY(WhereX,WhereY-1); { Up }
-          #75: GotoXY(WhereX-1,WhereY); { Left }
-          #77: GotoXY(WhereX+1,WhereY); { Right }
-          #80: GotoXY(WhereX,WhereY+1); { Down }
-          #82: InsLine;                 { Ins }
-          #83: DelLine;                 { Del }
-        end;
-      end;
-      #3: Done:=True;                   { Ctrl-C }
-      #13: WriteLn;                     { Enter }
-      #27: Done:=True;                  { Esc }
-    else
-      Write(Ch);
-    end;
-  until Done;
-  TextMode(OrigMode);
-end.

+ 0 - 8
rtl/os2/extest.pas

@@ -1,8 +0,0 @@
-program extest;
-
-uses dos;
-
-begin
-    exec('c:\ndos.com','');
-    writeln(doserror);
-end.

+ 0 - 24
rtl/os2/helloos2.pas

@@ -1,24 +0,0 @@
-program helloos2;
-
-var a,b:^word;
-
-begin
-        writeln('Hallo Wereld.');
-        if os_mode=osDOS then
-            writeln('We draaien onder DOS.')
-        else
-            writeln('We draaien onder OS/2.');
-        writeln('Vrij geheugen: ',memavail);
-        writeln('Grootste blok: ',maxavail);
-        writeln('Heapstart: ',longint(heaporg));
-        writeln('Heapend: ',longint(heapend));
-        writeln('Geheugen aan het bezetten.');
-        getmem(a,1000);
-        getmem(b,2000);
-        a^:=2;
-        b^:=10;
-        writeln('Vrij geheugen: ',memavail);
-        writeln('Grootste blok: ',maxavail);
-        freemem(a,1000);
-        freemem(b,2000);
-end.