tooltip: Cleanup the margin API.
Make it closer to other APIs across Awesome.
This commit is contained in:
parent
3380fd85fc
commit
68bfde45e1
|
@ -398,8 +398,13 @@ end
|
||||||
-- @tparam number New margins value
|
-- @tparam number New margins value
|
||||||
|
|
||||||
function tooltip:set_margin_leftright(val)
|
function tooltip:set_margin_leftright(val)
|
||||||
self.marginbox.left = val
|
self.marginbox:set_left(val)
|
||||||
self.marginbox.right = val
|
self.marginbox:set_right(val)
|
||||||
|
end
|
||||||
|
|
||||||
|
--TODO v5 deprecate this
|
||||||
|
function tooltip:set_margins_leftright(val)
|
||||||
|
self:set_margin_leftright(val)
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Set the margins around the top and bottom of the tooltip textbox
|
--- Set the margins around the top and bottom of the tooltip textbox
|
||||||
|
@ -409,8 +414,13 @@ end
|
||||||
-- @tparam number New margins value
|
-- @tparam number New margins value
|
||||||
|
|
||||||
function tooltip:set_margin_topbottom(val)
|
function tooltip:set_margin_topbottom(val)
|
||||||
self.marginbox.top = val
|
self.marginbox:set_top(val)
|
||||||
self.marginbox.bottom = val
|
self.marginbox:set_bottom(val)
|
||||||
|
end
|
||||||
|
|
||||||
|
--TODO v5 deprecate this
|
||||||
|
function tooltip:set_margins_topbottom(val)
|
||||||
|
self:set_margin_topbottom(val)
|
||||||
end
|
end
|
||||||
|
|
||||||
--- Add tooltip to an object.
|
--- Add tooltip to an object.
|
||||||
|
|
Loading…
Reference in New Issue