summaryrefslogtreecommitdiff
path: root/tests
Commit message (Collapse)AuthorAgeFilesLines
* Add pango_tab_array_to/from_stringserialize-attrs-and-tabsMatthias Clasen2021-11-171-0/+48
|
* Use serialization api in testattributesMatthias Clasen2021-11-173-552/+337
|
* tests: Reuse attribute serialization codeMatthias Clasen2021-11-1740-353/+309
| | | | Update affected test outputs.
* Add pango_attr_list_to/from_stringMatthias Clasen2021-11-172-0/+87
| | | | | | Add an api to serialize PangoAttrList. This will be useful in testing and debugging.
* ci: Don't run testrandom on macOsMatthias Clasen2021-11-161-1/+6
| | | | | It fails there (although it shouldn't), and I don't have the means to debug it.
* CosmeticsMatthias Clasen2021-11-161-1/+1
|
* Another small leak fixMatthias Clasen2021-11-161-0/+1
|
* Fix a small memleakMatthias Clasen2021-11-161-1/+3
| | | | | Our asan ci is unforgiving, and point out every memory leak.
* tests: Add spiced up wrapping testsBenjamin Otte2021-11-152-1/+320
| | | | | | | | | | | | | | | | | | * Generate random string that looks like a sentence. * Measure the size at 100 random widths. * assert that for those widths, when sorted, the measured widths are increasing and the heights are decreasing. * Generate random string that looks like a sentence. * Generate a 2nd string adding hyphen + newline after every char of original string. * Assert that wrap-char wrap with width=0 is not larger than the width of the 2nd string The tests also generate random strings in LTR, RTL or both at the same time to spice the test up even more. It does that by picking random words out of hunspell directories, and if none are installed, it falls back to lorem ipsum.
* Update affected testsline-breaking-fixes3Matthias Clasen2021-11-151-6/+6
| | | | Some of the layout tests now get better line breaks.
* Skip the test on macOSfix-itemize-crashMatthias Clasen2021-11-131-0/+6
|
* Fix a bug in Small Caps handlingMatthias Clasen2021-11-131-0/+24
| | | | | | | | | We were not passing the correct split_offset to pango_item_split(). Testcase included. Fixes: #627
* Update affected testsfix-hyphen-widthMatthias Clasen2021-11-102-8/+8
|
* Add a test for layout widthMatthias Clasen2021-11-101-0/+26
| | | | This checks behavior that is required by GTK.
* Add variant roundtrip testsMatthias Clasen2021-11-071-4/+42
| | | | | | Test some more tests for roundtripping casing variants from font description to font and back.
* Add a test for small capsMatthias Clasen2021-11-051-0/+41
| | | | | | | Add a test that verifies that PANGO_VARIANT_SMALL_CAPS survives a roundtrip from font description to font and back, and that it shows up in the font as smcp=1 in the OpenType features.
* Skip a failing test on macOSMatthias Clasen2021-11-021-0/+18
| | | | | I can't debug this using just the ci runner, so skip it until somebody can.
* Add tests for matrix transformationsMatthias Clasen2021-10-311-0/+39
|
* Revert "Disable failing line height tests"Matthias Clasen2021-10-301-9/+5
| | | | This reverts commit 7a4af7a052e7e4187955aad9c4c60853bad806f9.
* Add tests for glyph extentsMatthias Clasen2021-10-301-0/+42
|
* Disable failing line height testsgravity-metrics-fixMatthias Clasen2021-10-271-5/+9
| | | | | These need to wait until 20ec670e124e4461075 can be reapplied.
* Support for Catalan middle dot in word start and endJordi Mas2021-10-272-0/+10
|
* Merge branch 'empty-line-height-attr-fix' into 'main'Matthias Clasen2021-10-201-0/+174
|\ | | | | | | | | | | | | Fix empty line heights Closes #421 See merge request GNOME/pango!481
| * Add more line height testsempty-line-height-attr-fixMatthias Clasen2021-10-191-0/+133
| |
| * pangocairo: Round font metrics when appropriateMatthias Clasen2021-10-191-0/+41
| | | | | | | | | | | | | | | | | | | | | | When metrics hinting is on, we used to provide rounded font metrics. We should keep doing that since otherwise we end up with logical rects sometimes being rounded and sometimes not, leading to jumping empty lines. Test included. Fixes: #421
* | Update Unicode test cases to Unicode 14Peng Wu2021-10-203-9/+9
| |
* | Update Line Break to Unicode 14Peng Wu2021-10-121-1/+1
|/
* Be more forgiving about attribute orderingMatthias Clasen2021-09-012-0/+113
| | | | | | | | | | | | We don't really have firm control over the way attributes are ordered in the list, so the assumtion that we see proper nesting for baseline shifts was a bit optimistic. Just look through all open stack items for a match, and remove that. Test included.
* Merge branch 'baseline-shift' into 'main'Matthias Clasen2021-09-013-179/+21
|\ | | | | | | | | Implement baseline shifts See merge request GNOME/pango!462
| * test-layout: Add a --show-fonts optionbaseline-shiftMatthias Clasen2021-08-311-0/+15
| | | | | | | | A bit more natural than the environment variable.
| * test-layout: Disable fragile checksMatthias Clasen2021-08-311-175/+0
| | | | | | | | | | | | | | I added these for improved coverage, but they get in the way, Should probably just move these kind of checks to another place and leave this test focused on dumps.
| * markup: Change <sup> and <sub>Matthias Clasen2021-08-311-4/+4
| | | | | | | | | | | | | | | | Use the new baseline-shift and font-scale attributes to reimplement <sup> and <sub>. Now they take font metrics into account and nest properly.
| * Implement font-dependent scalingMatthias Clasen2021-08-311-0/+1
| | | | | | | | | | | | | | Add a new font-scale attribute to indicate font size changes due to super- and subscript shifts, and handle it during item post-processing to find the right font sizes.
| * Implement baseline shiftsMatthias Clasen2021-08-311-0/+1
| | | | | | | | | | | | | | | | | | | | | | Add a new baseline-shift attribute, which is similar to rise, but accumulates. In addition, it supports font- relative values such as superscript and subscript. We implement support for this by computing baseline shifts for run during line post-processing, and storing them in the runs. The renderer now takes these shifts into account when rendering layout lines.
* | test-shape: Show color glyph informationcolor-glyphMatthias Clasen2021-09-011-2/+11
|/
* tests: Test font roundtrips on MacOscoretext-font-describeMatthias Clasen2021-08-311-12/+5
| | | | | | We were skipping the test that would have found the brokenness in the previous fix. Lets see if we can get the test working on MacOs.
* test-break: Fix legend formattingMatthias Clasen2021-08-301-1/+1
|
* test-break: Add a --hex-chars optionMatthias Clasen2021-08-301-27/+44
|
* test-shape: Print out glyph classesMatthias Clasen2021-08-291-2/+31
| | | | | | These are not very reliable for things other than marks, but even that is useful for debugging cluster handling.
* test-itemize: Keep in sync with PangoLayoutMatthias Clasen2021-08-292-10/+11
| | | | | | This really needs some more generic treatment. Update affected test outputs.
* tests: Use introspection for attributesMatthias Clasen2021-08-291-64/+37
| | | | | | Now that we have introspection helpers for attributes, we can use them ourselves to make this code less brittle.
* test-itemize: Print more informationMatthias Clasen2021-08-283-1/+19
| | | | | | | Print out the items num_chars and char_offset, so we can check that the char_offset implementation works. Update affected test outputs.
* test-itemize: Improve generationMatthias Clasen2021-08-281-3/+3
| | | | | | | | | It is very annoying that gtest will dump its random seed into the output as soon as one calls g_test_init(). This pollutes our generated output. Work around that by deferring the g_test_init() call until after we've dealt with generating output.
* tests: Only print known analysis flagsMatthias Clasen2021-08-281-1/+5
| | | | We're going to steal one bit for private purposes.
* test-shape: Show cluster boundaries correctlyMatthias Clasen2021-08-271-11/+12
| | | | | | Cluster boundaries were cutting off the first character of a new cluster. Not great if the tools print out misleading information.
* test-shape: Add an option for hex charsMatthias Clasen2021-08-271-1/+20
| | | | | This is useful when trying to understand the output for scripts I don't read.
* More break testsmore-log-attr-thingsMatthias Clasen2021-08-266-0/+25
|
* Add code to validate log attrsMatthias Clasen2021-08-264-1/+587
| | | | | | This is just used in tests for now. If we decide to make an external log attr api, we can make this public.
* break: Fix up word fixupsMatthias Clasen2021-08-261-7/+7
| | | | | | | We were not correctly handling overlapping segments in all cases, with <span segment='word'>. Improve this. Update affected tests.
* break: Follow mandatory rules more strictlyMatthias Clasen2021-08-2613-91/+91
| | | | | | | | We were not putting a line break at the end of the text, in cases where a paragraph ends with a newline. Enforce this in all break apis. Update affected tests.