Mercurial > emacs
comparison lisp/dos-fns.el @ 88155:d7ddb3e565de
sync with trunk
author | Henrik Enberg <henrik.enberg@telia.com> |
---|---|
date | Mon, 16 Jan 2006 00:03:54 +0000 |
parents | 37645a051842 |
children |
comparison
equal
deleted
inserted
replaced
88154:8ce476d3ba36 | 88155:d7ddb3e565de |
---|---|
1 ;;; dos-fns.el --- MS-Dos specific functions | 1 ;;; dos-fns.el --- MS-Dos specific functions |
2 | 2 |
3 ;; Copyright (C) 1991, 1993, 1995, 1996 Free Software Foundation, Inc. | 3 ;; Copyright (C) 1991, 1993, 1995, 1996, 2002, 2003, 2004, |
4 ;; 2005 Free Software Foundation, Inc. | |
4 | 5 |
5 ;; Maintainer: Morten Welinder <terra@diku.dk> | 6 ;; Maintainer: Morten Welinder <terra@diku.dk> |
6 ;; Keywords: internal | 7 ;; Keywords: internal |
7 | 8 |
8 ;; This file is part of GNU Emacs. | 9 ;; This file is part of GNU Emacs. |
17 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the | 18 ;; MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the |
18 ;; GNU General Public License for more details. | 19 ;; GNU General Public License for more details. |
19 | 20 |
20 ;; You should have received a copy of the GNU General Public License | 21 ;; You should have received a copy of the GNU General Public License |
21 ;; along with GNU Emacs; see the file COPYING. If not, write to the | 22 ;; along with GNU Emacs; see the file COPYING. If not, write to the |
22 ;; Free Software Foundation, Inc., 59 Temple Place - Suite 330, | 23 ;; Free Software Foundation, Inc., 51 Franklin Street, Fifth Floor, |
23 ;; Boston, MA 02111-1307, USA. | 24 ;; Boston, MA 02110-1301, USA. |
24 | 25 |
25 ;;; Commentary: | 26 ;;; Commentary: |
26 | 27 |
27 ;; Part of this code is taken from (or derived from) demacs. | 28 ;; Part of this code is taken from (or derived from) demacs. |
28 | 29 |
29 ;;; Code: | 30 ;;; Code: |
30 | 31 |
31 ;; This overrides a trivial definition in files.el. | 32 ;; This overrides a trivial definition in files.el. |
32 (defun convert-standard-filename (filename) | 33 (defun convert-standard-filename (filename) |
33 "Convert a standard file's name to something suitable for the current OS. | 34 "Convert a standard file's name to something suitable for the current OS. |
34 This function's standard definition is trivial; it just returns the argument. | 35 This means to guarantee valid names and perhaps to canonicalize |
35 However, on some systems, the function is redefined | 36 certain patterns. |
36 with a definition that really does change some file names." | 37 |
38 On Windows and DOS, replace invalid characters. On DOS, make | |
39 sure to obey the 8.3 limitations. On Windows, turn Cygwin names | |
40 into native names, and also turn slashes into backslashes if the | |
41 shell requires it (see `w32-shell-dos-semantics')." | |
37 (if (or (not (stringp filename)) | 42 (if (or (not (stringp filename)) |
38 ;; This catches the case where FILENAME is "x:" or "x:/" or | 43 ;; This catches the case where FILENAME is "x:" or "x:/" or |
39 ;; "/", thus preventing infinite recursion. | 44 ;; "/", thus preventing infinite recursion. |
40 (string-match "\\`\\([a-zA-Z]:\\)?[/\\]?\\'" filename)) | 45 (string-match "\\`\\([a-zA-Z]:\\)?[/\\]?\\'" filename)) |
41 filename | 46 filename |
250 nil ; the original built-in function returned nil | 255 nil ; the original built-in function returned nil |
251 (set-frame-size (selected-frame) 80 43))) | 256 (set-frame-size (selected-frame) 80 43))) |
252 | 257 |
253 (provide 'dos-fns) | 258 (provide 'dos-fns) |
254 | 259 |
260 ;;; arch-tag: 00b03579-8ebb-4a02-8762-5c5a929774ad | |
255 ;;; dos-fns.el ends here | 261 ;;; dos-fns.el ends here |