add simpler constructor for SkFont
Bug: skia: Change-Id: I344574cfbba05f013c8844d1a33d680094506ad2 Reviewed-on: https://skia-review.googlesource.com/c/177079 Reviewed-by: Mike Reed <reed@google.com> Commit-Queue: Mike Reed <reed@google.com>
This commit is contained in:
parent
c9b7c720dd
commit
ea908a1fbe
@ -44,6 +44,9 @@ public:
|
||||
*/
|
||||
SkFont(sk_sp<SkTypeface> typeface, SkScalar size);
|
||||
|
||||
// Experimental
|
||||
SkFont(sk_sp<SkTypeface> typeface);
|
||||
|
||||
|
||||
/** Constructs SkFont with default values with SkTypeface and size in points,
|
||||
horizontal scale, and horizontal skew. Horizontal scale emulates condensed
|
||||
|
@ -39,6 +39,8 @@ SkFont::SkFont(sk_sp<SkTypeface> face, SkScalar size, SkScalar scaleX, SkScalar
|
||||
|
||||
SkFont::SkFont(sk_sp<SkTypeface> face, SkScalar size) : SkFont(std::move(face), size, 1, 0) {}
|
||||
|
||||
SkFont::SkFont(sk_sp<SkTypeface> face) : SkFont(std::move(face), kDefault_Size, 1, 0) {}
|
||||
|
||||
SkFont::SkFont() : SkFont(nullptr, kDefault_Size) {}
|
||||
|
||||
bool SkFont::operator==(const SkFont& b) const {
|
||||
|
Loading…
Reference in New Issue
Block a user