gbranden pushed a commit to branch master
in repository groff.
commit 524234f94e57c87d90a0936ec72aacd30988cc67
Author: G. Branden Robinson <[email protected]>
AuthorDate: Wed Aug 28 15:00:24 2024 -0500
[troff]: Trivially refactor (`causes_tprint()`).
[troff]: Boolify and rename member function of `node` class hierarchy to
`causes_tprint()`. This function indicates whether the node requires
certain formatter state (roughly, changes to the environment) to be
flushed to output before the next node is written ("tprint"ed).
* src/roff/troff/node.h
(struct node)
(class line_start_node)
(class space_node)
(class word_space_node)
(class unbreakable_space_node)
(class diverted_space_node)
(class diverted_copy_file_node)
(class extra_size_node)
(class vertical_size_node)
(class hmotion_node)
(class space_char_hmotion_node)
(class vmotion_node)
(class hline_node)
(class vline_node)
(class dummy_node)
(class transparent_dummy_node)
(class zero_width_node)
(class left_italic_corrected_node)
(class overstrike_node)
(class bracket_node)
(class special_node)
(class suppress_node)
(class tag_node)
(class draw_node):
* src/roff/troff/node.cpp
(class glyph_node)
(class ligature_node)
(class kern_pair_node)
(class dbreak_node)
(class hyphen_inhibitor_node)
(class italic_corrected_node)
(class break_char_node)
(class composite_node):
* src/roff/troff/input.cpp
(class non_interpreted_char_node)
(class token_node)
(class non_interpreted_node):
Rename `force_tprint()` member function declarations to
`causes_tprint()` and demote return type from `int` to `bool`.
* src/roff/troff/node.cpp
(hyphen_inhibitor_node::causes_tprint)
(node::causes_tprint)
(space_node::causes_tprint)
(special_node::causes_tprint)
(tag_node::causes_tprint)
(suppress_node::causes_tprint)
(unbreakable_space_node::causes_tprint)
(draw_node::causes_tprint)
(extra_size_node::causes_tprint)
(vertical_size_node::causes_tprint)
(hmotion_node::causes_tprint)
(space_char_hmotion_node::causes_tprint)
(vmotion_node::causes_tprint)
(hline_node::causes_tprint)
(vline_node::causes_tprint)
(dummy_node::causes_tprint)
(transparent_dummy_node::causes_tprint)
(zero_width_node::causes_tprint)
(italic_corrected_node::causes_tprint)
(left_italic_corrected_node::causes_tprint)
(overstrike_node::causes_tprint)
(bracket_node::causes_tprint)
(composite_node::causes_tprint)
(glyph_node::causes_tprint)
(ligature_node::causes_tprint)
(kern_pair_node::causes_tprint)
(dbreak_node::causes_tprint)
(break_char_node::causes_tprint)
(line_start_node::causes_tprint)
(word_space_node::causes_tprint)
(diverted_space_node::causes_tprint)
(diverted_copy_file_node::causes_tprint):
* src/roff/troff/input.cpp
(non_interpreted_char_node::causes_tprint)
(token_node::causes_tprint)
(non_interpreted_node::causes_tprint):
Rename `force_tprint()` member function definition to
`causes_tprint()` and demote return type from `int` to `bool`.
* src/roff/troff/node.cpp
(troff_output_file::really_print_line): Update call site.
Some gripes:
1. I wish I knew why no one ever wrote a design document for this
formatter.
2. Why make `causes_tprint()` (formerly `force_tprint()`) a pure
virtual function when practically everything that overrides it has
it return `false` (formerly `0`)? Why not make it impure and return
false in the base class? (...said somebody who's likely to cut his
thumb on one of C++'s sharper edges any minute now.)
3. Why all the separate member function definitions for
single statements? Isn't the idiomatic C++ thing to define this
inline as part of the class declaration?
---
ChangeLog | 92 ++++++++++++++++++++++++++++++
src/roff/troff/input.cpp | 18 +++---
src/roff/troff/node.cpp | 142 +++++++++++++++++++++++------------------------
src/roff/troff/node.h | 48 ++++++++--------
4 files changed, 196 insertions(+), 104 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 7a46b938d..f82dd8673 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,95 @@
+2024-08-28 G. Branden Robinson <[email protected]>
+
+ [troff]: Boolify and rename member function of `node` class
+ hierarchy to `causes_tprint()`. This function indicates whether
+ the node requires certain formatter state (roughly, changes to
+ the environment) to be flushed to output before the next node is
+ written ("tprint"ed).
+
+ * src/roff/troff/node.h
+ (struct node)
+ (class line_start_node)
+ (class space_node)
+ (class word_space_node)
+ (class unbreakable_space_node)
+ (class diverted_space_node)
+ (class diverted_copy_file_node)
+ (class extra_size_node)
+ (class vertical_size_node)
+ (class hmotion_node)
+ (class space_char_hmotion_node)
+ (class vmotion_node)
+ (class hline_node)
+ (class vline_node)
+ (class dummy_node)
+ (class transparent_dummy_node)
+ (class zero_width_node)
+ (class left_italic_corrected_node)
+ (class overstrike_node)
+ (class bracket_node)
+ (class special_node)
+ (class suppress_node)
+ (class tag_node)
+ (class draw_node):
+ * src/roff/troff/node.cpp
+ (class glyph_node)
+ (class ligature_node)
+ (class kern_pair_node)
+ (class dbreak_node)
+ (class hyphen_inhibitor_node)
+ (class italic_corrected_node)
+ (class break_char_node)
+ (class composite_node):
+ * src/roff/troff/input.cpp
+ (class non_interpreted_char_node)
+ (class token_node)
+ (class non_interpreted_node):
+ Rename `force_tprint()` member function declarations to
+ `causes_tprint()` and demote return type from `int` to `bool`.
+
+ * src/roff/troff/node.cpp
+ (hyphen_inhibitor_node::causes_tprint)
+ (node::causes_tprint)
+ (space_node::causes_tprint)
+ (special_node::causes_tprint)
+ (tag_node::causes_tprint)
+ (suppress_node::causes_tprint)
+ (unbreakable_space_node::causes_tprint)
+ (draw_node::causes_tprint)
+ (extra_size_node::causes_tprint)
+ (vertical_size_node::causes_tprint)
+ (hmotion_node::causes_tprint)
+ (space_char_hmotion_node::causes_tprint)
+ (vmotion_node::causes_tprint)
+ (hline_node::causes_tprint)
+ (vline_node::causes_tprint)
+ (dummy_node::causes_tprint)
+ (transparent_dummy_node::causes_tprint)
+ (zero_width_node::causes_tprint)
+ (italic_corrected_node::causes_tprint)
+ (left_italic_corrected_node::causes_tprint)
+ (overstrike_node::causes_tprint)
+ (bracket_node::causes_tprint)
+ (composite_node::causes_tprint)
+ (glyph_node::causes_tprint)
+ (ligature_node::causes_tprint)
+ (kern_pair_node::causes_tprint)
+ (dbreak_node::causes_tprint)
+ (break_char_node::causes_tprint)
+ (line_start_node::causes_tprint)
+ (word_space_node::causes_tprint)
+ (diverted_space_node::causes_tprint)
+ (diverted_copy_file_node::causes_tprint):
+ * src/roff/troff/input.cpp
+ (non_interpreted_char_node::causes_tprint)
+ (token_node::causes_tprint)
+ (non_interpreted_node::causes_tprint):
+ Rename `force_tprint()` member function definition to
+ `causes_tprint()` and demote return type from `int` to `bool`.
+
+ * src/roff/troff/node.cpp
+ (troff_output_file::really_print_line): Update call site.
+
2024-08-28 G. Branden Robinson <[email protected]>
* src/roff/troff/node.cpp: Fix code style nits.
diff --git a/src/roff/troff/input.cpp b/src/roff/troff/input.cpp
index 30ec49e4c..34960cee4 100644
--- a/src/roff/troff/input.cpp
+++ b/src/roff/troff/input.cpp
@@ -1268,7 +1268,7 @@ public:
int interpret(macro *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -1282,9 +1282,9 @@ const char *non_interpreted_char_node::type()
return "non_interpreted_char_node";
}
-int non_interpreted_char_node::force_tprint()
+bool non_interpreted_char_node::causes_tprint()
{
- return 0;
+ return false;
}
bool non_interpreted_char_node::is_tag()
@@ -1813,7 +1813,7 @@ public:
token_node *get_token_node();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -1841,9 +1841,9 @@ const char *token_node::type()
return "token_node";
}
-int token_node::force_tprint()
+bool token_node::causes_tprint()
{
- return 0;
+ return false;
}
bool token_node::is_tag()
@@ -5621,7 +5621,7 @@ public:
int ends_sentence();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -5644,9 +5644,9 @@ const char *non_interpreted_node::type()
return "non_interpreted_node";
}
-int non_interpreted_node::force_tprint()
+bool non_interpreted_node::causes_tprint()
{
- return 0;
+ return false;
}
bool non_interpreted_node::is_tag()
diff --git a/src/roff/troff/node.cpp b/src/roff/troff/node.cpp
index 9bdee0af4..4b7de8f3a 100644
--- a/src/roff/troff/node.cpp
+++ b/src/roff/troff/node.cpp
@@ -941,7 +941,7 @@ void troff_output_file::really_print_line(hunits x, vunits
y, node *n,
cur_div_level = n->div_nest_level;
}
// Now check whether the state has changed.
- if ((is_on() || n->force_tprint())
+ if ((is_on() || n->causes_tprint())
&& (state.changed(n->state) || n->is_tag() || n->is_special)) {
flush_tbuf();
do_motion();
@@ -1913,7 +1913,7 @@ public:
int character_type();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
void dump_node();
};
@@ -1938,7 +1938,7 @@ public:
void asciify(macro *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -1965,7 +1965,7 @@ public:
void asciify(macro *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
void vertical_extent(vunits *, vunits *);
};
@@ -1996,7 +1996,7 @@ public:
void asciify(macro *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
void dump_node();
};
@@ -2433,7 +2433,7 @@ public:
node *copy();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
hyphenation_type get_hyphenation_type();
};
@@ -2457,9 +2457,9 @@ const char *hyphen_inhibitor_node::type()
return "hyphen_inhibitor_node";
}
-int hyphen_inhibitor_node::force_tprint()
+bool hyphen_inhibitor_node::causes_tprint()
{
- return 0;
+ return false;
}
bool hyphen_inhibitor_node::is_tag()
@@ -2536,9 +2536,9 @@ node *node::last_char_node()
return 0;
}
-int node::force_tprint()
+bool node::causes_tprint()
{
- return 0;
+ return false;
}
bool node::is_tag()
@@ -2662,7 +2662,7 @@ public:
hunits skew();
node *add_self(node *, hyphen_list **);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -2806,7 +2806,7 @@ public:
tfont *get_tfont();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
int get_break_code();
};
@@ -3244,9 +3244,9 @@ node *space_node::copy()
return new space_node(n, set, was_escape_colon, col, state, div_nest_level);
}
-int space_node::force_tprint()
+bool space_node::causes_tprint()
{
- return 0;
+ return false;
}
bool space_node::is_tag()
@@ -3931,9 +3931,9 @@ int special_node::ends_sentence()
return 2;
}
-int special_node::force_tprint()
+bool special_node::causes_tprint()
{
- return 0;
+ return false;
}
bool special_node::is_tag()
@@ -4053,7 +4053,7 @@ const char *tag_node::type()
return "tag_node";
}
-int tag_node::force_tprint()
+bool tag_node::causes_tprint()
{
return !delayed;
}
@@ -4252,7 +4252,7 @@ void suppress_node::tprint(troff_output_file *out)
} // is_on
}
-int suppress_node::force_tprint()
+bool suppress_node::causes_tprint()
{
return is_on;
}
@@ -4289,7 +4289,7 @@ public:
tfont *get_tfont();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
void vertical_extent(vunits *, vunits *);
vunits vertical_width();
@@ -4506,9 +4506,9 @@ node *unbreakable_space_node::copy()
return new unbreakable_space_node(n, set, col, state, div_nest_level);
}
-int unbreakable_space_node::force_tprint()
+bool unbreakable_space_node::causes_tprint()
{
- return 0;
+ return false;
}
bool unbreakable_space_node::is_tag()
@@ -4577,9 +4577,9 @@ const char *draw_node::type()
return "draw_node";
}
-int draw_node::force_tprint()
+bool draw_node::causes_tprint()
{
- return 0;
+ return false;
}
bool draw_node::is_tag()
@@ -5228,9 +5228,9 @@ const char *extra_size_node::type()
return "extra_size_node";
}
-int extra_size_node::force_tprint()
+bool extra_size_node::causes_tprint()
{
- return 0;
+ return false;
}
bool extra_size_node::is_tag()
@@ -5253,9 +5253,9 @@ bool vertical_size_node::set_unformat_flag()
return false;
}
-int vertical_size_node::force_tprint()
+bool vertical_size_node::causes_tprint()
{
- return 0;
+ return false;
}
bool vertical_size_node::is_tag()
@@ -5280,9 +5280,9 @@ bool hmotion_node::set_unformat_flag()
return true;
}
-int hmotion_node::force_tprint()
+bool hmotion_node::causes_tprint()
{
- return 0;
+ return false;
}
bool hmotion_node::is_tag()
@@ -5315,9 +5315,9 @@ const char *space_char_hmotion_node::type()
return "space_char_hmotion_node";
}
-int space_char_hmotion_node::force_tprint()
+bool space_char_hmotion_node::causes_tprint()
{
- return 0;
+ return false;
}
bool space_char_hmotion_node::is_tag()
@@ -5351,9 +5351,9 @@ const char *vmotion_node::type()
return "vmotion_node";
}
-int vmotion_node::force_tprint()
+bool vmotion_node::causes_tprint()
{
- return 0;
+ return false;
}
bool vmotion_node::is_tag()
@@ -5372,9 +5372,9 @@ const char *hline_node::type()
return "hline_node";
}
-int hline_node::force_tprint()
+bool hline_node::causes_tprint()
{
- return 0;
+ return false;
}
bool hline_node::is_tag()
@@ -5393,9 +5393,9 @@ const char *vline_node::type()
return "vline_node";
}
-int vline_node::force_tprint()
+bool vline_node::causes_tprint()
{
- return 0;
+ return false;
}
bool vline_node::is_tag()
@@ -5413,9 +5413,9 @@ const char *dummy_node::type()
return "dummy_node";
}
-int dummy_node::force_tprint()
+bool dummy_node::causes_tprint()
{
- return 0;
+ return false;
}
bool dummy_node::is_tag()
@@ -5433,9 +5433,9 @@ const char *transparent_dummy_node::type()
return "transparent_dummy_node";
}
-int transparent_dummy_node::force_tprint()
+bool transparent_dummy_node::causes_tprint()
{
- return 0;
+ return false;
}
bool transparent_dummy_node::is_tag()
@@ -5458,9 +5458,9 @@ const char *zero_width_node::type()
return "zero_width_node";
}
-int zero_width_node::force_tprint()
+bool zero_width_node::causes_tprint()
{
- return 0;
+ return false;
}
bool zero_width_node::is_tag()
@@ -5479,9 +5479,9 @@ const char *italic_corrected_node::type()
return "italic_corrected_node";
}
-int italic_corrected_node::force_tprint()
+bool italic_corrected_node::causes_tprint()
{
- return 0;
+ return false;
}
bool italic_corrected_node::is_tag()
@@ -5551,9 +5551,9 @@ const char *left_italic_corrected_node::type()
return "left_italic_corrected_node";
}
-int left_italic_corrected_node::force_tprint()
+bool left_italic_corrected_node::causes_tprint()
{
- return 0;
+ return false;
}
bool left_italic_corrected_node::is_tag()
@@ -5671,9 +5671,9 @@ const char *overstrike_node::type()
return "overstrike_node";
}
-int overstrike_node::force_tprint()
+bool overstrike_node::causes_tprint()
{
- return 0;
+ return false;
}
bool overstrike_node::is_tag()
@@ -5705,9 +5705,9 @@ const char *bracket_node::type()
return "bracket_node";
}
-int bracket_node::force_tprint()
+bool bracket_node::causes_tprint()
{
- return 0;
+ return false;
}
bool bracket_node::is_tag()
@@ -5726,9 +5726,9 @@ const char *composite_node::type()
return "composite_node";
}
-int composite_node::force_tprint()
+bool composite_node::causes_tprint()
{
- return 0;
+ return false;
}
bool composite_node::is_tag()
@@ -5749,9 +5749,9 @@ const char *glyph_node::type()
return "glyph_node";
}
-int glyph_node::force_tprint()
+bool glyph_node::causes_tprint()
{
- return 0;
+ return false;
}
bool glyph_node::is_tag()
@@ -5771,9 +5771,9 @@ const char *ligature_node::type()
return "ligature_node";
}
-int ligature_node::force_tprint()
+bool ligature_node::causes_tprint()
{
- return 0;
+ return false;
}
bool ligature_node::is_tag()
@@ -5793,9 +5793,9 @@ const char *kern_pair_node::type()
return "kern_pair_node";
}
-int kern_pair_node::force_tprint()
+bool kern_pair_node::causes_tprint()
{
- return 0;
+ return false;
}
bool kern_pair_node::is_tag()
@@ -5815,9 +5815,9 @@ const char *dbreak_node::type()
return "dbreak_node";
}
-int dbreak_node::force_tprint()
+bool dbreak_node::causes_tprint()
{
- return 0;
+ return false;
}
bool dbreak_node::is_tag()
@@ -5861,9 +5861,9 @@ const char *break_char_node::type()
return "break_char_node";
}
-int break_char_node::force_tprint()
+bool break_char_node::causes_tprint()
{
- return 0;
+ return false;
}
bool break_char_node::is_tag()
@@ -5886,9 +5886,9 @@ const char *line_start_node::type()
return "line_start_node";
}
-int line_start_node::force_tprint()
+bool line_start_node::causes_tprint()
{
- return 0;
+ return false;
}
bool line_start_node::is_tag()
@@ -5920,9 +5920,9 @@ const char *word_space_node::type()
return "word_space_node";
}
-int word_space_node::force_tprint()
+bool word_space_node::causes_tprint()
{
- return 0;
+ return false;
}
bool word_space_node::is_tag()
@@ -5981,9 +5981,9 @@ const char *diverted_space_node::type()
return "diverted_space_node";
}
-int diverted_space_node::force_tprint()
+bool diverted_space_node::causes_tprint()
{
- return 0;
+ return false;
}
bool diverted_space_node::is_tag()
@@ -6001,9 +6001,9 @@ const char *diverted_copy_file_node::type()
return "diverted_copy_file_node";
}
-int diverted_copy_file_node::force_tprint()
+bool diverted_copy_file_node::causes_tprint()
{
- return 0;
+ return false;
}
bool diverted_copy_file_node::is_tag()
diff --git a/src/roff/troff/node.h b/src/roff/troff/node.h
index 773e72f6f..ccef903dc 100644
--- a/src/roff/troff/node.h
+++ b/src/roff/troff/node.h
@@ -65,7 +65,7 @@ struct node {
virtual ~node();
virtual node *copy() = 0;
virtual bool set_unformat_flag();
- virtual int force_tprint() = 0;
+ virtual bool causes_tprint() = 0;
virtual bool is_tag() = 0;
virtual int get_break_code();
virtual hunits width();
@@ -170,7 +170,7 @@ public:
line_start_node() {}
node *copy() { return new line_start_node; }
bool is_same_as(node *);
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
const char *type();
void asciify(macro *);
@@ -205,7 +205,7 @@ public:
bool is_same_as(node *);
void asciify(macro *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
hyphenation_type get_hyphenation_type();
};
@@ -238,7 +238,7 @@ public:
void asciify(macro *);
const char *type();
int merge_space(hunits, hunits, hunits);
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -254,7 +254,7 @@ public:
bool is_same_as(node *);
void asciify(macro *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
breakpoint *get_breakpoints(hunits, int,
breakpoint * /* rest */ = 0 /* nullptr */,
@@ -277,7 +277,7 @@ public:
int reread(int *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -292,7 +292,7 @@ public:
int reread(int *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -305,7 +305,7 @@ public:
node *copy();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -320,7 +320,7 @@ public:
bool set_unformat_flag();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -353,7 +353,7 @@ public:
void ascii_print(ascii_output_file *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
node *add_self(node *, hyphen_list **);
hyphen_list *get_hyphen_list(hyphen_list *, int *);
@@ -372,7 +372,7 @@ public:
void tprint(troff_output_file *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
node *add_self(node *, hyphen_list **);
hyphen_list *get_hyphen_list(hyphen_list *, int *);
@@ -390,7 +390,7 @@ public:
vunits vertical_width();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -407,7 +407,7 @@ public:
void tprint(troff_output_file *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -426,7 +426,7 @@ public:
void vertical_extent(vunits *, vunits *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -436,7 +436,7 @@ public:
node *copy();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
hyphenation_type get_hyphenation_type();
};
@@ -447,7 +447,7 @@ public:
node *copy();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
int ends_sentence();
hyphenation_type get_hyphenation_type();
@@ -463,7 +463,7 @@ public:
void tprint(troff_output_file *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
void append(node *);
int character_type();
@@ -484,7 +484,7 @@ public:
node *copy();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
hunits width();
node *last_char_node();
@@ -516,7 +516,7 @@ public:
hunits width();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
node *add_self(node *, hyphen_list **);
hyphen_list *get_hyphen_list(hyphen_list *, int *);
@@ -536,7 +536,7 @@ public:
hunits width();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
@@ -559,7 +559,7 @@ public:
void tprint(troff_output_file *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
int ends_sentence();
tfont *get_tfont();
@@ -581,7 +581,7 @@ public:
hunits width();
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
private:
void put(troff_output_file *, const char *);
@@ -598,7 +598,7 @@ public:
void tprint(troff_output_file *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
int ends_sentence(); // tri-state
};
@@ -627,7 +627,7 @@ public:
void tprint(troff_output_file *);
bool is_same_as(node *);
const char *type();
- int force_tprint();
+ bool causes_tprint();
bool is_tag();
};
_______________________________________________
Groff-commit mailing list
[email protected]
https://lists.gnu.org/mailman/listinfo/groff-commit