Cool beans. "Magic" isn't literal. No magic, any time. ;) It's also probably in one of my vintage PC programming books or vintage programming text file collection. It reprograms timer0 (the system timer) of the 8254 and chains the interrupt handler for IRQ 0 (interrupt 8), and then bangs data out the speaker port relatively fast compared to "dumb" beeps.
Text mouse cursor: I think I first came across this trick in the 1st ed of PC Intern.
Artifact on "normal" default VGA text mode 3: the right-most pixel is duplicated from an 8x16 source glyph is displayed as an 9x16 sprite on a 720x400 (pixels) hardware frame buffer, so the cursor trick periodically has a stair-step artifact when in-between characters. The pixel is duplicated so box and line drawing and other glyphs can be gapless, and it's 9 pixels wide as characters look better than squished into 8x16. The source glyph in the table remains 8 pixels wide because it's exactly one byte wide (1 bit per pixel), because 9 pixels would take up 32 more bytes in the standard glyph table (or 64 bytes more in a 512 character table). This won't happen in 8 pixel wide glyph modes like 80x50 X 8x8 (640x400 - mode 66h) IT uses.
TIL: Linux may have a text mouse console driver that works, I'm guessing, with a coordination between kernel settings and gpm.