Skip to content

Commit 9b2fd18

Browse files
torqueline0
authored andcommitted
Text: metr.typeBounds -> metr.bounds.
Failed to get refactored with @a3dcc893bccaa3353e5c58db1b19d0192c8a98cb. See #2.
1 parent e0292d1 commit 9b2fd18

1 file changed

Lines changed: 2 additions & 2 deletions

File tree

l0/ASSFoundation/Section/Text.lua

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -62,8 +62,8 @@ return function(ASS, ASSFInst, yutilsMissingMsg, createASSClass, re, util, unico
6262
local metr, tagList, shape = self:getTextMetrics(true)
6363
local drawing, an = ASS.Draw.DrawingBase{str=shape}, tagList.tags.align:getSet()
6464
-- fix position based on aligment
65-
drawing:sub(not an.left and (metr.width-metr.typeBounds.width) / (an.centerH and 2 or 1) or 0,
66-
not an.top and (metr.height-metr.typeBounds.height) / (an.centerV and 2 or 1) or 0
65+
drawing:sub(not an.left and (metr.width-metr.bounds.w) / (an.centerH and 2 or 1) or 0,
66+
not an.top and (metr.height-metr.bounds.h) / (an.centerV and 2 or 1) or 0
6767
)
6868

6969
-- rotate shape

0 commit comments

Comments
 (0)