s id=文本或者编辑框id
ug(id,"text",tx)
ug(id,"selectionstart",a)
ug(id,"selectionend",b)
ssg(tx,a,b,c)
s aa="<font color=#DC143C>"
s aaa="</font>"
ss(aa+c+aaa,hh)
sr(tx,c,hh,uuy)
sr(uuy,"\n","<br>",ui)
ss("(html)"+ui,uy)
us(id,"text",uy)
us(id,"selection",a)
.保留光标位置
.作者:youyou iapp代码助手原作开源,感谢嘻嘻哈哈走过去帮助