org.gnu.gtk
Class SelectionData
java.lang.Object
org.gnu.glib.GObject
org.gnu.gtk.SelectionData
- public class SelectionData
- extends GObject
Data used in Drag and drop operations
Methods inherited from class org.gnu.glib.GObject |
addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addEventHandler, addListener, equals, freezeNotify, getBooleanProperty, getData, getData, getDoubleProperty, getEventListenerClass, getEventType, getFloatProperty, getGObjectFromHandle, getHandle, getIntFromHandle, getIntProperty, getJavaObjectProperty, getLongProperty, getNullHandle, getPixbufProperty, getProperty, getStringFromHandle, getStringProperty, hashCode, hasProperty, instantiateJGObjectFromGType, notify, removeEventHandler, removeListener, retrieveGObject, setBooleanProperty, setData, setData, setDoubleProperty, setFloatProperty, setHandle, setIntProperty, setJavaObjectProperty, setLongProperty, setPixbufProperty, setProperty, setStringProperty, thawNotify |
Methods inherited from class java.lang.Object |
clone, finalize, getClass, notify, notifyAll, toString, wait, wait, wait |
SelectionData
public SelectionData(Handle handle)
getSelection
public Atom getSelection()
getTarget
public Atom getTarget()
getType
public Atom getType()
getFormat
public int getFormat()
getLength
public int getLength()
getText
public java.lang.String getText()
setText
public boolean setText(java.lang.String text)
targetsIncludText
public boolean targetsIncludText()
- Given that this SelectionData object holds a list of targets,
determines if any of the targets in targets can be used to provide text.
- Returns:
- TRUE if this SelectionData holds a list of targets, and a
suitable target for text is included, otherwise FALSE.
targetsIncludeImage
public boolean targetsIncludeImage(boolean writable)
- Given that this SelectionData object holds a list of targets,
determines if any of the targets in targets can be used to
provide a
Pixbuf
.
- Parameters:
writable
- Whether to accept only targets for which GTK+ knows
how to convert a pixbuf into the format.
- Returns:
- TRUE if this SelectionData holds a list of targets, and a
suitable target for images is included, otherwise FALSE.
getTargets
public Atom[] getTargets()
setPixbuf
public boolean setPixbuf(Pixbuf pixbuf)
getPixbuf
public Pixbuf getPixbuf()
setUris
public boolean setUris(java.lang.String[] uris)
getUris
public java.lang.String[] getUris()
getSelection
protected static final Handle getSelection(Handle selectionData)
getTarget
protected static final Handle getTarget(Handle selectionData)
getType
protected static final Handle getType(Handle selectionData)
getFormat
protected static final int getFormat(Handle selectionData)
getData
protected static final java.lang.String getData(Handle selectionData)
getLength
protected static final int getLength(Handle selectionData)
getDisplay
protected static final Handle getDisplay(Handle selectionData)
gtk_selection_data_get_text
protected static final java.lang.String gtk_selection_data_get_text(Handle selectionData)
gtk_selection_data_set_text
protected static final boolean gtk_selection_data_set_text(Handle selectionData,
java.lang.String str)
gtk_selection_data_get_targets
protected static final Handle[] gtk_selection_data_get_targets(Handle selectionData)
gtk_selection_data_targets_include_text
protected static final boolean gtk_selection_data_targets_include_text(Handle selectionData)
gtk_selection_data_set_pixbuf
protected static final boolean gtk_selection_data_set_pixbuf(Handle selectionData,
Handle pixbuf)
gtk_selection_data_get_pixbuf
protected static final Handle gtk_selection_data_get_pixbuf(Handle selectionData)
gtk_selection_data_set_uris
protected static final boolean gtk_selection_data_set_uris(Handle selectionData,
java.lang.String[] uris)
gtk_selection_data_get_uris
protected static final java.lang.String[] gtk_selection_data_get_uris(Handle selectionData)