Advertisement
Not a member of Pastebin yet?
Sign Up,
it unlocks many cool features!
- // In skia, one can choose a font with the following code.
- sk_sp<SkTypeface> typeface =
- SkTypeface::MakeFromName("Latin Modern Roman",
- SkFontStyle::FromOldStyle(SkTypeface::kNormal));
- SkPaint paint;
- paint.setTypeface(typeface);
- // display a sentence
- static const char message[] = "Hello World";
- canvas->drawText(message, strlen(message), 0, 0, paint);
Advertisement
Add Comment
Please, Sign In to add comment
Advertisement