File: wx243.htm

package info (click to toggle)
wxwin2-doc 2.01-1
  • links: PTS
  • area: main
  • in suites: potato
  • size: 6,540 kB
  • ctags: 5,968
  • sloc: cpp: 15,157; makefile: 434; sh: 6
file content (76 lines) | stat: -rw-r--r-- 3,306 bytes parent folder | download
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
<HTML>
<head><title>wxTextDropTarget</title></head>

<BODY BGCOLOR=#FFFFFF>
<A NAME="wxtextdroptarget"></A><CENTER>
<A HREF="wx.htm"><img align=center src="contents.gif" BORDER=0 ALT="Contents"></A> <A HREF="wx22.htm#classref"><img align=center src="up.gif" BORDER=0 ALT="Up"></A> <A HREF="wx242.htm#wxtextentrydialog"><img align=center src="back.gif" BORDER=0 ALT="Previous"></A> <A HREF="wx244.htm#wxtextvalidator"><img align=center src="forward.gif" BORDER=0 ALT="Next"></A> </CENTER><HR>

<H2>wxTextDropTarget</H2>
<P>
A predefined drop target for dealing with text data.<P>
<B><FONT COLOR="#FF0000">Derived from</FONT></B><P>
<A HREF="wx82.htm#wxdroptarget">wxDropTarget</A><P>
<B><FONT COLOR="#FF0000">Include files</FONT></B><P>
&lt;wx/dnd.h&gt;<P>
<B><FONT COLOR="#FF0000">See also</FONT></B><P>
<A HREF="wx312.htm#wxdndoverview">Drag and drop overview</A>, <A HREF="wx81.htm#wxdropsource">wxDropSource</A>, 
<A HREF="wx82.htm#wxdroptarget">wxDropTarget</A>, <A HREF="wx91.htm#wxfiledroptarget">wxFileDropTarget</A><P>
<B><FONT COLOR="#FF0000">Members</FONT></B><P>
<A HREF="#wxtextdroptargetwxtextdroptarget">wxTextDropTarget::wxTextDropTarget</A><BR>
<A HREF="#wxtextdroptargetgetformatcount">wxTextDropTarget::GetFormatCount</A><BR>
<A HREF="#wxtextdroptargetgetformat">wxTextDropTarget::GetFormat</A><BR>
<A HREF="#wxtextdroptargetondrop">wxTextDropTarget::OnDrop</A><BR>
<A HREF="#wxtextdroptargetondroptext">wxTextDropTarget::OnDropText</A><BR>
<P>

<HR>
<A NAME="wxtextdroptargetwxtextdroptarget"></A>
<H3>wxTextDropTarget::wxTextDropTarget</H3>
<P>
<B></B> <B>wxTextDropTarget</B>()<P>
Constructor.<P>

<HR>
<A NAME="wxtextdroptargetgetformatcount"></A>
<H3>wxTextDropTarget::GetFormatCount</H3>
<P>
<B>virtual size_t</B> <B>GetFormatCount</B>() <B>const</B><P>
See <A HREF="wx82.htm#wxdroptargetgetformatcount">wxDropTarget::GetFormatCount</A>. This function is implemented
appropriately for text.<P>

<HR>
<A NAME="wxtextdroptargetgetformat"></A>
<H3>wxTextDropTarget::GetFormat</H3>
<P>
<B>virtual wxDataFormat</B> <B>GetFormat</B>(<B>size_t </B><I>n</I>) <B>const</B><P>
See <A HREF="wx82.htm#wxdroptargetgetformat">wxDropTarget::GetFormat</A>. This function is implemented
appropriately for text.<P>

<HR>
<A NAME="wxtextdroptargetondrop"></A>
<H3>wxTextDropTarget::OnDrop</H3>
<P>
<B>virtual bool</B> <B>OnDrop</B>(<B>long </B><I>x</I>, <B>long </B><I>y</I>, <B>const void </B><I>*data</I>, <B>size_t </B><I>size</I>)<P>
See <A HREF="wx82.htm#wxdroptargetondrop">wxDropTarget::OnDrop</A>. This function is implemented
appropriately for text, and calls <A HREF="wx243.htm#wxtextdroptargetondroptext">wxTextDropTarget::OnDropText</A>.<P>

<HR>
<A NAME="wxtextdroptargetondroptext"></A>
<H3>wxTextDropTarget::OnDropText</H3>
<P>
<B>virtual bool</B> <B>OnDropText</B>(<B>long </B><I>x</I>, <B>long </B><I>y</I>, <B>const char </B><I>*data</I>)<P>
Override this function to receive dropped text.<P>
<B><FONT COLOR="#FF0000">Parameters</FONT></B><P>
<I>x</I><UL><UL>
The x coordinate of the mouse.</UL></UL>
<P>
<I>y</I><UL><UL>
The y coordinate of the mouse.</UL></UL>
<P>
<I>data</I><UL><UL>
The data being dropped: a NULL-terminated string.</UL></UL>
<P>
<B><FONT COLOR="#FF0000">Return value</FONT></B><P>
Return TRUE to accept the data, FALSE to veto the operation.<P>

</BODY></HTML>