From: George H. <geo...@us...> - 2006-09-25 11:44:39
|
Update of /cvsroot/win32forth/win32forth/src In directory sc8-pr-cvs9.sourceforge.net:/tmp/cvs-serv6187/win32forth/src Modified Files: paths.f Log Message: gah:Minor spelling corrections. Index: paths.f =================================================================== RCS file: /cvsroot/win32forth/win32forth/src/paths.f,v retrieving revision 1.25 retrieving revision 1.26 diff -C2 -d -r1.25 -r1.26 *** paths.f 26 Aug 2006 15:25:32 -0000 1.25 --- paths.f 25 Sep 2006 11:44:34 -0000 1.26 *************** *** 53,57 **** cr ." Current directory: " current-dir$ count type ; ! : chdir ( -<optional_new_directory>- ) \ *G Set the current directory. /parse-word count "chdir cr .dir ; --- 53,57 ---- cr ." Current directory: " current-dir$ count type ; ! : chdir ( -<optional_new_directory>- -- ) \ *G Set the current directory. /parse-word count "chdir cr .dir ; *************** *** 60,69 **** IN-APPLICATION ! : path: ( - ) \ *G Defines a directory search path. \n \ ** The first 2 cells are used too handle a search path. \n \ ** The next 260 bytes are reserved for a counted string of a path. \n ! \ ** followed by 0. \n ! \ ** In runtime it returns adres of the counted string of a path create -1 , 0 , MAX-PATH 1+ allot does> \ run-time: ( - path ) [ 2 cells ] literal + --- 60,69 ---- IN-APPLICATION ! : path: ( -- ) \ *G Defines a directory search path. \n \ ** The first 2 cells are used too handle a search path. \n \ ** The next 260 bytes are reserved for a counted string of a path. \n ! \ ** followed by null. \n ! \ ** At runtime it returns address of the counted string of a path create -1 , 0 , MAX-PATH 1+ allot does> \ run-time: ( - path ) [ 2 cells ] literal + *************** *** 78,84 **** create path-file$ MAX-PATH 1+ allot ! : path-source ( path - 2variable_path-source ) \ *G Path-source points to a substring in a path. \n ! \ ** Path-source returns this adress. 2 cells- ; --- 78,84 ---- create path-file$ MAX-PATH 1+ allot ! : path-source ( path -- 2variable_path-source ) \ *G Path-source points to a substring in a path. \n ! \ ** Path-source returns this address. 2 cells- ; *************** *** 156,161 **** INTERNAL ! : volume-indication? ( adr - flag ) ! \ *G True when the counted string at adr starts with x: or \\name dup 2 + c@ ascii : <> if count drop 2 s" \\" compare 0= --- 156,161 ---- INTERNAL ! : volume-indication? ( addr -- flag ) ! \ *G True when the counted string at addr starts with x: or \\name dup 2 + c@ ascii : <> if count drop 2 s" \\" compare 0= *************** *** 358,373 **** \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ ! : "file-clip" { adr len limit \ temp$ pre -- 'adr 'len } ! \ *G Clip filename to limit. new$ to temp$ \ so string isn't de-allocated on exit ! limit 20 max to limit \ must be at east 16 limit 20 - 2 / 6 + to pre \ balance start and end len limit > ! if adr pre 3 - temp$ place \ lay in first 5 chars s" ..." temp$ +place \ append some dots ! adr len dup limit pre - - 0MAX /string \ clip to last part temp$ +place \ of name and lay in temp$ count ! else adr len \ no need to clip file then ; --- 358,376 ---- \ \\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\\ ! : "file-clip" { addr len limit | temp$ pre -- addr len2 } ! \ *G Clip filename to limit. If limit is less than 20 then the filename is clipped to ! \ ** 20. len2=len if len < limit or len < 20. len2 = 20 if limit < 20. len2 = limt ! \ ** otherwise. The string (if clipped) contains ... in the middle to indicate that# ! \ ** it has been clipped. new$ to temp$ \ so string isn't de-allocated on exit ! limit 20 max to limit \ must be at least 16 limit 20 - 2 / 6 + to pre \ balance start and end len limit > ! if addr pre 3 - temp$ place \ lay in first 5 chars s" ..." temp$ +place \ append some dots ! addr len dup limit pre - - 0MAX /string \ clip to last part temp$ +place \ of name and lay in temp$ count ! else addr len \ no need to clip file then ; |