I am using a 9-slice image for a button but the button has a drop shadow on it. Therefore the slices look like 50%, 10%, 40%
The bottom 40% will leave a gap in column 1 and 3. Am I doing something wrong?
I am using a 100x100px .png
local function buildStartButton2() local nineSliceOptions = { frames = { { x=0, y=0, width=50, height=50 }, { x=50, y=0, width=10, height=50 }, { x=60, y=0, width=40, height=50 }, { x=0, y=50, width=50, height=10 }, { x=50, y=50, width=10, height=10 }, { x=60, y=50, width=40, height=10 }, { x=0, y=60, width=50, height=40 }, { x=50, y=60, width=10, height=40 }, { x=60, y=60, width=40, height=40 }, { x=0, y=0, width=50, height=50 }, { x=50, y=0, width=10, height=50 }, { x=60, y=0, width=40, height=50 }, { x=0, y=50, width=50, height=10 }, { x=50, y=50, width=10, height=10 }, { x=60, y=50, width=40, height=10 }, { x=0, y=60, width=50, height=40 }, { x=50, y=60, width=10, height=40 }, { x=60, y=60, width=40, height=40 } }, sheetContentWidth = 100, sheetContentHeight = 100 } local buttonSheet = graphics.newImageSheet( "art/menus/testBox.png", nineSliceOptions ) local myButton = widget.newButton { width = 270, height = 270, sheet = buttonSheet, topLeftFrame = 1, topMiddleFrame = 2, topRightFrame = 3, middleLeftFrame = 4, middleFrame = 5, middleRightFrame = 6, bottomLeftFrame = 7, bottomMiddleFrame = 8, bottomRightFrame = 9, topLeftOverFrame = 10, topMiddleOverFrame = 11, topRightOverFrame = 12, middleLeftOverFrame = 13, middleOverFrame = 14, middleRightOverFrame = 15, bottomLeftOverFrame = 16, bottomMiddleOverFrame = 17, bottomRightOverFrame = 18, label = "button" } myButton:setLabel( "9-Slice" ) end
Thanks for any help you can give me!
Gullie