.. include:: ../../common/cookbook/cookbook-hyperlinks
.. include:: ../../toolkit-substitutions
.. include:: ../substitutions

.. oe:namespace:: OEGrapheme


.. _OEGrapheme_OEPeptideDisplayOptions:

.. oe:class:: OEPeptideDisplayOptions

   .. oe:api::

      class OEPeptideDisplayOptions

   This class represents the :ref:`OEPeptideDisplayOptions <OEGrapheme_OEPeptideDisplayOptions>` class
   that encapsulates properties that determine how a peptide is depicted.

   .. seealso::

      * :oe:func:`OEGrapheme::OEDrawPeptide` function

   .. admonition:: Code Example

      * `Depict Peptide`_ **OpenEye Python Cookbook** recipe

   .. oe:method:: Constructors

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

         .. oe:api::

            OEPeptideDisplayOptions()

      .. oe:language:: python

         .. oe:api:: python

            OEPeptideDisplayOptions() -> OEPeptideDisplayOptions

      Default constructor.

      .. _figure_ OEPeptideDisplayOptions_Default:

      .. only:: oehtml

         .. figure:: ../images/OEPeptideDisplayOptions_Default.svg
            :align:  center
            :width:  600pt

            **Peptide depiction with default options**

      .. only:: oepdf

         .. figure:: ../images/OEPeptideDisplayOptions_Default.*
            :align:  center
            :width:  600pt

            **Peptide depiction with default options**


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

         .. oe:api::

            OEPeptideDisplayOptions(const OEPeptideDisplayOptions& rhs)

      .. oe:language:: python

         .. oe:api:: python

            OEPeptideDisplayOptions(style: int) -> OEPeptideDisplayOptions
            OEPeptideDisplayOptions(arg2: OEPeptideDisplayOptions) -> OEPeptideDisplayOptions

      Copy constructor.


   .. oe:method:: operator=
      :language: c++

      .. oe:api::

         OEPeptideDisplayOptions &operator=(const OEPeptideDisplayOptions &rhs)

      Assignment operator.


   .. oe:method:: GetAminoAcidScale

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

         .. oe:api::

            double GetAminoAcidScale() const

      .. oe:language:: python

         .. oe:api:: python

            GetAminoAcidScale() -> float

      Returns the scaling factor of amino-acid components in interactive mode.

      .. seealso::

         * :oe:meth:`OEGrapheme::OEPeptideDisplayOptions::SetAminoAcidScale` method


   .. oe:method:: GetInteractive

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

         .. oe:api::

            bool GetInteractive() const

      .. oe:language:: python

         .. oe:api:: python

            GetInteractive() -> bool

      Returns whether the generated :file:`svg` image will be interactive.

      .. seealso::

         * :oe:meth:`OEGrapheme::OEPeptideDisplayOptions::SetInteractive` method


   .. oe:method:: GetLabelStyle

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

         .. oe:api::

            unsigned int GetLabelStyle() const

      .. oe:language:: python

         .. oe:api:: python

            GetLabelStyle() -> int

      .. warning::

         |DEPRECATED-API|

   .. oe:method:: SetAminoAcidScale

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

         .. oe:api::

            void SetAminoAcidScale(double scale)

      .. oe:language:: python

         .. oe:api:: python

            SetAminoAcidScale(scale: float) -> None


      Sets the scaling factor of amino-acid components in interactive mode.

      scale
         This value has to be in a range of [0.25, 0.75]. The default value is 0.50.

      .. note::

         This option has to be used along with the
         :oe:meth:`OEGrapheme::OEPeptideDisplayOptions::SetInteractive` method

      **Example:**

      .. oe:source:: OEPeptideDispOpts_SetOpts.py
         :language: python
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETAMINOACIDSCALE

      .. oe:source:: OEPeptideDispOpts_SetOpts.cpp
         :language: c++
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETAMINOACIDSCALE

      .. oe:source:: OEPeptideDispOpts_SetOpts.java
         :language: java
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETAMINOACIDSCALE

      .. oe:source:: OEPeptideDispOpts_SetOpts.cs
         :language: csharp
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETAMINOACIDSCALE

      .. _figure_OEPeptideDisplayOptions_SetAminoAcidScale:

      .. only:: oehtml

         .. raw:: html

            <p align="center">
            <object data="../../_images/OEPeptideDisplayOptions_SetAminoAcidScale.svg" type="image/svg+xml"  width = "600" ></object>
            <p>

         .. the below is necessary to copy over the image to the build subdirectory

         .. image:: ../images/OEPeptideDisplayOptions_SetAminoAcidScale.svg
            :width: 1pt

      .. only:: oepdf

         |NOPDFIMAGE|

      .. note::

         This functionality is **only available** for :file:`.svg`
         image format. In other image formats it has no effect.


   .. oe:method:: SetInteractive

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

         .. oe:api::

            void SetInteractive(bool interactive)

      .. oe:language:: python

         .. oe:api:: python

            SetInteractive(interactive: bool) -> None

      Sets whether the generated :file:`svg` image will be interactive.
      In interactive mode the amino acid components of the compact peptide representation
      are depicted on mouse over.

      **Example:**

      .. oe:source:: OEPeptideDispOpts_SetOpts.py
         :language: python
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETINTERACTIVE

      .. oe:source:: OEPeptideDispOpts_SetOpts.cpp
         :language: c++
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETINTERACTIVE

      .. oe:source:: OEPeptideDispOpts_SetOpts.java
         :language: java
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETINTERACTIVE

      .. oe:source:: OEPeptideDispOpts_SetOpts.cs
         :language: csharp
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETINTERACTIVE


      .. _figure_OEPeptideDisplayOptions_SetInteractive:

      .. only:: oehtml

         .. raw:: html

            <p align="center">
            <object data="../../_images/OEPeptideDisplayOptions_SetInteractive.svg" type="image/svg+xml"  width = "600" ></object>
            <p>

         .. the below is necessary to copy over the image to the build subdirectory

         .. image:: ../images/OEPeptideDisplayOptions_SetInteractive.svg
            :width: 1pt

      .. only:: oepdf

         |NOPDFIMAGE|

      .. note::

         This functionality is **only available** for :file:`.svg`
         image format. In other image formats it has no effect.


   .. oe:method:: SetLabelStyle

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

         .. oe:api::

            void SetLabelStyle(unsigned int style)

      .. oe:language:: python

         .. oe:api:: python

            SetLabelStyle(style: int) -> None

      .. warning::

         |DEPRECATED-API|

      *style*
         This value has to be from the :oe:constns:`OEGrapheme::OEPeptideLabelStyle`
         namespace.

      **Example:**

      .. oe:source:: OEPeptideDispOpts_SetOpts.py
         :language: python
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETLABELSTYLE

      .. oe:source:: OEPeptideDispOpts_SetOpts.cpp
         :language: c++
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETLABELSTYLE

      .. oe:source:: OEPeptideDispOpts_SetOpts.java
         :language: java
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETLABELSTYLE

      .. oe:source:: OEPeptideDispOpts_SetOpts.cs
         :language: csharp
         :noindent:
         :frag:     SNIPPET-OEPEPTIDEDISPLAYOPTIONS-SETLABELSTYLE

      .. _figure_OEPeptideDisplayOptions_SetLabelStyle:

      .. only:: oehtml

         .. figure:: ../images/OEPeptideDisplayOptions_SetLabelStyle.svg
            :align:  center
            :width:  600pt

            **Peptide depiction with single letter style**

      .. only:: oepdf

         .. figure:: ../images/OEPeptideDisplayOptions_SetLabelStyle.*
            :align:  center
            :width:  600pt

            **Peptide depiction with single letter style**

      .. seealso::

         * :oe:constns:`OEGrapheme::OEPeptideLabelStyle` namespace
