Re: Drag and Drop in Tkx

[email protected] (Jeff Hobbs)
Newsgroups perl.tcltk
Message-ID <[email protected]>
On 11/09/2009 6:20 AM, Laurence Anthony wrote:
> I've seen  both the BWidgets and Tkdnd documentation before on the Tcl
> pages. But, moving this to a Perl Tkx environment doesn't seem that easy.
> For example, how do we create a standalone application in Tkx that uses the
> Tkdnd package. Is it possible? Do the solutions also imply that
> drag-and-drop will not work for the new Tile widgets unless Tkdnd is
> employed?
>
> Saying that, implementing a nice BWidgets drag-and-drop example in Tkx would
> be a good start. I'll try and do this when I get some extra time.

Yes, tkdnd could be added to a standalone app, inserted into the tkkit 
if you use ActivePerl/PDK, or otherwise as I believe Vadim has an 
alternative solution.  For tkkit, I have posted instructions to this 
list before about adding modules.  It does require an ActiveTcl 
installation (although it would be possible within Tkx itself ... it's 
slightly more complicated than the Tcl script I sent).

The BWidget dnd model would work with Ttk (tile / themed Tk), but you 
would have to extend the code for that.  Tkdnd is a C-based extension 
that works (via overlay bindings) for any widget, but also ties directly 
in to the native dnd for the platform.  It's not yet ported to OS X, but 
someone is working on it.

Jeff
lmpx.com only provides a reader for public news (NNTP) servers. It is not affiliated with the servers or forums shown here and is not responsible for the content of articles, which is written by their respective authors.