android - How to specify gap around text exactly -


in our company, design team expect exact gap (in pixel) between textview , picture under/above/at left of textview. example, textview , picture under it, gap calculated text's baseline (the bottom of character h) top of picture, example, 48 dp. in xml layout file, use same value 48 dp textview's layout_marginbottom. but, after built, design team capture screenshot , measure gap using photoshop, , proved gap not 48 dp, it's around 50 dp. tried includingfontpadding, not work expect. so, how specify exact gap around text?

resolution in photoshop set in pixels per inch official google documentation says android require images set in dpi.while ppi , dpi , not equivalent.android documentation describes relation px = dp*dpi/160. supporting multiple screens. , dashboards need own calculation . can take hear convert ppi dpi


Comments

Popular posts from this blog

how to proxy from https to http with lighttpd -

android - Automated my builds -

python - Flask migration error -