Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • Home
  • SEARCH
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 6359443
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: May 24, 20262026-05-24T23:31:09+00:00 2026-05-24T23:31:09+00:00

I’ve got this rather peculiar issue. I’m using the default Android appearances to style

  • 0

I’ve got this rather peculiar issue. I’m using the default Android appearances to style my TextViews, and all but one seam to be working flawlessly.

The appearance I’m using is ?android:attr/textAppearanceSmall, and it’s changing the font color without any issues when I’m in the layout XML designer and change the theme between Holo and Holo.Light (Android 3.0+).

However, one particular TextView won’t be styled when it’s running on the tablet, and it’s using the exact same XML code as the others, that are working.

Here’s my XML code for the TextView that doesn’t work:

<TextView android:id="@+id/textView1" 
    android:text="TextView"
    android:layout_height="wrap_content" 
    android:layout_alignParentBottom="true"
    android:layout_alignParentLeft="true"
    android:layout_width="match_parent"
    android:layout_marginTop="2sp"
    android:lines="2"
    android:gravity="top|center"
    android:textAppearance="?android:attr/textAppearanceSmall">
</TextView>

I’ve also tried doing it in code using the following method, but that doesn’t work either:

setTextAppearance(this, android.R.attr.textAppearanceSmall);

Any ideas?

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-05-24T23:31:10+00:00Added an answer on May 24, 2026 at 11:31 pm

    First, I’d like to point out that when styling more then one View-component with the same style (by using XML), there is the very neat way of creating Styles for that.

    So your Style might look like this:

    <?xml version="1.0" encoding="utf-8"?>
    <resources>
    
        <!-- The Style for all the TextViews -->
        <style name="TextViewStyle">
            <item name="android:layout_height">wrap_content</item>
            <item name="android:layout_alignParentBottom">true</item>
            <item name="android:layout_alignParentLeft">true</item>
            <item name="android:layout_width=">match_parent</item>
            <item name="android:layout_marginTop">2sp</item>
            <item name="android:lines">2</item>
            <item name="android:gravity">top|center</item>
            <item name="android:textAppearance">?android:attr/textAppearanceSmall</item>
        </style>
    
    </resources>
    

    While your Layout only looks like this:

    <TextView android:id="@+id/textView1" 
        android:text="TextView"
        style="@style/TextViewStyle"
    />
    
    <TextView android:id="@+id/textView2" 
        android:text="Another TextView"
        style="@style/TextViewStyle"
    />
    
    <!-- .... -->
    

    This makes the code much more maintainable and helps preventing typos.


    Last but not least, something similar to your problem has already been discussed here. This might help solving your problem, too.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

I'm parsing an RSS feed that has an &#8217; in it. SimpleXML turns this
I'm making a simple page using Google Maps API 3. My first. One marker
I want to count how many characters a certain string has in PHP, but
link Im having trouble converting the html entites into html characters, (&# 8217;) i
That's pretty much it. I'm using Nokogiri to scrape a web page what has
For some reason, after submitting a string like this Jack’s Spindle from a text
I'm new to using the Perl treebuilder module for HTML parsing and can't figure
I've got a string that has curly quotes in it. I'd like to replace
this is what i have right now Drawing an RSS feed into the php,
Seemingly simple, but I cannot find anything relevant on the web. What is the

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.