background-position: center center; // Note that I had to reapply background-position again问题background-position: center center;当我调整div的大小时,我可以确定背景图像的中心位于div的中心</
我正在尝试创建带有文本和drawableTop的按钮。我希望drawableTop是存储图像的常规大小,因为我对不同的屏幕大小有不同的大小。将height和width设置为match_parent似乎基于文本,将它们设置为Dip值会更改按钮的大小,但不会更改图像。我尝试了scaleX和scaleY,但这也改变了文本的大小,这是我不想要的。layout_height="wrap_content"
a