Skip to content
This repository was archived by the owner on Apr 16, 2026. It is now read-only.
This repository was archived by the owner on Apr 16, 2026. It is now read-only.

Zenburn Theme Background problems #6180

Closed

Description

@thaxyz

Zenburn Theme: background ccss doesn't apply after default css is loaded.

.cm-s-zenburn {...}
Modify with
.cm-s-zenburn, .cm-s-zenburn.CodeMirror {...}

zenburn.zip

Activity

  1. marijnh commented on Mar 17, 2020

    @marijnh
    Member

    Could you be more clear? How is the zenburn theme different from the others? At a glance, they seem to use the same level of specificity.

  2. thaxyz commented on Mar 17, 2020

    @thaxyz
    Author

    In my CM interface, I have made a <Select> which allows to choose the theme. Thus, it changes without reloading the editor (using .setOption("theme", <theme>).
    At page load, I load the "default" theme.
    When I change theme, the Zenburn options of class ".cm-s-zenburn" are not applied (most others work fine).
    Thus, it misses global background and foreground colors.
    By checking in other themes, I saw that they did not use ".cm-s-<theme>" for the global BG/FG but the class definition " .cm-s-<theme>.CodeMirror".
    After making the mod in the Zenburn.css, it works fine.

    Using CM v 5.52.0

    I did not check for every theme, as I wanted to use Zenburn.

    :-)

  3. marijnh commented on Mar 18, 2020

    @marijnh
    Member

    That makes sense. Applied in attached patch.

  4. added a commit that references this issue on Oct 31, 2020
    14d7274
  5. added a commit that references this issue on Sep 5, 2024
    e7b2c64
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions