annotate man/lispref/dragndrop.texi @ 288:e11d67e05968 r21-0b42

Import from CVS: tag r21-0b42
author cvs
date Mon, 13 Aug 2007 10:35:54 +0200
parents 558f606b08ae
children c9fe270a4101
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
1 @c -*-texinfo-*-
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
2 @c This is part of the XEmacs Lisp Reference Manual.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
3 @c Copyright (C) 1998 Oliver Graf <ograf@fga.de>
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
4 @c Original reference is (c) 1990, 1991, 1992, 1993, 1994 Free Software Foundation, Inc.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
5 @c See the file lispref.texi for copying conditions.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
6 @setfilename ../../info/dragndrop.texi
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
7 @node Drag'n'Drop, Modes, Scrollbars, Top
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
8 @chapter Drag'n'Drop
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
9 @cindex drag'n'drop
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
10
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
11 @emph{WARNING}: the Drag'n'Drop API is still under development and the
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
12 interface may change!
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
13
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
14 Drag'n'drop is a way to transfer information between multiple applications.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
15 To do this serveral GUIs define their own protocols. Examples are OffiX, CDE,
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
16 Motif, KDE, MSWindows, GNOME, and many more. To catch all these protocols,
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
17 XEmacs provides a generic API.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
18
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
19 One prime idea behind the API is to use a data interface that is
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
20 transparent for all systems. The author thinks that this is best
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
21 archived by using URL and MIME data, cause any internet enabled system
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
22 must support these for email already. XEmacs also already provides
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
23 powerful interfaces to support these types of data (tm and w3).
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
24
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
25 @menu
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
26 * Supported Protocols:: Which low-level protocols are supported.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
27 * Drop Interface:: How XEmacs handles a drop from another application.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
28 * Drag Interface:: Calls to initiate a drag from XEmacs.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
29 @end menu
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
30
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
31 @node Supported Protocols
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
32 @section Supported Protocols
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
33
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
34 The current release of XEmacs only support a small set of Drag'n'drop
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
35 protocols. Some of these only support limited options avaiable in the API.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
36
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
37 @menu
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
38 * OffiX DND:: A generic X based protocol.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
39 * CDE dt:: Common Desktop Environment used on suns.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
40 * MSWindows OLE:: Mr. Gates way of live.
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
41 * Loose ends:: The other protocols.
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
42 @end menu
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
43
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
44 @node OffiX DND
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
45 @subsection OffiX DND
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
46 @cindex OffiX DND
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
47
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
48 The OffiX Drag'n'Drop protocol is part of a X API/Widget library created by
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
49 Cesar Crusius. It is based on X-Atoms and ClientMessage events, and works with
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
50 any X platform supporting them.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
51
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
52 OffiX is supported if 'offix is member of the variable dragdrop-protocols, or
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
53 the feature 'offix is defined.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
54
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
55 Unfortunately it uses it's own data types. Examples are: File, Files,
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
56 Exe, Link, URL, MIME. The API tries to choose the right type for the data that
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
57 is dragged from XEmacs (well, not yet...).
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
58
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
59 XEmacs supports both MIME and URL drags and drops using this API. No application
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
60 interaction is possible while dragging is in progress.
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
61
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
62 For infomation about the OffiX project have a look at http://leb.net/~offix/
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
63
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
64 @node CDE dt
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
65 @subsection CDE dt
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
66 @cindex CDE dt
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
67
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
68 CDE stands for Common Desktop Environment. It is based on the Motif
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
69 widget library. It's drag'n'drop protocol is also an abstraction of the
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
70 Motif protocol (so it might be possible, that XEmacs will also support
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
71 the Motif protocol soon).
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
72
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
73 CDE has three different types: file, buffer, and text. XEmacs only uses
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
74 file and buffer drags. The API will disallow full URL drags, only file
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
75 method URLs are passed through.
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
76
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
77 Buffer drags are always converted to plain text.
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
78
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
79 @node MSWindows OLE
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
80 @subsection MSWindows OLE
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
81 @cindex MSWindows OLE
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
82
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
83 Only allows file drags and drops.
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
84
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
85 @node Loose ends
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
86 @subsection Loose ends
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
87
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
88 The following protocols will be supported soon: Xdnd, Motif, Xde (if I
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
89 get some specs).
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
90
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
91 In particular Xdnd will be one of the protocols that can benefit from
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
92 the XEmacs API, cause it also uses MIME types to encode dragged data.
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
93
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
94 @node Drop Interface
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
95 @section Drop Interface
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
96 @cindex drop
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
97 @cindex Drop API
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
98
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
99 For each activated low-level protocol, a internal routine will catch
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
100 incoming drops and convert them to a dragdrop-drop type
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
101 misc-user-event.
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
102
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
103 This misc-user-event has its function argument set to
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
104 dragdrop-drop-dispatch and the object contains the data of the drop
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
105 (converted to URL/MIME specific data).
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
106
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
107 @node Drag Interface
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
108 @section Drag Interface
288
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
109 @cindex drag
e11d67e05968 Import from CVS: tag r21-0b42
cvs
parents: 284
diff changeset
110 @cindex Drag API
284
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
111
558f606b08ae Import from CVS: tag r21-0b40
cvs
parents:
diff changeset
112 This describes the drag API (not implemented yet).