The --retina argument is convenient to set a device scale factor of 2, but for my use case I needed a variety of scale factors to match other displays.
Ref: #133
For example, Google Pixel 6 has a scale factor of 2.625. Some devices go up to 4.
My proposal is to add an additional argument, --scale-factor, that takes a float as argument, and is None by default.
To avoid confusion when using --retina and --scale-factor simultaneously, we could treat them as mutually exclusive and raise a helpful error. We can also check that the scale factor is positive.
A reusable function that validates and normalises the device scale factor provides the opportunity to validate other scale-factor-altering arguments in the future, such as the --device argument proposed in #129.
The
--retinaargument is convenient to set a device scale factor of2, but for my use case I needed a variety of scale factors to match other displays.Ref: #133
For example, Google Pixel 6 has a scale factor of
2.625. Some devices go up to4.My proposal is to add an additional argument,
--scale-factor, that takes a float as argument, and isNoneby default.To avoid confusion when using
--retinaand--scale-factorsimultaneously, we could treat them as mutually exclusive and raise a helpful error. We can also check that the scale factor is positive.A reusable function that validates and normalises the device scale factor provides the opportunity to validate other scale-factor-altering arguments in the future, such as the
--deviceargument proposed in #129.