gestion des commentaires de doc

git-svn-id: http://caml.inria.fr/svn/ocaml/trunk@4131 f963ae5c-01c2-4b8c-9fe0-0dff7051ff02
master
Maxence Guesdon 2001-12-05 20:26:20 +00:00
parent ee3fa28267
commit 82d02625e5
1 changed files with 18 additions and 3 deletions

View File

@ -1,8 +1,9 @@
;; useful colors
(cond
((and (x-display-color-p)
(not (memq 'font-lock-type-face (face-list))))
((x-display-color-p)
;
; (not (memq 'font-lock-type-face (face-list))))
; make the necessary faces
(make-face 'Firebrick)
(set-face-foreground 'Firebrick "Firebrick")
@ -18,6 +19,11 @@
(set-face-foreground 'DarkOliveGreen "DarkOliveGreen4")
(make-face 'CadetBlue)
(set-face-foreground 'CadetBlue "CadetBlue")
(make-face 'Stop)
(set-face-foreground 'Stop "White")
(set-face-background 'Stop "Red")
(make-face 'Doc)
(set-face-foreground 'Doc "Red")
; assign them as standard faces
(setq font-lock-comment-face 'Firebrick)
(setq font-lock-string-face 'RosyBrown)
@ -25,7 +31,10 @@
(setq font-lock-function-name-face 'MidnightBlue)
(setq font-lock-variable-name-face 'DarkGoldenRod)
(setq font-lock-type-face 'DarkOliveGreen)
(setq font-lock-reference-face 'CadetBlue)))
(setq font-lock-reference-face 'CadetBlue)
(setq font-lock-stop-face 'Stop)
(setq font-lock-doccomment-face 'Doc)
))
; The same definition is in caml.el:
; we don't know in which order they will be loaded.
@ -34,6 +43,12 @@
(defconst caml-font-lock-keywords
(list
;stop special comments
'("\\(^\\|[^\"]\\)\\((\\*\\*/\\*\\*)\\)"
2 font-lock-stop-face)
;doccomments
'("\\(^\\|[^\"]\\)\\((\\*\\*[^*]*\\([^)*][^*]*\\*+\\)*)\\)"
2 font-lock-doccomment-face)
;comments
'("\\(^\\|[^\"]\\)\\((\\*[^*]*\\*+\\([^)*][^*]*\\*+\\)*)\\)"
2 font-lock-comment-face)