Fix launch GUI in IntelliJ with bad preferences

## Context
This library has a client execution and release tests.
We use a main window to launch and test the segmentation gui. 
This window is implemented in a test class, so the gui execution in IntelliJ uses the test classpath.

## Description
As IntelliJ uses the production resources AND the test resources, the main window was loading a unit test preference file instead of the production one.
To fix this behaviour, we refactored the unit tests so that preferences are loaded from a ```String``` and no more from a ```File```