lynx-dev
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: lynx-dev lynx for WIN 3.1?


From: for address@hidden
Subject: Re: lynx-dev lynx for WIN 3.1?
Date: Wed, 29 Apr 1998 13:13:14 -0500 (CDT)

>     * From: address@hidden (for address@hidden)
>     * Date: Tue, 28 Apr 1998 00:19:48 -0500 (CDT)
>>     * From: address@hidden (for Michael Sokolov)
>>     * Date: Sun, 26 Apr 98 16:39:44 -0400
>>
>>DFishbeck <address@hidden> wrote:
>>> Is there a version of Lynx that I can use running Windows 3.1 with AOL as my
>>> ISP?
>>
>>Since every machine running Windows v3.10 is also running DOS, you can of
>>course use the DOS version of Lynx, but I don't think this will help you with
>>AOL.
>
>That would be just ideal, under two circumstances: 1. You have something
>like the UMSLIP dialup program that loads itself into high memory and
>pretends to be a network card or 2.  You have some kind of a Dos interface
>to winsock.dll.
>
Actually, the easy windows systems of Borland and Microsoft have some
interesting limitations when it comes to porting Dos apps that use color
text.  You get the impression that MS issued an edict against such color
ports for Windows 3 and 3.1.

After attempting to use the Borland easy windows to do color text, by
grabbing its window handle and attempting to set text color (didn't
work), I resurrected an old `stdiolib' system that I did as an adjunct
to a Pascal interpreter for Windows and am bringing it up to date so
that it accepts, e. g., win32 console color.  It uses Turbo Pascal
console function calls and C stdio functions.  (Note that
fprintf(stdout, ...); works correctly.) The next step is to get
it to work with libcurses or libslang under Win3/3.1, which probably
involves some rearrangement of the internal code for reading keys.

Some other problems are how to protect the library from unauthorized
commercial use and whether there are any fine points about using it to
port GNU and GNUish apps to Win3/3.1.

The following test program actually runs in 16-bit mode:
(coniotst.c)

#include <windows.h>
#include "e:\src\wstdio\wstdio.h"

#define FOREGROUND_BLUE (1)
#define FOREGROUND_GREEN        (2)
#define FOREGROUND_RED  (4)
#define FOREGROUND_INTENSITY    (16)
#define BACKGROUND_BLUE (16)
#define BACKGROUND_GREEN        (32)
#define BACKGROUND_RED  (64)
#define BACKGROUND_INTENSITY    (128)


int MAIN_(int argc, char **argv)
{
  int index, ch;
  SetColor(0x70);
  Clr_Scr();

  for (index=1; index <= 25; index++)
        {
        Delay(1000);
        SetColor((index % 16) + (((index + 1) % 16) << 4));
         Clr_Scr();
         GoToXY(35, index);
         printf("Hello world");
         ch = getch();
         if ((ch == 0) || (ch == 224)) break;
        };
  SetColor(0x70);
        Clr_Scr();
         return 0;
}


reply via email to

[Prev in Thread] Current Thread [Next in Thread]