However, I did find that if your add a 'gap_limit': 10 at top level in the wallet file then it does behave correctly and respect new addresses. ie. red addresses become normal.
Doesn't work for me. Where exactly do you have to place it?
I placed it immediately before the seed version. eg.
'imported_keys': {}, 'seed_version': 6}
becomes,
'imported_keys': {}, 'gap_limit': 10, 'seed_version': 6}
You don't have to mess about with the json wallet file. Just type the following in the electrum gui console:
wallet.storage.put( 'gap_limit', 100)
The above command sets it to a 100 but you can, of course, use any number you like. Remember to restart electrum after you do the above!