Author: bugman
Date: Thu Dec 11 10:38:43 2014
New Revision: 27075

URL: http://svn.gna.org/viewcvs/relax?rev=27075&view=rev
Log:
More improvements for the structure ID strings returned by the 
assemble_coord_array() function.


Modified:
    trunk/lib/structure/internal/coordinates.py

Modified: trunk/lib/structure/internal/coordinates.py
URL: 
http://svn.gna.org/viewcvs/relax/trunk/lib/structure/internal/coordinates.py?rev=27075&r1=27074&r2=27075&view=diff
==============================================================================
--- trunk/lib/structure/internal/coordinates.py (original)
+++ trunk/lib/structure/internal/coordinates.py Thu Dec 11 10:38:43 2014
@@ -96,12 +96,12 @@
                         atom_elem.append({})
 
                     # Create a new structure ID.
-                    ids.append('')
-                    if len(object_names) > 1:
-                        ids[-1] += object_names[struct_index]
-                    if model.num != None:
-                        ids[-1] += ", %i" % model.num
-                    ids[-1] += ", %s" % mol_name
+                    if len(object_names) > 1 and model.num != None:
+                        ids.append('%s, %i, %s' % (object_names[struct_index], 
model.num, mol_name))
+                    elif len(object_names) > 1:
+                        ids.append('%s, %s' % (object_names[struct_index], 
mol_name))
+                    else:
+                        ids.append('%s' % mol_name)
 
                 # A unique identifier.
                 if molecules != None:


_______________________________________________
relax (http://www.nmr-relax.com)

This is the relax-commits mailing list
[email protected]

To unsubscribe from this list, get a password
reminder, or change your subscription options,
visit the list information page at
https://mail.gna.org/listinfo/relax-commits

Reply via email to