all-the-icons.el icon indicating copy to clipboard operation
all-the-icons.el copied to clipboard

does these icons can show in frame title bar?

Open vinurs opened this issue 5 years ago • 9 comments

the icons is useful, and i want to show it in the frame title bar?

vinurs avatar Oct 20 '18 01:10 vinurs

AFAIK, it's possible on some platforms (i.e. Linux), try (setq frame-title-format (all-the-icons-icon-for-buffer)). On OSX, this is only possible since 26.2 and 27.1.

wyuenho avatar Feb 15 '19 01:02 wyuenho

i'm using 26.2, but this config doesn't work

vinurs avatar Apr 14 '19 10:04 vinurs

I'm using Emacs 26.1 on Ubuntu Linux with Spacemacs and the following seems to work. If you're not using Spacemacs you'll need to tweak it.

(defun cnb/title-prepare (title-format)
  (concat (spacemacs/title-prepare dotspacemacs-frame-title-format) " " (all-the-icons-icon-for-mode)))

(setq frame-title-format '((:eval
   (cnb/title-prepare dotspacemacs-frame-title-format))))

colbell avatar Apr 15 '19 07:04 colbell

i'm using macos 10.14.4, and my emacs is https://github.com/d12frosted/homebrew-emacs-plus and use spacemacs

vinurs avatar Apr 15 '19 08:04 vinurs

@vinurs Just telling people what doesn't work doesn't help. You need to tell people what you see, and possible why it doesn't work.

It could be that 1) you are actually using emacs 26.1 because that's what the homebrew formula installs by default in the link you provided, or 2) The icons actually display, but the wrong icon was shown. This could mean the frame's fontset on the Mac has not had the icon fonts appended/prepended. In which case you can see the troubleshooting guide in the README to fix your font. Just play around with the fontset names and character sets

wyuenho avatar Apr 16 '19 01:04 wyuenho

Hello, i work on macos, and install the emacs with: brew install emacs-plus --with-dbus --with-mailutils and now the emacs version is

$ brew info emacs-plus d12frosted/emacs-plus/emacs-plus: stable 26.2 (bottled), HEAD GNU Emacs text editor https://www.gnu.org/software/emacs/ /usr/local/Cellar/emacs-plus/HEAD-d9d9c32 (3,991 files, 130MB) * Built from source on 2019-04-19 at 17:38:59 with: --with-dbus --with-mailutils From: https://github.com/d12frosted/homebrew-emacs-plus/blob/master/Formula/emacs-plus.rb ==> Dependencies Build: pkg-config ✔ Recommended: little-cms2 ✔, gnutls ✔, librsvg ✔, imagemagick@6 ✔ Optional: dbus ✔, mailutils ✔, jansson ✘ ==> Requirements Optional: x11 ✘

then, i use spacemacs configuration,

(setq-default dotspacemacs-frame-title-format "^_^:%f")

and i my user-config file, i set the title:

(setq frame-title-format (all-the-icons-icon-for-buffer))

but the frame title shows: image

vinurs avatar Apr 29 '19 09:04 vinurs

So it's just showing the wrong icon. Have you tried adjusting the fontsets?

wyuenho avatar Apr 29 '19 17:04 wyuenho

I have the same issue as @vinurs . I tried the different fontsets. The icons are displayed correctly in the buffers, but not in the title bar.

seagle0128 avatar Apr 29 '19 18:04 seagle0128

@seagle0128 yes, it shows correctly in the buffer, but not in the title bar

vinurs avatar May 01 '19 01:05 vinurs