Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(2499)

Unified Diff: core/fpdftext/unicodenormalization.cpp

Issue 1897993002: Remove IPDF_TextPage, IPDF_TextPageFind and IPDF_LinkExtract interfaces. (Closed) Base URL: https://pdfium.googlesource.com/pdfium.git@master
Patch Set: Created 4 years, 8 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « core/fpdftext/unicodenormalization.h ('k') | fpdfsdk/fpdf_searchex.cpp » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: core/fpdftext/unicodenormalization.cpp
diff --git a/core/fpdftext/unicodenormalization.cpp b/core/fpdftext/unicodenormalization.cpp
deleted file mode 100644
index 67ab57cb5dc3cc137363aca9b0345d8079b4b2f7..0000000000000000000000000000000000000000
--- a/core/fpdftext/unicodenormalization.cpp
+++ /dev/null
@@ -1,50 +0,0 @@
-// Copyright 2014 PDFium Authors. All rights reserved.
-// Use of this source code is governed by a BSD-style license that can be
-// found in the LICENSE file.
-
-// Original code copyright 2014 Foxit Software Inc. http://www.foxitsoftware.com
-
-#include "core/fpdftext/unicodenormalization.h"
-
-#include "core/fpdftext/unicodenormalizationdata.h"
-#include "core/fxcrt/include/fx_string.h"
-
-namespace {
-
-const uint16_t* const g_UnicodeData_Normalization_Maps[5] = {
- nullptr, g_UnicodeData_Normalization_Map1, g_UnicodeData_Normalization_Map2,
- g_UnicodeData_Normalization_Map3, g_UnicodeData_Normalization_Map4};
-
-} // namespace
-
-FX_STRSIZE FX_Unicode_GetNormalization(FX_WCHAR wch, FX_WCHAR* pDst) {
- wch = wch & 0xFFFF;
- FX_WCHAR wFind = g_UnicodeData_Normalization[wch];
- if (!wFind) {
- if (pDst) {
- *pDst = wch;
- }
- return 1;
- }
- if (wFind >= 0x8000) {
- wch = wFind - 0x8000;
- wFind = 1;
- } else {
- wch = wFind & 0x0FFF;
- wFind >>= 12;
- }
- const uint16_t* pMap = g_UnicodeData_Normalization_Maps[wFind];
- if (pMap == g_UnicodeData_Normalization_Map4) {
- pMap = g_UnicodeData_Normalization_Map4 + wch;
- wFind = (FX_WCHAR)(*pMap++);
- } else {
- pMap += wch;
- }
- if (pDst) {
- FX_WCHAR n = wFind;
- while (n--) {
- *pDst++ = *pMap++;
- }
- }
- return (FX_STRSIZE)wFind;
-}
« no previous file with comments | « core/fpdftext/unicodenormalization.h ('k') | fpdfsdk/fpdf_searchex.cpp » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698