Adriaan de Groot
e51fbdc851
[locale] Apply coding style
2020-04-21 15:35:10 +02:00
Adriaan de Groot
1f3046dcca
Merge branch 'issue-1374'
...
This is just updating tests, not fixing things.
2020-04-21 12:44:46 +02:00
Adriaan de Groot
69fae85fe8
[locale] Fix test-build
...
- needs <set> if it doesn't get pulled in implicitly
- mark tests as expected-to-fail to not block release
- SEE #1374
2020-04-21 12:43:45 +02:00
Adriaan de Groot
a63a92e3d5
[locale]Fix build (clang, Debian)
...
- This is a follow-up to d0c205c1cc6a2ae49935c92bfd52911b9a0d43f7;
I really don't know why static constexpr const elements that are
not referenced by address need to be defined separately.
2020-04-17 13:41:21 +02:00
Adriaan de Groot
ebb5efcd42
[locale] Mark test as expected-to-fail
...
- There are still 88 issues with the timezone images
2020-04-17 13:06:05 +02:00
Adriaan de Groot
e804ad2488
[libcalamaresui] Rename enlarge()
...
- rename enlarge to ensureSize() and change the meaning from
"make this much bigger" to "make sure this is displayed",
which is easier on the caller to calculate.
2020-04-17 12:56:47 +02:00
Adriaan de Groot
ade623f6b8
[locale] Shuffle code
...
- Put the building-up-the-overall-page in one spot
- Claim a little more vertical space for the TZ widget
2020-04-17 12:56:39 +02:00
Adriaan de Groot
c0be53523c
[locale] Give TZWidget a fixed size
2020-04-17 10:02:54 +02:00
FLVAL
3f6e242fd9
Add files via upload
...
Resaved cause showing not 100% upload with latest correction
2020-04-16 19:21:44 +02:00
FLVAL
82c4e7aa54
Add files via upload
...
- udpated the _0.0 and _1.0 to not get overlap between Gibraltar and Cueta
- Fakaofo correction on _10.0 and _-11.0
- pin reduced size
2020-04-16 19:09:49 +02:00
Adriaan de Groot
82ba4be5e7
[locale] Test for pixel-perfect location of Gibraltar and Ceuta
...
- Can't get Gibraltar (and Ceuta) to be distinguished
2020-04-16 17:59:12 +02:00
Adriaan de Groot
3db901bd09
[locale] Expand tests to show overlapping locations
...
- This isn't something that Calamares can acutally fix,
so the test will be disabled later. After all, if
Brazzaville and Kinshasa are close enough that on the
map they are the same pixel, we can't move the cities.
2020-04-16 15:48:17 +02:00
FLVAL
e5b2faad9a
Add files via upload
...
Timezones updated for these countries found on pixel detection tool
Dublin is in 0 (-1 needs editing)
Gibraltar should be 1.0 (0 needs editing)
Guernsey and Jersey are in 0 (1.0 needs editing)
Lisbon is in 0 (-1 needs editing)
Vilnius should be in 2 (1 needs editing)
2020-04-16 02:54:38 +02:00
Adriaan de Groot
cd66405363
[locale] Test TZ images properly
...
- the test wasn't built with DEBUG_TIMEZONES, so it didn't get the
overlap-checking code at all.
2020-04-15 14:30:10 +02:00
Adriaan de Groot
d0c205c1cc
[locale] Fix build (gcc, Debian)
2020-04-15 14:19:47 +02:00
Adriaan de Groot
b890345b1f
[locale] Tidy includes
2020-04-15 11:45:27 +02:00
Adriaan de Groot
f7a87338b8
[locale] math headers got lost
2020-04-15 11:41:59 +02:00
Adriaan de Groot
a2a10d14b6
[locale] Improve logging in tests
2020-04-14 16:24:56 +02:00
Adriaan de Groot
29fd0e0319
[locale] Expand test to check zones-overlap
...
- Document index and find methods,
- Check that each location is claimed by only one image (e.g. by
one zone). This is currently false.
2020-04-14 16:21:24 +02:00
Adriaan de Groot
1d5c4f13aa
[locale] Move the find-a-zone-image-for position to the image list
2020-04-14 16:06:21 +02:00
Adriaan de Groot
6173f9337a
[locale] Refactor long+lat -> x,y mapping
...
- Move this code to a static method since it only depends on the
expected image size (which here, is managed by the image list).
2020-04-14 15:24:05 +02:00
Adriaan de Groot
3945008956
[locale] Test the TZ image loader
...
- QImage needs Qt5::Gui, so this isn't a guiless-test; it can use
the offscreen QPA, though.
- Check that the images are all the same size
- Debugging / check code removed from timezonewidget
2020-04-14 15:10:04 +02:00
Adriaan de Groot
340c462062
[locale] Refactor loading of timezone images
...
- Move the image-loading to a separate class
2020-04-14 14:44:24 +02:00
Adriaan de Groot
4b65600c08
[locale] Remove useless localeglobal
...
- Although ::init() was called, none of the actual functionality
from localeglobal was still in use.
2020-04-14 12:37:22 +02:00
Adriaan de Groot
36d9e7d8f4
[locale] Extend tests with tz-image-validation
...
- The idea is to check all the TZ images for consistency, like
TimeZoneWidget::setCurrentLocation() does when DEBUG_TIMEZONES is
on; a zone-pixel should be set in only **one** image.
The test so far is just a stub.
2020-04-14 11:59:45 +02:00
Adriaan de Groot
e84db033b0
[locale] Debug-message typo
2020-04-14 11:57:03 +02:00
Adriaan de Groot
f9d888ec24
[locale] Warnings--
...
- remove unused variables, tighten up code some
- while here, apply coding style
2020-04-14 11:32:15 +02:00
Adriaan de Groot
022e62b829
[licale] Fix build with DEBUG_TIMEZONES
...
- QLatin1String isn't a constexpr; the whole ZONE is a bit derpy,
so let's just #define it.
2020-04-14 11:26:03 +02:00
Adriaan de Groot
08b5012946
[locale] Apply coding style to Config
...
- ci/calamaresstyle
- sort includes by kind (local module, Calamares, Qt, STL)
- add copyright line
2020-03-24 22:48:14 +01:00
Camilo Higuita
8ff1996e12
add the localq module and config to locale
2020-03-24 09:47:53 -05:00
Adriaan de Groot
ebb3f319cc
[modules] Be more consistent in include punctuation
...
- Use <> for Qt, system, externals
- Use double-quotes for Calamares headers
2020-03-09 21:05:15 -05:00
Adriaan de Groot
adf81c0ab5
[locale][packagechooser] Fix tests, QCOMPARE again
2020-02-21 18:24:39 +01:00
Adriaan de Groot
6f996d8eed
CMake: give yamlcpp a proper imported target
...
- This makes linking easier,
- Adds the right includes (needed on FreeBSD),
- Lets us drop silly GUI setting for non-GUI tests (I think this was
a side-effect of compiling on FreeBSD, where UI would pull in
/usr/local/include).
2020-02-17 14:55:12 +01:00
Adriaan de Groot
4495a4c739
CMake: Allow extra libraries in calamares_add_test
...
- Extra libraries specified via LIBRARIES part of CMake function
- Convert all the other module tests
2020-02-17 14:36:52 +01:00
Adriaan de Groot
b044549013
[libcalamares] Merge PluginDllMacro.h into DllMacro.h
...
- Let's just have one header definining export- and visibility-
macros for Calamares. They are still selected based on the
export flags (*_PRO), just defined in one header instead of two.
2020-02-17 11:37:35 +01:00
Adriaan de Groot
a09593e4a2
[locale] Tighten up language-matching
...
- Drop plain startsWith() matching, since we now have "as" and "ast"
as supported languages, where one name is a prefix of the other.
2020-01-28 17:35:54 +01:00
Adriaan de Groot
49690fc681
[locale] Remove superfluous code
...
- the list is already filtered for UTF-8, so this is redundant
- this *incidentally* fixes the problem with Assamese and Asturian,
since Assamese (as_IN) was having its only entry removed,
after which it would match Asturian (ast_ES)
2020-01-28 16:41:15 +01:00
Adriaan de Groot
97f622e094
[locale] Use standard algorithms
2020-01-28 15:50:08 +01:00
Adriaan de Groot
1a8926181e
[locale] Warnings-- (initialization-order)
2020-01-07 10:46:26 +01:00
Adriaan de Groot
1625bb1dae
[locale] Support Qt 5.9
...
FIXES #1296
2020-01-07 00:09:04 +01:00
Adriaan de Groot
7bea19a62c
[locale] Fix build with debugging enabled (API changes)
2019-12-11 08:45:35 -05:00
Adriaan de Groot
242b79e2e1
[locale] Remove old Location information
...
- all the TZ location information now lives in the Calamares
locale service and the TZ list
- replace the Location class that was local to the timezone
widget by the TZZone class
- chase a bunch of small API changes that this needs
2019-12-11 08:45:35 -05:00
Adriaan de Groot
e164f8d63a
[locale] Fix build with DEBUG_TIMEZONE
...
- all the API changes were not reflected in the debugging code
2019-12-10 16:19:06 -01:00
Adriaan de Groot
fb9d53909e
[locale] Drop ZONES #define
...
- this was a "cheap" way to write a list, but going through
QStringList::split() is just a long-way-around for static
initialization
2019-12-10 16:09:48 -01:00
Adriaan de Groot
2dfbed40c5
[locale] Move defines
...
- Used in only one place, move to .cpp
- Drop useless scaling all the images *are* that size already
- Add debugging check that the images match expected size
2019-12-10 10:00:16 -07:00
Adriaan de Groot
9d9d9c361d
[locale] Clean up constants
...
- move LOCALESDIR to the one place it's used
- remove file with only unused #defines
2019-12-10 17:46:09 +01:00
Adriaan de Groot
7354d35faf
[locale] Apply coding style to timezonewidget/
2019-12-10 17:42:58 +01:00
Adriaan de Groot
1e04924224
[locale] Drop the TZ-widget's timezone database
...
- use the global TZ service instead
- contains hacks to keep some of the API unchanged, which will be
removed shortly
2019-12-10 17:29:35 +01:00
Adriaan de Groot
4089a01cb1
[locale] Create TZ model earlier
2019-12-11 01:31:56 +10:00
Adriaan de Groot
226530cf6f
[locale] Use model functions from locale service
...
- drop the home-grown combo-box filling, use model
2019-12-11 01:04:09 +10:00