Part.1 关键代码 var s = "天气"; // 需要匹配的字符 var reg = new RegExp("(" + s + ")", "g"); // 形成正则规则 var str = "天气真好,可以出去玩玩"; // 全部字符 var newstr = str.replace(reg, "<font color=red>$1</font>"); /
鼠标移动到.移出DIV时修改DIV的颜色: 1.Change the font and Div background color--function <div style="width:200px;height:200px;border:1px solid #ccc;color:#555" onmouseover="size()" onmouseout="size1()" id="d1"> sajdaskjdasl
(1)重写NumberPicker已达到修改显示字体颜色大小 public class TextColorNumberPicker extends NumberPicker { public TextColorNumberPicker(Context context) { super(context); } public TextColorNumberPicker(Context context, AttributeSet attrs) { super(context, attrs); } pu