| Unit: | SDL_cstruct | | Class: | TCTab | | Declaration: | function CalcMolExtents (var MinX, MinY, MaxX, MAxY,CentX, CentY: double): double; |
The method CalcMolExtents calculates the dimensions of the drawing of a structure as it is stored in the connection table. The coordinates returned set up a rectangle which encloses the structure. If no structure at all or no graphics information is contained in the connection table, a rectangle is returned which covers the whole virtual screen (MinX=0, MaxX=10000, MinY=0, MaxY=7000). In addition,CalcMolExtents also calculates the average bond length of the molecule and the center of the molecule. The average bond length is returned as the function value.
| Hint: |
The coordinates of the center of the molecule are calculated as the average of all atom coordinates. This is not necessarily equal to the half of the maximum extents. |
|