change the flag to automatic alignment