This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

Author epaine
Recipients epaine, gpolo, serhiy.storchaka
Date 2020-09-24.11:27:19
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1600946839.14.0.547852459363.issue41851@roundup.psfhosted.org>
In-reply-to
Content
I think it would be helpful to add these methods to the tkinter font class.

Starting with the equal method, I have found it very useful to be able to compare tkinter fonts based on their value rather than just name. I used this, for example, in #28694 to ensure the -font attribute had been changed correctly (though there I compared each of the attributes explicitly rather than using `.actual()` as I have in this patch).

The neg method, I think, would be very useful to allow easy conversion between points and pixels. For example:

points = Font(size=16)
pixels = -points
History
Date User Action Args
2020-09-24 11:27:19epainesetrecipients: + epaine, gpolo, serhiy.storchaka
2020-09-24 11:27:19epainesetmessageid: <1600946839.14.0.547852459363.issue41851@roundup.psfhosted.org>
2020-09-24 11:27:19epainelinkissue41851 messages
2020-09-24 11:27:19epainecreate