Return 'PROPNAME or alias' if *s* has an alias, else return 'PROPNAME', formatted for reST. For example, for the line markerfacecolor property, which has an alias, return 'markerfacecolor or mfc' and for the transform property, which does not, return 'transf
(self, s, target)
| 1657 | } |
| 1658 | |
| 1659 | def aliased_name_rest(self, s, target): |
| 1660 | """ |
| 1661 | Return 'PROPNAME or alias' if *s* has an alias, else return 'PROPNAME', |
| 1662 | formatted for reST. |
| 1663 | |
| 1664 | For example, for the line markerfacecolor property, which has an |
| 1665 | alias, return 'markerfacecolor or mfc' and for the transform |
| 1666 | property, which does not, return 'transform'. |
| 1667 | """ |
| 1668 | # workaround to prevent "reference target not found" |
| 1669 | if target in self._NOT_LINKABLE: |
| 1670 | return f'``{s}``' |
| 1671 | |
| 1672 | aliases = ''.join( |
| 1673 | f' or :meth:`{a} <{target}>`' for a in sorted(self.aliasd.get(s, []))) |
| 1674 | return f':meth:`{s} <{target}>`{aliases}' |
| 1675 | |
| 1676 | def pprint_setters(self, prop=None, leadingspace=2): |
| 1677 | """ |
no test coverage detected