summaryrefslogtreecommitdiff
Commit message (Collapse)AuthorAgeFilesLines
* Fix line heights in improper gravitiesgravity-fixesMatthias Clasen2021-11-272-5/+5
| | | | | | | | | | | Without this, we end up with line height being zero in gravity north or west. The visible symptom is that wrapped lines are drawn on top of each other with line-height != 0. Affected tests have been updated. Fixes: #631
* Fix misplaced glyphs in gravity eastMatthias Clasen2021-11-271-1/+4
| | | | | This was showing up as glyphs placed outside their logical extents.
* 1.49.41.49.4Matthias Clasen2021-11-272-1/+15
|
* Merge branch 'font-serialize-test' into 'main'Matthias Clasen2021-11-274-5/+111
|\ | | | | | | | | Avoid cosmetic ugliness See merge request GNOME/pango!522
| * Add a test for pango_font_serializefont-serialize-testMatthias Clasen2021-11-272-1/+79
| | | | | | | | | | Now that we have fonts in git, we can reliably test this.
| * font: Avoid cosmetic uglinessMatthias Clasen2021-11-272-4/+32
|/ | | | | | | | When setting variations to "", font descriptions would add an ugly useless " @" at the end of their serialization. Avoid that. Test included.
* Merge branch 'fix-emoji-in-tests' into 'main'Matthias Clasen2021-11-2728-1386/+1309
|\ | | | | | | | | Make sure glyphinfo is fully initialized See merge request GNOME/pango!523
| * Avoid an out-of-bound accessMatthias Clasen2021-11-271-1/+1
| | | | | | | | | | We can only use the width of the previous char if we are not at the first char. Found by asan.
| * Update tests one more timeMatthias Clasen2021-11-2622-1375/+1230
| |
| * tests: Fix font setup for EmojiMatthias Clasen2021-11-262-6/+70
| | | | | | | | We need to copy the scale hack for bitmaps.
| * Add more Emoji to the included emoji fontMatthias Clasen2021-11-261-0/+0
| |
| * Make sure glyphinfo is fully initializedMatthias Clasen2021-11-261-0/+1
| | | | | | | | | | The alternative is random test failures, now that we check all these fields in test-layout.
| * Add more fonts for test-layout testsMatthias Clasen2021-11-262-4/+7
|/
* Merge branch 'hinted-metrics-fixes' into 'main'Matthias Clasen2021-11-263-18/+54
|\ | | | | | | | | | | | | Hinted metrics fixes Closes #626 See merge request GNOME/pango!518
| * Test more font sizes in the empty line height testSebastian Keller2021-11-221-14/+24
| | | | | | | | | | | | This would have caught the issue fixed in the previous commit, because the default font choice of "serif 12" happened to not be affected by it. Most other fonts or font sizes however were.
| * Calculate hinted font height based on the hinted extentsSebastian Keller2021-11-221-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | The previous code was calculating the rounded up version of the difference between the unhinted ascender and uninted descender. This however would only result in the correct height if both unhinted extentss together only differ by less then an a Pango unit from their hinted counterparts. Otherwise the resulting height would be 1 unit too short. Fix this by using the difference between the hinted extents as height. Fixes: https://gitlab.gnome.org/GNOME/pango/-/issues/626
| * Introduce and use FLOOR and CEIL macros in Pango unitsSebastian Keller2021-11-222-4/+30
| | | | | | | | | | | | | | This replaces the code that was trying to implement those via the ROUND macro. This avoids a potential issue with values that already were on whole units being rounded up to the next whole unit in the code that was implementing CEIL this way.
* | Merge branch 'serialization-improvements' into 'main'Matthias Clasen2021-11-2566-1431/+17285
|\ \ | | | | | | | | | | | | Rename the serialize errors See merge request GNOME/pango!520
| * | Skip test-layout on macOSserialization-improvementsMatthias Clasen2021-11-251-1/+6
| | | | | | | | | | | | It should work there, but it doesn't.
| * | test-layout: Fix up comparison directionMatthias Clasen2021-11-251-1/+1
| | | | | | | | | | | | This makes more sense.
| * | test-layout: Use an fc fontmapMatthias Clasen2021-11-251-1/+13
| | | | | | | | | | | | | | | | | | | | | Our new, more precise font checks rely on data from fontconfig to identify fonts uniquely. So make sure that we use a custom fc fontmap, if we have one.
| * | Add a newline to serialization resultsMatthias Clasen2021-11-2529-216/+101
| | | | | | | | | | | | | | | | | | | | | | | | Otherwise editing the output in an editor is likely to make the data not match anymore, since most editors will add a final newline. Update all tests
| * | Make test-layout use included fontsMatthias Clasen2021-11-2533-205/+1685
| | | | | | | | | | | | | | | | | | | | | | | | | | | Add Cantarell, DejaVu Sans and a subset of Noto Color Emoji to git, and make test-layout use just those fonts. This should help with keeping the ci from breaking due to different system fonts. Update tests.
| * | test-layout: Drop the --show-font optionMatthias Clasen2021-11-241-6/+0
| | | | | | | | | | | | Not used anymore.
| * | serializer: Include unknown glyphs countMatthias Clasen2021-11-241-0/+3
| | |
| * | Add pango_font_serializeMatthias Clasen2021-11-242-0/+58
| | | | | | | | | | | | | | | | | | | | | Another debug api. This function produces a serialization of a font that is enough to uniquely identify the font. This is more detailed than what pango_font_describe creates.
| * | Add more testsMatthias Clasen2021-11-246-9/+1049
| | | | | | | | | | | | | | | These were produced with the help of http://gitlab.gnome.org/matthiasc/layout-editor
| * | serializer: Support a "comment" fieldMatthias Clasen2021-11-241-0/+47
| | | | | | | | | | | | | | | | | | Json doesn't have comments, so we have to add an explicit comment value. This will be useful to describe what test cases are about.
| * | Update test-layoutMatthias Clasen2021-11-2426-349/+13864
| | | | | | | | | | | | | | | | | | Use the new output serialization in test-layout to store both the input and output in the same file.
| * | Optionally serialize outputMatthias Clasen2021-11-2423-917/+384
| | | | | | | | | | | | | | | | | | | | | If requested, serialize lines, runs, and log attrs. This will let us use the serialization format to record not just the test inputs, but outputs as well.
| * | Add a way to get the font matrixMatthias Clasen2021-11-243-0/+44
| | | | | | | | | | | | | | | | | | Add some private api for the serializer to get the font matrix. This is needed to let the serializer write a unique fingerprint for the font.
| * | pango-view: Deserialize context tooMatthias Clasen2021-11-241-1/+1
| | | | | | | | | | | | | | | This lets us transfer things like base gravity from layout-editor to pango-view.
| * | More context serialization workMatthias Clasen2021-11-242-5/+63
| | |
| * | serializer: CosmeticsMatthias Clasen2021-11-241-11/+16
| | | | | | | | | | | | Avoid writing out empty attributes or tabs.
| * | Allow serializing context informationMatthias Clasen2021-11-243-10/+179
| | | | | | | | | | | | | | | | | | | | | | | | | | | Optionally include context information in the serialization and restore it. This will be useful for transporting for giving tests complete data that affects their output. Some tests included.
| * | Add flags to serialize and deserializeMatthias Clasen2021-11-245-21/+59
| | | | | | | | | | | | | | | | | | | | | This gives us some room to add more things to these apis, e.g. a way to store not just the input part of a layout, but also the output.
| * | Refactor enum serialization error handlingMatthias Clasen2021-11-241-54/+68
| | |
| * | Rename the serialize errorsMatthias Clasen2021-11-243-36/+54
| | | | | | | | | | | | | | | They are produced by deserialization, so call them that.
| * | CosmeticsMatthias Clasen2021-11-241-3/+3
| | |
| * | Fix visible space handlingMatthias Clasen2021-11-241-3/+5
|/ / | | | | | | | | Make space actually show up as visible space when we want that.
* | Merge branch 'line-breaking-fixes4' into 'main'Matthias Clasen2021-11-2318-33/+124
|\ \ | |/ |/| | | | | Fix a case of unintended hyphenation See merge request GNOME/pango!519
| * Fix handling of extra widthline-breaking-fixes4Matthias Clasen2021-11-221-5/+23
| | | | | | | | | | | | | | When handling items that fix completely, we were not consistently taking extra width into account, leading to hyphens sticking out in some cases.
| * break: Fix hyphen conditionMatthias Clasen2021-11-2210-27/+32
| | | | | | | | | | | | | | When looking at scripts, we want to look at the script of the *previous* character. And then we need to exclude SHY from the common script.
| * Fix a case of unintended hyphenationMatthias Clasen2021-11-223-1/+55
| | | | | | | | | | | | | | | | | | | | | | | | | | When we take a complete item because there are no breakpoints, we were inserting a hyphen at the end even though there may not be a breakpoint there, and ending up with a hyphen in the middle of an (overlong) line: Brat-wurst. Test included. This but was discovered with the help of http://gitlab.gnome.org/matthiasc/layout-editor
| * Add more autoptr definitionsMatthias Clasen2021-11-225-0/+14
|/
* Merge branch 'matthiasc/for-main' into 'main'Matthias Clasen2021-11-206-6/+30
|\ | | | | | | | | | | | | Don't replace | with hyphens Closes #630 See merge request GNOME/pango!516
| * ci: Allow the win32 render run to failMatthias Clasen2021-11-192-2/+2
| | | | | | | | | | | | I don't know why it started to fail, and am not in a position to debug it. So, let it fail, like we already do with the testsuite :(
| * Make summary work with meson 0.55Matthias Clasen2021-11-191-1/+1
| | | | | | | | That is what we have in ci.
| * build: Add a summaryMatthias Clasen2021-11-191-0/+25
| | | | | | | | | | I hope this will give some insight into what is happening in ci builds.
| * Don't replace | with hyphensMatthias Clasen2021-11-193-4/+3
|/ | | | | | | | | | | I went a bit overboard in #603. The vertical bar is too common, and this usage to specialized to do it by default. To enable this, we should rather make log attrs tweakable. We still replace hyphenation points with hyphens. Fixes: #630