Fix inline-fx parsing in karaskel and handling in kara-templater. (Fixes #577)
Originally committed to SVN as r1783.
This commit is contained in:
parent
d4a35fc03b
commit
15ce07e803
2 changed files with 3 additions and 3 deletions
|
@ -136,7 +136,7 @@ function parse_template(meta, styles, line, templates, mods)
|
||||||
addtext = true,
|
addtext = true,
|
||||||
keeptags = false,
|
keeptags = false,
|
||||||
fxgroup = nil,
|
fxgroup = nil,
|
||||||
inline_fx = nil,
|
fx = nil,
|
||||||
multi = false,
|
multi = false,
|
||||||
isline = false,
|
isline = false,
|
||||||
perchar = false,
|
perchar = false,
|
||||||
|
@ -634,7 +634,7 @@ function apply_one_syllable_template(syl, line, template, tenv, varctx, subs, sk
|
||||||
aegisub.debug.out(5, "Applying template to one syllable with text: %s\n", syl.text)
|
aegisub.debug.out(5, "Applying template to one syllable with text: %s\n", syl.text)
|
||||||
|
|
||||||
-- Check for right inline_fx
|
-- Check for right inline_fx
|
||||||
if t.inline_fx and t.inline_fx ~= syl.inline_fx then
|
if t.fx and t.fx ~= syl.inline_fx then
|
||||||
aegisub.debug.out(5, "Syllable has wrong inline-fx (wanted '%s', got '%s'), skipping.\n", t.inline_fx, syl.inline_fx)
|
aegisub.debug.out(5, "Syllable has wrong inline-fx (wanted '%s', got '%s'), skipping.\n", t.inline_fx, syl.inline_fx)
|
||||||
return false
|
return false
|
||||||
end
|
end
|
||||||
|
|
|
@ -137,7 +137,7 @@ function karaskel.preproc_line_text(meta, styles, line)
|
||||||
local syl = kara[i]
|
local syl = kara[i]
|
||||||
|
|
||||||
-- Detect any inline-fx tags
|
-- Detect any inline-fx tags
|
||||||
local inline_fx = syl.text:match("%{.*\\%-([^}\\]-)")
|
local inline_fx = syl.text:match("%{.*\\%-([^}\\]+)")
|
||||||
if inline_fx then
|
if inline_fx then
|
||||||
cur_inline_fx = inline_fx
|
cur_inline_fx = inline_fx
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue