Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork7.9k
Description
I grew tired of having to convert my units just for the sake of specifying the figure size. I'd like to specify the figure size directly in a metric unit, nominally centimeters (or millimeters, no difference). In most EU countries metric is the norm. I only have to deal with inches when looking at monitor sizes, printing, and matplotlib :(
I've found at least two issues about this:#1369 and the more generic#9226.
Of course, having support for generic unit specifiers would be nice, but I'm not entirely satisfied by the extra complexity of#9226. I'm also thorn about (size, unit) tuples, because I don't ever think I'm going to specify the figure size in AU, or picometers. Cm is regularly used for anything that fits paper.
I see two cases where inches are specified in the rc:
- figure.figsize
- savefig.pad_inches
In the api, there is the figsize kwarg, I guess a pad_inches kwarg, and the set_size_inches method.
What abound the KISS approach: add a figsize_cm kwarg, pad_cm, and the set_size_cm method, and the two respective rcParams? Fully backward compatible, and allows metric countries to get by easily.
I could easily contribute such a patch.