From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Kevin Ryde Newsgroups: gmane.emacs.devel Subject: nroff-mode groff \# comments (patch) Date: Thu, 24 May 2007 09:37:12 +1000 Message-ID: <87sl9nkt7b.fsf@zip.com.au> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: multipart/mixed; boundary="=-=-=" X-Trace: sea.gmane.org 1179963387 30487 80.91.229.12 (23 May 2007 23:36:27 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Wed, 23 May 2007 23:36:27 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Thu May 24 01:36:18 2007 Return-path: Envelope-to: ged-emacs-devel@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.50) id 1Hr0NN-0001Ll-7p for ged-emacs-devel@m.gmane.org; Thu, 24 May 2007 01:36:17 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Hr0NP-0002Q4-5c for ged-emacs-devel@m.gmane.org; Wed, 23 May 2007 19:36:19 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1Hr0NL-0002Pz-Rb for emacs-devel@gnu.org; Wed, 23 May 2007 19:36:15 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1Hr0NJ-0002Pn-G2 for emacs-devel@gnu.org; Wed, 23 May 2007 19:36:14 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1Hr0NJ-0002Pk-85 for emacs-devel@gnu.org; Wed, 23 May 2007 19:36:13 -0400 Original-Received: from mailout1-1.pacific.net.au ([61.8.2.208] helo=mailout1.pacific.net.au) by monty-python.gnu.org with esmtp (Exim 4.60) (envelope-from ) id 1Hr0NI-00087j-CY for emacs-devel@gnu.org; Wed, 23 May 2007 19:36:12 -0400 Original-Received: from mailproxy1.pacific.net.au (mailproxy1.pacific.net.au [61.8.2.162]) by mailout1.pacific.net.au (Postfix) with ESMTP id 8D1AC69FD25 for ; Thu, 24 May 2007 09:35:25 +1000 (EST) Original-Received: from localhost (ppp2D4D.dyn.pacific.net.au [61.8.45.77]) by mailproxy1.pacific.net.au (Postfix) with ESMTP id C131B8C1D for ; Thu, 24 May 2007 09:35:24 +1000 (EST) Original-Received: from gg by localhost with local (Exim 4.67) (envelope-from ) id 1Hr0OH-0003D9-4o for emacs-devel@gnu.org; Thu, 24 May 2007 09:37:13 +1000 User-Agent: Gnus/5.110007 (No Gnus v0.7) Emacs/22.0.99 (gnu/linux) X-detected-kernel: Linux 2.6, seldom 2.4 (older, 4) X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:71697 Archived-At: --=-=-= In groff \# introduces a comment, through to newline, like the normal troff \" but eating the newline as well, or something like that. You can lots for instance in om.tmac (/usr/share/groff/1.18.1/tmac/om.tmac) which comes with groff. (Remember to M-x nroff-mode.) 2007-05-24 Kevin Ryde * textmodes/nroff-mode.el: Groff \# comments. (nroff-mode-syntax-table): \# comment intro, plain # as punct per global table. (nroff-font-lock-keywords): Add # as a single char escape. (nroff-mode): In comment-start-skip, match \#. --=-=-= Content-Type: text/x-diff Content-Disposition: attachment; filename=nroff-mode.el.groff.diff *** nroff-mode.el 12 Mar 2007 10:16:24 +1100 1.32 --- nroff-mode.el 24 May 2007 09:33:22 +1000 *************** *** 66,71 **** --- 66,73 ---- ;; ' used otherwise). (modify-syntax-entry ?\" "\" 2" st) ;; Comments are delimited by \" and newline. + ;; And in groff also \# to newline. + (modify-syntax-entry ?# ". 2" st) (modify-syntax-entry ?\\ "\\ 1" st) (modify-syntax-entry ?\n ">" st) st) *************** *** 92,98 **** (mapconcat 'identity '("[f*n]*\\[.+?]" ; some groff extensions "(.." ; two chars after ( ! "[^(\"]" ; single char escape ) "\\|") "\\)") ) --- 94,100 ---- (mapconcat 'identity '("[f*n]*\\[.+?]" ; some groff extensions "(.." ; two chars after ( ! "[^(\"#]" ; single char escape ) "\\|") "\\)") ) *************** *** 127,133 **** (concat "[.']\\|" paragraph-separate)) ;; comment syntax added by mit-erl!gildea 18 Apr 86 (set (make-local-variable 'comment-start) "\\\" ") ! (set (make-local-variable 'comment-start-skip) "\\\\\"[ \t]*") (set (make-local-variable 'comment-column) 24) (set (make-local-variable 'comment-indent-function) 'nroff-comment-indent) (set (make-local-variable 'imenu-generic-expression) nroff-imenu-expression)) --- 129,135 ---- (concat "[.']\\|" paragraph-separate)) ;; comment syntax added by mit-erl!gildea 18 Apr 86 (set (make-local-variable 'comment-start) "\\\" ") ! (set (make-local-variable 'comment-start-skip) "\\\\[\"#][ \t]*") (set (make-local-variable 'comment-column) 24) (set (make-local-variable 'comment-indent-function) 'nroff-comment-indent) (set (make-local-variable 'imenu-generic-expression) nroff-imenu-expression)) --=-=-= Content-Type: text/plain; charset="us-ascii" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit Content-Disposition: inline _______________________________________________ Emacs-devel mailing list Emacs-devel@gnu.org http://lists.gnu.org/mailman/listinfo/emacs-devel --=-=-=--