diff options
| author | Miles Bader | 2005-06-14 23:56:26 +0000 |
|---|---|---|
| committer | Miles Bader | 2005-06-14 23:56:26 +0000 |
| commit | 63a5fd63030a0ca98c1a1ab3410cdb7721e77924 (patch) | |
| tree | cbfc77768e9275fbcce50ee5f016bae6a5a95488 | |
| parent | 33595ec6bea2d29f19b78bc7ecc830b27b6b4efb (diff) | |
| download | emacs-63a5fd63030a0ca98c1a1ab3410cdb7721e77924.tar.gz emacs-63a5fd63030a0ca98c1a1ab3410cdb7721e77924.zip | |
Revision: miles@gnu.org--gnu-2005/emacs--cvs-trunk--0--patch-415
Remove "-face" suffix from vhdl-mode faces
2005-06-14 Miles Bader <miles@gnu.org>
* lisp/progmodes/vhdl-mode.el (vhdl-prompt, vhdl-attribute, vhdl-enumvalue)
(vhdl-function, vhdl-directive, vhdl-reserved-word)
(vhdl-translate-off): Remove "-face" suffix and "font-lock-" from face
names.
(vhdl-speedbar-entity, vhdl-speedbar-architecture)
(vhdl-speedbar-configuration, vhdl-speedbar-package)
(vhdl-speedbar-library, vhdl-speedbar-instantiation)
(vhdl-speedbar-subprogram, vhdl-speedbar-entity-selected)
(vhdl-speedbar-architecture-selected)
(vhdl-speedbar-configuration-selected)
(vhdl-speedbar-package-selected)
(vhdl-speedbar-instantiation-selected): Remove "-face" suffix from face
names.
(vhdl-font-lock-keywords-2, vhdl-font-lock-keywords-5):
Use renamed faces.
(vhdl-prompt-face, vhdl-attribute-face, vhdl-enumvalue-face)
(vhdl-function-face, vhdl-directive-face, vhdl-reserved-words-face)
(vhdl-translate-off-face): Variables renamed to remove "font-lock-".
Use renamed faces.
(syntax-alist): Don't use "font-lock-" or "-face" in generated face
names.
(vhdl-font-lock-init, vhdl-ps-print-settings): Use renamed faces.
(vhdl-speedbar-insert-hierarchy, vhdl-speedbar-expand-entity)
(vhdl-speedbar-expand-package, vhdl-speedbar-update-current-unit)
(vhdl-speedbar-make-inst-line, vhdl-speedbar-make-pack-line)
(vhdl-speedbar-make-subpack-line, vhdl-speedbar-make-subprogram-line)
(vhdl-speedbar-item-info, vhdl-speedbar-check-unit): Use renamed faces.
| -rw-r--r-- | lisp/ChangeLog | 28 | ||||
| -rw-r--r-- | lisp/progmodes/vhdl-mode.el | 234 |
2 files changed, 159 insertions, 103 deletions
diff --git a/lisp/ChangeLog b/lisp/ChangeLog index b4cebfd0565..e24311ca65f 100644 --- a/lisp/ChangeLog +++ b/lisp/ChangeLog | |||
| @@ -1,5 +1,33 @@ | |||
| 1 | 2005-06-14 Miles Bader <miles@gnu.org> | 1 | 2005-06-14 Miles Bader <miles@gnu.org> |
| 2 | 2 | ||
| 3 | * progmodes/vhdl-mode.el (vhdl-prompt, vhdl-attribute, vhdl-enumvalue) | ||
| 4 | (vhdl-function, vhdl-directive, vhdl-reserved-word) | ||
| 5 | (vhdl-translate-off): Remove "-face" suffix and "font-lock-" from face | ||
| 6 | names. | ||
| 7 | (vhdl-speedbar-entity, vhdl-speedbar-architecture) | ||
| 8 | (vhdl-speedbar-configuration, vhdl-speedbar-package) | ||
| 9 | (vhdl-speedbar-library, vhdl-speedbar-instantiation) | ||
| 10 | (vhdl-speedbar-subprogram, vhdl-speedbar-entity-selected) | ||
| 11 | (vhdl-speedbar-architecture-selected) | ||
| 12 | (vhdl-speedbar-configuration-selected) | ||
| 13 | (vhdl-speedbar-package-selected) | ||
| 14 | (vhdl-speedbar-instantiation-selected): Remove "-face" suffix from face | ||
| 15 | names. | ||
| 16 | (vhdl-font-lock-keywords-2, vhdl-font-lock-keywords-5): | ||
| 17 | Use renamed faces. | ||
| 18 | (vhdl-prompt-face, vhdl-attribute-face, vhdl-enumvalue-face) | ||
| 19 | (vhdl-function-face, vhdl-directive-face, vhdl-reserved-words-face) | ||
| 20 | (vhdl-translate-off-face): Variables renamed to remove "font-lock-". | ||
| 21 | Use renamed faces. | ||
| 22 | (syntax-alist): Don't use "font-lock-" or "-face" in generated face | ||
| 23 | names. | ||
| 24 | (vhdl-font-lock-init, vhdl-ps-print-settings): Use renamed faces. | ||
| 25 | (vhdl-speedbar-insert-hierarchy, vhdl-speedbar-expand-entity) | ||
| 26 | (vhdl-speedbar-expand-package, vhdl-speedbar-update-current-unit) | ||
| 27 | (vhdl-speedbar-make-inst-line, vhdl-speedbar-make-pack-line) | ||
| 28 | (vhdl-speedbar-make-subpack-line, vhdl-speedbar-make-subprogram-line) | ||
| 29 | (vhdl-speedbar-item-info, vhdl-speedbar-check-unit): Use renamed faces. | ||
| 30 | |||
| 3 | * progmodes/sh-script.el (sh-heredoc): Remove "-face" suffix from | 31 | * progmodes/sh-script.el (sh-heredoc): Remove "-face" suffix from |
| 4 | face name. | 32 | face name. |
| 5 | (sh-heredoc-face): New backward-compatibility alias for renamed face. | 33 | (sh-heredoc-face): New backward-compatibility alias for renamed face. |
diff --git a/lisp/progmodes/vhdl-mode.el b/lisp/progmodes/vhdl-mode.el index d30b3a565a0..9885e9ae039 100644 --- a/lisp/progmodes/vhdl-mode.el +++ b/lisp/progmodes/vhdl-mode.el | |||
| @@ -1379,11 +1379,11 @@ Option `vhdl-align-groups' still applies within these blocks." | |||
| 1379 | (defcustom vhdl-highlight-keywords t | 1379 | (defcustom vhdl-highlight-keywords t |
| 1380 | "*Non-nil means highlight VHDL keywords and other standardized words. | 1380 | "*Non-nil means highlight VHDL keywords and other standardized words. |
| 1381 | The following faces are used: | 1381 | The following faces are used: |
| 1382 | `font-lock-keyword-face' : keywords | 1382 | `font-lock-keyword-face' : keywords |
| 1383 | `font-lock-type-face' : standardized types | 1383 | `font-lock-type' : standardized types |
| 1384 | `vhdl-font-lock-attribute-face': standardized attributes | 1384 | `vhdl-attribute' : standardized attributes |
| 1385 | `vhdl-font-lock-enumvalue-face': standardized enumeration values | 1385 | `vhdl-enumvalue' : standardized enumeration values |
| 1386 | `vhdl-font-lock-function-face' : standardized function and package names | 1386 | `vhdl-function' : standardized function and package names |
| 1387 | 1387 | ||
| 1388 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu | 1388 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu |
| 1389 | entry \"Fontify Buffer\")." | 1389 | entry \"Fontify Buffer\")." |
| @@ -1398,7 +1398,7 @@ The following faces are used: | |||
| 1398 | `font-lock-function-name-face' : names in declarations of units, | 1398 | `font-lock-function-name-face' : names in declarations of units, |
| 1399 | subprograms, components, as well as labels of VHDL constructs | 1399 | subprograms, components, as well as labels of VHDL constructs |
| 1400 | `font-lock-type-face' : names in type/nature declarations | 1400 | `font-lock-type-face' : names in type/nature declarations |
| 1401 | `vhdl-font-lock-attribute-face': names in attribute declarations | 1401 | `vhdl-attribute' : names in attribute declarations |
| 1402 | `font-lock-variable-name-face' : names in declarations of signals, | 1402 | `font-lock-variable-name-face' : names in declarations of signals, |
| 1403 | variables, constants, subprogram parameters, generics, and ports | 1403 | variables, constants, subprogram parameters, generics, and ports |
| 1404 | 1404 | ||
| @@ -1426,7 +1426,7 @@ NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu | |||
| 1426 | "*Non-nil means highlight forbidden words. | 1426 | "*Non-nil means highlight forbidden words. |
| 1427 | The reserved words specified in option `vhdl-forbidden-words' or having the | 1427 | The reserved words specified in option `vhdl-forbidden-words' or having the |
| 1428 | syntax specified in option `vhdl-forbidden-syntax' are highlighted in a | 1428 | syntax specified in option `vhdl-forbidden-syntax' are highlighted in a |
| 1429 | warning color (face `vhdl-font-lock-reserved-words-face') to indicate not to | 1429 | warning color (face `vhdl-reserved-word') to indicate not to |
| 1430 | use them. | 1430 | use them. |
| 1431 | 1431 | ||
| 1432 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu | 1432 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu |
| @@ -1440,7 +1440,7 @@ NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu | |||
| 1440 | (defcustom vhdl-highlight-verilog-keywords nil | 1440 | (defcustom vhdl-highlight-verilog-keywords nil |
| 1441 | "*Non-nil means highlight Verilog keywords as reserved words. | 1441 | "*Non-nil means highlight Verilog keywords as reserved words. |
| 1442 | Verilog keywords are highlighted in a warning color (face | 1442 | Verilog keywords are highlighted in a warning color (face |
| 1443 | `vhdl-font-lock-reserved-words-face') to indicate not to use them. | 1443 | `vhdl-reserved-word') to indicate not to use them. |
| 1444 | 1444 | ||
| 1445 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu | 1445 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu |
| 1446 | entry \"Fontify Buffer\")." | 1446 | entry \"Fontify Buffer\")." |
| @@ -1454,7 +1454,7 @@ NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu | |||
| 1454 | "*Non-nil means background-highlight code excluded from translation. | 1454 | "*Non-nil means background-highlight code excluded from translation. |
| 1455 | That is, all code between \"-- pragma translate_off\" and | 1455 | That is, all code between \"-- pragma translate_off\" and |
| 1456 | \"-- pragma translate_on\" is highlighted using a different background color | 1456 | \"-- pragma translate_on\" is highlighted using a different background color |
| 1457 | \(face `vhdl-font-lock-translate-off-face'). | 1457 | \(face `vhdl-translate-off'). |
| 1458 | Note: this might slow down on-the-fly fontification (and thus editing). | 1458 | Note: this might slow down on-the-fly fontification (and thus editing). |
| 1459 | 1459 | ||
| 1460 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu | 1460 | NOTE: Activate the new setting in a VHDL buffer by re-fontifying it (menu |
| @@ -1501,7 +1501,7 @@ different kinds of signals (e.g. \"Clk50\", \"Rst_n\") or objects (e.g. | |||
| 1501 | \"Signal_s\", \"Variable_v\", \"Constant_c\") by distinguishing them using | 1501 | \"Signal_s\", \"Variable_v\", \"Constant_c\") by distinguishing them using |
| 1502 | common substrings or name suffices. | 1502 | common substrings or name suffices. |
| 1503 | For each entry, a new face is generated with the specified colors and name | 1503 | For each entry, a new face is generated with the specified colors and name |
| 1504 | \"vhdl-font-lock-\" + name + \"-face\". | 1504 | \"vhdl-\" + name. |
| 1505 | 1505 | ||
| 1506 | NOTE: Activate a changed regexp in a VHDL buffer by re-fontifying it (menu | 1506 | NOTE: Activate a changed regexp in a VHDL buffer by re-fontifying it (menu |
| 1507 | entry \"Fontify Buffer\"). All other changes require restarting Emacs." | 1507 | entry \"Fontify Buffer\"). All other changes require restarting Emacs." |
| @@ -12484,7 +12484,7 @@ This does highlighting of keywords and standard identifiers.") | |||
| 12484 | (list | 12484 | (list |
| 12485 | (concat | 12485 | (concat |
| 12486 | "^\\s-*attribute\\s-+\\(\\w+\\)") | 12486 | "^\\s-*attribute\\s-+\\(\\w+\\)") |
| 12487 | 1 'vhdl-font-lock-attribute-face) | 12487 | 1 'vhdl-attribute) |
| 12488 | 12488 | ||
| 12489 | ;; highlight type/nature name in (sub)type/(sub)nature declarations | 12489 | ;; highlight type/nature name in (sub)type/(sub)nature declarations |
| 12490 | (list | 12490 | (list |
| @@ -12542,40 +12542,39 @@ This does highlighting of additional reserved words.") | |||
| 12542 | 12542 | ||
| 12543 | (defconst vhdl-font-lock-keywords-5 | 12543 | (defconst vhdl-font-lock-keywords-5 |
| 12544 | ;; background highlight translate-off regions | 12544 | ;; background highlight translate-off regions |
| 12545 | '((vhdl-match-translate-off (0 vhdl-font-lock-translate-off-face append))) | 12545 | '((vhdl-match-translate-off (0 vhdl-translate-off-face append))) |
| 12546 | "For consideration as a value of `vhdl-font-lock-keywords'. | 12546 | "For consideration as a value of `vhdl-font-lock-keywords'. |
| 12547 | This does background highlighting of translate-off regions.") | 12547 | This does background highlighting of translate-off regions.") |
| 12548 | 12548 | ||
| 12549 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 12549 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 12550 | ;; Font and color definitions | 12550 | ;; Font and color definitions |
| 12551 | 12551 | ||
| 12552 | (defvar vhdl-font-lock-prompt-face 'vhdl-font-lock-prompt-face | 12552 | (defvar vhdl-prompt-face 'vhdl-prompt |
| 12553 | "Face name to use for prompts.") | 12553 | "Face name to use for prompts.") |
| 12554 | 12554 | ||
| 12555 | (defvar vhdl-font-lock-attribute-face 'vhdl-font-lock-attribute-face | 12555 | (defvar vhdl-attribute-face 'vhdl-attribute |
| 12556 | "Face name to use for standardized attributes.") | 12556 | "Face name to use for standardized attributes.") |
| 12557 | 12557 | ||
| 12558 | (defvar vhdl-font-lock-enumvalue-face 'vhdl-font-lock-enumvalue-face | 12558 | (defvar vhdl-enumvalue-face 'vhdl-enumvalue |
| 12559 | "Face name to use for standardized enumeration values.") | 12559 | "Face name to use for standardized enumeration values.") |
| 12560 | 12560 | ||
| 12561 | (defvar vhdl-font-lock-function-face 'vhdl-font-lock-function-face | 12561 | (defvar vhdl-function-face 'vhdl-function |
| 12562 | "Face name to use for standardized functions and packages.") | 12562 | "Face name to use for standardized functions and packages.") |
| 12563 | 12563 | ||
| 12564 | (defvar vhdl-font-lock-directive-face 'vhdl-font-lock-directive-face | 12564 | (defvar vhdl-directive-face 'vhdl-directive |
| 12565 | "Face name to use for directives.") | 12565 | "Face name to use for directives.") |
| 12566 | 12566 | ||
| 12567 | (defvar vhdl-font-lock-reserved-words-face 'vhdl-font-lock-reserved-words-face | 12567 | (defvar vhdl-reserved-words-face 'vhdl-reserved-words |
| 12568 | "Face name to use for additional reserved words.") | 12568 | "Face name to use for additional reserved words.") |
| 12569 | 12569 | ||
| 12570 | (defvar vhdl-font-lock-translate-off-face 'vhdl-font-lock-translate-off-face | 12570 | (defvar vhdl-translate-off-face 'vhdl-translate-off |
| 12571 | "Face name to use for translate-off regions.") | 12571 | "Face name to use for translate-off regions.") |
| 12572 | 12572 | ||
| 12573 | ;; face names to use for words with special syntax. | 12573 | ;; face names to use for words with special syntax. |
| 12574 | (let ((syntax-alist vhdl-special-syntax-alist) | 12574 | (let ((syntax-alist vhdl-special-syntax-alist) |
| 12575 | name) | 12575 | name) |
| 12576 | (while syntax-alist | 12576 | (while syntax-alist |
| 12577 | (setq name (vhdl-function-name | 12577 | (setq name (vhdl-function-name "vhdl" (nth 0 (car syntax-alist)))) |
| 12578 | "vhdl-font-lock" (nth 0 (car syntax-alist)) "face")) | ||
| 12579 | (eval `(defvar ,name ',name | 12578 | (eval `(defvar ,name ',name |
| 12580 | ,(concat "Face name to use for " | 12579 | ,(concat "Face name to use for " |
| 12581 | (nth 0 (car syntax-alist)) "."))) | 12580 | (nth 0 (car syntax-alist)) "."))) |
| @@ -12599,7 +12598,7 @@ This does background highlighting of translate-off regions.") | |||
| 12599 | (custom-add-to-group | 12598 | (custom-add-to-group |
| 12600 | 'vhdl-highlight-faces 'font-lock-variable-name-face 'custom-face) | 12599 | 'vhdl-highlight-faces 'font-lock-variable-name-face 'custom-face) |
| 12601 | 12600 | ||
| 12602 | (defface vhdl-font-lock-prompt-face | 12601 | (defface vhdl-prompt |
| 12603 | '((((min-colors 88) (class color) (background light)) | 12602 | '((((min-colors 88) (class color) (background light)) |
| 12604 | (:foreground "Red1" :bold t)) | 12603 | (:foreground "Red1" :bold t)) |
| 12605 | (((class color) (background light)) (:foreground "Red" :bold t)) | 12604 | (((class color) (background light)) (:foreground "Red" :bold t)) |
| @@ -12608,40 +12607,50 @@ This does background highlighting of translate-off regions.") | |||
| 12608 | "Font lock mode face used to highlight prompts." | 12607 | "Font lock mode face used to highlight prompts." |
| 12609 | :group 'vhdl-highlight-faces | 12608 | :group 'vhdl-highlight-faces |
| 12610 | :group 'font-lock-highlighting-faces) | 12609 | :group 'font-lock-highlighting-faces) |
| 12610 | ;; backward-compatibility alias | ||
| 12611 | (put 'vhdl-font-lock-prompt-face 'face-alias 'vhdl-prompt) | ||
| 12611 | 12612 | ||
| 12612 | (defface vhdl-font-lock-attribute-face | 12613 | (defface vhdl-attribute |
| 12613 | '((((class color) (background light)) (:foreground "Orchid")) | 12614 | '((((class color) (background light)) (:foreground "Orchid")) |
| 12614 | (((class color) (background dark)) (:foreground "LightSteelBlue")) | 12615 | (((class color) (background dark)) (:foreground "LightSteelBlue")) |
| 12615 | (t (:italic t :bold t))) | 12616 | (t (:italic t :bold t))) |
| 12616 | "Font lock mode face used to highlight standardized attributes." | 12617 | "Font lock mode face used to highlight standardized attributes." |
| 12617 | :group 'vhdl-highlight-faces | 12618 | :group 'vhdl-highlight-faces |
| 12618 | :group 'font-lock-highlighting-faces) | 12619 | :group 'font-lock-highlighting-faces) |
| 12620 | ;; backward-compatibility alias | ||
| 12621 | (put 'vhdl-font-lock-attribute-face 'face-alias 'vhdl-attribute) | ||
| 12619 | 12622 | ||
| 12620 | (defface vhdl-font-lock-enumvalue-face | 12623 | (defface vhdl-enumvalue |
| 12621 | '((((class color) (background light)) (:foreground "SaddleBrown")) | 12624 | '((((class color) (background light)) (:foreground "SaddleBrown")) |
| 12622 | (((class color) (background dark)) (:foreground "BurlyWood")) | 12625 | (((class color) (background dark)) (:foreground "BurlyWood")) |
| 12623 | (t (:italic t :bold t))) | 12626 | (t (:italic t :bold t))) |
| 12624 | "Font lock mode face used to highlight standardized enumeration values." | 12627 | "Font lock mode face used to highlight standardized enumeration values." |
| 12625 | :group 'vhdl-highlight-faces | 12628 | :group 'vhdl-highlight-faces |
| 12626 | :group 'font-lock-highlighting-faces) | 12629 | :group 'font-lock-highlighting-faces) |
| 12630 | ;; backward-compatibility alias | ||
| 12631 | (put 'vhdl-font-lock-enumvalue-face 'face-alias 'vhdl-enumvalue) | ||
| 12627 | 12632 | ||
| 12628 | (defface vhdl-font-lock-function-face | 12633 | (defface vhdl-function |
| 12629 | '((((class color) (background light)) (:foreground "Cyan4")) | 12634 | '((((class color) (background light)) (:foreground "Cyan4")) |
| 12630 | (((class color) (background dark)) (:foreground "Orchid1")) | 12635 | (((class color) (background dark)) (:foreground "Orchid1")) |
| 12631 | (t (:italic t :bold t))) | 12636 | (t (:italic t :bold t))) |
| 12632 | "Font lock mode face used to highlight standardized functions and packages." | 12637 | "Font lock mode face used to highlight standardized functions and packages." |
| 12633 | :group 'vhdl-highlight-faces | 12638 | :group 'vhdl-highlight-faces |
| 12634 | :group 'font-lock-highlighting-faces) | 12639 | :group 'font-lock-highlighting-faces) |
| 12640 | ;; backward-compatibility alias | ||
| 12641 | (put 'vhdl-font-lock-function-face 'face-alias 'vhdl-function) | ||
| 12635 | 12642 | ||
| 12636 | (defface vhdl-font-lock-directive-face | 12643 | (defface vhdl-directive |
| 12637 | '((((class color) (background light)) (:foreground "CadetBlue")) | 12644 | '((((class color) (background light)) (:foreground "CadetBlue")) |
| 12638 | (((class color) (background dark)) (:foreground "Aquamarine")) | 12645 | (((class color) (background dark)) (:foreground "Aquamarine")) |
| 12639 | (t (:italic t :bold t))) | 12646 | (t (:italic t :bold t))) |
| 12640 | "Font lock mode face used to highlight directives." | 12647 | "Font lock mode face used to highlight directives." |
| 12641 | :group 'vhdl-highlight-faces | 12648 | :group 'vhdl-highlight-faces |
| 12642 | :group 'font-lock-highlighting-faces) | 12649 | :group 'font-lock-highlighting-faces) |
| 12650 | ;; backward-compatibility alias | ||
| 12651 | (put 'vhdl-font-lock-directive-face 'face-alias 'vhdl-directive) | ||
| 12643 | 12652 | ||
| 12644 | (defface vhdl-font-lock-reserved-words-face | 12653 | (defface vhdl-reserved-word |
| 12645 | '((((class color) (background light)) (:foreground "Orange" :bold t)) | 12654 | '((((class color) (background light)) (:foreground "Orange" :bold t)) |
| 12646 | (((min-colors 88) (class color) (background dark)) | 12655 | (((min-colors 88) (class color) (background dark)) |
| 12647 | (:foreground "Yellow1" :bold t)) | 12656 | (:foreground "Yellow1" :bold t)) |
| @@ -12650,20 +12659,23 @@ This does background highlighting of translate-off regions.") | |||
| 12650 | "Font lock mode face used to highlight additional reserved words." | 12659 | "Font lock mode face used to highlight additional reserved words." |
| 12651 | :group 'vhdl-highlight-faces | 12660 | :group 'vhdl-highlight-faces |
| 12652 | :group 'font-lock-highlighting-faces) | 12661 | :group 'font-lock-highlighting-faces) |
| 12662 | ;; backward-compatibility alias | ||
| 12663 | (put 'vhdl-font-lock-reserved-words-face 'face-alias 'vhdl-reserved-word) | ||
| 12653 | 12664 | ||
| 12654 | (defface vhdl-font-lock-translate-off-face | 12665 | (defface vhdl-translate-off |
| 12655 | '((((class color) (background light)) (:background "LightGray")) | 12666 | '((((class color) (background light)) (:background "LightGray")) |
| 12656 | (((class color) (background dark)) (:background "DimGray")) | 12667 | (((class color) (background dark)) (:background "DimGray")) |
| 12657 | (t ())) | 12668 | (t ())) |
| 12658 | "Font lock mode face used to background highlight translate-off regions." | 12669 | "Font lock mode face used to background highlight translate-off regions." |
| 12659 | :group 'vhdl-highlight-faces | 12670 | :group 'vhdl-highlight-faces |
| 12660 | :group 'font-lock-highlighting-faces) | 12671 | :group 'font-lock-highlighting-faces) |
| 12672 | ;; backward-compatibility alias | ||
| 12673 | (put 'vhdl-font-lock-translate-off-face 'face-alias 'vhdl-translate-off) | ||
| 12661 | 12674 | ||
| 12662 | ;; font lock mode faces used to highlight words with special syntax. | 12675 | ;; font lock mode faces used to highlight words with special syntax. |
| 12663 | (let ((syntax-alist vhdl-special-syntax-alist)) | 12676 | (let ((syntax-alist vhdl-special-syntax-alist)) |
| 12664 | (while syntax-alist | 12677 | (while syntax-alist |
| 12665 | (eval `(defface ,(vhdl-function-name | 12678 | (eval `(defface ,(vhdl-function-name "vhdl" (caar syntax-alist)) |
| 12666 | "vhdl-font-lock" (caar syntax-alist) "face") | ||
| 12667 | '((((class color) (background light)) | 12679 | '((((class color) (background light)) |
| 12668 | (:foreground ,(nth 2 (car syntax-alist)))) | 12680 | (:foreground ,(nth 2 (car syntax-alist)))) |
| 12669 | (((class color) (background dark)) | 12681 | (((class color) (background dark)) |
| @@ -12684,20 +12696,19 @@ This does background highlighting of translate-off regions.") | |||
| 12684 | (setq vhdl-font-lock-keywords-0 | 12696 | (setq vhdl-font-lock-keywords-0 |
| 12685 | (list (list (concat "\\(^\\|[ \t(.']\\)\\(<" | 12697 | (list (list (concat "\\(^\\|[ \t(.']\\)\\(<" |
| 12686 | vhdl-template-prompt-syntax ">\\)") | 12698 | vhdl-template-prompt-syntax ">\\)") |
| 12687 | 2 'vhdl-font-lock-prompt-face t) | 12699 | 2 'vhdl-prompt t) |
| 12688 | (list (concat "--\\s-*" | 12700 | (list (concat "--\\s-*" |
| 12689 | vhdl-directive-keywords-regexp "\\s-+\\(.*\\)$") | 12701 | vhdl-directive-keywords-regexp "\\s-+\\(.*\\)$") |
| 12690 | 2 'vhdl-font-lock-directive-face t))) | 12702 | 2 'vhdl-directive t))) |
| 12691 | ;; highlight keywords and standardized types, attributes, enumeration | 12703 | ;; highlight keywords and standardized types, attributes, enumeration |
| 12692 | ;; values, and subprograms | 12704 | ;; values, and subprograms |
| 12693 | (setq vhdl-font-lock-keywords-1 | 12705 | (setq vhdl-font-lock-keywords-1 |
| 12694 | (list | 12706 | (list |
| 12695 | (list (concat "'" vhdl-attributes-regexp) | 12707 | (list (concat "'" vhdl-attributes-regexp) 1 'vhdl-attribute) |
| 12696 | 1 'vhdl-font-lock-attribute-face) | ||
| 12697 | (list vhdl-types-regexp 1 'font-lock-type-face) | 12708 | (list vhdl-types-regexp 1 'font-lock-type-face) |
| 12698 | (list vhdl-functions-regexp 1 'vhdl-font-lock-function-face) | 12709 | (list vhdl-functions-regexp 1 'vhdl-function) |
| 12699 | (list vhdl-packages-regexp 1 'vhdl-font-lock-function-face) | 12710 | (list vhdl-packages-regexp 1 'vhdl-function) |
| 12700 | (list vhdl-enum-values-regexp 1 'vhdl-font-lock-enumvalue-face) | 12711 | (list vhdl-enum-values-regexp 1 'vhdl-enumvalue) |
| 12701 | (list vhdl-keywords-regexp 1 'font-lock-keyword-face))) | 12712 | (list vhdl-keywords-regexp 1 'font-lock-keyword-face))) |
| 12702 | ;; highlight words with special syntax. | 12713 | ;; highlight words with special syntax. |
| 12703 | (setq vhdl-font-lock-keywords-3 | 12714 | (setq vhdl-font-lock-keywords-3 |
| @@ -12708,14 +12719,13 @@ This does background highlighting of translate-off regions.") | |||
| 12708 | (cons | 12719 | (cons |
| 12709 | (cons (concat "\\<\\(" (nth 1 (car syntax-alist)) "\\)\\>") | 12720 | (cons (concat "\\<\\(" (nth 1 (car syntax-alist)) "\\)\\>") |
| 12710 | (vhdl-function-name | 12721 | (vhdl-function-name |
| 12711 | "vhdl-font-lock" (nth 0 (car syntax-alist)) "face")) | 12722 | "vhdl" (nth 0 (car syntax-alist)))) |
| 12712 | keywords)) | 12723 | keywords)) |
| 12713 | (setq syntax-alist (cdr syntax-alist))) | 12724 | (setq syntax-alist (cdr syntax-alist))) |
| 12714 | keywords)) | 12725 | keywords)) |
| 12715 | ;; highlight additional reserved words | 12726 | ;; highlight additional reserved words |
| 12716 | (setq vhdl-font-lock-keywords-4 | 12727 | (setq vhdl-font-lock-keywords-4 |
| 12717 | (list (list vhdl-reserved-words-regexp 1 | 12728 | (list (list vhdl-reserved-words-regexp 1 'vhdl-reserved-word))) |
| 12718 | 'vhdl-font-lock-reserved-words-face))) | ||
| 12719 | ;; highlight everything together | 12729 | ;; highlight everything together |
| 12720 | (setq vhdl-font-lock-keywords | 12730 | (setq vhdl-font-lock-keywords |
| 12721 | (append | 12731 | (append |
| @@ -12753,18 +12763,12 @@ This does background highlighting of translate-off regions.") | |||
| 12753 | (unless (or (not vhdl-print-customize-faces) | 12763 | (unless (or (not vhdl-print-customize-faces) |
| 12754 | ps-print-color-p) | 12764 | ps-print-color-p) |
| 12755 | (set (make-local-variable 'ps-bold-faces) | 12765 | (set (make-local-variable 'ps-bold-faces) |
| 12756 | '(font-lock-keyword-face | 12766 | '(font-lock-keyword-face font-lock-type-face |
| 12757 | font-lock-type-face | 12767 | vhdl-attribute vhdl-enumvalue vhdl-directive)) |
| 12758 | vhdl-font-lock-attribute-face | ||
| 12759 | vhdl-font-lock-enumvalue-face | ||
| 12760 | vhdl-font-lock-directive-face)) | ||
| 12761 | (set (make-local-variable 'ps-italic-faces) | 12768 | (set (make-local-variable 'ps-italic-faces) |
| 12762 | '(font-lock-comment-face | 12769 | '(font-lock-comment-face |
| 12763 | font-lock-function-name-face | 12770 | font-lock-function-name-face font-lock-type-face |
| 12764 | font-lock-type-face | 12771 | vhdl-attribute vhdl-enumvalue vhdl-directive)) |
| 12765 | vhdl-font-lock-attribute-face | ||
| 12766 | vhdl-font-lock-enumvalue-face | ||
| 12767 | vhdl-font-lock-directive-face)) | ||
| 12768 | (set (make-local-variable 'ps-underlined-faces) | 12772 | (set (make-local-variable 'ps-underlined-faces) |
| 12769 | '(font-lock-string-face)) | 12773 | '(font-lock-string-face)) |
| 12770 | (setq ps-always-build-face-reference t)) | 12774 | (setq ps-always-build-face-reference t)) |
| @@ -13973,7 +13977,7 @@ otherwise use cached data." | |||
| 13973 | 'bracket ?+ 'vhdl-speedbar-expand-entity (nth 0 ent-entry) | 13977 | 'bracket ?+ 'vhdl-speedbar-expand-entity (nth 0 ent-entry) |
| 13974 | (nth 1 ent-entry) 'vhdl-speedbar-find-file | 13978 | (nth 1 ent-entry) 'vhdl-speedbar-find-file |
| 13975 | (cons (nth 2 ent-entry) (nth 3 ent-entry)) | 13979 | (cons (nth 2 ent-entry) (nth 3 ent-entry)) |
| 13976 | 'vhdl-speedbar-entity-face depth) | 13980 | 'vhdl-speedbar-entity depth) |
| 13977 | (unless (nth 2 ent-entry) | 13981 | (unless (nth 2 ent-entry) |
| 13978 | (end-of-line 0) (insert "!") (forward-char 1)) | 13982 | (end-of-line 0) (insert "!") (forward-char 1)) |
| 13979 | (unless (member (nth 0 ent-entry) ent-inst-list) | 13983 | (unless (member (nth 0 ent-entry) ent-inst-list) |
| @@ -13987,7 +13991,7 @@ otherwise use cached data." | |||
| 13987 | 'bracket ?+ 'vhdl-speedbar-expand-config (nth 0 conf-entry) | 13991 | 'bracket ?+ 'vhdl-speedbar-expand-config (nth 0 conf-entry) |
| 13988 | (nth 1 conf-entry) 'vhdl-speedbar-find-file | 13992 | (nth 1 conf-entry) 'vhdl-speedbar-find-file |
| 13989 | (cons (nth 2 conf-entry) (nth 3 conf-entry)) | 13993 | (cons (nth 2 conf-entry) (nth 3 conf-entry)) |
| 13990 | 'vhdl-speedbar-configuration-face depth) | 13994 | 'vhdl-speedbar-configuration depth) |
| 13991 | (setq conf-alist (cdr conf-alist))) | 13995 | (setq conf-alist (cdr conf-alist))) |
| 13992 | ;; insert packages | 13996 | ;; insert packages |
| 13993 | (when pack-alist (vhdl-speedbar-make-title-line "Packages:" depth)) | 13997 | (when pack-alist (vhdl-speedbar-make-title-line "Packages:" depth)) |
| @@ -14178,7 +14182,7 @@ otherwise use cached data." | |||
| 14178 | (cons token (nth 0 arch-entry)) | 14182 | (cons token (nth 0 arch-entry)) |
| 14179 | (nth 1 arch-entry) 'vhdl-speedbar-find-file | 14183 | (nth 1 arch-entry) 'vhdl-speedbar-find-file |
| 14180 | (cons (nth 2 arch-entry) (nth 3 arch-entry)) | 14184 | (cons (nth 2 arch-entry) (nth 3 arch-entry)) |
| 14181 | 'vhdl-speedbar-architecture-face (1+ indent)) | 14185 | 'vhdl-speedbar-architecture (1+ indent)) |
| 14182 | (setq arch-alist (cdr arch-alist))) | 14186 | (setq arch-alist (cdr arch-alist))) |
| 14183 | ;; insert instantiations | 14187 | ;; insert instantiations |
| 14184 | (when inst-alist | 14188 | (when inst-alist |
| @@ -14361,7 +14365,7 @@ otherwise use cached data." | |||
| 14361 | (cons token (nth 0 comp-entry)) | 14365 | (cons token (nth 0 comp-entry)) |
| 14362 | (nth 1 comp-entry) 'vhdl-speedbar-find-file | 14366 | (nth 1 comp-entry) 'vhdl-speedbar-find-file |
| 14363 | (cons (nth 2 comp-entry) (nth 3 comp-entry)) | 14367 | (cons (nth 2 comp-entry) (nth 3 comp-entry)) |
| 14364 | 'vhdl-speedbar-entity-face (1+ indent)) | 14368 | 'vhdl-speedbar-entity (1+ indent)) |
| 14365 | (setq comp-alist (cdr comp-alist))) | 14369 | (setq comp-alist (cdr comp-alist))) |
| 14366 | ;; insert subprograms | 14370 | ;; insert subprograms |
| 14367 | (when func-alist | 14371 | (when func-alist |
| @@ -14477,43 +14481,43 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14477 | (let* ((file-entry (aget file-alist speedbar-last-selected-file t))) | 14481 | (let* ((file-entry (aget file-alist speedbar-last-selected-file t))) |
| 14478 | (vhdl-speedbar-update-units | 14482 | (vhdl-speedbar-update-units |
| 14479 | "\\[.\\] " (nth 0 file-entry) | 14483 | "\\[.\\] " (nth 0 file-entry) |
| 14480 | speedbar-last-selected-file 'vhdl-speedbar-entity-face) | 14484 | speedbar-last-selected-file 'vhdl-speedbar-entity) |
| 14481 | (vhdl-speedbar-update-units | 14485 | (vhdl-speedbar-update-units |
| 14482 | "{.} " (nth 1 file-entry) | 14486 | "{.} " (nth 1 file-entry) |
| 14483 | speedbar-last-selected-file 'vhdl-speedbar-architecture-face) | 14487 | speedbar-last-selected-file 'vhdl-speedbar-architecture) |
| 14484 | (vhdl-speedbar-update-units | 14488 | (vhdl-speedbar-update-units |
| 14485 | "\\[.\\] " (nth 3 file-entry) | 14489 | "\\[.\\] " (nth 3 file-entry) |
| 14486 | speedbar-last-selected-file 'vhdl-speedbar-configuration-face) | 14490 | speedbar-last-selected-file 'vhdl-speedbar-configuration) |
| 14487 | (vhdl-speedbar-update-units | 14491 | (vhdl-speedbar-update-units |
| 14488 | "[]>] " (nth 4 file-entry) | 14492 | "[]>] " (nth 4 file-entry) |
| 14489 | speedbar-last-selected-file 'vhdl-speedbar-package-face) | 14493 | speedbar-last-selected-file 'vhdl-speedbar-package) |
| 14490 | (vhdl-speedbar-update-units | 14494 | (vhdl-speedbar-update-units |
| 14491 | "\\[.\\].+(" '("body") | 14495 | "\\[.\\].+(" '("body") |
| 14492 | speedbar-last-selected-file 'vhdl-speedbar-package-face) | 14496 | speedbar-last-selected-file 'vhdl-speedbar-package) |
| 14493 | (vhdl-speedbar-update-units | 14497 | (vhdl-speedbar-update-units |
| 14494 | "> " (nth 6 file-entry) | 14498 | "> " (nth 6 file-entry) |
| 14495 | speedbar-last-selected-file 'vhdl-speedbar-instantiation-face)) | 14499 | speedbar-last-selected-file 'vhdl-speedbar-instantiation)) |
| 14496 | ;; highlight current units | 14500 | ;; highlight current units |
| 14497 | (let* ((file-entry (aget file-alist file-name t))) | 14501 | (let* ((file-entry (aget file-alist file-name t))) |
| 14498 | (setq | 14502 | (setq |
| 14499 | pos (vhdl-speedbar-update-units | 14503 | pos (vhdl-speedbar-update-units |
| 14500 | "\\[.\\] " (nth 0 file-entry) | 14504 | "\\[.\\] " (nth 0 file-entry) |
| 14501 | file-name 'vhdl-speedbar-entity-selected-face pos) | 14505 | file-name 'vhdl-speedbar-entity-selected pos) |
| 14502 | pos (vhdl-speedbar-update-units | 14506 | pos (vhdl-speedbar-update-units |
| 14503 | "{.} " (nth 1 file-entry) | 14507 | "{.} " (nth 1 file-entry) |
| 14504 | file-name 'vhdl-speedbar-architecture-selected-face pos) | 14508 | file-name 'vhdl-speedbar-architecture-selected pos) |
| 14505 | pos (vhdl-speedbar-update-units | 14509 | pos (vhdl-speedbar-update-units |
| 14506 | "\\[.\\] " (nth 3 file-entry) | 14510 | "\\[.\\] " (nth 3 file-entry) |
| 14507 | file-name 'vhdl-speedbar-configuration-selected-face pos) | 14511 | file-name 'vhdl-speedbar-configuration-selected pos) |
| 14508 | pos (vhdl-speedbar-update-units | 14512 | pos (vhdl-speedbar-update-units |
| 14509 | "[]>] " (nth 4 file-entry) | 14513 | "[]>] " (nth 4 file-entry) |
| 14510 | file-name 'vhdl-speedbar-package-selected-face pos) | 14514 | file-name 'vhdl-speedbar-package-selected pos) |
| 14511 | pos (vhdl-speedbar-update-units | 14515 | pos (vhdl-speedbar-update-units |
| 14512 | "\\[.\\].+(" '("body") | 14516 | "\\[.\\].+(" '("body") |
| 14513 | file-name 'vhdl-speedbar-package-selected-face pos) | 14517 | file-name 'vhdl-speedbar-package-selected pos) |
| 14514 | pos (vhdl-speedbar-update-units | 14518 | pos (vhdl-speedbar-update-units |
| 14515 | "> " (nth 6 file-entry) | 14519 | "> " (nth 6 file-entry) |
| 14516 | file-name 'vhdl-speedbar-instantiation-selected-face pos)))))) | 14520 | file-name 'vhdl-speedbar-instantiation-selected pos)))))) |
| 14517 | ;; move speedbar so the first highlighted unit is visible | 14521 | ;; move speedbar so the first highlighted unit is visible |
| 14518 | (when (and pos (not no-position)) | 14522 | (when (and pos (not no-position)) |
| 14519 | (goto-char pos) | 14523 | (goto-char pos) |
| @@ -14564,21 +14568,21 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14564 | (insert "(top)") | 14568 | (insert "(top)") |
| 14565 | (insert inst-name) | 14569 | (insert inst-name) |
| 14566 | (speedbar-make-button | 14570 | (speedbar-make-button |
| 14567 | start (point) 'vhdl-speedbar-instantiation-face 'speedbar-highlight-face | 14571 | start (point) 'vhdl-speedbar-instantiation 'speedbar-highlight-face |
| 14568 | 'vhdl-speedbar-find-file inst-file-marker)) | 14572 | 'vhdl-speedbar-find-file inst-file-marker)) |
| 14569 | (insert delimiter) | 14573 | (insert delimiter) |
| 14570 | (when ent-name | 14574 | (when ent-name |
| 14571 | (setq start (point)) | 14575 | (setq start (point)) |
| 14572 | (insert ent-name) | 14576 | (insert ent-name) |
| 14573 | (speedbar-make-button | 14577 | (speedbar-make-button |
| 14574 | start (point) 'vhdl-speedbar-entity-face 'speedbar-highlight-face | 14578 | start (point) 'vhdl-speedbar-entity 'speedbar-highlight-face |
| 14575 | 'vhdl-speedbar-find-file ent-file-marker) | 14579 | 'vhdl-speedbar-find-file ent-file-marker) |
| 14576 | (when arch-name | 14580 | (when arch-name |
| 14577 | (insert " (") | 14581 | (insert " (") |
| 14578 | (setq start (point)) | 14582 | (setq start (point)) |
| 14579 | (insert arch-name) | 14583 | (insert arch-name) |
| 14580 | (speedbar-make-button | 14584 | (speedbar-make-button |
| 14581 | start (point) 'vhdl-speedbar-architecture-face 'speedbar-highlight-face | 14585 | start (point) 'vhdl-speedbar-architecture 'speedbar-highlight-face |
| 14582 | 'vhdl-speedbar-find-file arch-file-marker) | 14586 | 'vhdl-speedbar-find-file arch-file-marker) |
| 14583 | (insert ")")) | 14587 | (insert ")")) |
| 14584 | (when conf-name | 14588 | (when conf-name |
| @@ -14586,14 +14590,14 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14586 | (setq start (point)) | 14590 | (setq start (point)) |
| 14587 | (insert conf-name) | 14591 | (insert conf-name) |
| 14588 | (speedbar-make-button | 14592 | (speedbar-make-button |
| 14589 | start (point) 'vhdl-speedbar-configuration-face 'speedbar-highlight-face | 14593 | start (point) 'vhdl-speedbar-configuration 'speedbar-highlight-face |
| 14590 | 'vhdl-speedbar-find-file conf-file-marker) | 14594 | 'vhdl-speedbar-find-file conf-file-marker) |
| 14591 | (insert ")"))) | 14595 | (insert ")"))) |
| 14592 | (when (and lib-name (not (equal lib-name (downcase (vhdl-work-library))))) | 14596 | (when (and lib-name (not (equal lib-name (downcase (vhdl-work-library))))) |
| 14593 | (setq start (point)) | 14597 | (setq start (point)) |
| 14594 | (insert " (" lib-name ")") | 14598 | (insert " (" lib-name ")") |
| 14595 | (put-text-property (+ 2 start) (1- (point)) 'face | 14599 | (put-text-property (+ 2 start) (1- (point)) 'face |
| 14596 | 'vhdl-speedbar-library-face)) | 14600 | 'vhdl-speedbar-library)) |
| 14597 | (insert-char ?\n 1) | 14601 | (insert-char ?\n 1) |
| 14598 | (put-text-property visible-start (point) 'invisible nil))) | 14602 | (put-text-property visible-start (point) 'invisible nil))) |
| 14599 | 14603 | ||
| @@ -14617,7 +14621,7 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14617 | (setq start (point)) | 14621 | (setq start (point)) |
| 14618 | (insert pack-name) | 14622 | (insert pack-name) |
| 14619 | (speedbar-make-button | 14623 | (speedbar-make-button |
| 14620 | start (point) 'vhdl-speedbar-package-face 'speedbar-highlight-face | 14624 | start (point) 'vhdl-speedbar-package 'speedbar-highlight-face |
| 14621 | 'vhdl-speedbar-find-file pack-file-marker) | 14625 | 'vhdl-speedbar-find-file pack-file-marker) |
| 14622 | (unless (car pack-file-marker) | 14626 | (unless (car pack-file-marker) |
| 14623 | (insert "!")) | 14627 | (insert "!")) |
| @@ -14626,7 +14630,7 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14626 | (setq start (point)) | 14630 | (setq start (point)) |
| 14627 | (insert "body") | 14631 | (insert "body") |
| 14628 | (speedbar-make-button | 14632 | (speedbar-make-button |
| 14629 | start (point) 'vhdl-speedbar-package-face 'speedbar-highlight-face | 14633 | start (point) 'vhdl-speedbar-package 'speedbar-highlight-face |
| 14630 | 'vhdl-speedbar-find-file body-file-marker) | 14634 | 'vhdl-speedbar-find-file body-file-marker) |
| 14631 | (insert ")")) | 14635 | (insert ")")) |
| 14632 | (insert-char ?\n 1) | 14636 | (insert-char ?\n 1) |
| @@ -14650,12 +14654,12 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14650 | (setq start (point)) | 14654 | (setq start (point)) |
| 14651 | (insert pack-name) | 14655 | (insert pack-name) |
| 14652 | (speedbar-make-button | 14656 | (speedbar-make-button |
| 14653 | start (point) 'vhdl-speedbar-package-face 'speedbar-highlight-face | 14657 | start (point) 'vhdl-speedbar-package 'speedbar-highlight-face |
| 14654 | 'vhdl-speedbar-find-file pack-file-marker) | 14658 | 'vhdl-speedbar-find-file pack-file-marker) |
| 14655 | (setq start (point)) | 14659 | (setq start (point)) |
| 14656 | (insert " (" lib-name ")") | 14660 | (insert " (" lib-name ")") |
| 14657 | (put-text-property (+ 2 start) (1- (point)) 'face | 14661 | (put-text-property (+ 2 start) (1- (point)) 'face |
| 14658 | 'vhdl-speedbar-library-face) | 14662 | 'vhdl-speedbar-library) |
| 14659 | (insert-char ?\n 1) | 14663 | (insert-char ?\n 1) |
| 14660 | (put-text-property visible-start (point) 'invisible nil))) | 14664 | (put-text-property visible-start (point) 'invisible nil))) |
| 14661 | 14665 | ||
| @@ -14678,14 +14682,14 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14678 | (setq start (point)) | 14682 | (setq start (point)) |
| 14679 | (insert func-name) | 14683 | (insert func-name) |
| 14680 | (speedbar-make-button | 14684 | (speedbar-make-button |
| 14681 | start (point) 'vhdl-speedbar-subprogram-face 'speedbar-highlight-face | 14685 | start (point) 'vhdl-speedbar-subprogram 'speedbar-highlight-face |
| 14682 | 'vhdl-speedbar-find-file func-file-marker) | 14686 | 'vhdl-speedbar-find-file func-file-marker) |
| 14683 | (when (car func-body-file-marker) | 14687 | (when (car func-body-file-marker) |
| 14684 | (insert " (") | 14688 | (insert " (") |
| 14685 | (setq start (point)) | 14689 | (setq start (point)) |
| 14686 | (insert "body") | 14690 | (insert "body") |
| 14687 | (speedbar-make-button | 14691 | (speedbar-make-button |
| 14688 | start (point) 'vhdl-speedbar-subprogram-face 'speedbar-highlight-face | 14692 | start (point) 'vhdl-speedbar-subprogram 'speedbar-highlight-face |
| 14689 | 'vhdl-speedbar-find-file func-body-file-marker) | 14693 | 'vhdl-speedbar-find-file func-body-file-marker) |
| 14690 | (insert ")")) | 14694 | (insert ")")) |
| 14691 | (insert-char ?\n 1) | 14695 | (insert-char ?\n 1) |
| @@ -14773,22 +14777,22 @@ NO-POSITION non-nil means do not re-position cursor." | |||
| 14773 | (message | 14777 | (message |
| 14774 | "%s \"%s\" in \"%s\"" | 14778 | "%s \"%s\" in \"%s\"" |
| 14775 | ;; design unit kind | 14779 | ;; design unit kind |
| 14776 | (cond ((or (eq face 'vhdl-speedbar-entity-face) | 14780 | (cond ((or (eq face 'vhdl-speedbar-entity) |
| 14777 | (eq face 'vhdl-speedbar-entity-selected-face)) | 14781 | (eq face 'vhdl-speedbar-entity-selected)) |
| 14778 | (if (equal (match-string 2) ">") "Component" "Entity")) | 14782 | (if (equal (match-string 2) ">") "Component" "Entity")) |
| 14779 | ((or (eq face 'vhdl-speedbar-architecture-face) | 14783 | ((or (eq face 'vhdl-speedbar-architecture) |
| 14780 | (eq face 'vhdl-speedbar-architecture-selected-face)) | 14784 | (eq face 'vhdl-speedbar-architecture-selected)) |
| 14781 | "Architecture") | 14785 | "Architecture") |
| 14782 | ((or (eq face 'vhdl-speedbar-configuration-face) | 14786 | ((or (eq face 'vhdl-speedbar-configuration) |
| 14783 | (eq face 'vhdl-speedbar-configuration-selected-face)) | 14787 | (eq face 'vhdl-speedbar-configuration-selected)) |
| 14784 | "Configuration") | 14788 | "Configuration") |
| 14785 | ((or (eq face 'vhdl-speedbar-package-face) | 14789 | ((or (eq face 'vhdl-speedbar-package) |
| 14786 | (eq face 'vhdl-speedbar-package-selected-face)) | 14790 | (eq face 'vhdl-speedbar-package-selected)) |
| 14787 | "Package") | 14791 | "Package") |
| 14788 | ((or (eq face 'vhdl-speedbar-instantiation-face) | 14792 | ((or (eq face 'vhdl-speedbar-instantiation) |
| 14789 | (eq face 'vhdl-speedbar-instantiation-selected-face)) | 14793 | (eq face 'vhdl-speedbar-instantiation-selected)) |
| 14790 | "Instantiation") | 14794 | "Instantiation") |
| 14791 | ((eq face 'vhdl-speedbar-subprogram-face) | 14795 | ((eq face 'vhdl-speedbar-subprogram) |
| 14792 | "Subprogram") | 14796 | "Subprogram") |
| 14793 | (t "")) | 14797 | (t "")) |
| 14794 | ;; design unit name | 14798 | ;; design unit name |
| @@ -14964,11 +14968,11 @@ expansion function)." | |||
| 14964 | (speedbar-position-cursor-on-line) | 14968 | (speedbar-position-cursor-on-line) |
| 14965 | (cond ((eq design-unit 'entity) | 14969 | (cond ((eq design-unit 'entity) |
| 14966 | (memq (get-text-property (match-end 0) 'face) | 14970 | (memq (get-text-property (match-end 0) 'face) |
| 14967 | '(vhdl-speedbar-entity-face | 14971 | '(vhdl-speedbar-entity |
| 14968 | vhdl-speedbar-entity-selected-face))) | 14972 | vhdl-speedbar-entity-selected))) |
| 14969 | ((eq design-unit 'subprogram) | 14973 | ((eq design-unit 'subprogram) |
| 14970 | (eq (get-text-property (match-end 0) 'face) | 14974 | (eq (get-text-property (match-end 0) 'face) |
| 14971 | 'vhdl-speedbar-subprogram-face)) | 14975 | 'vhdl-speedbar-subprogram)) |
| 14972 | (t nil)))) | 14976 | (t nil)))) |
| 14973 | 14977 | ||
| 14974 | (defun vhdl-speedbar-set-depth (depth) | 14978 | (defun vhdl-speedbar-set-depth (depth) |
| @@ -14979,82 +14983,106 @@ expansion function)." | |||
| 14979 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 14983 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 14980 | ;; Fontification | 14984 | ;; Fontification |
| 14981 | 14985 | ||
| 14982 | (defface vhdl-speedbar-entity-face | 14986 | (defface vhdl-speedbar-entity |
| 14983 | '((((class color) (background light)) (:foreground "ForestGreen")) | 14987 | '((((class color) (background light)) (:foreground "ForestGreen")) |
| 14984 | (((class color) (background dark)) (:foreground "PaleGreen"))) | 14988 | (((class color) (background dark)) (:foreground "PaleGreen"))) |
| 14985 | "Face used for displaying entity names." | 14989 | "Face used for displaying entity names." |
| 14986 | :group 'speedbar-faces) | 14990 | :group 'speedbar-faces) |
| 14991 | ;; backward-compatibility alias | ||
| 14992 | (put 'vhdl-speedbar-entity-face 'face-alias 'vhdl-speedbar-entity) | ||
| 14987 | 14993 | ||
| 14988 | (defface vhdl-speedbar-architecture-face | 14994 | (defface vhdl-speedbar-architecture |
| 14989 | '((((min-colors 88) (class color) (background light)) (:foreground "Blue1")) | 14995 | '((((min-colors 88) (class color) (background light)) (:foreground "Blue1")) |
| 14990 | (((class color) (background light)) (:foreground "Blue")) | 14996 | (((class color) (background light)) (:foreground "Blue")) |
| 14991 | (((class color) (background dark)) (:foreground "LightSkyBlue"))) | 14997 | (((class color) (background dark)) (:foreground "LightSkyBlue"))) |
| 14992 | "Face used for displaying architecture names." | 14998 | "Face used for displaying architecture names." |
| 14993 | :group 'speedbar-faces) | 14999 | :group 'speedbar-faces) |
| 15000 | ;; backward-compatibility alias | ||
| 15001 | (put 'vhdl-speedbar-architecture-face 'face-alias 'vhdl-speedbar-architecture) | ||
| 14994 | 15002 | ||
| 14995 | (defface vhdl-speedbar-configuration-face | 15003 | (defface vhdl-speedbar-configuration |
| 14996 | '((((class color) (background light)) (:foreground "DarkGoldenrod")) | 15004 | '((((class color) (background light)) (:foreground "DarkGoldenrod")) |
| 14997 | (((class color) (background dark)) (:foreground "Salmon"))) | 15005 | (((class color) (background dark)) (:foreground "Salmon"))) |
| 14998 | "Face used for displaying configuration names." | 15006 | "Face used for displaying configuration names." |
| 14999 | :group 'speedbar-faces) | 15007 | :group 'speedbar-faces) |
| 15008 | ;; backward-compatibility alias | ||
| 15009 | (put 'vhdl-speedbar-configuration-face 'face-alias 'vhdl-speedbar-configuration) | ||
| 15000 | 15010 | ||
| 15001 | (defface vhdl-speedbar-package-face | 15011 | (defface vhdl-speedbar-package |
| 15002 | '((((class color) (background light)) (:foreground "Grey50")) | 15012 | '((((class color) (background light)) (:foreground "Grey50")) |
| 15003 | (((class color) (background dark)) (:foreground "Grey80"))) | 15013 | (((class color) (background dark)) (:foreground "Grey80"))) |
| 15004 | "Face used for displaying package names." | 15014 | "Face used for displaying package names." |
| 15005 | :group 'speedbar-faces) | 15015 | :group 'speedbar-faces) |
| 15016 | ;; backward-compatibility alias | ||
| 15017 | (put 'vhdl-speedbar-package-face 'face-alias 'vhdl-speedbar-package) | ||
| 15006 | 15018 | ||
| 15007 | (defface vhdl-speedbar-library-face | 15019 | (defface vhdl-speedbar-library |
| 15008 | '((((class color) (background light)) (:foreground "Purple")) | 15020 | '((((class color) (background light)) (:foreground "Purple")) |
| 15009 | (((class color) (background dark)) (:foreground "Orchid1"))) | 15021 | (((class color) (background dark)) (:foreground "Orchid1"))) |
| 15010 | "Face used for displaying library names." | 15022 | "Face used for displaying library names." |
| 15011 | :group 'speedbar-faces) | 15023 | :group 'speedbar-faces) |
| 15024 | ;; backward-compatibility alias | ||
| 15025 | (put 'vhdl-speedbar-library-face 'face-alias 'vhdl-speedbar-library) | ||
| 15012 | 15026 | ||
| 15013 | (defface vhdl-speedbar-instantiation-face | 15027 | (defface vhdl-speedbar-instantiation |
| 15014 | '((((class color) (background light)) (:foreground "Brown")) | 15028 | '((((class color) (background light)) (:foreground "Brown")) |
| 15015 | (((min-colors 88) (class color) (background dark)) (:foreground "Yellow1")) | 15029 | (((min-colors 88) (class color) (background dark)) (:foreground "Yellow1")) |
| 15016 | (((class color) (background dark)) (:foreground "Yellow"))) | 15030 | (((class color) (background dark)) (:foreground "Yellow"))) |
| 15017 | "Face used for displaying instantiation names." | 15031 | "Face used for displaying instantiation names." |
| 15018 | :group 'speedbar-faces) | 15032 | :group 'speedbar-faces) |
| 15033 | ;; backward-compatibility alias | ||
| 15034 | (put 'vhdl-speedbar-instantiation-face 'face-alias 'vhdl-speedbar-instantiation) | ||
| 15019 | 15035 | ||
| 15020 | (defface vhdl-speedbar-subprogram-face | 15036 | (defface vhdl-speedbar-subprogram |
| 15021 | '((((class color) (background light)) (:foreground "Orchid4")) | 15037 | '((((class color) (background light)) (:foreground "Orchid4")) |
| 15022 | (((class color) (background dark)) (:foreground "BurlyWood2"))) | 15038 | (((class color) (background dark)) (:foreground "BurlyWood2"))) |
| 15023 | "Face used for displaying subprogram names." | 15039 | "Face used for displaying subprogram names." |
| 15024 | :group 'speedbar-faces) | 15040 | :group 'speedbar-faces) |
| 15041 | ;; backward-compatibility alias | ||
| 15042 | (put 'vhdl-speedbar-subprogram-face 'face-alias 'vhdl-speedbar-subprogram) | ||
| 15025 | 15043 | ||
| 15026 | (defface vhdl-speedbar-entity-selected-face | 15044 | (defface vhdl-speedbar-entity-selected |
| 15027 | '((((class color) (background light)) (:foreground "ForestGreen" :underline t)) | 15045 | '((((class color) (background light)) (:foreground "ForestGreen" :underline t)) |
| 15028 | (((class color) (background dark)) (:foreground "PaleGreen" :underline t))) | 15046 | (((class color) (background dark)) (:foreground "PaleGreen" :underline t))) |
| 15029 | "Face used for displaying entity names." | 15047 | "Face used for displaying entity names." |
| 15030 | :group 'speedbar-faces) | 15048 | :group 'speedbar-faces) |
| 15049 | ;; backward-compatibility alias | ||
| 15050 | (put 'vhdl-speedbar-entity-selected-face 'face-alias 'vhdl-speedbar-entity-selected) | ||
| 15031 | 15051 | ||
| 15032 | (defface vhdl-speedbar-architecture-selected-face | 15052 | (defface vhdl-speedbar-architecture-selected |
| 15033 | '((((min-colors 88) (class color) (background light)) (:foreground "Blue1" :underline t)) | 15053 | '((((min-colors 88) (class color) (background light)) (:foreground "Blue1" :underline t)) |
| 15034 | (((min-colors 88) (class color) (background light)) (:foreground "Blue1" :underline t)) | 15054 | (((min-colors 88) (class color) (background light)) (:foreground "Blue1" :underline t)) |
| 15035 | (((class color) (background light)) (:foreground "Blue" :underline t)) | 15055 | (((class color) (background light)) (:foreground "Blue" :underline t)) |
| 15036 | (((class color) (background dark)) (:foreground "LightSkyBlue" :underline t))) | 15056 | (((class color) (background dark)) (:foreground "LightSkyBlue" :underline t))) |
| 15037 | "Face used for displaying architecture names." | 15057 | "Face used for displaying architecture names." |
| 15038 | :group 'speedbar-faces) | 15058 | :group 'speedbar-faces) |
| 15059 | ;; backward-compatibility alias | ||
| 15060 | (put 'vhdl-speedbar-architecture-selected-face 'face-alias 'vhdl-speedbar-architecture-selected) | ||
| 15039 | 15061 | ||
| 15040 | (defface vhdl-speedbar-configuration-selected-face | 15062 | (defface vhdl-speedbar-configuration-selected |
| 15041 | '((((class color) (background light)) (:foreground "DarkGoldenrod" :underline t)) | 15063 | '((((class color) (background light)) (:foreground "DarkGoldenrod" :underline t)) |
| 15042 | (((class color) (background dark)) (:foreground "Salmon" :underline t))) | 15064 | (((class color) (background dark)) (:foreground "Salmon" :underline t))) |
| 15043 | "Face used for displaying configuration names." | 15065 | "Face used for displaying configuration names." |
| 15044 | :group 'speedbar-faces) | 15066 | :group 'speedbar-faces) |
| 15067 | ;; backward-compatibility alias | ||
| 15068 | (put 'vhdl-speedbar-configuration-selected-face 'face-alias 'vhdl-speedbar-configuration-selected) | ||
| 15045 | 15069 | ||
| 15046 | (defface vhdl-speedbar-package-selected-face | 15070 | (defface vhdl-speedbar-package-selected |
| 15047 | '((((class color) (background light)) (:foreground "Grey50" :underline t)) | 15071 | '((((class color) (background light)) (:foreground "Grey50" :underline t)) |
| 15048 | (((class color) (background dark)) (:foreground "Grey80" :underline t))) | 15072 | (((class color) (background dark)) (:foreground "Grey80" :underline t))) |
| 15049 | "Face used for displaying package names." | 15073 | "Face used for displaying package names." |
| 15050 | :group 'speedbar-faces) | 15074 | :group 'speedbar-faces) |
| 15075 | ;; backward-compatibility alias | ||
| 15076 | (put 'vhdl-speedbar-package-selected-face 'face-alias 'vhdl-speedbar-package-selected) | ||
| 15051 | 15077 | ||
| 15052 | (defface vhdl-speedbar-instantiation-selected-face | 15078 | (defface vhdl-speedbar-instantiation-selected |
| 15053 | '((((class color) (background light)) (:foreground "Brown" :underline t)) | 15079 | '((((class color) (background light)) (:foreground "Brown" :underline t)) |
| 15054 | (((min-colors 88) (class color) (background dark)) (:foreground "Yellow1" :underline t)) | 15080 | (((min-colors 88) (class color) (background dark)) (:foreground "Yellow1" :underline t)) |
| 15055 | (((class color) (background dark)) (:foreground "Yellow" :underline t))) | 15081 | (((class color) (background dark)) (:foreground "Yellow" :underline t))) |
| 15056 | "Face used for displaying instantiation names." | 15082 | "Face used for displaying instantiation names." |
| 15057 | :group 'speedbar-faces) | 15083 | :group 'speedbar-faces) |
| 15084 | ;; backward-compatibility alias | ||
| 15085 | (put 'vhdl-speedbar-instantiation-selected-face 'face-alias 'vhdl-speedbar-instantiation-selected) | ||
| 15058 | 15086 | ||
| 15059 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; | 15087 | ;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;; |
| 15060 | ;; Initialization | 15088 | ;; Initialization |