Start updating some wx.lib docstrings

This commit is contained in:
Robin Dunn
2016-06-09 21:46:05 -07:00
parent ddfbc17469
commit dd552ce670
11 changed files with 255 additions and 274 deletions

View File

@@ -36,8 +36,8 @@ def AdjustAlpha(colour, alpha):
:param integer `alpha`: the new value for the colour alpha channel (between 0
and 255).
:rtype: :class:`Colour`
:returns: A new :class:`Colour` with the alpha channel specified as input
:rtype: :class:`wx.Colour`
:returns: A new :class:`wx.Colour` with the alpha channel specified as input
"""
return wx.Colour(colour.Red(), colour.Green(), colour.Blue(), alpha)
@@ -48,12 +48,12 @@ def AdjustColour(color, percent, alpha=wx.ALPHA_OPAQUE):
Brighten/darken input colour by `percent` and adjust alpha
channel if needed. Returns the modified color.
:param Colour `color`: color object to adjust;
:param wx.Colour `color`: color object to adjust;
:param integer `percent`: percent to adjust +(brighten) or -(darken);
:param integer `alpha`: amount to adjust alpha channel.
:rtype: :class:`Colour`
:returns: A new darkened/lightened :class:`Colour` with the alpha channel
:rtype: :class:`wx.Colour`
:returns: A new darkened/lightened :class:`wx.Colour` with the alpha channel
specified as input
"""
@@ -76,10 +76,10 @@ def BestLabelColour(color, bw=False):
Get the best color to use for the label that will be drawn on
top of the given color.
:param Colour `color`: background color that text will be drawn on;
:param wx.Colour `color`: background color that text will be drawn on;
:param bool `bw`: If ``True``, only return black or white.
:rtype: :class:`Colour`
:rtype: :class:`wx.Colour`
"""
avg = sum(color.Get()) / 3
@@ -100,7 +100,7 @@ def GetHighlightColour():
"""
Gets the default highlight color.
:rtype: :class:`Colour`
:rtype: :class:`wx.Colour`
"""
if wx.Platform == '__WXMAC__':