GNSS-SDR  0.0.19
An Open Source GNSS Software Defined Receiver
display.h
Go to the documentation of this file.
1 /*!
2  * \file display.h
3  * \brief Defines useful display constants
4  * \author Antonio Ramos, 2018. antonio.ramos(at)cttc.es
5  *
6  * -----------------------------------------------------------------------------
7  *
8  * GNSS-SDR is a Global Navigation Satellite System software-defined receiver.
9  * This file is part of GNSS-SDR.
10  *
11  * Copyright (C) 2010-2020 (see AUTHORS file for a list of contributors)
12  * SPDX-License-Identifier: GPL-3.0-or-later
13  *
14  * -----------------------------------------------------------------------------
15  */
16 
17 #ifndef GNSS_SDR_DISPLAY_H
18 #define GNSS_SDR_DISPLAY_H
19 
20 #include <string>
21 
22 /** \addtogroup Core
23  * \{ */
24 /** \addtogroup System_Parameters
25  * \{ */
26 
27 
28 #ifndef NO_DISPLAY_COLORS
29 #define DISPLAY_COLORS 1
30 #endif
31 
32 
33 #ifdef DISPLAY_COLORS
34 
35 const std::string TEXT_RESET = "\033[0m";
36 const std::string TEXT_BLACK = "\033[30m";
37 const std::string TEXT_RED = "\033[31m";
38 const std::string TEXT_GREEN = "\033[32m";
39 const std::string TEXT_YELLOW = "\033[33m";
40 const std::string TEXT_BLUE = "\033[34m";
41 const std::string TEXT_MAGENTA = "\033[35m";
42 const std::string TEXT_CYAN = "\033[36m";
43 const std::string TEXT_WHITE = "\033[37m";
44 const std::string TEXT_BOLD_BLACK = "\033[1m\033[30m";
45 const std::string TEXT_BOLD_RED = "\033[1m\033[31m";
46 const std::string TEXT_BOLD_GREEN = "\033[1m\033[32m";
47 const std::string TEXT_BOLD_YELLOW = "\033[1m\033[33m";
48 const std::string TEXT_BOLD_BLUE = "\033[1m\033[34m";
49 const std::string TEXT_BOLD_MAGENTA = "\033[1m\033[35m";
50 const std::string TEXT_BOLD_CYAN = "\033[1m\033[36m";
51 const std::string TEXT_BOLD_WHITE = "\033[1m\033[37m";
52 
53 #else
54 
55 const std::string TEXT_RESET = "";
56 const std::string TEXT_BLACK = "";
57 const std::string TEXT_RED = "";
58 const std::string TEXT_GREEN = "";
59 const std::string TEXT_YELLOW = "";
60 const std::string TEXT_BLUE = "";
61 const std::string TEXT_MAGENTA = "";
62 const std::string TEXT_CYAN = "";
63 const std::string TEXT_WHITE = "";
64 const std::string TEXT_BOLD_BLACK = "";
65 const std::string TEXT_BOLD_RED = "";
66 const std::string TEXT_BOLD_GREEN = "";
67 const std::string TEXT_BOLD_YELLOW = "";
68 const std::string TEXT_BOLD_BLUE = "";
69 const std::string TEXT_BOLD_MAGENTA = "";
70 const std::string TEXT_BOLD_CYAN = "";
71 const std::string TEXT_BOLD_WHITE = "";
72 
73 #endif // DISPLAY_COLORS
74 
75 
76 /** \} */
77 /** \} */
78 #endif // GNSS_SDR_DISPLAY_H