From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Stefan Monnier Newsgroups: gmane.emacs.devel Subject: Re: using glyphs by default in perl-mode Date: Sat, 01 Jun 2013 10:47:04 -0400 Message-ID: References: <83li7ocdkb.fsf@gnu.org> <87d2sp92vb.fsf@lifelogs.com> <87bo877kf7.fsf@lifelogs.com> <87obbs7cew.fsf@lifelogs.com> <87ip1y54fx.fsf@lifelogs.com> NNTP-Posting-Host: plane.gmane.org Mime-Version: 1.0 Content-Type: text/plain X-Trace: ger.gmane.org 1370098035 20744 80.91.229.3 (1 Jun 2013 14:47:15 GMT) X-Complaints-To: usenet@ger.gmane.org NNTP-Posting-Date: Sat, 1 Jun 2013 14:47:15 +0000 (UTC) To: emacs-devel@gnu.org Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jun 01 16:47:14 2013 Return-path: Envelope-to: ged-emacs-devel@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 1Uin5M-00021s-Rz for ged-emacs-devel@m.gmane.org; Sat, 01 Jun 2013 16:47:12 +0200 Original-Received: from localhost ([::1]:53345 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uin5M-000205-Ho for ged-emacs-devel@m.gmane.org; Sat, 01 Jun 2013 10:47:12 -0400 Original-Received: from eggs.gnu.org ([2001:4830:134:3::10]:36505) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uin5J-0001zM-3a for emacs-devel@gnu.org; Sat, 01 Jun 2013 10:47:10 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1Uin5H-0004LL-Gi for emacs-devel@gnu.org; Sat, 01 Jun 2013 10:47:09 -0400 Original-Received: from chene.dit.umontreal.ca ([132.204.246.20]:59358) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1Uin5H-0004L7-BQ for emacs-devel@gnu.org; Sat, 01 Jun 2013 10:47:07 -0400 Original-Received: from fmsmemgm.homelinux.net (lechon.iro.umontreal.ca [132.204.27.242]) by chene.dit.umontreal.ca (8.14.1/8.14.1) with ESMTP id r51El5LJ017646; Sat, 1 Jun 2013 10:47:05 -0400 Original-Received: by fmsmemgm.homelinux.net (Postfix, from userid 20848) id D11F3AE1E3; Sat, 1 Jun 2013 10:47:04 -0400 (EDT) In-Reply-To: <87ip1y54fx.fsf@lifelogs.com> (Ted Zlatanov's message of "Sat, 01 Jun 2013 09:46:42 -0400") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.3.50 (gnu/linux) X-NAI-Spam-Flag: NO X-NAI-Spam-Threshold: 5 X-NAI-Spam-Score: 0 X-NAI-Spam-Rules: 1 Rules triggered RV4596=0 X-NAI-Spam-Version: 2.3.0.9362 : core <4596> : streams <972260> : uri <1436008> X-detected-operating-system: by eggs.gnu.org: Genre and OS details not recognized. X-Received-From: 132.204.246.20 X-BeenThere: emacs-devel@gnu.org X-Mailman-Version: 2.1.14 Precedence: list List-Id: "Emacs development discussions." List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Original-Sender: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Xref: news.gmane.org gmane.emacs.devel:159970 Archived-At: > 1) move `perl--prettify-symbols-alist' and the functions for it, > `perl--font-lock-compose-symbol' and `perl--font-lock-symbols-keywords' > to simple.el (with the "prog-" prefix). You might like to consider the pretty-lambda for Lisp as well as the sml-font-lock-symbols in elpa/packages/sml-mode/sml-mode.el. [ There are others out there for, e.g. for Hasekll-mode. ] > 2) declare `perl-prettify-symbols' obsolete in favor of the alist > `prog-prettify-symbols'. No need for such obsolescence declaration, since it's never been in any released version. > I gave `prog-prettify-symbols' two default choices: > `prog--prettify-symbols-alist-basic' (just -> => ::) and > `prog--prettify-symbols-alist-extended' (basic plus much more). It can > also be a free-form alist with key=string, value=character. I expect > programming modes will need to augment this list somehow, but I'd like > the user to simply say "I want basics or extended" instead of having to > select individual glyphs for every language. Maybe the choice should be > between :basic and :extended as symbols? Ideas welcome. In my experience, every major mode might want to provide its own list. > The patch grows simple.el. Perhaps it should live in prog.el or > prettify.el. prog.el seems more sensible. I think prog-mode.el is in order, yes. > I also wonder if it's possible to add the prettify support at the > `prog-mode' level, so each mode doesn't have to explicitly inline > those keywords. That would be nice, indeed. But I fear it's going to be tricky to make it work right, so let's keep it for later. > Unfortunately my font-lock-fu is not good, so I'd really appreciate help > with the last two issues. I spent a few hours on them but couldn't work > them out. I don't have much time to devote right now, but the current problem is probably a minor oversight. Stefan