From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Lennart Borgman Newsgroups: gmane.emacs.help Subject: Re: Getting minor mode to read word Date: Thu, 18 Nov 2010 14:54:20 +0100 Message-ID: References: <86wroalpht.fsf@pm18pc01.europe.root.pri> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 X-Trace: dough.gmane.org 1290088538 30347 80.91.229.12 (18 Nov 2010 13:55:38 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Thu, 18 Nov 2010 13:55:38 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: "Paulo J. Matos" Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Thu Nov 18 14:55:34 2010 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([199.232.76.165]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1PJ4xZ-0006TA-6F for geh-help-gnu-emacs@m.gmane.org; Thu, 18 Nov 2010 14:55:33 +0100 Original-Received: from localhost ([127.0.0.1]:42948 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PJ4xY-00072s-7u for geh-help-gnu-emacs@m.gmane.org; Thu, 18 Nov 2010 08:55:32 -0500 Original-Received: from [140.186.70.92] (port=38759 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1PJ4wl-0006qk-Mn for help-gnu-emacs@gnu.org; Thu, 18 Nov 2010 08:54:44 -0500 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1PJ4wk-00077K-JD for help-gnu-emacs@gnu.org; Thu, 18 Nov 2010 08:54:43 -0500 Original-Received: from mail-ew0-f41.google.com ([209.85.215.41]:60834) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1PJ4wk-00076d-Em for help-gnu-emacs@gnu.org; Thu, 18 Nov 2010 08:54:42 -0500 Original-Received: by ewy25 with SMTP id 25so1904437ewy.0 for ; Thu, 18 Nov 2010 05:54:41 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:received:mime-version:received:in-reply-to :references:from:date:message-id:subject:to:cc:content-type; bh=jeZDw58P5zI5ieYrdPDgDZsooJ49JmL5S66qSPuiWrg=; b=v6Arf0GkWuUYNXtKvVyIo31k4Obq42jn53fUH/JT8adnIG+Mhmoq602ddVWpJVkLK8 vyFejH2QeTvE9ysj4jXs1JgJ+KuWxuzIIwWoWdDRkXCeE+N21ciVwvr9PGjBXVDOOg2N GMqx10FmVcqY+vUGmXnVFJfohPVev8vjf1crk= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:from:date:message-id:subject:to :cc:content-type; b=OlWJ+bM3rjXaSb1XA+wBWW70x6lE5Y0N7sga0IY/siFOjIFZMIRrAdpDp5dQ/kJ2f5 fDtzzIKVWvlF6U9G6uB6xM1xYyZVKOQTCfmXXJsXue1BwIjmQKLHSgpuAgsxskD+hVSr 9g+6Oqrx94Ui4ktsW1IJ+EoW6x21Up8M7PMfc= Original-Received: by 10.213.34.20 with SMTP id j20mr507171ebd.71.1290088481068; Thu, 18 Nov 2010 05:54:41 -0800 (PST) Original-Received: by 10.213.22.135 with HTTP; Thu, 18 Nov 2010 05:54:20 -0800 (PST) In-Reply-To: <86wroalpht.fsf@pm18pc01.europe.root.pri> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) 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:75400 Archived-At: On Thu, Nov 18, 2010 at 2:39 PM, Paulo J. Matos wrote: > Hi all, > > I am trying to create a very simple minor mode to start with. Once the > mode is loaded I just want to transform all the strings matching a given > regexp: "B-[0-9]+" into a url which once clicked, opens the default > browser with a given url. > > My problem is to start up. How do I tell emacs that there is a minor > mode that people can load and which hook can I use to enable the search > function (for the regexp) to perform the search and replace the text for > a url everytime the buffer changes? Look at font lock keywords.