class OEPrepareDepictionOptions

This class represents OEPrepareDepictionOptions that stores the following parameters that are used when preparing a molecule for depiction.

Property Get method Set method Corresponding namespace / type
re-generating 2D coordinates GetClearCoords SetClearCoords boolean
adding depiction hydrogens GetAddDepictionHydrogens SetAddDepictionHydrogens boolean
perceiving MDL bond stereo (wedge/hash) GetPerceiveBondStereo SetPerceiveBondStereo boolean
suppressing explicit (non-depiction) hydrogens GetSuppressHydrogens SetSuppressHydrogens boolean
depiction orientation GetDepictOrientation SetDepictOrientation OEDepictOrientation

See also

See the effect of the above parameters in Table: Depictions generated with various parameter combinations when depiction are generated from the following input:

Parsing the “CC([C@@H]1C[C@@H]2C[C@H]1NC2)N(H)(H)” string with three explicit hydrogens necessary to define tetrahedral stereo centers and two additional explicit hydrogens.
Reading an MDL file with 2D coordinates and pre-assigned wedge/hash bonds. It also includes two explicit hydrogens.
Depictions generated with various parameter combinations
index clear coordinates suppress explicit H add depict H perceive wedge/hash from SMILES from MDL
(1) F F F F ../../_images/OEPrepDepictOpts-SMI-cc-0-sH-0-aH-0-pBS-0.png ../../_images/OEPrepDepictOpts-MDL-cc-0-sH-0-aH-0-pBS-0.png
(2) F F F T    
(3) F F T F    
(4) F F T T ../../_images/OEPrepDepictOpts-SMI-cc-0-sH-0-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-0-sH-0-aH-1-pBS-1.png
(5) F T F F    
(6) F T F T    
(7) F T T F    
(8) F T T T ../../_images/OEPrepDepictOpts-SMI-cc-0-sH-1-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-0-sH-1-aH-1-pBS-1.png
(9) T F F F    
(10) T F F T ../../_images/OEPrepDepictOpts-SMI-cc-1-sH-0-aH-0-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-1-sH-0-aH-0-pBS-1.png
(11) T F T F    
(12) T F T T ../../_images/OEPrepDepictOpts-SMI-cc-1-sH-0-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-1-sH-0-aH-1-pBS-1.png
(13) T T F F    
(14) T T F T    
(15) T T T F    
(16) T T T T ../../_images/OEPrepDepictOpts-SMI-cc-1-sH-1-aH-1-pBS-1.png ../../_images/OEPrepDepictOpts-MDL-cc-1-sH-1-aH-1-pBS-1.png


MDL = no op; SMILES = generating 2D coordinates is necessary
MDL = keeping original 2D coordinates, adding depiction hydrogens, re-perceiving wedge/hash bonds; SMILES = generating 2D coordinates, depiction hydrogens are kept; perceiving wedge/hash bonds
Default parameters; MDL = keeping original 2D coordinates, re-perceiving all other information; SMILES = generating 2D coordinates, regenerating all other information;
MDL = regenerating 2D coordinates and re-perceiving wedge/hash bonds (since no depiction hydrogens are added the wedge/hash bonds are on ring bonds); SMILES generating 2D coordinates and perceiving wedge/hash bonds;
Regenerating all information and keeping all explicit hydrogens
Regenerating all information; the depiction of identical molecules imported from SMILES and MDL will be identical


OEPrepareDepictionOptions(bool clearcoords=false, bool suppressH=true)

Default constructor that initializes an OEPrepareDepictionOptions object with the following properties:

See the OEPrepareDepictionOptions.SetClearCoords method.
See the OEPrepareDepictionOptions.SetSuppressHydrogens method.
Default parameters of the OEPrepareDepictionOptions class
Property Default value
re-generating 2D coordinates false
adding depiction hydrogens true
perceiving MDL bond stereo (wedge/hash) true
suppressing explicit (non-depiction) hydrogens true
depiction orientation OEDepictOrientation.Default
OEPrepareDepictionOptions(const OEPrepareDepictionOptions &rhs)

Copy constructor.


OEPrepareDepictionOptions &operator=(const OEPrepareDepictionOptions &rhs)

Assignment operator.


bool GetAddDepictionHydrogens() const

Returns whether the depiction hydrogens are kept/added.


bool GetClearCoords() const

Returns whether the 2D coordinates of a molecule are re-calculated.


unsigned int GetDepictOrientation() const

Returns the preferred orientation of the 2D coordinates. The return value is taken from the OEDepictOrientation namespace.


bool GetPerceiveBondStereo() const

Returns whether the hash/wedge bonds are re-assigned.


bool GetSuppressHydrogens() const

Returns whether the explicit (non-depiction) hydrogens are suppressed.


void SetAddDepictionHydrogens(bool)

Sets whether depiction hydrogens are kept/added.


void SetClearCoords(bool clearcoords)

Sets whether the 2D coordinates of the molecule are re-calculated. If the molecule has no 2D coordinates, then the 2D coordinates are always calculated by calling the OEDepictCoordinates regardless of this setting.


void SetDepictOrientation(unsigned int orientation)

Sets the preferred orientation of the 2D coordinates.

This value has to be from the OEDepictOrientation namespace.


void SetPerceiveBondStereo(bool)

Sets whether to re-assign the wedge and hash bonds by calling the OEMDLPerceiveBondStereo function.

See also


void SetSuppressHydrogens(bool)

Sets whether the explicit (non-depiction) hydrogens are suppressed in the molecule. Only hydrogens that are necessary to faithfully represent tetrahedral stereo-chemistry will be kept.

See also