[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[Octave-bug-tracker] [bug #55855] GUI configuration files are not locate
From: |
Mike Miller |
Subject: |
[Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention |
Date: |
Wed, 13 Mar 2019 21:21:02 -0400 (EDT) |
User-agent: |
Mozilla/5.0 (X11; Linux x86_64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/72.0.3626.121 Safari/537.36 |
Follow-up Comment #11, bug #55855 (project octave):
I haven't tested this patch yet, but I looked it over, here are a few
suggestions.
* When you check for the old_settings_file, I don't think you need to refer to
XDG_CONFIG_HOME, since that was only done recently on default, just look in
home_path + "/.config/octave".
* I don't think we need a new prompt here when migrating old settings to new
settings. Instead of extra code to try to copy the old file on top of the new
one, what about (pseudocode):
m_default_settings = new QSettings (...).
m_settings_file = m_default_settings->fileName ();
if (! exists m_settings_file)
old_settings_file = home + "/.config/octave/qt-settings";
if (exists old_settings_file)
QSettings old_settings (old_settings_file, IniFormat);
for (key : old_settings.allKeys ())
m_default_settings->setValue (key, old_settings.value (key));
endfor
endif
endif
With that kind of approach, I don't think it's necessary to prompt whether old
settings should be read, or show a warning if old settings can't be read, just
move on and start with defaults if the old file doesn't exist or can't be read
for some reason.
_______________________________________________________
Reply to this item at:
<https://savannah.gnu.org/bugs/?55855>
_______________________________________________
Message sent via Savannah
https://savannah.gnu.org/
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, (continued)
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten, 2019/03/07
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Mike Miller, 2019/03/07
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten, 2019/03/08
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Mike Miller, 2019/03/08
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten, 2019/03/08
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Mike Miller, 2019/03/08
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten, 2019/03/08
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/10
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/11
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/11
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention,
Mike Miller <=
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/16
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Mike Miller, 2019/03/16
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/16
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/20
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Mike Miller, 2019/03/21
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/22
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/22
- [Octave-bug-tracker] [bug #55855] GUI configuration files are not located following each platform's convention, Torsten Lilge, 2019/03/31