Opened 6 years ago
Closed 6 years ago
#2078 closed defect (fixed)
label colors not set/updated correctly
| Reported by: | Eric Pettersen | Owned by: | Tom Goddard |
|---|---|---|---|
| Priority: | moderate | Milestone: | 0.91 |
| Component: | Graphics | Version: | |
| Keywords: | Cc: | ||
| Blocked By: | Blocking: | ||
| Notify when closed: | Platform: | all | |
| Project: | ChimeraX |
Description
For both 2D and 3D labels, if the label color is not set then it is supposed to contrast with the label's own background color (if any) and otherwise the overall window background color. 3D labels with no background color of their own are the only ones that do this correctly. 3D labels with their own background always have black text, and 2D labels always initially contrast with the overall background regardless of their own background, and do not update when either background changes.
Note:
See TracTickets
for help on using tickets.
Fixed.
2D labels were not listening for graphics background color changes.
Both 2D and 3D labels incorrectly judged label background light/dark assuming RGB 0-1 values when actual values were 0-255.
Light background is defined as R + G + B > 1.5 where R,G,B are in range 0-1.