From: Eshel Yaron Date: Fri, 25 Nov 2022 10:50:21 +0000 (+0200) Subject: Recognize and highlight built-in predicate definitions X-Git-Tag: V9.1.0-sweep-0.9.1~3 X-Git-Url: http://git.eshelyaron.com/gitweb/?a=commitdiff_plain;h=87aed9cf8555945b3a61c493e4aba63162e59f40;p=sweep.git Recognize and highlight built-in predicate definitions * sweeprolog.el (sweeprolog-analyze-fragment-to-faces): recognize "def_swi" and "def_iso" predicate head kinds . --- diff --git a/sweeprolog.el b/sweeprolog.el index 94ccb26..d9bce9b 100644 --- a/sweeprolog.el +++ b/sweeprolog.el @@ -1334,6 +1334,20 @@ resulting list even when found in the current clause." (:background "orange" :weight bold) "ISO specified predicate definitions.") +(sweeprolog-defface + head-def-iso + (:inherit font-lock-builtin-face) + (:foreground "blue" :weight bold) + (:foreground "cyan" :weight bold) + "Built-in ISO specified predicate definitions.") + +(sweeprolog-defface + head-def-swi + (:inherit font-lock-builtin-face) + (:foreground "blue" :weight bold) + (:foreground "cyan" :weight bold) + "Built-in SWI-Prolog predicate definitions.") + (sweeprolog-defface head-imported (:inherit font-lock-function-name-face) @@ -1799,6 +1813,10 @@ resulting list even when found in the current clause." (list (list beg end (sweeprolog-head-test-face)))) (`("head" "meta" . ,_) (list (list beg end (sweeprolog-head-meta-face)))) + (`("head" "def_iso" . ,_) + (list (list beg end (sweeprolog-head-def-iso-face)))) + (`("head" "def_swi" . ,_) + (list (list beg end (sweeprolog-head-def-swi-face)))) (`("head" "iso" . ,_) (list (list beg end (sweeprolog-head-iso-face)))) (`("head" "exported" . ,_)