Age | Commit message (Collapse) | Author |
|
The dash parameters where not copied; the copy
could point at random data and cause corpus
tests to hang when testing Skia.
PDFium measures text directly by calling FreeType.
Turn off hinting altogether in Skia so that drawn
text matches the metrics that PDFium measures.
Premultiply bits retrieved from images, and check
to see that the device bits are always
premultiplied.
Look for null graphics state and matrices.
R=thestig@chromium.org,dsinclair@chromium.org
BUG=pdfium:532
Review-Url: https://codereview.chromium.org/2120353004
|
|
Review-Url: https://codereview.chromium.org/2075383002
|
|
Fix nits along the way.
Review-Url: https://codereview.chromium.org/2083943003
|
|
Move ifx_renderdevicedriver class to its own file to share with
multiple devices to reduce code duplication.
Review-Url: https://codereview.chromium.org/2078783002
|
|
These changes are specific to Mac and Skia builds. They are
needed for these builds to compile with clang_use_chrome_plugin.
BUG=pdfium:469
Review-Url: https://codereview.chromium.org/2081523002
|
|
Review-Url: https://codereview.chromium.org/2077243002
|
|
- Clean up CFX_GEModule.
- Remove duplicate #defines in fx_ge.h
- Remove IsFontStyleFromCharCode() that always returns true.
- Mark a FXTEXT_CHARPOS field as Mac only.
Review-Url: https://codereview.chromium.org/2075333002
|
|
This change contains files in core directory which were not covered
in part I. This is part of the efforts to make PDFium code compilable
by Clang chromium style plugins.
The changes are mainly the following:
-- move inline constructor/destructor of complex class/struct out-of-line;
-- add constructor/destructor of complex class/struct if not
explicitly defined;
-- add explicit out-of-line copy constructor when needed;
-- move inline virtual functions out-of-line;
-- Properly mark virtual functions with 'override';
-- some minor cleanups;
BUG=pdfium:469
Review-Url: https://codereview.chromium.org/2060913003
|
|
Review-Url: https://codereview.chromium.org/2059883004
|
|
Make the return types/arguments match reality.
Review-Url: https://codereview.chromium.org/2053483002
|
|
Review-Url: https://codereview.chromium.org/2032613003
|
|
CFX_PSRenderer, IFX_PSOutput, CPSOutput, CPSPrinterDriver.
Also reland commit 2d63eaa.
Review-Url: https://codereview.chromium.org/2019603002
|
|
This code has several disadvantages over a more modern graphics engine:
- no SIMD support
- no GPU support
- limited quality
Further, calling this code locks in the perceived resolution, so that
the output cannot be scaled without additional loss.
By directing all bitmap drawing through
CFX_SkiaDeviceDriver::StartDIBits, Skia can handle all appropriate
bitmap optimizations.
To that end, SetDIBits and StretchDIBits now call StartDIBits.
Other changes:
Skia's bitmaps are premultiplied. PDF contains bitmaps that are
unpremultiplied. PDFium appears to use premultiplied bitmaps sometimes,
and unpremultiplied bitmaps elsewhere. Add a debug check for
unpremultiplied bits in Skia's driver, and add a utility to premultiply
PDFium's bitmaps' bits.
PDFium supports a 24 bit RGB bitmap padded to a 32 bit word. Set the
high byte so that Skia can treat this as an ARGB bitmap.
Defer the application of the alpha value to the draw call rather than
calling MultiplyAlpha where possible.
Allow the destination bitmap to be alpha 8 or argb 32.
Review-Url: https://codereview.chromium.org/2025043002
|
|
So everyone can avoid doing Byte to WideString conversions.
Also remove CFX_GEFont::GetPsName() and deduplicate a couple of
GetPsName() calls.
Review-Url: https://codereview.chromium.org/2019173002
|
|
Review-Url: https://codereview.chromium.org/2004313007
|
|
Remove unused dithering code.
Review-Url: https://codereview.chromium.org/2010813003
|
|
Review-Url: https://codereview.chromium.org/2011943004
|
|
Review-Url: https://codereview.chromium.org/2009803003
|
|
Review-Url: https://codereview.chromium.org/2009253003
|
|
Review-Url: https://codereview.chromium.org/2017503002
|
|
Review-Url: https://codereview.chromium.org/1990583002
|
|
Some Freetype implementations (like the one packaged with Fedora) do
not support hinting due to patents 6219025, 6239783, 6307566, 6225973,
6243070, 6393145, 6421054, 6282327, and 6624828; the latest one expires
10/7/19. This makes LCD antialiasing very ugly, so we instead fall back
on NORMAL antialiasing.
A before/after on Fedora: https://bugs.chromium.org/p/chromium/issues/detail?id=479400#c31
BUG=479400
Review-Url: https://codereview.chromium.org/1982263004
|
|
Add missing helper function to CFX_ByteTextBuf to avoid the
anti-pattern CFX_ByteString(sBuf.AsStringC()), using the name
"Make" to indicate there's an allocation going on in this case.
Change some method arguments to take pre-existing ByteStrings where
possible.
Review-Url: https://codereview.chromium.org/1977093002
|
|
PDFium uses fxge to denote the graphics engine used
for general rendering. When pdf_use_skia=1 is set,
use Skia as the default engine instead of antigrain.
R=tsepez@chromium.org,dsinclair@chromium.org
Review-Url: https://codereview.chromium.org/1975143002
|
|
Review-Url: https://codereview.chromium.org/1973913002
|
|
Review-Url: https://codereview.chromium.org/1968273002
|
|
This CL removes the IFPF_DeviceModule, IFPF_FontMgr and IFPF_Font interfaces
in favour of their concrete classes.
BUG=pdfium:467
Review URL: https://codereview.chromium.org/1881043004
|
|
This CL removes IFX_ArabicChar, IFX_RTFBreak, IFX_TxtBreak, IFX_WordBreak,
IFX_FormatString, and IFX_GSUBTable. References were updated to be the concrete
classes.
The CFX_GSUBTable was also removed as it is unused.
BUG=pdfium:468
Review URL: https://codereview.chromium.org/1882213002
|
|
This Cl removes the two interfaces and renames CFDE_SolidBrush to CFDE_Brush.
Uncalled methods are removed from both CFDE_Brush and CFDE_Pen and code
simplified to match.
BUG=pdfium:468
Review URL: https://codereview.chromium.org/1881803003
|
|
Attempting to open bug_434.pdf on my Linux box would fail with:
../../xfa/fxfa/app/xfa_fwltheme.cpp:96: virtual FWL_ERR
CXFA_FWLTheme::Initialize(): Assertion `__null != m_pCalendarFont' failed.
I tracked the regression back to [1].
The issue seems to be in CFX_FontManager::AddInstalledFont we will only add
one font for a given Charset. In my case I end up loading 6 charsets, but the
fonts are all strange ones. When I open the PDF, it fails to find 'Arial'
because I've registered these other fonts.
To fix this I changed the m_FaceArray into a struct of {name, chraset}. Then
we record all fonts into this list and search over that list for the charset
when needed. This allows bug_434.pdf to open and the test to pass successfully.
1- https://pdfium.googlesource.com/pdfium/+/fe73e7849b8b4ce49408d2f52f3fc29b370b82b5
Review URL: https://codereview.chromium.org/1874433002
|
|
Using these webpages as guides
http://www.globelegislators.org/pdfjs/test/pdfs/alphatrans.pdf
http://www.antennahouse.com/antenna1/wp-content/uploads/2015/07/background-image-gradient-1.pdf
flesh out the gradient shaders to include the PostScript Type 0
sampling function and to include radial gradients. This CL makes
rendering these pages agree with Adobe Reader output.
Some of these examples use an Extend array to clip the gradient.
Skia does not currently support this natively, so construct the
clip manually for now.
Other PDF pages may construct gradients using alternate mechanisms
-- this code will continue to be refactored as those come to light.
In particular, this CL sets up the clip and matrix differently for
axial gradients and radial gradients -- while it makes sense to do
it one way only, I prefer to defer until I have more examples to
work with.
R=dsinclair@chromium.org,tsepez@chromium.org
Review URL: https://codereview.chromium.org/1870463002
|
|
Neither are implemented. Removed.
BUG=pdfium:468
Review URL: https://codereview.chromium.org/1872463002
|
|
Interface is never implemented.
BUG=pdfium:468
Review URL: https://codereview.chromium.org/1864893003
|
|
This CL is a straight move of the fxge includes into core/fxge/include.
Review URL: https://codereview.chromium.org/1868533002
|