Eric,

Quick and dirty check: This works in a script entry field:

function s(arg1) {select @{arg1}}; s "oxygen"; color pink;

Is the problem that whatever is not in quotes? Quotes were required above.

Otis

--
Otis Rothenberger
o...@chemagic.com
http://chemagic.com

> On Jan 26, 2015, at 1:28 PM, Eric Martz <ema...@microbio.umass.edu> wrote:
> 
> I now have 2 "aliases" that work perfectly! (See definitions at the 
> bottom below)
> 
> q # toggles quality (antialiasdisplay)
> h # toggles selectionhalos
> 
> I have been unable to come up with the syntax that would define a 
> function so this:
> 
> s whatever
> 
> would perform this:
> 
> select whatever
> 
> For example this does nothing (not even an error):
> 
> function s(arg1) {select @{arg1}}
> 
> s 5
> 
> and neither do 3 other variations I've tried.
> 
> Thanks!
> 
> --------------
> These work:
> 
> function q() {set antialiasDisplay @{!antialiasDisplay}}
> 
> function h() {selectionhalos @{!selectionhalos}}
> 
> 
> 
> 
> ------------------------------------------------------------------------------
> Dive into the World of Parallel Programming. The Go Parallel Website,
> sponsored by Intel and developed in partnership with Slashdot Media, is your
> hub for all things parallel software development, from weekly thought
> leadership blogs to news, videos, case studies, tutorials and more. Take a
> look and join the conversation now. http://goparallel.sourceforge.net/
> _______________________________________________
> Jmol-users mailing list
> Jmol-users@lists.sourceforge.net
> https://lists.sourceforge.net/lists/listinfo/jmol-users




------------------------------------------------------------------------------
Dive into the World of Parallel Programming. The Go Parallel Website,
sponsored by Intel and developed in partnership with Slashdot Media, is your
hub for all things parallel software development, from weekly thought
leadership blogs to news, videos, case studies, tutorials and more. Take a
look and join the conversation now. http://goparallel.sourceforge.net/
_______________________________________________
Jmol-users mailing list
Jmol-users@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jmol-users

Reply via email to