@@ -24,10 +24,12 @@ OF_ASSUME_NONNULL_BEGIN /*! @file */ +@class OFColor; + /*! * @class OFStdIOStream OFStdIOStream.h ObjFW/OFStdIOStream.h * * @brief A class for providing standard input, output and error as OFStream. * @@ -62,10 +64,31 @@ * number of rows could not be queried. */ @property (readonly, nonatomic) int rows; - (instancetype)init OF_UNAVAILABLE; + +/*! + * @brief Sets the foreground color on the underlying terminal. Does nothing if + * there is no underlying terminal or colors are unsupported. + * + * @param color The foreground color to set + */ +- (void)setForegroundColor: (OFColor *)color; + +/*! + * @brief Sets the background color on the underlying terminal. Does nothing if + * there is no underlying terminal or colors are unsupported. + * + * @param color The background color to set + */ +- (void)setBackgroundColor: (OFColor *)color; + +/*! + * @brief Resets forward and background color. + */ +- (void)resetColor; @end #ifdef __cplusplus extern "C" { #endif