My android marquee java won't run -
below java function marquee:
public textview setmarqueetext(string content){ textstyle = new htmlparser().parse(content); txtview = new textview(this.playercontext); txtview.setlayoutparams(new framelayout.layoutparams(layoutparams.match_parent,layoutparams.match_parent)); if (!textstyle.getfontsize().isempty()){ txtview.settextsize(typedvalue.complex_unit_px, (float)(double.parsedouble(textstyle.getfontsize()) * screenratio)); } string color = textstyle.getfontcolor(); if (!color.endswith("")){ txtview.settextcolor(color.parsecolor(color)); } txtview.setsingleline(true); txtview.setellipsize(truncateat.marquee); txtview.setmarqueerepeatlimit(-1); txtview.setgravity(gravity.bottom); txtview.setfocusable(true); txtview.sethorizontallyscrolling(true); txtview.settext(html.fromhtml(content)); txtview.setselected(true); return txtview; }
i call function using below way:
text t; t = new text(context,1.777); layout.addview(t.setmarqueetext("cool"));
but show static "cool" , not scroll. can me here?
Comments
Post a Comment