android - TextView on Button -
i created custom button
, added textview
programmatically:
layout `framelayout` containing `button` , `textview`
textview tv = new textview(context); framelayout.layoutparams lp=new framelayout.layoutparams(framelayout.layoutparams.wrap_content,framelayout.layoutparams.wrap_content); lp.gravity = gravity.center_vertical; tv.setlayoutparams(lp); tv.settextcolor(getcontrastcolor(left)); tv.settext(" " + left); layout.addview(tv);
on device works (opo) - can see texts on emulator (nexus 5) doesn't - texts invisible - maybe below button.
knows problem?
i found answer - in android 5 there new property - elevation. needed check if sdk 21 , if change elavation of textview
Comments
Post a Comment