modified for changing hard tab to soft tab