MCPcopy Create free account
hub / github.com/Noumena-Network/code / setAltScreenActive

Method setAltScreenActive

src/ink/ink.tsx:998–1007  ·  view source on GitHub ↗

* Called by the component on mount/unmount. * Controls cursor.y clamping in the renderer and gates alt-screen-aware * behavior in SIGCONT/resize/unmount handlers. Repaints on change so * the first alt-screen frame (and first main-screen frame on exit) is * a full redraw

(active: boolean, mouseTracking = false)

Source from the content-addressed store, hash-verified

996 * a full redraw with no stale diff state.
997 */
998 setAltScreenActive(active: boolean, mouseTracking = false): void {
999 if (this.altScreenActive === active) return;
1000 this.altScreenActive = active;
1001 this.altScreenMouseTracking = active && mouseTracking;
1002 if (active) {
1003 this.resetFramesForAltScreen();
1004 } else {
1005 this.repaint();
1006 }
1007 }
1008 get isAltScreenActive(): boolean {
1009 return this.altScreenActive;
1010 }

Callers 1

AlternateScreenFunction · 0.80

Calls 2

repaintMethod · 0.95

Tested by

no test coverage detected