I'm trying to build a tabbar in corona only using custom graphics for up/down states, and background. I find that corona adds left and right padding as the attached image & basic setup below shows. The images are both 32x32 and should fill the space exactly, instead there are black lines at either end and the buttons are forced to overlap.
I've tried every option available in the docs but with no success. Does anyone know if there's an undocumented option that overrides the automatic positioning of tabbar buttons?
-- table to setup buttons
local tabButtons = {
{ up="icon1.png", down="icon1-down.png", width = 32, height = 32, cornerRadius=0, onPress=onFirstView, selected=true },
{ up="icon2.png", down="icon2-down.png", width = 32, height = 32, cornerRadius=0, onPress=onSecondView },
}
-- create the actual tabBar widget
local tabBar = widget.newTabBar{
width=64, height=32,
buttons = tabButtons
}
Here's the output:
This is a known bug and is being addressed.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With