From: Ezra B. <ezr...@us...> - 2010-12-02 05:33:03
|
Update of /cvsroot/win32forth/win32forth/apps/ForthForm In directory sfp-cvsdas-4.v30.ch3.sourceforge.com:/tmp/cvs-serv13413 Modified Files: CreateToolBar.f FORTHFORM.F FormMenu.f FormPad.f Log Message: Made these apps compilable from IDE Index: FORTHFORM.F =================================================================== RCS file: /cvsroot/win32forth/win32forth/apps/ForthForm/FORTHFORM.F,v retrieving revision 1.24 retrieving revision 1.25 diff -C2 -d -r1.24 -r1.25 *** FORTHFORM.F 3 Aug 2008 00:49:04 -0000 1.24 --- FORTHFORM.F 2 Dec 2010 05:32:54 -0000 1.25 *************** *** 120,124 **** \ adapted from WinEd ! 20209 constant fform_version# \ 2.02.09 \ Version numbers: v.ww.rr --- 120,124 ---- \ adapted from WinEd ! 20210 constant fform_version# \ 2.02.10 \ Version numbers: v.ww.rr *************** *** 192,211 **** \+ withbgnd BkGndImageWindow link-formwindow \ link ! : Start-Win32ForthIDE ( -- ) \ start the editor if not already started ! editor-present? ! if s" Win32Forth*IDE" "SetToForeground drop ! else s" Win32ForthIDE.exe" PrePend<Home>\ ! conhndl ExecuteFile ! then ; ! ! : ffLoadProject ( -- ) \ start the project manager if not started ! s" Win32for.exe" PrePend<Home>\ ! temp$ place s" LoadProject" temp$ +place temp$ ! exec-cmd drop ; ! ! : Start-ProjectManager ( -- ) \ start the project manager if not started ! ?promgr-started ?exit ! s" Project.exe" PrePend<Home>\ ! GetHandle: TheMainWindow ExecuteFile ; : set-base-path ( -- ) --- 192,211 ---- \+ withbgnd BkGndImageWindow link-formwindow \ link ! \ : Start-Win32ForthIDE ( -- ) \ start the editor if not already started ! \ editor-present? ! \ if s" Win32Forth*IDE" "SetToForeground drop ! \ else s" Win32ForthIDE.exe" PrePend<Home>\ ! \ conhndl ExecuteFile ! \ then ; ! \ ! \ : ffLoadProject ( -- ) \ start the project manager if not started ! \ s" Win32for.exe" PrePend<Home>\ ! \ temp$ place s" LoadProject" temp$ +place temp$ ! \ exec-cmd drop ; ! \ ! \ : Start-ProjectManager ( -- ) \ start the project manager if not started ! \ ?promgr-started ?exit ! \ s" Project.exe" PrePend<Home>\ ! \ GetHandle: TheMainWindow ExecuteFile ; : set-base-path ( -- ) *************** *** 372,376 **** then ; ' updatewin is doupdate ! /* ******************** Specialised words for ForthForm.cfg ************** */ #IFDEF withbgnd create BkGndImage$ 0 , max-path allot-to \ for user supplied BackGroundImage --- 372,376 ---- then ; ' updatewin is doupdate ! \ ******************** Specialised words for ForthForm.cfg ************** */ #IFDEF withbgnd create BkGndImage$ 0 , max-path allot-to \ for user supplied BackGroundImage *************** *** 385,389 **** ' SetBackGroundImage alias SetWallpaper \ for compatibility #ENDIF ! /* ************************************************************************* */ : SaveRebar ( -- ) --- 385,389 ---- ' SetBackGroundImage alias SetWallpaper \ for compatibility #ENDIF ! \ ************************************************************************* */ : SaveRebar ( -- ) *************** *** 617,621 **** Repeat ; is doCloseAllForms ! /* ********************** Main ForthForm Window *************** */ :Object MainWindow <Super Window --- 617,621 ---- Repeat ; is doCloseAllForms ! \ ********************** Main ForthForm Window *************** */ :Object MainWindow <Super Window *************** *** 771,775 **** On_Size: self ;m ! /* ***************** Toolbar handlers *********************** */ :M WM_NOTIFY { h m w l \ hwndfrom -- f } --- 771,775 ---- On_Size: self ;m ! \ ***************** Toolbar handlers *********************** */ :M WM_NOTIFY { h m w l \ hwndfrom -- f } *************** *** 909,913 **** then ExitScintillaControl \+ sysgen 0 Call PostQuitMessage ! \+ sysgen false fform-started \ set as no longer running On_Done: super --- 909,913 ---- then ExitScintillaControl \+ sysgen 0 Call PostQuitMessage ! \ \+ sysgen false fform-started \ set as no longer running On_Done: super *************** *** 935,971 **** ;M ! : answer_message ( -- ) \ if file specified open it ! SetForegroundWindow: self ! param-buffer count ?dup ! if OpenByExtension ! else drop ! then ; ! ! : build-form-list { \ tmp cnt -- } ! 0 param-buffer ! \ default at no forms ! #Forms 0= ?exit ! 0 to cnt \ reset ! param-buffer cell+ to tmp ! #Forms 1+ 1 ! ?do i >Link#: FormList ! TextFile: [ Data@: FormList ] dup 1+ cnt + ! param-max > not \ don't exceed buffer ! if tuck tmp place 1+ +to cnt ! 1 param-buffer +! \ increment form count ! tmp count + to tmp ! else 2drop ! then ! loop ; ! ! : send-forms ( -- ) ! build-form-list 0 FORMS_SENT win32forth-message ; ! ! :M Win32Forth: ( h m w l -- ) ! over case ! FF_ACTIVATE of answer_message endof ! WANT_FORMS of send-forms endof ! Win32Forth: super ! endcase ! 0 ;M :M PushKey: ( c -- ) --- 935,971 ---- ;M ! \ : answer_message ( -- ) \ if file specified open it ! \ SetForegroundWindow: self ! \ param-buffer count ?dup ! \ if OpenByExtension ! \ else drop ! \ then ; ! \ ! \ : build-form-list { \ tmp cnt -- } ! \ 0 param-buffer ! \ default at no forms ! \ #Forms 0= ?exit ! \ 0 to cnt \ reset ! \ param-buffer cell+ to tmp ! \ #Forms 1+ 1 ! \ ?do i >Link#: FormList ! \ TextFile: [ Data@: FormList ] dup 1+ cnt + ! \ param-max > not \ don't exceed buffer ! \ if tuck tmp place 1+ +to cnt ! \ 1 param-buffer +! \ increment form count ! \ tmp count + to tmp ! \ else 2drop ! \ then ! \ loop ; ! \ ! \ : send-forms ( -- ) ! \ build-form-list 0 FORMS_SENT win32forth-message ; ! \ ! \ :M Win32Forth: ( h m w l -- ) ! \ over case ! \ FF_ACTIVATE of answer_message endof ! \ WANT_FORMS of send-forms endof ! \ Win32Forth: super ! \ endcase ! \ 0 ;M :M PushKey: ( c -- ) *************** *** 974,978 **** 'O' +k_control of doOpen endof K_F9 of SetFocus: Monitor endof ! K_F12 of ffLoadProject endof K_F1 of doFormHelp endof endcase ;M --- 974,978 ---- 'O' +k_control of doOpen endof K_F9 of SetFocus: Monitor endof ! \ K_F12 of ffLoadProject endof K_F1 of doFormHelp endof endcase ;M *************** *** 1005,1020 **** ; ! : check-if-running ( -- ) ! ed-ptr ! if ?fform-started ! if CmdLine ?dup ! if strip-cmdline ! else drop pad 0 ! then param-buffer place ! 0 FF_ACTIVATE win32forth-message ! bye ! else true fform-started \ set as running ! then ! then ; : show-release-notes ( -- ) \ show one time only --- 1005,1020 ---- ; ! \ : check-if-running ( -- ) ! \ ed-ptr ! \ if ?fform-started ! \ if CmdLine ?dup ! \ if strip-cmdline ! \ else drop pad 0 ! \ then param-buffer place ! \ 0 FF_ACTIVATE win32forth-message ! \ bye ! \ else true fform-started \ set as running ! \ then ! \ then ; : show-release-notes ( -- ) \ show one time only *************** *** 1026,1030 **** : FForm ( -- ) ! \+ sysgen check-if-running init-forthform LoadDefaults \ read default settings in registry --- 1026,1030 ---- : FForm ( -- ) ! \ \+ sysgen check-if-running init-forthform LoadDefaults \ read default settings in registry *************** *** 1039,1043 **** : EndForthForm ( -- ) ! doCloseAllForms false fform-started k_bye ; : ff ( -- ) \ main executable word --- 1039,1043 ---- : EndForthForm ( -- ) ! doCloseAllForms ( false fform-started ) k_bye ; : ff ( -- ) \ main executable word *************** *** 1045,1048 **** --- 1045,1052 ---- ['] FForm catch ExitOnError ; + : run-ff ( -- ) + ff + messageloop ; + previous definitions *************** *** 1067,1070 **** --- 1071,1075 ---- #ENDIF + false to sys-warning? 0 value con : ForthConsole ( -- ) *************** *** 1086,1089 **** --- 1091,1096 ---- then ; + true to sys-warning? + #IFDEF sysgen ' ForthConsole is doForth *************** *** 1092,1096 **** #ENDIF ! /* ********************** ForthForm Preferences **************** */ \ preferences.frm \ preferences dialog --- 1099,1103 ---- #ENDIF ! \ ********************** ForthForm Preferences **************** */ \ preferences.frm \ preferences dialog *************** *** 1140,1144 **** right of CheckButton: radAlignRight endof endcase ; is doPref ! /* ************************************************************************* */ :NoName ( -- ) \ shutdown --- 1147,1151 ---- right of CheckButton: radAlignRight endof endcase ; is doPref ! \ ************************************************************************* */ :NoName ( -- ) \ shutdown *************** *** 1228,1233 **** \+ sysgen s" %DIRWin32ForthIDE.exe /B %FILENAME %LINE" browse$ place \+ sysgen &forthdir count &appdir place \ create ForthForm.exe in the Win32Forth directory ! ! \+ sysgen 0 0 ' ff application ForthForm.exe forthform also --- 1235,1240 ---- \+ sysgen s" %DIRWin32ForthIDE.exe /B %FILENAME %LINE" browse$ place \+ sysgen &forthdir count &appdir place \ create ForthForm.exe in the Win32Forth directory ! \+ sysgen consolehiddenboot ! \+ sysgen ' run-ff save ForthForm.exe forthform also *************** *** 1240,1242 **** \s - That's all folks! --- 1247,1248 ---- Index: FormMenu.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/apps/ForthForm/FormMenu.f,v retrieving revision 1.5 retrieving revision 1.6 diff -C2 -d -r1.5 -r1.6 *** FormMenu.f 25 Feb 2007 19:04:42 -0000 1.5 --- FormMenu.f 2 Dec 2010 05:32:54 -0000 1.6 *************** *** 48,54 **** MenuItem "&Define Menu" doCreateMenu ; :MenuItem mnu_psheet "&Property Form Template" doPropertyForm ; ! MenuSeparator ! MenuItem "Win32Forth IDE" Start-Win32ForthIDE ; ! MENUITEM "Compile &Project\tF12" FFLoadProject ; \ MenuItem "Project Manager " Start-ProjectManager ; --- 48,54 ---- MenuItem "&Define Menu" doCreateMenu ; :MenuItem mnu_psheet "&Property Form Template" doPropertyForm ; ! \ MenuSeparator ! \ MenuItem "Win32Forth IDE" Start-Win32ForthIDE ; ! \ MENUITEM "Compile &Project\tF12" FFLoadProject ; \ MenuItem "Project Manager " Start-ProjectManager ; Index: CreateToolBar.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/apps/ForthForm/CreateToolBar.f,v retrieving revision 1.7 retrieving revision 1.8 diff -C2 -d -r1.7 -r1.8 *** CreateToolBar.f 15 Apr 2007 02:59:51 -0000 1.7 --- CreateToolBar.f 2 Dec 2010 05:32:54 -0000 1.8 *************** *** 737,741 **** r> >Link#: TBList ; ! /* : WriteDefaultButtonText ( -- ) +crlf s" :ToolStrings ButtonText" append&crlf --- 737,741 ---- r> >Link#: TBList ; ! (( : WriteDefaultButtonText ( -- ) +crlf s" :ToolStrings ButtonText" append&crlf *************** *** 756,760 **** 1 +tabs s" ts," append "append s" Help" append "append +crlf s" ;ToolStrings" append&crlf +crlf ; ! */ : WriteDefaultTooltips ( -- ) --- 756,760 ---- 1 +tabs s" ts," append "append s" Help" append "append +crlf s" ;ToolStrings" append&crlf +crlf ; ! )) : WriteDefaultTooltips ( -- ) Index: FormPad.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/apps/ForthForm/FormPad.f,v retrieving revision 1.3 retrieving revision 1.4 diff -C2 -d -r1.3 -r1.4 *** FormPad.f 27 Dec 2006 18:43:57 -0000 1.3 --- FormPad.f 2 Dec 2010 05:32:54 -0000 1.4 *************** *** 93,100 **** : ShowSource ( addr cnt title$ cnt -- ) ! editor-present? \ is SciEdit open? ! if ed-filename place \ pass name through shared memory ! copy-clipboard \ send source to clipboard ! 0 FF_PASTE editor-message \ tell SciEdit to paste it else View: FormPad then ; --- 93,100 ---- : ShowSource ( addr cnt title$ cnt -- ) ! false \ editor-present? \ is SciEdit open? ! if \ ed-filename place \ pass name through shared memory ! \ copy-clipboard \ send source to clipboard ! \ 0 FF_PASTE editor-message \ tell SciEdit to paste it else View: FormPad then ; |