Skip to content

Conversation

@neiljp
Copy link
Collaborator

@neiljp neiljp commented Mar 21, 2023

What does this PR do?

There are currently 3 open PRs (#1300, #1175, #324) for solarized dark, so I've taken the most complete (#1175) and added extra commits such that this runs and is usable with current ZT.

In doing so, the extra commits address my outstanding concerns regarding #1175.

I'm going to close the other PRs, though they can still be referenced.

While this is broadly usable as it is, there are various factors that it'd be good to address before merging:

  • validate colors at lower bit depths (ie. 16 or 256 colors) approximate those at 24bit depth; there is various discussion (Themes: Add preliminary "dark solarized" theme. #324) regarding this, though the code layout is different in that PR
  • avoid using palette entries inappropriate to the dark theme (specifically from the light theme)
  • manual validation that styled elements are all reasonably legible

Compared to #1175, my update to use dark-theme aliases in the enum breaks the addition of BOLD to the colors, so we could explore an alternative to that, as discussed in my commit.

When building upon this PR (see tools/fetch-pull-request), please keep commits separate on top for comparison, at least initially, since there will be multiple authors.

Tested?

  • Manually
  • Existing tests (adapted, if necessary)
  • New tests added (for any new behavior)
  • Passed linting & tests (each commit)
siddharthc30 and others added 4 commits March 21, 2023 10:34
Remove unnecessary import. Capitalize colors, as they are constants. Add some colors, to include full Solarized palette (data needs confirmation). Add aliases to foreground/background colors for dark/light themes, to avoid using incorrect palette entries in those themes. NOTE: We could extract the duplicate entries further into other enums, as I suggested in zulip#1175, or as constants outside of the enum, but this works for now.
Adds solarized to complete themes tests; renames style name to pass tests. Updates colors to use capitalized names, and translate from specific names to aliases which enable clear use in the theme. Various color changes made to improve to basic level of legibility. Solarized removed from theme aliases (not an old theme). Fixes still required: - still uses colors from the light theme that it is not supposed to use - needs a lot of checking of colors for best consistency different bit-depths - visual inspection during regular usage, ie. selection of good colors per UI element - syntax highlighting section needs validation (may be greatly simplified)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

area: colors/styles/themes size: XL [Automatic label added by zulipbot]

3 participants