From: Rod O. <rod...@us...> - 2008-12-19 22:38:49
|
Update of /cvsroot/win32forth/win32forth/src/console In directory 23jxhf1.ch3.sourceforge.com:/tmp/cvs-serv18193 Modified Files: Console1.f Console2.f ConsoleMenu.f ConsoleStatbar.f NewConsole.f Log Message: Rod: put some console words in-system and/or made internal. More words could be put in-system to make turnkeys smaller. Index: ConsoleStatbar.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/src/console/ConsoleStatbar.f,v retrieving revision 1.9 retrieving revision 1.10 diff -C2 -d -r1.9 -r1.10 *** ConsoleStatbar.f 19 Aug 2008 03:55:24 -0000 1.9 --- ConsoleStatbar.f 19 Dec 2008 22:38:41 -0000 1.10 *************** *** 10,14 **** ! \ INTERNAL \ ***************************************************************************** --- 10,14 ---- ! INTERNAL \ ***************************************************************************** *************** *** 109,112 **** --- 109,114 ---- \ ***************************************************************************** + in-system + : Update-Console-Statusbar ( -- ) \ update the status bar GetHandle: ConsoleStatusbar *************** *** 124,127 **** --- 126,131 ---- \ EXTERNAL + in-application + \ changed to use the reset-stack-chain \ January 22nd, 2004 - 13:53 dbu *************** *** 132,135 **** --- 136,140 ---- reset-stack-chain chain-add CONSOLE-STATUSBAR-RESET-STACKS + (( INTERNAL *************** *** 140,144 **** : Console-SetDisplayDepth ( n -- ) SetDisplayDepth: ConsoleStatusbar ; ! MODULE --- 145,149 ---- : Console-SetDisplayDepth ( n -- ) SetDisplayDepth: ConsoleStatusbar ; ! )) MODULE Index: NewConsole.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/src/console/NewConsole.f,v retrieving revision 1.31 retrieving revision 1.32 diff -C2 -d -r1.31 -r1.32 *** NewConsole.f 17 Dec 2008 10:17:23 -0000 1.31 --- NewConsole.f 19 Dec 2008 22:38:41 -0000 1.32 *************** *** 32,35 **** --- 32,38 ---- CommandWindow cmd + INTERNAL + EXTERNAL + \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ *************** *** 183,187 **** INTERNAL ! EXTERNAL : c_type ( a n -- ) --- 186,190 ---- INTERNAL ! in-system : c_type ( a n -- ) *************** *** 284,288 **** : c_getrowoff ( -- n ) FirstVisibleRow: cmd ; ! :noname ( n -- ) Case --- 287,291 ---- : c_getrowoff ( -- n ) FirstVisibleRow: cmd ; ! IN-APPLICATION :noname ( n -- ) Case *************** *** 319,322 **** --- 322,326 ---- )) + IN-SYSTEM ' menukey-more is LogKeyStrokes *************** *** 360,365 **** ; ! forth-io-chain chain-add NewConsole ! :noname ( -- ) --- 364,368 ---- ; ! \in-system-ok forth-io-chain chain-add NewConsole :noname ( -- ) Index: ConsoleMenu.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/src/console/ConsoleMenu.f,v retrieving revision 1.21 retrieving revision 1.22 diff -C2 -d -r1.21 -r1.22 *** ConsoleMenu.f 2 Sep 2008 07:01:23 -0000 1.21 --- ConsoleMenu.f 19 Dec 2008 22:38:41 -0000 1.22 *************** *** 249,257 **** @ repeat drop ! true havemenu! ZeroMenu: console-menu conhndl loadmenu: console-menu menuhandle: console-menu ! conhndl call SetMenu havemenu! ZeroMenu: console-popup conhndl loadmenu: console-popup ; --- 249,257 ---- @ repeat drop ! \ true havemenu! ZeroMenu: console-menu conhndl loadmenu: console-menu menuhandle: console-menu ! conhndl call SetMenu drop \ havemenu! ZeroMenu: console-popup conhndl loadmenu: console-popup ; *************** *** 260,265 **** : Menu-off ( -- ) \ turn off the console's menubar ! false havemenu! ! 0 conhndl call SetMenu 0= havemenu! ; --- 260,265 ---- : Menu-off ( -- ) \ turn off the console's menubar ! \ false havemenu! ! 0 conhndl call SetMenu drop \ 0= havemenu! ; Index: Console1.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/src/console/Console1.f,v retrieving revision 1.6 retrieving revision 1.7 diff -C2 -d -r1.6 -r1.7 *** Console1.f 17 Dec 2008 10:17:23 -0000 1.6 --- Console1.f 19 Dec 2008 22:38:41 -0000 1.7 *************** *** 30,33 **** --- 30,36 ---- \ sound stuff \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ + + in-application + VARIABLE TONE_FREQ 700 TONE_FREQ ! VARIABLE TONE_DURA 50 TONE_DURA ! *************** *** 108,115 **** --- 111,127 ---- 8 value tab-size 8 value left-margin + + in-system + 4 value right-margin 0 value tab-margin 5 value tabs-max + + in-application + 0 value tabing? \ are we tabing, default to no + + in-system + 0 value first-line? \ is this the first line of a paragraph -8 value indent \ indent/outdent spaces *************** *** 148,151 **** --- 160,165 ---- 0tab ; + in-application + : TABING-ON ( -- ) true to tabing? ; *************** *** 157,160 **** --- 171,176 ---- synonym tabbing-on tabing-on + in-system + : CRTAB ( -- ) cr \ [cdo] because w32fconsole.dll was removed *************** *** 179,184 **** \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ 1 PROC GetKeyState ! : shiftmask ( -- mask ) 0 17 ( VK_CONTROL ) Call GetKeyState 32768 and \ if control is down --- 195,202 ---- \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ + in-application + 1 PROC GetKeyState ! : shiftmask ( -- mask ) 0 17 ( VK_CONTROL ) Call GetKeyState 32768 and \ if control is down *************** *** 194,201 **** --- 212,223 ---- shiftmask control_mask and 0<> ; + in-system + 4 PROC SetWindowPos : set-conpos ( x y -- ) \ set the console position 2>r ( SWP_NOSIZE ) 1 0 0 2r> ( HWND_TOP ) 0 _conHndl call SetWindowPos drop ; + (( + in-application 0 value havemenu? *************** *** 203,206 **** --- 225,230 ---- to havemenu? ; + in-system + )) 1 PROC GetDC : conDC ( -- dc ) \ get the console device context *************** *** 241,244 **** --- 265,270 ---- \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ + in-application + SYNONYM EKEY KEY ( -- u ) SYNONYM EKEY? KEY? ( -- flag ) Index: Console2.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/src/console/Console2.f,v retrieving revision 1.13 retrieving revision 1.14 diff -C2 -d -r1.13 -r1.14 *** Console2.f 2 Sep 2008 07:01:23 -0000 1.13 --- Console2.f 19 Dec 2008 22:38:41 -0000 1.14 *************** *** 22,29 **** --- 22,33 ---- \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ + (( + in-system : minimize-console ( -- ) SW_SHOWMINIMIZED conhndl call ShowWindow drop ; + in-application + )) \ Make console the foreground window. Ignore error which will occur if we are \ running under Windows95 and we are already the foreground window. *************** *** 52,55 **** --- 56,61 ---- ['] SetActiveWindow (SetWindow) ; + in-system + : _foreground-console ( -- ) conhndl (SetForegroundWindow) ; *************** *** 64,67 **** --- 70,74 ---- ' _activate-console is activate-console + in-application 0 value mousex |