Color State List Resource
ColorStateList
可以用XML定义,并且可以用到View文字上。
文件存放位置:
res/color/filename.xml
语法:
<?xml version="1.0" encoding="utf-8"?><selectorxmlns:android="http://schemas.android.com/apk/res/android">
<item
android:color="hex_color"
android:state_pressed=["true" | "false"]
android:state_focused=["true" | "false"]
android:state_selected=["true" | "false"]
android:state_checkable=["true" | "false"]
android:state_checked=["true" | "false"]
android:state_enabled=["true" | "false"]
android:state_window_focused=["true" | "false"] /></selector>
例子:
定义,/res/color/button_text_color.xml
<?xml version="1.0" encoding="utf-8"?>
<selector xmlns:android="http://schemas.android.com/apk/res/android">
<item android:state_pressed="true"
android:color="#ffff0000"/> <!-- pressed -->
<item android:state_focused="true"
android:color="#ff0000ff"/> <!-- focused 在键盘手机上才会显示效果 -->
<item android:color="#ff000000"/> <!-- default -->
</selector>
应用:
<Button
android:layout_width="fill_parent"
android:layout_height="wrap_content"
android:text="@string/button_text"
android:textColor="@color/button_text_color" />
相关推荐
public void setFieldErrors(Map,List<String>> errorMap)从接口 ValidationAware 复制的描述 Set the field error map of fieldname (String) to Collection of String error messages. 指定者: 接口 ...
Windows Server 2003 Resource Kit Tools 其中包括的工具有: Acctinfo.dll (documented in Readme.htm) Adlb.exe: Active Directory Load Balancing Tool,AD负载均衡 Admx.msi: ADM File Parser,ADM文件解析 ...
manual and resource-intensive process. Frag Shield抯 MFT fragmentation prevention technology is now fully automatic and re-written to operate invisibly using InvisiTasking technology. o ...
dev->early_suspend.level = EARLY_SUSPEND_LEVEL_DISABLE_FB + 1; dev->early_suspend.suspend = vfe_early_suspend; dev->early_suspend.resume = vfe_late_resume; // [hawkview_err]xxxxcan't open /dev/...
06.zip<br>Combobox Color Picker <br>选择颜色的ComboBox(6KB)<END><br>7,07.zip<br>Switch between drop down & drop list mode <br>处理drop down和drop list方式之间的转换(32KB)<END><br>8,08.zip<br>Drop down...
1,01.zip<br>Output<br>显示所有的调试信息(5KB)<END><br>2,02.zip<br>Some general debugging tips<br>一般的调试技巧(11KB)<END><br>3,03.zip<br>Debugging ISAPI extension<br>调试ISAPI扩展(4KB)<END><br>4,04....
.NET Resource List ASP.NET Web Hosting Sites ASP.NET Web Sites C# Web Sites Visual Basic .NET Web Sites .NET Web Sites XML Web Services Microsoft .NET Websites Microsoft .NET ...
A filter is an object that performs filtering tasks on either the request to a resource (a servlet or static content), or on the response from a resource, or both. Filters perform filtering in the ...
Note: Only showing participant and session state change events. 1. MainWndProc - User selects to make a call to a buddy / SIP URI 2. MainWndProc - Does some error checking, URI formatting if ...
IOCTL_VIDEO_GET_OUTPUT_DEVICE_POWER_STATE IOCTL_VIDEO_ENUM_MONITOR_PDO IOCTL_VIDEO_INIT_WIN32K_CALLBACKS IOCTL_VIDEO_IS_VGA_DEVICE IOCTL_VIDEO_MAP_VIDEO_MEMORY IOCTL_VIDEO_QUERY_NUM_AVAIL_MODES ...
(Screen Shot)<br> * Load and Save State - With the ExpressBars, you can load and save Bar state to an INI file, to the Windows Registry and to a stream.<br> * Detachable Sub-Menus - ExpressBars ...
The most comprehensive and time-efficient LPIC-1 study guide available, it's an extraordinarily cost-effective alternative to expensive training: a perfect resource for all LPIC-1 candidates....
User can type data into an edit box or can bring up dialog or popup window by clicking a button. TMemoryTable implements BDE in-memory table as a dataset component (with Delete operation). ...
24)..Added: EResLeaks improvements (new funcs: ResourceAdd, ResourceDelete, ResourceName; support for realloc-like functions) 25)..Fixed: Added workaround for bug in JIRA 5.x 26)..Fixed: Rare ...
User can type data into an edit box or can bring up dialog or popup window by clicking a button. TMemoryTable implements BDE in-memory table as a dataset component (with Delete operation). ...
4.< font color="red">samplar< /font> 另外,XML标记必须遵循下面的命名规则: 1.名字中可以包含字母、数字以及其它字母; 2.名字不能以数字或"_" (下划线) 开头; 3.名字不能以字母 xml (或 XML 或 Xml ..)...
Cannot access field <fieldname> as type variant." * TClientDataSet doesn‘t save data to file when FileName is set and there is no existing file on disk (Quality Central 2307). * Using the Delphi...
The resource type has the following resource block format: Resource Type (Code) Content DB (2) Data 1: sub-resource; Data 2: 0; Data 3: 0 File (3) Data 1: File ID; Data 2: 0; Data 3: 0 Index (4) Data ...
4.7 Appendix – List of 3GPP LTE Standards 78 Contents vii 5 Channel Dependent Scheduling 83 5.1 Introduction 83 5.2 SC-FDMA Performance Measures 88 5.3 Scheduling Algorithms 91 5.4 Channel Models ...
<no opcode> | add r0,r1 ;only available inside an IT block, or | ;as 32-bit T2 instruction add r8,r1 | add r8,r1 ;high register used, does not update PSR adds r8,r1 | adds r8,r1 ;only available...