Fix for the graph scale text colour changing depending on graph position #1957
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Checklist
Description
In the current latest code of conky, when you have a graph scale enabled, the text will change colour whenever a "high point" on the graph reached the "end" of the graph. It's difficult to describe so I took some screenshots:
Before
The scale text changes colour to whatever the colour of the leftmost "bar" of the graph is.
After
No longer does this
I'm not sure if this was an intended feature, if it was, feel free to close this. imo it shouldn't change colour because it makes the text very hard to read when the whole graph is full of red.
It's a simple fix, just adding one extra line to change the colour back to the "first" graph colour (i.e. the colour of the lowest values)
There shouldn't be any unintended side effects of the change, because looking at the code, this is the last if statement in a block, and right after the if statements, the colour gets changed anyway (
set_foreground_color(last_colour);
)