0
0
Fork 0
mirror of https://github.com/matrix-construct/construct synced 2024-12-25 23:14:13 +01:00

ircd: Enumerate non-standard but ubiquitous mIRC colors.

This commit is contained in:
Jason Volk 2016-09-08 10:49:45 -07:00
parent c5ce56dfe9
commit f25cb78588
2 changed files with 59 additions and 0 deletions

58
include/ircd/color.h Normal file
View file

@ -0,0 +1,58 @@
/**
* Copyright (C) 2014 Jason Volk
* Copyright (C) 2014 Svetlana Tkachenko
* Copyright (C) 2016 Charybdis Development Team
*
* This program is free software: you can redistribute it and/or modify
* it under the terms of the GNU General Public License as published by
* the Free Software Foundation, either version 3 of the License, or
* (at your option) any later version.
*
* This program is distributed in the hope that it will be useful,
* but WITHOUT ANY WARRANTY; without even the implied warranty of
* MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
* GNU General Public License for more details.
*
* You should have received a copy of the GNU General Public License
* along with this program. If not, see <http://www.gnu.org/licenses/>.
*/
#pragma once
#define HAVE_IRCD_COLOR_H
#ifdef __cplusplus
namespace ircd {
namespace color {
enum mode
:uint8_t
{
OFF = 0x0f,
BOLD = 0x02,
COLOR = 0x03,
ITALIC = 0x09,
STRIKE = 0x13,
UNDER = 0x15,
UNDER2 = 0x1f,
REVERSE = 0x16,
};
enum class fg
{
WHITE, BLACK, BLUE, GREEN,
LRED, RED, MAGENTA, ORANGE,
YELLOW, LGREEN, CYAN, LCYAN,
LBLUE, LMAGENTA, GRAY, LGRAY
};
enum class bg
{
LGRAY_BLINK, BLACK, BLUE, GREEN,
RED_BLINK, RED, MAGENTA, ORANGE,
ORANGE_BLINK, GREEN_BLINK, CYAN, CYAN_BLINK,
BLUE_BLINK, MAGENTA_BLINK, BLACK_BLINK, LGRAY,
};
} // namespace color
} // namespace ircd
#endif // __cplusplus

View file

@ -70,6 +70,7 @@ namespace ircd
#include "defaults.h"
#include "exception.h"
#include "numeric.h"
#include "color.h"
#include "messages.h"
#include "rfc1459.h"
#include "err.h"