www.delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/2000/11/10/00:00:29

From: Jack Klein <jackklein AT spamcop DOT net>
Newsgroups: comp.os.msdos.djgpp
Subject: Re: cursor
Message-ID: <cXsLOk0f1zJiKD784VjSxRKo85Ag@4ax.com>
References: <8udus7$jmh$1 AT lacerta DOT tiscalinet DOT it> <8ueg6s$qab$1 AT nets3 DOT rz DOT RWTH-Aachen DOT DE> <sfnl0tcdo2jeu66h0l3jb1k4m4m5s542hq AT 4ax DOT com> <8011-Thu09Nov2000204050+0200-eliz AT is DOT elta DOT co DOT il>
X-Newsreader: Forte Agent 1.6/32.525
MIME-Version: 1.0
Lines: 46
Date: Fri, 10 Nov 2000 04:52:43 GMT
NNTP-Posting-Host: 12.75.153.11
X-Complaints-To: abuse AT worldnet DOT att DOT net
X-Trace: bgtnsc05-news.ops.worldnet.att.net 973831963 12.75.153.11 (Fri, 10 Nov 2000 04:52:43 GMT)
NNTP-Posting-Date: Fri, 10 Nov 2000 04:52:43 GMT
Organization: AT&T Worldnet
To: djgpp AT delorie DOT com
DJ-Gateway: from newsgroup comp.os.msdos.djgpp
Reply-To: djgpp AT delorie DOT com

On Thu, 09 Nov 2000 20:40:51 +0200, "Eli Zaretskii"
<eliz AT is DOT elta DOT co DOT il> wrote in comp.os.msdos.djgpp:

> > From: Damian Yerrick <Bullcr_pd_yerrick AT hotmail DOT comRemoveBullcr_p>
> > Newsgroups: comp.os.msdos.djgpp
> > Date: Thu, 09 Nov 2000 17:25:38 GMT
> > 
> > Even the true text-mode cursor can be drawn as a | character though...
> 
> You mean, turn off the BIOS cursor and draw a character instead of it?
> That's quite tedious, especially if you want the cursor to blink.
> 
> Or do you mean something else?

A very long time ago on a system that was Z80 based, not x86, there
was a pretty clever solution that could probably be adapted to today's
PCs, although no so easily.

It basically had a text mode only display, but used a RAM, not a ROM,
for a character generator.  You can do something similar with all PC
displays with EGA or greater capability.

When you move the cursor onto some position of the display, build a
character pixel map consisting of the character with your vertical
line merged in, and set an unused character value (perhaps 255, which
is a blank) to use this bit map.

Hook the timer and on every fourth timer alternate between the actual
char value and the modified char value (i.e., 255), to get about a 2.5
Hz blink rate.

Of course you have to have coordination with your foreground display
routines.  They must set a flag to tell the timer routine to stop
working during display updates, and put back the original character,
and so on.

The last few versions of the Norton Utilities for DOS offered text
mode "graphics" including an arrow mouse pointer as an option on
computers with an EGA or higher, which was much more complicated.
Even though the mouse pointer was the size of a text character, they
allowed it to move pixel-by-pixel, which means it could be covering
varying parts of up to four characters at any given time.

Jack Klein
-- 
Home: http://jackklein.home.att.net

- Raw text -


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