Copy-Paste and Drag&Drop

The cut, copy, and paste operations work in the bean and application versions of Marvin, and also in the applets.

However, because of security reasons, the untrusted (unsigned) applets perform these operations using a local clipboard inside the JVM process.

The non-applet versions of Marvin and the signed Marvin applets are allowed to use the system clipboard.

Copy, Copy As..., Copy as Smiles

Marvin has three commands to place objects on the clipboard: Copy, Copy As... and Copy as Smiles.

  • Copy command: the structure is copied to the clipboard in a couple of formats.
    The molecule always will be there in mrv, MDL Molfile and DayLight SMILES formats.
    The other formats (like Plain Text or Bitmap Image) are optional. See the table in the Clipboard formats section about supported options and default settings.

  • Copy As... command: a dialog is displayed to select in which format the molecule will be placed to the clipboard.

  • Copy as Smiles command: the Smiles string of the structure is copied to the clipboard in String and Plain Text formats.

Any file format of Marvin can be copied to the clipboard as String or Plain Text. choosing Edit->Source.

Clipboard formats

Marvin can place more than one clipboard objects on the clipboard, each represents the same molecule in different format. Copy from Marvin supports the following representations:

  • Marvin Document (mrv): Marvin's own format. Only Marvin can paste it.

  • MDL Molfile: a popular molecule description format. A lot of chemical drawing tool can paste it like Marvin, ChemDraw, etc.

  • Daylight SMILES: wide range molecule format. Several chemical editor can paste it. In a few editor, SMILES can not be pasted directly. E.g. ChemDraw uses the "Paste Special/SMILES" option to copy SMILES from the clipboard.

  • Daylight SMARTS: a chemical format for specifying substructural patterns in molecules. Compared to SMILES, SMARTS is a more general notation thanks to its use of extended sets of atomic and bond symbols and logical operators, which make SMARTS a useful tool in substructure searching.

  • Plain Text (molecule source): To be able to copy the molecule source into text editors or into other application that do not support chemical formats.

  • Bitmap Image: To paste molecule image into presentations or into documents.

  • Vector Graphical Image (EMF): The vector graphics is scalable unlike bitmap image. It can be pasted into MS-Office documents or into other applications that support Enhanced MetaFile format.

  • OLE object: To copy a Marvin OLE object into MS-Office. This format is available under Windows. To be able to paste it into an MS-Office document, marvinOLEServer.exe registration is required. (Marvin installer does it automatically or you can register it manually in Marvin applications through the Edit/Preferences/OLEServer menu.) You can read more about OLE support in Marvin OLE User's Guide.

  • Portable document format (PDF) which contains vector graphical image. It is the default format in MacOSX.

A couple of formats are not available on a few platforms.

Supported formats:

Format

Windows

Mac OS X

Linux

Marvin Document (mrv)

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

MDL Molfile

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

Daylight SMILES

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

Plain Text (molecule source)

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/check.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

Bitmap Image

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

Vector Graphical Image (EMF)

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/error.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/error.png

OLE object

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/error.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/error.png

PDF

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/error.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/error.png

 

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/check.png

supported

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/error.png

not supported

images/s/en_GB/6219/97b73ca06fd2a90682d80f34d4c4c163eebdd511.89/_/images/icons/emoticons/lightbulb_on0.png

selected as default

When the content of the clipboard is pasted into an application (and it is available in more than one format), the application retrieves data in the most descriptive format.

Microsoft Office

Most versions of Microsoft Office prefer pasting image instead of text if the content of the clipboard is available in both formats. But there are a few ones that paste text as default. In that case, you should use "Paste As Special" option in MS-Office to paste it as image but it can be unconfortable to someone. The workaround can be the restriction of the text copy from Marvin. That is the reason why text copy is disabled in the default settings of Marvin (on a couple of platforms).
In that case, we recommend Copy As... or Copy as SMILES to paste text into MS-Word and in other editors. Another solution can be to change the default options of the Copy command (see above how to do it).

If we compare Bitmap and Vector Graphical Image formats, the situation is the same as in the previous case (text vs. image). Most of the applications prefer bitmap image although they can accept vector graphical images as an Enhanced MetaFile (EMF), like MS-Word. Since vector graphics are scalable unlike bitmap images, EMF is chosen as default from image formats (where it is supported).

Data transfer between Marvin and other chemical drawing tools

 

Windows1

Macintosh OS X4

ISISDraw2

Copy & Paste

Copy & Paste

ChemDraw

Copy & Paste

Copy & Paste

ChemDraw Plugin

Copy & Paste

Paste

 

Copy: copy a structure from the application into Marvin
Paste: copy a structure from Marvin into the application

1: On windows in Java 1.2-1.3.1, the <Java home directory>/jre/lib/flavormap.properties file must be edited: MDLCT=chemical/x-mdl-Molfile

2: In case of ISISDraw the following option must be checked: Option -> Settings -> General -> Copy Mol/Rxnfile to the Clipboard

3: Copy as SMILES works

4: In OS X, since Java 1.4, data transfer in chemical formats does not work. In that case, molecule can be pasted only as image or text into chemical drawing tools. Copy from an application to Marvin works if the application can place data as Plain Text to the clipboard.

Data transfer between Marvin and other applications

Marvin can paste SMILES strings, MDL MolFiles, etc. from a text editor as molecules.

X Window System: most text editors (xedit, emacs, gvim, etc.) do not transfer data to the X clipboard, so Marvin is unable to communicate with them. Copy&Paste works with the following editors and other programs:

  • GNOME programs: gedit, gnotepad+ (gnp), gxedit, etc.

  • Motif programs: asWedit, nedit, Netscape, etc.

With the xclipboard program, you can test whether your favorite editor uses the X clipboard or not.