all messages for Emacs-related lists mirrored at yhetil.org
 help / color / mirror / code / Atom feed
* mode-line-buffer-identification without restriction on width of buffer name
@ 2024-07-21 23:19 Heime
  0 siblings, 0 replies; only message in thread
From: Heime @ 2024-07-21 23:19 UTC (permalink / raw)
  To: Heime via Users list for the GNU Emacs text editor

Have been trying to remove the format restriction on the width
of the buffer name, but I cannot simply replace 

(concat " " (format-mode-line mode-line-buffer-identification))

with

(vodilac-buffer-name)

The mouse click effect to move to previous and to next buffer 
would not work.

(defun vodilac-buffer-name ()
  "Return `buffer-name' with spaces around it."
  (format " %s " (buffer-name)))

(defface vodilac-bfname-rotatif-facespk
  '((t :background "#ff4500"  ; Orange Red
       :foreground "#ffffff"  ; White
       :inherit mode-line-buffer-id)))

(defface prevodilac-inaktv-facespk
  `((t :background ,vodilac-dark-gray      ; "#222222"
       :foreground ,vodilac-light-gray)))  ; "#888888"


(defun vodilac-name-rotatif-face ()

  (if (mode-line-window-selected-p)
        'vodilac-bfname-rotatif-facespk
    'vodilac-inaktv-facespk))


(defface vodilac-mouse-facespk
  `((t :background ,vodilac-white         ; "#222222"
       :foreground ,vodilac-orange-red))  ; "#888888"
  "Face for Mouse Hover Effect in Modeline.")

(defvar-local vodilac-panelit-name-rotatif
  '(:eval
      (propertize
        (concat " " (format-mode-line mode-line-buffer-identification))
        'face (vodilac-name-rotatif-face)
        'mouse-face 'vodilac-mouse-facespk
        'help-echo "Click to select buffer")))

(put 'vodilac-panelit-name-rotatif 'risky-local-variable t)



^ permalink raw reply	[flat|nested] only message in thread

only message in thread, other threads:[~2024-07-21 23:19 UTC | newest]

Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2024-07-21 23:19 mode-line-buffer-identification without restriction on width of buffer name Heime

Code repositories for project(s) associated with this external index

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

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.