File: bolt-term.h

package info (click to toggle)
bolt 0.9.10-1
  • links: PTS, VCS
  • area: main
  • in suites: forky, sid
  • size: 1,844 kB
  • sloc: ansic: 29,085; python: 2,938; xml: 460; javascript: 269; sh: 166; makefile: 14
file content (60 lines) | stat: -rw-r--r-- 1,435 bytes parent folder | download | duplicates (5)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
/*
 * Copyright © 2017 Red Hat, Inc
 *
 * This program is free software; you can redistribute it and/or
 * modify it under the terms of the GNU Lesser General Public
 * License as published by the Free Software Foundation; either
 * version 2.1 of the License, or (at your option) any later version.
 *
 * This library 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
 * Lesser General Public License for more details.
 *
 * You should have received a copy of the GNU Lesser General Public
 * License along with this library. If not, see <http://www.gnu.org/licenses/>.
 *
 * Authors:
 *       Christian J. Kellner <christian@kellner.me>
 */

#pragma once

#include <glib.h>
#include <string.h>

G_BEGIN_DECLS

#define ANSI_NORMAL "\x1B[0m"
#define ANSI_RED "\x1B[0;31m"
#define ANSI_GREEN "\x1B[0;32m"
#define ANSI_YELLOW "\x1B[0;33m"
#define ANSI_BLUE "\x1B[0;34m"
#define ANSI_HIGHLIGHT_BLACK "\x1B[0;1;30m"
#define ANSI_HIGHLIGHT_RED "\x1B[0;1;31m"

int              bolt_is_fancy_terminal (void);

const char *     bolt_color (const char *color);

typedef enum {
  TREE_VERTICAL,
  TREE_BRANCH,
  TREE_RIGHT,
  TREE_SPACE,

  BLACK_CIRCLE,
  WHITE_CIRCLE,

  ARROW,
  MDASH,
  ELLIPSIS,

  WARNING_SIGN,

  BOLT_GLYPH_LAST
} BoltGlyph;

const char *    bolt_glyph (BoltGlyph g);

G_END_DECLS