Add isFixedPitch
authorMatthew Leibowitz <mattleibow@live.com>
Tue, 19 Nov 2019 03:49:24 +0000 (05:49 +0200)
committerMatthew Leibowitz <mattleibow@live.com>
Tue, 19 Nov 2019 03:49:24 +0000 (05:49 +0200)
include/c/sk_typeface.h
src/c/sk_typeface.cpp

index 82a5a742f5c6d968ebf8948dfa173fe72cc17df5..2b56903926a117d255684203ea7d2b88938c4da0 100644 (file)
@@ -34,6 +34,7 @@ SK_C_API int sk_typeface_count_tables(sk_typeface_t* typeface);
 SK_C_API int sk_typeface_get_table_tags(sk_typeface_t* typeface, sk_font_table_tag_t tags[]);
 SK_C_API size_t sk_typeface_get_table_size(sk_typeface_t* typeface, sk_font_table_tag_t tag);
 SK_C_API size_t sk_typeface_get_table_data(sk_typeface_t* typeface, sk_font_table_tag_t tag, size_t offset, size_t length, void* data);
+SK_C_API bool sk_typeface_is_fixed_pitch(sk_typeface_t* typeface);
 
 // font manager
 
index a245a1b73c68a915f81a6650dbc4769e5bd77b37..c3cde1f7d38b5805a6c0a13dbbfd98d4445c952f 100644 (file)
@@ -98,6 +98,10 @@ size_t sk_typeface_get_table_data(sk_typeface_t* typeface, sk_font_table_tag_t t
     return AsTypeface(typeface)->getTableData(tag, offset, length, data);
 }
 
+bool sk_typeface_is_fixed_pitch(sk_typeface_t* typeface) {
+    return AsTypeface(typeface)->isFixedPitch();
+}
+
 
 // font manager