From ed815718f2c29c9867da39246d436d47dde7a893 Mon Sep 17 00:00:00 2001 From: Jonathan Payne Date: Sun, 11 Dec 2011 03:11:42 -0800 Subject: [PATCH] titlesafe stuff. --- Themes/_fallback/Scripts/01 alias.lua | 18 ++++++++++++++++++ 1 file changed, 18 insertions(+) diff --git a/Themes/_fallback/Scripts/01 alias.lua b/Themes/_fallback/Scripts/01 alias.lua index 4a3dada4eb..2dbaab71a4 100644 --- a/Themes/_fallback/Scripts/01 alias.lua +++ b/Themes/_fallback/Scripts/01 alias.lua @@ -19,6 +19,24 @@ _screen = { cy = SCREEN_CENTER_Y } +-- Title & Action safe calculation, probably messy. Uses microsofts suggestion of 85% ( 7.5% per side ) +function GetTitleSafeH( fPerc ) + return math.floor( SCREEN_RIGHT * fPerc ); +end + +function GetTitleSafeV( fPerc ) + return math.floor( SCREEN_BOTTOM * fPerc ); +end + +SAFE_WIDTH = GetTitleSafeH(0.075); +SAFE_HEIGHT = GetTitleSafeV(0.075); + +_safe = { + w = GetTitleSafeH(0.075); + h = GetTitleSafeV(0.075); +} + + --[[ compatibility aliases ]] --[[ Actor ]]