53 Commits

Author SHA1 Message Date
Rapptz
eedd7e3014 Add support for new pink default avatars 2023-06-07 22:12:47 -04:00
Rapptz
2d6c50dbe1 Add note about colour changing 2023-02-28 09:02:42 -05:00
Leonardo
e161f6ef3e
Update colour constants 2023-02-23 00:45:51 -05:00
Rapptz
0c68eb338c Add colour previews to the documentation 2023-02-16 10:45:53 -05:00
TheMaster3558
9562a9683a
Add dark_embed and light_embed to Colour 2023-02-10 19:32:00 -05:00
Guddi
66d85007b7
Uppercase color codes in the docs 2022-11-21 01:16:01 -05:00
Rapptz
de941ababe Add Colour.from_str factory method
This moves the command extension parsing code over to the main library
since it can be potentially useful for others.
2022-04-20 06:49:28 -04:00
Kellen
0f18d93e47
Remove unused imports 2022-04-02 04:58:39 -04:00
Stocker
5aa696ccfa
Fix typing issues and improve typing completeness across the library
Co-authored-by: Danny <Rapptz@users.noreply.github.com>
Co-authored-by: Josh <josh.ja.butt@gmail.com>
2022-03-13 23:52:10 -04:00
Josh
147948af9b
Use typing.Self throughout library 2022-03-01 07:53:24 -05:00
Rapptz
88b520b5ab Reformat code using black
Segments where readability was hampered were fixed by appropriate
format skipping directives. New code should hopefully be black
compatible. The moment they remove the -S option is probably the moment
I stop using black though.
2022-02-20 08:04:58 -05:00
Ryan
c6a6c6af85
Add Colour.brand_green and Colour.brand_red 2021-08-24 07:02:36 -04:00
Rapptz
9a61a5a063 Typehint Colour.__init__ parameter 2021-08-24 03:15:28 -04:00
chromacoat dreamkey
c896563af4
Fix Colour.fuchsia docstring typo 2021-05-15 20:00:35 -04:00
Dorukyum
5ad88dec72
Change Colour.blurple to new one
This moves the old one to Colour.og_blurple.
2021-05-15 02:13:12 -04:00
Arnav Jindal
ee3e2944ba
Add Colour.fuchsia and Colour.yellow 2021-05-15 02:07:45 -04:00
Nadir Chowdhury
757cfad38f
Type up **kwargs of various methods 2021-05-10 20:24:48 -04:00
Josh
c69b20c52c
Type hint colour.py 2021-05-05 10:27:52 -04:00
numbermaniac
b84717fc76
Make spelling of "colour" consistent in docs 2021-04-27 04:37:35 -04:00
ppotatoo
f4a861d76e
Add __int__ to discord.Colour 2021-04-26 21:38:20 -04:00
Nadir Chowdhury
89456022cf
Add __all__ to remaining modules 2021-04-07 02:30:32 -04:00
Rapptz
9d39b135f4 Modernize code to use f-strings
This also removes the encoding on the top, since Python 3 does it by
default. It also changes some methods to use `yield from`.
2021-04-04 07:03:53 -04:00
Maselkov
baa1ab058b
Add an optional seed parameter for Colour.random 2021-03-28 06:28:35 -04:00
Nihaal Sangha
69bdc3a184
Change copyright year to present 2021-01-15 05:28:11 -05:00
Rapptz
6caa983b5e Clarify Colour.random RNG 2020-11-21 22:18:39 -05:00
Caio Alexandre
896a5bef1d Add Colour.random factory method 2020-11-21 22:16:41 -05:00
Josh
62040de6a7
Fix Colour.dark_theme docstring. 2020-10-16 22:51:50 -04:00
BluePhoenixGame
4b18238ade
Add discord.Colour classmethod dark_theme 2020-09-09 00:52:19 -04:00
SebbyLaw
9b24ff4f77 Add gray alias for discord.Colour 2020-07-22 23:18:29 -04:00
Skezza
c3bca7ec73
Documentation formatting 2020-06-30 23:32:00 -04:00
Sebastian Law
b4b953bfc6
Fix various inconsistencies within the documentation (#5067) 2020-06-28 03:45:58 -04:00
Rapptz
6071607176 Bump copyright year to 2020
Closes #2510
2020-01-19 20:03:00 -05:00
NCPlayz
3c9bcc2851 Improve documentation 2019-06-07 19:27:46 -04:00
Dante Dam
9656a21ebe Bumped copyright years to 2019. 2019-01-28 22:22:50 -05:00
bmintz
bb8b3bf2aa Add Colour.from_hsv
HSV is an easier to use colour format, and its inclusion in the colour
module will hopefully encourage its use.
2018-08-22 21:06:09 -04:00
Tobotimus
3112e1c17e Add intersphinx 2018-01-06 17:23:59 -05:00
Rapptz
f4e01b3a92 Make supported operations stand out more than attributes. 2017-05-20 02:08:34 -04:00
Rapptz
7a84661312 Rename Colour.to_tuple to Colour.to_rgb. 2017-05-15 03:40:27 -04:00
Rapptz
6f53491f9a Add Colour.from_rgb. 2017-05-15 03:37:21 -04:00
Rapptz
4023510032 Use describe for Colour documentation. 2017-05-15 02:29:03 -04:00
Rapptz
96eca8aa53 Add Colour.blurple and Colour.greyple. 2017-05-13 17:39:12 -04:00
Rapptz
702d596af9 Check that the type in Colour and Permissions are int. 2017-02-21 08:19:32 -05:00
Rapptz
ff9f5749e1 Update copyright year to 2017. 2017-01-20 23:19:19 -05:00
Rapptz
dceba9d962 Add useful repr to all data classes. 2017-01-03 09:52:06 -05:00
Rapptz
e4b16851bf Slots use tuples instead now. 2017-01-03 09:51:50 -05:00
Rapptz
07607060c1 Fix Colour.__str__ to actually pad zeroes. 2016-06-16 22:49:34 -04:00
Rapptz
db4cc791dd Update license of files to 2016. 2016-01-04 22:28:29 -05:00
Rapptz
f1f0e169e4 Add __slots__ where appropriate to data classes. 2015-12-19 06:18:12 -05:00
Rapptz
51d91c2a82 Most data classes now support hashing. 2015-12-17 00:32:54 -05:00
Rapptz
9137d92f67 All data classes now support !=, == and str(obj). 2015-12-13 22:53:48 -05:00