Skip to content
This repository was archived by the owner on Feb 25, 2025. It is now read-only.

Commit 233fc0b

Browse files
reed-at-googleSkia Commit-Bot
authored andcommitted
remove unused cruft
Bug: skia: Change-Id: I41c66d87a82afaf0835b88ee8599e6da0d2a5f58 Reviewed-on: https://skia-review.googlesource.com/c/191424 Commit-Queue: Mike Reed <[email protected]> Reviewed-by: Mike Reed <[email protected]> Auto-Submit: Mike Reed <[email protected]>
1 parent b69179b commit 233fc0b

File tree

4 files changed

+3
-22
lines changed

4 files changed

+3
-22
lines changed

include/core/SkFont.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -511,7 +511,6 @@ class SK_API SkFont {
511511
friend class SkCanonicalizeFont;
512512
friend class SkFontPriv;
513513
friend class SkGlyphRunListPainter;
514-
friend class SkPaint;
515514
friend class SkTextBlobCacheDiffCanvas;
516515
friend class SVGTextBuilder;
517516
};

include/core/SkPaint.h

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,6 @@ class SkImageFilter;
3232
class SkMaskFilter;
3333
class SkPath;
3434
class SkPathEffect;
35-
struct SkPoint;
3635
class SkShader;
3736

3837
/** \class SkPaint

src/core/SkFont.cpp

Lines changed: 0 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -413,20 +413,6 @@ sk_sp<SkTypeface> SkFont::refTypefaceOrDefault() const {
413413

414414
//////////////////////////////////////////////////////////////////////////////////////////////////
415415

416-
int SkFontPriv::ValidCountText(const void* text, size_t length, SkTextEncoding encoding) {
417-
switch (encoding) {
418-
case kUTF8_SkTextEncoding: return SkUTF::CountUTF8((const char*)text, length);
419-
case kUTF16_SkTextEncoding: return SkUTF::CountUTF16((const uint16_t*)text, length);
420-
case kUTF32_SkTextEncoding: return SkUTF::CountUTF32((const int32_t*)text, length);
421-
case kGlyphID_SkTextEncoding:
422-
if (!SkIsAlign2(intptr_t(text)) || !SkIsAlign2(length)) {
423-
return -1;
424-
}
425-
return length >> 1;
426-
}
427-
return -1;
428-
}
429-
430416
void SkFontPriv::ScaleFontMetrics(SkFontMetrics* metrics, SkScalar scale) {
431417
metrics->fTop *= scale;
432418
metrics->fAscent *= scale;

src/core/SkFontPriv.h

Lines changed: 3 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -54,9 +54,6 @@ class SkFontPriv {
5454

5555
static void ScaleFontMetrics(SkFontMetrics*, SkScalar);
5656

57-
// returns -1 if buffer is invalid for specified encoding
58-
static int ValidCountText(const void* text, size_t length, SkTextEncoding);
59-
6057
/**
6158
Returns the union of bounds of all glyphs.
6259
Returned dimensions are computed by font manager from font data,
@@ -71,9 +68,9 @@ class SkFontPriv {
7168
static SkRect GetFontBounds(const SkFont&);
7269

7370
static bool IsFinite(const SkFont& font) {
74-
return SkScalarIsFinite(font.fSize) &&
75-
SkScalarIsFinite(font.fScaleX) &&
76-
SkScalarIsFinite(font.fSkewX);
71+
return SkScalarIsFinite(font.getSize()) &&
72+
SkScalarIsFinite(font.getScaleX()) &&
73+
SkScalarIsFinite(font.getSkewX());
7774
}
7875

7976
// Returns the number of elements (characters or glyphs) in the array.

0 commit comments

Comments
 (0)