Skip to content

Commit 2a379ab

Browse files
committed
show the wrong line started with line 1 instead of line 0, as Aegisub
1 parent 3837937 commit 2a379ab

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ASFMKV_dev.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -380,7 +380,7 @@ def eventTagsSplit(assInfo: dict, changeOnly: bool = True) -> dict:
380380
eventfont = assInfo['Styles'].get(events[i]['Style'].lstrip('*'))
381381
if eventfont is None:
382382
if len(re.sub(effectDel, '', eventftext)) > 0:
383-
raise Exception('未定义 行{0} 所用样式"{1}\"'.format(i, events[i]['Style'].lstrip('*')))
383+
raise Exception('未定义 行{0} 所用样式"{1}\"'.format(i+1, events[i]['Style'].lstrip('*')))
384384
continue
385385

386386
# 粗体、斜体标签处理
@@ -1124,7 +1124,7 @@ def outputSameLength(s: str) -> str:
11241124
# { 字体绝对路径: { 字体索引: (字体名称(dict), 斜体, 粗体, 字体样式(dict), 字体家族名称(dict)) } }
11251125
# dupfont 词典结构
11261126
# { 重复字体名称 : [ 字体1绝对路径, 字体2绝对路径, ... ] }
1127-
def fontProgress(fl: list, font_info: list = [{}, {}, {}, [], {}], overwrite: bool = False, usingCache: bool = True) -> list:
1127+
def fontProgress(fl: list, font_info: list = [{}, {}, {}, {}, {}], overwrite: bool = False, usingCache: bool = True) -> list:
11281128
"""
11291129
字体处理部分
11301130
@@ -4039,7 +4039,7 @@ def loadMain(reload: bool = False):
40394039
if not reload:
40404040
if not o_fontload:
40414041
font_list = getFontFileList(fontin)
4042-
font_info = fontProgress(font_list, [{}, {}, {}, [], {}], f_priority)
4042+
font_info = fontProgress(font_list, [{}, {}, {}, {}, {}], f_priority)
40434043
del font_list
40444044
mkvmv = '\n\033[1;33m没有检测到 mkvmerge\033[0m'
40454045

0 commit comments

Comments
 (0)