Thank you so much, the JMol script is really useful!
Just one last thing, how come the following is giving me errors:
viewer.evalString("defaultColorScheme JMOL;");
viewer.evalString("drawHover on;");
I am not sure how to set those values. I am sensing I am missing something
in front of quotes. Thanks once again!
On Mon, Nov 23, 2009 at 11:17 PM, Robert Hanson <hans...@stolaf.edu> wrote:
> OK, so there are two things here: JavaScript and Jmol scripts. The
> JavaScript just allows interaction on a web page so the user can have some
> buttons or menus or links on the page that transmit Jmol script to the
> applet.
>
> If you want to try scripts with Integration.java, you can just change the
> code in that file and re-run it.
>
> final static String strScript = "delay; move 360 0 0 0 0 0 0 0 4;";
>
> "delay...." -- that's the Jmol script. The scripting documentation is at
> http://chemapps.stolaf.edu/jmol/docs. Lots of examples there. It doesn't
> have to be very complex. But it can be.
>
>
> On Mon, Nov 23, 2009 at 8:14 PM, Andy Lu <andylu0...@gmail.com> wrote:
>
>> Are javascripts used only when trying to incorporate it onto html? because
>> I want a script for it to able to run in Eclipse. Do I put those scripts in
>> the integration.java?
>> Do you have any sample examples of a finished script? I am not sure where
>> to start.
>> Thank you for your explanation!
>>
>> On Mon, Nov 23, 2009 at 7:50 AM, Robert Hanson <hans...@stolaf.edu>wrote:
>>
>>> Andy, welcome to Jmol. You are going to find it exceptionally easy to do
>>> all the things you suggest.
>>>
>>> On Sun, Nov 22, 2009 at 7:15 PM, Andy Lu <andylu0...@gmail.com> wrote:
>>>
>>>> I just started programming with JMol java files and I got the
>>>> Integration.java file to work from JMol website.
>>>>
>>>> I have 5 questions:
>>>> 1) How can I set the ball and stick model as the default because when I
>>>> tried to open a file through my file I/O and sending a pdb file to it, it
>>>> shows up as ribbon.
>>>>
>>>
>>> you just script anything you want. There is a command "set defaultScript"
>>> that defines the script that will be run after any file is read. See
>>> http://chemapps.stolaf.edu/jmol/docs
>>>
>>>
>>>
>>>> 2) Is there a way that I can read another pdb file containing a few
>>>> number of residues and highlight only those (halo option) from a bigger
>>>> protein file? I tried to put jmolviewer.setSelectionHalos(true); in my
>>>> integration.java, but it didn't work.
>>>>
>>>
>>> You should do all your interfacing with jmolviewer.evalString(....) if
>>> you can. These are sequenced properly; the other methods are mostly
>>> deprecated. You can do just about anything with scripting.
>>>
>>>
>>>
>>>> 3) Is there a way that I can have the info about a residue show up when
>>>> I move my mouse over it?
>>>
>>>
>>> We call that hovering, and you can catch that with a callback if you want
>>> to totally customize it, or you can define a simple "hover label" template
>>> that will be filled in for you with basic atom information to your detailed
>>> specification. See the documentation for details.
>>>
>>>
>>>>
>>>> 4) Is there a way that I can write a code to draw a line connecting 2
>>>> selected resides?
>>>>
>>>
>>> draw or measure, depending upon what you want.
>>>
>>>
>>>> 5) I know that there is a BFactor option, what does it do?
>>>>
>>>
>>> there's a column in the PDF file that is the BFactor or temperature data.
>>> Not sure about the "option" you are talking about.
>>>
>>>
>>>>
>>>> I would greatly appreciated if you can help me with my problems, I
>>>> really need some help!
>>>>
>>>> Thank you!
>>>>
>>>>
>>>> ------------------------------------------------------------------------------
>>>> Let Crystal Reports handle the reporting - Free Crystal Reports 2008
>>>> 30-Day
>>>> trial. Simplify your report design, integration and deployment - and
>>>> focus on
>>>> what you do best, core application coding. Discover what's new with
>>>> Crystal Reports now. http://p.sf.net/sfu/bobj-july
>>>> _______________________________________________
>>>> Jmol-users mailing list
>>>> Jmol-users@lists.sourceforge.net
>>>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>>>
>>>>
>>>
>>>
>>> --
>>> Robert M. Hanson
>>> Professor of Chemistry
>>> St. Olaf College
>>> 1520 St. Olaf Ave.
>>> Northfield, MN 55057
>>> http://www.stolaf.edu/people/hansonr
>>> phone: 507-786-3107
>>>
>>>
>>> If nature does not answer first what we want,
>>> it is better to take what answer we get.
>>>
>>> -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
>>>
>>>
>>> ------------------------------------------------------------------------------
>>> Let Crystal Reports handle the reporting - Free Crystal Reports 2008
>>> 30-Day
>>> trial. Simplify your report design, integration and deployment - and
>>> focus on
>>> what you do best, core application coding. Discover what's new with
>>> Crystal Reports now. http://p.sf.net/sfu/bobj-july
>>> _______________________________________________
>>> Jmol-users mailing list
>>> Jmol-users@lists.sourceforge.net
>>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>>
>>>
>>
>>
>> --
>> Andy Lu
>>
>>
>> ------------------------------------------------------------------------------
>> Let Crystal Reports handle the reporting - Free Crystal Reports 2008
>> 30-Day
>> trial. Simplify your report design, integration and deployment - and focus
>> on
>> what you do best, core application coding. Discover what's new with
>> Crystal Reports now. http://p.sf.net/sfu/bobj-july
>> _______________________________________________
>> Jmol-users mailing list
>> Jmol-users@lists.sourceforge.net
>> https://lists.sourceforge.net/lists/listinfo/jmol-users
>>
>>
>
>
> --
> Robert M. Hanson
> Professor of Chemistry
> St. Olaf College
> 1520 St. Olaf Ave.
> Northfield, MN 55057
> http://www.stolaf.edu/people/hansonr
> phone: 507-786-3107
>
>
> If nature does not answer first what we want,
> it is better to take what answer we get.
>
> -- Josiah Willard Gibbs, Lecture XXX, Monday, February 5, 1900
>
>
> ------------------------------------------------------------------------------
> Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
> trial. Simplify your report design, integration and deployment - and focus
> on
> what you do best, core application coding. Discover what's new with
> Crystal Reports now. http://p.sf.net/sfu/bobj-july
> _______________________________________________
> Jmol-users mailing list
> Jmol-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jmol-users
>
>
--
Andy Lu
------------------------------------------------------------------------------
Let Crystal Reports handle the reporting - Free Crystal Reports 2008 30-Day
trial. Simplify your report design, integration and deployment - and focus on
what you do best, core application coding. Discover what's new with
Crystal Reports now. http://p.sf.net/sfu/bobj-july
_______________________________________________
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users