Android微调文本大小

由于一些设计问题,我设计的旋转器具有较小的宽度和高度.而这个较小的宽度和高度没有显示在微调器的提示中写入的完整文本.
如果有任何解决方案可以减少微调器的文本大小,请帮助.

我附上问题的屏幕截图.

http://www.freeimagehosting.net/97147

解决方法:

根据您的需要使用以下代码……

ArrayAdapter adapter = ArrayAdapter.createFromresource(this, R.array.Questions, R.layout.custom_spinner_list);
            adapter.setDropDownViewResource(R.layout.customer_spinner);
            spin.setAdapter(adapter);

custom_spinner_list.xml

<TextView xmlns:android="http://schemas.android.com/apk/res/android"
    android:text="@+id/TextView01"
    android:id="@+id/TextView01"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:textSize="12dp"
    android:textColor="#000000">
</TextView>

customer_spinner.xml

<TextView xmlns:android="http://schemas.android.com/apk/res/android"
    android:text="@+id/TextView01"
    android:id="@+id/TextView01"
    android:layout_width="fill_parent"
    android:layout_height="wrap_content"
    android:textSize="12dp"
    android:textColor="#000000"
    android:height="42dp"
    android:gravity="center_vertical"
    android:padding = "2dp">
</TextView>

相关文章

Android性能优化——之控件的优化 前面讲了图像的优化,接下...
前言 上一篇已经讲了如何实现textView中粗字体效果,里面主要...
最近项目重构,涉及到了数据库和文件下载,发现GreenDao这个...
WebView加载页面的两种方式 一、加载网络页面 加载网络页面,...
给APP全局设置字体主要分为两个方面来介绍 一、给原生界面设...
前言 最近UI大牛出了一版新的效果图,按照IOS的效果做的,页...