Age | Commit message (Collapse) | Author |
|
Skia is moving to normalize on std::swap instead of its own SkTSwap.
This removes the use of SkTSwap from PDFium so that Skia can remove it.
Change-Id: If77708c1f363f4fd82a4c7905c7fbb2060900532
Reviewed-on: https://pdfium-review.googlesource.com/35470
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
ArgbEncode() does the same thing.
Change-Id: Ibb05ed4aae720c0a5ba66771699c0d7e11230921
Reviewed-on: https://pdfium-review.googlesource.com/32230
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
BUG=pdfium:234
Change-Id: I5c900aa0547afef0c60de35422b4ee489daa6cfb
Reviewed-on: https://pdfium-review.googlesource.com/32913
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: Id7bf252ebe25c92d26065d1138a445ebb2f78d0b
Reviewed-on: https://pdfium-review.googlesource.com/32187
Reviewed-by: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
Replace it with CFX_BitStream.
Change-Id: Ib74657f888b8dec8b6fdad7b49e28d250991c590
Reviewed-on: https://pdfium-review.googlesource.com/32852
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Rather than messing with actual inheritence, add type-checking wrappers
and just blatantly cast to incomplete types. Along the way, this points
out places where we would downcast without checking, which I fix.
Change-Id: Ieb303eb46ad8522dfe082454f1f10f247ffd52d5
Reviewed-on: https://pdfium-review.googlesource.com/32030
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
Get bounds checking "for free".
Change-Id: Ic60d63836f6c223e2ee1262649d47da54bb30ecc
Reviewed-on: https://pdfium-review.googlesource.com/30876
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
They currently take const FX_RECT*, but the pointer is never nullptr.
Also add a comment to explain why FX_RECT is the way it is. It has the
same layout as a win32 RECT.
Change-Id: Icf0e4c3eb25fe03317590a736578e053b9dccf7a
Reviewed-on: https://pdfium-review.googlesource.com/30051
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This CL renames fsdk_common and fsdk_define to cpdfsdk_common and
cpdfsdk_helpers respectively.
Change-Id: I8ee7a308561f1ff2f510954444f953b0c8fed788
Reviewed-on: https://pdfium-review.googlesource.com/29371
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL renames IFX classes in core/fxge to Iface.
Change-Id: I137167ddd4ff1563d8002d9501222c27183408cc
Reviewed-on: https://pdfium-review.googlesource.com/27990
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL renames the 3 IFX files in core/fxcrt to Iface instead.
Change-Id: I7cee6836650b71bc5c5729a8147fda62f0910fe3
Reviewed-on: https://pdfium-review.googlesource.com/27970
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I79c756153608a345f27c7ccac8009bf68512dba8
Reviewed-on: https://pdfium-review.googlesource.com/25790
Commit-Queue: Mike Reed <reed@google.com>
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Bug: 806612
Change-Id: I22bd9046dd37a1b596762c46a6b29a323d6e9fa1
Reviewed-on: https://pdfium-review.googlesource.com/24410
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
BUG=chromium:805881
Change-Id: I5f920649f425d0cfc47c780b36ed70f23cbe1299
Reviewed-on: https://pdfium-review.googlesource.com/24191
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I0a07dbc9850bef2184ed35ff04b08385fc1bdd17
Reviewed-on: https://pdfium-review.googlesource.com/22891
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
This CL removes friends from classes in fxge/.
Change-Id: I8180004de3ebf818ed4c8d5256a01c33cd2d880e
Reviewed-on: https://pdfium-review.googlesource.com/16170
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL moves the CFX_Font definition out of fx_font.h and into
cfx_font.h to match the cfx_font.cpp implementation.
Change-Id: Icc2fc7463fa4b9d0bec925e80b60a638136a83a1
Reviewed-on: https://pdfium-review.googlesource.com/14951
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This CL renames the FX_OS defines to have _OS_ in their names and drops
the _DESKTOP suffix. The FXM defines have been changed to just FX.
Change-Id: Iab172fba541713b5f6d14fb8098baf68e3364c74
Reviewed-on: https://pdfium-review.googlesource.com/14833
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL moves CFX_UnownedPtr to UnownedPtr and places in the fxcrt
namespace.
Bug: pdfium:898
Change-Id: I6d1fa463f365e5cb3aafa8c8a7a5f7eff62ed8e0
Reviewed-on: https://pdfium-review.googlesource.com/14620
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL renames CFX_RetainPtr to RetainPtr and places in the fxcrt
namespace.
Bug: pdfium:898
Change-Id: I8798a9f79cb0840d3f037e8d04937cedd742914e
Reviewed-on: https://pdfium-review.googlesource.com/14616
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I703321108712e8c4a11a8343ecf8b1a8804c1d1a
Reviewed-on: https://pdfium-review.googlesource.com/14352
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This CL removes the fx_basic.h header and fixes up includes as needed.
Change-Id: I49af32a8327bdbcda40c50a61ffbd75d06609040
Reviewed-on: https://pdfium-review.googlesource.com/12670
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
This CL moves IFX_Pause out to its own class from fx_basic and updates
includes as needed.
Change-Id: Iebdd183d8c85aa17570f190f1a7d1602c0af3c8b
Reviewed-on: https://pdfium-review.googlesource.com/12491
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Converted CFX_RenderDevice::DrawCosmeticLine() and IFX_RenderDeviceDriver::
DrawCosmeticLine() to take in CFX_PointF objects instead of two coordinates
per point.
Bug=pdfium:769
Change-Id: I6116e4106a61487184a71e79c1dca3a85e8c7c27
Reviewed-on: https://pdfium-review.googlesource.com/11410
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Most calls to the Skia Driver combine flushing
the draw cache with deleting the driver itself.
Progressive drawing needs to flush the cache to
keep drawing in order, but the driver must remain
for the next progressive draw.
R=dsinclair@chromium.org, hnakashima@chromium.org
Bug: pdfium:833
Change-Id: I311f80b2dc0ef6e4df9a3a0f082ae076cb7a591f
Reviewed-on: https://pdfium-review.googlesource.com/8890
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Bug:
Change-Id: Ic40d1fce83b6b13f638c522205a765c20f6ccd50
Reviewed-on: https://pdfium-review.googlesource.com/8090
Commit-Queue: Mike Reed <reed@google.com>
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
Reviewed-by: Cary Clark <caryclark@google.com>
|
|
PDFium's native code reverse engineers the glyph code on Mac
by taking the character code point, looking up its name in
FreeType, and then finding the named glyph's index from
CoreGraphics.
If the FreeType glyph index and the CoreGraphics index don't
match, it uses CoreGraphics' index when drawing.
The IDs match except when drawing an embedded Type 1 font tha
has been sparsely populated to cut down on the PDF size.
R=dsinclair@chromium.org
Bug: 738279
Change-Id: I16d993b611afe3b2481b36f886644524c9c351ef
Reviewed-on: https://pdfium-review.googlesource.com/7650
Reviewed-by: Nicolás Peña <npm@chromium.org>
Commit-Queue: Cary Clark <caryclark@skia.org>
|
|
This should unblock the skia-roller
Bug:Skia:6828
Change-Id: Id918f017ed69bea9536eb1df8c31d43eac51d680
Reviewed-on: https://pdfium-review.googlesource.com/7730
Reviewed-by: dsinclair <dsinclair@chromium.org>
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
Skia has no direct match for a different 2x3
matrix per glyph -- if the 2x3 is a square scale
with rotation, we can do that with RSX transforms.
The bug used the 2x3 to do a condensed face,
which we can do with SkPaint::setTextScaleX.
Otherwise, we draw a character at a time.
R=dsinclair@chromium.org,npm@chromium.org
Bug: 736703
Change-Id: I8f14fd63ffdaee886b63d1154b771f9de092a83f
Reviewed-on: https://pdfium-review.googlesource.com/7272
Commit-Queue: Cary Clark <caryclark@google.com>
Reviewed-by: dsinclair <dsinclair@chromium.org>
Reviewed-by: Nicolás Peña <npm@chromium.org>
|
|
This brings the cpp and h files together and removes the
redundant ge/ path.
Change-Id: I36594b8ae719d362768ba4c2e4ce173e287363eb
Reviewed-on: https://pdfium-review.googlesource.com/7452
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Add debugging for bounding clip boxes
Add debugging to dump save count (probably not useful)
Make debugging output easier to find
R=dsinclair@chromium.org,npm@chromium.org
Bug:
Change-Id: I4b985b8810c80a3061a11401e26a065d17236604
Reviewed-on: https://pdfium-review.googlesource.com/7278
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
GetClipBox returned wrong clip bounds
Found tracing through looking for other bugs.
GetClipBox is used by graphics outside of
Skia so it needs to be kept up to date.
R=dsinclair@chromium.org,npm@chromium.org
Bug: 736703
Change-Id: I2b3fdfe91053848243e5b486a2615a233654c5a9
Reviewed-on: https://pdfium-review.googlesource.com/7274
Reviewed-by: Nicolás Peña <npm@chromium.org>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
clip rect should mirror existing construction
Also found tracing. Keep the clip rect
in sync with its expected value for
compatibility.
R=dsinclair@chromium.org,npm@chromium.org
Bug: 736703
Change-Id: I57bab209f5e1febb5fbcd91860b43296063f1f80
Reviewed-on: https://pdfium-review.googlesource.com/7275
Reviewed-by: Nicolás Peña <npm@chromium.org>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
disabled by default
R=dsinclair@chromium.org,npm@chromium.org
Bug:
Change-Id: Iab08a7120d28b2d81a5e1d4768fd95a460208ebf
Reviewed-on: https://pdfium-review.googlesource.com/7277
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
I could not get this to reproduce. It was also
reported in April, but I marked it fixed because
I couldn't reproduce this then, either. I suspect
that the result of LineSide() is +/-inf, causing
either minBounds or maxBounds in
ClipAngledGradient() to be set to -1, triggering
the stack buffer misread.
R=dsinclair@chromium.org,npm@chromium.org
Bug: 736574
Change-Id: Id828321f8c5481b862822be43d76a41dd8e74ef0
Reviewed-on: https://pdfium-review.googlesource.com/7273
Reviewed-by: dsinclair <dsinclair@chromium.org>
Reviewed-by: Nicolás Peña <npm@chromium.org>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
Code around this bug was altered in April
to fix the off by one bug, but somehow the
loop counter fix was overlooked.
R=dsinclair@chromium.org,npm@chromium.org
Bug: 736195
Change-Id: I583a9f2389e6111ae1b847b961afaafd5e854810
Reviewed-on: https://pdfium-review.googlesource.com/7276
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
The bool returned by Start was not being used and the method was always
called right after the constructor, so it should be in the constructor.
Change-Id: I98abf9f7c11fbe42b3aa15ec5e46731198aa23d5
Reviewed-on: https://pdfium-review.googlesource.com/7151
Commit-Queue: Nicolás Peña <npm@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
This is unused except for being a pathway for indirect deps.
Change-Id: I717290235ccbc59429ad24231033382958e2a086
Reviewed-on: https://pdfium-review.googlesource.com/6910
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
Change-Id: I8365ba80e3395d59a3cf35dbd9d9162e86e712e3
Reviewed-on: https://pdfium-review.googlesource.com/5970
Commit-Queue: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
This CL separates pageint.h and the supporting cpp files into indivudal
class files.
Change-Id: Idcadce41976a8cd5f0d916e6a5ebbc283fd36527
Reviewed-on: https://pdfium-review.googlesource.com/5930
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Change-Id: I88466943171f19259f84add69679741d44c8e123
Reviewed-on: https://pdfium-review.googlesource.com/5551
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
More straight forward than CFX_GEModule owning in and CPDF_ModuleMgr
holding a pointer to it.
Remove assumptions that the codec modules may return nullptr, and do
IWYU.
Change-Id: Iba7fc3c7ec223fd6d29a1ab74ed13d35689bc5d5
Reviewed-on: https://pdfium-review.googlesource.com/5654
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Bug:
Change-Id: I294e765916f35ef933142789179a06ffad67fc31
Reviewed-on: https://pdfium-review.googlesource.com/5494
Reviewed-by: Mike Reed <reed@google.com>
Commit-Queue: Mike Reed <reed@google.com>
|
|
This Cl renames the CFX_RenderDevice subclasses to make their usage
clearer.
Change-Id: Ie820b57df9a3743ce8c6893fb483b398a1f1bdbe
Reviewed-on: https://pdfium-review.googlesource.com/5390
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I9306afed2747e3b0054adeea1d39916cac47f5c5
Reviewed-on: https://pdfium-review.googlesource.com/5091
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
- The agg driver never initializes an ICC transform and always uses an
alpha_flag equal to 0 in a couple of methods.
- The skia driver is not using CFX_Renderer. If it needs it later, we should
move it out of fx_agg_driver.cpp into its own file, instead of duplicating the
code.
Change-Id: Ibd721cf1760270bea3f8f95d6e1e8edbc6ba1792
Reviewed-on: https://pdfium-review.googlesource.com/3952
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Reviewed-by: Cary Clark <caryclark@google.com>
Commit-Queue: Nicolás Peña <npm@chromium.org>
|
|
Skia tracks the font passed so it can
use it later to draw. In XFA's case,
the font is discarded after Skia sees it,
but before it draws with it.
Track the TypeFace instead, which
remains available across the XFA
lifetime.
R=dsinclair@chromium.org
Bug: 705193
Change-Id: I4fc9fee4a7d96ea25f242975f6c0d10941f5c549
Reviewed-on: https://pdfium-review.googlesource.com/4058
Reviewed-by: Nicolás Peña <npm@chromium.org>
Commit-Queue: Nicolás Peña <npm@chromium.org>
|
|
If a clip with bounds (0, 0, 0, 0) is used to specify
the limits of a gradient, the clipping rectangle will
be degenerate.
Leave the clip empty in this case.
R=dsinclair@chromium.org
Bug: 705736
Change-Id: I4a5845459c1527f2c643563d6bef4d6dcc6781d3
Reviewed-on: https://pdfium-review.googlesource.com/4071
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Cary Clark <caryclark@google.com>
|
|
To help find future bugs, add printf and checking
to see that the skia clip stack and the pdfium
clip stack are in sync.
Bug: 705783,795821
Change-Id: I3ed39cbe2514ab18e5bee6eb363cc2d0f042bff5
Reviewed-on: https://pdfium-review.googlesource.com/4090
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
- All callers of CFX_DIBitmap methods use nullptr as the ICC Transform.
- The CFX_ScanlineCompositor is always initialized with a null ICC transform.
Many of its methods call TranslateScanline from the ICC module. This method
casts just uses ((CLcmsCmm*)pTransform)->m_hTransform, and this should not be
done when pTransform is nullptr.
Change-Id: I1b846d1f20699fa017cb9a276be3214eb8fabd4b
Reviewed-on: https://pdfium-review.googlesource.com/3931
Commit-Queue: Nicolás Peña <npm@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|