From: Erik V. <eri...@hc...> - 2007-01-13 11:06:26
|
> > There is a new properties file called "my.properties", > > which is intended to hold the user's local preferences > > (in so far these are not configurable by some screen). > > Currently this file only holds the SVG/GIF tile preference, > > and the log4j properties. > > One of the log4j properties is the log file path; the > > default is log/18xx.log. > > > > We should include a "remember my choices" style of checkbox or button > and save more of the UI fields into the properties file. This should > be in the Options UI and one of the drop-downs so the user can do it > both before starting a game and during a game. Do we already have any choice items like that? I don't think so, but once we have such items, we should find a place to store these. I don't know how such storage is realised in other systems. If it's a properties file, I would suggest to create another one for that purpose: one that can be overwritten by the program after any change. my.properties would then be reserved for properties that are not (or not yet) maintainable via the UI. However, I don't have any strong feelings about this. BTW by default log4j expects a configuration file named log4j.properties, but I have changed this into my.properties by setting a system property in the main() method. This property is checked by log4j. It can also be provided on the command line, but I don't check that yet. This property setting should always be the first statement to execute in any new main program that we might develop in the future. Erik. |