Age | Commit message (Collapse) | Author |
|
Only use the PDF font metrics for stretched substitute fonts, in all
other cases, trust the embedded font file instead.
|
|
|
|
Only use the PDF character widths when also stretching glyphs to match
the PDF metrics.
|
|
|
|
Drop the unused 'serif' argument to the CJK lookup functions.
Use the BCP 47 names for CJK scripts and languages:
zh-Hant for traditional Chinese,
zh-Hans for simplified Chinese,
ja for Japanese,
ko for Korean.
The lookup function also allows commonly used language+country codes:
zh-TW and zh-HK for traditional Chinese,
zh-CN for simplified Chinese.
|
|
This was used to prevent infinite cycles in the Type3 font CharProcs,
but the previous commits forbids all cycles in order to prevent memory
leaks due to cyclic reference counts.
|
|
|
|
|
|
Several things irk me about passing values as const pointers:
* They can be NULL, which is not a valid value.
* They require explicit temporary variables for storage.
* They don't compose easily in a legible manner, requiring
weird pointer passing semantics where the variable being assigned
is hidden as an argument in the innermost function call.
* We can't change the value through the pointer, requiring yet more
local variables to hold copies of the input value.
In the device interface where we pass a matrix to a function, we often
find ourselves making a local copy of the matrix so we can concatenate
other transforms to it. This copying is a lot of unnecessary busywork
that I hope to eventually avoid by laying the groundwork with this
commit.
This is a rather large API change, so I apologize for the inconvenience,
but I hope the end result and gain in legibility will be worth the pain.
|
|
|
|
Do not cache PDF fonts, since they have custom metrics and encodings that
cannot be shared. This is primarily to speed up font loading for EPUB, PDF
appearance synthesis, and any other uses of default metrics and unicode
encoded fonts.
|
|
The Noto symbol font has been split into two. The second symbol font only
contains a subset of the emojis, so reinstate the real emoji font and add
both symbol fonts to the fallback chain.
|
|
Import Source Han Serif 1.001.
Use serif fonts in preference for sans.
|
|
Return TTC subfont index from fz_lookup_noto_font.
|
|
|
|
|
|
Force the face_flags to include TRICKY if we detect a DynaLab font
name instead of trying to force hinting ourselves.
|
|
Don't create a useless pdf_font_desc when writing font resources.
Simplify reference counting by using fewer intermediate variables.
|
|
|
|
|
|
We were previously using the font's family as its name. Now if only one
of family and style are defined we use that. If both are present we
concatenate family and style with an intervening space, unless style
already has family as a prefix, in which case we just use the style.
Better would be to use the font's full name, but that is more difficult
to obtain via the freetype API.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
* Use pool allocator and linked lists for all levels.
* Remove separate fz_stext_sheet struct.
* Remove unused 'script' style.
* Remove 'span' level items.
* Detect visual/logical RTL layouts.
* Detect indented paragraphs.
|
|
|
|
Update separations interface further to cope with whether spots
should be rendered separately, or as composite colors.
|
|
|
|
We still use the fz_context versions as the default, but these
can be overridden with draw device options.
|
|
|
|
This is very common and not a problem. Let's keep warnings
for problematic things, and not use them for informational
messages such as these.
|
|
|
|
Fix for bug 697943.
Set the initial replacement font bbox to the empty rectangle for type3 fonts,
and let the type3 glyph loading initialize by taking the union of all glyph
bboxes.
Set the replacement font bbox for non-Type3 fonts to the unit rectangle.
Also remove unused flag from fz_font struct.
|
|
|
|
It's not used, so prone to bit rot. Better to purge it.
|
|
|
|
|
|
|
|
Rename fz_write to fz_write_data.
Rename fz_write_buffer_* and fz_buffer_printf to fz_append_*.
Be consistent in naming:
fz_write_* calls write to fz_output.
fz_append_* calls append to fz_buffer.
Update documentation.
|
|
|
|
|
|
|
|
Move the definition of the structure contents into new fitz-imp.h
file. Make all code outside of fitz access the buffer through the
defined API.
Add a convenience API for people that want to get buffers as
null terminated C strings.
|
|
Ideographic and full-width punctuation inherit the script from the
surroundings, like all other punctuation. This does not play well
with our fallback font lookups.
Add special cases for ideographic and fullwidth unicode blocks.
|
|
tests_private/pdf/sumatra/1297_-_interpolate_at_lower_resolutions.pdf
times out in the cluster.
This is due to us having empty t3 glyphs defined that define d1
rectangles that are wildly different to the default font bbox.
Add code to spot that t3 glyphs are empty, and to use a tiny font
bbox for them.
(It might be nicer to drop the empty display lists, but then this
produces knock on problems further on, where non-existent display
lists lead to NULL pixmaps, which lead to us think that renders
failed etc).
|
|
|
|
As fz_drop_*()/fz_free() all must handle NULL.
|