开发者

Change the size of android Checkbox

In my Android application I need to change the size of the android checkbox. I searched and understood it can not be done by simply changing the properties. I found the THIS LINK but can't really figure out what exactly have to do. [Can't find this link, "android-sdk-windows-1.0_r2\tools\lib\res\default\values\themes.xml"].

开发者_开发技巧Can Someone please help me to achieve this??? Thanks


The path for themes.xml and styles.xml is changed from the given one to android-sdk-windows\platforms\android-8\data\res\values (android-8 is for API-level 8). The drawable btn_check.xml is available at android-sdk-windows\platforms\android-8\data\res\drawable, while the other drawable components are available at respective hdpi / mdpi folders.

2) You simply need to include the respective drawables of the checkbox in different states (i.e. focused, pressed, checked, or normal), and a drawable for the background as well (often the nine-patch file given in the link). Include these in the respective xml to specify the looks of the checkbox as given in the link, and include that xml in the android:button and android:background attributes of your checkbox. That should do it all...! :)

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜