Reading the preferences will now:
* read the default preferences (if defined) and add them into the preferences config
* read the unsynced preferences and add them on top of any default preferences
* read the synced preferences and add them on top of the default and unsynced preferences.
Writing the preferences works basically the same way, just that it writes out preferences to either the synced or unsynced preferences file depending on the preference. This is determined by the std::arrays added to preferences.hpp and is checked at compile time via the static_assert these these arrays and the prefs_list are all constexpr - forgetting to add a new preference or remove an existing preference to these arrays will cause a compile error.
This also means that unknown preferences will not be written back out, so the removal of any existing "password" and "password_is_wrapped" preferences no longer needs to be explicitly done. Additionally, the clear() and erase() methods are removed:
* clear() is not desireable in the first place and it's not actually applicable to anything currently using it since they're just single attributes at the root of the config object anyway
* erase() is a one liner method that's not needed anymore since all handling now has access to the preferences_ config object
For GCC-13, cfb28fbfb5 (in master)
added -Wno-dangling-reference, and that commit explains why the
false positive is triggered by calling find_widget. For GCC-14
there's an attribute so we can flag this specific function as ok.
Clang complains about unknown attributes in the gnu:: namespace,
so has to have the #if, and the #if means we need the #ifdef.
There are still warnings in src/actions/attack.cpp, but that area is
being worked on for an infinite recursion bug, and those warnings log
in a single batch instead of being spread across multiple .cpp files.
(cherry picked from commit e42f83a8d2,
with an improvement to the documentation after cherry-picking)
These are causing warnings with GCC-14.
An iterator can often be a struct containing a single pointer, so
creating a reference to such a small struct doesn't make sense.
The structure returned by child_range is likely to be exactly two
pointers, so it's not a burden to keep it even though back() has
already finished accessing the child_iterator.
(cherry picked from commit 087fa65dc5)
Appears to be unused, and is still Python2 code. To be Python3, these
lines need to change:
- f = file(fn)
+ f = open(fn, encoding="utf-8")
- gettext = f.read().decode("utf8")
+ gettext = f.read()
Even knowing how to make it work, it still doesn't seem useful to keep.
wmlunits uses html_output.Translation, but that's not this class. It's
a wrapper around Python's standard gettext library, in html_output.py.
dawn.png was leftover from the Time of Day being shown with an overlay
image; 074e157400 removed dusk.png and
night.png. The image itself should be a transparent blue hexagon, but
the alpha channel was corrupted, and so it appeared completely
transparent.
In copyrights.csv, make the capitalisation of Kitty's name consistent,
and attribute the orb-disengaged.png image.