Why does a flashing taskbar result in a fullscreen console returning to windowed mode?

Commenter Daniel wonders why a flashing taskbar results in a fullscreen console returning to windowed mode.

I didn't know the answer to this, but I formulated a guess, and I was ready to just post my guess. (Because everything I write is just conjecture anyway. Informed conjecture, but still.) But I had some time, so I went spelunking through the code history and about a half hour later, I found confirmation for my guess, so now it's not just a guess but a fact. (Don't expect me to go to all this effort in general. Guessing is a lot less time-consuming.)

The code to force a fullscreen console into windowed mode when a window flashes was introduced in Windows 2000, and I even found the bug report that led to the change, suitably edited of course:

Title: A flashing window should ensure that the taskbar (and the window itself?) are both visible
Date submitted: November 7, 1997

This is a problem similar to the auto-hide taskbar situation. If the taskbar is not visible, it has to be shown when flashed. This may force a full screen switch.

If the system is in full screen mode (ie, open a command window and type alt-enter), then if someone calls FlashWindow the user won't see the flashing window. So we have to make the screen switch to windowed mode. This is especially bad when someone calls SetForegroundWindow but we don't let him take the foreground; we simply flash the window instead.

The bug report pretty much lays out the justification for this change in behavior, so I'll leave it as it is.

Comments (23)
  1. John says:

    By "suitably edited" I assume you mean all the profanity was removed.

  2. Ryan Bemrose says:

    The justification is still wrong.  The desktop will never belong to the user as long as any app that calls FlashWindow() can forcefully interrupt what the user is doing.

    Try the following scenario on for size:

    1) Install Windows Live Messenger.

    2) Make your taskbar really big and set it to auto-hide.

    3) Begin working on Important Stuff (something more important than, say having an inane conversation with an annoying co-worker)

    4) Get an IM from said co-worker asking about basketball scores.

    5) Involuntarily click on the messenger window and chat with your co-worker about inane garbage, because the taskbar is going to keep popping up on top of your other work until the co-worker shuts up, so you won’t be getting any more work done anyway.

  3. frymaster says:
    1. Set live messenger to "away" or "offline" :P
  4. manicmarc says:


    I never have problem with messenger. It stops flashing after a few flashes. Turn off notifications and you won’t get any annoying animated notifications. I can be coding for a long time before I notice someone has messaged me, and they usually walk over and interrupt me if I don’t respond(!) anyway.

    There is a bug where it will flash for no reason after loosing focus, which is annoying since you think you’ve got a response and you haven’t.

  5. Gwyn says:
    1. Uninstall live messenger, and don’t make your taskbar so big?
  6. Paul Williams says:


    Let’s look at an alternative.  Assume I am a stock-trading whiz and a programming guru (neither are true in reality).  I have 100,000 shares of BIGCO stock.  BIGCO is trading at $100 / share, I have a nice nest egg built up.

    I have invested heavily in one company, so I carefully monitor my portfolio to ensure I am safe.  I run a fancy stock trading program that allows me to configure real-time alerts.  If BIGCO drops below $90 / share, it will flash on my taskbar; I’ll click it, view the alert, and act accordingly.  Seconds could mean the difference between retiring now or working until I am 101 years old.

    I also setup my CNN news ticker to alert me if it sees any BIGCO stories.  It, too, is supposed to flash on my task bar.

    I decide to flex my programming muscles by opening a command window full screen.  I merrily ftp/Perl/telnet/bash/Python/su/format c: my way to future glory.  Surely this code will make me rich any day now!

    Meanwhile, CNN runs a surprising story about BIGCO declaring bankruptcy.  The CNN news ticker tries to alert me by flashing the task bar, but it can’t– the command windows is full screen, and YOU decided that it shouldn’t disturb me.

    BIGCO stock dips immediately to $75, $40, and then below $1.  The stock market software is trying to warn me that I’m rapidly becoming destitute, but because YOU decided that I won’t get these alerts while I’m working, I am now broke, bankrupt, and actively looking up your address to tell you what I think about your decisions in person!

    Long story short (too late), don’t make your taskbar so big.  :)

  7. Aram Hăvărneanu says:

    Well, on 64 bit Windows 7 and Vista there’s only Windowed mode. I Wonder why. Don’t know anything about 32 bit versions.

  8. Alexandre Grigoriev says:


    I suspect that switching to text mode requires a callout to real mode BIOS through VDM, which is not supported in x64 OS (it doesn’t have VDM anymore).

  9. Cheong says:

    RyanBemrose: There’s some reason why WLM has a option to block message notifications when you’re in full screen mode…

  10. Bob says:

    Aram: Full-screen consoles aren’t supported under the New Driver Order with Vista, regardless of bitness. You have to be running an XP display driver (including Standard VESA) to go full-screen.

  11. slq says:

    Paul Williams,

    this is why God created stop-loss orders ;)

  12. Mark Sowul says:

    I wonder why (and how) every IM app I know (which includes Live Messenger, AIM, and Trillian, at least) manages to just flash the taskbar incessantly rather than respecting, "flash, flash, flash, stay highlighted."  It’s only marginally less annoying than it would be to just pop the UI in my face.  

    Live Messenger in particular somehow manages also not to work with "Close All Windows" (when multiple chat windows are opened and grouped in the taskbar), and it seems to botch window message processing in some way (the columns on DefWndProc come to mind), because if any of its windows are open, hitting the play/pause/next keys on my keyboard results in Windows Media Player reacting as though I hit the key 10 times.  But I digress.  

  13. Daniel ZY says:

    When you do alt in Vista 32 bit SP1 (regular build) the following message appears: "This system does not support full screen mode", the funny part is the title "Server 2008 DEBUG build Environment).

    How this happens?

  14. steveg says:

    Am I the only one would have hours of entertainment/fascination trawling through the Windows version source control system? Even something seemingly innocuous like the Notepad source code would probably be interesting…

    oooooh… 1992 *that’s* when the split each message into it’s own function… ooooh, obscure bug… really? no way! how did someone find that?

    I’d love to be locked away for a week just poking around. I should really get a life.

  15. ender says:

    Speaking of taskbar, I have it set to autohide, but sometimes something will cause it to want my attention and not go away. Usually the culprit is a menu from tray icon that didn’t open fast enough (and I went to do other things), but in some cases the taskbar plain and simply won’t hide away, with no visible reason (no button flashing, no forgotten menu in sight). Any idea how to find who’s responsible?

  16. @Paul Williams

    That’s why there are such things as desktop notifications and other similar stuff. Flashing the taskbar is absolutely the least informative way to notify about anything important.

    Showing a big message with the stock value and a large button "sell now!" would be more appropriate UI design decision for your situation.

  17. Brian Tkatch says:

    I would have thought a flashing full-screen window should have flashed some background color, not go to windowed mode.

    But, noone asked me.

  18. LionsPhil says:

    If you want sublety in your full-screen console notifications, you don’t want a full-screen console. You probably want a maximized window, so that Windows still has the resolution and colour depth capability to do so. Go rummage around on the Internets for a suitably retro VGA font, if you must.

    (Personally, my current taskbar irritation is that Windows 7 seems to have stopped the buttons being a mile-deep, after MS fixed this back in 2000 or so. Gah.)

  19. MadQ says:

    @ender: It’s probably a fancy animated icon in the  ashtray^H^H^H^H^H^H^H notification area. A colleague of mine was complaining about the same thing last week. I told him to disable "Animated Icon" in Antivirus product X’s notification area icon’s context menu.

  20. Mike Dimmick says:

    @Daniel ZY: because that’s the title of your console window, which presumably was created from the "Server 2008 DEBUG build Environment" shortcut installed by the Windows SDK.

    As Raymond has mentioned before, if you have multiple shortcuts to the same program, Windows picks a random shortcut to put on the Recently Used part of the Start Menu, because it counts programs, not shortcuts.

  21. foxyshadis says:

    @ender: If you have balloon tips (the actual notifications it’s named after) disabled, the taskbar will pop up and stay up until the invisible balloon goes away, usually after 30 seconds or whenever you click the right icon to acknowledge.

  22. Awesome. This is what we mean when we say Windows doesn’t take proper advantage of multiple monitors (We can remain full screen while monitoring the taskbar).

  23. Aaron says:

    This doesn’t always happen.

    I’ve recently been playing MS Flight Sim X (in full screen mode), and when new IM’s come in (on any IM service) Flight Sim remains foreground, full-screen.   When I eventually switch back to a windowed view, I can see the task bar has been flashing the whole time.

Comments are closed.

Skip to main content