B4J Question [ABMaterial] how to reduce vertical space in a control?

rbirago

Active Member
Licensed User
Longtime User
Sometimes (specially for a small device) the screen space is precious.
As you can see in this sample:
control vertical spacing.png

the question is: how to reduce the vertical space between the title of field and the content and between content and lower underline?
It is not a control margin/padding, because margin/padding is the space between controls. I mean spacing between the components of the control itself.
Thank you.
Roberto
 

Cableguy

Expert
Licensed User
Longtime User
Most visual effects/changes in ABMATERIAL are made using the components Theme, or directly within its properties. Further customization can be achieved using CSS but you really need to know your stuff.
 
Upvote 0

rbirago

Active Member
Licensed User
Longtime User
unfortunately I have not found theme's properties (ABMCombo, ABMInput) to adjust vertical space between content and header/footer of the control. Any other suggestion?
 
Upvote 0

Cableguy

Expert
Licensed User
Longtime User
As I said, and as @alwaysbusy often says...
"It's AB Material, not AB Whatever you want"
It follows Google's Material visual Guide Lines!
So your only solution is to try CSS...
 
Upvote 0

alwaysbusy

Expert
Licensed User
Longtime User
These type of components with animation have a rather complex CSS system behind them. There is .Narrow on some components you can try:

B4X:
Dim inp1 As ABMInput
inp1.Initialize(page, "inp1new", ABM.INPUT_PASSWORD, "Nieuw paswoord (minimum 8 characters)", False, "onetwopwd")
inp1.Narrow = True

Alwaysbusy
 
Upvote 0

Harris

Expert
Licensed User
Longtime User
Yes, small devices are a be-otch. (on some occasions - cards vrs table for example).
I encounter this all the time with ABM. The trick is - not to fight it - but accept it.
Otherwise, you descend down the rabbit hole of no return.... wasting precious dev time.

What is "good enough"? The alternative is many more magnitudes of what we have here (ABM).
 
Upvote 0
Top