openmolecules.org

 
Home » DataWarrior » Bug Reports » Chemical Structure copy/paste issue for Linux v4.7.2
Chemical Structure copy/paste issue for Linux v4.7.2 [message #317] Mon, 19 March 2018 14:46 Go to next message
bruno.b is currently offline  bruno.b
Messages: 11
Registered: October 2014
Location: Germaniy
Junior Member
I was very happy to see that the latest version support copy&paste and drag&drop.
I tried to paste a MOL, SMILES and IDCODE. Unfortunately, it does not work with MOL and SMILES. I am not sure this is a bug.

Here are the messages from the console:


GetClipboardData MDLCT
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDL_MOL
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDLSK
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDLSK_EMBEDDED
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData IDCODE
Pasted string 'VitC


13 13 0 0 1 0 0 0 0 0 1 V2000
7.8349 6.8596 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0
8.5487 6.4458 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0
7.8349 7.6825 0.0000 O 0 0 0 0 0 0 0 0 0 0 0 0
9.2625 6.8596 0.0000 O 0 0 0 0 0 0 0 0 0 0 0 0
7.3256 5.0000 0.0000 O 0 0 0 0 0 0 0 0 0 0 0 0
5.5365 5.0068 0.0000 O 0 0 0 0 0 0 0 0 0 0 0 0
5.0000 6.7027 0.0000 O 0 0 0 0 0 0 0 0 0 0 0 0
7.1210 6.4458 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0
6.8528 5.6752 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0
6.4686 6.9505 0.0000 O 0 0 0 0 0 0 0 0 0 0 0 0
6.0230 5.6752 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0
5.7843 6.4458 0.0000 C 0 0 0 0 0 0 0 0 0 0 0 0
7.7507 5.9162 0.0000 H 0 0 0 0 0 1 0 0 0 0 0 0
1 2 1 0 0 0 0
1 3 1 1 0 0 0
1 8 1 0 0 0 0
2 4 1 0 0 0 0
5 9 1 0 0 0 0
6 11 1 0 0 0 0
7 12 2 0 0 0 0
8 9 1 0 0 0 0
8 10 1 0 0 0 0
8 13 1 1 0 0 0
9 11 2 0 0 0 0
10 12 1 0 0 0 0
11 12 1 0 0 0 0
M END
$$$$
'
returned Mol is null





Pasting a SMILES does not work:

GetClipboardData ACT_MOLECULE
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
Mol is null
GetClipboardData MDLCT
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDL_MOL
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDLSK
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDLSK_EMBEDDED
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData IDCODE
Pasted string '[C@@H](CO)(O)[C@]1([H])C(O)=C(O)C(=O)O1'
NativeClipboardAccessor.pasteMolecule(): Exception java.lang.ArrayIndexOutOfBoundsException
returned Mol is null


Pasting an IDCODE works:


GetClipboardData ACT_MOLECULE
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
Mol is null
GetClipboardData MDLCT
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDL_MOL
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDLSK
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData MDLSK_EMBEDDED
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Molecule
Exception in getClipboardData: java.awt.datatransfer.UnsupportedFlavorException: Actelion Reaction
GetClipboardData IDCODE
Pasted string 'dcLF@@Rag\bbTVTILuSUTaSh@'
returned Mol is com.actelion.research.chem.StereoMolecule@7e9cbe66






Best regards,

Bruno
Re: Chemical Structure copy/paste issue for Linux v4.7.2 [message #326 is a reply to message #317] Sat, 21 April 2018 22:42 Go to previous message
thomas is currently offline  thomas
Messages: 146
Registered: June 2014
Senior Member
Dear Bruno,

thank you for the suggestion. Indeed, it is not a bug. Pasting a SMILES or molfile is currently not supported. However, I have updated the clipboard handling code to automatically check for smiles and molfiles and convert, if possible. In addition I am looking into name to structure. IUPAC name to structure would be possible via the OPSIN library, other compound names would require a dictionary, which would make the DataWarrior installation substantially larger. I could use my name2structure remote service, but for privacy reasons should ask in advance, whether DataWarrior may send the name out to a server. I will think of a solution...

Regards, Thomas
Previous Topic: Chemical Structure copy/paste issue for Mac v4.7.2
Next Topic: Chrial drawn structures in dwar / sdf different
Goto Forum:
  


Current Time: Fri Jul 20 06:59:56 CEST 2018

Total time taken to generate the page: 0.00569 seconds