Does marvin view (mview) work with marvin JS

User 4616a6b00d

11-03-2016 09:25:11

Hi ,


Since there are problems with clarity of images in marvin JS i thought of going with the marvin view using javascript which we had earlier used for marvin sketch. 


<h:inputHidden id="moleculeTxtM" value="#{experimentHome.mrvData}" />


<s:div id="appletContainer">


<center>


<script>


       var mrvData = document.getElementById("frmMarvinSketch:moleculeTxt").value;


       alert(mrvData);


       if(null == mrvData ){


        mrvData = document.getElementById("form1:moleculeTxtM").value; 


       }


        mview_begin("../marvinjs",600,250);


mview_param("mrv",mrvData);


mview_end();


</script>


</center>


</s:div>


The above line of code ,more importantly the one which is marked bold-Will it work with marvin js?  .If any changes to be done please let me know . If this is not the solution, please let me know the alternative solution to get the clear view of scheme data once it is retrieved from database. 

ChemAxon 7c2d26e5cf

11-03-2016 13:05:33

Meanwhile MarvinView is a Java Applet, Marvin JS is a pure JavaScript component.


I am afraid if the client's browser does not support Java Plugin, MarvinView applet will not work.


I recommend to consult with the applet compatibility with the Marvin team.

ChemAxon 7c2d26e5cf

11-03-2016 13:08:45

I have moved this topic to the Marvin forum.

User 870ab5b546

24-03-2016 16:28:55

If all you want is images of your molecules, you can use the static MarvinJS method marvin.ImageExporter.mrvToDataUrl() to convert the structure to an image data URL, which you can then display directly in a Web page. See https://marvinjs-demo.chemaxon.com/latest/jsdoc.html. 


If you want an image of your molecule that you can manipulate (rotate, add H atoms, show stereochemical descriptors), you have three choices:



  1. MarvinJS, but the structure is editable, and there are all those toolbars.

  2. MarvinView applet, but you cannot use Chrome, and soon other browsers will stop supporting Java plugins as well.

  3. Java Web Start version of MarvinView, but it takes a long time to load the first time.