added skin directives for the text object

This commit is contained in:
Kenny Shields 2013-11-09 09:30:08 -05:00
parent 973bb1b8ef
commit 69d0988f5c
2 changed files with 20 additions and 0 deletions

View File

@ -38,6 +38,23 @@ function newobject:initialize()
self.linksenabled = false
self.OnClickLink = nil
local skin = loveframes.util.GetActiveSkin()
local directives = skin.directives
if directives then
local text_default_color = directives.text_default_color
local text_default_shadowcolor = directives.text_default_shadowcolor
local text_default_font = directives.text_default_font
if text_default_color then
self.defaultcolor = text_default_color
end
if text_default_shadowcolor then
self.shadowcolor = text_default_shadowcolor
end
if text_default_font then
self.font = text_default_font
end
end
end
--[[---------------------------------------------------------

View File

@ -15,6 +15,9 @@ local smallfont = love.graphics.newFont(10)
local imagebuttonfont = love.graphics.newFont(15)
local bordercolor = {143, 143, 143, 255}
-- add skin directives to this table
skin.directives = {}
-- controls
skin.controls = {}