Applet only parameters
The following parameters are meaningful only for the applet (JMSketch) and not for the JavaBean (MSketchPane).
Parameter |
Meaning |
Default |
menubar |
Enable the embedded menubar. |
true |
buttonmenubar |
Enable menubar in button (/hide) mode if the menubar parameter is true. Combine it with the detach parameter to set the button mode. |
true |
detach |
Detachment behavior. The value consists of some optional arguments: show/hide size, and maxscale. If more arguments are included, they must be separated by a comma. |
size=444x350 |
undetachByX |
Sketcher window close (x) behavior. |
true |
mol |
The molecule file to be loaded at startup, as either a URL or the file itself (inline) in MDL mol, compressed mol, SMILES, SMARTS, etc format. |
|
preload |
Deprecated |
|
cacheMols |
Store loaded molecules in an internal cache (true or false). |
false |
loadMols |
Comma-separated list of molfiles to preload. Useful for caching molecules in JavaScript "slideshows". |
|
usedJars |
Comma-separated list of additional jar files that can be used by the applet. The additional files have to be defined with their paths relative to the applet's base. |
|
imageSaveFormat |
The default file format for image saving. |
png |
molLoaderFinishedEvent |
Evaluates a JavaScript code after the loading of the molecule into the editor is finished. This "event" is invoked if molecule is loaded-in into the applet in any of the following cases:
Note: If the MAYSCRIPT option is not specified, JavaScript can not be evaluated from the applet. E.g.: msketch_mayscript= true ; msketch_begin( "marvin" , 400 , 300 ); msketch_param( "mol" , "caffeine.mol" ); msketch_param( "molLoaderFinishedEvent" , "js:alert('Molecule is loaded-in.')" ); msketch_end(); |
|
listenpropertychange |
Switch on/off property change event listener to the applet. If listener is active, the applet will call propertyChange(prop) JavaScript method. If you would like to handle property change events in JavaScript, implement this method in your html source. Note: If the MAYSCRIPT option is not specified, JavaScript can not be evaluated from the applet. E.g.: function propertyChange(prop) { if (document.textform != null ) { var s = document.textform.txt.value; document.textform.txt.value = s + "\n" + prop; } } msketch_mayscript= true ; msketch_begin( "marvin" , 400 , 300 ); msketch_param( "listenpropertychange" , "true" ); msketch_end(); If you also specify the "appletid" parameter, its value will appear in the name of the property as prefix (e.g.: "firstapplet.mol"). |
false |
appletid |
Identify applet in property change event notifications to JavaScript. Use this parameter with listenpropertychange when more than one applet are located on the same web page. It helps to identify which applet sent the notification. |
|
skin |
Change the component's Look & Feel (only in SWING applet). If you do not specify this parameter, Marvin will use the default LookAndFeel style. |
javax.swing.plaf .metal .MetalLookAndFeel |
splashScreenImage |
Change the component's splash screen displayed at startup. If you do not specify this parameter, Marvin will use its default splash screen. |
null |
license |
Sets the contents of a pre-read license file to the license manager to read and validate licenses from. |
|
licenseFile |
Sets the license file location to the license manager to read and validate licenses from. |
|
onError |
A string containing a javascript code, that has to be run by the applet, if it has a failure at initialization. |
|
alertError |
If this parameter is set to true, the applet will show a javascript alert window with an error message, if there was a problem in the initialization process of the applet. |
|
legacy_lifecycle |
The "legacy_lifecycle" is a general Java applet parameter. If its value is true, it helps avoid destroying the applet when you leaves the applet page. If you use "marvin.js", it sets its value to true automatically unless you specify its value explicitly. By the way, the default value of this parameter in Java is false. See the discussion about it on the forum. |
|
bgloadPriority |
You can specify the order of the modules for background loading. After startup of MarvinSketch, modules that are not used yet are started downloading in the background to fast up their initalization of their first usage. The value of this parameter is a comma separated list of modules that get priority for loading. See also bgloadEnabled. |
|
bgloadEnabled |
Let or deny loading of rest of modules in a background thread after startup. Set this parameter to true to accept background loading. Set it to false if you would like to reject this functionality. |
true |
sketchHelp |
MarvinSketch help contents. Accepts relative URL to the applet codebase or any absolute URL. |
chemaxon/marvin/help /sketch-index.html |
sketchQuickHelp |
MarvinSketch quick help. Accepts relative URL to the applet codebase or any absolute URL. |
chemaxon/marvin/help /sketch.html |
checkerConfigURL |
Default checker configuration URL. Accepts any absolute URL. |
local configuration |