bug-gnu-emacs
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[PATCH]WoMan's buffer name not customizable


From: Terechkov Evgenii
Subject: [PATCH]WoMan's buffer name not customizable
Date: Sun, 07 Oct 2007 12:29:28 +0800
User-agent: Gnus/5.11 (Gnus v5.11) Emacs/22.1 (gnu/linux)

Hello.

In my Emacs 22.1.1 I meet little trouble: WoMan's buffers names begin
from "*" and, with combination with iswitchb and ibuffer (I setup them
to hide all buffers, whos names begin on asterisk, as it usually
temporary buffers) I just "can't see needed WoMan's buffers in various
buffer lists. What I need is, I think, customization of WoMan's buffer
names. So I digg the elisp code and write attached simple patch. It's
work fine for me (not ideally, actually, e.g., it show man's section
number at begin of buffer name). I hope this patch will be included in
next stable release of Emacs.

P.S.: sorry for my ugly English.
diff -ruN /home/evg/.emacs.d/woman.el.orig /home/evg/.emacs.d/woman.el
--- /home/evg/.emacs.d/woman.el.orig    2007-10-07 12:03:17 +0800
+++ /home/evg/.emacs.d/woman.el 2007-10-07 12:09:50 +0800
@@ -537,6 +537,15 @@
   :type 'hook
   :group 'woman)
 
+(defcustom woman-buffer-name-format "*WoMan %b*"
+  "Format specification for WoMan's buffer name.
+These fields are available at this moment:
+
+%b     initial buffer name
+"
+  :group 'woman
+  :type 'string)
+
 
 ;; Interface options
 
@@ -1633,7 +1642,7 @@
                           (substring bufname (1+ dot)) " "
                           (substring bufname 0 dot))))
     (generate-new-buffer-name          ; ensure uniqueness
-     (concat "*WoMan " bufname "*"))))
+     (format-spec woman-buffer-name-format (list (cons ?b bufname))))))
 
 (defvar woman-frame nil
   "Dedicated frame used for displaying WoMan windows.")

-- 
                                                С уважением, Терешков
                                                Евгений.

reply via email to

[Prev in Thread] Current Thread [Next in Thread]