Typedef font structs
Use the `struct S; typedef struct S S;` pattern in NDK font headers.
This allows these headers to compile in C and matches the pattern used
by other NDK headers.
Change-Id: I912b2a517931eabbf2405f322ee1f5ddb53dd19f
diff --git a/include/android/font.h b/include/android/font.h
index 45eb81a..0225725 100644
--- a/include/android/font.h
+++ b/include/android/font.h
@@ -87,10 +87,11 @@
AFONT_WEIGHT_MAX = 1000
};
+struct AFont;
/**
* AFont provides information of the single font configuration.
*/
-struct AFont;
+typedef struct AFont AFont;
/**
* Close an AFont.
diff --git a/include/android/font_matcher.h b/include/android/font_matcher.h
index 63b0328..60ff95e 100644
--- a/include/android/font_matcher.h
+++ b/include/android/font_matcher.h
@@ -117,11 +117,12 @@
AFAMILY_VARIANT_ELEGANT = 2,
};
+struct AFontMatcher;
/**
* AFontMatcher performs match operation on given parameters and available font files.
* This matcher is not a thread-safe object. Do not pass this matcher to other threads.
*/
-struct AFontMatcher;
+typedef struct AFontMatcher AFontMatcher;
/**
* Select the best font from given parameters.
diff --git a/include/android/system_fonts.h b/include/android/system_fonts.h
index b0bbb95..94484ea 100644
--- a/include/android/system_fonts.h
+++ b/include/android/system_fonts.h
@@ -87,13 +87,14 @@
__BEGIN_DECLS
+struct ASystemFontIterator;
/**
* ASystemFontIterator provides access to the system font configuration.
*
* ASystemFontIterator is an iterator for all available system font settings.
* This iterator is not a thread-safe object. Do not pass this iterator to other threads.
*/
-struct ASystemFontIterator;
+typedef struct ASystemFontIterator ASystemFontIterator;
/**
* Create a system font iterator.