first stage of auto indent