mirror of
https://github.com/cyberarm/cyberarm_engine.git
synced 2026-05-06 16:08:16 +00:00
Fixed button image off center if button has margin left/top
This commit is contained in:
@@ -23,8 +23,8 @@ module CyberarmEngine
|
||||
|
||||
def draw_image
|
||||
@image.draw(
|
||||
styled(:border_thickness_left) + styled(:padding_left) + @x,
|
||||
styled(:border_thickness_top) + styled(:padding_top) + @y,
|
||||
styled(:border_thickness_left) + styled(:margin_left) + styled(:padding_left) + @x,
|
||||
styled(:border_thickness_top) + styled(:margin_top) + styled(:padding_top) + @y,
|
||||
@z + 2,
|
||||
@scale_x, @scale_y, @text.color
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user