summaryrefslogtreecommitdiff
path: root/core/fpdftext/cpdf_textpage.cpp
diff options
context:
space:
mode:
authorTom Sepez <tsepez@chromium.org>2018-04-09 20:33:45 +0000
committerChromium commit bot <commit-bot@chromium.org>2018-04-09 20:33:45 +0000
commite372ad7333bdd6bb0c579cf074843ef0c6f3414f (patch)
tree9928344d0def23d3fb070713a88947aceb6b5c71 /core/fpdftext/cpdf_textpage.cpp
parent0d8e530fbf898c1ba1ba4d3d91aa17e3fd4d8317 (diff)
downloadpdfium-e372ad7333bdd6bb0c579cf074843ef0c6f3414f.tar.xz
Use ByteStringView / pdfium::span in CPDF font as appropriate.chromium/3393
Change-Id: I92c7ba605bf95a9023ad046b8dddebe0a0592802 Reviewed-on: https://pdfium-review.googlesource.com/29992 Reviewed-by: dsinclair <dsinclair@chromium.org> Commit-Queue: Tom Sepez <tsepez@chromium.org>
Diffstat (limited to 'core/fpdftext/cpdf_textpage.cpp')
-rw-r--r--core/fpdftext/cpdf_textpage.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/core/fpdftext/cpdf_textpage.cpp b/core/fpdftext/cpdf_textpage.cpp
index e2d1f5f0a6..91c92492cd 100644
--- a/core/fpdftext/cpdf_textpage.cpp
+++ b/core/fpdftext/cpdf_textpage.cpp
@@ -610,7 +610,7 @@ uint32_t CPDF_TextPage::GetCharWidth(uint32_t charCode,
ByteString str;
pFont->AppendChar(&str, charCode);
- w = pFont->GetStringWidth(str.c_str(), 1);
+ w = pFont->GetStringWidth(str.AsStringView());
if (w > 0)
return w;