Age | Commit message (Collapse) | Author |
|
This CL removes the code for verifying and creating checksums associated
with form elements in XFA documents. This was the only code requiring
the SAXReader which has also been removed.
According to the XFA spec and application can decide which parts of the
signatures are supported. This feature is being removed until we
determine if/when it is needed.
Bug: pdfium:1063
Change-Id: Iec2261282340f8fc72a1225d2e0d3e6ddf05edcb
Reviewed-on: https://pdfium-review.googlesource.com/30150
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Greatly simplify the code which was neither changing allocations nor
doing any actual work. Eventually GetBuffer() will return a span, and
this makes fewer places to change.
Comment AsFPDFWideString() as a place where we may want a redundant
copy, and make available outside the .cpp file.
Fix one "const" along the way.
Change-Id: I187758b69a0ba3501b3622f6c06280793cd5d464
Reviewed-on: https://pdfium-review.googlesource.com/30011
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Tom Sepez <tsepez@chromium.org>
|
|
It is rarely used and FX_RECT is the more common integer rect type.
Change-Id: I7c5b875321c2d587becedcd058bb3a57fd1f0b61
Reviewed-on: https://pdfium-review.googlesource.com/30053
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
It currently takes const FX_RECT*, but the pointer is never nullptr.
Change-Id: I571e9e8dd04756bc4daa25a61a5af8d1f902914b
Reviewed-on: https://pdfium-review.googlesource.com/30052
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This makes XFA widgets lose focus when a click is performed outside
their area.
Bug: chromium:820256
Change-Id: I7b70fafdc625089f3340a3494bfd51e5c8d0446d
Reviewed-on: https://pdfium-review.googlesource.com/29860
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
The StartLoad, DoLoad and StopLoad methods are called in sequence from
the CPDFXFA_Context. This CL merges the three methods into a single Load
method.
Change-Id: I7135502354fb4c64784c89fa39b74fc58c76b683
Reviewed-on: https://pdfium-review.googlesource.com/29990
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Keeping the internal widget details, since they are likely needed for
wiring up XFA with the other form APIs.
BUG=pdfium:1056
Change-Id: I000468e27bbb59346c4288f1c4f0fe96ed5f3603
Reviewed-on: https://pdfium-review.googlesource.com/29870
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
Currently this is being treated as a case of "data not available" which
leads to an infinite loop.
BUG=pdfium:1055
Change-Id: I2722a5b364d56a4ad5b7cca2a4b42e6b13a933f4
Reviewed-on: https://pdfium-review.googlesource.com/29831
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
The existing code for spellchecking is non-functional and we are not
planning on fixing/finishing it, so removing it, since it currently is
marking everything as misspelt.
BUG=pdfium:1054
Change-Id: I23aaa13c09aed483376d7d06f47fdf31d890786b
Reviewed-on: https://pdfium-review.googlesource.com/29790
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
This CL converts CPDF_DefaultAppearance to return
Optional<CFX_Color:Type> items instead of having a HasColor. This saves
the double parse of the appearance stream.
Change-Id: Ib3c136da6e2adfb559e495de1d299cce0b4ad25f
Reviewed-on: https://pdfium-review.googlesource.com/29630
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL changes the CPDF_DefaultAppearance code to remove the HasFont
method and change GetFont to return an Optional. This forces all the
call sites to verify a font was returned correctly and removes the need
for the duplicate appearance stream parsing.
Bug: chromium:827430
Change-Id: If09e0a7d3f7dd63ad77b97a5a388127e4a02da61
Reviewed-on: https://pdfium-review.googlesource.com/29610
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This experimental API has been superceded by FPDF_SetPrintMode().
Change-Id: I41f8efbb2f40edea60df55c36f7ee3743ac20839
Reviewed-on: https://pdfium-review.googlesource.com/29510
Reviewed-by: Rebekah Potter <rbpotter@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This CL converts the CPDF_DefaultAppearance::GetColor methods to return
instead of using reference parameters.
Change-Id: I9ba6bf060a536290a83d3c9ce6e115511f28664c
Reviewed-on: https://pdfium-review.googlesource.com/29410
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
This CL renames CBA_AnnotIterator to CPDFSDK_AnnotIterator. This
iterator does not seem to be restricted to just BAAnnot entries, so
rename to the more general name.
Change-Id: I735dc37cd5417a2b544882db515dbef4d4dbae67
Reviewed-on: https://pdfium-review.googlesource.com/29430
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
This CL moves code over to using CPDF_DefaultAppearance instead of
calling the CPDF_SimpleParser directly. This means the code for finding
a specific tag start can move into CPDF_DefaultAppearance directly.
Change-Id: I1dc64e54aedd03d059b963121d466f3eb75c17db
Reviewed-on: https://pdfium-review.googlesource.com/28410
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL makes the fpdfsdk/fpdf* files to be consistently prefixed with
fpdf_ instead of randomly dropping the _.
Change-Id: I23e3c8a0831b56bcd17c788d9fe874b2ab8b24fc
Reviewed-on: https://pdfium-review.googlesource.com/29390
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
This CL moves more of the fpdfsdk/ code around to better match the
naming of other files.
Change-Id: I203d91e3e345b2b4767df7a69dd5bd981d61f1d2
Reviewed-on: https://pdfium-review.googlesource.com/29372
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@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 collects the various fsdk_define methods into a fsdk_define.cpp
class. Methods only used in one place are moved into the appropriate
anonymous namespaces.
Change-Id: I75bfc7e8fe20711106fcf9821adeb41d69bf5848
Reviewed-on: https://pdfium-review.googlesource.com/29310
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL removes the ByteString version of PDF_NameDecode and forces the
callers to use the ByteStringView variant.
Change-Id: I5a955d8e909e2045ee45843af54b23e98abe00ed
Reviewed-on: https://pdfium-review.googlesource.com/29350
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
For the cases where we always initialize the font managers, do it in the
constructor instead of as a secondary call.
Change-Id: Ic59b331d1eb357878cd5786b187b5b79bace4498
Reviewed-on: https://pdfium-review.googlesource.com/29291
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Initially it contains:
- FPDFPageObj_CountMarks
- FPDFPageObj_GetMark
- FPDFPageObjMark_GetName
This allows reading the content marks from a page object.
Bug: pdfium:1037
Change-Id: I3d7554b71f938778890fdb44088e0d45dd2718d9
Reviewed-on: https://pdfium-review.googlesource.com/28710
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
This reverts commit ac3e57eee888904d39a07b58ca7d57f8f8b0e51a.
Reason for revert: Tried to reproduce on win bot, 10/10 passed.
Relanding, hopefully it was just a hiccup.
Original change's description:
> Revert "Add FPDFAnnot_CountAttachmentPoints"
>
> This reverts commit ca28cb636331de447125de476decbec333fe613b.
>
> Reason for revert: broke Windows embeddertests
>
> https://build.chromium.org/p/client.pdfium/builders/windows/builds/4622
>
> I got it when landing my CL, which is unrelated. Since this CL passed the bot, I'm guessing it's a flaky test?
>
> Original change's description:
> > Add FPDFAnnot_CountAttachmentPoints
> >
> > This CL adds a function to the API that returns the number of quadpoint
> > sets.
> >
> > Change-Id: I999bc567a4c98f6c32e87810e7ecfbb634c7b677
> > Reviewed-on: https://pdfium-review.googlesource.com/29130
> > Reviewed-by: Lei Zhang <thestig@chromium.org>
> > Commit-Queue: Lei Zhang <thestig@chromium.org>
>
> TBR=thestig@chromium.org,dsinclair@chromium.org,ralf.sippl@gmail.com
>
> Change-Id: Id96b5d4e18be2184c9d24f77bda7499aad0ed211
> No-Presubmit: true
> No-Tree-Checks: true
> No-Try: true
> Reviewed-on: https://pdfium-review.googlesource.com/29190
> Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
> Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
TBR=thestig@chromium.org,dsinclair@chromium.org,ralf.sippl@gmail.com,hnakashima@chromium.org
Change-Id: Ie586552b355ef1f040ae162a539a6b9ebf50d125
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://pdfium-review.googlesource.com/29210
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
This reverts commit ca28cb636331de447125de476decbec333fe613b.
Reason for revert: broke Windows embeddertests
https://build.chromium.org/p/client.pdfium/builders/windows/builds/4622
I got it when landing my CL, which is unrelated. Since this CL passed the bot, I'm guessing it's a flaky test?
Original change's description:
> Add FPDFAnnot_CountAttachmentPoints
>
> This CL adds a function to the API that returns the number of quadpoint
> sets.
>
> Change-Id: I999bc567a4c98f6c32e87810e7ecfbb634c7b677
> Reviewed-on: https://pdfium-review.googlesource.com/29130
> Reviewed-by: Lei Zhang <thestig@chromium.org>
> Commit-Queue: Lei Zhang <thestig@chromium.org>
TBR=thestig@chromium.org,dsinclair@chromium.org,ralf.sippl@gmail.com
Change-Id: Id96b5d4e18be2184c9d24f77bda7499aad0ed211
No-Presubmit: true
No-Tree-Checks: true
No-Try: true
Reviewed-on: https://pdfium-review.googlesource.com/29190
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
Change-Id: If816c4f532f03513ad06959182b0e0edfd688e39
Reviewed-on: https://pdfium-review.googlesource.com/29170
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
This CL adds a function to the API that returns the number of quadpoint
sets.
Change-Id: I999bc567a4c98f6c32e87810e7ecfbb634c7b677
Reviewed-on: https://pdfium-review.googlesource.com/29130
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Also fix nits in QuadPoints code in cpdf_annot.cpp.
Change-Id: I7852b673d3dca906e6d250cb3cfa305f8ea7e742
Reviewed-on: https://pdfium-review.googlesource.com/28893
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This is a step to fix XFA combobox popups being rendered outside the
page.
The rest of the fix is in:
https://chromium-review.googlesource.com/c/chromium/src/+/961249
Bug: chromium:820106
Change-Id: I51e5667bc08cdb2028c0afafa6e29e929e661c94
Reviewed-on: https://pdfium-review.googlesource.com/28371
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Centralize the static_casts involved.
Change-Id: I036ead3b30abd60804b31343de8fda9912e03b0b
Reviewed-on: https://pdfium-review.googlesource.com/28892
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
WideString::Compare() went bad but no embedder test failed. Improve
coverage by hand crafting a PDF similar to the sample PDF in the bug
report.
BUG=chromium:823369
Change-Id: I267f53ba3ef7612bf54771a85f8305b2cbc3cfcb
Reviewed-on: https://pdfium-review.googlesource.com/28910
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Also fix some comments.
Change-Id: Ib42dcf04906139020bdbdfe86e6088faa1c31daa
Reviewed-on: https://pdfium-review.googlesource.com/28830
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Also change it from a macro to a constexpr function.
Change-Id: I8b2bb42c45a23da6db136abdaee24132db4471c6
Reviewed-on: https://pdfium-review.googlesource.com/28579
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Mark the other ArgbEncode() variant as constexpr.
Change-Id: I84207d805766e5efc669638bd8a15cfead356a41
Reviewed-on: https://pdfium-review.googlesource.com/28577
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I196e3148d680c9efeaf9609dd3ddbfe3f6635fa6
Reviewed-on: https://pdfium-review.googlesource.com/28576
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Since that is what it really returns. Add a replacement ArgbToColorRef()
that only returns a FX_COLORREF, and remove a duplicate implementation.
Then update callers and only use ArgbToAlphaAndColorRef() where
appropriate.
Also update comments to explain what FX_COLORREF is.
Change-Id: I5ed3d71683898dc2b3a66395dea0ec2562c14a68
Reviewed-on: https://pdfium-review.googlesource.com/28575
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Currently, when constructing AP for multi-line markup annotations, we
only take into account the first set of quadpoints, resulting in only
the first line of the annotation being displayed if the annotation spans
multiple lines.
This CL, initially written by Jane Liu <janeliulwq@google.com>
(https://pdfium-review.googlesource.com/12010) takes into account all
the quadpoints, so multi-line annotations can be displayed correctly.
BUG=pdfium:876
Change-Id: I8be10ee38e01eb6525ddef556df1b727189455c7
Reviewed-on: https://pdfium-review.googlesource.com/28590
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This causes a scrollbar to appear. We need a test case that contains
an AcroForm combobox with a popup that is large enough to create a
scrollbar.
Bug: chromium:823378, chromium:820278
Change-Id: I6e93bda5b938f9f7c08ceeef7989794ea7764532
Reviewed-on: https://pdfium-review.googlesource.com/28750
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
BUG=chromium:821305
Change-Id: I371572f60ea3984ce044e25125d882b3c2d03115
Reviewed-on: https://pdfium-review.googlesource.com/28733
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
Treat values less than -1 as -1.
BUG=chromium:821305
Change-Id: Ieaced045473fa51097400e5af1286f0d3f4d0143
Reviewed-on: https://pdfium-review.googlesource.com/28732
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
BUG=chromium:821305
Change-Id: I261bc9704363d2a6b930146b2a275d2fa5178165
Reviewed-on: https://pdfium-review.googlesource.com/28692
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
Either give them shorter names, or change them to kFoo.
Change-Id: I3cb7ba242784f163e9c6ba7346d48c622e792ae1
Reviewed-on: https://pdfium-review.googlesource.com/28690
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Found by ClangTidy.
BUG=pdfium:1039
Change-Id: I2bb9256a63d5459e959c1a3228418073245d7a86
Reviewed-on: https://pdfium-review.googlesource.com/28731
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Found by ClangTidy.
BUG=pdfium:1040
Change-Id: I6d7cb26ae2d12f5650f73596d0b991234b076f57
Reviewed-on: https://pdfium-review.googlesource.com/28712
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
One that takes a CFX_FloatRect instead of LBRT floats. Use it where
appropriate.
Change-Id: I8ba19e86c61c91d8b4ef685b5cb65c8fb717f013
Reviewed-on: https://pdfium-review.googlesource.com/28581
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This call removes a page object from a page. We currently offer an
API to insert these objects, but not to remove.
Bug: pdfium:1037
Change-Id: I35ff596f9e7c87a39051f0cb1de40a5bec40fee5
Reviewed-on: https://pdfium-review.googlesource.com/28492
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|
|
Change-Id: I07f4363046be920816e8d0dae766c7af833284db
Reviewed-on: https://pdfium-review.googlesource.com/28582
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I5de956c8a759c974659396a34a355eb0840d2144
Reviewed-on: https://pdfium-review.googlesource.com/28580
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
This replaces them with equivalent FXSYS_*wlower/upper methods, which
uses ICU to perform the correct Unicode operations.
BUG=pdfium:1035
Change-Id: I432db5bef9eda71762016b619d93155949d054db
Reviewed-on: https://pdfium-review.googlesource.com/28530
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
In this doc there is a hyphen followed a fi ligature. Older versions of
PDFium were not inserting the appropriate soft hyphen marker (0x0002)
at this point, since they were only checking for ASCII characters. That
bug is fixed in the preceding CLs, so this test is being added to avoid
regressions.
BUG=pdfium:1029
Change-Id: I9c9906de5a13ade1400a589fb18967938150516d
Reviewed-on: https://pdfium-review.googlesource.com/28470
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
A number of our character helper methods take in wide character types,
but only do tests/operations on the ASCII range of characters. As a
very quick first pass I am renaming all of the foot-gun methods to
explictly call out this behaviour, while I do a bigger
cleanup/refactor.
BUG=pdfium:1035
Change-Id: Ia035dfa1cb6812fa6d45155c4565475032c4c165
Reviewed-on: https://pdfium-review.googlesource.com/28330
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|