From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Dieter Wilhelm Newsgroups: gmane.emacs.help Subject: font-lock regexp for complementary keywords Date: Mon, 24 Jul 2006 18:53:55 +0200 Message-ID: <87k663nduk.fsf@hans.local.net> NNTP-Posting-Host: main.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: sea.gmane.org 1153819133 8395 80.91.229.2 (25 Jul 2006 09:18:53 GMT) X-Complaints-To: usenet@sea.gmane.org NNTP-Posting-Date: Tue, 25 Jul 2006 09:18:53 +0000 (UTC) Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Jul 25 11:18:51 2006 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by ciao.gmane.org with esmtp (Exim 4.43) id 1G5J3y-0003qd-Ii for geh-help-gnu-emacs@m.gmane.org; Tue, 25 Jul 2006 11:18:50 +0200 Original-Received: from localhost ([127.0.0.1] helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1G5J3x-00080y-VF for geh-help-gnu-emacs@m.gmane.org; Tue, 25 Jul 2006 05:18:50 -0400 Original-Received: from mailman by lists.gnu.org with tmda-scanned (Exim 4.43) id 1G5J3i-0007yQ-CN for help-gnu-emacs@gnu.org; Tue, 25 Jul 2006 05:18:34 -0400 Original-Received: from exim by lists.gnu.org with spam-scanned (Exim 4.43) id 1G5J3h-0007wq-61 for help-gnu-emacs@gnu.org; Tue, 25 Jul 2006 05:18:34 -0400 Original-Received: from [199.232.76.173] (helo=monty-python.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1G5J3g-0007wX-TL for help-gnu-emacs@gnu.org; Tue, 25 Jul 2006 05:18:32 -0400 Original-Received: from [212.227.126.171] (helo=moutng.kundenserver.de) by monty-python.gnu.org with esmtp (Exim 4.52) id 1G5J4y-0000z2-8P for help-gnu-emacs@gnu.org; Tue, 25 Jul 2006 05:19:52 -0400 Original-Received: from [84.167.65.190] (helo=duenenhof-wilhelm.de) by mrelayeu.kundenserver.de (node=mrelayeu2) with ESMTP (Nemesis), id 0MKwtQ-1G5J3f042L-0003xJ; Tue, 25 Jul 2006 11:18:31 +0200 Original-Received: by duenenhof-wilhelm.de (Postfix, from userid 1000) id AE4CC75518; Mon, 24 Jul 2006 18:53:56 +0200 (CEST) Original-To: help-gnu-emacs@gnu.org User-Agent: Gnus/5.11 (Gnus v5.11) Emacs/22.0.50 (gnu/linux) X-Provags-ID: kundenserver.de abuse@kundenserver.de login:d7ab225b98a136e1c2910381f940ecb9 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:36214 Archived-At: Hi I'd like to fontify Ansys keywords. The solver accepts unique short forms of the command keywords, the rest is ignored. For example the uniqe part of `/filname' is `/fil' and I'd like to fontify /fil and /filn and /filna and /filnam and /filname and as well. The only idea I got so far is to do it in 5 separate font-lock statements: \\(/fil\\) 1 font-lock... /fil\\(n\\) 1 fon... /filn\\(a\\) 1 ... /filna\\(m\\) 1 ... /filnam\\(e\\) 1 ... Very ugly and inefficient, isn't it? Originally I thought that something like this /fil\\(n\\|na\\|nam\\|name\\) would work but rexexp-bulider doesn't show any matches for the complementing alternatives. -- Best wishes H. Dieter Wilhelm Darmstadt, Germany