[Top][All Lists]

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

Move `rcirc-activity-string' to beginning of mode-line

From: Thorsten Jolitz
Subject: Move `rcirc-activity-string' to beginning of mode-line
Date: Thu, 04 Jul 2013 15:44:33 +0200
User-agent: Gnus/5.130002 (Ma Gnus v0.2) Emacs/24.3 (gnu/linux)

Hi List, 

I often split windows vertically so that the mode-line is not fully
visible anymore, and thus the RCIRC activity-string - appended by
`rcirc-track-minor-mode' at the end of `global-mode-string', which itself
appears at the end of `mode-line-format' - is not visible anymore. 

#+begin_src emacs-lisp
  (define-minor-mode rcirc-track-minor-mode
    "Global minor mode for tracking activity in rcirc buffers.
  With a prefix argument ARG, enable the mode if ARG is positive,
  and disable it otherwise.  If called from Lisp, enable the mode
  if ARG is omitted or nil."
    ;; toggle the mode-line channel indicator
    (if rcirc-track-minor-mode
          (and (not (memq 'rcirc-activity-string global-mode-string))
               (setq global-mode-string
                     (append global-mode-string '(rcirc-activity-string))))

I would like to have this rcirc notifier at a more prominent place,
maybe even right at the beginning of the mode-line. I deleted
`rcirc-activity-string' from the 'global-mode-string' in my init-file
after loading rcirc and tried this

#+begin_src emacs-lisp
(setq mode-line-format
      (cons (car mode-line-format)
            (cons 'rcirc-activity-string (cdr mode-line-format))))

but it does not have any effect, maybe its overridden later on again? 

What would be the right way to move this `rcirc-activity-string' to the
beginning of the mode-line?


reply via email to

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