From: Axel Kohlmeyer (akohlmey_at_gmail.com)
Date: Thu Oct 27 2011 - 12:42:02 CDT

On Thu, Oct 27, 2011 at 12:43 PM, Mike Wykes <mikewykes_at_gmail.com> wrote:

> Hi there,
>
> I am a VMD novice and would greatly appreciate some help.
>
> Could someone tell me if it is possible to label all the
> covalent/coordinate bonds in a system (i.e. bonds shown by VMD when
> using the lines/bonds drawing method) without having to manually click
> every pair of bonded atoms ?
>

topo getbondlist
should give you an easily digestable list of bonds

http://sites.google.com/site/akohlmey/software/topotools/topotools---documentation#TOC-getbondlist-type-order-both-none-

and then you just need to do a loop and generate the
labels using the "label" command.
http://www.ks.uiuc.edu/Research/vmd/current/ug/node131.html

I imagine this must somehow be possible via the tcl command line, but
> I have no idea where to start.
>
> Could someone possibly point me in the right direction on how to go
> about generating the required command?
>

so you would have to do something like this
(off the top of my head and completely untested)

set mol [molinfo top]
foreach {b1 b2} [topo getbondlist none] {
  label add Bonds "$mol/$b1" "$mol/$b2"
}

good luck,
     axel.

>
> Many thanks,
>
> Mike
>

-- 
Dr. Axel Kohlmeyer
akohlmey_at_gmail.com  http://goo.gl/1wk0
Institute for Computational Molecular Science
Temple University, Philadelphia PA, USA.