D Deleted member 103 Guest Nov 5, 2014 #1 Hi, in B4a there for the Button Property "Disabled Drawable", how can you recreate this Property in B4i?
Hi, in B4a there for the Button Property "Disabled Drawable", how can you recreate this Property in B4i?
Erel B4X founder Staff member Licensed User Longtime User Nov 5, 2014 #2 iOS views do not use drawables. If you are using a system button then the text color will change automatically when the button is disabled. Do you want to change the text color for a disabled custom button? Upvote 0
iOS views do not use drawables. If you are using a system button then the text color will change automatically when the button is disabled. Do you want to change the text color for a disabled custom button?
D Deleted member 103 Guest Nov 5, 2014 #3 Erel said: iOS views do not use drawables. If you are using a system button then the text color will change automatically when the button is disabled. Do you want to change the text color for a disabled custom button? Click to expand... No, the Bitmap. Upvote 0
Erel said: iOS views do not use drawables. If you are using a system button then the text color will change automatically when the button is disabled. Do you want to change the text color for a disabled custom button? Click to expand... No, the Bitmap.
Erel B4X founder Staff member Licensed User Longtime User Nov 5, 2014 #4 You can use this sub to set the background image: Code: Copy 'state: 0 - normal, 1 - highlighted, 2 - disabled Sub SetBackgroundImage(b As Button, bmp As Bitmap, state As Int) Dim no As NativeObject = b no.RunMethod("setBackgroundImage:forState:", Array(bmp, state)) End Sub Upvote 0
You can use this sub to set the background image: Code: Copy 'state: 0 - normal, 1 - highlighted, 2 - disabled Sub SetBackgroundImage(b As Button, bmp As Bitmap, state As Int) Dim no As NativeObject = b no.RunMethod("setBackgroundImage:forState:", Array(bmp, state)) End Sub
A Allan Cameron Member Licensed User Longtime User Dec 10, 2014 #6 Erel--How do I set the button text color in code. There does not seem to be a .TextColor setting Upvote 0
Erel B4X founder Staff member Licensed User Longtime User Dec 10, 2014 #7 1. This is a community forum. Please don't limit your questions to a single member. 2. Please start a new thread for this question. Upvote 0
1. This is a community forum. Please don't limit your questions to a single member. 2. Please start a new thread for this question.