Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

IDLE: simplify, optimize, and clean up code context #81711

Closed
terryjreedy opened this issue Jul 9, 2019 · 5 comments
Closed

IDLE: simplify, optimize, and clean up code context #81711

terryjreedy opened this issue Jul 9, 2019 · 5 comments
Assignees
Labels
3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes topic-IDLE type-bug An unexpected behavior, bug, or error

Comments

@terryjreedy
Copy link
Member

BPO 37530
Nosy @terryjreedy, @taleinat, @csabella, @miss-islington
PRs
  • bpo-37530: simplify, optimize and clean up IDLE code context #14675
  • [3.8] bpo-37530: simplify, optimize and clean up IDLE code context (GH-14675) #14807
  • [3.7] bpo-37530: simplify, optimize and clean up IDLE code context (GH-14675) #14808
  • Note: these values reflect the state of the issue at the time it was migrated and might not reflect the current state.

    Show more details

    GitHub fields:

    assignee = 'https://github.com/terryjreedy'
    closed_at = <Date 2019-07-17.08:59:43.129>
    created_at = <Date 2019-07-09.17:44:47.305>
    labels = ['3.8', 'expert-IDLE', 'type-bug', '3.7', '3.9']
    title = 'IDLE: simplify, optimize, and clean up code context'
    updated_at = <Date 2019-07-17.08:59:43.128>
    user = 'https://github.com/terryjreedy'

    bugs.python.org fields:

    activity = <Date 2019-07-17.08:59:43.128>
    actor = 'taleinat'
    assignee = 'terry.reedy'
    closed = True
    closed_date = <Date 2019-07-17.08:59:43.129>
    closer = 'taleinat'
    components = ['IDLE']
    creation = <Date 2019-07-09.17:44:47.305>
    creator = 'terry.reedy'
    dependencies = []
    files = []
    hgrepos = []
    issue_num = 37530
    keywords = ['patch']
    message_count = 5.0
    messages = ['347568', '348000', '348049', '348051', '348052']
    nosy_count = 4.0
    nosy_names = ['terry.reedy', 'taleinat', 'cheryl.sabella', 'miss-islington']
    pr_nums = ['14675', '14807', '14808']
    priority = 'normal'
    resolution = 'fixed'
    stage = 'resolved'
    status = 'closed'
    superseder = None
    type = 'behavior'
    url = 'https://bugs.python.org/issue37530'
    versions = ['Python 3.7', 'Python 3.8', 'Python 3.9']

    @terryjreedy
    Copy link
    Member Author

    Issue for Tal's PR 14675, dependency of bpo-33610.

    1. Only create CodeContext instances for "real" editors windows, but not e.g. shell or output windows.
    • Previously, were created but never activated because menu item deactivated. This is even better.
    1. Remove configuration update Tk event fired every second, by having the editor window ask its code context widget to update when necessary, i.e. upon font or highlighting updates.

    2. When code context isn't being shown, avoid having a Tk event fired every 100ms to check whether the code context needs to be updated.

    3. Use the editor window's getlineno() method where applicable.

    4. Fix a bare except:.

    @terryjreedy terryjreedy added 3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes labels Jul 9, 2019
    @terryjreedy terryjreedy self-assigned this Jul 9, 2019
    @terryjreedy terryjreedy added topic-IDLE type-bug An unexpected behavior, bug, or error labels Jul 9, 2019
    @terryjreedy
    Copy link
    Member Author

    PR 14030 for bpo-17535 (line numbers) also has code for 1. I want to merge this first, and fix-up the other.

    Changing context font at the same time as the text font, instead of up to 1 second later, eliminates a visual glitch and is a user-visible improvement. Ditto for highlight changes, although the situation is more complicated due to text recoloring (a separate issue).

    @taleinat
    Copy link
    Contributor

    New changeset 7036e1d by Tal Einat in branch 'master':
    bpo-37530: simplify, optimize and clean up IDLE code context (GH-14675)
    7036e1d

    @miss-islington
    Copy link
    Contributor

    New changeset bb79ab8 by Miss Islington (bot) in branch '3.7':
    bpo-37530: simplify, optimize and clean up IDLE code context (GH-14675)
    bb79ab8

    @miss-islington
    Copy link
    Contributor

    New changeset 6cf7c45 by Miss Islington (bot) in branch '3.8':
    bpo-37530: simplify, optimize and clean up IDLE code context (GH-14675)
    6cf7c45

    @ezio-melotti ezio-melotti transferred this issue from another repository Apr 10, 2022
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
    Labels
    3.7 (EOL) end of life 3.8 only security fixes 3.9 only security fixes topic-IDLE type-bug An unexpected behavior, bug, or error
    Projects
    None yet
    Development

    No branches or pull requests

    3 participants