[Top][All Lists]
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Groff-commit] groff ./ChangeLog src/devices/grotty/tty.cpp
From: |
Werner LEMBERG |
Subject: |
[Groff-commit] groff ./ChangeLog src/devices/grotty/tty.cpp |
Date: |
Sat, 11 Feb 2006 17:51:09 +0000 |
CVSROOT: /cvsroot/groff
Module name: groff
Branch:
Changes by: Werner LEMBERG <address@hidden> 06/02/11 17:51:09
Modified files:
. : ChangeLog
src/devices/grotty: tty.cpp
Log message:
* src/devices/grotty/tty.cpp (output_character_t): New type.
(tty_printer::make_bold, tty_printer::add_char, tty_printer::put_char):
Change argument type to output_character_t.
(crossings): Change element type to output_character_t.
CVSWeb URLs:
http://cvs.savannah.gnu.org/viewcvs/groff/groff/ChangeLog.diff?tr1=1.898&tr2=1.899&r1=text&r2=text
http://cvs.savannah.gnu.org/viewcvs/groff/groff/src/devices/grotty/tty.cpp.diff?tr1=1.14&tr2=1.15&r1=text&r2=text
Patches:
Index: groff/ChangeLog
diff -u groff/ChangeLog:1.898 groff/ChangeLog:1.899
--- groff/ChangeLog:1.898 Sat Feb 11 17:48:09 2006
+++ groff/ChangeLog Sat Feb 11 17:51:09 2006
@@ -1,5 +1,12 @@
2006-02-11 Bruno Haible <address@hidden>
+ * src/devices/grotty/tty.cpp (output_character_t): New type.
+ (tty_printer::make_bold, tty_printer::add_char, tty_printer::put_char):
+ Change argument type to output_character_t.
+ (crossings): Change element type to output_character_t.
+
+2006-02-11 Bruno Haible <address@hidden>
+
Make the glyph data type abstract.
* src/include/font.h (glyph_t): New class.
(name_to_index, number_to_index): Change return type to glyph_t.
@@ -57,13 +64,6 @@
* src/libs/libgroff/font.cpp (font::load): Remove failure tests for
font::name_to_index.
-2006-02-11 Bruno Haible <address@hidden>
-
- * src/roff/troff/input.cpp (font::name_to_index): Never return a
- negative value.
- * src/libs/libgroff/font.cpp (font::load): Remove failure tests for
- font::name_to_index.
-
2006-02-10 Werner LEMBERG <address@hidden>
* doc/groff.texinfo (Assigning Formats): Number registers are always
Index: groff/src/devices/grotty/tty.cpp
diff -u groff/src/devices/grotty/tty.cpp:1.14
groff/src/devices/grotty/tty.cpp:1.15
--- groff/src/devices/grotty/tty.cpp:1.14 Sat Feb 11 17:48:09 2006
+++ groff/src/devices/grotty/tty.cpp Sat Feb 11 17:51:09 2006
@@ -42,6 +42,9 @@
#define TAB_WIDTH 8
+// A character of the output device fits in a 32-bit word.
+typedef unsigned int output_character_t;
+
static int horizontal_tab_flag = 0;
static int form_feed_flag = 0;
static int bold_flag_option = 1;
@@ -206,9 +209,9 @@
int cu_flag;
PTABLE(schar) tty_colors;
void make_underline(int);
- void make_bold(unsigned int, int);
+ void make_bold(output_character_t, int);
schar color_to_idx(color *col);
- void add_char(unsigned int, int, int, int, color *, color *, unsigned char);
+ void add_char(output_character_t, int, int, int, color *, color *, unsigned
char);
char *make_rgb_string(unsigned int, unsigned int, unsigned int);
int tty_color(unsigned int, unsigned int, unsigned int, schar *,
schar = DEFAULT_COLOR_IDX);
@@ -220,7 +223,7 @@
void special(char *arg, const environment *env, char type);
void change_color(const environment * const env);
void change_fill_color(const environment * const env);
- void put_char(unsigned int);
+ void put_char(output_character_t);
void put_color(schar, int);
void begin_page(int) { }
void end_page(int page_length);
@@ -326,7 +329,7 @@
}
}
-void tty_printer::make_bold(unsigned int c, int w)
+void tty_printer::make_bold(output_character_t c, int w)
{
if (old_drawing_scheme) {
if (!w)
@@ -371,7 +374,7 @@
((tty_font *)f)->get_mode());
}
-void tty_printer::add_char(unsigned int c, int w,
+void tty_printer::add_char(output_character_t c, int w,
int h, int v,
color *fore, color *back,
unsigned char mode)
@@ -546,7 +549,7 @@
}
}
-void tty_printer::put_char(unsigned int wc)
+void tty_printer::put_char(output_character_t wc)
{
if (is_utf8 && wc >= 0x80) {
char buf[6 + 1];
@@ -610,7 +613,7 @@
// ` ' = 0, ` ' = 1, `|' = 2, `|' = 3
// | |
-static int crossings[4*4] = {
+static output_character_t crossings[4*4] = {
0x0000, 0x2577, 0x2575, 0x2502,
0x2576, 0x250C, 0x2514, 0x251C,
0x2574, 0x2510, 0x2518, 0x2524,
@@ -658,7 +661,7 @@
for (p = g; p; delete p, p = nextp) {
nextp = p->next;
if (p->mode & CU_MODE) {
- cu_flag = p->code;
+ cu_flag = (p->code != 0);
continue;
}
if (nextp && p->hpos == nextp->hpos) {
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- [Groff-commit] groff ./ChangeLog src/devices/grotty/tty.cpp,
Werner LEMBERG <=