8000 IDLE uses incorrect screen dimension units · Issue #120104 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content
IDLE uses incorrect screen dimension units #120104
Closed
@serhiy-storchaka

Description

@serhiy-storchaka

In two places IDLE uses incorrect unit for screen dimension:

self.frame = frame = Frame(self, padding="5px")

self.frame = Frame(top, padding="5px")

It uses "5px", but the only documented valid suffixes are "c", "i", "m" and "p". Tk ignores the rest in versions < 8.7, but in 8.7 and 9.0 this is an error. And this is for good, because "px" did not mean pixels, as was expected, but printer's points (1/72 inch).

If we want to keep the same look, we should change "px" to "p". But if it originally should be in pixels, we should remove the suffix. In all other places padding is specified in pixels, and this makes sense, so I believe the latter option is better.

Linked PRs

Metadata

Metadata

Assignees

No one assigned

    Labels

    topic-IDLEtype-bugAn unexpected behavior, bug, or error

    Projects

    Status

    Done

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0