From: bojohan+news@dd.chalmers.se (Johan Bockgård)
Subject: Re: Derived Mode 101 HOWTO
Date: Sun, 12 Mar 2006 06:29:36 +0100 [thread overview]
Message-ID: <yoijacbwgri7.fsf@linus003.dd.chalmers.se> (raw)
In-Reply-To: slrne0sfdp.2r9.tim@linus.johnson.com
Tim Johnson <tim@johnsons-web.com> writes:
> (defvar newlisp-font-lock-keywords
> `(,@scheme-font-lock-keywords
> (,(concat "\\<\\(" newlisp-keywords "\\)\\>")
> . font-lock-newlisp-keywords-face))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[C-h v font-lock-keywords]
Emacs:
"FACENAME is an expression whose value is the face name to use."
^^^^^^^^^^^^^^^^^^^^^^
XEmacs:
"FACE-FORM :== The symbol naming a defined face. | Expression whos
value is the face name to use. If you want FACE-FORM to be a
symbol that evaluates to a face, use a form like "(progn sym)"."
> (define-derived-mode newlisp-mode scheme-mode "newlisp"
> "A major mode for Newlisp."
> (set (make-local-variable 'font-lock-defaults)
> (cons newlisp-font-lock-keywords
> ;; Copy the rest of font-lock-defaults from
> ;; scheme-mode if available.
> (or (cdr font-lock-defaults)
> '(nil t (("+-*/.<>=!?$%_&~^:" . "w")))))))
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
[C-h v font-lock-defaults]
Emacs:
"If SYNTAX-ALIST is non-nil, it should be a list of cons pairs of the form
(CHAR-OR-STRING . STRING) used to set the local Font Lock syntax table"
^^^^^^^^^^^^^^
XEmacs:
"If SYNTAX-ALIST is non-nil, it should be a list of cons pairs of the form
(CHAR . STRING) used to set the local Font Lock syntax table"
^^^^
--
Johan Bockgård
next prev parent reply other threads:[~2006-03-12 5:29 UTC|newest]
Thread overview: 16+ messages / expand[flat|nested] mbox.gz Atom feed top
2006-03-06 17:59 Derived Mode 101 HOWTO Tim Johnson
2006-03-07 18:01 ` Stefan Monnier
2006-03-08 2:58 ` Tim Johnson
2006-03-08 5:46 ` Stefan Monnier
2006-03-08 16:58 ` Tim Johnson
2006-03-11 17:15 ` Stefan Monnier
2006-03-12 0:57 ` Tim Johnson
2006-03-12 13:49 ` Stefan Monnier
2006-03-13 1:48 ` Tim Johnson
2006-03-13 10:10 ` Johan Bockgård
2006-03-13 17:57 ` Tim Johnson
2006-03-13 21:35 ` Johan Bockgård
2006-03-13 23:57 ` Tim Johnson
2006-03-12 5:29 ` Johan Bockgård [this message]
2006-03-12 17:50 ` Tim Johnson
2006-03-12 18:14 ` Johan Bockgård
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
List information: https://www.gnu.org/software/emacs/
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=yoijacbwgri7.fsf@linus003.dd.chalmers.se \
--to=bojohan+news@dd.chalmers.se \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).