From: Jack Klein Newsgroups: comp.os.msdos.djgpp Subject: Re: cursor Message-ID: References: <8udus7$jmh$1 AT lacerta DOT tiscalinet DOT it> <8ueg6s$qab$1 AT nets3 DOT rz DOT RWTH-Aachen DOT DE> <8011-Thu09Nov2000204050+0200-eliz AT is DOT elta DOT co DOT il> X-Newsreader: Forte Agent 1.6/32.525 MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit 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" wrote in comp.os.msdos.djgpp: > > From: Damian Yerrick > > 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