• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /macosx-10.9.5/emacs-92/emacs/lisp/progmodes/

Lines Matching +defs:font +defs:spec

165   :link '(custom-group-link :tag "Font Lock Faces group" font-lock-faces)
456 (defvar ada-spec-suffixes '(".ads")
457 "List of possible suffixes for Ada spec files.
838 ;; character. This is already done in `font-lock-mode' (in
839 ;; `font-lock-syntactic-keywords', so we take advantage of the existing
840 ;; mechanism. If font-lock-mode is not activated, we do it by hand in
862 ;; almost never used as such and throws font-lock and indentation
945 This would be a duplicate of font-lock if both are used at the same time."
965 ;; Setting this only if font-lock is not set won't work
966 ;; if the user activates or deactivates font-lock-mode,
1073 (defun ada-add-extensions (spec body)
1075 Going from body to spec with `ff-find-other-file' used these
1082 (setcdr tmp (list (cons spec (cadr tmp))))
1083 (add-to-list 'ada-other-file-alist (list reg (list spec)))))
1085 (let* ((reg (concat (regexp-quote spec) "$"))
1092 (cons (concat (regexp-quote spec) "\\'") 'ada-mode))
1096 (add-to-list 'ada-spec-suffixes spec)
1104 spec)
1148 If you use this function in a spec and no body is available, it gets created with body stubs.
1221 ;; font-lock support :
1227 (put 'ada-mode 'font-lock-defaults
1228 '(ada-font-lock-keywords
1231 (set (make-local-variable 'font-lock-defaults)
1232 '(ada-font-lock-keywords
1236 (font-lock-syntactic-keywords . ada-font-lock-syntactic-keywords)))
1260 ada-spec-suffixes)))
1268 ada-spec-suffixes)))
1276 ada-spec-suffixes)))
1381 ;; font-lock-mode
1386 (add-hook 'font-lock-mode-hook 'ada-deactivate-properties nil t)))
4643 (define-key map "\C-k" 'ada-package-spec)
4645 (define-key map "\C-p" 'ada-procedure-spec)
4647 (define-key map "\C-f" 'ada-function-spec)
4654 (define-key map "\C-t" 'ada-task-spec)
4784 ["Package Spec" ada-package-spec t]
4785 ["Function Spec" ada-function-spec t]
4786 ["Procedure Spec" ada-procedure-spec t]
4789 ["Task Spec" ada-task-spec t]
4979 ;; unit names, and to find the other file (spec or body) from the current
4980 ;; file (body or spec).
5001 The name returned is the body if `current-buffer' is the spec,
5002 or the spec otherwise."
5004 (let ((is-spec nil)
5006 (suffixes ada-spec-suffixes)
5009 ;; Guess whether we have a spec or a body, and get the basename of the
5012 (while (and (not is-spec)
5015 (setq is-spec t
5019 (if (not is-spec)
5030 (if (not (or is-spec is-body))
5034 (if is-spec
5036 (setq suffixes ada-spec-suffixes))
5037 (setq is-spec name)
5049 (set 'is-spec other)))
5053 (setq is-spec (concat name (car suffixes)))))
5056 is-spec)))
5162 (defun ada-get-body-name (&optional spec-name)
5168 (unless spec-name (setq spec-name (buffer-file-name)))
5170 ;; Remove the spec extension. We can not simply remove the file extension,
5174 (let ((suffixes ada-spec-suffixes)
5177 (setq end (- (length spec-name) (length (car suffixes))))
5178 (if (string-equal (car suffixes) (substring spec-name end))
5179 (setq spec-name (substring spec-name 0 end)))
5187 (file-name-sans-extension spec-name)))
5192 (file-name-sans-extension spec-name)))
5198 ;; support for font-lock.el
5209 (defconst ada-font-lock-syntactic-keywords
5220 (defvar ada-font-lock-keywords
5225 (list "\\<\\(function[ \t]+return\\)\\>" '(1 font-lock-keyword-face) )
5228 (list "^[ \t]*\\(#.*\n\\)" '(1 font-lock-type-face t))
5250 '(1 font-lock-keyword-face) '(2 font-lock-function-name-face nil t))
5257 '(1 font-lock-keyword-face nil t) '(2 font-lock-type-face nil t))
5275 (1 font-lock-keyword-face) (3 font-lock-function-name-face nil t))
5281 '(1 font-lock-keyword-face)
5283 font-lock-function-name-face
5284 font-lock-type-face) nil t))
5287 ;; Note that font-lock only works on single lines, thus we can not
5291 '(1 font-lock-keyword-face) '(2 font-lock-reference-face nil t))
5295 '("<<\\(\\sw+\\)>>" 1 font-lock-reference-face)
5298 (list "\\([0-9]+#[0-9a-fA-F_]+#\\)" '(1 font-lock-constant-face t))
5301 (list "\\W\\([-+]?[0-9._]+\\)\\>" '(1 font-lock-constant-face))
5314 (let (buffer-invisibility-spec)
5349 ;; or package body from its spec.
5428 The spec must be the previously visited buffer.
5460 "Create a dummy subprogram body in package body file from spec surrounding point."
5463 (spec (match-beginning 0))
5467 (goto-char spec)
5473 (setq spec (buffer-substring spec (point)))
5490 (insert spec)
5494 (error "Not in subprogram spec"))))
5557 (autoload 'ada-function-spec "ada-stmt" nil t)
5562 (autoload 'ada-package-spec "ada-stmt" nil t)
5564 (autoload 'ada-procedure-spec "ada-stmt" nil t)
5570 (autoload 'ada-task-spec "ada-stmt" nil t)