summaryrefslogtreecommitdiff
path: root/pango
Commit message (Collapse)AuthorAgeFilesLines
* win32: Implement create_hb_fontChun-wei Fan2019-07-181-0/+85
| | | | | | | | | This renders correctly in ci. This attempts to acquire the hb_font_t from the HFont that we acquire from the Windows HFONT that we use, so that we can pass things to HarfBuzz, which will handle the shaping for us. win32: Set scale on hb font
* coretext: Implement create_hb_fontMatthias Clasen2019-07-181-0/+24
| | | | This has been tested and renders correctly.
* fc: Drop freetype from pangofc-font.hMatthias Clasen2019-07-186-12/+9
| | | | | Stop using FT_Face here, so we can stop including freetype headers.
* fc: Drop some gratitious use of FT typesMatthias Clasen2019-07-184-15/+3
|
* fc: Deprecate FT_Face gettersMatthias Clasen2019-07-182-2/+4
| | | | | We are moving away from a freetype dependency, so these will be going away at some point.
* fc: Use harfbuzz for glyph extentsMatthias Clasen2019-07-181-63/+28
| | | | Harfbuzz has the api, no need to use freetype.
* fc: Use harfbuzz for font metricsMatthias Clasen2019-07-181-111/+28
| | | | | | Note that some of the harfbuzz api we use here has not landed yet. See https://github.com/harfbuzz/harfbuzz/pull/1432
* fc: Drop the cmap cacheMatthias Clasen2019-07-183-78/+0
| | | | This is now unused.
* fc: Use harfbuzz for glyph lookupMatthias Clasen2019-07-181-42/+4
| | | | We don't need our own caching here.
* fc: Make pangofc_shape backend-neutralMatthias Clasen2019-07-181-44/+47
| | | | | Use typechecks for the two remaining bits of code that use PangoFcFont.
* fc: Make hb font immutableMatthias Clasen2019-07-181-0/+2
| | | | | | The frontend is caching this object, and we are giving it out to applications. We really can't allow them to modify it in any way.
* fc: Move font setup code from the shaperMatthias Clasen2019-07-183-332/+147
| | | | | | | | | | | | Move all the code that sets up the hb_font_t to pango_fc_font_create_hb_font, and use it from the shaper. This is the second step towards taking over font management. Even better, harfbuzz has a ready-made function for this. We can drop a lot of FT_Face-using code this way. We assume unhinted rendering for now, so we can set ppem to 0.
* fc: Implement create_hb_fontMatthias Clasen2019-07-183-1/+69
|
* Add api to get a hb_font_tMatthias Clasen2019-07-183-6/+49
| | | | | Add pango_font_get_hb_font, which will make it easier access harfbuzz features.
* coretext: Remove unused codeMatthias Clasen2019-07-181-24/+0
|
* Fix more compiler warningsMatthias Clasen2019-07-182-2/+2
| | | | These are clang warnings.
* Fix compiler warningsMatthias Clasen2019-07-184-5/+5
|
* OS X: Prevent recursion in get_metricsMatthias Clasen2019-07-181-14/+0
| | | | | create_base_metrics is not meant to fill in widths. That is done in _pango_cairo_font_get_metrics.
* OS X: build fixesMatthias Clasen2019-07-182-1/+4
|
* glyph iter: Adjust assertionsMatthias Clasen2019-07-171-2/+2
| | | | | | With the inserted hyphens we end up in a situation where we have start_char == end_char at the end of an item. It seems to be otherwise harmless.
* layout: Fix reshaping with hyphen runsMatthias Clasen2019-07-171-2/+15
| | | | | | When we are uninserting a hyphen run, we need to undo the modifications of the item we split it off from.
* layout: Correctly account for hyphen widthMatthias Clasen2019-07-171-8/+14
| | | | | | We were sometimes adding a hyphen width when the break we were taking did not actually require a hyphen, causing us to break prematurely.
* Fix a compiler warningMatthias Clasen2019-07-171-1/+0
|
* fc: Return a coverage levelMatthias Clasen2019-07-171-1/+3
| | | | | We were just returning a boolean, leaving it up to luck to match coverage level enum values.
* Fix no-break attribute filteringMatthias Clasen2019-07-171-1/+5
| | | | pango_attribute_equal does not compare ranges. Oops.
* Merge branch 'tailor-break' into 'master'Matthias Clasen2019-07-163-64/+106
|\ | | | | | | | | Tailor break See merge request GNOME/pango!86
| * Deprecate pango_breakMatthias Clasen2019-07-162-13/+10
| | | | | | | | | | To break correctly, use pango_default_break and pango_tailor_break.
| * layout: Tailor breaks properlyMatthias Clasen2019-07-161-35/+47
| | | | | | | | | | | | Call pango_default_break on the entire text, and then pango_tailor_break on segments with homogeneous language and script.
| * Add pango_tailor_breakMatthias Clasen2019-07-162-16/+49
| | | | | | | | | | | | This function lets you apply language-specific tailoring on top of breaks produced by pango_default_break.
* | cairo win32: Set height in font metricsMatthias Clasen2019-07-161-4/+3
| |
* | context: Treat metrics height like ascent+descentMatthias Clasen2019-07-161-0/+1
| | | | | | | | | | | | PangoContext has somewhat redundant code to create metrics, which wasn't treating the new height member like it should.
* | layout: Don't free no_break_attributes prematurelyMatthias Clasen2019-07-161-4/+4
|/ | | | | We use them in a loop. Don't free them before the loop is done.
* pangofc-font.c: Trivial fix on pre-C99 compilersChun-wei Fan2019-07-151-2/+2
| | | | Make sure we declare variables at the top of the block.
* layout: Avoid access-after-freeMatthias Clasen2019-07-151-2/+4
| | | | | insert_run (... TRUE) frees the need_hyphen array, so we need to check for the hyphen beforehand.
* layout: Improve soft hyphen handlingMatthias Clasen2019-07-141-1/+8
| | | | | | | | | | | Point the item that we create for the inserted hyphen at the SHY in the paragraph text, shortening the previous run by one character. It would be nicer to not insert an extra run at all and just reshape the previous one in a way that maps the SHY to a hyphen, but that is more difficult to do as long as we are going through the shape engine API.
* layout: Fix some offset-vs-index confusionMatthias Clasen2019-07-141-32/+54
| | | | | | | | | | | | | | | | | We had some sad cases where we used a char offset as a byte index, with the expected bad results once there are multibyte characters in the mix. Instead of poking at the text in the middle of line-breaking, go back to keeping a plain array of positions that need a hyphen inserted. We maintain this array in parallel to the existing log_widths array, so hopefully the offset math is working out now. It is tempting to look at log_attrs.is_white for this, but that gives us double hyphens when breaks are taken at explicit hyphens. So, keep this information separately.
* layout: Correct a field typeMatthias Clasen2019-07-141-1/+1
| | | | | We had a boolean member in ParaBreakState that was used as an int. Oops
* Some more doc tweaksMatthias Clasen2019-07-144-3/+14
|
* Clean up docs a bitMatthias Clasen2019-07-133-53/+15
| | | | Avoid duplicate comments in struct defintions.
* Add some more docsMatthias Clasen2019-07-132-1/+4
|
* Documentation tweaksMatthias Clasen2019-07-136-7/+172
|
* Deprecate pango_fc_font_has_charMatthias Clasen2019-07-122-3/+2
| | | | We have pango_font_has_char now.
* Rename pango_font_coversMatthias Clasen2019-07-124-9/+7
| | | | | We already had a has_char api in pangofc, so use that name.
* Revert "Reduce overlinking"Matthias Clasen2019-07-121-3/+5
| | | | This reverts commit f972ba0562823a8d55ad02ff9609481a884c79f8.
* Revert "Move pangofc to libpango"Matthias Clasen2019-07-121-22/+8
| | | | This reverts commit 8b85815f1b122842d915e7fc29cc68d228a64dbb.
* coverage: Fix the copy implementationMatthias Clasen2019-07-121-1/+10
| | | | This should do a deep copy.
* coverage: Fix the implementationMatthias Clasen2019-07-121-2/+8
| | | | We never created the set. Oops.
* Document pango_item_apply_attrsMatthias Clasen2019-07-121-0/+18
|
* docs: Fix parameter name mismatchesMatthias Clasen2019-07-122-4/+4
| | | | gtk-doc doesn't like these.
* ot: Avoid deprecated harfbuzz apiMatthias Clasen2019-07-121-4/+6
| | | | Don't use deprecated api to implement deprecated api!