microGUI.Drawing.Color ====================== .. py:module:: microGUI.Drawing.Color Classes ------- .. autoapisummary:: microGUI.Drawing.Color.eColors microGUI.Drawing.Color.ColorBase microGUI.Drawing.Color.Color Module Contents --------------- .. py:class:: eColors Collection of standard colors for use by a Galaxie microGUI application .. seealso:: - :py:class:`microGUI.Drawing.Color.Color` - :py:attr:`microGUI.Widgets.Basic.Basic` - :py:attr:`microGUI.Widgets.Basic.Basic.Color` - :py:attr:`microGUI.Widgets.Basic.Basic.LightFillColor` - :py:attr:`microGUI.Widgets.Basic.Basic.DarkFillColor` - :py:attr:`microGUI.Widgets.Basic.Basic.LightBevelColor` - :py:attr:`microGUI.Widgets.Basic.Basic.DarkBevelColor` .. py:attribute:: AliceBlue :type: int :value: 4293982463 .. py:attribute:: AntiqueWhite :type: int :value: 4294634455 .. py:attribute:: Aqua :type: int :value: 4278255615 .. py:attribute:: Aquamarine :type: int :value: 4286578644 .. py:attribute:: Azure :type: int :value: 4293984255 .. py:attribute:: Beige :type: int :value: 4294309340 .. py:attribute:: Bisque :type: int :value: 4294960324 .. py:attribute:: Black :type: int :value: 4278190080 .. py:attribute:: BlanchedAlmond :type: int :value: 4294962125 .. py:attribute:: Blue :type: int :value: 4278190335 .. py:attribute:: BlueViolet :type: int :value: 4287245282 .. py:attribute:: Brown :type: int :value: 4289014314 .. py:attribute:: BurlyWood :type: int :value: 4292786311 .. py:attribute:: CadetBlue :type: int :value: 4284456608 .. py:attribute:: Chartreuse :type: int :value: 4286578432 .. py:attribute:: Chocolate :type: int :value: 4291979550 .. py:attribute:: Coral :type: int :value: 4294934352 .. py:attribute:: CornflowerBlue :type: int :value: 4284782061 .. py:attribute:: Cornsilk :type: int :value: 4294965468 .. py:attribute:: Crimson :type: int :value: 4292613180 .. py:attribute:: Cyan :type: int :value: 4278255615 .. py:attribute:: DarkBlue :type: int :value: 4278190219 .. py:attribute:: DarkCyan :type: int :value: 4278225803 .. py:attribute:: DarkGoldenrod :type: int :value: 4290283019 .. py:attribute:: DarkGray :type: int :value: 4289309097 .. py:attribute:: DarkGreen :type: int :value: 4278215680 .. py:attribute:: DarkKhaki :type: int :value: 4290623339 .. py:attribute:: DarkMagenta :type: int :value: 4287299723 .. py:attribute:: DarkOliveGreen :type: int :value: 4283788079 .. py:attribute:: DarkOrange :type: int :value: 4294937600 .. py:attribute:: DarkOrchid :type: int :value: 4288230092 .. py:attribute:: DarkRed :type: int :value: 4287299584 .. py:attribute:: DarkSalmon :type: int :value: 4293498490 .. py:attribute:: DarkSeaGreen :type: int :value: 4287609999 .. py:attribute:: DarkSlateBlue :type: int :value: 4282924427 .. py:attribute:: DarkSlateGray :type: int :value: 4281290575 .. py:attribute:: DarkTurquoise :type: int :value: 4278243025 .. py:attribute:: DarkViolet :type: int :value: 4287889619 .. py:attribute:: DeepPink :type: int :value: 4294907027 .. py:attribute:: DeepSkyBlue :type: int :value: 4278239231 .. py:attribute:: DimGray :type: int :value: 4285098345 .. py:attribute:: DodgerBlue :type: int :value: 4280193279 .. py:attribute:: Firebrick :type: int :value: 4289864226 .. py:attribute:: FloralWhite :type: int :value: 4294966000 .. py:attribute:: ForestGreen :type: int :value: 4280453922 .. py:attribute:: Fuchsia :type: int :value: 4294902015 .. py:attribute:: Gainsboro :type: int :value: 4292664540 .. py:attribute:: GhostWhite :type: int :value: 4294506751 .. py:attribute:: Gold :type: int :value: 4294956800 .. py:attribute:: Goldenrod :type: int :value: 4292519200 .. py:attribute:: Gray :type: int :value: 4286611584 .. py:attribute:: Green :type: int :value: 4278222848 .. py:attribute:: GreenYellow :type: int :value: 4289593135 .. py:attribute:: Honeydew :type: int :value: 4293984240 .. py:attribute:: HotPink :type: int :value: 4294928820 .. py:attribute:: IndianRed :type: int :value: 4291648604 .. py:attribute:: Indigo :type: int :value: 4283105410 .. py:attribute:: Ivory :type: int :value: 4294967280 .. py:attribute:: Khaki :type: int :value: 4293977740 .. py:attribute:: Lavender :type: int :value: 4293322490 .. py:attribute:: LavenderBlush :type: int :value: 4294963445 .. py:attribute:: LawnGreen :type: int :value: 4286381056 .. py:attribute:: LemonChiffon :type: int :value: 4294965965 .. py:attribute:: LightBlue :type: int :value: 4289583334 .. py:attribute:: LightCoral :type: int :value: 4293951616 .. py:attribute:: LightCyan :type: int :value: 4292935679 .. py:attribute:: LightGoldenrodYellow :type: int :value: 4294638290 .. py:attribute:: LightGray :type: int :value: 4292072403 .. py:attribute:: LightGreen :type: int :value: 4287688336 .. py:attribute:: LightPink :type: int :value: 4294948545 .. py:attribute:: LightSalmon :type: int :value: 4294942842 .. py:attribute:: LightSeaGreen :type: int :value: 4280332970 .. py:attribute:: LightSkyBlue :type: int :value: 4287090426 .. py:attribute:: LightSlateGray :type: int :value: 4286023833 .. py:attribute:: LightSteelBlue :type: int :value: 4289774814 .. py:attribute:: LightYellow :type: int :value: 4294967264 .. py:attribute:: Lime :type: int :value: 4278255360 .. py:attribute:: LimeGreen :type: int :value: 4281519410 .. py:attribute:: Linen :type: int :value: 4294635750 .. py:attribute:: Magenta :type: int :value: 4294902015 .. py:attribute:: Maroon :type: int :value: 4286578688 .. py:attribute:: MediumAquamarine :type: int :value: 4284927402 .. py:attribute:: MediumBlue :type: int :value: 4278190285 .. py:attribute:: MediumOrchid :type: int :value: 4290401747 .. py:attribute:: MediumPurple :type: int :value: 4287852763 .. py:attribute:: MediumSeaGreen :type: int :value: 4282168177 .. py:attribute:: MediumSlateBlue :type: int :value: 4286277870 .. py:attribute:: MediumSpringGreen :type: int :value: 4278254234 .. py:attribute:: MediumTurquoise :type: int :value: 4282962380 .. py:attribute:: MediumVioletRed :type: int :value: 4291237253 .. py:attribute:: MidnightBlue :type: int :value: 4279834992 .. py:attribute:: MintCream :type: int :value: 4294311930 .. py:attribute:: MistyRose :type: int :value: 4294960353 .. py:attribute:: Moccasin :type: int :value: 4294960309 .. py:attribute:: NavajoWhite :type: int :value: 4294958765 .. py:attribute:: Navy :type: int :value: 4278190208 .. py:attribute:: OldLace :type: int :value: 4294833638 .. py:attribute:: Olive :type: int :value: 4286611456 .. py:attribute:: OliveDrab :type: int :value: 4285238819 .. py:attribute:: Orange :type: int :value: 4294944000 .. py:attribute:: OrangeRed :type: int :value: 4294919424 .. py:attribute:: Orchid :type: int :value: 4292505814 .. py:attribute:: PaleGoldenrod :type: int :value: 4293847210 .. py:attribute:: PaleGreen :type: int :value: 4288215960 .. py:attribute:: PaleTurquoise :type: int :value: 4289720046 .. py:attribute:: PaleVioletRed :type: int :value: 4292571283 .. py:attribute:: PapayaWhip :type: int :value: 4294963157 .. py:attribute:: PeachPuff :type: int :value: 4294957753 .. py:attribute:: Peru :type: int :value: 4291659071 .. py:attribute:: Pink :type: int :value: 4294951115 .. py:attribute:: Plum :type: int :value: 4292714717 .. py:attribute:: PowderBlue :type: int :value: 4289781990 .. py:attribute:: Purple :type: int :value: 4286578816 .. py:attribute:: Red :type: int :value: 4294901760 .. py:attribute:: RosyBrown :type: int :value: 4290547599 .. py:attribute:: RoyalBlue :type: int :value: 4282477025 .. py:attribute:: SaddleBrown :type: int :value: 4287317267 .. py:attribute:: Salmon :type: int :value: 4294606962 .. py:attribute:: SandyBrown :type: int :value: 4294222944 .. py:attribute:: SeaGreen :type: int :value: 4281240407 .. py:attribute:: SeaShell :type: int :value: 4294964718 .. py:attribute:: Sienna :type: int :value: 4288696877 .. py:attribute:: Silver :type: int :value: 4290822336 .. py:attribute:: SkyBlue :type: int :value: 4287090411 .. py:attribute:: SlateBlue :type: int :value: 4285160141 .. py:attribute:: SlateGray :type: int :value: 4285563024 .. py:attribute:: Snow :type: int :value: 4294966010 .. py:attribute:: SpringGreen :type: int :value: 4278255487 .. py:attribute:: SteelBlue :type: int :value: 4282811060 .. py:attribute:: Tan :type: int :value: 4291998860 .. py:attribute:: Teal :type: int :value: 4278222976 .. py:attribute:: Thistle :type: int :value: 4292394968 .. py:attribute:: Tomato :type: int :value: 4294927175 .. py:attribute:: Transparent :type: int :value: 16777215 .. py:attribute:: Turquoise :type: int :value: 4282441936 .. py:attribute:: Violet :type: int :value: 4293821166 .. py:attribute:: Wheat :type: int :value: 4294303411 .. py:attribute:: White :type: int :value: 4294967295 .. py:attribute:: WhiteSmoke :type: int :value: 4294309365 .. py:attribute:: Yellow :type: int :value: 4294967040 .. py:attribute:: YellowGreen :type: int :value: 4288335154 .. py:class:: ColorBase Internal storage for store what is a color .. py:attribute:: R :type: microGUI.Types.Color.ColorType :value: 8 .. py:attribute:: G :type: microGUI.Types.Color.ColorType :value: 8 .. py:attribute:: B :type: microGUI.Types.Color.ColorType :value: 8 .. py:attribute:: A :type: microGUI.Types.Color.ColorType :value: 8 .. py:class:: Color(argb: int or ColorType = Colors.Black) Represents an ARGB (alpha, red, green, blue) color. .. py:attribute:: Colors .. py:attribute:: ColorBase .. py:method:: FromRGB(red: int, green: int, blue: int) :classmethod: Creates a Color structure from a tuple like (r, g, b) in that case valid int values are 0 through 255 The alpha value is implicitly 255 (fully opaque). .. seealso:: - :py:func:`~microGUI.Drawing.Color.Color.FromCMYK()` - :py:func:`~microGUI.Drawing.Color.Color.FromHex()` - :py:func:`~microGUI.Drawing.Color.Color.FromARGB()` :param red: The red component. Valid values are 0 through 255. :type red: int :param green: The green component. Valid values are 0 through 255. :type green: int :param blue: The blue component. Valid values are 0 through 255. :type blue: int :return: The :class:`~microGUI.Drawing.Color.Color` that this method creates. :rtype: :class:`~microGUI.Drawing.Color.Color` .. py:method:: FromARGB(argb: int or tuple) :classmethod: **Options** - Creates a Color structure from a 32-bit ARGB - Creates a Color structure from a tuple like (a, r, g, b) in that case valid int values are 0 through 255 .. attention:: The byte-ordering of the 32-bit ARGB value is AARRGGBB. The most significant byte (MSB), represented by AA, is the alpha component value. The second, third, and fourth bytes, represented by RR, GG, and BB, respectively, are the color components red, green, and blue, respectively. .. seealso:: - :py:func:`~microGUI.Drawing.Color.Color.FromCMYK()` - :py:func:`~microGUI.Drawing.Color.Color.FromRGB()` - :py:func:`~microGUI.Drawing.Color.Color.FromHex()` :param argb: The ColorType 32-bit int value or a tuple :type argb: tuple or ColorType :return: The :class:`~microGUI.Drawing.Color.Color` that this method creates. :rtype: :class:`~microGUI.Drawing.Color.Color` .. py:method:: FromCMYK(cyan: int, magenta: int, yellow: int, key: int) :classmethod: Creates a Color class from the specified 8-bit color values (cyan, magenta, yellow and key pate (black)). The alpha value is implicitly 255 (fully opaque). .. seealso:: - :py:func:`~microGUI.Drawing.Color.Color.FromARGB()` - :py:func:`~microGUI.Drawing.Color.Color.FromHex()` :param cyan: The cyan component. Valid values are 0 through 255. :type cyan: int :param magenta: The magenta component. Valid values are 0 through 255. :type magenta: int :param yellow: The yellow component. Valid values are 0 through 255. :type yellow: int :param key: The key plate component. Valid values are 0 through 255. :type key: int :return: The :py:class:`~microGUI.Drawing.Color.Color` that this method creates. :rtype: :class:`~microGUI.Drawing.Color.Color` .. py:method:: FromHex(color: str) :classmethod: Creates a Color class from the specified HTML HEX palette. The alpha value is implicitly 255 (fully opaque). .. seealso:: - :py:func:`~microGUI.Drawing.Color.Color.FromARGB()` - :py:func:`~microGUI.Drawing.Color.Color.FromCMYK()` :param color: HTML color HEX :type color: str :return: The :py:class:`~microGUI.Drawing.Color.Color` that this method creates. :rtype: :py:class:`~microGUI.Drawing.Color.Color` .. py:method:: ToARGB() :classmethod: Gets the 32-bit ARGB value of this Color class. :return: The 32-bit ARGB value :py:class:`~microGUI.Type.Color.ColorType` of this :py:class:`~microGUI.Drawing.Color.Color`. :rtype: :py:class:`~microGUI.Types.Color.ColorType`