unofficial mirror of emacs-devel@gnu.org 
 help / color / mirror / code / Atom feed
* tool bar icons not updated according to :active condition
@ 2006-01-23 18:59 Reiner Steib
  2006-02-24 15:23 ` Chong Yidong
  0 siblings, 1 reply; 21+ messages in thread
From: Reiner Steib @ 2006-01-23 18:59 UTC (permalink / raw)


Hi,

`gnus-group-mode-map' contains the following menu entry (see
`gnus-group-make-menu-bar'):

  (easy-menu-define gnus-group-reading-menu gnus-group-mode-map ""
    `("Group"
      [...]
      ["Describe" gnus-group-describe-group
        :active (gnus-group-group-name) ...]

I.e. this menu item should be inactive[1] if the point isn't on a
group line (e.g. on non-group lines when using topics mode [2]).  In
the menu, this works correctly, i.e. the menu item is disabled
(probably because the menu is updated when clicking on "Group").

In `gnus-group-make-tool-bar' the describe-group entry is also added
to the tool bar (icon: etc/images/gnus/describe-group.xpm):

  (tool-bar-add-item-from-menu
    'gnus-group-describe-group "describe-group" gnus-group-mode-map)

But after moving up/down in the group buffer (C-p/C-n), the icon is
not updated (enabled/disabled) when changing from a group to a topic
line and vice versa.

After `C-l' (or after `redraw-frame' [3]), the correct icon is
displayed.  A workaround could be to redraw the frame after every
point-motion (is there a after-point-motion-hook?).

Bye, Reiner.

[1]
,----[ <f1> f gnus-group-group-name RET ]
| gnus-group-group-name is a compiled Lisp function in `gnus-group.el'.
| (gnus-group-group-name)
| 
| Get the name of the newsgroup on the current line.
`----

[2]
,----
| [ Gnus -- 6456 ]
|   [ misc -- 11 ]
|          1: nnml:test 
|         10: nndraft:drafts 
| [...]
`----

[3] Tested with...

(global-set-key (kbd "<down>")
		(lambda (&optional arg)
		  (interactive)
		  (or arg (setq arg 1))
		  (next-line arg)
		  (redraw-frame (selected-frame))))
-- 
       ,,,
      (o o)
---ooO-(_)-Ooo---  |  PGP key available  |  http://rsteib.home.pages.de/

^ permalink raw reply	[flat|nested] 21+ messages in thread

end of thread, other threads:[~2006-03-08 14:36 UTC | newest]

Thread overview: 21+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-01-23 18:59 tool bar icons not updated according to :active condition Reiner Steib
2006-02-24 15:23 ` Chong Yidong
2006-02-25  9:31   ` Reiner Steib
2006-02-25 23:30     ` Kim F. Storm
2006-02-26 19:39       ` Reiner Steib
2006-02-27  9:04         ` Kim F. Storm
2006-03-02 19:20           ` Reiner Steib
2006-03-05  0:58             ` Richard Stallman
2006-03-05 14:51               ` Reiner Steib
2006-03-05 20:55                 ` Stefan Monnier
2006-03-05 21:57                   ` Reiner Steib
2006-02-26 12:15     ` Reiner Steib
2006-02-26 14:28       ` Chong Yidong
2006-02-27 19:02       ` Richard Stallman
2006-02-28 14:53         ` Reiner Steib
2006-03-04 22:25           ` Kim F. Storm
2006-03-08 14:36             ` Reiner Steib
2006-02-28 14:59         ` Chong Yidong
2006-02-28 15:06           ` Reiner Steib
2006-03-01 17:55           ` Richard Stallman
2006-03-04 15:14             ` Chong Yidong

Code repositories for project(s) associated with this public inbox

	https://git.savannah.gnu.org/cgit/emacs.git

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).