随笔分类 -  Android

摘要:从android4.0起系统设置的”显示“提供设置字体大小的选项。这个设置直接会影响到所有sp为单位的字体适配,所以很多app在设置了系统字体后瞬间变得面目全非。下面是解决方案 [java] Resources res = super.getResources(); Configuration co 阅读全文
posted @ 2015-12-23 15:42 逍的遥 阅读(672) 评论(0) 推荐(0) 编辑
摘要:第一种方法:在.xml文件中将这两个List分别放入不同的布局管理器中,比如说 上面一个ExpandableListView一个ListView分别放入两个LinearLayout布局中。在MainAct... 阅读全文
posted @ 2015-12-21 14:58 逍的遥 阅读(386) 评论(0) 推荐(0) 编辑
摘要:非常简单直接上代码:转自:http://blog.sina.com.cn/s/blog_4ac1b5f60102vgnx.html final EditText et1=(EditText)findViewById(R.id.editText1); final Calendar c ... 阅读全文
posted @ 2015-12-17 10:17 逍的遥 阅读(761) 评论(0) 推荐(0) 编辑
摘要:动态添加spinner 控件Spinner s = new Spinner(this);String []items={"自己定义的要显示的数组"};my_SpinnerAdapter array_adapter =new my_SpinnerAdapter(this, android.R.layo... 阅读全文
posted @ 2015-12-15 22:34 逍的遥 阅读(3418) 评论(0) 推荐(1) 编辑
摘要:这里实现 两个 编辑框同一水平上 按1:1分割空间这里的1:1 比例可以通过 lp1.weight : 1p2.weight =m:n 实现 { LinearLayout l=new LinearLayout(this); EditText et1 = new EditT... 阅读全文
posted @ 2015-12-15 22:29 逍的遥 阅读(946) 评论(0) 推荐(0) 编辑

点击右上角即可分享
微信分享提示