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

Entry Widget Not Editable under Windows XP with dialog call. #53882

Closed
firatozgul mannequin opened this issue Aug 24, 2010 · 5 comments
Closed

Entry Widget Not Editable under Windows XP with dialog call. #53882

firatozgul mannequin opened this issue Aug 24, 2010 · 5 comments
Labels
OS-windows topic-tkinter type-bug An unexpected behavior, bug, or error

Comments

@firatozgul
Copy link
Mannequin

firatozgul mannequin commented Aug 24, 2010

BPO 9673
Nosy @terryjreedy

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 = None
closed_at = <Date 2014-05-18.23:16:57.827>
created_at = <Date 2010-08-24.17:49:40.901>
labels = ['type-bug', 'expert-tkinter', 'OS-windows']
title = 'Entry Widget Not Editable under Windows XP with dialog call.'
updated_at = <Date 2021-01-09.00:18:23.998>
user = 'https://bugs.python.org/firatozgul'

bugs.python.org fields:

activity = <Date 2021-01-09.00:18:23.998>
actor = 'terry.reedy'
assignee = 'none'
closed = True
closed_date = <Date 2014-05-18.23:16:57.827>
closer = 'terry.reedy'
components = ['Tkinter', 'Windows']
creation = <Date 2010-08-24.17:49:40.901>
creator = 'firatozgul'
dependencies = []
files = []
hgrepos = []
issue_num = 9673
keywords = []
message_count = 5.0
messages = ['114800', '114805', '114812', '218765', '384701']
nosy_count = 4.0
nosy_names = ['terry.reedy', 'gpolo', 'firatozgul', 'claird']
pr_nums = []
priority = 'normal'
resolution = 'third party'
stage = 'resolved'
status = 'closed'
superseder = None
type = 'behavior'
url = 'https://bugs.python.org/issue9673'
versions = ['Python 2.6']

@firatozgul
Copy link
Mannequin Author

firatozgul mannequin commented Aug 24, 2010

In a Tkinter application that has an Entry() widget on the main window and an askopenfilename() dialog, one should be able to click and type into the Entry() widget as soon as the askopenfilename() dialog is closed. However, the askopenfilename() dialog renders the Entry() widget on the main window unusable/non-editable.

This issue was explored in http://mail.python.org/pipermail/tkinter-discuss/2010-August/002332.html at Tkinter-Discuss mailing list. All details relating to the issue can be followed from there.

It seems that only Windows OS is affected by this issue. In Ubuntu Karmic Koala (GNOME) and Debian (IceWM), at least, this issue cannot be reproduced, and everything works like expected.

@firatozgul firatozgul mannequin added topic-tkinter OS-windows type-bug An unexpected behavior, bug, or error labels Aug 24, 2010
@claird
Copy link
Mannequin

claird mannequin commented Aug 24, 2010

If it'll help, I can translate this to Tcl/Tk, and report it to the Tk maintainers.

My first impression, which is in the realm of wild speculation, is that this is a Tk defect which has already been corrected. A bit more care in composition of a homologous Tk-coded example should swiftly confirm or falsify that proposition.

@firatozgul
Copy link
Mannequin Author

firatozgul mannequin commented Aug 24, 2010

That sounds nice.

@terryjreedy
Copy link
Member

The reverenced post did not give a runnable minimal example with the claimed bug, but only described more complex code at a now dead link. The following from http://effbot.org/tkinterbook/entry.htm works on my Win7 machine.

import tkinter as tk
master = tk.Tk()
e = tk.Entry(master)
e.pack()
e.focus_set()
def callback():
    print(e.get())
b = tk.Button(master, text="get", width=10, command=callback)
b.pack()
tk.mainloop()

@terryjreedy
Copy link
Member

My testing was inadequate. From bpo-42867, it appears that 0. the bug is limited to Windows; 1. opening a canned dialog or message box is part of getting the buggy behavior; 2. timing is involved; 3. the bug can be exhibited on Windows directly with wish/tk, so that it is a 3rd party tcl/tk issue and not a tkinter issue. Hence changing the issue resolution.

A workaround mentioned in both the referenced tkinter thread and bpo-42867 is to call after_idle() at some point.

@terryjreedy terryjreedy changed the title Entry Widget Not Editable under Windows XP Entry Widget Not Editable under Windows XP with dialog call. Jan 9, 2021
@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
OS-windows topic-tkinter type-bug An unexpected behavior, bug, or error
Projects
None yet
Development

No branches or pull requests

1 participant