Print this page
9718 update mandoc to 1.14.4

Split Close
Expand all
Collapse all
          --- old/usr/src/cmd/mandoc/tbl_html.c
          +++ new/usr/src/cmd/mandoc/tbl_html.c
   1      -/*      $Id: tbl_html.c,v 1.23 2017/07/31 16:14:10 schwarze Exp $ */
        1 +/*      $Id: tbl_html.c,v 1.24 2018/06/25 13:45:57 schwarze Exp $ */
   2    2  /*
   3    3   * Copyright (c) 2011 Kristaps Dzonsons <kristaps@bsd.lv>
   4    4   * Copyright (c) 2014, 2015, 2017 Ingo Schwarze <schwarze@openbsd.org>
   5    5   *
   6    6   * Permission to use, copy, modify, and distribute this software for any
   7    7   * purpose with or without fee is hereby granted, provided that the above
   8    8   * copyright notice and this permission notice appear in all copies.
   9    9   *
  10   10   * THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
  11   11   * WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
↓ open down ↓ 60 lines elided ↑ open up ↑
  72   72          case SCALE_MM:  /* 1/1000 inch */
  73   73                  return su->scale / 100.0;
  74   74          default:
  75   75                  abort();
  76   76          }
  77   77  }
  78   78  
  79   79  static void
  80   80  html_tblopen(struct html *h, const struct tbl_span *sp)
  81   81  {
  82      -        struct tag      *t;
  83      -        int              ic;
  84      -
  85   82          if (h->tbl.cols == NULL) {
  86   83                  h->tbl.len = html_tbl_len;
  87   84                  h->tbl.slen = html_tbl_strlen;
  88   85                  h->tbl.sulen = html_tbl_sulen;
  89   86                  tblcalc(&h->tbl, sp, 0, 0);
  90   87          }
  91      -
  92   88          assert(NULL == h->tblt);
  93   89          h->tblt = print_otag(h, TAG_TABLE, "c", "tbl");
  94      -
  95      -        t = print_otag(h, TAG_COLGROUP, "");
  96      -        for (ic = 0; ic < sp->opts->cols; ic++)
  97      -                print_otag(h, TAG_COL, "shw", h->tbl.cols[ic].width);
  98      -        print_tagq(h, t);
  99   90  }
 100   91  
 101   92  void
 102   93  print_tblclose(struct html *h)
 103   94  {
 104   95  
 105   96          assert(h->tblt);
 106   97          print_tagq(h, h->tblt);
 107   98          h->tblt = NULL;
 108   99  }
↓ open down ↓ 53 lines elided ↑ open up ↑
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX