2008-11-21 03:16:16 -05:00
|
|
|
USING: editors io.files io.launcher kernel math.parser
|
2008-12-15 22:45:18 -05:00
|
|
|
namespaces sequences windows.shell32 make io.pathnames ;
|
2008-11-21 03:16:16 -05:00
|
|
|
IN: editors.notepad2
|
|
|
|
|
2008-12-08 21:11:24 -05:00
|
|
|
: notepad2-path ( -- path )
|
2008-11-21 03:16:16 -05:00
|
|
|
\ notepad2-path get-global [
|
2008-12-15 22:45:18 -05:00
|
|
|
windows-directory "system32\\notepad.exe" append-path
|
2009-01-16 15:13:17 -05:00
|
|
|
[ "notepad.exe" ] unless*
|
2008-12-08 21:11:24 -05:00
|
|
|
] unless* ;
|
2008-11-21 03:16:16 -05:00
|
|
|
|
|
|
|
: notepad2 ( file line -- )
|
|
|
|
[
|
|
|
|
notepad2-path ,
|
|
|
|
"/g" , number>string , ,
|
|
|
|
] { } make run-detached drop ;
|
|
|
|
|
2008-12-08 21:11:24 -05:00
|
|
|
[ notepad2 ] edit-hook set-global
|