aboutsummaryrefslogtreecommitdiffhomepage
path: root/src/pdf/SkPDFFont.cpp
diff options
context:
space:
mode:
authorGravatar robertphillips <robertphillips@google.com>2016-08-15 15:36:58 -0700
committerGravatar Commit bot <commit-bot@chromium.org>2016-08-15 15:36:58 -0700
commit5ba165ee9cd8dc5ea0d10f6a035a3d0cf7c132cd (patch)
tree095564282a349afc024632281f7693d005acf498 /src/pdf/SkPDFFont.cpp
parente6f8ff00136b589c5ee1fc04de5d910d188fa98d (diff)
Revert of SkPDF: unify drawText and drawPosText (patchset #2 id:40001 of https://codereview.chromium.org/2241683005/ )
Reason for revert: I believe this is breaking the Google3 roll Original issue's description: > SkPDF: unify drawText and drawPosText > > Motivation: a later CL will add drawTextBlob() (after > https://crrev.com/2084533004 lands). This CL is designed > with that change in mind. Also fewer redundant lines of > code. > > BUG=skia: > GOLD_TRYBOT_URL= https://gold.skia.org/search?issue=2241683005 > > Committed: https://skia.googlesource.com/skia/+/6059dc32fe36358175cb81541c91e74a2a7e771a TBR=bungeman@google.com,halcanary@google.com # Skipping CQ checks because original CL landed less than 1 days ago. NOPRESUBMIT=true NOTREECHECKS=true NOTRY=true BUG=skia: Review-Url: https://codereview.chromium.org/2248923002
Diffstat (limited to 'src/pdf/SkPDFFont.cpp')
-rw-r--r--src/pdf/SkPDFFont.cpp16
1 files changed, 1 insertions, 15 deletions
diff --git a/src/pdf/SkPDFFont.cpp b/src/pdf/SkPDFFont.cpp
index 05dbdc7e55..769771ab23 100644
--- a/src/pdf/SkPDFFont.cpp
+++ b/src/pdf/SkPDFFont.cpp
@@ -498,7 +498,7 @@ bool SkPDFFont::hasGlyph(uint16_t id) {
return (id >= fFirstGlyphID && id <= fLastGlyphID) || id == 0;
}
-int SkPDFFont::glyphsToPDFFontEncoding(SkGlyphID* glyphIDs, int numGlyphs) const {
+int SkPDFFont::glyphsToPDFFontEncoding(uint16_t* glyphIDs, int numGlyphs) {
// A font with multibyte glyphs will support all glyph IDs in a single font.
if (this->multiByteGlyphs()) {
return numGlyphs;
@@ -517,20 +517,6 @@ int SkPDFFont::glyphsToPDFFontEncoding(SkGlyphID* glyphIDs, int numGlyphs) const
return numGlyphs;
}
-int SkPDFFont::glyphsToPDFFontEncodingCount(const SkGlyphID* glyphIDs,
- int numGlyphs) const {
- if (this->multiByteGlyphs()) { // A font with multibyte glyphs will
- return numGlyphs; // support all glyph IDs in a single font.
- }
- for (int i = 0; i < numGlyphs; i++) {
- if (glyphIDs[i] != 0 &&
- (glyphIDs[i] < fFirstGlyphID || glyphIDs[i] > fLastGlyphID)) {
- return i;
- }
- }
- return numGlyphs;
-}
-
// static
SkPDFFont* SkPDFFont::GetFontResource(SkPDFCanon* canon,
SkTypeface* typeface,