summaryrefslogtreecommitdiff
path: root/pango
Commit message (Collapse)AuthorAgeFilesLines
* Fix a g_ascii_formatd callfix-asciid-callMatthias Clasen2022-01-181-1/+1
| | | | | | | | | | | We were passing a format specifier that starts with ' ', which some implementations of that API don't like. This change removes an extraneous space from the output. Update affected tests. Fixes: #659
* Check for fontmapsno-fontmap-no-funMatthias Clasen2022-01-141-0/+2
| | | | | | | To avoid trivialities, check that our context has a fontmap, at a strategic place. Fixes: #658
* docs: Fix a typoMatthias Clasen2022-01-141-3/+3
|
* Deprecate pango_coverage_ref/unrefdeprecate-coverage-refMatthias Clasen2022-01-102-3/+7
| | | | These are just wrappers of g_object_ref/unref.
* Drop uses of pango_coverage_ref/unrefMatthias Clasen2022-01-107-13/+13
| | | | Just use g_object_ref/unref.
* Add version macros for 1.52Matthias Clasen2022-01-101-0/+24
|
* fonts: Fix get_face default implMatthias Clasen2022-01-101-1/+1
|
* Add a default implementation for list_facesMatthias Clasen2022-01-101-0/+13
|
* Merge branch 'attrlist-splice' into 'main'Matthias Clasen2022-01-101-3/+17
|\ | | | | | | | | | | | | Clarify pango_attr_list_splice docs Closes #653 See merge request GNOME/pango!574
| * Reinstate previous behavior or pango_attr_list_spliceattrlist-spliceMatthias Clasen2022-01-071-3/+17
| | | | | | | | | | | | | | | | | | | | If gap is zero, don't limit the inserted attributes; that does not make sense. Spell out the different use cases in the docs. Testcase included. Fixes: #653
| * Clarify pango_attr_list_splice docsMatthias Clasen2022-01-071-1/+1
| | | | | | | | | | Make it explicit that the spliced-in attributes are limited to the the 'gap'.
* | g-i: add since annotations to enum membersbilelmoussaoui/giBilal Elmoussaoui2022-01-082-14/+8
|/
* Avoid an uninitialized variable warningMatthias Clasen2022-01-061-1/+4
| | | | Fixes: #650
* serializer: Serialize non-ASCII correctly if char is unsignedSimon McVittie2022-01-041-1/+1
| | | | | | | | | | | | | If char is unsigned, the first byte of a non-trivial UTF-8 sequence will be 0x80 or higher, instead of being negative. In this case we need to process it as UTF-8, instead of printing only the first byte and then skipping to the next UTF-8 character. char is usually signed on x86 and some other architectures, but not on the ARM or PowerPC families, among others. Resolves: https://gitlab.gnome.org/GNOME/pango/-/issues/652 Signed-off-by: Simon McVittie <smcv@debian.org>
* layout: Make sloped carets work betterMatthias Clasen2022-01-031-1/+4
| | | | | | | | When the font matrix has uneven scales, we need to factor that into the slope that we get from the font metrics. Tested with a condensed italic Cantarell.
* Merge branch 'matthiasc/for-main' into 'main'Matthias Clasen2022-01-021-0/+1
|\ | | | | | | | | Add a test for letterspacing See merge request GNOME/pango!570
| * Turn off hlig too when letterspacingMatthias Clasen2022-01-021-0/+1
| | | | | | | | Just for completeness.
* | Pass synthetic slant to harfbuzzsynthetic-slantMatthias Clasen2022-01-021-2/+10
| | | | | | | | | | | | | | | | | | | | | | | | When our font matrix includes a slant, pass that information to HarfBuzz, so it can adjust its mark positioning, metrics like caret slope, etc. This commit corrects the code that pulls the font matrix out of fontconfig to properly take the flipped y axis between fontconfig and pango into account. Requires new api in HarfBuzz > 3.2
* | Add pango_matrix_get_slant_ratioMatthias Clasen2022-01-022-0/+36
|/ | | | | Add API to extract the slant ratio from a PangoMatrix. Tests included.
* font: Documentation additions and clarificationsMatthias Clasen2022-01-011-3/+9
| | | | | Face names are not actually guaranteed to be unique, so don't say that.
* fontmap: Improve docs slightlyMatthias Clasen2022-01-011-0/+5
| | | | Mention GListModel.
* CosmeticsMatthias Clasen2022-01-011-1/+1
|
* itemize: Try harder to avoid NULL fontsMatthias Clasen2021-12-251-3/+5
| | | | | Always fall back to the base font if the fontset has no coverage.
* tracing: Fix the definesMatthias Clasen2021-12-252-8/+20
| | | | | | | | We want to define pango_trace_mark to nothing. This reveals that we've never compiled these calls out before, and there are some warnings to be fixed in that case.
* Install pango-fontset-simple.hMatthias Clasen2021-12-251-0/+1
|
* fontsetsimple: Make privately accessiblefontset-cosmeticsMatthias Clasen2021-12-242-14/+45
| | | | This will be used in the future
* Drop pango-fontset-private.hMatthias Clasen2021-12-249-43/+8
| | | | This was just an empty header.
* fontsetsimple: Simplify coverage handlingMatthias Clasen2021-12-231-55/+17
| | | | | | This functionality is basically unused. Lets not keep an array of coverages around for it.
* Split off PangoFontsetSimpleMatthias Clasen2021-12-236-291/+354
| | | | Put PangoFontsetSimple into its own files.
* Make missing space smallersmaller-spaceMatthias Clasen2021-12-221-1/+1
| | | | | | | The Microsoft paper I was citing actually recommends 1/4 em for ASCII space. Make it so... Update affected tests.
* Use a better size for missing spaceMatthias Clasen2021-12-211-39/+4
| | | | | | | | | | Follow the Microsoft Typography recommendations from https://docs.microsoft.com/en-us/typography/develop/character-design-standards/whitespace and use half of an em for missing space. Update affected tests. Fixes: #647
* fc: Implement get_absolute_sizeMatthias Clasen2021-12-211-0/+14
| | | | No surprises here.
* Add a private api to get the font sizeMatthias Clasen2021-12-212-1/+21
| | | | | | | | Add a private vfunc to get the (absolute) size of a font. This default implementation just pulls it out of the font description, but we can do implement this cheaper without copying the font description.
* CosmeticsMatthias Clasen2021-12-191-9/+10
| | | | | Rename some variables, so we actually know what these matrices are.
* Fix line height with emulated small capsfix-small-caps-line-heightMatthias Clasen2021-12-194-14/+40
| | | | | | | | When we change font scale for emulating small caps, keep the original font around in the analysis, and use it for calculating the run height. Fixes: #622
* Add some private apiMatthias Clasen2021-12-192-0/+63
| | | | | | Add some api to let us store another font in a PangoAnalysis. This will be used in the following commits.
* Improve line width accountingMatthias Clasen2021-12-181-1/+1
| | | | | | | We want to avoid trading chars for hyphens in the margin beyond the set width. Fixes: #646
* layout: Fix a cornercase of line width accountingMatthias Clasen2021-12-181-8/+12
| | | | | We don't collapse space at the very end, so we should count such spaces towards the line width.
* serializer: Fix a typoMatthias Clasen2021-12-181-1/+1
| | | | | | Oops, we were not serializing the height at all. Update all affected tests.
* Add some docsMatthias Clasen2021-12-181-0/+25
| | | | Add doc comments for some private API.
* fc: CleanupMatthias Clasen2021-12-183-3/+3
| | | | | | Stop using fcfont->matrix. This is just a redundant copy of the matrix that is already available in the font key. Just use that.
* cairo: Work harder to measure spacemore-space-tweaksMatthias Clasen2021-12-171-3/+21
| | | | | | | | | | | When coming up with a width for a missing space, we were just measuring the hex digits. But in subsetted fonts, such as the ones we use for ci, hex digits might well be missing. Take that into account and still provide some nonzero width for space. Update affected tests.
* shape: More tweaks to space handlingMatthias Clasen2021-12-171-4/+16
| | | | | | | | | | | | | | It is a difficult dance between HarfBuzz and pango which glyphs we let hb synthesize, and which ones we need to fake ourselves. HarfBuzz knows how to create other spaces from 0x20, so if the font is lacking spaces, we want to tell HarfBuzz that we don't have that glyph *except* for 0x20 where we need to fake one, and provide HarfBuzz with a suitable width. Update affected tests.
* Revert "Fix advance widths with transforms"fix-vertical-regressionMatthias Clasen2021-12-171-16/+29
| | | | | | | | | This reverts commit ccb651dd2a876a4f4a4cb9351f05332173e709ba. This broke vertical text rendering, see https://gitlab.com/inkscape/inkscape/-/issues/2950. Update affected tests and add a vertical test.
* Merge branch 'fix-spaceless-fonts' into 'main'Matthias Clasen2021-12-161-1/+9
|\ | | | | | | | | | | | | Fix handling of space-less fonts Closes #641 See merge request GNOME/pango!552
| * Fix handling of space-less fontsfix-spaceless-fontsMatthias Clasen2021-12-161-1/+9
| | | | | | | | | | | | | | | | | | | | | | HarfBuzz knows how to synthesize spaces, we just need to tickle it in the right way. Test included. Update affected tests. Fixes: #641
* | Merge branch 'arabic-format' into 'main'Matthias Clasen2021-12-161-18/+22
|\ \ | |/ | | | | | | | | | | Fix Arabic format chars Closes #642 See merge request GNOME/pango!553
| * Fix Arabic format charsMatthias Clasen2021-12-161-18/+22
| | | | | | | | | | | | | | We can't treat these like spaces, since they are visible and need the proper font. Fixes: #642
* | Add a missing includemissing-includeMatthias Clasen2021-12-161-0/+1
|/ | | | | | This was breaking the build on some macOs versions. Fixes: #640
* pango-item-private.h: fix x86-64 x32 buildsAlexander Kanavin2021-12-131-1/+1
| | | | Fixes: #637