diff options
author | Ben Longbons <b.r.longbons@gmail.com> | 2014-02-07 21:40:00 -0800 |
---|---|---|
committer | Ben Longbons <b.r.longbons@gmail.com> | 2014-02-07 21:42:43 -0800 |
commit | 7a15a3efe85837d52d950cc9f895eadcc9eb6be1 (patch) | |
tree | d941f22af3d524eec70382d8470f3f14418916fa /src/io | |
parent | f6a91ce07b382dd79c1e42dbc84e2694d83cfc01 (diff) | |
download | tmwa-7a15a3efe85837d52d950cc9f895eadcc9eb6be1.tar.gz tmwa-7a15a3efe85837d52d950cc9f895eadcc9eb6be1.tar.bz2 tmwa-7a15a3efe85837d52d950cc9f895eadcc9eb6be1.tar.xz tmwa-7a15a3efe85837d52d950cc9f895eadcc9eb6be1.zip |
Name the terminal escapes
Diffstat (limited to 'src/io')
-rw-r--r-- | src/io/tty.cpp | 21 | ||||
-rw-r--r-- | src/io/tty.hpp | 38 |
2 files changed, 59 insertions, 0 deletions
diff --git a/src/io/tty.cpp b/src/io/tty.cpp new file mode 100644 index 0000000..d2e084e --- /dev/null +++ b/src/io/tty.cpp @@ -0,0 +1,21 @@ +#include "tty.hpp" +// io/tty.cpp - terminal escape sequences +// +// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com> +// +// This file is part of The Mana World (Athena server) +// +// 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/>. + +/* Nothing to see here, move along */ diff --git a/src/io/tty.hpp b/src/io/tty.hpp new file mode 100644 index 0000000..86616f1 --- /dev/null +++ b/src/io/tty.hpp @@ -0,0 +1,38 @@ +#ifndef TMWA_IO_TTY_HPP +#define TMWA_IO_TTY_HPP +// io/tty.hpp - terminal escape sequences +// +// Copyright © 2014 Ben Longbons <b.r.longbons@gmail.com> +// +// This file is part of The Mana World (Athena server) +// +// 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/>. + +# include "../sanity.hpp" + + +# define SGR_BLACK "\e[30m" +# define SGR_RED "\e[31m" +# define SGR_GREEN "\e[32m" +# define SGR_YELLOW "\e[33m" +# define SGR_BLUE "\e[34m" +# define SGR_MAGENTA "\e[35m" +# define SGR_CYAN "\e[36m" +# define SGR_WHITE "\e[37m" + +# define SGR_BOLD "\e[1m" + +# define SGR_RESET "\e[0m" + +#endif //TMWA_IO_TTY_HPP |