Constraint layout button text center alignment
问题 I'm using the new Constraint layout to build my layout. I need to have Button that occupies almost the entire screen width and that was easy using constraints. As you can see in the image I am setting the width to 0dp (Any size), but the text don't stick at the center what's usually the normal for a button text. I've tried: - set gravity to center - set textAlignment to center Looks like this properties can't work with 0dp width (Any size). So I've tried to set the width to match_parent using