delorie.com/archives/browse.cgi   search  
Mail Archives: djgpp/1999/04/29/03:19:25

Date: Thu, 29 Apr 1999 10:16:56 +0300 (IDT)
From: Eli Zaretskii <eliz AT is DOT elta DOT co DOT il>
X-Sender: eliz AT is
To: Michael Bukin <M DOT A DOT Bukin AT inp DOT nsk DOT su>
cc: djgpp AT delorie DOT com
Subject: Re: Windows trashes my 800x600 graphics mode program
In-Reply-To: <20d80o96zh.fsf@Sky.inp.nsk.su>
Message-ID: <Pine.SUN.3.91.990429101620.6487D-100000@is>
MIME-Version: 1.0
Reply-To: djgpp AT delorie DOT com
X-Mailing-List: djgpp AT delorie DOT com
X-Unsubscribes-To: listserv AT delorie DOT com

On 28 Apr 1999, Michael Bukin wrote:

> > Could you please describe these adverse effects on application switching?
> 
> Application calls Int 0x2F4000 and enters graphics mode.  When I try
> to switch with ALT-TAB, I don't get to Windows desktop, instead I see
> black screen with white mouse cursor.  Sometimes I can switch back to
> the test application with ALT-TAB (to the black screen of graphics
> mode), and sometimes I was unable to switch back, but maybe I was
> switching to some other applications, just because I can not see which
> application is selected with ALT-TAB.  But when I switch with Windows
> key, sometimes I get to desktop and sometimes to black screen with
> cursor.

The docs for the 2F/40xx series of functions is confusing, and
probably leaves some crucial details out.  For example, it doesn't
even say explicitly that 2F/4000 *must* be called to enable the
switch-to-{fore,back}ground call-outs.  It is no accident that even
Ralf Brown's Interrupt List doesn't get these functions right.

> When application finishes, sometimes I loose font, i.e. I can see
> colors of Norton Commander panels, but no characters (using
> `mode co80' fixes it).  Maybe it happens when test application
> switches to text mode when it is not currently selected application.
> 
> When I try to switch DOS-box from fullscreen to windowed mode after
> application has finished its work, Windows pops up message that it can
> not run this application minimized or that it will be shut down, or I
> get to black screen with cursor again and can not get rid of it with
> ALT-TAB, CTRL-ALT-DEL and whatever, so I have to reboot.

From what docs is available, it seems that calling 2F/4000 causes
Windows to stop saving and restoring the video memory, leaving that to
the application.  I don't think your test program did that.  Also,
there are the 2F/4005 and 2F/4006 call-outs that the application is
supposed to handle after it called 2F/4000.

Perhaps ignoring all this mess is the reason for the strange behavior?

- Raw text -


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