Class AtomMassGenerator
java.lang.Object
org.openscience.cdk.renderer.generators.BasicAtomGenerator
org.openscience.cdk.renderer.generators.AtomMassGenerator
- All Implemented Interfaces:
IGenerator<IAtomContainer>
IGenerator that can render mass number information of atoms.-
Nested Class Summary
Nested classes/interfaces inherited from class BasicAtomGenerator
BasicAtomGenerator.AtomColor, BasicAtomGenerator.AtomColorer, BasicAtomGenerator.AtomRadius, BasicAtomGenerator.ColorByType, BasicAtomGenerator.CompactAtom, BasicAtomGenerator.CompactShape, BasicAtomGenerator.KekuleStructure, BasicAtomGenerator.Shape, BasicAtomGenerator.ShowEndCarbons, BasicAtomGenerator.ShowExplicitHydrogensModifier and TypeClassDescriptionstatic classClass to hold the color by which atom labels are drawn.static classIAtomColorerused to draw elements.static classMagic number with unknown units that defines the radius around an atom, e.g. used for highlighting atoms.static classBoolean property that triggers atoms to be colored by type when set to true.static classBoolean parameters that will cause atoms to be drawn as filled shapes when set to true.static classShape to be used when drawing atoms in compact mode, as defined by theBasicAtomGenerator.CompactAtomparameter.static classDetermines whether structures should be drawn as Kekule structures, thus giving each carbon element explicitly, instead of not displaying the element symbol.static enumWhen atoms are selected or in compact mode, they will be covered by a shape determined by this enumeration.static classBoolean parameters that will show carbons with only one (non-hydrogen) neighbor to be drawn with an element symbol.static classBoolean property that triggers explicit hydrogens to be drawn if set to true. -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionbooleanshowCarbon(IAtom atom, IAtomContainer container, RendererModel model) Returns true if the mass number of this element is set and not equal the mass number of the most abundant isotope of this element.Methods inherited from class BasicAtomGenerator
canDraw, generate, generate, generateCompactElement, generateElement, getAtomColor, getParameters, hasCoordinates, invisibleCarbon, invisibleHydrogen, isHydrogenModifier and TypeMethodDescriptionprotected booleancanDraw(IAtom atom, IAtomContainer container, RendererModel model) Checks an atom to see if it should be drawn.generate(IAtomContainer atomContainer, IAtom atom, RendererModel model) Generate the rendering element(s) for a particular atom.generate(IAtomContainer container, RendererModel model) Converts aIChemObjectfrom the chemical data model into something that can be drawn in the chemical drawing.generateCompactElement(IAtom atom, RendererModel model) Generate a compact element for an atom, such as a circle or a square, rather than text element.generateElement(IAtom atom, int alignment, RendererModel model) Generate an atom symbol element.protected ColorgetAtomColor(IAtom atom, RendererModel model) Returns the drawing color of the given atom.Returns the list ofIGeneratorParameterfor this particular generator.protected booleanhasCoordinates(IAtom atom) Checks an atom to see if it has 2D coordinates.protected booleaninvisibleCarbon(IAtom atom, IAtomContainer atomContainer, RendererModel model) Checks an atom to see if it is an 'invisible carbon' - that is, it is: a) a carbon atom and b) this carbon should not be shown.protected booleaninvisibleHydrogen(IAtom atom, RendererModel model) Checks an atom to see if it is an 'invisible hydrogen' - that is, it is a) an (explicit) hydrogen, and b) explicit hydrogens are set to off.protected booleanisHydrogen(IAtom atom) Determines if the atom is a hydrogen.
-
Constructor Details
-
AtomMassGenerator
public AtomMassGenerator()
-
-
Method Details
-
showCarbon
Returns true if the mass number of this element is set and not equal the mass number of the most abundant isotope of this element.- Overrides:
showCarbonin classBasicAtomGenerator- Parameters:
atom-IAtomwhich is being examinedcontainer-IAtomContainerof which the atom is partmodel- theRendererModel- Returns:
- true, when mass number information should be depicted
-