I write a desktop widget consisting of one TextView with text (API 16+). I create shape.xml to round the corners of the TextView. On the screen, everything turns out beautifully. Next in the widget settings you need to change the background color. I do remoteViews.setInt (R.id.layout, "setBackgroundColor", color). The color changes, but the widget becomes rectangular, without rounding the corners. Why is this happening? Where does the given form go?
How, then, to change the color of the widget, if it is hard-coded in the xml shape?