Button with rounded corners

ardhuru

Member
Licensed User
Longtime User
I have a button that changes colors depending on certain parameters. Actually, it is also being used as a label that displays different text depending on the state of certain things. Now, if I dont define the colors in the code, the button has rounded corners by default (radius 5, I think). But with the color definations, the button shape has sharp corners. This even happens if I change the button properties in the designer to staelist drawable', instead of defaultdrawable.

I have seen this thread http://www.b4x.com/forum/basic4android-updates-questions/6642-button-color-background.html but that doesnt really help.

Any idea how I can retain the color statements in the code, and yet have rounded corners?
 
Last edited:

ardhuru

Member
Licensed User
Longtime User
Thanks for that, Klaus. Got it working.

Its thanks to the excellent support on this forum that my project, which started off with very modest requirements, is now getting close to the state I want it to be in.

Regards,

Anand Dhuru
 
Upvote 0
Top