delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/07/22/08:16:14

From: Jason Green <news AT jgreen4 DOT fsnet DOT co DOT uk>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: to del a window ...
Date: Sat, 22 Jul 2000 13:07:29 +0100
Organization: Customer of Planet Online
Lines: 49
Message-ID: <m83jns0b20u8uqu332jlujemcuq35h3qtv@4ax.com>
References: <8l80r8$10t$1 AT nets3 DOT rz DOT RWTH-Aachen DOT DE> <1gcfns4pgdgaqemjt0299qa1075n3tej81 AT 4ax DOT com> <200007210844 DOT LAA20461 AT mailgw1 DOT netvision DOT net DOT il> <kasgnscvpbd67p2klnpivul26ev826v29i AT 4ax DOT com>
NNTP-Posting-Host: modem-135.titanium.dialup.pol.co.uk
Mime-Version: 1.0
X-Trace: newsg3.svr.pol.co.uk 964267708 13034 62.136.21.135 (22 Jul 2000 12:08:28 GMT)
NNTP-Posting-Date: 22 Jul 2000 12:08:28 GMT
X-Complaints-To: abuse AT theplanet DOT net
X-Newsreader: Forte Agent 1.7/32.534
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

Damian Yerrick <Bullcr_pd_yerrick AT hotmail DOT comRemoveBullcr_p> wrote:

> >> Oh, BTW, anyone know how to
> >> knock the VGA up into an 80x100, 80x120 text mode using DJGPP?

I tried to do something like this a while back, but lack of low-level
PC knowledge prevented me from doing anything useful.

I'm sure you already know how to change text modes, but here is a
function I used:

void set_video_mode(int mode)
{
  __dpmi_regs regs;
  regs.x.ax = mode & 0xFF;
  __dpmi_int(0x10, &regs);
}

If you cycle through possible values of mode and use conio functions
to get the screen dimensions you will probably find all sorts of weird
text modes that your card is capable of.  Some modes will cause
lock-ups, so it's best to log the results to a file and open/close it
between each mode switch, and be prepared for reboots.

Having said that, the only modes that seemed to work properly for me
were the ones that textmode() provides for anyway.

However, there is one mode that would be a useful addition to DJGPP,
if someone could work out how to implement it.  80x60 chars is listed
in the Linux LILO docs as one of the standard VGA text modes and is
achieved using a 640x480 pixel variation of the 80x50 char text mode
(normally 640x400 pixels).  

I tried to implement this in DOS using ideas taken from the LILO
source code, but numerous reboots suggested this is not the project
for me. ;-)  If anyone is interested in looking at this I can dig out
the references and/or source code.

> >Each one has a special video mode number for these text modes.
> >See Ralf Brown's Interrupt List for details, under function 0
> >of Int 10h, there's a huge table there which tells this.
> 
> I know 80x117 can be done with EGA and standard VGA (go to 350
> scanline text mode and knock the character height down to 3
> scanlines).  But how do I notify the DJGPP Screen*() routines
> that I have done this so I can use them for blitting?

Out of interest, what possible use is a 3 pixel high font?
Does the DOS command line behave itself if you switch to this mode?

- Raw text -


  webmaster     delorie software   privacy  
  Copyright © 2019   by DJ Delorie     Updated Jul 2019