[BACK]Return to util.c CVS log [TXT][DIR] Up to [local] / src / usr.bin / mg

Diff for /src/usr.bin/mg/util.c between version 1.48 and 1.49

version 1.48, 2023/04/21 13:39:37 version 1.49, 2023/04/21 14:14:13
Line 482 
Line 482 
 int  int
 space_to_tabstop(int f, int n)  space_to_tabstop(int f, int n)
 {  {
         int     c;          int     col, target;
   
         if (n < 0)          if (n < 0)
                 return (FALSE);                  return (FALSE);
         if (n == 0)          if (n == 0)
                 return (TRUE);                  return (TRUE);
   
         c = curwp->w_doto;          col = target = getcolpos(curwp);
         while (n-- > 0)          while (n-- > 0)
                 c = ntabstop(c, curbp->b_tabw);                  target = ntabstop(target, curbp->b_tabw);
         return (linsert(c - curwp->w_doto, ' '));          return (linsert(target - col, ' '));
 }  }
   
 /*  /*

Legend:
Removed from v.1.48  
changed lines
  Added in v.1.49