1 ! Copyright (C) 2012 John Benediktsson
2 ! See http://factorcode.org/license.txt for BSD license
4 USING: accessors kernel math system terminal windows.kernel32 ;
8 M: windows (terminal-size)
9 STD_OUTPUT_HANDLE GetStdHandle
10 CONSOLE_SCREEN_BUFFER_INFO new
11 [ GetConsoleScreenBufferInfo ] keep swap zero? [
15 [ [ Right>> ] [ Left>> ] bi - 1 + ]
16 [ [ Bottom>> ] [ Top>> ] bi - 1 + ] bi