.. oe:namespace:: OEGrapheme


.. meta::
   :keywords: OEBondGlyphBase, BondGlyphBase


.. _OEGrapheme_OEBondGlyphBase:

.. oe:class:: OEBondGlyphBase

   .. oe:api::

      class OEBondGlyphBase

   :ref:`OEBondGlyphBase <OEGrapheme_OEBondGlyphBase>` is an abstract class that
   defines the interface used for bond annotation.

   .. seealso::

      * :ref:`chapter_annotation` chapter
      * :oe:func:`OEGrapheme::OEAddGlyph` function.

   The following classes derive from this class:

    * :ref:`OEBondGlyphArrow <OEGrapheme_OEBondGlyphArrow>`
    * :ref:`OEBondGlyphCircle <OEGrapheme_OEBondGlyphCircle>`
    * :ref:`OEBondGlyphCross <OEGrapheme_OEBondGlyphCross>` class
    * :ref:`OEBondGlyphCurvedArrow <OEGrapheme_OEBondGlyphCurvedArrow>` class
    * :ref:`OEBondGlyphScissors <OEGrapheme_OEBondGlyphScissors>` class
    * :ref:`OEBondGlyphStitch <OEGrapheme_OEBondGlyphStitch>` class
    * :ref:`OEBondGlyphZigZag <OEGrapheme_OEBondGlyphZigZag>` class


   .. ################################################################
      #
      ################################################################

   .. oe:method:: Constructors

      .. oe:language:: c++ java csharp

         .. oe:api::

            OEBondGlyphBase()

      .. oe:language:: python

         .. oe:api:: python

            OEBondGlyphBase() -> OEBondGlyphBase

      Default constructor.


   .. ################################################################
      #
      ################################################################

   .. oe:method:: CreateCopy

      .. oe:language:: c++ java csharp

         .. oe:api::

            virtual OEBondGlyphBase* CreateCopy() const = 0

      .. oe:language:: python

         .. oe:api:: python

            CreateCopy() -> OEBondGlyphBase

      Virtual const constructor which allows copying of concrete
      derived objects using a reference to this base class.


   .. ################################################################
      #
      ################################################################

   .. oe:method:: RenderGlyph

      .. oe:language:: c++ java csharp

         .. oe:api::

            bool RenderGlyph(OEDepict::OE2DMolDisplay &,
                             const OEChem::OEBondBase *) const = 0

      .. oe:language:: python

         .. oe:api:: python

            RenderGlyph(disp: OE2DMolDisplay, bond: OEBondBase) -> bool

      It is a virtual const method that is implemented in the concrete
      derived classes to annotate the given bond (*i.e.* to draw a `glyph` to
      mark the bond).

      *disp*
         The :ref:`OE2DMolDisplay <OEDepict_OE2DMolDisplay>` object that is modified
         to annotate the specified bond.

      *atom*
         The :ref:`OEBondBase <OEChem_OEBondBase>` object being annotated.
