Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Printer friendly color scheme for sadf #205

Closed
mgierlings opened this Issue Dec 22, 2018 · 6 comments

Comments

Projects
None yet
2 participants
@mgierlings
Copy link

mgierlings commented Dec 22, 2018

First of all let me say thanks for creating sysstat, it is a great tool set.

While I personally like the SVG ouput produced by sadf (colored graph on dark background), it is not really suitable for (black/white) printing. I checked the sadf man page and did a web search but didn't find any option to enable a "light-background-mode" for sadf. Does sadf currently offer any way to generate printer friendly SVGs?

If no such feature exists, recoloring the graphs using image editing software could be a workaround. However I think it would be useful, if there was a way to natively produce printer friendly output with sadf. What do you think?

@sysstat

This comment has been minimized.

Copy link
Owner

sysstat commented Dec 23, 2018

This is the end of the year, and Santa Claus may actually add this new feature to next sysstat version! 😉

@mgierlings

This comment has been minimized.

Copy link
Author

mgierlings commented Dec 23, 2018

Nice, thank you Sebastien and Santa Claus of course =). Merry Christmas to you and the sysstat community.

@sysstat

This comment has been minimized.

Copy link
Owner

sysstat commented Jan 11, 2019

Commit d18e78c enables the user to select a different color palette for sadf SVG output, using a new option "customcol":
sadf -g -O customcol (...)
I'm not sure that this new palette is really printer friendly (though it is intended to be), so please test it and tell me which colors should be changed so that it can be printer friendly by default.
Here is a sample output:

image

Anyway this new palette will be fully customizable be the user (patches to come soon) so everybody should be able to find the right match for his need.

@mgierlings

This comment has been minimized.

Copy link
Author

mgierlings commented Jan 12, 2019

Thanks for the update. I think I'd definitely use a white background for the default printer scheme. I also converted your image to grey scale, to see how it would look on a non color printer here is the result
greyscale

(%usr, %guest, %gnice); (%steal, %iowait) and (%nice, %soft) are really hard to distinguish.

I found this post on graphicdesign stackexchange pretty helpful. It seems that picking the following colors from the bottom palette, plus black and white, might do the trick:

  • black (#000000)
  • the dark blue (circle 7) (#1A1AFF)
  • one purpleish tone (i.e. circle 8), (i.e. #B21AFF)
  • the red (circle 1, might need some tweaking if it is too similar to the purple) (#FF1A1A)
  • the light blue (circle 6) (#1AB2FF)
  • one darker greenish tone (circles 4, 5) (i.e. #1AFFB2)
  • the orange (circle 2) (#FFB31A)
  • the light green (circle 3) (#B2FF1A)
  • white (#FFFFFF)

Edit just realized, white would work for the bar since it has an outline, however it wont work for the chart legend, since white font on white background will not be visible

sysstat added a commit that referenced this issue Jan 13, 2019

sadf: SVG: Update custom color palette
Change default colors used for custom color palette.
Those colors should be better for black and white printers.
See #205.

Signed-off-by: Sebastien GODARD <sysstat@users.noreply.github.com>
@sysstat

This comment has been minimized.

Copy link
Owner

sysstat commented Jan 13, 2019

Commit 87320de adds a new black and white palette. I still think that some colors are hard to distinguish.
I also modified the default colors used by the custom palette to match your colors above (see commit 4cd46fa). One color (used for %gnice) is almost white and hardly visible though.
Sample outputs:

Black and white palette ("sadf -g -O bwcol (...)"):
image

Custom palette with updated colors ("sadf -g -O customcol (...)"):
image

And the default palette ("sadf -g (...)"):
image

@mgierlings

This comment has been minimized.

Copy link
Author

mgierlings commented Jan 16, 2019

This looks very good to me, thank you for the effort. I think there is only so much we can do with grey scale. For many occasions it will be sufficient to use less then nine graphs in a single chart so the barely readable light grey should not become a problem too often.

@sysstat sysstat closed this Jan 20, 2019

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
You can’t perform that action at this time.