spacemacs icon indicating copy to clipboard operation
spacemacs copied to clipboard

Unable to use more than one custom theme

Open ishovkun opened this issue 7 years ago • 2 comments

Description :octocat:

<<DESCRIPTION OF THE PROBLEM>> I am unable to use more that one custom (local) theme in spacemacs.

Reproduction guide :beetle:

  • Start Emacs
  • I have the following theme-related lines in my .spacemacs:
dotspacemacs-themes
'((palenight :location local)
  (one-dark :location local)
  solarized-dark)
  • Only the first of these themes gets picked up whereas the other is not listed in the themes list.
  • When I you either of the themes and comment out the other everything works fine.

Observed behaviour: :eyes: :broken_heart: <<DESCRIPTION OF THE OBSERVED BEHAVIOUR>> Only one theme gets picked up by spacemacs

Expected behaviour: :heart: :smile: <<DESCRIPTION OF THE EXPECTED BEHAVIOUR>> All of my custom themes are picked up so I do not have to restart emacs in order to switch a theme.

System Info :computer:

  • OS: gnu/linux
  • Emacs: 26.1
  • Spacemacs: 0.300.0
  • Spacemacs branch: develop (rev. 4a9d53578)
  • Graphic display: t
  • Distribution: spacemacs
  • Editing style: hybrid
  • Completion: helm
  • Layers:
(html javascript cmake helm markdown semantic auto-completion better-defaults emacs-lisp git
      (latex :variables latex-enable-auto-fill nil)
      python
      (c-c++ :variables c-c++-enable-clang-support t)
      imenu-list ycmd spell-checking
      (auto-completion :variables auto-completion-enable-snippets-in-popup t auto-completion-enable-sort-by-usage t)
      org shell version-control)
  • System configuration features: XPM JPEG TIFF GIF PNG RSVG IMAGEMAGICK SOUND GPM DBUS GSETTINGS NOTIFY ACL GNUTLS LIBXML2 FREETYPE M17N_FLT LIBOTF XFT ZLIB TOOLKIT_SCROLL_BARS GTK3 X11 MODULES THREADS LIBSYSTEMD LCMS2

Backtrace :paw_prints:

<<BACKTRACE IF RELEVANT>>

ishovkun avatar Jun 28 '18 16:06 ishovkun

I came across the same problem. This has not been fixed yet. However, I found a way to make it work.

I did like (spacemacs/load-theme '(one-dark :location local)) in dotspacemacs/user-config then it worked.

lum1narie avatar Jan 28 '23 19:01 lum1narie

This issue has been automatically marked as stale because it has not had recent activity. It will be closed if no further activity occurs. Please let us know if this issue is still valid!

github-actions[bot] avatar May 01 '24 16:05 github-actions[bot]

This is still a valid issue.

bcc32 avatar Jul 14 '24 17:07 bcc32

I identified two problems:

  1. spacemacs/cycle-spacemacs-theme currently passes only the theme name to spacemacs/load-theme, however, it needs to pass the full (THEME-NAME :location ...) or whatever in order to set up load paths correctly. This causes SPC T n to break because it can't find the right files.
  2. (custom-available-themes) doesn't include any of the dotspacemacs-themes with :location local because they have not been added to custom-theme-load-path (except for the first one). This affects what themes are actually included in the SPC T s completion list. Also, even if they were included, those commands just call load-theme rather than spacemacs/load-theme, so they would still not find the files correctly.

bcc32 avatar Jul 14 '24 18:07 bcc32