Add flags and character ranges