comparison lisp/progmodes/fortran.el @ 1475:2596132752ff

Doc fix.
author Christopher Zaborsky <rogue@erratum.com>
date Sun, 25 Oct 1992 19:44:06 +0000
parents 213978acbc1e
children a6da00e1c5ad
comparison
equal deleted inserted replaced
1474:341c17b20f2a 1475:2596132752ff
479 (list-one-abbrev-table fortran-mode-abbrev-table "*Help*") 479 (list-one-abbrev-table fortran-mode-abbrev-table "*Help*")
480 (message "Listing abbrev table...done")) 480 (message "Listing abbrev table...done"))
481 481
482 (defun fortran-column-ruler () 482 (defun fortran-column-ruler ()
483 "Inserts a column ruler momentarily above current line, till next keystroke. 483 "Inserts a column ruler momentarily above current line, till next keystroke.
484 The ruler is defined by the value of fortran-column-ruler. 484 The ruler is defined by the value of `fortran-column-ruler'.
485 The key typed is executed unless it is SPC." 485 The key typed is executed unless it is SPC."
486 (interactive) 486 (interactive)
487 (momentary-string-display 487 (momentary-string-display
488 fortran-column-ruler (save-excursion (beginning-of-line) (point)) 488 fortran-column-ruler (save-excursion (beginning-of-line) (point))
489 nil "Type SPC or any command to erase ruler.")) 489 nil "Type SPC or any command to erase ruler."))
490 490
491 (defun fortran-window-create () 491 (defun fortran-window-create ()
492 "Makes the window 72 columns wide. 492 "Makes the window 72 columns wide.
493 See also fortran-window-create-momentarily." 493 See also `fortran-window-create-momentarily'."
494 (interactive) 494 (interactive)
495 (condition-case error 495 (condition-case error
496 (progn 496 (progn
497 (let ((window-min-width 2)) 497 (let ((window-min-width 2))
498 (if (< (window-width) (frame-width)) 498 (if (< (window-width) (frame-width))
506 'error))) 506 'error)))
507 507
508 (defun fortran-window-create-momentarily (&optional arg) 508 (defun fortran-window-create-momentarily (&optional arg)
509 "Momentarily makes the window 72 columns wide. 509 "Momentarily makes the window 72 columns wide.
510 Optional ARG non-nil and non-unity disables the momentary feature. 510 Optional ARG non-nil and non-unity disables the momentary feature.
511 See also fortran-window-create." 511 See also `fortran-window-create'."
512 (interactive "p") 512 (interactive "p")
513 (if (or (not arg) 513 (if (or (not arg)
514 (= arg 1)) 514 (= arg 1))
515 (save-window-excursion 515 (save-window-excursion
516 (if (not (equal (fortran-window-create) 'error)) 516 (if (not (equal (fortran-window-create) 'error))
935 nil t) 935 nil t)
936 (looking-at (concat "^[ \t0-9]*do[ \t]*0*" charnum)))))))) 936 (looking-at (concat "^[ \t0-9]*do[ \t]*0*" charnum))))))))
937 937
938 (defun fortran-analyze-file-format () 938 (defun fortran-analyze-file-format ()
939 "Return 0 if Fixed format is used, 1 if Tab formatting is used. 939 "Return 0 if Fixed format is used, 1 if Tab formatting is used.
940 Use fortran-tab-mode-default if no non-comment statements are found in the 940 Use `fortran-tab-mode-default' if no non-comment statements are found in the
941 file before the end or the first fortran-analyze-depth lines." 941 file before the end or the first `fortran-analyze-depth' lines."
942 (save-excursion 942 (save-excursion
943 (goto-char (point-min)) 943 (goto-char (point-min))
944 (setq i 0) 944 (setq i 0)
945 (while (not (or 945 (while (not (or
946 (eobp) 946 (eobp)
954 ((looking-at " ") 0) 954 ((looking-at " ") 0)
955 (fortran-tab-mode-default 1) 955 (fortran-tab-mode-default 1)
956 (t 0)))) 956 (t 0))))
957 957
958 (defun fortran-tab-mode (arg) 958 (defun fortran-tab-mode (arg)
959 "Toggle fortran-tab-mode which indicates style of continuation lines. 959 "Toggle `fortran-tab-mode' which indicates style of continuation lines.
960 With no argument, toggle on/off the tabbing mode of continuation lines. 960 With no argument, toggle on/off the tabbing mode of continuation lines.
961 If argument is a positive number, or non-nil if not a number, fortran-tab-mode 961 If argument is a positive number, or non-nil if not a number,
962 is turned on. Otherwise 962 `fortran-tab-mode' is turned on. Otherwise `fortran-tab-mode' is false"
963 If `fortran-tab-mode' is false"
964 (interactive "P") 963 (interactive "P")
965 (setq fortran-tab-mode 964 (setq fortran-tab-mode
966 (if (null arg) (not fortran-tab-mode) 965 (if (null arg) (not fortran-tab-mode)
967 (if (numberp arg) 966 (if (numberp arg)
968 (> (prefix-numeric-value arg) 0) 967 (> (prefix-numeric-value arg) 0)
985 (setq fortran-tab-mode-string " TAB-format") 984 (setq fortran-tab-mode-string " TAB-format")
986 (set-buffer-modified-p (buffer-modified-p))) 985 (set-buffer-modified-p (buffer-modified-p)))
987 986
988 (defun fortran-setup-fixed-format-style () 987 (defun fortran-setup-fixed-format-style ()
989 "Set up fortran mode to use the column 6 mode of continuation lines. 988 "Set up fortran mode to use the column 6 mode of continuation lines.
990 Use the command fortran-tab-mode to toggle between this and tab 989 Use the command `fortran-tab-mode' to toggle between this and tab
991 character format style." 990 character format style."
992 (setq fortran-comment-line-column 6) 991 (setq fortran-comment-line-column 6)
993 (setq fortran-minimum-statement-indent 6) 992 (setq fortran-minimum-statement-indent 6)
994 (setq indent-tabs-mode nil) 993 (setq indent-tabs-mode nil)
995 (setq fortran-column-ruler 994 (setq fortran-column-ruler