Dosbox won’t get Ctrl-Break…

As you do not know, during my recent bike holidays, I ran into Arnout and had another go at Sokoban. Of course, I couldn’t just let it be and I’ve been having some fun ever since tinkering with the source code.

Point of particular annoyance: in Dosbox, QB / QBasic does not react to CTRL+Break. Which happens to be the key code to halt the program and edit it — in other words, my debugging key. I now got curious, and turned to The Google.

  • Here’s why CTRL+Break doesn’t work in a normal DosBox setup.
    (tl;dr version: no event generated whatsoever by the keypress. Also: this is a “magical” key-combo, in that it triggers an erase of the keyboard buffer and a call to a special handler — in short: special magic is needed, and none of it is there).
  • Apparently, there is a patch to enable CTRL+Break (note that this patch requires another patch). Didn’t try it myself.
  • Best of all: QB / QBasic respond similarly to CTRL+ScrollLock. Which works out of the (dos)box. :)

Comments are closed.