[BACK]Return to mdoc_html.c CVS log [TXT][DIR] Up to [cvsweb.bsd.lv] / mandoc

Diff for /mandoc/mdoc_html.c between version 1.156 and 1.157

version 1.156, 2011/04/04 15:33:03 version 1.157, 2011/04/04 15:41:05
Line 751  mdoc_nm_pre(MDOC_ARGS)
Line 751  mdoc_nm_pre(MDOC_ARGS)
 static int  static int
 mdoc_xr_pre(MDOC_ARGS)  mdoc_xr_pre(MDOC_ARGS)
 {  {
         struct htmlpair          tag[2];          struct htmlpair  tag[2];
         const struct mdoc_node  *nn;  
   
         if (NULL == n->child)          if (NULL == n->child)
                 return(0);                  return(0);
Line 768  mdoc_xr_pre(MDOC_ARGS)
Line 767  mdoc_xr_pre(MDOC_ARGS)
         } else          } else
                 print_otag(h, TAG_A, 1, tag);                  print_otag(h, TAG_A, 1, tag);
   
         nn = n->child;          n = n->child;
         print_text(h, nn->string);          print_text(h, n->string);
   
         if (NULL == (nn = nn->next))          if (NULL == (n = n->next))
                 return(0);                  return(0);
   
         h->flags |= HTML_NOSPACE;          h->flags |= HTML_NOSPACE;
         print_text(h, "(");          print_text(h, "(");
         h->flags |= HTML_NOSPACE;          h->flags |= HTML_NOSPACE;
         print_text(h, nn->string);          print_text(h, n->string);
         h->flags |= HTML_NOSPACE;          h->flags |= HTML_NOSPACE;
         print_text(h, ")");          print_text(h, ")");
         return(0);          return(0);
Line 1168  mdoc_d1_pre(MDOC_ARGS)
Line 1167  mdoc_d1_pre(MDOC_ARGS)
 static int  static int
 mdoc_sx_pre(MDOC_ARGS)  mdoc_sx_pre(MDOC_ARGS)
 {  {
         struct htmlpair          tag[2];          struct htmlpair  tag[2];
         const struct mdoc_node  *nn;          char             buf[BUFSIZ];
         char                     buf[BUFSIZ];  
   
         strlcpy(buf, "#", BUFSIZ);          strlcpy(buf, "#", BUFSIZ);
         for (nn = n->child; nn; nn = nn->next) {          for (n = n->child; n; n = n->next) {
                 html_idcat(buf, nn->string, BUFSIZ);                  html_idcat(buf, n->string, BUFSIZ);
                 if (nn->next)                  if (n->next)
                         html_idcat(buf, " ", BUFSIZ);                          html_idcat(buf, " ", BUFSIZ);
         }          }
   
Line 1451  mdoc_ft_pre(MDOC_ARGS)
Line 1449  mdoc_ft_pre(MDOC_ARGS)
 static int  static int
 mdoc_fn_pre(MDOC_ARGS)  mdoc_fn_pre(MDOC_ARGS)
 {  {
         struct tag              *t;          struct tag      *t;
         struct htmlpair          tag[2];          struct htmlpair  tag[2];
         const struct mdoc_node  *nn;          char             nbuf[BUFSIZ];
         char                     nbuf[BUFSIZ];          const char      *sp, *ep;
         const char              *sp, *ep;          int              sz, i, pretty;
         int                      sz, i;  
   
           pretty = MDOC_SYNPRETTY & n->flags;
         synopsis_pre(h, n);          synopsis_pre(h, n);
   
         /* Split apart into type and name. */          /* Split apart into type and name. */
Line 1515  mdoc_fn_pre(MDOC_ARGS)
Line 1513  mdoc_fn_pre(MDOC_ARGS)
         bufcat_style(h, "white-space", "nowrap");          bufcat_style(h, "white-space", "nowrap");
         PAIR_STYLE_INIT(&tag[1], h);          PAIR_STYLE_INIT(&tag[1], h);
   
         for (nn = n->child->next; nn; nn = nn->next) {          for (n = n->child->next; n; n = n->next) {
                 i = 1;                  i = 1;
                 if (MDOC_SYNPRETTY & n->flags)                  if (MDOC_SYNPRETTY & n->flags)
                         i = 2;                          i = 2;
                 t = print_otag(h, TAG_I, i, tag);                  t = print_otag(h, TAG_I, i, tag);
                 print_text(h, nn->string);                  print_text(h, n->string);
                 print_tagq(h, t);                  print_tagq(h, t);
                 if (nn->next) {                  if (n->next) {
                         h->flags |= HTML_NOSPACE;                          h->flags |= HTML_NOSPACE;
                         print_text(h, ",");                          print_text(h, ",");
                 }                  }
Line 1531  mdoc_fn_pre(MDOC_ARGS)
Line 1529  mdoc_fn_pre(MDOC_ARGS)
         h->flags |= HTML_NOSPACE;          h->flags |= HTML_NOSPACE;
         print_text(h, ")");          print_text(h, ")");
   
         if (MDOC_SYNPRETTY & n->flags) {          if (pretty) {
                 h->flags |= HTML_NOSPACE;                  h->flags |= HTML_NOSPACE;
                 print_text(h, ";");                  print_text(h, ";");
         }          }

Legend:
Removed from v.1.156  
changed lines
  Added in v.1.157

CVSweb