harmony-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Sian January" <sianjanu...@googlemail.com>
Subject Re: [tools] settings/config file
Date Tue, 17 Jun 2008 15:16:18 GMT
Hi András,

In general I would say if it's something the user would want to change then
they should be able to do it via the GUI rather than having to edit a file
(e.g clicking "Window" > "Preferences" or similar).  You might need to use a
file under the covers to store the information, and in that case I think you
would probably put it somewhere in the user's home directory since an
installation of Java can be used by multiple users.

An alternative is to define a -X option, which would save you having to
store the preferences in a file, but the user would have to specify the
option every time they start the tool.

However it might be easier for you to avoid this entirely, as Sun's
policytool does.  For the specific examples you mentioned it might be best
to just choose intelligent defaults, e.g. use the System font size and
choose a good default for the window location.  That's probably what I would
do personally (at least for the two examples that you mentioned).



On 17/06/2008, András Belicza <iczaaa@gmail.com> wrote:
> Hi!
> I'm developing the Harmony policytool tool, and 1 question emerged to me.
> There might be reasonable settings that one might want to put in a config
> file in order so Harmony users can change it (only in config file) without
> having to recompile the whole Harmony project.
> Where can I put such config file for policytool?
> It would be a single text file like 'policytool.cfg' in which I would put
> some options/properties which could drive/control the running of
> For example font type, font size, GUI window location etc. Currently I'm
> having these in the Java sources.
> And how can I reach that file? E.g. same directory as policytool.exe or
> relative to a system variable like $JAVA_HOME or $HARMONY_HOME?
> Or should I just leave these options gathered in one central Java source
> file?
> Thanks,
>    András Belicza

Unless stated otherwise above:
IBM United Kingdom Limited - Registered in England and Wales with number
Registered office: PO Box 41, North Harbour, Portsmouth, Hampshire PO6 3AU

  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message