nsIClipboardCommands

IID:b8100c90-73be-11d2-92a5-00105a1b0d64
Inherits From:nsISupports
Status:FROZEN

An interface for embedding clients who wish to interact with the system-wide OS clipboard. Mozilla does not use a private clipboard, instead it places its data directly onto the system clipboard. The webshell implements this interface.

This interface is implemented by the following components:


Methods

PRBool canCopyImageContents ( ) PRBool canCopyImageLocation ( ) PRBool canCopyLinkLocation ( ) PRBool canCopySelection ( ) PRBool canCutSelection ( ) PRBool canPaste ( ) void copyImageContents ( ) void copyImageLocation ( ) void copyLinkLocation ( ) void copySelection ( ) void cutSelection ( ) void paste ( ) void selectAll ( ) void selectNone ( )

PRBool canCopyImageContents ( )

Returns whether we can copy an image's contents.

Returns:
true if an image is selected, false otherwise

PRBool canCopyImageLocation ( )

Returns whether we can copy an image location.

Returns:
true if an image is selected, false otherwise.

PRBool canCopyLinkLocation ( )

Returns whether we can copy a link location.

Returns:
true if a link is selected, false otherwise.

PRBool canCopySelection ( )

Returns whether there is a selection and it is copyable.

Returns:
true if there is a selection, false otherwise.

PRBool canCutSelection ( )

Returns whether there is a selection and it is not read-only.

Returns:
true if the current selection can be cut, false otherwise.

PRBool canPaste ( )

Returns whether the current contents of the clipboard can be pasted and if the current selection is not read-only.

Returns:
true there is data to paste on the clipboard and the current selection is not read-only, false otherwise

void copyImageContents ( )

Copy the contents of the selected image.


void copyImageLocation ( )

Copy the location of the selected image.


void copyLinkLocation ( )

Copy the link location of the current selection (e.g., the href attribute of a selected a tag).


void copySelection ( )

Copy the current selection onto the clipboard.


void cutSelection ( )

Cut the current selection onto the clipboard.


void paste ( )

Paste the contents of the clipboard into the current selection.


void selectAll ( )

Select the entire contents.


void selectNone ( )

Clear the current selection (if any). Insertion point ends up at beginning of current selection.

Reference documentation is generated from Mozilla's source.

Add a note User Contributed Notes
No comments available

Copyright © 1999 - 2005 XULPlanet.com