473,386 Members | 1,668 Online
Bytes | Software Development & Data Engineering Community
Post Job

Home Posts Topics Members FAQ

Join Bytes to post your question to a community of 473,386 software developers and data experts.

Double Click Mouse Event in Tkinter

Creating a Windows application:
<Double-Button-1> mouse event has a conflict when there is also a
binding to the <Button-1> event. It seems like a silly oversight that
performing a double click will also initiate the single click action.

Has anyone figured out a way to circumvent this problem? Right now I am
making the Double click function undo the action my Single click
function does, but this is very annoying, especially since the action
that is bound to the Single click flashes for a second.

Jan 7 '06 #1
1 5258
"scott_gui" wrote:
Creating a Windows application:
<Double-Button-1> mouse event has a conflict when there is also a
binding to the <Button-1> event. It seems like a silly oversight that
performing a double click will also initiate the single click action.
If your design depends on your code being able to accurately figure out what
the user will do in the future, you may want to go back to the drawing board.
Has anyone figured out a way to circumvent this problem? Right now I am
making the Double click function undo the action my Single click
function does, but this is very annoying, especially since the action
that is bound to the Single click flashes for a second.


I don't think I've ever seen any recent application that does this (be-
cause all possible "solutions" are annoying), but I seem to recall that
the Explorer in some early version of Windows overloaded single and
double click actions by delaying the single click action (click and wait =
single click action, click and click = double click action).

To implement this in Tkinter, you can schedule an "after" task in the
Button-1 handler, and cancel it in the Double-Button-1 handler. But
a redesign is probably a better idea...

</F>

Jan 7 '06 #2

This thread has been closed and replies have been disabled. Please start a new discussion.

Similar topics

1
by: eltronic | last post by:
here is some code to add right click context menus. in the few apps I've edited sofar, it just works, once you run rCbinder with the root of the gui or bind B3 all present and future widgets will...
1
by: Sakharam Phapale | last post by:
Hi All, How to capture Mouse Single click and mouse double click event on Commnad Button. I am doing as follows. Private void Button1_MouseUp(Object sender,...
5
by: Nick | last post by:
Hey guys, I have 2 events on a windows forms datagrid, the mouse move as well as the double click events. What's happening is that when I double click on a row in the grid, the mouse move event...
2
by: scott_gui | last post by:
I am creating a Windows application: The mouse event <Double-Button-1> has a conflict when the <Button-1> event also has a binding. Double clicks will first perform the single click action. This...
1
by: Tuvas | last post by:
I am trying to execute a function with a tkinter event binding double click. With 2 mouse clicks done quickly, the function should happen, otherwise, it should not. However, I am noticing that the...
9
by: Armando | last post by:
I have an app (A2000) where I am letting the user move an object on the screen. I use the OnClick for a command button event to modify the object's Top (or Left) properties, but you can only click...
2
by: techsatish | last post by:
Hi, I want the double click event to call(here not able to get the MouseEventArgs) and execute the mouseup event code or any one tell me how to make my treecontrol double click nodes to behave...
3
by: Techsatish | last post by:
how to make a mouseup event called only once during a double click event? here double click is made on a tree node in a tree control. I have the code inside mouseup event....in runtime the...
0
by: Paul DeWitt | last post by:
I have a textbox on a Windows Form. I am wanting to display a popup form to request/validate info if the user clicks the textbox and have a different form (to delete data) load if the user either...
0
by: Charles Arthur | last post by:
How do i turn on java script on a villaon, callus and itel keypad mobile phone
0
by: aa123db | last post by:
Variable and constants Use var or let for variables and const fror constants. Var foo ='bar'; Let foo ='bar';const baz ='bar'; Functions function $name$ ($parameters$) { } ...
0
by: ryjfgjl | last post by:
If we have dozens or hundreds of excel to import into the database, if we use the excel import function provided by database editors such as navicat, it will be extremely tedious and time-consuming...
0
BarryA
by: BarryA | last post by:
What are the essential steps and strategies outlined in the Data Structures and Algorithms (DSA) roadmap for aspiring data scientists? How can individuals effectively utilize this roadmap to progress...
1
by: Sonnysonu | last post by:
This is the data of csv file 1 2 3 1 2 3 1 2 3 1 2 3 2 3 2 3 3 the lengths should be different i have to store the data by column-wise with in the specific length. suppose the i have to...
0
by: Hystou | last post by:
There are some requirements for setting up RAID: 1. The motherboard and BIOS support RAID configuration. 2. The motherboard has 2 or more available SATA protocol SSD/HDD slots (including MSATA, M.2...
0
by: Hystou | last post by:
Most computers default to English, but sometimes we require a different language, especially when relocating. Forgot to request a specific language before your computer shipped? No problem! You can...
0
Oralloy
by: Oralloy | last post by:
Hello folks, I am unable to find appropriate documentation on the type promotion of bit-fields when using the generalised comparison operator "<=>". The problem is that using the GNU compilers,...
0
jinu1996
by: jinu1996 | last post by:
In today's digital age, having a compelling online presence is paramount for businesses aiming to thrive in a competitive landscape. At the heart of this digital strategy lies an intricately woven...

By using Bytes.com and it's services, you agree to our Privacy Policy and Terms of Use.

To disable or enable advertisements and analytics tracking please visit the manage ads & tracking page.