Removing generic templates toolbar from MarvinSketch applet

User 08353716d8

26-01-2011 15:44:18

Hi,


I've been meaning to ask this for a bit, but priority has finally been given here at work. I THINK around version 5.3, the way the templates work changed a bit. I believe the Generic Templates toolbar has always shown up by default (correct me if I'm wrong). We have some situations where we give students those tools, and some where we don't. We used to handle this by setting ttmpls0 either to '*Generic*chemaxon/marvin/templates/generic.t' when the bar is needed, and to empty string when it is not.


Now, even where there is no ttmpls0 param at all, the Generic Templates toolbar shows. If I try setting ttmpls0 to empty string, as I had done in the past, I now get a Java error from the applet.


So, my question is - how do I hide the Generic Templates toolbar from showing in the Advanced Toolbars area (on the bottom of the applet)? I checked in the documentation but only found info about adding extra templates, not removing the default ones.


Any help is greatly appreciated.


thanks,


Danny Holyfield

User 08353716d8

27-01-2011 20:33:02

So .. does anyone know an error-free way to remove the generic templates toolbar from the MarvinSketch applet? I'm tasked with removing it, but completely lost at this point as to how to accomplish that.

ChemAxon 5433b8e56b

28-01-2011 00:28:23

Hi Danny,


yes you are right, there were a complete change in the representation of the templates and the template library itself in 5.3.0. There were a lot of change, and this seem to be something which is working differently.


For now, you can disable the template toolbar via a customization file. You can find a detailed documentation on customization here. The technical part of applying a server side configuration file can be found here.


You can remove the generic templates with the toolbar if you delete the My templates toolbar from the toolbar section on the configuration GUI. If you have any further question, do not hasitate to ask.


I hope this helps.


Regards,
Istvan

User 08353716d8

28-01-2011 15:09:44

I see .. so it can no longer be done via applet parameters? This presents a problem for us, as we do show that toolbar in certain conditional situations. It sounds like we may have to change what is available as we'll be locked into one configuration per server - is that correct?

User 08353716d8

28-01-2011 15:11:37

Also, for certain chemical 'modes', we show the bicyclics and rings template sets - I'm assuming this is an all-or-nothing thing with rmeoving the my templates toolbar - would there be no way to show bicyclics and rings but NOT generic templates?

User 08353716d8

01-02-2011 22:02:59

So, we've agreed on a compromise here, this setup will work ok for us as far as templates. However, I'm having trouble finding a reference to the actual line that needs to be added to customization.xml to remove My Templates. All I need really is the path to it, I assume it's another <remove> tag. Any help is appreciated ...


thanks,


Danny Holyfield

ChemAxon 5433b8e56b

02-02-2011 04:59:52

Hi Dany,


sorry for the late reply, i had consult with the
developer of the customization part, and it had taken time. Yes there is a
remove tag inside a scheme definition. The smallest xml to remove only the template toolbar from the default configuration wich is active:


<?xml version="1.0" encoding="UTF-8"?>

<customization active="default">

<scheme id="default">

<remove path="toolbar/mytemplates"/>

</scheme>

</customization>


But unfortunatelly in this case the template toolbar is missing at all, and all scheme has to have this remove tag to remove it at all, since the schemes can be switched (only the customization via GUI is disabled) when there is an active customization.xml for MarvinSketch.


We will dicuss the possible solutions, to make this functionality available again thru applet parameters and/or thru applet methods. We will keep you informed on the status.


Regards,
Istvan

User 08353716d8

02-02-2011 20:05:56

Thanks, that worked as far as removing the advanced templates toolbar.


Now, were you saying that modifying templates via applet parameters shouldn't be working at all anymore? I'm now noticing a new problem - we have some situations where advanced templates DO need to show, with bicyclics and rings, and generics since they are default. I had done this with applet parameters in the past like so:


<param name='ttmpls1' value='*Rings*chemaxon/marvin/templates/rings.t'>
<param name='ttmpls4' value='*Bicyclics*chemaxon/marvin/templates/bicycles.t'>


But now, when I use a customization file that does NOT remove advanced templates, and I include these applet params, I no longer get the generic, bicyclic or rings template sets - instead I get a single template icon with a triangle on it. Do biycyclics and rings now need to be added via the xml files as well? If so, can you give me the paths for those? I'm assuming it would just be a standard 'add' tag with the path.


Any help is well appreciated, thanks again for helping me get the advanced templates toolbar off in the situations where we need that particular configuration.


thanks


Danny Holyfield

User 08353716d8

03-02-2011 16:53:22

So I realize that the triangle I see is the beginning of the rings template set. Any idea why the entire set won't show? If I inculde both of these parameters, I see the triangle and the square, the first two icons on the rings set. I need to be able to again show the entire rings and bicyclics sets.


thanks


Danny Holyfield

ChemAxon 5433b8e56b

03-02-2011 17:14:50

Hi Dany,


that is a problem in the parameter handling as i assume. I will check it later today, and get back to you with solutions, or information on the issue.


Istvan

User 08353716d8

03-02-2011 20:53:56

So, I've been poking around with this today and have found that rings and bicyclics can be added by including the following lines in the customization xml:


<add path="toolbar/mytemplates/rings"/>
<add path="toolbar/mytemplates/bicyclic"/>


however, then the generic templates disappear. I'm not having much luck adding those back in. I've tried both


<add path="toolbar/mytemplates/generic"/>


<add path="toolbar/mytemplates/generics"/>


but neither adds that toolbar back. Would it be possible to get a full set of updated template management instructions for MarvinSketch 5.3.8. given that the applet parameters no longer work?


thanks


Danny Holyfield

User 08353716d8

07-02-2011 18:45:53

Any word on this? If there is a proper (and full) guide to managing templates in MarvinSketch 5.3.8, that would be helpful. What is currently up in support has not provided enough detail for me. I do have the OSX stand-alone version, is there somewhere I can find the customization.xml file if I just set what I want to appear via the stand-alone menus?


 


any help is appreciated


thanks


Danny Holyfield

ChemAxon 5433b8e56b

08-02-2011 12:44:04

Hi Dany,


sorry for the silence, i also had to play around with this, because the documentation seems to be incomplete unfortunatelly.


I have talked with the developer of customization part of the code, and it turned out neither of these path is considered to be valid. The marvin.templates.properties file causing the appearance of the templates. This file is located in your home directory inside the chemaxon settings directory.


We will fix this ASAP.


Regards,
Istvan

ChemAxon 5433b8e56b

25-02-2011 20:23:07

Hi Danny,


I would like to inform you, that the fix is ready, and released in 5.4.1.1.


It works as you descirbed, so if you set the ttmpls0 parameter for example to "*Generic*" than the generic templates are disabled, and won't be visible on toolbar. If you also set the tmpls0 parameter to this value, than the generic templates are deleted from the template library also.


So i suggest to use the applet parameters as before instead of customization, since in the customization, you only can enebale or disable the template toolbar at all, but you can not modify its contents.


Regards,
Istvan