/frameworks/base/core/tests/coretests/src/android/provider/ |
FontsContractE2ETest.java | 31 import android.graphics.Typeface; 87 private Typeface mTypeface; 92 public void onTypefaceRetrieved(Typeface typeface) { 93 mTypeface = typeface; 101 public Typeface getTypeface() { 163 Typeface typeface = FontsContract.buildTypeface( local 169 Typeface typeface2 = FontsContract.buildTypeface( 172 // Neighter fetchFonts nor buildTypeface should cache the Typeface [all...] |
/frameworks/layoutlib/bridge/src/android/graphics/ |
Typeface_Delegate.java | 60 * Delegate implementing the native methods of android.graphics.Typeface 62 * Through the layoutlib_create tool, the original native methods of Typeface have been replaced by 67 * and the original Typeface class. 107 // initialize Typeface because the SDK fonts location hasn't been set. 109 Typeface.sDefaults = null; 141 int style = weight >= 600 ? (italic ? Typeface.BOLD_ITALIC : Typeface.BOLD) : 142 (italic ? Typeface.ITALIC : Typeface.NORMAL); 186 if (weight == Typeface.RESOLVE_BY_FONT_TABLE) 254 Typeface typeface = Typeface.findFromCache(context.getAssets(), path); local [all...] |
/frameworks/minikin/include/minikin/ |
FontFamily.h | 62 Builder(const std::shared_ptr<MinikinFont>& typeface) : mTypeface(typeface) {} 99 inline const std::shared_ptr<MinikinFont>& typeface() const { return mTypeface; } function in class:minikin::Font 107 Font(std::shared_ptr<MinikinFont>&& typeface, FontStyle style, HbFontUniquePtr&& baseFont) 108 : mTypeface(std::move(typeface)), mStyle(style), mBaseFont(std::move(baseFont)) {} 110 static HbFontUniquePtr prepareFont(const std::shared_ptr<MinikinFont>& typeface);
|
/frameworks/support/compat/src/main/java/androidx/core/graphics/ |
TypefaceCompatApi26Impl.java | 25 import android.graphics.Typeface; 49 * Implementation of the Typeface compat methods for API 26 and above. 165 * Call method Typeface#createFromFamiliesWithDefault( 168 protected Typeface createFromFamiliesWithDefault(Object family) { 172 return (Typeface) mCreateFromFamiliesWithDefault.invoke(null /* static method */, 203 public Typeface createFromFontFamilyFilesResourceEntry(Context context, 225 public Typeface createFromFontInfo(Context context, 233 // public API to create Typeface from file descriptor. 241 return new Typeface.Builder(pfd.getFileDescriptor()) 273 final Typeface typeface = createFromFamiliesWithDefault(fontFamily) local [all...] |
/frameworks/support/emoji/core/src/main/java/androidx/emoji/text/ |
EmojiMetadata.java | 22 import android.graphics.Typeface; 105 final Typeface typeface = mMetadataRepo.getTypeface(); local 106 final Typeface oldTypeface = paint.getTypeface(); 107 paint.setTypeface(typeface); 118 * @return return typeface to be used to render this metadata 120 public Typeface getTypeface() {
|
FontRequestEmojiCompatConfig.java | 22 import android.graphics.Typeface; 311 // TODO: Good to add new API to create Typeface from FD not to open FD twice. 312 final Typeface typeface = mFontProviderHelper.buildTypeface(mContext, font); local 317 mCallback.onLoaded(MetadataRepo.create(typeface, buffer)); 339 public Typeface buildTypeface(@NonNull Context context,
|
/packages/apps/Camera2/src/com/android/camera/ui/ |
ModeSelectorItem.java | 21 import android.graphics.Typeface; 74 Typeface typeface; local 76 typeface = Typeface.create("sans-serif-medium", Typeface.NORMAL); 78 // Load roboto_light typeface from assets. 79 typeface = Typeface.createFromAsset(getResources().getAssets(), 82 mText.setTypeface(typeface); [all...] |
/external/robolectric-shadows/shadows/framework/src/main/java/org/robolectric/shadows/ |
ShadowPaint.java | 10 import android.graphics.Typeface; 39 private Typeface typeface; field in class:ShadowPaint 168 public Typeface getTypeface() { 169 return typeface; 173 public Typeface setTypeface(Typeface typeface) { 174 this.typeface = typeface; [all...] |
/external/skqp/src/gpu/text/ |
GrStencilAndCoverTextContext.cpp | 380 const SkTypeface* typeface = fFont.getTypeface(); local 382 reinterpret_cast<uint32_t&>(builder[0]) = typeface ? typeface->uniqueID() : 0; 390 const SkTypeface* typeface = fFont.getTypeface(); local 392 reinterpret_cast<uint32_t&>(builder[0]) = typeface ? typeface->uniqueID() : 0; 399 const SkTypeface* typeface = glyphCache->getScalerContext()->getTypeface(); local 404 reinterpret_cast<uint32_t&>(builder[0]) = typeface ? typeface->uniqueID() : 0;
|
/frameworks/base/core/java/com/android/internal/widget/ |
SubtitleView.java | 29 import android.graphics.Typeface; 196 public void setTypeface(Typeface typeface) { 197 if (mTextPaint.getTypeface() != typeface) { 198 mTextPaint.setTypeface(typeface); 287 final Typeface typeface = style.getTypeface(); local 288 setTypeface(typeface);
|
/frameworks/support/compat/src/androidTest/java/androidx/core/graphics/ |
TypefaceCompatTest.java | 33 import android.graphics.Typeface; 99 * Helper method to get the used font resource id by typeface. 101 * If the typeface is created from one of the R.font.large_a, R.font.large_b, R.font.large_c or 102 * R.font.large_d resource, this method returns the resource id used by the typeface. 104 private static int getSelectedFontResourceId(Typeface typeface) { 111 p.setTypeface(typeface); 147 Typeface mTypeface; 154 public void onFontRetrieved(@NonNull Typeface typeface) { 229 Typeface typeface = TypefaceCompat.createFromResourcesFamilyXml(mContext, local 241 Typeface typeface = TypefaceCompat.createFromResourcesFamilyXml(mContext, local 316 Typeface typeface = TypefaceCompat.createFromResourcesFamilyXml(mContext, entry, mResources, local 438 Typeface typeface = TypefaceCompat.createFromResourcesFontFile(mContext, mResources, local [all...] |
/frameworks/support/compat/src/androidTest/java/androidx/core/provider/ |
FontsContractCompatTest.java | 42 import android.graphics.Typeface; 126 Typeface typeface = FontsContractCompat.buildTypeface( local 132 Typeface typeface2 = FontsContractCompat.buildTypeface( 135 // Neither fetchFonts nor buildTypeface should cache the Typeface. 136 assertNotSame(typeface, typeface2); 406 false /* isBlockingFetch */, 300 /* timeout */, Typeface.NORMAL); 415 Typeface mTypeface; 422 public void onFontRetrieved(@NonNull Typeface typeface) { [all...] |
/external/skia/src/ports/ |
SkScalerContext_win_dw.cpp | 49 static bool is_hinted(DWriteFontTypeface* typeface) { 51 AutoTDWriteTable<SkOTTableMaximumProfile> maxp(typeface->fDWriteFontFace.get()); 75 bool get_gasp_range(DWriteFontTypeface* typeface, int size, GaspRange* range) { 76 AutoTDWriteTable<SkOTTableGridAndScanProcedure> gasp(typeface->fDWriteFontFace.get()); 120 static bool has_bitmap_strike(DWriteFontTypeface* typeface, GaspRange range) { 123 AutoTDWriteTable<SkOTTableEmbeddedBitmapLocation> eblc(typeface->fDWriteFontFace.get()); 162 AutoTDWriteTable<SkOTTableEmbeddedBitmapScaling> ebsc(typeface->fDWriteFontFace.get()); 212 DWriteFontTypeface* typeface = this->getDWriteTypeface(); local 213 fIsColorFont = typeface->fFactory2 && 214 typeface->fDWriteFontFace2 & [all...] |
/external/skia/tests/ |
SerializationTest.cpp | 327 static void serialize_and_compare_typeface(sk_sp<SkTypeface> typeface, const char* text, 330 // Create a paint with the typeface. 334 paint.setTypeface(std::move(typeface)); 360 // Load typeface from file to test CreateFromFile with index. 362 auto typeface = SkTypeface::MakeFromStream(new SkMemoryStream(std::move(data)), 1); local 363 if (!typeface) { 366 serialize_and_compare_typeface(std::move(typeface), "A!", reporter); 371 // Load typeface as stream to create with axis settings. 377 sk_sp<SkTypeface> typeface(SkTypeface::MakeFromFontData( 379 if (!typeface) { [all...] |
/external/skqp/src/ports/ |
SkScalerContext_win_dw.cpp | 49 static bool is_hinted(DWriteFontTypeface* typeface) { 51 AutoTDWriteTable<SkOTTableMaximumProfile> maxp(typeface->fDWriteFontFace.get()); 75 bool get_gasp_range(DWriteFontTypeface* typeface, int size, GaspRange* range) { 76 AutoTDWriteTable<SkOTTableGridAndScanProcedure> gasp(typeface->fDWriteFontFace.get()); 120 static bool has_bitmap_strike(DWriteFontTypeface* typeface, GaspRange range) { 123 AutoTDWriteTable<SkOTTableEmbeddedBitmapLocation> eblc(typeface->fDWriteFontFace.get()); 162 AutoTDWriteTable<SkOTTableEmbeddedBitmapScaling> ebsc(typeface->fDWriteFontFace.get()); 212 DWriteFontTypeface* typeface = this->getDWriteTypeface(); local 213 fIsColorFont = typeface->fFactory2 && 214 typeface->fDWriteFontFace2 & [all...] |
/external/skqp/tests/ |
SerializationTest.cpp | 327 static void serialize_and_compare_typeface(sk_sp<SkTypeface> typeface, const char* text, 330 // Create a paint with the typeface. 334 paint.setTypeface(std::move(typeface)); 360 // Load typeface from file to test CreateFromFile with index. 362 auto typeface = SkTypeface::MakeFromStream(new SkMemoryStream(std::move(data)), 1); local 363 if (!typeface) { 366 serialize_and_compare_typeface(std::move(typeface), "A!", reporter); 371 // Load typeface as stream to create with axis settings. 377 sk_sp<SkTypeface> typeface(SkTypeface::MakeFromFontData( 379 if (!typeface) { [all...] |
/frameworks/base/core/jni/ |
android_graphics_Canvas.cpp | 25 #include <hwui/Typeface.h> 494 const Typeface* typeface = paint->getAndroidTypeface(); local 497 static_cast<minikin::Bidi>(bidiFlags), *paint, typeface, nullptr); 505 const Typeface* typeface = paint->getAndroidTypeface(); local 509 static_cast<minikin::Bidi>(bidiFlags), *paint, typeface, nullptr); 518 const Typeface* typeface = paint->getAndroidTypeface(); local 523 contextCount, x, y, bidiFlags, *paint, typeface, mt) 531 const Typeface* typeface = paint->getAndroidTypeface(); local 547 const Typeface* typeface = paint->getAndroidTypeface(); local 562 const Typeface* typeface = paint->getAndroidTypeface(); local [all...] |
/packages/apps/TvSettings/Settings/src/com/android/tv/settings/system/development/ |
CaptionCustomFragment.java | 199 final String typeface = Settings.Secure.getString(getContext().getContentResolver(), local 201 return TextUtils.isEmpty(typeface) ? "default" : typeface;
|
/external/robolectric/v1/src/main/java/com/xtremelabs/robolectric/shadows/ |
ShadowTextView.java | 4 import android.graphics.Typeface; 51 private Typeface typeface; field in class:ShadowTextView 140 public Typeface getTypeface() { 141 return typeface; 145 public void setTypeface(Typeface typeface) { 146 this.typeface = typeface;
|
/external/robolectric/v1/src/test/java/com/xtremelabs/robolectric/shadows/ |
TextViewTest.java | 4 import android.graphics.Typeface; 337 Typeface typeface = Robolectric.newInstanceOf(Typeface.class); local 338 textView.setTypeface(typeface); 339 Assert.assertEquals(typeface, textView.getTypeface());
|
/external/robolectric-shadows/robolectric/src/test/java/org/robolectric/shadows/ |
ShadowTextViewTest.java | 18 import android.graphics.Typeface; 370 Typeface typeface = Shadow.newInstanceOf(Typeface.class); local 371 textView.setTypeface(typeface); 372 assertSame(typeface, textView.getTypeface());
|
/external/sl4a/Common/src/com/googlecode/android_scripting/facade/ui/ |
ViewInflater.java | 23 import android.graphics.Typeface; 521 int style = getInteger(Typeface.class, value); 523 textview.setTypeface(Typeface.DEFAULT); 527 } else if (attr.equals("typeface")) { 529 Typeface typeface = textview.getTypeface(); local 530 int style = typeface == null ? 0 : typeface.getStyle(); 531 textview.setTypeface(Typeface.create(value, style)); [all...] |
/frameworks/support/compat/src/main/java/androidx/core/provider/ |
FontsContractCompat.java | 31 import android.graphics.Typeface; 174 static final LruCache<String, Typeface> sTypefaceCache = new LruCache<>(16); 191 final Typeface typeface = TypefaceCompat.createFromFontInfo( local 193 return new TypefaceResult(typeface, typeface != null 209 final Typeface mTypeface; 212 TypefaceResult(@Nullable Typeface typeface, 214 mTypeface = typeface; [all...] |
/packages/apps/Dialer/java/com/android/dialer/app/calllog/ |
PhoneCallDetailsHelper.java | 23 import android.graphics.Typeface; 233 Typeface typeface = details.isRead ? Typeface.SANS_SERIF : Typeface.DEFAULT_BOLD; local 234 views.nameView.setTypeface(typeface); 235 views.voicemailTranscriptionView.setTypeface(typeface); 236 views.voicemailTranscriptionBrandingView.setTypeface(typeface); 237 views.callLocationAndDate.setTypeface(typeface); 334 title.setTypeface(Typeface.create("sans-serif-medium", Typeface.NORMAL)) [all...] |
/packages/apps/Messaging/src/com/android/messaging/ui/conversationlist/ |
ConversationListItemView.java | 23 import android.graphics.Typeface; 73 private Typeface mListItemReadTypeface; 74 private Typeface mListItemUnreadTypeface; 377 final Typeface typeface; local 378 final int typefaceStyle = mData.getShowDraft() ? Typeface.ITALIC : Typeface.NORMAL; 384 typeface = mListItemReadTypeface; 388 typeface = mListItemUnreadTypeface; 393 mSnippetTextView.setTypeface(typeface, typefaceStyle) [all...] |