anchor.diff:  %% @see null_text/1
   %% @see text_par/2
   
  +
   text(S) ->
  -    mktext(string(S)).   % convert to internal representation
  +    text(S, 8).
  +
  +text(S, TabWidth) ->
  +    mktext(string(S, TabWidth)).   % convert to internal representation
   
   %% This function is used internally only, and expects a string on
   %% the internal representation:
  
positive.code: %% The function `layout/1' performs the final transformation to a single
  %% flat string from the restricted document form.
  
  layout(L, FileFormat) ->
      lists:reverse(layout(0, L, FileFormat,  [])).
  
  layout(N, #above{d1 = #text{s = S}, d2 = L}, D,  Cs) ->
      case D of 
  	dos ->
  	    layout(N, L, D, [$\n, $\r | flatrev(string_chars(S), indent(N, Cs))]);
  	mac ->
  	    layout(N, L, D, [$\r | flatrev(string_chars(S), indent(N, Cs))]);
  	_->
  	    layout(N, L, D, [$\n | flatrev(string_chars(S), indent(N, Cs))])
      end;
  layout(N, #nest{n = N1, d = L}, D, Cs) ->
      layout(N + N1, L, D, Cs);
  layout(N, #text{s = S}, _D, Cs) ->
      flatrev(string_chars(S), indent(N, Cs));
  layout(_N, null, _D, Cs) ->
      Cs.
  
  indent(N, Cs) when N >= 8 ->
      indent(N - 8, [$\t | Cs]);
  indent(N, Cs) when N > 0 ->
      indent(N - 1, [$\s | Cs]);
  indent(_N, Cs) ->
      Cs.
  
  flatrev(Cs, As) ->
  
negative.code: %% Null strings are strings whose "official width" is zero, typically
  %% used for markup that is not supposed to affect the indentation.
  
  
  string(S, TabWidth) ->
      [strwidth(S, TabWidth)| S].
  
  null_string(S) ->
      [0 | S].
  