From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Richard Riley Newsgroups: gmane.emacs.help Subject: Re: sh mode for region only ? Date: Wed, 09 May 2012 16:19:21 +0200 Organization: aich tea tea pea dicky riley dot net Message-ID: <8g1umtfndi.fsf@news.eternal-september.org> References: <155DEC68569B714B86C2C7075F5EDA9844A6@DAKIYA1.pegasus.local> Reply-To: help-gnu-emacs@gnu.org NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: dough.gmane.org 1336573201 24013 80.91.229.3 (9 May 2012 14:20:01 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Wed, 9 May 2012 14:20:01 +0000 (UTC) To: help-gnu-emacs@gnu.org Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Wed May 09 16:20:00 2012 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([208.118.235.17]) by plane.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1SS7kG-0002AE-8Q for geh-help-gnu-emacs@m.gmane.org; Wed, 09 May 2012 16:20:00 +0200 Original-Received: from localhost ([::1]:46675 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SS7kF-0007NA-HV for geh-help-gnu-emacs@m.gmane.org; Wed, 09 May 2012 10:19:59 -0400 Original-Received: from eggs.gnu.org ([208.118.235.92]:33827) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SS7k6-0007LE-UK for help-gnu-emacs@gnu.org; Wed, 09 May 2012 10:19:55 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1SS7ju-0005Hu-Gv for help-gnu-emacs@gnu.org; Wed, 09 May 2012 10:19:50 -0400 Original-Received: from plane.gmane.org ([80.91.229.3]:50943) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1SS7ju-0005GA-A9 for help-gnu-emacs@gnu.org; Wed, 09 May 2012 10:19:38 -0400 Original-Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1SS7jq-0001yi-EJ for help-gnu-emacs@gnu.org; Wed, 09 May 2012 16:19:34 +0200 Original-Received: from 85.183.18.158 ([85.183.18.158]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 09 May 2012 16:19:34 +0200 Original-Received: from rileyrg by 85.183.18.158 with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Wed, 09 May 2012 16:19:34 +0200 X-Injected-Via-Gmane: http://gmane.org/ Mail-Followup-To: help-gnu-emacs@gnu.org Original-Lines: 33 Original-X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: 85.183.18.158 Mail-Copies-To: never User-Agent: Gnus/5.130006 (Ma Gnus v0.6) Emacs/24.1.50 (gnu/linux) Cancel-Lock: sha1:PHdBYI7D+8cQcs6Uh4q8qWhOisA= X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 80.91.229.3 X-BeenThere: help-gnu-emacs@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: Users list for the GNU Emacs text editor List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Original-Sender: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.help:84774 Archived-At: Doug Lewan writes: > At my last job I had to work with HTML that was heavily laden with JavaScript, so something similar was very useful for me. > I wrote a post-command-hook to see if the point had moved into a region of JavaScript and, if it had, then change to JavaScript mode. > > If your regions of shell code have reasonably consistent delimiters, then doing the same thing should not be too difficult. > > ,Doug nxhtml might be good for you too. > >> -----Original Message----- >> From: help-gnu-emacs-bounces+dougl=shubertticketing.com@gnu.org >> [mailto:help-gnu-emacs-bounces+dougl=shubertticketing.com@gnu.org] On >> Behalf Of Alexandre Oberlin >> Sent: Wednesday, 2012 May 09 09:26 >> To: help-gnu-emacs@gnu.org >> Subject: sh mode for region only ? >> >> Hi all, >> >> Is there a possibility to benefit of sh (or whatever) syntax >> highlighting on a region only? >> >> This could be useful when editing a list of instructions containing >> codes. >> >> Alexandre >> >