- Remove the inline feature detection, it doesn't work for features of
dependencies. Instead use `required-features` in `Cargo.toml` for the
specific binary.
- The asset moved one level up relatively to `../../assets/style.toml`
* Expanded on API for Checkbox and for Enabled.
Added a `with_x` variant to both, for easier chaining.
* Added enabled/disable macro support to everything with an enabled/disabled method.
This also gives them `with_enabled`, but more importantly, keeps things tidy
You generally want to stick to default colors because of terminal color
schemes. If you don't, you risk getting suboptimal contrast and
difficult-to-read text. When you _do_ want to peg something to a color,
you need to fully specify the foreground and background to ensure you
have enough contrast for text to be readable.
Our project, below
(https://github.com/facebookincubator/resctl/tree/master/resctl/below),
wants to set a less jarring highlight color than red. In order to
effectively do this, we need a way to specify the highlighted text color
without causing a cascade of pegged colors. In other words, if we were
to manually set PaletteColor::View, we would need to manually set
everything PaletteColor::View is `ColorStyle`'d with, and so forth.
I realize this is an API breaking change. I spent some time considering
alternatives (such as detecting whether or not `HighlightText` is set,
and if not, use `View` as the highlighted text color). The problem with
the other options is that you'd need to:
1) Document the fallback behavior
2) Maintain backwards compat code paths
Seeing as cursive is pre-1.0 release, I figure this is the best way
forward.
This change fixes cursive issue #428, caused by indexing into an empty
list. The issue is corrected by using the .get() method to safely
handle the case where the requested index doesn't exist, and renders
no label in that case.
Change the tertiary color in the default theme to white instead of grey.
Currently, the tertiary color is the same as the view background color,
making it invisible as foreground color. This makes the Outset effect
not work as (I think) intended.