aboutsummaryrefslogtreecommitdiffstats
path: root/fxbarcode/cbc_ean8.cpp
Commit message (Collapse)AuthorAgeFilesLines
* Restructure EAN barcode classes to merge common code.Lei Zhang2018-12-031-44/+8
| | | | | | | | | | | Add an additional layer of class hierarchy to merge some common code between 3 very similar barcode implementations. Change-Id: I435613006a59b1af8c7d05e7c8ba50f64a2c43b5 Reviewed-on: https://pdfium-review.googlesource.com/c/46150 Reviewed-by: Tom Sepez <tsepez@chromium.org> Reviewed-by: Lei Zhang <thestig@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
* Use size_t in more places in fxbarcode.Lei Zhang2018-11-301-4/+4
| | | | | | | Change-Id: Ibed68449c0ac39fa5a97be6dd4922a24b35d46b9 Reviewed-on: https://pdfium-review.googlesource.com/c/46030 Commit-Queue: Lei Zhang <thestig@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
* Remove some useless calculations in fxbarcode.Lei Zhang2018-11-291-2/+2
| | | | | | | | | num - 0 and num * 1 are not helpful. Remove some casts as well. Change-Id: I816afd543501fb87ea0780cb0afb4754e7983324 Reviewed-on: https://pdfium-review.googlesource.com/c/45990 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
* Rename WideString::{UTF8,UTF16LE}_Encode() to To{UTF8,UTF16LE}().Tom Sepez2018-11-271-2/+2
| | | | | | | | | Make consistent with ToDefANSI(). Change-Id: I576f5a8a2bb3f633c7dca67efd7712fa610acf4d Reviewed-on: https://pdfium-review.googlesource.com/c/45791 Commit-Queue: Tom Sepez <tsepez@chromium.org> Reviewed-by: Lei Zhang <thestig@chromium.org>
* Move fxcrt::{Byte,Wide}Strings with std::move().Tom Sepez2018-06-191-7/+4
| | | | | | | | | | | Remove some string copies in barcode that were noticed whilst looking for moves. Change-Id: Ieda34d00f633576ba1f0dca283dcdabfb36f236c Reviewed-on: https://pdfium-review.googlesource.com/35410 Reviewed-by: dsinclair <dsinclair@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
* Convert string class namesRyan Harrison2017-09-181-9/+9
| | | | | | | | | | | | | | | | | Automated using git grep & sed. Replace StringC classes with StringView classes. Remove the CFX_ prefix and put string classes in fxcrt namespace. Change AsStringC() to AsStringView(). Rename tests from TEST(fxcrt, *String*Foo) to TEST(*String*, Foo). Couple of tests needed to have their names regularlized. BUG=pdfium:894 Change-Id: I7ca038685c8d803795f3ed02545124f7a224c83d Reviewed-on: https://pdfium-review.googlesource.com/14151 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Ryan Harrison <rharrison@chromium.org>
* Remove isDevice parameter from barcode Render().Henrique Nakashima2017-09-051-3/+3
| | | | | | | | | | isDevice is currently false in tests and fuzzers and true in real usage. This CL changes it all to true. Change-Id: Idea14795d7f0bb70031e04e5c58e248de72fd39e Reviewed-on: https://pdfium-review.googlesource.com/13130 Commit-Queue: Henrique Nakashima <hnakashima@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
* Convert calls to Mid() to Left() or Right() if possibleRyan Harrison2017-07-281-1/+1
| | | | | | | | | | | | | | | | | | | | | The various string/byte classes support Mid(), Left(), and Right() for extracting substrings. Mid() can handle all possible cases, but Left() and Right() are useful for common cases and more explicit about what is going on. Calls like Mid(offset, length - offset) can be converted to Right(length - offset). Calls like Mid(0, length) can be converted to Left(length). If the substring being extracted does not extend all the way to one of the edges of the string, then Mid() still needs to be used. BUG=pdfium:828 Change-Id: I2ec46ad3d71aac0f7b513e103c69cbe8c854cf62 Reviewed-on: https://pdfium-review.googlesource.com/9510 Commit-Queue: Ryan Harrison <rharrison@chromium.org> Reviewed-by: Tom Sepez <tsepez@chromium.org>
* Remove more |new|s, part 8Tom Sepez2017-05-021-1/+2
| | | | | | | Change-Id: I0e3f4bd33e66fd48db8371a5cc2f8db964720d08 Reviewed-on: https://pdfium-review.googlesource.com/4731 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>
* Change more fxbarcode to use return values.Lei Zhang2017-04-211-27/+21
| | | | | | | Change-Id: Idcc05fb8c5a1448f552b4db5ae131ad82aef4d59 Reviewed-on: https://pdfium-review.googlesource.com/4258 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
* Remove dead barcode bitmap rendering code.Lei Zhang2017-04-171-7/+0
| | | | | | | Change-Id: Idb5ef2aed456e84e0781c374b211560ab7d4fa3d Reviewed-on: https://pdfium-review.googlesource.com/4257 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: Lei Zhang <thestig@chromium.org>
* Move xfa/fxbarcode fxbarcode/Dan Sinclair2017-03-291-0/+94
Nothing in fxbarcode/ depends on XFA code. This CL moves xfa/fxbarcode to be fxbarcode/ and creates a static_library for fxbarcode which is depend on by the xfa library. Change-Id: I0b708737b07efb94b769a5238d92af92bc62880d Reviewed-on: https://pdfium-review.googlesource.com/3291 Reviewed-by: Tom Sepez <tsepez@chromium.org> Commit-Queue: dsinclair <dsinclair@chromium.org>