Index: src/OFColor.h ================================================================== --- src/OFColor.h +++ src/OFColor.h @@ -24,11 +24,13 @@ */ @interface OFColor: OFObject #ifdef OF_HAVE_CLASS_PROPERTIES @property (class, readonly, nonatomic) OFColor *black; @property (class, readonly, nonatomic) OFColor *silver; -@property (class, readonly, nonatomic) OFColor *grey; +@property (class, readonly, nonatomic) OFColor *gray; +@property (class, readonly, nonatomic) OFColor *grey + OF_DEPRECATED(ObjFW, 1, 1, "Use gray instead"); @property (class, readonly, nonatomic) OFColor *white; @property (class, readonly, nonatomic) OFColor *maroon; @property (class, readonly, nonatomic) OFColor *red; @property (class, readonly, nonatomic) OFColor *purple; @property (class, readonly, nonatomic) OFColor *fuchsia; @@ -74,17 +76,28 @@ * @return The HTML color `silver` */ + (OFColor *)silver; /** - * @brief Returns the HTML color `grey`. + * @brief Returns the HTML color `gray`. + * + * The RGBA value is (0.5, 0.5, 0.5, 1). + * + * @return The HTML color `gray` + */ ++ (OFColor *)gray; + +/** + * @brief Returns the HTML color `gray`. + * + * @deprecated Use @ref gray instead. * * The RGBA value is (0.5, 0.5, 0.5, 1). * - * @return The HTML color `grey` + * @return The HTML color `gray` */ -+ (OFColor *)grey; ++ (OFColor *)grey OF_DEPRECATED(ObjFW, 1, 1, "Use gray instead"); /** * @brief Returns the HTML color `white`. * * The RGBA value is (1, 1, 1, 1). Index: src/OFColor.m ================================================================== --- src/OFColor.m +++ src/OFColor.m @@ -109,11 +109,11 @@ return name##Color; \ } PREDEFINED_COLOR(black, 0.00f, 0.00f, 0.00f) PREDEFINED_COLOR(silver, 0.75f, 0.75f, 0.75f) -PREDEFINED_COLOR(grey, 0.50f, 0.50f, 0.50f) +PREDEFINED_COLOR(gray, 0.50f, 0.50f, 0.50f) PREDEFINED_COLOR(white, 1.00f, 1.00f, 1.00f) PREDEFINED_COLOR(maroon, 0.50f, 0.00f, 0.00f) PREDEFINED_COLOR(red, 1.00f, 0.00f, 0.00f) PREDEFINED_COLOR(purple, 0.50f, 0.00f, 0.50f) PREDEFINED_COLOR(fuchsia, 1.00f, 0.00f, 1.00f) @@ -123,10 +123,15 @@ PREDEFINED_COLOR(yellow, 1.00f, 1.00f, 0.00f) PREDEFINED_COLOR(navy, 0.00f, 0.00f, 0.50f) PREDEFINED_COLOR(blue, 0.00f, 0.00f, 1.00f) PREDEFINED_COLOR(teal, 0.00f, 0.50f, 0.50f) PREDEFINED_COLOR(aqua, 0.00f, 1.00f, 1.00f) + ++ (OFColor *)grey +{ + return [self gray]; +} + (instancetype)colorWithRed: (float)red green: (float)green blue: (float)blue alpha: (float)alpha Index: src/OFStdIOStream.m ================================================================== --- src/OFStdIOStream.m +++ src/OFStdIOStream.m @@ -137,11 +137,11 @@ return 35; if ([color isEqual: [OFColor teal]]) return 36; if ([color isEqual: [OFColor silver]]) return 37; - if ([color isEqual: [OFColor grey]]) + if ([color isEqual: [OFColor gray]]) return 90; if ([color isEqual: [OFColor red]]) return 91; if ([color isEqual: [OFColor lime]]) return 92; Index: tests/terminal/TerminalTests.m ================================================================== --- tests/terminal/TerminalTests.m +++ tests/terminal/TerminalTests.m @@ -28,11 +28,11 @@ @implementation TerminalTests - (void)applicationDidFinishLaunching: (OFNotification *)notification { OFArray *colors = [OFArray arrayWithObjects: - [OFColor black], [OFColor silver], [OFColor grey], [OFColor white], + [OFColor black], [OFColor silver], [OFColor gray], [OFColor white], [OFColor maroon], [OFColor red], [OFColor purple], [OFColor fuchsia], [OFColor green], [OFColor lime], [OFColor olive], [OFColor yellow], [OFColor navy], [OFColor blue], [OFColor teal], [OFColor aqua], nil]; size_t i;