Home
last modified time | relevance | path

Searched refs:style (Results 1 – 25 of 534) sorted by relevance

12345678910>>...22

/frameworks/base/core/java/android/content/res/
DStringBlock.java33 import android.text.style.AbsoluteSizeSpan;
34 import android.text.style.BackgroundColorSpan;
35 import android.text.style.BulletSpan;
36 import android.text.style.CharacterStyle;
37 import android.text.style.ForegroundColorSpan;
38 import android.text.style.LineHeightSpan;
39 import android.text.style.RelativeSizeSpan;
40 import android.text.style.StrikethroughSpan;
41 import android.text.style.StyleSpan;
42 import android.text.style.SubscriptSpan;
[all …]
/frameworks/opt/setupwizard/library/test/robotest/src/com/android/setupwizardlib/util/
DThemeResolverTest.java47 assertThat(themeResolver.resolve("material")).isEqualTo(R.style.SuwThemeMaterial); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
48 assertThat(themeResolver.resolve("material_light")).isEqualTo(R.style.SuwThemeMaterial_Light); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
49 assertThat(themeResolver.resolve("glif")).isEqualTo(R.style.SuwThemeGlif); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
50 assertThat(themeResolver.resolve("glif_light")).isEqualTo(R.style.SuwThemeGlif_Light); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
51 assertThat(themeResolver.resolve("glif_v2")).isEqualTo(R.style.SuwThemeGlifV2); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
52 assertThat(themeResolver.resolve("glif_v2_light")).isEqualTo(R.style.SuwThemeGlifV2_Light); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
53 assertThat(themeResolver.resolve("glif_v3")).isEqualTo(R.style.SuwThemeGlifV3); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
54 assertThat(themeResolver.resolve("glif_v3_light")).isEqualTo(R.style.SuwThemeGlifV3_Light); in resolve_nonDayNight_shouldReturnCorrespondingTheme()
62 assertThat(themeResolver.resolve("material")).isEqualTo(R.style.SuwThemeMaterial_DayNight); in resolve_dayNight_shouldReturnDayNightTheme()
64 .isEqualTo(R.style.SuwThemeMaterial_DayNight); in resolve_dayNight_shouldReturnDayNightTheme()
[all …]
/frameworks/base/tools/aapt2/link/
DAutoVersioner_test.cpp87 …Style* style = test::GetValueForConfig<Style>(table.get(), "app:style/Foo", test::ParseConfigOrDie… in TEST() local
88 ASSERT_THAT(style, NotNull()); in TEST()
89 ASSERT_EQ(style->entries.size(), 1u); in TEST()
90 EXPECT_EQ(test::ParseNameOrDie("android:attr/onClick"), style->entries.front().key.name); in TEST()
92style = test::GetValueForConfig<Style>(table.get(), "app:style/Foo", test::ParseConfigOrDie("v13")… in TEST()
93 ASSERT_THAT(style, NotNull()); in TEST()
94 ASSERT_EQ(style->entries.size(), 2u); in TEST()
95 EXPECT_EQ(test::ParseNameOrDie("android:attr/onClick"), style->entries[0].key.name); in TEST()
97 style->entries[1].key.name); in TEST()
99style = test::GetValueForConfig<Style>(table.get(), "app:style/Foo", test::ParseConfigOrDie("v17")… in TEST()
[all …]
DReferenceLinker_test.cpp89 Style* style = test::GetValue<Style>(table.get(), "com.app.test:style/Theme"); in TEST() local
90 ASSERT_THAT(style, NotNull()); in TEST()
91 style->entries.back().value = in TEST()
120 Style* style = test::GetValue<Style>(table.get(), "com.app.test:style/Theme"); in TEST() local
121 ASSERT_THAT(style, NotNull()); in TEST()
122 ASSERT_TRUE(style->parent); in TEST()
123 ASSERT_TRUE(style->parent.value().id); in TEST()
124 EXPECT_EQ(ResourceId(0x01060000), style->parent.value().id.value()); in TEST()
126 ASSERT_EQ(2u, style->entries.size()); in TEST()
128 ASSERT_TRUE(style->entries[0].key.id); in TEST()
[all …]
DAutoVersioner.cpp92 if (Style* style = ValueCast<Style>(config_value->value.get())) { in Consume() local
96 auto iter = style->entries.begin(); in Consume()
97 while (iter != style->entries.end()) { in Consume()
115 iter = style->entries.erase(iter); in Consume()
132 std::unique_ptr<Style> new_style(style->Transform(cloner)); in Consume()
133 new_style->SetComment(style->GetComment()); in Consume()
134 new_style->SetSource(style->GetSource()); in Consume()
/frameworks/base/tools/aapt2/
DValueVisitor_test.cpp43 void Visit(Style* style) override { in Visit()
44 visited_style = style; in Visit()
45 DescendingValueVisitor::Visit(style); in Visit()
58 std::unique_ptr<Style> style = in TEST() local
65 style->Accept(&visitor); in TEST()
67 ASSERT_EQ(style.get(), visitor.visited_style); in TEST()
71 ASSERT_EQ(style->entries.size() + 2, visitor.visited_refs.size()); in TEST()
78 std::unique_ptr<Style> style = in TEST() local
83 EXPECT_NE(ValueCast<Style>(style.get()), nullptr); in TEST()
84 EXPECT_EQ(ValueCast<Reference>(style.get()), nullptr); in TEST()
/frameworks/opt/setupwizard/library/main/src/com/android/setupwizardlib/util/
DThemeResolver.java38 .setDefaultTheme(R.style.SuwThemeGlif_DayNight) in getDefault()
107 return R.style.SuwThemeGlifV3_DayNight; in getDayNightThemeRes()
110 return R.style.SuwThemeGlifV2_DayNight; in getDayNightThemeRes()
113 return R.style.SuwThemeGlif_DayNight; in getDayNightThemeRes()
116 return R.style.SuwThemeMaterial_DayNight; in getDayNightThemeRes()
133 return R.style.SuwThemeGlifV3_Light; in getThemeRes()
135 return R.style.SuwThemeGlifV3; in getThemeRes()
137 return R.style.SuwThemeGlifV2_Light; in getThemeRes()
139 return R.style.SuwThemeGlifV2; in getThemeRes()
141 return R.style.SuwThemeGlif_Light; in getThemeRes()
[all …]
/frameworks/layoutlib/bridge/tests/src/com/android/layoutlib/bridge/impl/
DResourceHelperTest.java24 import android.text.style.AbsoluteSizeSpan;
25 import android.text.style.BulletSpan;
26 import android.text.style.ForegroundColorSpan;
27 import android.text.style.RelativeSizeSpan;
28 import android.text.style.StrikethroughSpan;
29 import android.text.style.StyleSpan;
30 import android.text.style.SubscriptSpan;
31 import android.text.style.SuperscriptSpan;
32 import android.text.style.TypefaceSpan;
33 import android.text.style.URLSpan;
[all …]
/frameworks/base/libs/input/
DSpriteIcon.h29 inline SpriteIcon() : style(0), hotSpotX(0), hotSpotY(0) {} in SpriteIcon()
30 inline SpriteIcon(const graphics::Bitmap& bitmap, int32_t style, float hotSpotX, float hotSpotY) in SpriteIcon()
31 : bitmap(bitmap), style(style), hotSpotX(hotSpotX), hotSpotY(hotSpotY) {} in SpriteIcon()
34 int32_t style; member
39 return SpriteIcon(bitmap.copy(ANDROID_BITMAP_FORMAT_RGBA_8888), style, hotSpotX, hotSpotY); in copy()
44 style = 0; in reset()
/frameworks/base/core/java/android/text/
DHtml.java27 import android.text.style.AbsoluteSizeSpan;
28 import android.text.style.AlignmentSpan;
29 import android.text.style.BackgroundColorSpan;
30 import android.text.style.BulletSpan;
31 import android.text.style.CharacterStyle;
32 import android.text.style.ForegroundColorSpan;
33 import android.text.style.ImageSpan;
34 import android.text.style.ParagraphStyle;
35 import android.text.style.QuoteSpan;
36 import android.text.style.RelativeSizeSpan;
[all …]
/frameworks/base/core/java/android/text/style/
DStyleSpan.java17 package android.text.style;
59 public StyleSpan(int style) { in StyleSpan() argument
60 this(style, Configuration.FONT_WEIGHT_ADJUSTMENT_UNDEFINED); in StyleSpan()
75 public StyleSpan(@Typeface.Style int style, int fontWeightAdjustment) { in StyleSpan() argument
76 mStyle = style; in StyleSpan()
145 private static void apply(Paint paint, int style, int fontWeightAdjustment) { in apply() argument
155 int want = oldStyle | style; in apply()
165 if ((style & Typeface.BOLD) != 0) { in apply()
DTypefaceSpan.java17 package android.text.style;
164 int style; in applyFontFamily() local
167 style = Typeface.NORMAL; in applyFontFamily()
169 style = old.getStyle(); in applyFontFamily()
171 final Typeface styledTypeface = Typeface.create(family, style); in applyFontFamily()
172 int fake = style & ~styledTypeface.getStyle(); in applyFontFamily()
DTextAppearanceSpan.java17 package android.text.style;
195 a = context.obtainStyledAttributes(com.android.internal.R.style.Theme, in TextAppearanceSpan()
209 public TextAppearanceSpan(String family, int style, int size, in TextAppearanceSpan() argument
212 mStyle = style; in TextAppearanceSpan()
465 int style = 0; in updateMeasureState() local
468 style = mStyle; in updateMeasureState()
469 styledTypeface = Typeface.create(mTypeface, style); in updateMeasureState()
474 style = tf.getStyle(); in updateMeasureState()
477 style |= mStyle; in updateMeasureState()
480 styledTypeface = Typeface.create(mFamilyName, style); in updateMeasureState()
[all …]
/frameworks/base/core/tests/coretests/src/android/text/
DSpannedTest.java24 import android.text.style.CharacterStyle;
25 import android.text.style.StyleSpan;
26 import android.text.style.TextAppearanceSpan;
27 import android.text.style.TypefaceSpan;
91 StyleSpan[] style; in testWrapParcel() local
93 style = s2.getSpans(1, 2, StyleSpan.class); in testWrapParcel()
94 assertEquals(1, style.length); in testWrapParcel()
95 assertEquals(1, s2.getSpanStart(style[0])); in testWrapParcel()
96 assertEquals(2, s2.getSpanEnd(style[0])); in testWrapParcel()
98 style = s2.getSpans(3, 7, StyleSpan.class); in testWrapParcel()
[all …]
/frameworks/minikin/include/minikin/
DFont.h76 Builder& setStyle(FontStyle style) { in setStyle() argument
77 mWeight = style.weight(); in setStyle()
78 mSlant = style.slant(); in setStyle()
123 FontStyle style = FontStyle(reader); in readFrom() local
127 new Font(style, typefaceMetadataReader, typefaceLoader, localeListId)); in readFrom()
140 inline FontStyle style() const { return mStyle; } in style() function
148 Font(std::shared_ptr<MinikinFont>&& typeface, FontStyle style, HbFontUniquePtr&& baseFont, in Font() argument
151 mStyle(style), in Font()
156 Font(FontStyle style, BufferReader typefaceMetadataReader, TypefaceLoader* typefaceLoader, in Font() argument
158 : mStyle(style), in Font()
/frameworks/base/core/jni/
Dandroid_view_PointerIcon.h70 int32_t style; member
78 return style == POINTER_ICON_STYLE_NULL; in isNullIcon()
82 style = POINTER_ICON_STYLE_NULL; in reset()
93 jobject contextObj, int32_t style);
108 jobject contextObj, int32_t style, PointerIcon* outPointerIcon);
/frameworks/opt/setupwizard/library/test/instrumentation/src/com/android/setupwizardlib/test/
DItemLayoutTest.java48 R.style.SuwThemeMaterial_Light, in data()
49 R.style.SuwThemeMaterial, in data()
50 R.style.SuwThemeGlif_Light, in data()
51 R.style.SuwThemeGlif, in data()
52 R.style.SuwThemeGlifV2_Light, in data()
53 R.style.SuwThemeGlifV2 in data()
/frameworks/base/core/tests/coretests/src/com/android/internal/policy/
DPhoneWindowTest.java63 createPhoneWindowWithTheme(R.style.LayoutInDisplayCutoutModeUnset); in layoutInDisplayCutoutMode_unset()
72 createPhoneWindowWithTheme(R.style.LayoutInDisplayCutoutModeDefault); in layoutInDisplayCutoutMode_default()
81 createPhoneWindowWithTheme(R.style.LayoutInDisplayCutoutModeShortEdges); in layoutInDisplayCutoutMode_shortEdges()
90 createPhoneWindowWithTheme(R.style.LayoutInDisplayCutoutModeNever); in layoutInDisplayCutoutMode_never()
99 createPhoneWindowWithTheme(R.style.LayoutInDisplayCutoutModeAlways); in layoutInDisplayCutoutMode_always()
108 createPhoneWindowWithTheme(R.style.WindowBackgroundColorLiteral); in testWindowBackground_colorLiteral()
120 createPhoneWindowWithTheme(R.style.WindowBackgroundFallbackColorLiteral); in testWindowBackgroundFallback_colorLiteral()
134 createPhoneWindowWithTheme(R.style.WindowBackgroundFallbackColorLiteral); in testWindowBackgroundFallbackWithExplicitBackgroundSet_colorLiteral()
/frameworks/base/libs/androidfw/tests/
DTheme_test.cpp78 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleOne).has_value()); in TEST_F()
98 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value()); in TEST_F()
127 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value()); in TEST_F()
136 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value()); in TEST_F()
137 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleThree).has_value()); in TEST_F()
166 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleTwo).has_value()); in TEST_F()
167 ASSERT_TRUE(theme->ApplyStyle(app::R::style::StyleThree, true /* force */).has_value()); in TEST_F()
197 ASSERT_TRUE(theme->ApplyStyle(libclient::R::style::Theme, false /*force*/).has_value()); in TEST_F()
222 ASSERT_TRUE(theme_one->ApplyStyle(app::R::style::StyleOne).has_value()); in TEST_F()
235 ASSERT_TRUE(theme_two->ApplyStyle(app::R::style::StyleThree).has_value()); in TEST_F()
[all …]
/frameworks/base/core/tests/coretests/src/android/graphics/
DTypefaceTest.java78 for (int style : STYLES) { in testDefaults()
79 String msg = "style = " + style; in testDefaults()
80 assertNotNull(msg, Typeface.defaultFromStyle(style)); in testDefaults()
81 assertEquals(msg, style, Typeface.defaultFromStyle(style).getStyle()); in testDefaults()
163 final int style = random.nextInt(3); in testMultithreadCacheStressTest()
164 final Typeface result = Typeface.create(base, style); in testMultithreadCacheStressTest()
165 assertEquals(style, result.getStyle()); in testMultithreadCacheStressTest()
240 for (int style : STYLES) { in testSetSystemFontMap()
241 String msg = "style = " + style; in testSetSystemFontMap()
242 assertNotNull(msg, Typeface.defaultFromStyle(style)); in testSetSystemFontMap()
[all …]
DFontFileUtilTest.java107 for (Pair<Integer, Boolean> style : FontTestUtil.getAllStyles()) { in testRegularFonts()
108 int weight = style.first.intValue(); in testRegularFonts()
109 boolean italic = style.second.booleanValue(); in testRegularFonts()
124 for (Pair<Integer, Boolean> style : FontTestUtil.getAllStyles()) { in testTtcFont()
125 int weight = style.first.intValue(); in testTtcFont()
126 boolean italic = style.second.booleanValue(); in testTtcFont()
140 for (Pair<Integer, Boolean> style : FontTestUtil.getAllStyles()) { in testVariationFont()
141 int weight = style.first.intValue(); in testVariationFont()
142 boolean italic = style.second.booleanValue(); in testVariationFont()
/frameworks/base/core/java/android/text/format/
DRelativeDateTimeFormatter.java126 android.icu.text.RelativeDateTimeFormatter.Style style; in getRelativeTimeSpanString() local
128 style = android.icu.text.RelativeDateTimeFormatter.Style.SHORT; in getRelativeTimeSpanString()
130 style = android.icu.text.RelativeDateTimeFormatter.Style.LONG; in getRelativeTimeSpanString()
174 str = getFormatter(icuLocale, style, displayContext).format( in getRelativeTimeSpanString()
180 str = getFormatter(icuLocale, style, displayContext).format( in getRelativeTimeSpanString()
227 getFormatter(icuLocale, style, displayContext); in getRelativeTimeSpanString()
277 android.icu.text.RelativeDateTimeFormatter.Style style; in getRelativeDateTimeString() local
279 style = android.icu.text.RelativeDateTimeFormatter.Style.SHORT; in getRelativeDateTimeString()
281 style = android.icu.text.RelativeDateTimeFormatter.Style.LONG; in getRelativeDateTimeString()
325 return getFormatter(icuLocale, style, capitalizationContext) in getRelativeDateTimeString()
[all …]
/frameworks/base/packages/SystemUI/tests/src/com/android/systemui/statusbar/notification/logging/
DNotificationMemoryMeterTest.kt54 style = NotificationEnums.STYLE_NONE, in currentNotificationMemoryUse_plainNotification()
74 style = NotificationEnums.STYLE_RANKER_GROUP, in currentNotificationMemoryUse_rankerGroupNotification()
93 style = NotificationEnums.STYLE_NONE, in currentNotificationMemoryUse_plainNotification_dontDoubleCountSameBitmap()
116 style = NotificationEnums.STYLE_NONE, in currentNotificationMemoryUse_customViewNotification_marksTrue()
136 style = NotificationEnums.STYLE_NONE, in currentNotificationMemoryUse_notificationWithDataIcon_calculatesCorrectly()
165 style = NotificationEnums.STYLE_BIG_PICTURE, in currentNotificationMemoryUse_bigPictureStyle()
191 style = NotificationEnums.STYLE_CALL, in currentNotificationMemoryUse_callingStyle()
227 style = NotificationEnums.STYLE_MESSAGING, in currentNotificationMemoryUse_messagingStyle()
249 style = NotificationEnums.STYLE_NONE, in currentNotificationMemoryUse_carExtender()
270 style = NotificationEnums.STYLE_NONE, in currentNotificationMemoryUse_tvWearExtender()
[all …]
/frameworks/base/core/java/com/android/internal/widget/
DSubtitleView.java272 final CaptionStyle style; in setStyle() local
274 style = CaptionStyle.getCustomStyle(cr); in setStyle()
276 style = CaptionStyle.PRESETS[styleId]; in setStyle()
280 mForegroundColor = style.hasForegroundColor() ? in setStyle()
281 style.foregroundColor : defStyle.foregroundColor; in setStyle()
282 mBackgroundColor = style.hasBackgroundColor() ? in setStyle()
283 style.backgroundColor : defStyle.backgroundColor; in setStyle()
284 mEdgeType = style.hasEdgeType() ? style.edgeType : defStyle.edgeType; in setStyle()
285 mEdgeColor = style.hasEdgeColor() ? style.edgeColor : defStyle.edgeColor; in setStyle()
288 final Typeface typeface = style.getTypeface(); in setStyle()
/frameworks/opt/setupwizard/library/test/instrumentation/src/com/android/setupwizardlib/template/
DButtonFooterMixinTest.java70 final Button button = mixin.addButton("foobar", R.style.SuwGlifButton_Primary); in testAddButton()
88 mixin.addButton(R.string.suw_next_button_label, R.style.SuwGlifButton_Primary); in testAddButtonTextRes()
104 mixin.addButton("foo", R.style.SuwGlifButton_Secondary); in testAddSpace()
106 mixin.addButton("bar", R.style.SuwGlifButton_Primary); in testAddSpace()
120 final Button fooButton = mixin.addButton("foo", R.style.SuwGlifButton_Secondary); in testRemoveButton()
121 final Button barButton = mixin.addButton("bar", R.style.SuwGlifButton_Secondary); in testRemoveButton()
137 final Button fooButton = mixin.addButton("foo", R.style.SuwGlifButton_Secondary); in testRemoveSpace()
154 final Button fooButton = mixin.addButton("foo", R.style.SuwGlifButton_Secondary); in testRemoveAllViews()

12345678910>>...22