remove chinese

This commit is contained in:
Thomas Avé 2023-05-08 13:41:39 +02:00
parent fab7eb39b5
commit c02ae7cc40
1 changed files with 0 additions and 1 deletions

View File

@ -658,7 +658,6 @@ function render_elements(master_ass)
buttontext = buttontext:gsub(':%((.?.?.?)%) unknown ', ':%(%1%)') --gsub('%) unknown %(\'', '')
local maxchars = element.layout.button.maxchars
-- 认为1个中文字符约等于1.5个英文字符
local charcount = (buttontext:len() + select(2, buttontext:gsub('[^\128-\193]', ''))*2) / 3
if not (maxchars == nil) and (charcount > maxchars) then
local limit = math.max(0, maxchars - 3)