GV

GeezerVison

The World Wide Web, restored to 800 pixels of glory.

Home|About|Gaming cabinet|Archives|How it works|Starter sites

On this site

  • Sign in
  • ActionsCI/CD and automation
  • CodespacesCloud development environments
  • All Features
  • Documentation
  • Training
  • Certifications
  • Build with Copilot
  • Customize Copilot
  • Integrations
  • Trending repos
  • GitHub Sponsors
  • Developer articles
  • Enterprises

This view

  • Original page
  • New address

GeezerVison is showing github.com — IDLE uses incorrect screen dimension units · Issue #120104 · python/cpython

IDLE uses incorrect screen dimension units #120104

New issue
Copy link
New issue
Copy link
Closed
#122740
Closed
IDLE uses incorrect screen dimension units#120104
#122740
Copy link
Labels
topic-IDLEtype-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error

Description

@serhiy-storchaka
serhiy-storchaka
opened on Jun 5, 2024
Issue body actions

In two places IDLE uses incorrect unit for screen dimension:

cpython/Lib/idlelib/configdialog.py

Line 114 in 983efcf

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

cpython/Lib/idlelib/searchbase.py

Line 89 in 983efcf

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

  • gh-120104: IDLE: Fix padding in config and search dialogs #120107
  • [3.13] gh-120104: IDLE: Fix padding in config and search dialogs (GH-120107) #122740
  • [3.12] gh-120104: IDLE: Fix padding in config and search dialogs (GH-120107) #122741

Activity

  1. serhiy-storchaka
    added
    3.12only security fixesonly security fixes
    3.13only security fixesonly security fixes
    3.14bugs and security fixesbugs and security fixes
    on Jun 5, 2024
  2. serhiy-storchaka
    added this to IDLE Issueson Jun 5, 2024
  3. Eclips4
    added
    topic-IDLE
    on Jun 5, 2024
  4. serhiy-storchaka
    added a commit that references this issue on Jun 5, 2024

    pythongh-120104: IDLE: Fix padding in config and search dialogs

    4f6e57c
  5. terryjreedy commented on Jun 5, 2024

    @terryjreedy
    terryjreedy
    on Jun 5, 2024
    Member
    More actions

    Both of those are ttk Frames PRs originally authored by Mark Roseman in 2020 for issue #78168. I would prefer consistently using pixels. I will check later to see the effect of just removing 'p' and if I prefer (as I suspect) increasing the number.

  6. terryjreedy commented on Aug 2, 2024

    @terryjreedy
    terryjreedy
    on Aug 2, 2024
    Member
    More actions

    Since pixels are smaller than points, the result is slightly smaller padding in various places, but it looks fine to me. So I will leave the patch as is.

  7. terryjreedy
    added a commit that references this issue on Aug 6, 2024

    gh-120104: IDLE: Fix padding in config and search dialogs (#120107)

    4b66b6b
  8. miss-islington
    added 2 commits that reference this issue on Aug 6, 2024

    pythongh-120104: IDLE: Fix padding in config and search dialogs (pyth…

    1c8833f

    pythongh-120104: IDLE: Fix padding in config and search dialogs (pyth…

    00dc108
  9. terryjreedy
    linked a pull request that will close this issue[3.13] gh-120104: IDLE: Fix padding in config and search dialogs (GH-120107) #122740on Aug 6, 2024
  10. terryjreedy
    added a commit that references this issue on Aug 6, 2024

    [3.12] gh-120104: IDLE: Fix padding in config and search dialogs (GH-…

    81bed0f
  11. terryjreedy
    added
    type-bugAn unexpected behavior, bug, or errorAn unexpected behavior, bug, or error
    and removed
    3.12only security fixesonly security fixes
    3.13only security fixesonly security fixes
    3.14bugs and security fixesbugs and security fixes
    on Aug 6, 2024
  12. brandtbucher
    added a commit that references this issue on Aug 7, 2024

    pythongh-120104: IDLE: Fix padding in config and search dialogs (pyth…

    41808d7
  13. blhsing
    added a commit that references this issue on Aug 22, 2024

    pythongh-120104: IDLE: Fix padding in config and search dialogs (pyth…

    2e844ee
  14. Yhg1s
    added a commit that references this issue on Sep 27, 2024

    [3.13] gh-120104: IDLE: Fix padding in config and search dialogs (GH-…

    4a58bdb
  15. terryjreedy
    closed this as completedon Sep 28, 2024
  16. github-project-automation
    moved this to Done in IDLE Issueson Sep 28, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

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

    Projects

    • IDLE Issues
      Status
      Done
      Show more project fields

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

    You are visitor 01402520 — GeezerVison does not store the pages you look up.
    Best viewed with Netscape Navigator 4.7 or Internet Explorer 6 at 800×600. No cookies required.