Age | Commit message (Collapse) | Author |
|
|
|
For now, treat auto in margins as zero.
|
|
|
|
|
|
|
|
|
|
Move the two SVG utility functions into fitz/util.h
|
|
|
|
|
|
When we climb up the box tree to create a new block box for block-level
elements that are deep inside inline-level elements, we should propagate
this to the caller so it can also climb up. Otherwise other child
elements in the inline-level element will be inserted before the
block box that was created for the content that was shunted up the tree.
|
|
The bug was introduced in commit ad09b038 where we adjust the y coordinate
in draw calls instead of using the top level matrix so that high level
output devices get reasonable page coordinates for objects.
We forgot to adjust the y coordinate for images.
|
|
We used to bake in the page_top in all the y coordinates of all objects,
and use the top level matrix to subtract page_top.
If we subtract page_top from the y coordinates instead of using the
matrix to do it, we get smaller numbers in the device calls.
|
|
We accidentally used int for the page height when loading links, and in
the case where the page dimension is not an integer number of points that
would lead to rounding accumulation errors in the resulting bounding
boxes.
|
|
|
|
|
|
This was causing problems when laying out a document multiple times,
where old line breaks taken would be sticky.
|
|
|
|
Non-destructively zero terminate a fz_buffer for use as a C string.
|
|
|
|
|
|
|
|
|
|
We would not create a link box for the "bar" text in links of the form:
<a href="foo"><span>bar</span></a>.
|
|
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.
|
|
All seen in MSVC, mostly in 64bit builds.
|
|
|
|
Allows id anchoring to block elements as well as inline elements.
Fix for bug 697123.
|
|
All link destinations should be URIs, and a document specific function
can be called to resolve them to actual page numbers.
Outlines have cached page numbers as well as string URIs.
|
|
|
|
|
|
|
|
|
|
Fixes memory leaks when parsing throws exceptions and saves a lot of
tiny mallocs for objects that have common life times.
|
|
Removes the need to carry fz_pool along in all boxes.
|
|
|
|
Keep them as 'FLOW' entries rather than box entries. Although
they technically enclose areas of text, we only ever use them
as points.
Thanks to Tor for fixing this code.
|
|
Saves 12 bytes per fz_html, and we have a lot.
|
|
Saves 8 bytes on every css_style (and we have a lot of those).
|
|
|
|
|
|
Only create a text object if we are definitely going to use it,
and then take care of exceptions being thrown.
|
|
Thanks to Vlad Glagolev for the example file, analysis and
patch.
We had failed to initialise the "last break class" value, so that
when we use it as an index into an array, we run the risk of
crashing.
The fix is simply to initialise it. By initialising it to OP
we don't allow any softbreaks to be added when it's uninitialised,
which feels right to me.
|
|
The fz_font structure now doesn't know anything about
harfbuzz at all, it merely offers an abstract
'fz_shaper_data_t' entry.
|
|
Move the definition of fz_font to be in a private header file
rather than in the public API. Add accessors for specific
parts of the structure and use them as appropriate.
The font flags, and the harfbuzz records remain public.
This means that only 3 files now need access to the font
implementation (font.c, pdf-font.c and pdf-type3.c). This
may be able to be improved further in future.
|
|
|
|
This silences the many warnings we get when building for x64
in windows.
This does not address any of the warnings we get in thirdparty
libraries - in particular harfbuzz. These look (at a quick
glance) harmless though.
|
|
|
|
We store an hb_font in every font, and currently have fz_drop_font
know to call harfbuzz to destroy it. This causes harfbuzz to be
included even in builds that never use it.
We improve this situation by storing both an hb_font, and a
function pointer to destroy it within fz_font. This costs us
an extra pointer per fz_font, but solves the problem.
|
|
Don't try to load SVG images if SVG support is disabled.
|
|
|