Skip to content

Commit

Permalink
Text: metr.typeBounds -> metr.bounds.
Browse files Browse the repository at this point in the history
Failed to get refactored with @a3dcc893bccaa3353e5c58db1b19d0192c8a98cb.

See #2.
  • Loading branch information
torque authored and line0 committed Sep 14, 2015
1 parent e0292d1 commit 9b2fd18
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions l0/ASSFoundation/Section/Text.lua
Original file line number Diff line number Diff line change
Expand Up @@ -62,8 +62,8 @@ return function(ASS, ASSFInst, yutilsMissingMsg, createASSClass, re, util, unico
local metr, tagList, shape = self:getTextMetrics(true)
local drawing, an = ASS.Draw.DrawingBase{str=shape}, tagList.tags.align:getSet()
-- fix position based on aligment
drawing:sub(not an.left and (metr.width-metr.typeBounds.width) / (an.centerH and 2 or 1) or 0,
not an.top and (metr.height-metr.typeBounds.height) / (an.centerV and 2 or 1) or 0
drawing:sub(not an.left and (metr.width-metr.bounds.w) / (an.centerH and 2 or 1) or 0,
not an.top and (metr.height-metr.bounds.h) / (an.centerV and 2 or 1) or 0
)

-- rotate shape
Expand Down

0 comments on commit 9b2fd18

Please sign in to comment.