Changeset - r24654:66b379079421
[Not reviewed]
master
0 1 0
Patric Stout - 3 years ago 2021-01-13 13:55:55
truebrain@openttd.org
Change: darken the background of all graph to increase contrast (#8557)

Now lines like Mauve, Dark Green and Purple are much more visible
without hurting the other colours.
1 file changed with 3 insertions and 0 deletions:
0 comments (0 inline, 0 general)
src/graph_gui.cpp
Show inline comments
 
@@ -322,12 +322,15 @@ protected:
 
		r.bottom = r.top + y_sep * num_hori_lines;
 

	
 
		OverflowSafeInt64 interval_size = interval.highest + abs(interval.lowest);
 
		/* Where to draw the X axis. Use floating point to avoid overflowing and results of zero. */
 
		x_axis_offset = (int)((r.bottom - r.top) * (double)interval.highest / (double)interval_size);
 

	
 
		/* Draw the background of the graph itself. */
 
		GfxFillRect(r.left, r.top, r.right, r.bottom, GREY_SCALE(2));
 

	
 
		/* Draw the vertical grid lines. */
 

	
 
		/* Don't draw the first line, as that's where the axis will be. */
 
		x = r.left + x_sep;
 

	
 
		for (int i = 0; i < this->num_vert_lines; i++) {
0 comments (0 inline, 0 general)