예제 #1
0
        //returns true if the luminosity of c1 is less than c2.
        internal static bool IsDarker(this Color c1, Color c2)
        {
            HlsColor hc1 = new HlsColor(c1);
            HlsColor hc2 = new HlsColor(c2);

            return(hc1.Luminosity < hc2.Luminosity);
        }
예제 #2
0
        public override bool Equals(object o)
        {
            if (!(o is HlsColor))
            {
                return(false);
            }

            HlsColor c = (HlsColor)o;

            return(_hue == c._hue &&
                   _saturation == c._saturation &&
                   _luminosity == c._luminosity &&
                   _isSystemColorsControl == c._isSystemColorsControl);
        }