This patch adds the ability to theme the amount of color difference of every other row in the outliner. The option appears as a color with alpha in the outliner section of the theme settings. The color is lightly overlayed onto every other row in the outliner. Previously, every other row was hard-coded to be 6 values brighter than their adjecent rows. With this patch, users have more control over the difference in color. For example, a user could choose to remove the color difference between the rows (by making this option transparent) and have a solid background color in the outliner.
Details
- Reviewers
Pablo Vazquez (pablovazquez) Brecht Van Lommel (brecht) Campbell Barton (campbellbarton) - Group Reviewers
User Interface
Diff Detail
- Repository
- rB Blender
Event Timeline
Functionality wise is a +1. I'm usually against adding new theme settings (we have so many), but this one helps readability and even allows disabling the overlay altogether.
The only thing I'm not sure about is the name of the variable TH_ROW_OVERLAY, but I'll leave that to developers. What do you think @Brecht Van Lommel (brecht)?
This setting could even be introduced in the future for other editors with odd/even rows like the file browser.
| source/blender/editors/interface/resources.c | ||
|---|---|---|
| 798 | Not sure about the name TH_ROW_OVERLAY, since it doesn't overlay all rows. Wouldn't it be more like variation? odd? interleaved? TH_ROW_VARIATION TH_ROW_ODD TH_ROW_INTERLEAVE Keeping in mind this could be used for the file browser as well. | |
This is missing updates for existing preferences in versioning_userdef.c.
See D4650: For Discussion - Small Outliner Changes for an example of how to do that.
Renamed the variables to row_alternating and TH_ROW_ALTERNATING
Modified versioning_userdef.c to reflect the theme option
Thanks, committed rB68c12c80e501803f88b62f5f6f0f6a56bb53f303
Minor changes:
- Don't scale alpha by 0.2 (adjust alpha in theme instead).
- Use term alternate has same meaning and is shorter.
- Bump version in BKE_blender_version.h.