The current handling of settings is a very roundabout leftover from the days of
gconf. Simplify and handle the setting more directly. At the same time move
handling of saving the window state to gsettings instead of saving it to a
config file.
Test was still failing because it checked the document content before closing.
This commit forces document flush before this check, making the test successful.
CRs always appear at the same modulus 2 offset in test strings, thus bug
https://github.com/mate-desktop/pluma/issues/100 is never detected.
Setting substring lengths to 3 causes the test to detect bug #100, thus failing,
as it should yet do.