694 |
|
|
695 |
int text_glob::is_nf (void) |
int text_glob::is_nf (void) |
696 |
{ |
{ |
697 |
return is_tag && (strncmp(text_string, "html-tag:.fi", 12) == 0) && |
return is_tag && (strncmp(text_string, "html-tag:.fi", |
698 |
|
strlen("html-tag:.fi")) == 0) && |
699 |
(get_arg() == 0); |
(get_arg() == 0); |
700 |
} |
} |
701 |
|
|
705 |
|
|
706 |
int text_glob::is_fi (void) |
int text_glob::is_fi (void) |
707 |
{ |
{ |
708 |
return( is_tag && (strncmp(text_string, "html-tag:.fi", 12) == 0) && |
return( is_tag && (strncmp(text_string, "html-tag:.fi", |
709 |
|
strlen("html-tag:.fi")) == 0) && |
710 |
(get_arg() == 1) ); |
(get_arg() == 1) ); |
711 |
} |
} |
712 |
|
|
725 |
|
|
726 |
int text_glob::is_ce (void) |
int text_glob::is_ce (void) |
727 |
{ |
{ |
728 |
return is_tag && (strcmp(text_string, "html-tag:.ce") == 0); |
return is_tag && (strncmp(text_string, "html-tag:.ce", |
729 |
|
strlen("html-tag:.ce")) == 0); |
730 |
} |
} |
731 |
|
|
732 |
/* |
/* |
735 |
|
|
736 |
int text_glob::is_in (void) |
int text_glob::is_in (void) |
737 |
{ |
{ |
738 |
return is_tag && (strncmp(text_string, "html-tag:.in ", strlen("html-tag:.in ")) == 0); |
return is_tag && (strncmp(text_string, "html-tag:.in ", |
739 |
|
strlen("html-tag:.in ")) == 0); |
740 |
} |
} |
741 |
|
|
742 |
/* |
/* |
745 |
|
|
746 |
int text_glob::is_po (void) |
int text_glob::is_po (void) |
747 |
{ |
{ |
748 |
return is_tag && (strncmp(text_string, "html-tag:.po ", strlen("html-tag:.po ")) == 0); |
return is_tag && (strncmp(text_string, "html-tag:.po ", |
749 |
|
strlen("html-tag:.po ")) == 0); |
750 |
} |
} |
751 |
|
|
752 |
/* |
/* |
755 |
|
|
756 |
int text_glob::is_ti (void) |
int text_glob::is_ti (void) |
757 |
{ |
{ |
758 |
return is_tag && (strncmp(text_string, "html-tag:.ti ", strlen("html-tag:.ti ")) == 0); |
return is_tag && (strncmp(text_string, "html-tag:.ti ", |
759 |
|
strlen("html-tag:.ti ")) == 0); |
760 |
} |
} |
761 |
|
|
762 |
/* |
/* |
2082 |
void handle_state_assertion (text_glob *g); |
void handle_state_assertion (text_glob *g); |
2083 |
void do_end_para (text_glob *g); |
void do_end_para (text_glob *g); |
2084 |
int round_width (int x); |
int round_width (int x); |
2085 |
|
void handle_tag_within_title (text_glob *g); |
2086 |
|
|
2087 |
// ADD HERE |
// ADD HERE |
2088 |
|
|
2089 |
public: |
public: |
2216 |
} |
} |
2217 |
|
|
2218 |
/* |
/* |
2219 |
|
* handle_tag_within_title - handle a limited number of tags within |
2220 |
|
* the context of a table. Those tags which |
2221 |
|
* set values rather than generate spaces |
2222 |
|
* and paragraphs. |
2223 |
|
*/ |
2224 |
|
|
2225 |
|
void html_printer::handle_tag_within_title (text_glob *g) |
2226 |
|
{ |
2227 |
|
if (g->is_in() || g->is_ti() || g->is_po() || g->is_ce() || g->is_ll() |
2228 |
|
|| g->is_fi() || g->is_nf()) |
2229 |
|
troff_tag(g); |
2230 |
|
} |
2231 |
|
|
2232 |
|
/* |
2233 |
* do_center - handle the .ce commands from troff. |
* do_center - handle the .ce commands from troff. |
2234 |
*/ |
*/ |
2235 |
|
|
2375 |
title.has_been_found = TRUE; |
title.has_been_found = TRUE; |
2376 |
return; |
return; |
2377 |
} else if (t->is_a_tag()) { |
} else if (t->is_a_tag()) { |
2378 |
|
handle_tag_within_title(t); |
2379 |
page_contents->glyphs.sub_move_right(); /* move onto next word */ |
page_contents->glyphs.sub_move_right(); /* move onto next word */ |
2380 |
removed_from_head = ((!page_contents->glyphs.is_empty()) && |
removed_from_head = ((!page_contents->glyphs.is_empty()) && |
2381 |
(page_contents->glyphs.is_equal_to_head())); |
(page_contents->glyphs.is_equal_to_head())); |
2392 |
removed_from_head = ((!page_contents->glyphs.is_empty()) && |
removed_from_head = ((!page_contents->glyphs.is_empty()) && |
2393 |
(page_contents->glyphs.is_equal_to_head())); |
(page_contents->glyphs.is_equal_to_head())); |
2394 |
} |
} |
2395 |
} while ((! page_contents->glyphs.is_equal_to_head()) || (removed_from_head)); |
} while ((! page_contents->glyphs.is_equal_to_head()) || |
2396 |
|
(removed_from_head)); |
2397 |
} |
} |
2398 |
} |
} |
2399 |
} |
} |