text widget: drag and drop
- From: "Ihug" <pc@xxxxxxxxxxxxxx>
- Date: Tue, 29 Nov 2005 17:08:03 +1300
I am trying to get drag and drop to work.
One thing I am trying to understand is when events get triggered - this
differs once the mouse button is depressed.
When the user moves the mouse over the various tags they are highlighted (as
per the Motion binding below).
When the user presses button-1 the drag gets initiated.
When the user releases button-1 the drop gets initiated.
The problem is once the button is pressed no more motion events get
triggered, hence nullifying the "drag" effect.
Can the text widget ($tw) be configured to activate motion events while the
buttons are pressed?
$tw tag bind $tag <Motion> "highlight_bar $t $tag_no"
$tw tag bind $tag <1> [list select_list_1 $t $tag_no "drag"]
$tw tag bind $tag <ButtonRelease-1> [list select_list_1 $t $tag_no "drop"]
.
- Follow-Ups:
- Re: text widget: drag and drop
- From: Bryan Oakley
- Re: text widget: drag and drop
- Prev by Date: Re: string handle problem
- Next by Date: Re: Where can I download tclodbc?
- Previous by thread: Expect timeout problem. I needs help.
- Next by thread: Re: text widget: drag and drop
- Index(es):