[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.58 and 1.62

version 1.58, 2010/04/06 07:27:42 version 1.62, 2010/05/13 06:22:11
Line 729  mdoc_nm_pre(MDOC_ARGS)
Line 729  mdoc_nm_pre(MDOC_ARGS)
 {  {
         struct htmlpair tag;          struct htmlpair tag;
   
         if (SEC_SYNOPSIS == n->sec && n->prev) {          if (SEC_SYNOPSIS == n->sec &&
                           n->prev && MDOC_LINE & n->flags) {
                 bufcat_style(h, "clear", "both");                  bufcat_style(h, "clear", "both");
                 PAIR_STYLE_INIT(&tag, h);                  PAIR_STYLE_INIT(&tag, h);
                 print_otag(h, TAG_BR, 1, &tag);                  print_otag(h, TAG_BR, 1, &tag);
Line 1116  mdoc_bl_pre(MDOC_ARGS)
Line 1117  mdoc_bl_pre(MDOC_ARGS)
 {  {
         struct ord      *ord;          struct ord      *ord;
   
           if (MDOC_HEAD == n->type)
                   return(0);
         if (MDOC_BLOCK != n->type)          if (MDOC_BLOCK != n->type)
                 return(1);                  return(1);
         if (MDOC_Enum != a2list(n))          if (MDOC_Enum != a2list(n))
Line 1386  mdoc_bd_pre(MDOC_ARGS)
Line 1389  mdoc_bd_pre(MDOC_ARGS)
                 }                  }
   
         /* FIXME: -centered, etc. formatting. */          /* FIXME: -centered, etc. formatting. */
           /* FIXME: does not respect -offset ??? */
   
         if (MDOC_BLOCK == n->type) {          if (MDOC_BLOCK == n->type) {
                 bufcat_su(h, "margin-left", &su);                  bufcat_su(h, "margin-left", &su);
Line 1554  mdoc_fd_pre(MDOC_ARGS)
Line 1558  mdoc_fd_pre(MDOC_ARGS)
         struct htmlpair  tag;          struct htmlpair  tag;
         struct roffsu    su;          struct roffsu    su;
   
         if (SEC_SYNOPSIS == n->sec) {          if (SEC_SYNOPSIS == n->sec && MDOC_LINE & n->flags) {
                 if (n->next && MDOC_Fd != n->next->tok) {                  if (n->next && MDOC_Fd != n->next->tok) {
                         SCALE_VS_INIT(&su, 1);                          SCALE_VS_INIT(&su, 1);
                         bufcat_su(h, "margin-bottom", &su);                          bufcat_su(h, "margin-bottom", &su);
Line 1602  mdoc_ft_pre(MDOC_ARGS)
Line 1606  mdoc_ft_pre(MDOC_ARGS)
 {  {
         struct htmlpair  tag;          struct htmlpair  tag;
   
         if (SEC_SYNOPSIS == n->sec)          if (SEC_SYNOPSIS == n->sec && MDOC_LINE & n->flags)
                 print_otag(h, TAG_DIV, 0, NULL);                  print_otag(h, TAG_DIV, 0, NULL);
   
         PAIR_CLASS_INIT(&tag, "ftype");          PAIR_CLASS_INIT(&tag, "ftype");
Line 1623  mdoc_fn_pre(MDOC_ARGS)
Line 1627  mdoc_fn_pre(MDOC_ARGS)
         int                      sz, i;          int                      sz, i;
         struct roffsu            su;          struct roffsu            su;
   
         if (SEC_SYNOPSIS == n->sec) {          if (SEC_SYNOPSIS == n->sec && MDOC_LINE & n->flags) {
                 SCALE_HS_INIT(&su, INDENT);                  SCALE_HS_INIT(&su, INDENT);
                 bufcat_su(h, "margin-left", &su);                  bufcat_su(h, "margin-left", &su);
                 su.scale = -su.scale;                  su.scale = -su.scale;
Line 1864  mdoc_in_pre(MDOC_ARGS)
Line 1868  mdoc_in_pre(MDOC_ARGS)
         int                      i;          int                      i;
         struct roffsu            su;          struct roffsu            su;
   
         if (SEC_SYNOPSIS == n->sec) {          if (SEC_SYNOPSIS == n->sec && MDOC_LINE & n->flags) {
                 if (n->next && MDOC_In != n->next->tok) {                  if (n->next && MDOC_In != n->next->tok) {
                         SCALE_VS_INIT(&su, 1);                          SCALE_VS_INIT(&su, 1);
                         bufcat_su(h, "margin-bottom", &su);                          bufcat_su(h, "margin-bottom", &su);
Line 2169  mdoc_lb_pre(MDOC_ARGS)
Line 2173  mdoc_lb_pre(MDOC_ARGS)
 {  {
         struct htmlpair tag;          struct htmlpair tag;
   
         if (SEC_SYNOPSIS == n->sec)          if (SEC_LIBRARY == n->sec && MDOC_LINE & n->flags)
                 print_otag(h, TAG_DIV, 0, NULL);                  print_otag(h, TAG_DIV, 0, NULL);
         PAIR_CLASS_INIT(&tag, "lib");          PAIR_CLASS_INIT(&tag, "lib");
         print_otag(h, TAG_SPAN, 1, &tag);          print_otag(h, TAG_SPAN, 1, &tag);
Line 2219  mdoc__x_pre(MDOC_ARGS)
Line 2223  mdoc__x_pre(MDOC_ARGS)
                 break;                  break;
         case(MDOC__T):          case(MDOC__T):
                 PAIR_CLASS_INIT(&tag[0], "ref-title");                  PAIR_CLASS_INIT(&tag[0], "ref-title");
                 print_text(h, "\\(lq");  
                 h->flags |= HTML_NOSPACE;  
                 break;                  break;
         case(MDOC__U):          case(MDOC__U):
                 PAIR_CLASS_INIT(&tag[0], "link-ref");                  PAIR_CLASS_INIT(&tag[0], "link-ref");
Line 2249  static void
Line 2251  static void
 mdoc__x_post(MDOC_ARGS)  mdoc__x_post(MDOC_ARGS)
 {  {
   
           /* TODO: %U */
   
         h->flags |= HTML_NOSPACE;          h->flags |= HTML_NOSPACE;
         switch (n->tok) {  
         case (MDOC__T):  
                 print_text(h, "\\(rq");  
                 h->flags |= HTML_NOSPACE;  
                 break;  
         default:  
                 break;  
         }  
         print_text(h, n->next ? "," : ".");          print_text(h, n->next ? "," : ".");
 }  }

Legend:
Removed from v.1.58  
changed lines
  Added in v.1.62

CVSweb