1 /* ncmpc (Ncurses MPD Client) 2 * (c) 2004-2020 The Music Player Daemon Project 3 * Project homepage: http://musicpd.org 4 * 5 * This program is free software; you can redistribute it and/or modify 6 * it under the terms of the GNU General Public License as published by 7 * the Free Software Foundation; either version 2 of the License, or 8 * (at your option) any later version. 9 * 10 * This program is distributed in the hope that it will be useful, 11 * but WITHOUT ANY WARRANTY; without even the implied warranty of 12 * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 13 * GNU General Public License for more details. 14 * 15 * You should have received a copy of the GNU General Public License along 16 * with this program; if not, write to the Free Software Foundation, Inc., 17 * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. 18 */ 19 20 #ifndef STYLES_HXX 21 #define STYLES_HXX 22 23 #include "config.h" 24 25 #include <curses.h> 26 27 enum class Style : unsigned { 28 /** 29 * The ncurses default style. 30 * 31 * @see assume_default_colors(3ncurses) 32 */ 33 DEFAULT, 34 35 TITLE, 36 TITLE_BOLD, 37 LINE, 38 LINE_BOLD, 39 LINE_FLAGS, 40 LIST, 41 LIST_BOLD, 42 PROGRESSBAR, 43 PROGRESSBAR_BACKGROUND, 44 STATUS, 45 STATUS_BOLD, 46 STATUS_TIME, 47 STATUS_ALERT, 48 DIRECTORY, 49 PLAYLIST, 50 BACKGROUND, 51 END 52 }; 53 54 #ifdef ENABLE_COLORS 55 56 /** 57 * Throws on error. 58 */ 59 void 60 ModifyStyle(const char *name, const char *value); 61 62 void 63 ApplyStyles() noexcept; 64 65 #endif 66 67 void 68 SelectStyle(WINDOW *w, Style style) noexcept; 69 70 #endif 71