michaelrsweet / pappl

PAPPL - Printer Application Framework
https://www.msweet.org/pappl
Apache License 2.0
309 stars 49 forks source link

Fix darkness calculation in web interface #333

Closed proski closed 9 months ago

proski commented 9 months ago

Round stored percent values to the closest hardware darkness value.

proski commented 9 months ago

The original code would only preserve 0%, 20%, 40%, 60%, 80% and 100% for TSPL driver with 16 darkness levels. Other values would slide one step towards 0% on every save.

michaelrsweet commented 9 months ago

OK, I've re-tested and agree.

michaelrsweet commented 9 months ago

[master 7a395b9] Round darkness value (Issue #333)

[v1.4.x 8f62251] Round darkness value (Issue #333)