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

Diff for /mandoc/html.c between version 1.216 and 1.220

version 1.216, 2017/07/14 15:56:37 version 1.220, 2017/09/06 16:24:25
Line 250  html_make_id(const struct roff_node *n)
Line 250  html_make_id(const struct roff_node *n)
   
         buf = NULL;          buf = NULL;
         deroff(&buf, n);          deroff(&buf, n);
           if (buf == NULL)
                   return NULL;
   
         /* http://www.w3.org/TR/html5/dom.html#the-id-attribute */          /* http://www.w3.org/TR/html5/dom.html#the-id-attribute */
   
Line 623  print_otag(struct html *h, enum htmltag tag, const cha
Line 625  print_otag(struct html *h, enum htmltag tag, const cha
                 case 'u':                  case 'u':
                         su = va_arg(ap, struct roffsu *);                          su = va_arg(ap, struct roffsu *);
                         break;                          break;
                 case 'v':  
                         i = va_arg(ap, int);  
                         su = &mysu;  
                         SCALE_VS_INIT(su, i);  
                         break;  
                 case 'w':                  case 'w':
                         if ((arg2 = va_arg(ap, char *)) == NULL)                          if ((arg2 = va_arg(ap, char *)) != NULL) {
                                 break;                                  su = &mysu;
                         su = &mysu;                                  a2width(arg2, su);
                         a2width(arg2, su);                          }
                           if (*fmt == '*') {
                                   if (su != NULL && su->unit == SCALE_EN &&
                                       su->scale > 5.9 && su->scale < 6.1)
                                           su = NULL;
                                   fmt++;
                           }
                         if (*fmt == '+') {                          if (*fmt == '+') {
                                 /* Increase to make even bold text fit. */                                  if (su != NULL) {
                                 su->scale *= 1.2;                                          /* Make even bold text fit. */
                                 /* Add padding. */                                          su->scale *= 1.2;
                                 su->scale += 3.0;                                          /* Add padding. */
                                           su->scale += 3.0;
                                   }
                                 fmt++;                                  fmt++;
                         }                          }
                         if (*fmt == '-') {                          if (*fmt == '-') {
                                 su->scale *= -1.0;                                  if (su != NULL)
                                           su->scale *= -1.0;
                                 fmt++;                                  fmt++;
                         }                          }
                         break;                          break;
Line 652  print_otag(struct html *h, enum htmltag tag, const cha
Line 658  print_otag(struct html *h, enum htmltag tag, const cha
                 /* Second letter: style name. */                  /* Second letter: style name. */
   
                 switch (*fmt++) {                  switch (*fmt++) {
                 case 'b':  
                         attr = "margin-bottom";  
                         break;  
                 case 'h':                  case 'h':
                         attr = "height";                          attr = "height";
                         break;                          break;
Line 663  print_otag(struct html *h, enum htmltag tag, const cha
Line 666  print_otag(struct html *h, enum htmltag tag, const cha
                         break;                          break;
                 case 'l':                  case 'l':
                         attr = "margin-left";                          attr = "margin-left";
                         break;  
                 case 't':  
                         attr = "margin-top";  
                         break;                          break;
                 case 'w':                  case 'w':
                         attr = "width";                          attr = "width";

Legend:
Removed from v.1.216  
changed lines
  Added in v.1.220

CVSweb