From mboxrd@z Thu Jan 1 00:00:00 1970 Path: news.gmane.org!not-for-mail From: Yuri Khan Newsgroups: gmane.emacs.help Subject: Re: A macro for printing keymap bindings in a pretty fashion Date: Tue, 6 Sep 2011 08:15:19 +0700 Message-ID: References: <4E652EF8.6020707@gmail.com> NNTP-Posting-Host: lo.gmane.org Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 X-Trace: dough.gmane.org 1315271737 20623 80.91.229.12 (6 Sep 2011 01:15:37 GMT) X-Complaints-To: usenet@dough.gmane.org NNTP-Posting-Date: Tue, 6 Sep 2011 01:15:37 +0000 (UTC) Cc: help-gnu-emacs@gnu.org To: Jonathan Ganc Original-X-From: help-gnu-emacs-bounces+geh-help-gnu-emacs=m.gmane.org@gnu.org Tue Sep 06 03:15:33 2011 Return-path: Envelope-to: geh-help-gnu-emacs@m.gmane.org Original-Received: from lists.gnu.org ([140.186.70.17]) by lo.gmane.org with esmtp (Exim 4.69) (envelope-from ) id 1R0kGC-0004De-2K for geh-help-gnu-emacs@m.gmane.org; Tue, 06 Sep 2011 03:15:32 +0200 Original-Received: from localhost ([::1]:43826 helo=lists.gnu.org) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0kGB-0005Ds-53 for geh-help-gnu-emacs@m.gmane.org; Mon, 05 Sep 2011 21:15:31 -0400 Original-Received: from eggs.gnu.org ([140.186.70.92]:50660) by lists.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0kG3-0005CV-0X for help-gnu-emacs@gnu.org; Mon, 05 Sep 2011 21:15:27 -0400 Original-Received: from Debian-exim by eggs.gnu.org with spam-scanned (Exim 4.71) (envelope-from ) id 1R0kG0-0007th-QZ for help-gnu-emacs@gnu.org; Mon, 05 Sep 2011 21:15:22 -0400 Original-Received: from mail-qy0-f176.google.com ([209.85.216.176]:64820) by eggs.gnu.org with esmtp (Exim 4.71) (envelope-from ) id 1R0kG0-0007tY-Lu for help-gnu-emacs@gnu.org; Mon, 05 Sep 2011 21:15:20 -0400 Original-Received: by qyl16 with SMTP id 16so3510926qyl.0 for ; Mon, 05 Sep 2011 18:15:19 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type; bh=2DOMpMek8Atle4gPVi6gfoi3DVI/rfP5IrMD/c0j1nw=; b=LmZ+LcQy9vsOaDa9xJocGtHA8lIufJtDTpAFHH/efGWF4NKytd8khHb/xBa6FZg0Iv oo8Mji8GDXgw6WHMgqIUl8q5jUd5BgBI++isiq+BPcI11696W7oh5tEvDvGkTf3gx2l+ 1tIlH70axHhLAzAPOPSy1kmn8MYfljDmz+nas= Original-Received: by 10.229.24.132 with SMTP id v4mr3438741qcb.193.1315271719629; Mon, 05 Sep 2011 18:15:19 -0700 (PDT) Original-Received: by 10.229.246.76 with HTTP; Mon, 5 Sep 2011 18:15:19 -0700 (PDT) In-Reply-To: <4E652EF8.6020707@gmail.com> X-detected-operating-system: by eggs.gnu.org: GNU/Linux 2.6 (newer, 2) X-Received-From: 209.85.216.176 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:82156 Archived-At: On Tue, Sep 6, 2011 at 03:20, Jonathan Ganc wrote: > So I wrote a macro "pkb" (for print key-bindings), which I've attached. It > outputs the keybindings as a (somewhat) pretty html document. The simplified > instructions: after loading the two .el files, run (pkb-html-save-keymap > KEYMAP OUTPUT-FILE-NAME), where KEYMAP is the KEYMAP you want printed and > OUTPUT-FILE-NAME is where the output will stored; e.g. (pkb-html-save-keymap > (current-global-map) "~/test.html"). `pkb-html-save-keymap' has many other > options that are described in the help function. I have placed an example of > the output at http://www.ph.utexas.edu/~jonganc/emacs/example.html; note > that the example is direct output from the macro. Your choice of up arrow for 'forward' and down arrow for 'backward' is a bit counter-intuitive. Otherwise, nice idea.