MCPcopy Index your code
hub / github.com/plotly/plotly.py / description

Method description

_plotly_utils/basevalidators.py:1577–1603  ·  view source on GitHub ↗
(self)

Source from the content-addressed store, hash-verified

1575 return self._named_colorscales
1576
1577 def description(self):
1578 colorscales_str = "\n".join(
1579 textwrap.wrap(
1580 repr(sorted(list(self.named_colorscales))),
1581 initial_indent=" " * 12,
1582 subsequent_indent=" " * 13,
1583 break_on_hyphens=False,
1584 width=80,
1585 )
1586 )
1587
1588 desc = """\
1589 The '{plotly_name}' property is a colorscale and may be
1590 specified as:
1591 - A list of colors that will be spaced evenly to create the colorscale.
1592 Many predefined colorscale lists are included in the sequential, diverging,
1593 and cyclical modules in the plotly.colors package.
1594 - A list of 2-element lists where the first element is the
1595 normalized color level value (starting at 0 and ending at 1),
1596 and the second item is a valid color string.
1597 (e.g. [[0, 'green'], [0.5, 'red'], [1.0, 'rgb(0, 0, 255)']])
1598 - One of the following named colorscales:
1599{colorscales_str}.
1600 Appending '_r' to a named colorscale reverses it.
1601""".format(plotly_name=self.plotly_name, colorscales_str=colorscales_str)
1602
1603 return desc
1604
1605 def validate_coerce(self, v):
1606 v_valid = False

Callers

nothing calls this directly

Calls 2

wrapMethod · 0.45
formatMethod · 0.45

Tested by

no test coverage detected