From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Juri Linkov Newsgroups: gmane.emacs.devel Subject: Re: Another input method feature needed Date: Fri, 02 Jul 2010 23:52:34 +0300 Organization: JURTA Message-ID: <87bpap8v3h.fsf@mail.jurta.org> References: <87wru14onc.fsf@mail.jurta.org> <49520.130.55.132.126.1276531995.squirrel@webmail.lanl.gov> <87y6ebo1c3.fsf@mail.jurta.org> <87aaqr2s2v.fsf@gmail.com> <87mxurmap7.fsf@mail.jurta.org> <87d3vfwc06.fsf@gmail.com> <87zkyeesjs.fsf@mail.jurta.org> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii X-Trace: dough.gmane.org 1278108771 26499 80.91.229.12 (2 Jul 2010 22:12:51 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Fri, 2 Jul 2010 22:12:51 +0000 (UTC) Cc: =?utf-8?B?xaB0xJtww6FuIE7Em21lYw==?= , emacs-devel@gnu.org To: Stefan Monnier Original-X-From: emacs-devel-bounces+ged-emacs-devel=m.gmane.org@gnu.org Sat Jul 03 00:12:49 2010 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.69) (envelope-from ) id 1OUoTZ-00013B-2V for ged-emacs-devel@m.gmane.org; Sat, 03 Jul 2010 00:12:49 +0200 Original-Received: from localhost ([127.0.0.1]:52409 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OUoTY-0002EM-1y for ged-emacs-devel@m.gmane.org; Fri, 02 Jul 2010 18:12:48 -0400 Original-Received: from [140.186.70.92] (port=42594 helo=eggs.gnu.org) by lists.gnu.org with esmtp (Exim 4.43) id 1OUoTK-0002D8-Pz for emacs-devel@gnu.org; Fri, 02 Jul 2010 18:12:36 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.69) (envelope-from ) id 1OUoTI-0002Xl-2P for emacs-devel@gnu.org; Fri, 02 Jul 2010 18:12:34 -0400 Original-Received: from smtp-out2.starman.ee ([85.253.0.4]:41128 helo=mx2.starman.ee) by eggs.gnu.org with esmtp (Exim 4.69) (envelope-from ) id 1OUoTH-0002XL-P3 for emacs-devel@gnu.org; Fri, 02 Jul 2010 18:12:32 -0400 X-Virus-Scanned: by Amavisd-New at mx2.starman.ee Original-Received: from mail.starman.ee (82.131.28.160.cable.starman.ee [82.131.28.160]) by mx2.starman.ee (Postfix) with ESMTP id ADB6C3F4137; Sat, 3 Jul 2010 01:12:25 +0300 (EEST) In-Reply-To: (Stefan Monnier's message of "Thu, 01 Jul 2010 02:05:02 +0200") User-Agent: Gnus/5.13 (Gnus v5.13) Emacs/24.0.50 (x86_64-pc-linux-gnu) X-detected-operating-system: by eggs.gnu.org: GNU/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:126713 Archived-At: >>> Let's not let this fall into oblivion the second time. Any objections >>> against Juri including the library into Emacs and continuing integrating >>> it/working on it (or the other way round)? > > If it's in a usable state, it can be installed. If not, then maybe it > can be split into smaller steps where each step is in a usable state. Currently the code is too ugly to install. I'd like to refactor help functions first. >> In any case it would be useful to split help functions into two parts: > >> 1. data collection that returns data structures with help information; >> 2. view generation that renders the output according to defined layouts. > > Feel free to install refactoring patches that do that. Refactoring patches are not ready yet. I'm thinking about what is the best way of doing that. Actually for the data part there is already exists something similar to what we need: for advised functions `ad-get-advice-info' returns an alist with information about an advised function: ((active . t/nil) (before adv1 adv2 ...) (around adv1 adv2 ...) (after adv1 adv2 ...) (activation adv1 adv2 ...) (deactivation adv1 adv2 ...) (origname . ) (cache . ( . ))) We could create a new function `describe-function-info' that will return a similar alist with information about all functions with association keys like `docstring', `file-name', `keybindings', `arglist', `obsolete', etc. And similarly for other help functions: `describe-variable-info', `describe-face-info', ... For the view part we need a templating library. I think the most suitable is skeleton.el. It is used successfully in autoinsert.el to generate large complex text blocks. So we could use skeleton.el and add new variables `describe-function-skeleton', `describe-variable-skeleton', ... -- Juri Linkov http://www.jurta.org/emacs/