Age | Commit message (Collapse) | Author |
|
Change-Id: Iab7ff29c2ce9ed56715b5897e89da2d9d693583c
Reviewed-on: https://pdfium-review.googlesource.com/20252
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I556934f61f24883e684865e4a8fc5e0519248cee
Reviewed-on: https://pdfium-review.googlesource.com/20251
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I3efc57cd7325d16e3ca8ebdeeaec06012b2c56e3
Reviewed-on: https://pdfium-review.googlesource.com/20110
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Bug: 790693
Change-Id: I9b1d87e024229d8b01f55ec554e2cc544db6ac06
Reviewed-on: https://pdfium-review.googlesource.com/20230
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
Unlike ToFxRect(), which floors the LBRT values. Also fix some nits.
Change-Id: I0680eebb09031807a14402ca30b13558ea5b56d9
Reviewed-on: https://pdfium-review.googlesource.com/20213
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
Unlike ScaleFromCenterPoint(), Scale() just scales the LBRT values.
Also add unit tests for CFX_FloatRect::Normalize().
Change-Id: Iebf48fa9adcf47adff3255b157d3e3056f3687fc
Reviewed-on: https://pdfium-review.googlesource.com/20212
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
Change-Id: I6baab14c989e8ae692ed1c846b135af95c09ce37
Reviewed-on: https://pdfium-review.googlesource.com/20210
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
Change-Id: I08706f53bf3960cbea60b09a1702bf0ba371f1ce
Reviewed-on: https://pdfium-review.googlesource.com/20211
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Change-Id: I32cc3cb0a8a987980b900a5650cc051cb50dd1cc
Reviewed-on: https://pdfium-review.googlesource.com/20190
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This CL continues removing structs from CFX_CTTGSUBTable
Change-Id: I1ede1e3e736f87292b6119406fd5f12a0bb7e7cb
Reviewed-on: https://pdfium-review.googlesource.com/20170
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
Change-Id: Iec4e999d76dabc9b6cd00323881c5c87afc5f629
Reviewed-on: https://pdfium-review.googlesource.com/19930
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
The current implementation of text extraction was difficult to
understand, duplicated logic that existed in other methods, and wasn't
clear about the units the inputs were in. It also didn't handle
control characters correctly.
The new implementation leans on the methods for converting indices
between the text buffer index and character list index spaces to avoid
duplication of code. It also makes it clear to the reader that inputs
are in the character list index space. Finally, it fixes issues being
seen in Chrome with respect of ranges being slightly off.
This CL also adds a test for extracting text that has control
characters.
BUG=pdfium:942,chromium:654578
Change-Id: Id9d1f360c2d7492c7b5a48d6c9ae29f530892742
Reviewed-on: https://pdfium-review.googlesource.com/20014
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
Reviewed-by: Henrique Nakashima <hnakashima@chromium.org>
|
|
The data used is clearly a CID Range, but the code was interpreting it
as single CID values.
Change-Id: Ibb68f5ca2150d74b007a64ef5daa412fd542cecd
Reviewed-on: https://pdfium-review.googlesource.com/17650
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Or initialize members in the header. Also make m_dwFileLen member const.
Change-Id: Iaaeab9a93e18e4ab313437362c0012d729b01647
Reviewed-on: https://pdfium-review.googlesource.com/9970
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
The original fix to https://crbug.com/641333 was too strict. Relax the
checks and use a std::tuple for the path map key, instead of trying to
"hash" a key.
BUG=chromium:788864
Change-Id: I6e6a96691bce2834c2e95baa16ebd39e6aa03140
Reviewed-on: https://pdfium-review.googlesource.com/19950
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
In this CL we prevent integer overflow by checking that the integers are
in the appropriate range before casting from unsigned to signed.
Bug: 789524
Change-Id: I41572849f18ffb0f0739c80130ee6b5061845d29
Reviewed-on: https://pdfium-review.googlesource.com/20011
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
See the bugs and cxx post for justification and details:
https://groups.google.com/a/chromium.org/forum/#!topic/cxx/RkOHzIK6Tq8
This change was done using clang-tidy as described here:
https://chromium.googlesource.com/chromium/src/+/lkcr/docs/clang_tidy.md
Bug: chromium:776257
Change-Id: Iebab34f3ee97a6249e4517d1f5dec1971c36fcba
Reviewed-on: https://pdfium-review.googlesource.com/19973
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
See the bugs and cxx post for justification and details:
https://groups.google.com/a/chromium.org/forum/#!topic/cxx/RkOHzIK6Tq8
This change was done using clang-tidy as described here:
https://chromium.googlesource.com/chromium/src/+/lkcr/docs/clang_tidy.md
Bug: chromium:776257
Change-Id: I1f6637cde8b3e41825993a736bed6763dd7beacb
Reviewed-on: https://pdfium-review.googlesource.com/19971
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
See the bugs and cxx post for justification and details:
https://groups.google.com/a/chromium.org/forum/#!topic/cxx/RkOHzIK6Tq8
This change was done using clang-tidy as described here:
https://chromium.googlesource.com/chromium/src/+/lkcr/docs/clang_tidy.md
In some cases the the tool leaves behind a string of commas where it
replaced a member initializer list
(https://bugs.llvm.org/show_bug.cgi?id=35051). They were cleaned up
with:
git diff --name-only | \
xargs sed -E -i 's/(^\s*|\)\s*):[ ,]*= default/\1 = default/'
Bug: chromium:778959, chromium:778957
Change-Id: I23e60d3d6c8bc9e8574d425710a0441cb5510d6b
Reviewed-on: https://pdfium-review.googlesource.com/19970
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Bug:
Change-Id: I0c930ca30637f58af3b60ed8f1383bd9234a1723
Reviewed-on: https://pdfium-review.googlesource.com/19850
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: Lei Zhang <thestig@chromium.org>
|
|
Bug: pdfium:774
Change-Id: I2056583c270f1bb0046250ce2ec53a2cbe46b893
Reviewed-on: https://pdfium-review.googlesource.com/19672
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL removes some useless structs from CFX_CTTGSUBTable.
Change-Id: Iaf8b58d70b36d77fea73946c6b4279b15f5726e8
Reviewed-on: https://pdfium-review.googlesource.com/19710
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
Bug: pdfium:774
Change-Id: Id993864c4ae009e686c62e7be13e2db5d8cb4170
Reviewed-on: https://pdfium-review.googlesource.com/19572
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Bug: pdfium:774
Change-Id: Ie7674ac55dea6284a0d974cef107ef357197a06b
Reviewed-on: https://pdfium-review.googlesource.com/19610
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This CL makes the helper methods 'ConvertBuffer_'* in CFX_DIBSource void
since they always succeed.
Change-Id: I55dd714bec5ccc3695cd0bbebcf978d767acc53a
Reviewed-on: https://pdfium-review.googlesource.com/19650
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
This CL removes the CollectionSize and updates call locations as needed.
Bug: pdfium:774
Change-Id: I813c500b3a17a194407ceb1304252b9b16fe1779
Reviewed-on: https://pdfium-review.googlesource.com/19590
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This CL removes the use of CollectionSize from CPDF_StructTree and uses
size_t in the callers.
Bug: pdfium:774
Change-Id: I860a51a533642c949c497ca26e74ba064a8aa9ba
Reviewed-on: https://pdfium-review.googlesource.com/19530
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
BUG=chromium:788103
Change-Id: I8ebdbc78eb14c358d7ac019b96de4828e6071b79
Reviewed-on: https://pdfium-review.googlesource.com/19350
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
In this CL, we do some nit cleanup and change many var++ to ++var in
CFX_DIBSource.
Change-Id: I2379e6e15688cbde68415adc47b01114ad0785c1
Reviewed-on: https://pdfium-review.googlesource.com/19570
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
This CL changes CountKids to not used CollectionSize and returns size_t
directly. Callers updated as needed.
Bug: pdfium:774
Change-Id: I8862218e62cd13be9473fa8116afd29cd3afde04
Reviewed-on: https://pdfium-review.googlesource.com/19510
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Bug: pdfium:774
Change-Id: I4996f5526884c33d92df964045bd5467c392df5e
Reviewed-on: https://pdfium-review.googlesource.com/19490
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Bug: pdfium:774
Change-Id: I7ebbcb17374b4117f92b94edbd8bcba18efe6313
Reviewed-on: https://pdfium-review.googlesource.com/19470
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
Bug: pdfium:774
Change-Id: I3fcde6fba46d21affa63d79fab2d83f47c9c5f84
Reviewed-on: https://pdfium-review.googlesource.com/19450
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL updates various methods in CPDF_TextObject to return or received
size_t values. Callers have been updated as needed.
Bug: pdfium:774
Change-Id: Id72511bc74637c6261add39f5414c9a4b8390b82
Reviewed-on: https://pdfium-review.googlesource.com/19430
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
|
|
This CL updates the various call sites to use size_t instead of other
types.
Bug: pdfium:774
Change-Id: Id8b75728b61c0ca1b15bc815831c885d33374f7b
Reviewed-on: https://pdfium-review.googlesource.com/19410
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
Bug: pdfium:774
Change-Id: Ie24d0741f8c8d7988166aeb4b9ce87491993d30c
Reviewed-on: https://pdfium-review.googlesource.com/19390
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
BUG=pdfium:939
Change-Id: I4204965bd8b81bea3c485fcb27adfa212cce4e69
Reviewed-on: https://pdfium-review.googlesource.com/19190
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
Change-Id: I45468fa7944290fbbe3d2e67f884164ae8d84160
Reviewed-on: https://pdfium-review.googlesource.com/19171
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Change-Id: Ic552a652856ca231f3d2077c76a20d5916adb3c1
Reviewed-on: https://pdfium-review.googlesource.com/19170
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
Or change them to clear().
Change-Id: Ia9e3e1f0d74b948cec3f8df85d205f830ac9216c
Reviewed-on: https://pdfium-review.googlesource.com/19172
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This gets rid of most core/ non-const ref passing, either by passing by
pointer-to-pointer instead, or by returning std::pair.
Change-Id: Id7bdc355a1a725a05f9fa2f1e982ca8c975beef1
Reviewed-on: https://pdfium-review.googlesource.com/19030
Commit-Queue: Lei Zhang <thestig@chromium.org>
Reviewed-by: dsinclair <dsinclair@chromium.org>
|
|
So callers no longer have to call str.TrimLeft(); str.TrimRight();
Change-Id: If931eaa8d891f487b9618ebbeee5ee294e807846
Reviewed-on: https://pdfium-review.googlesource.com/18990
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This CL converts the CFX_DateTime::Now method to be a static and updates
the callers.
Change-Id: I26052c6194ed2d43bca5fee2542787ce166eda85
Reviewed-on: https://pdfium-review.googlesource.com/18670
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
This CL moves the Format and FormatV methods of ByteString to be static.
Bug: pdfium:934
Change-Id: I9c30455a789aff9f619b9d5bf89c0712644f2d9a
Reviewed-on: https://pdfium-review.googlesource.com/18650
Commit-Queue: dsinclair <dsinclair@chromium.org>
Reviewed-by: Tom Sepez <tsepez@chromium.org>
|
|
This CL moves the Format and FormatV methods from WideString to be
static.
Bug: pdfium:934
Change-Id: I9941d6a2a5bbf0a82087cd0ea5d0f8fc42eecd3e
Reviewed-on: https://pdfium-review.googlesource.com/18630
Reviewed-by: Tom Sepez <tsepez@chromium.org>
Commit-Queue: dsinclair <dsinclair@chromium.org>
|
|
This CL unifies a bit the public methods of CFGAS_FontMgr. It does so by
replacing the multiple maps on the Windows implementation to a single
map from hash to font. Also, cloning CFX_Fonts is avoided with the use
of SetLogicalFontStyle. These Windows changes are just mimicking other
OS's. As a side-effect, some members of CFX_Fonts are now owned so the
raw pointers are replaced with unique_ptrs.
Change-Id: I576d438572ccbe6c48f8f5cc434d66fc6adba372
Reviewed-on: https://pdfium-review.googlesource.com/18131
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
This code doesn't depend on XFA, but is only used by it. Moving it
out, so it will be easier for me to write some tools for extracting
data out of PDFs.
Bug:
Change-Id: Ic18613b46abed5124c47f539833b01b12c1c6e56
Reviewed-on: https://pdfium-review.googlesource.com/18410
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Ryan Harrison <rharrison@chromium.org>
|
|
This should allow https://pdfium-review.googlesource.com/15770 to safely
reland.
BUG=chromium:781529
Change-Id: Id0c1bde3280fb72125d8e74751b9a1cb35302b6f
Reviewed-on: https://pdfium-review.googlesource.com/18170
Reviewed-by: dsinclair <dsinclair@chromium.org>
Commit-Queue: Lei Zhang <thestig@chromium.org>
|
|
This CL adds checks in CJBig2_GRRDProc to verify if the decoder is
completed before trying to decode. This is currently done in all
decoding calls in CJBig2_GRDProc.
Bug: chromium:782826
Change-Id: Ifb4ee4d09e8357e969aefa107b4dafbc2284324b
Reviewed-on: https://pdfium-review.googlesource.com/18333
Reviewed-by: Lei Zhang <thestig@chromium.org>
Commit-Queue: Nicolás Peña Moreno <npm@chromium.org>
|
|
Change-Id: Id53f57085fecfe331c8cbfa6bb372b5ea5044442
Reviewed-on: https://pdfium-review.googlesource.com/18332
Reviewed-by: Lei Zhang <thestig@chromium.org>
Reviewed-by: Ryan Harrison <rharrison@chromium.org>
Commit-Queue: Henrique Nakashima <hnakashima@chromium.org>
|