"Fossies" - the Fresh Open Source Software Archive 
Member "most-5.2.0/src/display.c" (4 Aug 2022, 1483 Bytes) of package /linux/misc/most-5.2.0.tar.gz:
As a special service "Fossies" has tried to format the requested source page into HTML format using (guessed) C and C++ source code syntax highlighting (style:
standard) with prefixed line numbers and
code folding option.
Alternatively you can here
view or
download the uninterpreted source code file.
For more information about "display.c" see the
Fossies "Dox" file reference documentation and the latest
Fossies "Diffs" side-by-side code changes report:
5.1.0_vs_5.2.0.
1 /*
2 This file is part of MOST.
3
4 Copyright (c) 1991, 1999, 2002, 2005-2021, 2022 John E. Davis
5
6 This program is free software; you can redistribute it and/or modify it
7 under the terms of the GNU General Public License as published by the Free
8 Software Foundation; either version 2 of the License, or (at your option)
9 any later version.
10
11 This program is distributed in the hope that it will be useful, but WITHOUT
12 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
13 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License for
14 more details.
15
16 You should have received a copy of the GNU General Public License along
17 with this program; if not, write to the Free Software Foundation, Inc., 675
18 Mass Ave, Cambridge, MA 02139, USA.
19 */
20 #include <stdio.h>
21 #include <slang.h>
22 #include "jdmacros.h"
23
24 #include "display.h"
25 #include "color.h"
26
27 void most_narrow_width(void)
28 {
29 SLsmg_refresh ();
30 SLtt_write_string ("\033[?3l");
31 }
32
33 void most_wide_width(void)
34 {
35 SLsmg_refresh ();
36 SLtt_write_string ("\033[?3h");
37 }
38
39 void most_tt_set_color (int color)
40 {
41 SLsmg_set_color (color);
42 }
43
44 void most_tt_bold_video (void)
45 {
46 SLsmg_set_color (MOST_BOLD_COLOR);
47 }
48
49 void most_tt_normal_video (void)
50 {
51 SLsmg_set_color (0);
52 }
53
54 void most_tt_underline_video (void)
55 {
56 SLsmg_set_color (MOST_ULINE_COLOR);
57 }
58
59 void most_tt_reverse_video (void)
60 {
61 SLsmg_set_color (MOST_STATUS_COLOR);
62 }
63
64 void most_goto_rc (int r, int c)
65 {
66 SLsmg_gotorc (r - 1, c - 1);
67 }
68