private int whiteSpaceLength(String indent){
  if (indent == null)   return 0;
 else {
    int size=0;
    int l=indent.length();
    int tabSize=getTabSize();
    for (int i=0; i < l; i++)     size+=indent.charAt(i) == '\t' ? tabSize : 1;
    return size;
  }
}

private int whiteSpaceLength ( String indent ) { if ( indent == null ) return 0 ; else { int size = 0 ; int l = indent . length ( ) ; int tabSize = getTabSize ( ) ; for ( int i = 0 ; i < l ; i ++ ) size += indent . charAt ( i ) == '\t' ? tabSize : 1 ; return size ; } }
returns the size in characters of a string . all characters count one , tabs count the editor ' s preference for the tab display
