Skip to content

[themes] Put theme configuration to settings.json #7358

Closed

Description

@Tyriar

Having a theme/currentTheme key that could be set in settings.json would be useful in automatically setting the theme in an automated setup. I'm assuming right now it's handled in local storage or something instead?

Activity

  1. added
    *question
    themes
    on Jun 7, 2016
  2. aeschli commented on Jun 8, 2016

    @aeschli
    Contributor

    Yes, part of your workbench settings that know about recently opened VSCode input, window sizes, cursor positions.
    We could put that in the settings. Would we remove it from the File>Preferences menu then? We would loose the theme previewing. If we keep it we would have to ask the user of where to define the theme in user or workbench settings.

  3. added
    feature-request
    and removed
    *question
    on Jun 8, 2016
  4. changed the title [-]Why is the current theme handled outside of settings.json[/-] [+][themes] Put theme configuration to settings.json[/+] on Jun 8, 2016
  5. Tyriar commented on Jun 8, 2016

    @Tyriar
    ContributorAuthor

    Couldn't the theme preview just live update the settings.json?

  6. aeschli commented on Jun 8, 2016

    @aeschli
    Contributor

    Which one? User or workspace settings?

  7. Tyriar commented on Jun 9, 2016

    @Tyriar
    ContributorAuthor

    Martin Aeschlimann (@aeschli) well it would be weird to have a workspace-associated theme, so user. Good point though that there would be a bit of weirdness there. In the end I think it would be good to be able to script your entire vscode setup, themes are the main missing piece in that now that extensions can be installed via the CLI.

  8. gerane commented on Jun 17, 2016

    @gerane

    I say you keep the two synced. I'd like to have that ability.

  9. isvoboda commented on Jul 26, 2016

    @isvoboda

    Daniel Imms (@Tyriar) actually there are situations when theme per workspace makes sense -- I am dealing with the reduced color pallet in the default light+ and dark+ themes which forced me to switch the theme every time I am working with different types of code i.e. workspace.

  10. siegebell commented on Oct 6, 2016

    @siegebell

    When developing extensions, I often have two vscode instances running (sometimes four!) and it would be very helpful if I could quickly distinguish them by assigning each a different theme.

  11. Jackbennett commented on Dec 6, 2016

    @Jackbennett

    To add some use cases, I'd like the set the theme per workstation for our environment. I specifically want to mandate a light theme because our users screenshot examples from VSCode and it'd save a lot of toner. But I appreciate that's quite specific. If you add printing support you might also want the ability to use a specific print theme.

    Perhaps a workstation.json can be superseded by the settings.json which as currently is superseded by the workspace.json?

    I think the quickest improvement would be to add the theme key to settings.json which takes precedence over storage.json. I currently create a fixed settings.json with a GPO to preset other things, it's easy enough for admins to copy across settings they want to keep.

  12. cheapsteak commented on Jan 6, 2017

    @cheapsteak

    it would be weird to have a workspace-associated theme

    I actually found this thread because I was trying to figure out how to get a workspace-associated theme. I'm quite frequently working on multiple projects and being able to associate a specific project's editor window with a particular color would be incredibly helpful

  13. steveinatorx commented on Jan 21, 2017

    @steveinatorx

    this would be a killer feature.

  14. atmd83 commented on Jan 26, 2017

    @atmd83

    just setting up a new machine after putting my settings.json in source control to maintain across boxes. Having the theme 'settable' from settings.json seems a really worthwhile feature (as well as the icon theme)

    is automatically installing a theme from the market place if it isn't currently installed (and set in settings.json) too big a step?

  15. added
    plan-item
    on Feb 9, 2017
  16. hashhar commented on Feb 9, 2017

    @hashhar
    Contributor

    Could it be implemented with an additional setting key called "saveThemeTo" with the values, "user", "workspace" to decide where to make changes by default during live preview?

    Also, what are the scenarios when the "theme" setting would need to be auto-changed? Just when live-previewing I guess?

    EDIT

    Another mechanism can be changing the "theme" in user settings unless a "theme" has been specified in workspace settings.
    If a theme has been specified in worskspace settings, update both when live-previewing?

    The dirtiest but easiest way would be to obviously add two different menu items.

  17. aeschli commented on Feb 21, 2017

    @aeschli
    Contributor

    Theme configuration is now part of the settings:

      // Specifies the color theme used in the workbench.
      "workbench.colorTheme": "Default Dark+",
    
      // Specifies the icon theme used in the workbench.
      "workbench.iconTheme": null,
    

    It can be configured as a user and also as a workspace setting.

  18. shanalikhan commented on Feb 21, 2017

    @shanalikhan

    So i can get all the installed file icons and themes both from iterating in the extensions ?
    (vscode.extension.all.forEach(e => e.packageJSON.contributes ....)

    And set current via settings.json !

  19. aeschli commented on Feb 21, 2017

    @aeschli
    Contributor

    Yes, in the packageJSON you find all contributed themes & icon theme including the path to the theme file and icon theme file.

  20. locked and limited conversation to collaborators on Nov 18, 2017
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Labels

feature-requestplan-itemthemes

Type

No type

Projects

No projects

    Milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions