Home
last modified time | relevance | path

Searched refs:fonts (Results 1 – 25 of 51) sorted by relevance

123

/frameworks/support/compat/tests/java/android/support/v4/provider/
DFontsContractCompatTest.java166 FontInfo[] fonts = FontsContractCompat.getFontFromProvider( in testGetFontFromProvider_resultOK() local
168 assertNotNull(fonts); in testGetFontFromProvider_resultOK()
169 assertEquals(1, fonts.length); in testGetFontFromProvider_resultOK()
170 FontInfo font = fonts[0]; in testGetFontFromProvider_resultOK()
182 FontInfo[] fonts = FontsContractCompat.getFontFromProvider( in testGetFontFromProvider_providerDoesntReturnAllFields() local
184 assertNotNull(fonts); in testGetFontFromProvider_providerDoesntReturnAllFields()
185 assertEquals(1, fonts.length); in testGetFontFromProvider_providerDoesntReturnAllFields()
186 FontInfo font = fonts[0]; in testGetFontFromProvider_providerDoesntReturnAllFields()
195 FontInfo[] fonts = FontsContractCompat.getFontFromProvider( in testGetFontFromProvider_resultFontNotFound() local
197 assertNotNull(fonts); in testGetFontFromProvider_resultFontNotFound()
[all …]
/frameworks/base/core/tests/coretests/src/android/provider/
DFontsContractTest.java35 import android.graphics.fonts.FontVariationAxis;
76 FontInfo[] fonts = FontsContract.getFontFromProvider( in testGetFontFromProvider_resultOK() local
78 assertNotNull(fonts); in testGetFontFromProvider_resultOK()
79 assertEquals(1, fonts.length); in testGetFontFromProvider_resultOK()
80 FontInfo font = fonts[0]; in testGetFontFromProvider_resultOK()
95 FontInfo[] fonts = FontsContract.getFontFromProvider( in testGetFontFromProvider_providerDoesntReturnAllFields() local
97 assertNotNull(fonts); in testGetFontFromProvider_providerDoesntReturnAllFields()
98 assertEquals(1, fonts.length); in testGetFontFromProvider_providerDoesntReturnAllFields()
99 FontInfo font = fonts[0]; in testGetFontFromProvider_providerDoesntReturnAllFields()
111 FontInfo[] fonts = FontsContract.getFontFromProvider( in testGetFontFromProvider_resultFontNotFound() local
[all …]
/frameworks/base/data/fonts/
DAndroid.mk25 $(PRODUCT_OUT)/system/fonts/$(1) : $(PRODUCT_OUT)/system/fonts/$(2)
32 $(ALL_MODULES.$(1).INSTALLED) $(PRODUCT_OUT)/system/fonts/$(1)
56 LOCAL_MODULE_PATH := $(TARGET_OUT)/fonts
72 $(eval LOCAL_MODULE_PATH := $(TARGET_OUT)/fonts)\
90 LOCAL_MODULE := fonts.xml
93 AOSP_FONTS_FILE := frameworks/base/data/fonts/fonts.xml
96 ADDITIONAL_FONTS_SCRIPT := frameworks/base/tools/fonts/add_additional_fonts.py
97 ADD_ADDITIONAL_FONTS := $(local-generated-sources-dir)/fonts.xml
115 FONTCHAIN_LINTER := frameworks/base/tools/fonts/fontchain_lint.py
123 fontchain_lint: $(FONTCHAIN_LINTER) $(TARGET_OUT)/etc/fonts.xml $(PRODUCT_OUT)/system.img
Dfonts.mk20 fonts.xml
/frameworks/support/compat/java/android/support/v4/graphics/
DTypefaceCompatBaseImpl.java52 private static <T> T findBestFont(T[] fonts, int style, StyleExtractor<T> extractor) { in findBestFont() argument
59 for (final T font : fonts) { in findBestFont()
71 protected FontInfo findBestInfo(FontInfo[] fonts, int style) { in findBestInfo() argument
72 return findBestFont(fonts, style, new StyleExtractor<FontInfo>() { in findBestInfo()
108 @Nullable CancellationSignal cancellationSignal, @NonNull FontInfo[] fonts, int style) {
110 if (fonts.length < 1) {
113 FontInfo font = findBestInfo(fonts, style);
DTypefaceCompatApi21Impl.java64 @NonNull FontInfo[] fonts, int style) { in createFromFontInfo() argument
65 if (fonts.length < 1) { in createFromFontInfo()
68 final FontInfo bestFont = findBestInfo(fonts, style); in createFromFontInfo()
DTypefaceCompatApi26Impl.java26 import android.graphics.fonts.FontVariationAxis;
233 @NonNull FontsContractCompat.FontInfo[] fonts, int style) { in createFromFontInfo() argument
234 if (fonts.length < 1) { in createFromFontInfo()
240 final FontsContractCompat.FontInfo bestFont = findBestInfo(fonts, style); in createFromFontInfo()
253 context, fonts, cancellationSignal); in createFromFontInfo()
256 for (FontsContractCompat.FontInfo font : fonts) { in createFromFontInfo()
DTypefaceCompat.java71 @Nullable CancellationSignal cancellationSignal, @NonNull FontInfo[] fonts, in createFromFontInfo() argument
143 @Nullable CancellationSignal cancellationSignal, @NonNull FontInfo[] fonts, int style) { in createFromFontInfo() argument
144 return sTypefaceCompatImpl.createFromFontInfo(context, cancellationSignal, fonts, style); in createFromFontInfo()
/frameworks/minikin/libs/minikin/
DFontFamily.cpp100 FontFamily::FontFamily(std::vector<Font>&& fonts) : FontFamily(0 /* variant */, std::move(fonts)) { in FontFamily() argument
103 FontFamily::FontFamily(int variant, std::vector<Font>&& fonts) in FontFamily() argument
104 : FontFamily(FontLanguageListCache::kEmptyListId, variant, std::move(fonts)) { in FontFamily()
107 FontFamily::FontFamily(uint32_t langId, int variant, std::vector<Font>&& fonts) in FontFamily() argument
108 : mLangId(langId), mVariant(variant), mFonts(std::move(fonts)) { in FontFamily()
229 std::vector<Font> fonts; in createFamilyWithVariation() local
249 fonts.push_back(Font(std::move(minikinFont), font.style)); in createFamilyWithVariation()
252 return std::shared_ptr<FontFamily>(new FontFamily(mLangId, mVariant, std::move(fonts))); in createFamilyWithVariation()
/frameworks/minikin/tests/util/
DFontTestUtils.cpp51 std::vector<Font> fonts; in getFontFamilies() local
74 fonts.push_back(Font(minikinFont, FontStyle(weight, italic))); in getFontFamilies()
78 fonts.push_back(Font(minikinFont, FontStyle(weight, italic))); in getFontFamilies()
85 family = std::make_shared<FontFamily>(variant, std::move(fonts)); in getFontFamilies()
89 family = std::make_shared<FontFamily>(langId, variant, std::move(fonts)); in getFontFamilies()
/frameworks/layoutlib/rename_font/
Dbuild_font_single.py121 fonts = []
131 fonts.append(font)
146 fonts.append(font)
147 return fonts
150 def update_tag(tag, fonts): argument
152 fonts_iterator = fonts.__iter__()
Dbuild_font.py137 fonts = []
147 fonts.append(font)
162 fonts.append(font)
163 return fonts
166 def update_tag(tag, fonts): argument
168 fonts_iterator = fonts.__iter__()
Dtest.py36 fonts = build_font.get_font_info(name_tag)
39 self.assertEqual(fonts[0].family, "Roboto1200310")
40 self.assertEqual(fonts[0].fullname, "Roboto1200310 Regular")
DREADME3 java.awt.Font#layoutGlyphVector() if two fonts with same name but differnt
4 versions are loaded. As a workaround, we rename all the fonts that we ship with
/frameworks/base/core/java/android/provider/
DFontsContract.java34 import android.graphics.fonts.FontVariationAxis;
294 public FontFamilyResult(@FontResultStatus int statusCode, @Nullable FontInfo[] fonts) { in FontFamilyResult() argument
296 mFonts = fonts; in FontFamilyResult()
535 final FontInfo[] fonts = result.getFonts(); in requestFonts() local
536 if (fonts == null || fonts.length == 0) { in requestFonts()
541 for (final FontInfo font : fonts) { in requestFonts()
558 final Typeface typeface = buildTypeface(context, cancellationSignal, fonts); in requestFonts()
600 FontInfo[] fonts = getFontFromProvider( in fetchFonts() local
602 return new FontFamilyResult(FontFamilyResult.STATUS_OK, fonts); in fetchFonts()
621 @Nullable CancellationSignal cancellationSignal, @NonNull FontInfo[] fonts) { in buildTypeface() argument
[all …]
/frameworks/layoutlib/bridge/src/android/graphics/
DTypeface_Delegate.java26 import android.graphics.fonts.FontVariationAxis;
101 List<Font> fonts = new ArrayList<Font>(mFontFamilies.length); in getFonts() local
109 fonts.add(font); in getFonts()
124 fonts.add(font); in getFonts()
126 fonts.add(font2); in getFonts()
133 fonts.add(null); in getFonts()
137 return fonts; in getFonts()
DBidiRenderer.java268 …ate static List<ScriptRun> getScriptRuns(char[] text, int start, int limit, List<FontInfo> fonts) { in getScriptRuns() argument
278 getScriptFont(text, scriptStart, scriptLimit, fonts)); in getScriptRuns()
286 private static Font getScriptFont(char[] text, int start, int limit, List<FontInfo> fonts) { in getScriptFont() argument
287 for (FontInfo fontInfo : fonts) { in getScriptFont()
297 return fonts.get(0).mFont; in getScriptFont()
/frameworks/support/emoji/core/tests/java/android/support/text/emoji/
DFontRequestEmojiCompatConfigTest.java198 final FontInfo[] fonts = new FontInfo[] { in testLoad_success() local
202 doReturn(new FontFamilyResult(STATUS_OK, fonts)).when(mFontProviderHelper).fetchFonts( in testLoad_success()
218 final FontInfo[] fonts = new FontInfo[] { in testLoad_retryPolicy() local
222 doReturn(new FontFamilyResult(STATUS_OK, fonts)).when(mFontProviderHelper).fetchFonts( in testLoad_retryPolicy()
241 final FontInfo[] fonts = new FontInfo[] { in testLoad_keepRetryingAndGiveUp() local
245 doReturn(new FontFamilyResult(STATUS_OK, fonts)).when(mFontProviderHelper).fetchFonts( in testLoad_keepRetryingAndGiveUp()
270 final FontInfo[] fonts = new FontInfo[] { in testLoad_keepRetryingAndFail() local
274 doReturn(new FontFamilyResult(STATUS_OK, fonts)).when(mFontProviderHelper).fetchFonts( in testLoad_keepRetryingAndFail()
328 final FontInfo[] fonts = new FontInfo[]{ in testLoad_keepRetryingAndSuccess() local
332 doReturn(new FontFamilyResult(STATUS_OK, fonts)).when(mFontProviderHelper).fetchFonts( in testLoad_keepRetryingAndSuccess()
[all …]
/frameworks/support/compat/java/android/support/v4/provider/
DFontsContractCompat.java381 public FontFamilyResult(@FontResultStatus int statusCode, @Nullable FontInfo[] fonts) { in FontFamilyResult() argument
383 mFonts = fonts; in FontFamilyResult()
528 final FontInfo[] fonts = result.getFonts(); in requestFont()
529 if (fonts == null || fonts.length == 0) { in requestFont()
539 for (final FontInfo font : fonts) { in requestFont()
567 fonts); in requestFont()
604 @Nullable CancellationSignal cancellationSignal, @NonNull FontInfo[] fonts) { in buildTypeface() argument
605 return TypefaceCompat.createFromFontInfo(context, cancellationSignal, fonts, in buildTypeface()
622 public static Map<Uri, ByteBuffer> prepareFontData(Context context, FontInfo[] fonts, in prepareFontData() argument
626 for (FontInfo font : fonts) { in prepareFontData()
[all …]
/frameworks/base/graphics/java/android/graphics/
DFontListParser.java20 import android.graphics.fonts.FontVariationAxis;
80 List<FontConfig.Font> fonts = new ArrayList<FontConfig.Font>(); in readFamily() local
85 fonts.add(readFont(parser)); in readFamily()
98 return new FontConfig.Family(name, fonts.toArray(new FontConfig.Font[fonts.size()]), lang, in readFamily()
/frameworks/base/core/java/android/text/
DFontConfig.java24 import android.graphics.fonts.FontVariationAxis;
206 public Family(@NonNull String name, @NonNull Font[] fonts, @NonNull String language, in Family() argument
209 mFonts = fonts; in Family()
/frameworks/base/core/java/android/content/res/
DFontResourcesParser.java178 List<FontFileResourceEntry> fonts = new ArrayList<>(); in readFamily() local
185 fonts.add(entry); in readFamily()
191 if (fonts.isEmpty()) { in readFamily()
194 return new FontFamilyFilesResourceEntry(fonts.toArray( in readFamily()
195 new FontFileResourceEntry[fonts.size()])); in readFamily()
/frameworks/support/compat/java/android/support/v4/content/res/
DFontResourcesParserCompat.java197 List<FontFileResourceEntry> fonts = new ArrayList<>(); in readFamily() local
202 fonts.add(readFont(parser, resources)); in readFamily()
207 if (fonts.isEmpty()) { in readFamily()
210 return new FontFamilyFilesResourceEntry(fonts.toArray( in readFamily()
211 new FontFileResourceEntry[fonts.size()])); in readFamily()
/frameworks/minikin/include/minikin/
DFontFamily.h125 explicit FontFamily(std::vector<Font>&& fonts);
126 FontFamily(int variant, std::vector<Font>&& fonts);
127 FontFamily(uint32_t langId, int variant, std::vector<Font>&& fonts);
/frameworks/support/emoji/core/src/android/support/text/emoji/
DFontRequestEmojiCompatConfig.java234 final FontsContractCompat.FontInfo[] fonts = result.getFonts(); in retrieveFontInfo() local
235 if (fonts == null || fonts.length == 0) { in retrieveFontInfo()
238 return fonts[0]; // Assuming the GMS Core provides only one font file. in retrieveFontInfo()

123