mirror of https://github.com/odrling/Aegisub
Compare commits
37 Commits
Author | SHA1 | Date |
---|---|---|
odrling | b33ccb591d | |
odrling | eab9e2cc09 | |
odrling | 4b2f9d864a | |
odrling | a08026ba41 | |
odrling | 5ae8bfe521 | |
odrling | 4cf1eb084f | |
odrling | 6d8be650c7 | |
odrling | 37588eb75a | |
odrling | 49503516fb | |
odrling | 8ca0bfd366 | |
odrling | f996638648 | |
odrling | a68f670908 | |
odrling | 5108535f52 | |
odrling | a958faea51 | |
odrling | 0953d23168 | |
odrling | 3f2a16c2b3 | |
RhiobeT | ac88140aaa | |
Jeanjean Pierre | 2ac564092d | |
odrling | 8ab7a886d3 | |
odrling | 7ec32f8b2e | |
odrling | fbe26ad6c2 | |
odrling | 0f1e16c51b | |
odrling | bd6383a4cc | |
odrling | 78097c63f0 | |
odrling | 0146c2e13f | |
odrling | deaf588af9 | |
odrling | 30f2d5ac09 | |
odrling | ce60cfed61 | |
odrling | 4ac55501c3 | |
odrling | 155cd9937a | |
odrling | 7bd37b6ca1 | |
odrling | ebc0a31d48 | |
odrling | 03d5ff6980 | |
Vincent Wong | 35cd0322ca | |
Vincent Wong | 44bda6e5d9 | |
Vincent Wong | a74323803b | |
Vincent Wong | f1d17ac6b7 |
|
@ -0,0 +1,9 @@
|
||||||
|
#!/bin/bash
|
||||||
|
|
||||||
|
dest="ftp://shelter.mahoro-net.org/aegisub-japan7"
|
||||||
|
tag=$(git describe --exact-match)
|
||||||
|
[ "$tag" ] || exit
|
||||||
|
|
||||||
|
curl -T 'packages\win_installer\output\Aegisub-Japan7-x64.exe' --user $FTP_USER:$FTP_PASS "$dest/Aegisub-Japan7-x64-${tag#v}.exe"
|
||||||
|
printf "${tag#v}\n$(git tag -l --format='%contents' $tag)" > latest
|
||||||
|
curl -T latest --user "$FTP_USER:$FTP_PASS" "$dest/"
|
68
.travis.yml
68
.travis.yml
|
@ -1,68 +0,0 @@
|
||||||
sudo: required
|
|
||||||
dist: trusty
|
|
||||||
language: cpp
|
|
||||||
|
|
||||||
git:
|
|
||||||
submodules: false
|
|
||||||
|
|
||||||
addons:
|
|
||||||
apt:
|
|
||||||
sources:
|
|
||||||
- ubuntu-toolchain-r-test
|
|
||||||
packages:
|
|
||||||
- libasound2-dev
|
|
||||||
- libfftw3-dev
|
|
||||||
- libhunspell-dev
|
|
||||||
- yasm
|
|
||||||
- libfribidi-dev
|
|
||||||
- libass-dev
|
|
||||||
- libicu-dev
|
|
||||||
- luarocks
|
|
||||||
- g++-5
|
|
||||||
|
|
||||||
matrix:
|
|
||||||
include:
|
|
||||||
- compiler: gcc
|
|
||||||
env: BOOST_VERSION=55
|
|
||||||
- compiler: gcc
|
|
||||||
env: BOOST_VERSION=60
|
|
||||||
before_install:
|
|
||||||
- sudo update-alternatives --install /usr/bin/gcc gcc /usr/bin/gcc-5 60 --slave /usr/bin/g++ g++ /usr/bin/g++-5 --slave /usr/bin/gcov gcov /usr/bin/gcov-5
|
|
||||||
|
|
||||||
install:
|
|
||||||
# Can't install these via the apt addon due to the whitelist
|
|
||||||
- sudo apt-get install -y -qq libffms2-dev libwxgtk3.0-dev libuchardet-dev
|
|
||||||
|
|
||||||
- sudo pip install cpp-coveralls
|
|
||||||
- sudo luarocks install busted > /dev/null
|
|
||||||
- sudo luarocks install moonscript > /dev/null
|
|
||||||
- sudo luarocks install uuid > /dev/null
|
|
||||||
|
|
||||||
- git submodule --quiet init
|
|
||||||
- git submodule --quiet update vendor/googletest
|
|
||||||
|
|
||||||
- cd vendor
|
|
||||||
- rm -rf boost
|
|
||||||
- wget http://sourceforge.net/projects/boost/files/boost/1.${BOOST_VERSION}.0/boost_1_${BOOST_VERSION}_0.tar.bz2/download
|
|
||||||
- tar xjf download
|
|
||||||
- mv boost_1_${BOOST_VERSION}_0 boost
|
|
||||||
- cd boost
|
|
||||||
- ./bootstrap.sh
|
|
||||||
- ./b2 -j3 -layout=system threading=multi cxxflags=-std=c++11 link=shared variant=release --without-python --without-iostreams --without-serialization --without-graph --without-log --without-math --without-signals --without-test --without-wave --without-mpi --without-program_options --without-graph_parallel --without-context --without-coroutine --without-random --without-timer --without-date_time
|
|
||||||
- cd ../..
|
|
||||||
|
|
||||||
script:
|
|
||||||
- export CPATH=$(pwd)/vendor/boost
|
|
||||||
- export LD_LIBRARY_PATH=$(pwd)/vendor/boost/stage/lib:$LD_LIBRARY_PATH
|
|
||||||
- export CPPFLAGS="-fprofile-arcs -ftest-coverage"
|
|
||||||
- export LIBS="-lgcov"
|
|
||||||
- autoreconf -if
|
|
||||||
- ./configure BOOST_LDFLAGS="-L$(pwd)/vendor/boost/stage/lib" --enable-debug || cat config.log
|
|
||||||
- make -j3 all test
|
|
||||||
- coveralls --exclude vendor --exclude src --exclude build --exclude tools --exclude libaegisub/windows > /dev/null
|
|
||||||
|
|
||||||
notifications:
|
|
||||||
email:
|
|
||||||
- on_success: change
|
|
||||||
- on_failure: change
|
|
||||||
|
|
|
@ -1,6 +1,6 @@
|
||||||
Microsoft Visual Studio Solution File, Format Version 12.00
|
Microsoft Visual Studio Solution File, Format Version 12.00
|
||||||
# Visual Studio 2013
|
# Visual Studio 2013
|
||||||
VisualStudioVersion = 12.0.30324.0
|
VisualStudioVersion = 15.0.28307.168
|
||||||
MinimumVisualStudioVersion = 10.0.40219.1
|
MinimumVisualStudioVersion = 10.0.40219.1
|
||||||
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Aegisub", "build\Aegisub\Aegisub.vcxproj", "{9DDDB9E5-E4A1-423D-A224-F6D4E5AAC06A}"
|
Project("{8BC9CEB8-8B4A-11D0-8D11-00A0C91BC942}") = "Aegisub", "build\Aegisub\Aegisub.vcxproj", "{9DDDB9E5-E4A1-423D-A224-F6D4E5AAC06A}"
|
||||||
ProjectSection(ProjectDependencies) = postProject
|
ProjectSection(ProjectDependencies) = postProject
|
||||||
|
|
|
@ -9,6 +9,7 @@ HAVE_OPENAL = @with_openal@
|
||||||
HAVE_OSS = @with_oss@
|
HAVE_OSS = @with_oss@
|
||||||
HAVE_PORTAUDIO = @with_portaudio@
|
HAVE_PORTAUDIO = @with_portaudio@
|
||||||
HAVE_UCHARDET = @with_uchardet@
|
HAVE_UCHARDET = @with_uchardet@
|
||||||
|
SYSTEM_LUAJIT = @with_system_luajit@
|
||||||
|
|
||||||
##############
|
##############
|
||||||
# BUILD OUTPUT
|
# BUILD OUTPUT
|
||||||
|
|
|
@ -0,0 +1,85 @@
|
||||||
|
image: Visual Studio 2017
|
||||||
|
|
||||||
|
install:
|
||||||
|
- cd %APPVEYOR_BUILD_FOLDER%
|
||||||
|
- git submodule update --init --recursive
|
||||||
|
- set PATH=C:\gettext\bin;"C:\Program Files (x86)\Inno Setup 5";C:\yasm;%PATH%
|
||||||
|
- mkdir C:\yasm
|
||||||
|
- curl -o "C:\yasm\yasm.exe" http://www.tortall.net/projects/yasm/releases/yasm-1.3.0-win64.exe
|
||||||
|
- mkdir C:\gettext
|
||||||
|
- curl -L -o "C:\gettext.zip" https://github.com/vslavik/gettext-tools-windows/releases/download/v0.20.1/gettext-tools-windows-0.20.1.zip
|
||||||
|
- cd C:\gettext
|
||||||
|
- 7z x C:\gettext.zip
|
||||||
|
|
||||||
|
build_script:
|
||||||
|
- cd %APPVEYOR_BUILD_FOLDER%
|
||||||
|
- MSBuild.exe Aegisub.sln /target:BuildTasks
|
||||||
|
- MSBuild.exe Aegisub.sln /m /p:Configuration=Release /p:Platform=x64
|
||||||
|
|
||||||
|
after_build:
|
||||||
|
- curl -o "C:\aegisub-codecs.zip" http://mugen.karaokes.moe/downloads/aegisub-codecs.zip
|
||||||
|
- cd %APPVEYOR_BUILD_FOLDER%
|
||||||
|
- msgfmt.exe -o po\ar.mo po\ar.po
|
||||||
|
- msgfmt.exe -o po\wxstd-ar.mo vendor\wxWidgets\locale\ar.po
|
||||||
|
- msgfmt.exe -o po\bg.mo po\bg.po
|
||||||
|
- msgfmt.exe -o po\ca.mo po\ca.po
|
||||||
|
- msgfmt.exe -o po\wxstd-ca.mo vendor\wxWidgets\locale\ca.po
|
||||||
|
- msgfmt.exe -o po\cs.mo po\cs.po
|
||||||
|
- msgfmt.exe -o po\wxstd-cs.mo vendor\wxWidgets\locale\cs.po
|
||||||
|
- msgfmt.exe -o po\da.mo po\da.po
|
||||||
|
- msgfmt.exe -o po\wxstd-da.mo vendor\wxWidgets\locale\da.po
|
||||||
|
- msgfmt.exe -o po\de.mo po\de.po
|
||||||
|
- msgfmt.exe -o po\wxstd-de.mo vendor\wxWidgets\locale\de.po
|
||||||
|
- msgfmt.exe -o po\el.mo po\el.po
|
||||||
|
- msgfmt.exe -o po\wxstd-el.mo vendor\wxWidgets\locale\el.po
|
||||||
|
- msgfmt.exe -o po\es.mo po\es.po
|
||||||
|
- msgfmt.exe -o po\wxstd-es.mo vendor\wxWidgets\locale\es.po
|
||||||
|
- msgfmt.exe -o po\eu.mo po\eu.po
|
||||||
|
- msgfmt.exe -o po\wxstd-eu.mo vendor\wxWidgets\locale\eu.po
|
||||||
|
- msgfmt.exe -o po\fa.mo po\fa.po
|
||||||
|
- msgfmt.exe -o po\fi.mo po\fi.po
|
||||||
|
- msgfmt.exe -o po\wxstd-fi.mo vendor\wxWidgets\locale\fi.po
|
||||||
|
- msgfmt.exe -o po\fr_FR.mo po\fr_FR.po
|
||||||
|
- msgfmt.exe -o po\wxstd-fr.mo vendor\wxWidgets\locale\fr.po
|
||||||
|
- msgfmt.exe -o po\gl.mo po\gl.po
|
||||||
|
- msgfmt.exe -o po\wxstd-gl_ES.mo vendor\wxWidgets\locale\gl_ES.po
|
||||||
|
- msgfmt.exe -o po\hu.mo po\hu.po
|
||||||
|
- msgfmt.exe -o po\wxstd-hu.mo vendor\wxWidgets\locale\hu.po
|
||||||
|
- msgfmt.exe -o po\id.mo po\id.po
|
||||||
|
- msgfmt.exe -o po\wxstd-id.mo vendor\wxWidgets\locale\id.po
|
||||||
|
- msgfmt.exe -o po\it.mo po\it.po
|
||||||
|
- msgfmt.exe -o po\wxstd-it.mo vendor\wxWidgets\locale\it.po
|
||||||
|
- msgfmt.exe -o po\ja.mo po\ja.po
|
||||||
|
- msgfmt.exe -o po\wxstd-ja.mo vendor\wxWidgets\locale\ja.po
|
||||||
|
- msgfmt.exe -o po\ko.mo po\ko.po
|
||||||
|
- msgfmt.exe -o po\wxstd-ko_KR.mo vendor\wxWidgets\locale\ko_KR.po
|
||||||
|
- msgfmt.exe -o po\nl.mo po\nl.po
|
||||||
|
- msgfmt.exe -o po\wxstd-nl.mo vendor\wxWidgets\locale\nl.po
|
||||||
|
- msgfmt.exe -o po\pl.mo po\pl.po
|
||||||
|
- msgfmt.exe -o po\wxstd-pl.mo vendor\wxWidgets\locale\pl.po
|
||||||
|
- msgfmt.exe -o po\pt_BR.mo po\pt_BR.po
|
||||||
|
- msgfmt.exe -o po\wxstd-pt_BR.mo vendor\wxWidgets\locale\pt_BR.po
|
||||||
|
- msgfmt.exe -o po\pt_PT.mo po\pt_PT.po
|
||||||
|
- msgfmt.exe -o po\wxstd-pt.mo vendor\wxWidgets\locale\pt.po
|
||||||
|
- msgfmt.exe -o po\ru.mo po\ru.po
|
||||||
|
- msgfmt.exe -o po\wxstd-ru.mo vendor\wxWidgets\locale\ru.po
|
||||||
|
- msgfmt.exe -o po\sr_RS.mo po\sr_RS.po
|
||||||
|
- msgfmt.exe -o po\sr_RS@latin.mo po\sr_RS@latin.po
|
||||||
|
- msgfmt.exe -o po\uk_UA.mo po\uk_UA.po
|
||||||
|
- msgfmt.exe -o po\wxstd-uk_UA.mo vendor\wxWidgets\locale\uk_UA.po
|
||||||
|
- msgfmt.exe -o po\vi.mo po\vi.po
|
||||||
|
- msgfmt.exe -o po\wxstd-vi.mo vendor\wxWidgets\locale\vi.po
|
||||||
|
- msgfmt.exe -o po\zh_CN.mo po\zh_CN.po
|
||||||
|
- msgfmt.exe -o po\wxstd-zh_CN.mo vendor\wxWidgets\locale\zh_CN.po
|
||||||
|
- msgfmt.exe -o po\zh_TW.mo po\zh_TW.po
|
||||||
|
- msgfmt.exe -o po\wxstd-zh_TW.mo vendor\wxWidgets\locale\zh_TW.po
|
||||||
|
- 7z x "C:\aegisub-codecs.zip"
|
||||||
|
- cd packages\win_installer
|
||||||
|
- iscc aegisub3.iss
|
||||||
|
- cd ..\..
|
||||||
|
|
||||||
|
on_success:
|
||||||
|
- IF DEFINED APPVEYOR_REPO_TAG_NAME bash.exe ".ci\upload_win_installer.sh"
|
||||||
|
|
||||||
|
artifacts:
|
||||||
|
- path: packages\win_installer\output\Aegisub-Japan7-x64.exe
|
|
@ -12,10 +12,16 @@ DATA_AUTOMATION_INSTALLED = $(addprefix $(DESTDIR)$(P_DATA)/automation/, $(DATA_
|
||||||
$(DESTDIR)$(P_DATA)/automation/%: $(d)%
|
$(DESTDIR)$(P_DATA)/automation/%: $(d)%
|
||||||
$(MKDIR_INSTALL)
|
$(MKDIR_INSTALL)
|
||||||
|
|
||||||
aegisub-lua_OBJ := $(d)tests/aegisub.o $(TOP)lib/libaegisub.a $(TOP)lib/libluabins.a $(LIBS_LUA)
|
aegisub-lua_OBJ := $(d)tests/aegisub.o $(TOP)lib/libaegisub.a $(TOP)lib/libluabins.a
|
||||||
aegisub-lua_CPPFLAGS := $(CPPFLAGS_BOOST) $(CFLAGS_LUA) -I$(TOP)libaegisub/include -I$(TOP)src $(CXXFLAGS_WX)
|
aegisub-lua_CPPFLAGS := $(CPPFLAGS_BOOST) $(CFLAGS_LUA) -I$(TOP)libaegisub/include -I$(TOP)src $(CXXFLAGS_WX)
|
||||||
aegisub-lua_LIBS := $(LIBS_WX) $(LIBS_BOOST) $(LIBS_ICU) $(LIBS_PTHREAD)
|
aegisub-lua_LIBS := $(LIBS_WX) $(LIBS_BOOST) $(LIBS_ICU) $(LIBS_PTHREAD)
|
||||||
|
|
||||||
|
ifeq (no, $(SYSTEM_LUAJIT))
|
||||||
|
aegisub-lua_OBJ += $(LIBS_LUA)
|
||||||
|
else
|
||||||
|
aegisub-lua_LIBS += $(LIBS_LUA)
|
||||||
|
endif
|
||||||
|
|
||||||
PROGRAM += $(d)aegisub-lua
|
PROGRAM += $(d)aegisub-lua
|
||||||
|
|
||||||
test-automation: $(PROGRAM)
|
test-automation: $(PROGRAM)
|
||||||
|
|
|
@ -0,0 +1,177 @@
|
||||||
|
local tr = aegisub.gettext
|
||||||
|
|
||||||
|
script_name = tr"Duetto Meika"
|
||||||
|
script_description = tr"The ultimate tool for karaoke duets"
|
||||||
|
script_author = "amoethyst"
|
||||||
|
|
||||||
|
include("utils.lua")
|
||||||
|
|
||||||
|
|
||||||
|
function replace_style(line, style_name, style_string)
|
||||||
|
before_style, after_style = line.text:match("^(.-{[^}]-)\\?s:".. style_name .."(.*)$")
|
||||||
|
return before_style .. style_string .. after_style
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function duetto(subs, sel)
|
||||||
|
styles = {}
|
||||||
|
|
||||||
|
-- create the style map
|
||||||
|
for _, line in ipairs(subs) do
|
||||||
|
if line.class == "style" then
|
||||||
|
styles[line.name] = line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
-- duetto~
|
||||||
|
for _, i in ipairs(sel) do
|
||||||
|
line = subs[i]
|
||||||
|
|
||||||
|
current_style = styles[line.style]
|
||||||
|
-- match every `s:` marker
|
||||||
|
for style_name in line.text:gmatch("{[^}]*s:([^}\\]*)[^}]*}") do
|
||||||
|
if style_name ~= current_style.name then
|
||||||
|
|
||||||
|
style = styles[style_name]
|
||||||
|
-- build the tags to use the new style
|
||||||
|
style_string = ""
|
||||||
|
if current_style.color1 ~= style.color1 then
|
||||||
|
style_string = style_string .. "\\c" .. style.color1
|
||||||
|
end
|
||||||
|
if current_style.color2 ~= style.color2 then
|
||||||
|
style_string = style_string .. "\\2c" .. style.color2
|
||||||
|
end
|
||||||
|
if current_style.color3 ~= style.color3 then
|
||||||
|
style_string = style_string .. "\\3c" .. style.color3
|
||||||
|
end
|
||||||
|
if current_style.color4 ~= style.color4 then
|
||||||
|
style_string = style_string .. "\\4c" .. style.color4
|
||||||
|
end
|
||||||
|
|
||||||
|
-- set style
|
||||||
|
line.text = replace_style(line, style_name, style_string)
|
||||||
|
current_style = style
|
||||||
|
else
|
||||||
|
-- remove marker to not break everything
|
||||||
|
line.text = replace_style(line, style_name, "")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
subs[i] = line
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.set_undo_point(script_name)
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function test_colors(c1, c2)
|
||||||
|
return color_from_style(c1) == color_from_style(c2)
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function get_script_style(style, styles)
|
||||||
|
for key, script_style in pairs(styles) do
|
||||||
|
if (test_colors(style.color1, script_style.color1)
|
||||||
|
and test_colors(style.color2, script_style.color2)
|
||||||
|
and test_colors(style.color3, script_style.color3)
|
||||||
|
and test_colors(style.color4, script_style.color4)
|
||||||
|
and tonumber(style.fontsize) == tonumber(script_style.fontsize)
|
||||||
|
and style.fontname == script_style.fontname) then
|
||||||
|
return script_style
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return nil
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function deduetto_meika(subs, sel)
|
||||||
|
local styles = {}
|
||||||
|
local last_style = -1
|
||||||
|
|
||||||
|
-- create the style map
|
||||||
|
for i, line in ipairs(subs) do
|
||||||
|
if line.class == "style" then
|
||||||
|
styles[line.name] = line
|
||||||
|
last_style = i
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
local new_styles = {}
|
||||||
|
|
||||||
|
for _, i in ipairs(sel) do
|
||||||
|
local line = subs[i]
|
||||||
|
local current_style = table.copy(styles[line.style])
|
||||||
|
|
||||||
|
local search_index = 1
|
||||||
|
while search_index < #line.text do
|
||||||
|
local match_start, match_end = line.text:find("{[^}]*}", search_index)
|
||||||
|
if match_start == nil then
|
||||||
|
break
|
||||||
|
end
|
||||||
|
|
||||||
|
local bracketed = line.text:sub(match_start, match_end)
|
||||||
|
local new_style = false
|
||||||
|
|
||||||
|
-- change style's colors
|
||||||
|
for tag, value in bracketed:gmatch("\\([1-4]?c)([^}\\]*)") do
|
||||||
|
new_style = true
|
||||||
|
if tag == "c" or tag == "1c" then
|
||||||
|
current_style.color1 = value
|
||||||
|
elseif tag == "2c" then
|
||||||
|
current_style.color2 = value
|
||||||
|
elseif tag == "3c" then
|
||||||
|
current_style.color3 = value
|
||||||
|
elseif tag == "4c" then
|
||||||
|
current_style.color4 = value
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
-- change style's font
|
||||||
|
for tag, value in bracketed:gmatch("\\(f[sn])([^}\\]*)") do
|
||||||
|
new_style = true
|
||||||
|
if tag == "fs" then
|
||||||
|
current_style.fontsize = value
|
||||||
|
elseif tag == "fn" then
|
||||||
|
current_style.fontname = value
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if new_style then
|
||||||
|
local script_style = get_script_style(current_style, styles)
|
||||||
|
if script_style == nil then
|
||||||
|
if get_script_style(current_style, new_styles) == nil then
|
||||||
|
new_styles[#new_styles+1] = table.copy(current_style)
|
||||||
|
end
|
||||||
|
else
|
||||||
|
-- remove inline colors
|
||||||
|
bracketed = bracketed:gsub("\\[1-4]?c[^\\}]*", "")
|
||||||
|
bracketed = bracketed:gsub("\\[1-4]?a[^\\}]*", "")
|
||||||
|
-- remove inline fonts
|
||||||
|
bracketed = bracketed:gsub("\\f[sn][^\\}]*", "")
|
||||||
|
|
||||||
|
-- add style marker
|
||||||
|
if line.style ~= script_style.name then
|
||||||
|
bracketed = "{s:" .. script_style.name .. bracketed:sub(2, #bracketed)
|
||||||
|
end
|
||||||
|
line.text = line.text:sub(1, match_start-1) .. bracketed .. line.text:sub(match_end + 1, #line.text)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
search_index = match_start + 1
|
||||||
|
end
|
||||||
|
|
||||||
|
subs[i] = line
|
||||||
|
end
|
||||||
|
|
||||||
|
if #new_styles > 0 then
|
||||||
|
for i, new_style in ipairs(new_styles) do
|
||||||
|
new_style.name = "Deduetto style " .. i
|
||||||
|
subs.insert(last_style, new_style)
|
||||||
|
last_style = last_style + 1
|
||||||
|
aegisub.log("Created new style: " .. new_style.name .. "\n")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.register_macro(script_name, script_description, duetto)
|
||||||
|
aegisub.register_macro(tr"Deduetto Meika", tr"Create styles from inline color tags", deduetto_meika)
|
|
@ -0,0 +1,172 @@
|
||||||
|
local tr = aegisub.gettext
|
||||||
|
|
||||||
|
script_name = tr"Karaoke 1sec adjust lead-in"
|
||||||
|
script_description = tr"Adjust karaoke leadin to 1sec"
|
||||||
|
script_author = "Flore"
|
||||||
|
script_version = "1.00"
|
||||||
|
|
||||||
|
include("cleantags.lua")
|
||||||
|
|
||||||
|
leadinmsec = 1000 --lead in time can be changed here
|
||||||
|
|
||||||
|
ktag = "\\[kK][fo]?%d+" --pattern used to detect karaoke tags
|
||||||
|
|
||||||
|
-- KM template line definition
|
||||||
|
km_template_effect = "template pre-line all keeptags"
|
||||||
|
km_templayte_text = '!retime("line",$start < 900 and -$start or -900,200)!{!$start < 900 and "\\\\k" .. ($start/10) or "\\\\k90"!\\fad(!$start < 900 and $start or 300!,200)}'
|
||||||
|
|
||||||
|
function hasleadin(line)--check if there is an existing lead in (2 consecutive bracket with karaoke tags at the start of the line)
|
||||||
|
return line.text:find("^{[^{}]-" .. ktag .. "[^{}]-}%s*{[^{}]-" .. ktag .. "[^{}]-}")
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function removeleadin(line)
|
||||||
|
if not hasleadin(line) then
|
||||||
|
return line
|
||||||
|
end
|
||||||
|
|
||||||
|
leadin = tonumber( line.text:match("^{[^{}]-\\[kK][fo]?(%d+)[^{}]-}%s*{[^{}]-" .. ktag .. "[^{}]-}") ) --read lead-in value
|
||||||
|
line.text = line.text:gsub("^({[^{}]-)\\[kK][fo]?%d+(.-}%s*{[^{}]-" .. ktag .. ".-})","%1%2") --remove lead in
|
||||||
|
|
||||||
|
line.text = cleantags(line.text) --clean tags
|
||||||
|
|
||||||
|
line.start_time = line.start_time + leadin*10 --adjust start time
|
||||||
|
|
||||||
|
--aegisub.log(line.text)
|
||||||
|
|
||||||
|
return line
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function adjust_1sec(subs, sel)
|
||||||
|
|
||||||
|
for _, i in ipairs(sel) do
|
||||||
|
local line = subs[i]
|
||||||
|
|
||||||
|
line.text = cleantags(line.text)
|
||||||
|
|
||||||
|
if( line.text:find(ktag)) then--don't do anything if there is no ktags in this line
|
||||||
|
|
||||||
|
--start by removing existing lead-in
|
||||||
|
while hasleadin(line) do
|
||||||
|
if aegisub.progress.is_cancelled() then return end
|
||||||
|
line = removeleadin(line)
|
||||||
|
end
|
||||||
|
|
||||||
|
--then add our lead in
|
||||||
|
|
||||||
|
if line.start_time >= leadinmsec then
|
||||||
|
line.text = string.format("{\\k%d}%s",leadinmsec/10, line.text)
|
||||||
|
line.start_time = line.start_time - leadinmsec
|
||||||
|
|
||||||
|
else --if line starts too early to put the needed lead in, make the line start at time 0 and fill with appropriate lead in
|
||||||
|
line.text = string.format("{\\k%d}%s",line.start_time/10, line.text)
|
||||||
|
line.start_time = 0
|
||||||
|
end
|
||||||
|
|
||||||
|
subs[i] = line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.set_undo_point(tr"1sec adjust lead-in")
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function remove_tag(line, tag)
|
||||||
|
local expr = "^(.-{[^}]*)\\" .. tag .. "[^\\}]*(.*)"
|
||||||
|
while true do
|
||||||
|
before, after = line.text:match(expr)
|
||||||
|
if before == nil then
|
||||||
|
return line
|
||||||
|
else
|
||||||
|
line.text = cleantags(before .. after)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function is_template_line(line)
|
||||||
|
return (line.class == "dialogue"
|
||||||
|
and line.effect == km_template_effect
|
||||||
|
and line.text == km_templayte_text)
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function mugenizer(subs)
|
||||||
|
local first = nil
|
||||||
|
local styles_different = false
|
||||||
|
local styles = 0
|
||||||
|
local i_styles = {}
|
||||||
|
local template_present = false
|
||||||
|
|
||||||
|
for i, line in ipairs(subs) do
|
||||||
|
if line.class == "info" then
|
||||||
|
if line.key == "PlayResX" or line.key == "PlayResY" then
|
||||||
|
line.value = "0"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if line.class == "style" then
|
||||||
|
line.fontname = "Arial"
|
||||||
|
line.fontsize = "24"
|
||||||
|
line.outline = "1.5"
|
||||||
|
line.margin_l = "15"
|
||||||
|
line.margin_r = "15"
|
||||||
|
line.margin_t = "20"
|
||||||
|
line.margin_b = "20"
|
||||||
|
|
||||||
|
i_styles[styles] = i
|
||||||
|
if styles > 0 then
|
||||||
|
styles_different = styles_different or line.color1 ~= subs[i_styles[styles-1]].color1 or line.color2 ~= subs[i_styles[styles-1]].color2 or line.color3 ~= subs[i_styles[styles-1]].color3 or line.color4 ~= subs[i_styles[styles-1]].color4
|
||||||
|
end
|
||||||
|
styles = styles + 1
|
||||||
|
end
|
||||||
|
|
||||||
|
if is_template_line(line) then
|
||||||
|
line.comment = true
|
||||||
|
template_present = true
|
||||||
|
end
|
||||||
|
|
||||||
|
if line.class == "dialogue" and not line.comment and line.effect ~= "fx" then
|
||||||
|
if first == nil then
|
||||||
|
first = i
|
||||||
|
end
|
||||||
|
|
||||||
|
line.text = cleantags(line.text)
|
||||||
|
|
||||||
|
while hasleadin(line) do
|
||||||
|
if aegisub.progress.is_cancelled() then return end
|
||||||
|
line = removeleadin(line)
|
||||||
|
end
|
||||||
|
|
||||||
|
line = remove_tag(line, "fad")
|
||||||
|
end
|
||||||
|
|
||||||
|
subs[i] = line
|
||||||
|
end
|
||||||
|
|
||||||
|
if not styles_different then
|
||||||
|
for i = 0, styles-1, 1 do
|
||||||
|
line = subs[i_styles[i]]
|
||||||
|
line.color1 = "&H008AFF"
|
||||||
|
line.color2 = "&HFFFFFF"
|
||||||
|
line.color3 = "&H000000"
|
||||||
|
line.color4 = "&H000000"
|
||||||
|
subs[i_styles[i]] = line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
if not template_present then
|
||||||
|
-- add mugen's magic line
|
||||||
|
line = subs[first]
|
||||||
|
line.comment = true
|
||||||
|
line.start_time = 0
|
||||||
|
line.end_time = 0
|
||||||
|
line.effect = km_template_effect
|
||||||
|
line.text = km_templayte_text
|
||||||
|
subs.insert(first, line)
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.register_macro(script_name, script_description, adjust_1sec)
|
||||||
|
aegisub.register_macro(tr"Mugenizer", tr"Mugenize your subs", mugenizer)
|
|
@ -1,79 +0,0 @@
|
||||||
--[[
|
|
||||||
Copyright (c) 2007, Niels Martin Hansen
|
|
||||||
All rights reserved.
|
|
||||||
|
|
||||||
Redistribution and use in source and binary forms, with or without
|
|
||||||
modification, are permitted provided that the following conditions are met:
|
|
||||||
|
|
||||||
* Redistributions of source code must retain the above copyright notice,
|
|
||||||
this list of conditions and the following disclaimer.
|
|
||||||
* Redistributions in binary form must reproduce the above copyright notice,
|
|
||||||
this list of conditions and the following disclaimer in the documentation
|
|
||||||
and/or other materials provided with the distribution.
|
|
||||||
* Neither the name of the Aegisub Group nor the names of its contributors
|
|
||||||
may be used to endorse or promote products derived from this software
|
|
||||||
without specific prior written permission.
|
|
||||||
|
|
||||||
THIS SOFTWARE IS PROVIDED BY THE COPYRIGHT HOLDERS AND CONTRIBUTORS "AS IS"
|
|
||||||
AND ANY EXPRESS OR IMPLIED WARRANTIES, INCLUDING, BUT NOT LIMITED TO, THE
|
|
||||||
IMPLIED WARRANTIES OF MERCHANTABILITY AND FITNESS FOR A PARTICULAR PURPOSE
|
|
||||||
ARE DISCLAIMED. IN NO EVENT SHALL THE COPYRIGHT OWNER OR CONTRIBUTORS BE
|
|
||||||
LIABLE FOR ANY DIRECT, INDIRECT, INCIDENTAL, SPECIAL, EXEMPLARY, OR
|
|
||||||
CONSEQUENTIAL DAMAGES (INCLUDING, BUT NOT LIMITED TO, PROCUREMENT OF
|
|
||||||
SUBSTITUTE GOODS OR SERVICES; LOSS OF USE, DATA, OR PROFITS; OR BUSINESS
|
|
||||||
INTERRUPTION) HOWEVER CAUSED AND ON ANY THEORY OF LIABILITY, WHETHER IN
|
|
||||||
CONTRACT, STRICT LIABILITY, OR TORT (INCLUDING NEGLIGENCE OR OTHERWISE)
|
|
||||||
ARISING IN ANY WAY OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE
|
|
||||||
POSSIBILITY OF SUCH DAMAGE.
|
|
||||||
]]
|
|
||||||
|
|
||||||
local tr = aegisub.gettext
|
|
||||||
|
|
||||||
script_name = tr"Automatic karaoke lead-in"
|
|
||||||
script_description = tr"Join up the ends of selected lines and add \\k tags to shift karaoke"
|
|
||||||
script_author = "Niels Martin Hansen"
|
|
||||||
script_version = "1.0"
|
|
||||||
|
|
||||||
function add_auto_leadin(subs, sel)
|
|
||||||
-- Smallest inter-line duration
|
|
||||||
local min_interdur = nil
|
|
||||||
|
|
||||||
for i = 2, #sel do
|
|
||||||
-- Grab two selected lines
|
|
||||||
local A = subs[sel[i-1]]
|
|
||||||
local B = subs[sel[i]]
|
|
||||||
|
|
||||||
-- Blank duration between lines
|
|
||||||
local interdur = B.start_time - A.end_time
|
|
||||||
|
|
||||||
if interdur > 0 then
|
|
||||||
-- Update smallest inter-line duration
|
|
||||||
if not min_interdur or interdur < min_interdur then
|
|
||||||
min_interdur = interdur
|
|
||||||
end
|
|
||||||
|
|
||||||
B.start_time = A.end_time
|
|
||||||
B.text = string.format("{\\k%d}%s", interdur/10, B.text)
|
|
||||||
|
|
||||||
subs[sel[i]] = B
|
|
||||||
else
|
|
||||||
aegisub.debug.out(2, "Warning: Skipping line-pair with zero or negative inter-duration:\n%s\n%s\n\n", A.text, B.text)
|
|
||||||
end
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
if min_interdur then
|
|
||||||
aegisub.debug.out(0, "Smallest inter-line duration: %d milliseconds", min_interdur)
|
|
||||||
|
|
||||||
aegisub.set_undo_point(script_name)
|
|
||||||
else
|
|
||||||
aegisub.debug.out(2, "Warning: No lines modified")
|
|
||||||
end
|
|
||||||
|
|
||||||
end
|
|
||||||
|
|
||||||
function check_minsel_2(subs, sel)
|
|
||||||
return #sel >= 2
|
|
||||||
end
|
|
||||||
|
|
||||||
aegisub.register_macro(script_name, script_description, add_auto_leadin, check_minsel_2)
|
|
|
@ -0,0 +1,48 @@
|
||||||
|
local tr = aegisub.gettext
|
||||||
|
|
||||||
|
script_name = tr"Split karaoke line"
|
||||||
|
script_description = tr"Split line at {split} marker according to ktags"
|
||||||
|
script_author = "amoethyst"
|
||||||
|
script_version = "1.0"
|
||||||
|
|
||||||
|
function split_line(subs, sel)
|
||||||
|
|
||||||
|
function getduration(line)
|
||||||
|
d = 0
|
||||||
|
|
||||||
|
kduration = "{[^}]-\\[kK][fo]?(%d+)[^}]-}"
|
||||||
|
for match in line:gmatch(kduration) do
|
||||||
|
d = d + tonumber(match)
|
||||||
|
end
|
||||||
|
|
||||||
|
return d * 10
|
||||||
|
end
|
||||||
|
|
||||||
|
insertions = 0
|
||||||
|
for _, i in ipairs(sel) do
|
||||||
|
i = i + insertions
|
||||||
|
line1 = subs[i]
|
||||||
|
line2 = subs[i]
|
||||||
|
|
||||||
|
split_expr = "(.-)%s*{split}%s*(.*)"
|
||||||
|
line1.text, line2.text = line1.text:match(split_expr)
|
||||||
|
|
||||||
|
while line1.text ~= nil do
|
||||||
|
line1.end_time = line1.start_time + getduration(line1.text)
|
||||||
|
line2.start_time = line1.end_time
|
||||||
|
|
||||||
|
subs[i] = line1
|
||||||
|
i = i + 1
|
||||||
|
insertions = insertions + 1
|
||||||
|
subs.insert(i, line2)
|
||||||
|
line1 = subs[i]
|
||||||
|
|
||||||
|
line1.text, line2.text = line1.text:match(split_expr)
|
||||||
|
end
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.set_undo_point(tr"Karaoke split")
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.register_macro(script_name, script_description, split_line)
|
|
@ -1,21 +0,0 @@
|
||||||
-- Automation 4 demo script
|
|
||||||
-- Macro that adds \be1 tags in front of every selected line
|
|
||||||
|
|
||||||
local tr = aegisub.gettext
|
|
||||||
|
|
||||||
script_name = tr"Add edgeblur"
|
|
||||||
script_description = tr"A demo macro showing how to do simple line modification in Automation 4"
|
|
||||||
script_author = "Niels Martin Hansen"
|
|
||||||
script_version = "1"
|
|
||||||
|
|
||||||
|
|
||||||
function add_edgeblur(subtitles, selected_lines, active_line)
|
|
||||||
for z, i in ipairs(selected_lines) do
|
|
||||||
local l = subtitles[i]
|
|
||||||
l.text = "{\\be1}" .. l.text
|
|
||||||
subtitles[i] = l
|
|
||||||
end
|
|
||||||
aegisub.set_undo_point(script_name)
|
|
||||||
end
|
|
||||||
|
|
||||||
aegisub.register_macro(script_name, tr"Adds \\be1 tags to all selected lines", add_edgeblur)
|
|
|
@ -1,80 +0,0 @@
|
||||||
-- Automation 4 demo script
|
|
||||||
-- Converts halfwidth (ASCII) Latin letters to fullwidth JIS Latin letters
|
|
||||||
|
|
||||||
local tr = aegisub.gettext
|
|
||||||
|
|
||||||
script_name = tr("Make text fullwidth")
|
|
||||||
script_description = tr("Shows how to use the unicode include to iterate over characters and a lookup table to convert those characters to something else.")
|
|
||||||
script_author = "Niels Martin Hansen"
|
|
||||||
script_version = "1"
|
|
||||||
|
|
||||||
include("unicode.lua")
|
|
||||||
|
|
||||||
|
|
||||||
lookup = {
|
|
||||||
['!'] = '!', ['"'] = '”', ['#'] = '#', ['$'] = '$',
|
|
||||||
['%'] = '%', ['&'] = '&', ["'"] = '’', ['('] = '(',
|
|
||||||
[')'] = ')', ['*'] = '*', ['+'] = '+', [','] = ',',
|
|
||||||
['-'] = '-', ['.'] = '.', ['/'] = '/',
|
|
||||||
['1'] = '1', ['2'] = '2', ['3'] = '3', ['4'] = '4',
|
|
||||||
['5'] = '5', ['6'] = '6', ['7'] = '7', ['8'] = '8',
|
|
||||||
['9'] = '9', ['0'] = '0',
|
|
||||||
[':'] = ':', [';'] = ';', ['<'] = '<', ['='] = '=',
|
|
||||||
['>'] = '>', ['?'] = '?', ['@'] = '@',
|
|
||||||
['A'] = 'A', ['B'] = 'B', ['C'] = 'C', ['D'] = 'D',
|
|
||||||
['E'] = 'E', ['F'] = 'F', ['G'] = 'G', ['H'] = 'H',
|
|
||||||
['I'] = 'I', ['J'] = 'J', ['K'] = 'K', ['L'] = 'L',
|
|
||||||
['M'] = 'M', ['N'] = 'N', ['O'] = 'O', ['P'] = 'P',
|
|
||||||
['Q'] = 'Q', ['R'] = 'R', ['S'] = 'S', ['T'] = 'T',
|
|
||||||
['U'] = 'U', ['V'] = 'V', ['W'] = 'W', ['X'] = 'X',
|
|
||||||
['Y'] = 'Y', ['Z'] = 'Z',
|
|
||||||
['['] = '[', ['\\'] = '\', [']'] = ']', ['^'] = '^',
|
|
||||||
['a'] = 'a', ['b'] = 'b', ['c'] = 'c', ['d'] = 'd',
|
|
||||||
['e'] = 'e', ['f'] = 'f', ['g'] = 'g', ['h'] = 'h',
|
|
||||||
['i'] = 'i', ['j'] = 'j', ['k'] = 'k', ['l'] = 'l',
|
|
||||||
['m'] = 'm', ['n'] = 'n', ['o'] = 'o', ['p'] = 'p',
|
|
||||||
['q'] = 'q', ['r'] = 'r', ['s'] = 's', ['t'] = 't',
|
|
||||||
['u'] = 'u', ['v'] = 'v', ['w'] = 'w', ['x'] = 'x',
|
|
||||||
['y'] = 'y', ['z'] = 'z',
|
|
||||||
['_'] = '_', ['`'] = '‘',
|
|
||||||
['{'] = '{', ['|'] = '|', ['}'] = '}', ['~'] = '~',
|
|
||||||
}
|
|
||||||
|
|
||||||
function make_fullwidth(subtitles, selected_lines, active_line)
|
|
||||||
for z, i in ipairs(selected_lines) do
|
|
||||||
local l = subtitles[i]
|
|
||||||
|
|
||||||
aegisub.debug.out(string.format('Processing line %d: "%s"\n', i, l.text))
|
|
||||||
aegisub.debug.out("Chars: \n")
|
|
||||||
|
|
||||||
local in_tags = false
|
|
||||||
local newtext = ""
|
|
||||||
for c in unicode.chars(l.text) do
|
|
||||||
aegisub.debug.out(c .. ' -> ')
|
|
||||||
if c == "{" then
|
|
||||||
in_tags = true
|
|
||||||
end
|
|
||||||
if in_tags then
|
|
||||||
aegisub.debug.out(c .. " (ignored, in tags)\n")
|
|
||||||
newtext = newtext .. c
|
|
||||||
else
|
|
||||||
if lookup[c] then
|
|
||||||
aegisub.debug.out(lookup[c] .. " (converted)\n")
|
|
||||||
newtext = newtext .. lookup[c]
|
|
||||||
else
|
|
||||||
aegisub.debug.out(c .. " (not found in lookup)\n")
|
|
||||||
newtext = newtext .. c
|
|
||||||
end
|
|
||||||
end
|
|
||||||
if c == "}" then
|
|
||||||
in_tags = false
|
|
||||||
end
|
|
||||||
end
|
|
||||||
|
|
||||||
l.text = newtext
|
|
||||||
subtitles[i] = l
|
|
||||||
end
|
|
||||||
aegisub.set_undo_point(tr"Make fullwidth")
|
|
||||||
end
|
|
||||||
|
|
||||||
aegisub.register_macro(tr"Make fullwidth", tr"Convert Latin letters to SJIS fullwidth letters", make_fullwidth)
|
|
|
@ -1,32 +0,0 @@
|
||||||
-- Copyright (c) 2010, Thomas Goyne <plorkyeran@aegisub.org>
|
|
||||||
--
|
|
||||||
-- Permission to use, copy, modify, and distribute this software for any
|
|
||||||
-- purpose with or without fee is hereby granted, provided that the above
|
|
||||||
-- copyright notice and this permission notice appear in all copies.
|
|
||||||
--
|
|
||||||
-- THE SOFTWARE IS PROVIDED "AS IS" AND THE AUTHOR DISCLAIMS ALL WARRANTIES
|
|
||||||
-- WITH REGARD TO THIS SOFTWARE INCLUDING ALL IMPLIED WARRANTIES OF
|
|
||||||
-- MERCHANTABILITY AND FITNESS. IN NO EVENT SHALL THE AUTHOR BE LIABLE FOR
|
|
||||||
-- ANY SPECIAL, DIRECT, INDIRECT, OR CONSEQUENTIAL DAMAGES OR ANY DAMAGES
|
|
||||||
-- WHATSOEVER RESULTING FROM LOSS OF USE, DATA OR PROFITS, WHETHER IN AN
|
|
||||||
-- ACTION OF CONTRACT, NEGLIGENCE OR OTHER TORTIOUS ACTION, ARISING OUT OF
|
|
||||||
-- OR IN CONNECTION WITH THE USE OR PERFORMANCE OF THIS SOFTWARE.
|
|
||||||
|
|
||||||
local tr = aegisub.gettext
|
|
||||||
|
|
||||||
script_name = tr"Strip tags"
|
|
||||||
script_description = tr"Remove all override tags from selected lines"
|
|
||||||
script_author = "Thomas Goyne"
|
|
||||||
script_version = "1"
|
|
||||||
|
|
||||||
function strip_tags(subs, sel)
|
|
||||||
for _, i in ipairs(sel) do
|
|
||||||
local line = subs[i]
|
|
||||||
line.text = line.text:gsub("{[^}]+}", "")
|
|
||||||
subs[i] = line
|
|
||||||
end
|
|
||||||
aegisub.set_undo_point(tr"strip tags")
|
|
||||||
end
|
|
||||||
|
|
||||||
aegisub.register_macro(script_name, script_description, strip_tags)
|
|
||||||
|
|
|
@ -0,0 +1,523 @@
|
||||||
|
--[[ "Blur / Layers" creates layers with blur. Supports 2 borders, xbord, ybord, xshad, and yshad. Basic support for transforms and \r.
|
||||||
|
"Blur + Glow" - Same as above but with an extra layer for glow. Set blur amount and alpha for the glow.
|
||||||
|
The "double border" option additionally lets you change the size and colour of the 2nd border.
|
||||||
|
If blur is missing, default blur is added.
|
||||||
|
"Bottom blur" allows you to use different blur for the lowest non-glow layer than for top layer(s).
|
||||||
|
"fix \\1a for layers with border and fade" - Uses \1a&HFF& for the duration of a fade on layers with border.
|
||||||
|
"transition" - for \fad(500,0) with transition 80ms you get \1a&HFF&\t(420,500,\1a&H00&).
|
||||||
|
"only add glow" - will add glow to a line with a border, without messing with the primary / border. (Blur + Glow)
|
||||||
|
"only add 2nd border" - will add 2nd border, without messing with the primary / first border. (Blur / Layers)
|
||||||
|
"Fix fades" - Recalculates those \1a fades mentioned above.
|
||||||
|
Use this when you shift something like an episode title to a new episode and the duration of the sign is different.
|
||||||
|
"Change layer" - raises or lowers layer for all selected lines by the same amount. [This is separate from the other functions.]
|
||||||
|
|
||||||
|
Full manual: http://unanimated.xtreemhost.com/ts/scripts-manuals.htm#blurglow
|
||||||
|
]]
|
||||||
|
|
||||||
|
script_name="Blur and Glow"
|
||||||
|
script_description="Add blur and/or glow to signs"
|
||||||
|
script_author="unanimated"
|
||||||
|
script_url="http://unanimated.xtreemhost.com/ts/blur-and-glow.lua"
|
||||||
|
script_version="2.5"
|
||||||
|
script_namespace="ua.BlurAndGlow"
|
||||||
|
|
||||||
|
local haveDepCtrl,DependencyControl,depRec=pcall(require,"l0.DependencyControl")
|
||||||
|
if haveDepCtrl then
|
||||||
|
script_version="2.5.0"
|
||||||
|
depRec=DependencyControl{feed="https://raw.githubusercontent.com/TypesettingTools/unanimated-Aegisub-Scripts/master/DependencyControl.json"}
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function glow(subs,sel)
|
||||||
|
if not res.rep then al=res.alfa bl=res.blur end
|
||||||
|
if res.glowcol then glowc=res.glc:gsub("#(%x%x)(%x%x)(%x%x)","&H%3%2%1&") end
|
||||||
|
if res.autod then if res.clr or res.bsize then res.double=true end end
|
||||||
|
for z=#sel,1,-1 do
|
||||||
|
i=sel[z]
|
||||||
|
progress("Glowing line: "..(#sel-z+1).."/"..#sel)
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text
|
||||||
|
if defaref and line.style=="Default" then sr=defaref
|
||||||
|
elseif lastref and laststyle==line.style then sr=lastref
|
||||||
|
else sr=stylechk(line.style) end
|
||||||
|
lastref=sr laststyle=line.style
|
||||||
|
duration=line.end_time-line.start_time
|
||||||
|
|
||||||
|
-- get colors, border, shadow from style
|
||||||
|
stylinfo(text)
|
||||||
|
text=preprocess(text)
|
||||||
|
line.text=text
|
||||||
|
|
||||||
|
if border~="0" or text:match("\\[xy]bord") then
|
||||||
|
|
||||||
|
-- WITH TWO BORDERS
|
||||||
|
if res.double then
|
||||||
|
|
||||||
|
-- second border
|
||||||
|
line1=line
|
||||||
|
line1.text=text
|
||||||
|
line1.text=borderline2(line1.text)
|
||||||
|
line1.layer=line1.layer+1
|
||||||
|
subs.insert(i+1,line1)
|
||||||
|
|
||||||
|
-- first border
|
||||||
|
line2=line
|
||||||
|
line2.text=text
|
||||||
|
line2.text=borderline(line2.text)
|
||||||
|
if shadow~="0" then line2.text=line2.text:gsub("^({\\[^}]+)}","%1\\shad"..shadow.."}") end
|
||||||
|
if not res.s_mid then line2.text=line2.text:gsub("^({\\[^}]-)}","%1\\4a&HFF&}") end
|
||||||
|
line2.layer=line2.layer+1
|
||||||
|
subs.insert(i+2,line2)
|
||||||
|
|
||||||
|
-- top line
|
||||||
|
line3=line
|
||||||
|
line3.text=text
|
||||||
|
line3.text=topline(line3.text)
|
||||||
|
line3.layer=line3.layer+1
|
||||||
|
subs.insert(i+3,line3)
|
||||||
|
|
||||||
|
-- bottom / glow
|
||||||
|
text=borderline2(text)
|
||||||
|
text=glowlayer(text,"3c","3")
|
||||||
|
if res.botalpha and line.text:match("\\fad%(") then text=botalfa(text) end
|
||||||
|
line.layer=line.layer-3
|
||||||
|
line.text=text
|
||||||
|
sls=3
|
||||||
|
|
||||||
|
else
|
||||||
|
-- WITH ONE BORDER
|
||||||
|
|
||||||
|
-- border
|
||||||
|
line2=line
|
||||||
|
if not res.onlyg then
|
||||||
|
line2.text=text
|
||||||
|
line2.text=borderline(line2.text)
|
||||||
|
end
|
||||||
|
line2.layer=line2.layer+1
|
||||||
|
subs.insert(i+1,line2)
|
||||||
|
|
||||||
|
-- top line
|
||||||
|
line3=line
|
||||||
|
line3.layer=line3.layer+1
|
||||||
|
if not res.onlyg then
|
||||||
|
line3.text=text
|
||||||
|
line3.text=topline(line3.text)
|
||||||
|
subs.insert(i+2,line3)
|
||||||
|
end
|
||||||
|
|
||||||
|
-- bottom / glow
|
||||||
|
text=glowlayer(text,"3c","3")
|
||||||
|
if res.botalpha and line.text:match("\\fad%(") then text=botalfa(text) end
|
||||||
|
line.layer=line.layer-2
|
||||||
|
line.text=text
|
||||||
|
sls=2
|
||||||
|
|
||||||
|
end
|
||||||
|
|
||||||
|
else
|
||||||
|
-- WITHOUT BORDER
|
||||||
|
|
||||||
|
line2=line
|
||||||
|
line2.layer=line2.layer+1
|
||||||
|
subs.insert(i+1,line2)
|
||||||
|
text=glowlayer(text,"c","1")
|
||||||
|
line.layer=line.layer-1
|
||||||
|
line.text=text
|
||||||
|
sls=1
|
||||||
|
|
||||||
|
end
|
||||||
|
subs[i]=line
|
||||||
|
for s=z,#sel do sel[s]=sel[s]+sls end
|
||||||
|
end
|
||||||
|
progress("Blur & Glow: DONE")
|
||||||
|
return sel
|
||||||
|
end
|
||||||
|
|
||||||
|
function layerblur(subs,sel)
|
||||||
|
if res.autod then if res.clr or res.bsize then res.double=true end end
|
||||||
|
for z=#sel,1,-1 do
|
||||||
|
i=sel[z]
|
||||||
|
progress("Blurring line: "..(#sel-z+1).."/"..#sel)
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text
|
||||||
|
if defaref~=nil and line.style=="Default" then sr=defaref
|
||||||
|
elseif lastref~=nil and laststyle==line.style then sr=lastref
|
||||||
|
else sr=stylechk(line.style) end
|
||||||
|
lastref=sr laststyle=line.style
|
||||||
|
duration=line.end_time-line.start_time
|
||||||
|
|
||||||
|
-- get colors, border, shadow from style
|
||||||
|
stylinfo(text)
|
||||||
|
text=preprocess(text)
|
||||||
|
line.text=text
|
||||||
|
|
||||||
|
-- TWO BORDERS
|
||||||
|
if res.double then
|
||||||
|
|
||||||
|
-- first border
|
||||||
|
line2=line
|
||||||
|
if not res.onlyb then
|
||||||
|
line2.text=text
|
||||||
|
line2.text=borderline(line2.text)
|
||||||
|
if not res.s_mid then line2.text=line2.text:gsub("^({\\[^}]-)}","%1\\4a&HFF&}") end
|
||||||
|
end
|
||||||
|
line2.layer=line2.layer+1
|
||||||
|
subs.insert(i+1,line2)
|
||||||
|
|
||||||
|
-- top line
|
||||||
|
line3=line
|
||||||
|
line3.layer=line3.layer+1
|
||||||
|
if not res.onlyb then
|
||||||
|
line3.text=text
|
||||||
|
line3.text=topline(line3.text)
|
||||||
|
subs.insert(i+2,line3)
|
||||||
|
end
|
||||||
|
|
||||||
|
-- second border
|
||||||
|
text=borderline2(text)
|
||||||
|
line.layer=line.layer-2
|
||||||
|
line.text=text
|
||||||
|
sls=2
|
||||||
|
|
||||||
|
-- ONE BORDER
|
||||||
|
else
|
||||||
|
|
||||||
|
-- top line
|
||||||
|
line3=line
|
||||||
|
line3.text=text
|
||||||
|
line3.text=topline(line3.text)
|
||||||
|
line3.layer=line3.layer+1
|
||||||
|
subs.insert(i+1,line3)
|
||||||
|
|
||||||
|
-- bottom line
|
||||||
|
text=borderline(text)
|
||||||
|
line.layer=line.layer-1
|
||||||
|
line.text=text
|
||||||
|
sls=1
|
||||||
|
end
|
||||||
|
|
||||||
|
subs[i]=line
|
||||||
|
for s=z,#sel do sel[s]=sel[s]+sls end
|
||||||
|
end
|
||||||
|
progress("Blur: DONE")
|
||||||
|
end
|
||||||
|
|
||||||
|
function topline(txt)
|
||||||
|
txt=txt
|
||||||
|
:gsub("(\\t%([^%)]*)\\bord[%d%.]+","%1")
|
||||||
|
:gsub("(\\t%([^%)]*)\\shad[%d%.]+","%1")
|
||||||
|
:gsub("\\t%([^\\]*%)","")
|
||||||
|
if not txt:match("^{[^}]-\\bord") then txt=txt:gsub("^{\\","{\\bord0\\") end
|
||||||
|
txt=txt
|
||||||
|
:gsub("\\bord[%d%.]+","\\bord0")
|
||||||
|
:gsub("(\\r[^}]-)}","%1\\bord0}")
|
||||||
|
txt=txt:gsub("(\\[xy]bord)[%d%.]+","") :gsub("\\3c&H%x+&","")
|
||||||
|
if shadow~="0" then txt=txt:gsub("^({\\[^}]+)}","%1\\shad"..shadow.."}") end
|
||||||
|
txt=txt
|
||||||
|
:gsub("^({\\[^}]-)}","%1\\4a&HFF&}")
|
||||||
|
:gsub("(\\r[^}]-)}","%1\\shad"..shadow.."\\4a&HFF&}")
|
||||||
|
:gsub("\\bord[%d%.%-]+([^}]-)(\\bord[%d%.%-]+)","%1%2")
|
||||||
|
:gsub("\\shad[%d%.%-]+([^}]-)(\\shad[%d%.%-]+)","%1%2")
|
||||||
|
if res.s_top then txt=txt:gsub("\\4a&HFF&","") end
|
||||||
|
txt=txt:gsub("{}","")
|
||||||
|
return txt
|
||||||
|
end
|
||||||
|
|
||||||
|
function borderline(txt)
|
||||||
|
txt=txt:gsub("\\c&H%x+&","")
|
||||||
|
-- transform check
|
||||||
|
if txt:match("^{[^}]-\\t%([^%)]-\\3c") then
|
||||||
|
pretrans=text:match("^{(\\[^}]-)\\t")
|
||||||
|
if not pretrans:match("^{[^}]-\\3c") then txt=txt:gsub("^{\\","{\\c"..soutline.."\\") end
|
||||||
|
end
|
||||||
|
if not txt:match("^{[^}]-\\3c&[^}]-}") then
|
||||||
|
txt=txt:gsub("^({\\[^}]+)}","%1\\c"..soutline.."}")
|
||||||
|
:gsub("(\\r[^}]-)}","%1\\c"..routline.."}")
|
||||||
|
end
|
||||||
|
txt=txt:gsub("(\\3c)(&H%x+&)","%1%2\\c%2")
|
||||||
|
:gsub("(\\r[^}]-)}","%1\\c"..routline.."}")
|
||||||
|
:gsub("(\\r[^}]-\\3c)(&H%x+&)([^}]-)}","%1%2\\c%2%3")
|
||||||
|
:gsub("\\c&H%x+&([^}]-)(\\c&H%x+&)",function(a,b) if not a:match("\\t") then return a..b end end)
|
||||||
|
:gsub("{%*?}","")
|
||||||
|
if res.bbl and not res.double then txt=txt:gsub("\\blur[%d%.]+","\\blur"..res.bblur) end
|
||||||
|
if res.botalpha and txt:match("\\fad%(") then txt=botalfa(txt) end
|
||||||
|
return txt
|
||||||
|
end
|
||||||
|
|
||||||
|
function borderline2(txt)
|
||||||
|
outlinetwo=primary
|
||||||
|
if res.clr then col3=res.c3:gsub("#(%x%x)(%x%x)(%x%x)","&H%3%2%1&") outlinetwo=col3 rimary=col3 end
|
||||||
|
bordertwo=border
|
||||||
|
if res.bsize then bordertwo=res.secbord end
|
||||||
|
-- transform check
|
||||||
|
if txt:match("^{[^}]-\\t%([^%)]-\\bord") then
|
||||||
|
pretrans=text:match("^{(\\[^}]-)\\t")
|
||||||
|
if not pretrans:match("^{[^}]-\\bord") then txt=txt:gsub("^{\\","{\\bord"..border.."\\") end
|
||||||
|
end
|
||||||
|
if not txt:match("^{[^}]-\\bord") then txt=txt:gsub("^{\\","{\\bord"..border.."\\") end
|
||||||
|
txt=txt:gsub("(\\r[^\\}]-)([\\}])","%1\\bord"..rbord.."%2")
|
||||||
|
:gsub("(\\r[^\\}]-)\\bord[%d%.%-]+([^}]-)(\\bord[%d%.%-]+)","%1%2%3")
|
||||||
|
:gsub("(\\bord)([%d%.]+)",function(a,b) if res.bsize then brd=bordertwo else brd=b end return a..b+brd end)
|
||||||
|
:gsub("(\\[xy]bord)([%d%.]+)",function(a,b) return a..b+b end)
|
||||||
|
:gsub("\\3c&H%x+&","")
|
||||||
|
:gsub("^({\\[^}]+)}","%1\\3c"..outlinetwo.."}")
|
||||||
|
:gsub("(\\3c)(&H%x+&)","%1"..outlinetwo)
|
||||||
|
if res.clr then txt=txt:gsub("\\c&H%x+&([^}]-)}","\\c"..rimary.."\\3c"..outlinetwo.."%1}")
|
||||||
|
else txt=txt:gsub("(\\c)(&H%x+&)([^}]-)}","%1%2%3\\3c%2}") end
|
||||||
|
txt=txt:gsub("(\\r[^}]+)}","%1\\3c"..rimary.."}")
|
||||||
|
:gsub("\\c&H%x+&([^}]-)(\\c&H%x+&)",function(a,b) if not a:match("\\t") then return a..b end end)
|
||||||
|
:gsub("\\3c&H%x+&([^}]-)(\\3c&H%x+&)",function(a,b) if not a:match("\\t") then return a..b end end)
|
||||||
|
:gsub("{%*?}","")
|
||||||
|
if res.bbl and res.double then txt=txt:gsub("\\blur[%d%.]+","\\blur"..res.bblur) end
|
||||||
|
if res.botalpha and txt:match("\\fad%(") then txt=botalfa(txt) end
|
||||||
|
return txt
|
||||||
|
end
|
||||||
|
|
||||||
|
function glowlayer(txt,kol,alf)
|
||||||
|
txt=txt:gsub("\\alpha&H(%x%x)&",function(a) if a>al then return "\\alpha&H"..a.."&" else return "\\alpha&H"..al.."&" end end)
|
||||||
|
:gsub("\\"..alf.."a&H(%x%x)&",function(a) if a>al then return "\\"..alf.."a&H"..a.."&" else return "\\"..alf.."a&H"..al.."&" end end)
|
||||||
|
:gsub("(\\blur)[%d%.]*([\\}])","%1"..bl.."%2")
|
||||||
|
:gsub("(\\r[^}]-)}","%1\\alpha&H"..al.."&}")
|
||||||
|
if not txt:match("^{[^}]-\\alpha") then txt=txt:gsub("^({\\[^}]-)}","%1\\alpha&H"..al.."&}") end
|
||||||
|
if res.alfa=="00" then txt=txt:gsub("^({\\[^}]-)\\alpha&H00&","%1") end
|
||||||
|
txt=txt:gsub("{%*?}","")
|
||||||
|
if res.glowcol then
|
||||||
|
if txt:match("^{\\[^}]-\\"..kol.."&") then txt=txt:gsub("\\"..kol.."&H%x+&","\\"..kol..glowc)
|
||||||
|
else txt=txt:gsub("\\"..kol.."&H%x+&","\\"..kol..glowc) txt=txt:gsub("^({\\[^}]-)}","%1\\"..kol..glowc.."}")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return txt
|
||||||
|
end
|
||||||
|
|
||||||
|
function botalfa(txt)
|
||||||
|
fadin,fadout=txt:match("\\fad%((%d+)%,(%d+)")
|
||||||
|
alfadin=res.alphade alfadout=res.alphade
|
||||||
|
if res.alphade=="max" then alfadin=fadin alfadout=fadout end
|
||||||
|
if fadin==nil or fadout==nil then aegisub.log("\n ERROR: Failed to capture fade times from line:\n "..text) end
|
||||||
|
if fadin~="0" then
|
||||||
|
txt=txt:gsub("^({\\[^}]-)}","%1\\1a&HFF&\\t("..fadin-alfadin..","..fadin..",\\1a&H00&)}")
|
||||||
|
end
|
||||||
|
if fadout~="0" then
|
||||||
|
txt=txt:gsub("^({\\[^}]-)}","%1\\t("..duration-fadout..","..duration-fadout+alfadout..",\\1a&HFF&)}")
|
||||||
|
end
|
||||||
|
return txt
|
||||||
|
end
|
||||||
|
|
||||||
|
function stylinfo(text)
|
||||||
|
startags=text:match("^{\\[^}]-}") or ""
|
||||||
|
startags=startags:gsub("\\t%b()","")
|
||||||
|
|
||||||
|
primary=startags:match("^{[^}]-\\c(&H%x+&)") or sr.color1:gsub("H%x%x","H")
|
||||||
|
soutline=sr.color3:gsub("H%x%x","H")
|
||||||
|
outline=startags:match("^{[^}]-\\3c(&H%x+&)") or soutline
|
||||||
|
border=startags:match("^{[^}]-\\bord([%d%.]+)") or tostring(sr.outline)
|
||||||
|
shadow=startags:match("^{[^}]-\\shad([%d%.]+)") or tostring(sr.shadow)
|
||||||
|
|
||||||
|
if text:match("\\r%a") then
|
||||||
|
rstyle=text:match("\\r([^\\}]+)")
|
||||||
|
reref=stylechk(rstyle)
|
||||||
|
rimary=reref.color1:gsub("H%x%x","H")
|
||||||
|
routline=reref.color3:gsub("H%x%x","H")
|
||||||
|
rbord=tostring(reref.outline)
|
||||||
|
else routline=soutline rimary=primary rbord=border
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function preprocess(text)
|
||||||
|
if not text:match("^{\\") then text="{\\blur"..bdef.."}"..text -- default blur if no tags
|
||||||
|
text=text:gsub("(\\r[^}]-)}","%1\\blur"..bdef.."}")
|
||||||
|
end
|
||||||
|
if not text:match("\\blur") then text=text:gsub("^{\\","{\\blur"..bdef.."\\") -- default blur if missing in tags
|
||||||
|
text=text:gsub("(\\r[^}]-)}","%1\\blur"..bdef.."}")
|
||||||
|
end
|
||||||
|
if text:match("\\blur") and not text:match("^{[^}]*blur[^}]*}") then -- add blur if missing in first tag block
|
||||||
|
text=text:gsub("^{\\","{\\blur"..bdef.."\\")
|
||||||
|
end
|
||||||
|
if text:match("^{[^}]-\\t[^}]-}") and not text:match("^{[^}]-\\3c[^}]-\\t") then -- \t workaround
|
||||||
|
text=text:gsub("^{\\","{\\3c"..soutline.."\\")
|
||||||
|
end
|
||||||
|
text=text:gsub("\\1c","\\c")
|
||||||
|
return text
|
||||||
|
end
|
||||||
|
|
||||||
|
function fixfade(subs,sel)
|
||||||
|
for z=#sel,1,-1 do
|
||||||
|
i=sel[z]
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text
|
||||||
|
sr=stylechk(line.style)
|
||||||
|
duration=line.end_time-line.start_time
|
||||||
|
border=tostring(sr.outline)
|
||||||
|
bord=text:match("^{[^}]-\\bord([%d%.]+)")
|
||||||
|
if bord then border=bord end
|
||||||
|
|
||||||
|
if border~="0" and line.text:match("\\fad%(") then
|
||||||
|
text=text:gsub("\\1a&H%x+&","") :gsub("\\t%([^\\%(%)]-%)","")
|
||||||
|
text=botalfa(text)
|
||||||
|
end
|
||||||
|
line.text=text
|
||||||
|
subs[i]=line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function layeraise(subs,sel)
|
||||||
|
for z=#sel,1,-1 do
|
||||||
|
i=sel[z]
|
||||||
|
line=subs[i]
|
||||||
|
if line.layer+res["layer"]>=0 then line.layer=line.layer+res["layer"] else t_error("You're dumb. Layers can't go below 0.",1) end
|
||||||
|
subs[i]=line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function styleget(subs)
|
||||||
|
styles={}
|
||||||
|
for i=1,#subs do
|
||||||
|
if subs[i].class=="style" then
|
||||||
|
table.insert(styles,subs[i])
|
||||||
|
end
|
||||||
|
if subs[i].class=="dialogue" then break end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function stylechk(sn)
|
||||||
|
for s=1,#styles do
|
||||||
|
if sn==styles[s].name then
|
||||||
|
sr=styles[s]
|
||||||
|
if styles[s].name=="Default" then defaref=styles[s] end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if sr==nil then t_error("Style '"..sn.."' doesn't exist.",1) end
|
||||||
|
return sr
|
||||||
|
end
|
||||||
|
|
||||||
|
function saveconfig()
|
||||||
|
bgconf="Blur & Glow config\n\n"
|
||||||
|
for key,val in ipairs(GUI) do
|
||||||
|
if val.class=="floatedit" or val.class=="dropdown" or val.class=="color" then
|
||||||
|
bgconf=bgconf..val.name..":"..res[val.name].."\n"
|
||||||
|
end
|
||||||
|
if val.class=="checkbox" and val.name~="save" then
|
||||||
|
bgconf=bgconf..val.name..":"..tf(res[val.name]).."\n"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
blurkonfig=ADP("?user").."\\blurandglow.conf"
|
||||||
|
file=io.open(blurkonfig,"w")
|
||||||
|
file:write(bgconf)
|
||||||
|
file:close()
|
||||||
|
ADD({{class="label",label="Config saved to:\n"..blurkonfig}},{"OK"},{close='OK'})
|
||||||
|
end
|
||||||
|
|
||||||
|
function loadconfig()
|
||||||
|
blurkonfig=ADP("?user").."\\blurandglow.conf"
|
||||||
|
file=io.open(blurkonfig)
|
||||||
|
if file~=nil then
|
||||||
|
konf=file:read("*all")
|
||||||
|
io.close(file)
|
||||||
|
for key,val in ipairs(GUI) do
|
||||||
|
if val.class=="floatedit" or val.class=="checkbox" or val.class=="dropdown" or val.class=="color" then
|
||||||
|
if konf:match(val.name) then val.value=detf(konf:match(val.name..":(.-)\n")) end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function tf(val)
|
||||||
|
if val==true then ret="true"
|
||||||
|
elseif val==false then ret="false"
|
||||||
|
else ret=val end
|
||||||
|
return ret
|
||||||
|
end
|
||||||
|
|
||||||
|
function detf(txt)
|
||||||
|
if txt=="true" then ret=true
|
||||||
|
elseif txt=="false" then ret=false
|
||||||
|
else ret=txt end
|
||||||
|
return ret
|
||||||
|
end
|
||||||
|
|
||||||
|
function logg(m) m=tf(m) or "nil" aegisub.log("\n "..m) end
|
||||||
|
|
||||||
|
function progress(msg)
|
||||||
|
if aegisub.progress.is_cancelled() then ak() end
|
||||||
|
aegisub.progress.title(msg)
|
||||||
|
end
|
||||||
|
|
||||||
|
function t_error(message,cancel)
|
||||||
|
ADD({{class="label",label=message}},{"OK"},{close='OK'})
|
||||||
|
if cancel then ak() end
|
||||||
|
end
|
||||||
|
|
||||||
|
function blurandglow(subs,sel)
|
||||||
|
ADD=aegisub.dialog.display
|
||||||
|
ADP=aegisub.decode_path
|
||||||
|
ak=aegisub.cancel
|
||||||
|
GUI={
|
||||||
|
--left
|
||||||
|
{x=0,y=0,width=2,class="label",label=" = Blur and Glow version "..script_version.." ="},
|
||||||
|
{x=0,y=1,class="label",label="Glow blur:"},
|
||||||
|
{x=0,y=2,class="label",label="Glow alpha:"},
|
||||||
|
|
||||||
|
{x=1,y=1,width=2,class="floatedit",name="blur",value=3},
|
||||||
|
{x=1,y=2,width=2,class="dropdown",name="alfa",items={"00","20","30","40","50","60","70","80","90","A0","B0","C0","D0","F0"},value="80"},
|
||||||
|
|
||||||
|
{x=0,y=3,class="checkbox",name="glowcol",label="glow c.:",hint="glow colour"},
|
||||||
|
{x=1,y=3,width=2,class="color",name="glc"},
|
||||||
|
|
||||||
|
{x=0,y=4,width=2,class="checkbox",name="s_top",label="keep shadow on top layer"},
|
||||||
|
|
||||||
|
{x=0,y=5,width=5,class="checkbox",name="botalpha",label="fix \\1a for layers with border and fade --> transition:",value=true,
|
||||||
|
hint="uses \\1a&HFF& for bottom layer during fade"},
|
||||||
|
{x=5,y=5,class="dropdown",name="alphade",items={0,45,80,120,160,200,"max"},value=45},
|
||||||
|
{x=6,y=5,width=2,class="label",label="ms"},
|
||||||
|
|
||||||
|
{x=0,y=6,width=4,class="checkbox",name="onlyg",label="only add glow (layers w/ border)"},
|
||||||
|
|
||||||
|
-- right
|
||||||
|
{x=4,y=0,class="checkbox",name="double",label="double border"},
|
||||||
|
{x=5,y=0,width=2,class="checkbox",name="onlyb",label="only add 2nd border"},
|
||||||
|
|
||||||
|
{x=4,y=1,class="checkbox",name="bbl",label="bottom blur:",
|
||||||
|
hint="Blur for bottom layer \n[not the glow layer] \nif different from top layer."},
|
||||||
|
{x=5,y=1,width=2,class="floatedit",name="bblur",value=1},
|
||||||
|
|
||||||
|
{x=4,y=2,class="checkbox",name="bsize",label="2nd b. size:",
|
||||||
|
hint="Size for 2nd border \n[counts from first border out] \nif different from the current border."},
|
||||||
|
{x=5,y=2,width=2,class="floatedit",name="secbord",value=2},
|
||||||
|
|
||||||
|
{x=4,y=3,class="checkbox",name="clr",label="2nd b. colour:",hint="Colour for 2nd border \nif different from primary."},
|
||||||
|
{x=5,y=3,width=2,class="color",name="c3"},
|
||||||
|
|
||||||
|
{x=4,y=4,width=4,class="checkbox",name="s_mid",label="keep shadow on middle layer"},
|
||||||
|
|
||||||
|
{x=4,y=6,class="label",label=" Change layer:"},
|
||||||
|
{x=5,y=6,class="dropdown",name="layer",items={"-5","-4","-3","-2","-1","+1","+2","+3","+4","+5"},value="+1"},
|
||||||
|
|
||||||
|
|
||||||
|
{x=0,y=7,width=2,class="checkbox",name="rep",label="repeat with last settings"},
|
||||||
|
{x=4,y=7,class="checkbox",name="autod",label="auto double",value=true,
|
||||||
|
hint="automatically use double border\nif 2nd colour or 2nd border size is checked"},
|
||||||
|
{x=6,y=6,class="dropdown",name="def",items={"0.3","0.4","0.5","0.6","0.7","0.8","0.9","1"},value="0.6",hint="config: default blur"},
|
||||||
|
{x=5,y=7,width=2,class="checkbox",name="save",label="save configuration"},
|
||||||
|
}
|
||||||
|
loadconfig()
|
||||||
|
buttons={"Blur / Layers","Blur + Glow","Fix fades","Change layer","cancel"}
|
||||||
|
pressed,res=ADD(GUI,buttons,{ok='Blur / Layers',close='cancel'})
|
||||||
|
if pressed=="cancel" then ak() end
|
||||||
|
bdef=res.def
|
||||||
|
if res.onlyg then res.double=false end
|
||||||
|
if res.onlyb then res.double=true end
|
||||||
|
if res.save then saveconfig()
|
||||||
|
else
|
||||||
|
if res.rep then res=lastres end
|
||||||
|
styleget(subs)
|
||||||
|
if pressed=="Blur / Layers" then layerblur(subs,sel) end
|
||||||
|
if pressed=="Blur + Glow" then sel=glow(subs,sel) end
|
||||||
|
if pressed=="Fix fades" then fixfade(subs,sel) end
|
||||||
|
if pressed=="Change layer" then layeraise(subs,sel) end
|
||||||
|
end
|
||||||
|
if res.rep==false then lastres=res end
|
||||||
|
aegisub.set_undo_point(script_name)
|
||||||
|
return sel
|
||||||
|
end
|
||||||
|
|
||||||
|
if haveDepCtrl then depRec:registerMacro(blurandglow) else aegisub.register_macro(script_name,script_description,blurandglow) end
|
|
@ -0,0 +1,148 @@
|
||||||
|
script_name="Change Case"
|
||||||
|
script_description="Capitalises text or makes it lowercase / uppercase"
|
||||||
|
script_author="unanimated"
|
||||||
|
script_version="3.0"
|
||||||
|
script_namespace="ua.ChangeCase"
|
||||||
|
|
||||||
|
local haveDepCtrl,DependencyControl,depRec=pcall(require,"l0.DependencyControl")
|
||||||
|
if haveDepCtrl then
|
||||||
|
script_version="3.0.0"
|
||||||
|
depRec=DependencyControl{feed="https://raw.githubusercontent.com/TypesettingTools/unanimated-Aegisub-Scripts/master/DependencyControl.json"}
|
||||||
|
end
|
||||||
|
|
||||||
|
re=require'aegisub.re'
|
||||||
|
unicode=require'aegisub.unicode'
|
||||||
|
|
||||||
|
function case(subs,sel)
|
||||||
|
for z,i in ipairs(sel) do
|
||||||
|
line=subs[i]
|
||||||
|
t=line.text
|
||||||
|
if P=="lowercase" then t=lowercase(t) end
|
||||||
|
if P=="UPPERCASE" then t=uppercase(t) end
|
||||||
|
if P=="Lines" then t=capitalines(t) end
|
||||||
|
if P=="Sentences" then
|
||||||
|
if res.mod then res.mod=false t=lowercase(t) res.mod=true end
|
||||||
|
t=sentences(t)
|
||||||
|
end
|
||||||
|
if P=="Words" then
|
||||||
|
if not res.mod then t=lowercase(t) end
|
||||||
|
t=capitalise(t)
|
||||||
|
end
|
||||||
|
line.text=t
|
||||||
|
subs[i]=line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function lowercase(t)
|
||||||
|
t=t
|
||||||
|
:gsub("\\[Nnh]","{%1}")
|
||||||
|
:gsub("^([^{]*)",function(l)
|
||||||
|
if res.mod then l=re.sub(l,[[\b(\u\u+'?\u*)]],function(u) return ulower(u) end) return l
|
||||||
|
else return ulower(l) end end)
|
||||||
|
:gsub("}([^{]*)",function(l)
|
||||||
|
if res.mod then l=re.sub(l,[[\b(\u\u+'?\u*)]],function(u) return ulower(u) end) return "}"..l
|
||||||
|
else return "}"..ulower(l) end end)
|
||||||
|
:gsub("{(\\[Nnh])}","%1")
|
||||||
|
return t
|
||||||
|
end
|
||||||
|
|
||||||
|
function uppercase(t)
|
||||||
|
t=t
|
||||||
|
:gsub("\\[Nnh]","{%1}")
|
||||||
|
:gsub("^([^{]*)",function(u) return uupper(u) end)
|
||||||
|
:gsub("}([^{]*)",function(u) return "}"..uupper(u) end)
|
||||||
|
:gsub("{(\\[Nnh])}","%1")
|
||||||
|
return t
|
||||||
|
end
|
||||||
|
|
||||||
|
function capitalines(t)
|
||||||
|
t=re.sub(t,[[^(["']?\l)]],function(l) return uupper(l) end)
|
||||||
|
t=re.sub(t,[[^\{[^}]*\}(["']?\l)]],function(l) return uupper(l) end)
|
||||||
|
if not res.mod then
|
||||||
|
t=t:gsub(" i([' %?!%.,])"," I%1"):gsub("\\Ni([' ])","\\NI%1")
|
||||||
|
end
|
||||||
|
return t
|
||||||
|
end
|
||||||
|
|
||||||
|
function sentences(t)
|
||||||
|
somewords={"English","Japanese","American","British","German","French","Spanish","Monday","Tuesday","Wednesday","Thursday","Friday","Saturday","Sunday","January","February","April","June","July","August","September","October","November","December"}
|
||||||
|
hnrfx={"%-san","%-kun","%-chan","%-sama","%-dono","%-se[nm]pai","%-on%a+an"}
|
||||||
|
t=re.sub(t,[[^(["']?\l)]],function(l) return uupper(l) end)
|
||||||
|
t=re.sub(t,[[^\{[^}]*\}(["']?\l)]],function(l) return uupper(l) end)
|
||||||
|
t=re.sub(t,[[[\.\?!](\s|\s\\N|\\N)["']?(\l)]],function(l) return uupper(l) end)
|
||||||
|
t=t
|
||||||
|
:gsub(" i([' %?!%.,])"," I%1")
|
||||||
|
:gsub("\\Ni([' ])","\\NI%1")
|
||||||
|
:gsub(" m(arch %d)"," M%1")
|
||||||
|
:gsub(" a(pril %d)"," A%1")
|
||||||
|
for l=1,#somewords do t=t:gsub(somewords[l]:lower(),somewords[l]) end
|
||||||
|
for h=1,#hnrfx do
|
||||||
|
t=t:gsub("([ %p]%l)(%l*"..hnrfx[h]..")",function(h,f) return h:upper()..f end)
|
||||||
|
t=t:gsub("(\\N%l)(%l*"..hnrfx[h]..")",function(h,f) return h:upper()..f end)
|
||||||
|
end
|
||||||
|
t=re.sub(t,"\\b(of|in|from|\\d+st|\\d+nd|\\d+rd|\\d+th) m(arch|ay)\\b","\\1 M\\2")
|
||||||
|
t=re.sub(t,"\\bm(r|rs|s)\\.","M\\1.")
|
||||||
|
t=re.sub(t,"\\bdr\\.","Dr.")
|
||||||
|
return t
|
||||||
|
end
|
||||||
|
|
||||||
|
function capitalise(txt)
|
||||||
|
word={"A","About","Above","Across","After","Against","Along","Among","Amongst","An","And","Around","As","At","Before","Behind","Below","Beneath","Beside","Between","Beyond","But","By","Despite","During","Except","For","From","In","Inside","Into","Near","Nor","Of","On","Onto","Or","Over","Per","Sans","Since","Than","The","Through","Throughout","Till","To","Toward","Towards","Under","Underneath","Unlike","Until","Unto","Upon","Versus","Via","With","Within","Without","According to","Ahead of","Apart from","Aside from","Because of","Inside of","Instead of","Next to","Owing to","Prior to","Rather than","Regardless of","Such as","Thanks to","Up to","and Yet"}
|
||||||
|
onore={"%-San","%-Kun","%-Chan","%-Sama","%-Dono","%-Se[nm]pai","%-On%a+an"}
|
||||||
|
nokom={"^( ?)([^{]*)","(})([^{]*)"}
|
||||||
|
for n=1,2 do
|
||||||
|
txt=txt:gsub(nokom[n],function(no_t,t)
|
||||||
|
t=t:gsub("\\[Nnh]","{%1}")
|
||||||
|
t=re.sub(t,[[\b\l]],function(l) return uupper(l) end)
|
||||||
|
t=re.sub(t,[[[I\l]'(\u)]],function(l) return ulower(l) end)
|
||||||
|
|
||||||
|
for r=1,#word do w=word[r]
|
||||||
|
t=t
|
||||||
|
:gsub("^ "..w.." "," "..w:lower().." ")
|
||||||
|
:gsub("([^%.:%?!]) "..w.." ","%1 "..w:lower().." ")
|
||||||
|
:gsub("([^%.:%?!]) (%b{})"..w.." ","%1 %2"..w:lower().." ")
|
||||||
|
:gsub("([^%.:%?!]) (%*Large_break%* ?)"..w.." ","%1 %2"..w:lower().." ")
|
||||||
|
end
|
||||||
|
|
||||||
|
-- Roman numbers (this may mismatch some legit words - sometimes there just are 2 options and it's a guess)
|
||||||
|
t=t
|
||||||
|
:gsub("$","#")
|
||||||
|
:gsub("(%s?)([IVXLCDM])([ivxlcdm]+)([%s%p#])",function(s,r,m,e) return s..r..m:upper()..e end)
|
||||||
|
:gsub("([DLM])ID","%1id")
|
||||||
|
:gsub("DIM","Dim")
|
||||||
|
:gsub("MIX","Mix")
|
||||||
|
:gsub("Ok([%s%p#])","OK%1")
|
||||||
|
for h=1,#onore do
|
||||||
|
t=t:gsub(onore[h].."([%s%p#])",onore[h]:lower().."%1")
|
||||||
|
end
|
||||||
|
t=t
|
||||||
|
:gsub("#$","")
|
||||||
|
:gsub("{(\\[Nnh])}","%1")
|
||||||
|
return no_t..t end)
|
||||||
|
end
|
||||||
|
return txt
|
||||||
|
end
|
||||||
|
|
||||||
|
ulower=unicode.to_lower_case
|
||||||
|
uupper=unicode.to_upper_case
|
||||||
|
|
||||||
|
function logg(m) m=m or "nil" aegisub.log("\n "..m) end
|
||||||
|
|
||||||
|
function capital(subs,sel)
|
||||||
|
GUI={
|
||||||
|
{x=1,y=0,class="label",label="Words - Capitalise Words Like in Titles"},
|
||||||
|
{x=1,y=1,class="label",label=" Lines - Capitalise first word in selected lines"},
|
||||||
|
{x=1,y=2,class="label",label=" Sentences - Capitalise first word in each sentence"},
|
||||||
|
{x=1,y=3,class="label",label=" Lowercase - make text in selected lines lowercase"},
|
||||||
|
{x=1,y=4,class="label",label=" Uppercase - MAKE TEXT IN SELECTED LINES UPPERCASE"},
|
||||||
|
{x=2,y=5,class="label",label=script_name.." v "..script_version},
|
||||||
|
{x=1,y=5,class="checkbox",name="mod",label="mod",hint="Words - leave uppercase words\nLines - don't capitalize 'i'\nSentences - run lowercase first\nlowercase - only for uppercase words"},
|
||||||
|
}
|
||||||
|
P,res=aegisub.dialog.display(GUI,{"Words","Lines","Sentences","lowercase","UPPERCASE","Cancel"},{ok='Words',close='Cancel'})
|
||||||
|
if P=="Cancel" then aegisub.cancel() end
|
||||||
|
case(subs,sel)
|
||||||
|
aegisub.set_undo_point(script_name)
|
||||||
|
return sel
|
||||||
|
end
|
||||||
|
|
||||||
|
if haveDepCtrl then depRec:registerMacro(capital) else aegisub.register_macro(script_name,script_description,capital) end
|
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,116 @@
|
||||||
|
-- Manual: http://unanimated.hostfree.pw/ts/scripts-manuals.htm#cycle
|
||||||
|
|
||||||
|
script_name="Cycles"
|
||||||
|
script_description="Cycles blur, border, shadow, alpha, alignment, font spacing"
|
||||||
|
script_author="unanimated"
|
||||||
|
script_version="2.0"
|
||||||
|
script_namespace="ua.Cycles"
|
||||||
|
|
||||||
|
local haveDepCtrl,DependencyControl,depRec=pcall(require,"l0.DependencyControl")
|
||||||
|
if haveDepCtrl then
|
||||||
|
script_version="2.0.0"
|
||||||
|
depRec=DependencyControl{feed="https://raw.githubusercontent.com/unanimated/luaegisub/master/DependencyControl.json"}
|
||||||
|
end
|
||||||
|
|
||||||
|
-- SETTINGS - You can change these sequences
|
||||||
|
blur_sequence={"0.6","0.8","1","1.2","1.5","2","2.5","3","4","5","6","8","10","0.4","0.5"}
|
||||||
|
bord_sequence={"0","1","1.5","2","2.5","3","4","5","6","7","8","9","10","11","12","15","20"}
|
||||||
|
shad_sequence={"0","1","1.5","2","2.5","3","4","5","6","7","8","9","10","11","12"}
|
||||||
|
alpha_sequence={"FF","00","10","30","60","80","A0","C0","E0"}
|
||||||
|
align_sequence={"1","2","3","4","5","6","7","8","9"}
|
||||||
|
fsp_sequence={"0","1","2","3","4","5","6","7","8","10","12","15","20","30"}
|
||||||
|
|
||||||
|
--[[ Adding more tags
|
||||||
|
You could make this also work for the following tags: frz, frx, fry, fax, fay, fs, fscx, fscy, be, xbord, xshad, ybord, yshad
|
||||||
|
by doing 3 things:
|
||||||
|
1. add a new sequence to the settings above for the tag you want to add
|
||||||
|
2. add a function below here based on what the others look like (it's adjusted for negative values too)
|
||||||
|
3. add "aegisub.register_macro("Cycles/YOUR_SCRIPT_NAME","Cycles WHATEVER_YOU_CHOOSE",FUNCTION_NAME_HERE)" at the end of the script
|
||||||
|
If you at least roughly understand the basics, this should be easy. The main cycle function remains the same for all tags.
|
||||||
|
Should you want to add other tags with different value patterns, check the existing exceptions for alpha in the cycle function.]]
|
||||||
|
|
||||||
|
function blur(subs,sel) cycle(subs,sel,"blur",blur_sequence) end
|
||||||
|
function bord(subs,sel) cycle(subs,sel,"bord",bord_sequence) end
|
||||||
|
function shad(subs,sel) cycle(subs,sel,"shad",shad_sequence) end
|
||||||
|
function alph(subs,sel) cycle(subs,sel,"alpha",alpha_sequence) end
|
||||||
|
function algn(subs,sel) cycle(subs,sel,"an",align_sequence) end
|
||||||
|
function fsp(subs,sel) cycle(subs,sel,"fsp",fsp_sequence) end
|
||||||
|
|
||||||
|
function cycle(subs,sel,tag,sequence)
|
||||||
|
if tag=="alpha" then base=16 else base=10 end
|
||||||
|
for z,i in ipairs(sel) do
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text
|
||||||
|
local back
|
||||||
|
if line.comment or text:match'{switch}$' then back=true end
|
||||||
|
text=text:gsub("\\t(%b())",function(t) return "\\t"..t:gsub("\\","|") end)
|
||||||
|
|
||||||
|
if tag=="alpha" then val1=text:match("^{[^}]-\\alpha&H(%x%x)&") else val1=text:match("^{[^}]-\\"..tag.."(%-?[%d%.]+)") end
|
||||||
|
if val1 then
|
||||||
|
for n=1,#sequence do
|
||||||
|
N=n+1
|
||||||
|
if back then N=n-1 end
|
||||||
|
if N==0 then N=#sequence end
|
||||||
|
if val1==sequence[n] then val2=sequence[N] or sequence[1] break end
|
||||||
|
end
|
||||||
|
if val2==nil then
|
||||||
|
for n=1,#sequence do
|
||||||
|
if n>1 or sequence[1]~="FF" then
|
||||||
|
local N=n
|
||||||
|
if back then N=n-1 end
|
||||||
|
if N==0 then N=#sequence end
|
||||||
|
if tonumber(val1,base)<tonumber(sequence[n],base) then val2=sequence[N] break end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if val2==nil then if back then val2=sequence[#sequence] else val2=sequence[1] end end
|
||||||
|
if tag=="alpha" then
|
||||||
|
text=text:gsub("^({[^}]-\\alpha&H)%x%x","%1"..val2)
|
||||||
|
else
|
||||||
|
text=text:gsub("^({[^}]-\\"..tag..")%-?[%d%.]+","%1"..val2)
|
||||||
|
end
|
||||||
|
val2=nil
|
||||||
|
else
|
||||||
|
text="{\\"..tag..sequence[1].."}"..text
|
||||||
|
text=text:gsub("alpha(%x%x)}","alpha&H%1&}")
|
||||||
|
:gsub("{(\\.-)}{\\","{%1\\")
|
||||||
|
end
|
||||||
|
|
||||||
|
text=text:gsub("{\\[^}]-}",function(t) return t:gsub("|","\\") end)
|
||||||
|
line.text=text
|
||||||
|
subs[i]=line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function switch(subs,sel)
|
||||||
|
for z,i in ipairs(sel) do
|
||||||
|
l=subs[i]
|
||||||
|
t=l.text
|
||||||
|
t=t.."{switch}"
|
||||||
|
t=t:gsub("{switch}{switch}$","")
|
||||||
|
l.text=t
|
||||||
|
subs[i]=l
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function logg(m) m=m or "nil" aegisub.log("\n "..m) end
|
||||||
|
|
||||||
|
if haveDepCtrl then
|
||||||
|
depRec:registerMacros({
|
||||||
|
{"Cycles/Blur Cycle","Cycles Blur",blur},
|
||||||
|
{"Cycles/Border Cycle","Cycles Border",bord},
|
||||||
|
{"Cycles/Shadow Cycle","Cycles Shadow",shad},
|
||||||
|
{"Cycles/Alpha Cycle","Cycles Alpha",alph},
|
||||||
|
{"Cycles/Alignment Cycle","Cycles Alignment",algn},
|
||||||
|
{"Cycles/FontSpacing Cycle","Cycles Font Spacing",fsp},
|
||||||
|
{"Cycles/Switch","Switches sequence direction",switch},
|
||||||
|
},false)
|
||||||
|
else
|
||||||
|
aegisub.register_macro("Cycles/Blur Cycle","Cycles Blur",blur)
|
||||||
|
aegisub.register_macro("Cycles/Border Cycle","Cycles Border",bord)
|
||||||
|
aegisub.register_macro("Cycles/Shadow Cycle","Cycles Shadow",shad)
|
||||||
|
aegisub.register_macro("Cycles/Alpha Cycle","Cycles Alpha",alph)
|
||||||
|
aegisub.register_macro("Cycles/Alignment Cycle","Cycles Alignment",algn)
|
||||||
|
aegisub.register_macro("Cycles/FontSpacing Cycle","Cycles Font Spacing",fsp)
|
||||||
|
aegisub.register_macro("Cycles/Switch","Switches sequence direction",switch)
|
||||||
|
end
|
File diff suppressed because it is too large
Load Diff
File diff suppressed because it is too large
Load Diff
|
@ -0,0 +1,758 @@
|
||||||
|
-- Disclaimer: RTFM! - http://unanimated.hostfree.pw/ts/scripts-manuals.htm#cleanup
|
||||||
|
|
||||||
|
script_name="Script Cleanup"
|
||||||
|
script_description="Garbage disposal and elimination of incriminating evidence"
|
||||||
|
script_author="unanimated"
|
||||||
|
script_version="5.0"
|
||||||
|
script_namespace="ua.ScriptCleanup"
|
||||||
|
|
||||||
|
local haveDepCtrl,DependencyControl,depRec=pcall(require,"l0.DependencyControl")
|
||||||
|
if haveDepCtrl then
|
||||||
|
script_version="5.0.0"
|
||||||
|
depRec=DependencyControl{feed="https://raw.githubusercontent.com/unanimated/luaegisub/master/DependencyControl.json"}
|
||||||
|
end
|
||||||
|
|
||||||
|
dont_delete_empty_tags=false -- option to not delete {}
|
||||||
|
|
||||||
|
re=require'aegisub.re'
|
||||||
|
|
||||||
|
function cleanlines(subs,sel)
|
||||||
|
if res.all then
|
||||||
|
for k,v in ipairs(GUI) do
|
||||||
|
if v.x==0 then res[v.name]=true end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
for z,i in ipairs(sel) do
|
||||||
|
progress("Processing line: "..z.."/"..#sel)
|
||||||
|
prog=math.floor(z/#sel*100)
|
||||||
|
aegisub.progress.set(prog)
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text
|
||||||
|
stl=line.style
|
||||||
|
|
||||||
|
if res.nots and not res.nocom then text=text:gsub("{TS[^}]*} *","") end
|
||||||
|
|
||||||
|
if res.nocom then
|
||||||
|
text=text:gsub("{[^\\}]-}","")
|
||||||
|
:gsub("{[^\\}]-\\N[^\\}]-}","")
|
||||||
|
:gsub("^({[^}]-}) *","%1")
|
||||||
|
:gsub(" *$","")
|
||||||
|
end
|
||||||
|
|
||||||
|
if res.clear_a then line.actor="" end
|
||||||
|
if res.clear_e then line.effect="" end
|
||||||
|
|
||||||
|
if res.layers and line.layer<5 then
|
||||||
|
if stl:match("Defa") or stl:match("Alt") or stl:match("Main") then line.layer=line.layer+5 end
|
||||||
|
end
|
||||||
|
|
||||||
|
if res.cleantag and text:match("{[*>]?\\") then
|
||||||
|
txt2=text
|
||||||
|
text=text:gsub("{\\\\k0}",""):gsub(">\\","\\"):gsub("{(\\[^}]-)} *\\N *{(\\[^}]-)}","\\N{%1%2}")
|
||||||
|
repeat text,r=text:gsub("{(\\[^}]-)}{(\\[^}]-)}","{%1%2}") until r==0
|
||||||
|
text=text:gsub("({\\[^}]-){(\\[^}]-})","%1%2"):gsub("{.-\\r","{\\r"):gsub("^{\\r([\\}])","{%1")
|
||||||
|
:gsub("\\fad%(0,0%)",""):gsub(ATAG.."$",""):gsub("^({\\[^}]-)\\frx0\\fry0","%1"):gsub("\\%a+%(%)","")
|
||||||
|
text=text:gsub(ATAG,function(tgs)
|
||||||
|
tgs2=tgs
|
||||||
|
:gsub("\\+([\\}])","%1")
|
||||||
|
:gsub("(\\[^\\})]+)",function(a) if not a:match'clip' and not a:match'\\fn' and not a:match'\\r' then a=a:gsub(' ','') end return a end)
|
||||||
|
:gsub("(\\%a+)([%d%-]+%.%d+)",function(a,b) if not a:match("\\fn") then b=rnd2dec(b) end return a..b end)
|
||||||
|
:gsub("(\\%a+)%(([%d%.%-]+),([%d%.%-]+)%)",function(a,b,c) b=rnd2dec(b) c=rnd2dec(c) return a.."("..b..","..c..")" end)
|
||||||
|
:gsub("(\\%a+)%(([%d%.%-]+),([%d%.%-]+),([%d%.%-]+),([%d%.%-]+)",function(a,b,c,d,e)
|
||||||
|
return a.."("..rnd2dec(b)..","..rnd2dec(c)..","..rnd2dec(d)..","..rnd2dec(e) end)
|
||||||
|
tgs2=duplikill(tgs2)
|
||||||
|
tgs2=extrakill(tgs2)
|
||||||
|
return tgs2
|
||||||
|
end)
|
||||||
|
if txt2~=text then kleen=kleen+1 end
|
||||||
|
end
|
||||||
|
|
||||||
|
if res.overlap then
|
||||||
|
if line.comment==false and stl:match("Defa") then
|
||||||
|
start=line.start_time
|
||||||
|
endt=line.end_time
|
||||||
|
if i<#subs then nextline=subs[i+1] nextart=nextline.start_time end
|
||||||
|
prevline=subs[i-1]
|
||||||
|
prevstart=prevline.start_time
|
||||||
|
prevend=prevline.end_time
|
||||||
|
dur=line.end_time-line.start_time
|
||||||
|
ms2fr=aegisub.frame_from_ms
|
||||||
|
fr2ms=aegisub.ms_from_frame
|
||||||
|
keyframes=aegisub.keyframes()
|
||||||
|
startf=ms2fr(start)
|
||||||
|
endf=ms2fr(endt)
|
||||||
|
prevendf=ms2fr(prevend)
|
||||||
|
nextartf=ms2fr(nextart)
|
||||||
|
|
||||||
|
-- start gaps/overlaps
|
||||||
|
if prevline.class=="dialogue" and prevline.style:match("Defa") and dur>50 then
|
||||||
|
-- get keyframes
|
||||||
|
kfst=0 kfprev=0
|
||||||
|
for k,kf in ipairs(keyframes) do
|
||||||
|
if kf==startf then kfst=1 end
|
||||||
|
if kf==prevendf then kfprev=1 end
|
||||||
|
end
|
||||||
|
-- start overlap
|
||||||
|
if start<prevend and prevend-start<=50 then
|
||||||
|
if kfst==0 or kfprev==1 then nstart=prevend end
|
||||||
|
end
|
||||||
|
-- start gap
|
||||||
|
if start>prevend and start-prevend<=50 then
|
||||||
|
if kfst==0 and kfprev==1 then nstart=prevend end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
-- end gaps/overlaps
|
||||||
|
if i<#subs and nextline.style:match("Defa") and dur>50 then
|
||||||
|
--get keyframes
|
||||||
|
kfend=0 kfnext=0
|
||||||
|
for k,kf in ipairs(keyframes) do
|
||||||
|
if kf==endf then kfend=1 end
|
||||||
|
if kf==nextartf then kfnext=1 end
|
||||||
|
end
|
||||||
|
-- end overlap
|
||||||
|
if endt>nextart and endt-nextart<=50 then
|
||||||
|
if kfnext==1 and kfend==0 then nendt=nextart end
|
||||||
|
end
|
||||||
|
-- end gap
|
||||||
|
if endt<nextart and nextart-endt<=50 then
|
||||||
|
if kfend==0 or kfnext==1 then nendt=nextart end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if nstart then line.start_time=nstart end
|
||||||
|
if nendt then line.end_time=nendt end
|
||||||
|
nstart=nil nendt=nil
|
||||||
|
end
|
||||||
|
|
||||||
|
if res.spaces then text=text:gsub(" +"," ") :gsub(" *$","") :gsub("^({\\[^}]-}) *","%1") end
|
||||||
|
|
||||||
|
if res.nobreak2 then text=text:gsub("\\[Nn]","")
|
||||||
|
elseif res.nobreak then
|
||||||
|
text=text
|
||||||
|
:gsub(" *{\\i0}\\N{\\i1} *"," ")
|
||||||
|
:gsub("%*","_ast_")
|
||||||
|
:gsub("\\[Nn]","*")
|
||||||
|
:gsub(" *%*+ *"," ")
|
||||||
|
:gsub("_ast_","*")
|
||||||
|
end
|
||||||
|
|
||||||
|
if res.hspace then text=text:gsub("\\h","") end
|
||||||
|
if res.notag then text=text:gsub(ATAG,"") end
|
||||||
|
if res.allcol then text=text:gsub("\\[1234]?c[^\\})]*","") end
|
||||||
|
if res.alpha14 then text=text:gsub("\\[1234]a[^\\})]*","")
|
||||||
|
elseif res.allphas then text=text:gsub("\\[1234]a[^\\})]*","") :gsub("\\alpha[^\\})]*","") end
|
||||||
|
if res.xyshad then text=text:gsub("\\[xy]shad[^\\})]*","")
|
||||||
|
elseif res.allshad then text=text:gsub("\\[xy]?shad[^\\})]*","") end
|
||||||
|
if res.xyrot then text=text:gsub("\\fr[xy][^\\})]*","")
|
||||||
|
elseif res.allrot then text=text:gsub("\\fr[^\\})]*","") end
|
||||||
|
if res.allpers then text=text:gsub("\\f[ar][xyz][^\\})]*","") :gsub("\\org%b()","") end
|
||||||
|
if res.scales then text=text:gsub("\\fsc[xy][^\\})]*","")
|
||||||
|
elseif res.allsize then text=text:gsub("\\fs[%d.]+","") :gsub("\\fs([\\}%)])","%1") :gsub("\\fsc[xy][^\\})]*","") end
|
||||||
|
if res.parent2 then text=text:gsub("(\\%a%a+)(%b())",function(a,b) if a=='\\pos' then return a..b else return "" end end)
|
||||||
|
elseif res.parent then text=text:gsub("\\%a%a+%b()","") end
|
||||||
|
if res.ctrans then text=text:gsub(ATAG,function(tg) return cleantr(tg) end) end
|
||||||
|
if res.inline2 then repeat text,r=text:gsub("(.)"..ATAG.."(.-{%*?\\)","%1%2") until r==0
|
||||||
|
elseif res.inline then text=text:gsub("(.)"..ATAG,"%1") end
|
||||||
|
|
||||||
|
if res.alphacol then
|
||||||
|
text=text
|
||||||
|
:gsub("alpha&(%x%x)&","alpha&H%1&")
|
||||||
|
:gsub("alpha&?H?(%x%x)&?([\\}])","alpha&H%1&%2")
|
||||||
|
:gsub("alpha&H0&","alpha&H00&")
|
||||||
|
:gsub("alpha&H(%x%x)%x*&","alpha&H%1&")
|
||||||
|
:gsub("(\\[1234]a)&(%x%x)&","%1&H%2&")
|
||||||
|
:gsub("(\\[1234]a)(%x%x)([\\}])","%1&H%2&%3")
|
||||||
|
:gsub("(\\[1234]?c&)(%x%x%x%x%x%x)&","%1H%2&")
|
||||||
|
:gsub("(\\[1234]?c&H%x%x%x%x%x%x)([^&])","%1&%2")
|
||||||
|
:gsub("(\\i?clip%([^%)]-) ?([\\}])","%1)%2")
|
||||||
|
:gsub("(\\t%([^%)]-\\i?clip%([^%)]-%))([\\}])","%1)%2")
|
||||||
|
:gsub("(fad%([%d,]+)([\\}])","%1)%2")
|
||||||
|
:gsub("([1234]?[ac])H&(%x+)","%1&H%2")
|
||||||
|
:gsub("([1234]?c&H)00(%x%x%x%x%x%x)","%1%2")
|
||||||
|
end
|
||||||
|
|
||||||
|
text=text:gsub("^ *","") :gsub("\\t%([^\\%)]-%)","") :gsub("{%*}","")
|
||||||
|
if not dont_delete_empty_tags then text=text:gsub("{}","") end
|
||||||
|
if line.text~=text then chng=chng+1 end
|
||||||
|
line.text=text
|
||||||
|
subs[i]=line
|
||||||
|
end
|
||||||
|
if res.info then
|
||||||
|
infotxt="Lines with modified Text field: "..chng
|
||||||
|
if res.cleantag then infotxt=infotxt.."\nChanges from Clean Tags: "..kleen end
|
||||||
|
P,rez=ADD({{class="label",label=infotxt}},{"OK"},{close='OK'})
|
||||||
|
end
|
||||||
|
return sel
|
||||||
|
end
|
||||||
|
|
||||||
|
-- delete commented lines from selected lines
|
||||||
|
function nocom_line(subs,sel)
|
||||||
|
progress("Deleting commented lines")
|
||||||
|
ncl_sel={}
|
||||||
|
for s=#sel,1,-1 do
|
||||||
|
line=subs[sel[s]]
|
||||||
|
if line.comment then
|
||||||
|
for z,i in ipairs(ncl_sel) do ncl_sel[z]=i-1 end
|
||||||
|
subs.delete(sel[s])
|
||||||
|
else
|
||||||
|
table.insert(ncl_sel,sel[s])
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return ncl_sel
|
||||||
|
end
|
||||||
|
|
||||||
|
-- delete empty lines
|
||||||
|
function noempty(subs,sel)
|
||||||
|
progress("Deleting empty lines")
|
||||||
|
noe_sel={}
|
||||||
|
for s=#sel,1,-1 do
|
||||||
|
line=subs[sel[s]]
|
||||||
|
if line.text=="" then
|
||||||
|
for z,i in ipairs(noe_sel) do noe_sel[z]=i-1 end
|
||||||
|
subs.delete(sel[s])
|
||||||
|
else
|
||||||
|
table.insert(noe_sel,sel[s])
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return noe_sel
|
||||||
|
end
|
||||||
|
|
||||||
|
-- delete commented or empty lines
|
||||||
|
function noemptycom(subs,sel)
|
||||||
|
progress("Deleting commented/empty lines")
|
||||||
|
noecom_sel={}
|
||||||
|
for s=#sel,1,-1 do
|
||||||
|
line=subs[sel[s]]
|
||||||
|
if line.comment or line.text=="" then
|
||||||
|
for z,i in ipairs(noecom_sel) do noecom_sel[z]=i-1 end
|
||||||
|
subs.delete(sel[s])
|
||||||
|
else
|
||||||
|
table.insert(noecom_sel,sel[s])
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return noecom_sel
|
||||||
|
end
|
||||||
|
|
||||||
|
-- delete unused styles
|
||||||
|
function nostyle(subs,sel)
|
||||||
|
stylist=",,"
|
||||||
|
for i=#subs,1,-1 do
|
||||||
|
if subs[i].class=="dialogue" then
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text
|
||||||
|
st2=text:match("\\r([^\\}]*)")
|
||||||
|
st=line.style
|
||||||
|
if not stylist:match(","..esc(st)..",") then stylist=stylist..st..",," end
|
||||||
|
if st2 and st2~="" and not stylist:match(","..esc(st2)..",") then stylist=stylist..st2..",," end
|
||||||
|
end
|
||||||
|
if subs[i].class=="style" then
|
||||||
|
style=subs[i]
|
||||||
|
if res.nostyle2 and style.name:match("Defa") or res.nostyle2 and style.name:match("Alt") then nodel=1 else nodel=0 end
|
||||||
|
if not stylist:match(","..esc(style.name)..",") and nodel==0 then
|
||||||
|
subs.delete(i)
|
||||||
|
logg("\n Deleted style: "..style.name)
|
||||||
|
for s=1,#sel do sel[s]=sel[s]-1 end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
return sel
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
-- kill everything
|
||||||
|
function killemall(subs,sel)
|
||||||
|
if res.inverse then
|
||||||
|
for k,v in ipairs(GUI) do
|
||||||
|
if v.x>4 and v.y>0 and v.name~="onlyt" then res[v.name]=not res[v.name] end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
for z,i in ipairs(sel) do
|
||||||
|
progress("Processing line: "..z.."/"..#sel)
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text
|
||||||
|
if res.onlyt then res.trans=false
|
||||||
|
text=text:gsub(ATAG,function(t) return t:gsub("\\","|") end)
|
||||||
|
:gsub("|t(%b())",function(t) return "\\t"..t:gsub("|","\\") end)
|
||||||
|
end
|
||||||
|
tags=text:match(STAG) or ""
|
||||||
|
inline=text:gsub(STAG,"")
|
||||||
|
if res.skill and res.ikill then trgt=text tg=3
|
||||||
|
elseif res.ikill then trgt=inline tg=2
|
||||||
|
else trgt=tags tg=1 end
|
||||||
|
if res.border then trgt=killtag("[xy]?bord",trgt) end
|
||||||
|
if res.shadow then trgt=killtag("shad",trgt) end
|
||||||
|
if res.blur then trgt=killtag("blur",trgt) end
|
||||||
|
if res.bee then trgt=killtag("be",trgt) end
|
||||||
|
if res.fsize then trgt=killtag("fs",trgt) end
|
||||||
|
if res.fspace then trgt=killtag("fsp",trgt) end
|
||||||
|
if res.scalex then trgt=killtag("fscx",trgt) end
|
||||||
|
if res.scaley then trgt=killtag("fscy",trgt) end
|
||||||
|
if res.fade then trgt=trgt:gsub("\\fade?%b()","") end
|
||||||
|
if res.posi then trgt=trgt:gsub("\\pos%b()","") end
|
||||||
|
if res.move then trgt=trgt:gsub("\\move%b()","") end
|
||||||
|
if res.org then trgt=trgt:gsub("\\org%b()","") end
|
||||||
|
if res.color1 then trgt=killctag("1?c",trgt) end
|
||||||
|
if res.color2 then trgt=killctag("2c",trgt) end
|
||||||
|
if res.color3 then trgt=killctag("3c",trgt) end
|
||||||
|
if res.color4 then trgt=killctag("4c",trgt) end
|
||||||
|
if res.alfa1 then trgt=killctag("1a",trgt) end
|
||||||
|
if res.alfa2 then trgt=killctag("2a",trgt) end
|
||||||
|
if res.alfa3 then trgt=killctag("3a",trgt) end
|
||||||
|
if res.alfa4 then trgt=killctag("4a",trgt) end
|
||||||
|
if res.alpha then trgt=killctag("alpha",trgt) end
|
||||||
|
if res.clip then trgt=trgt:gsub("\\i?clip%b()","") end
|
||||||
|
if res.fname then trgt=trgt:gsub("\\fn[^\\}]+","") end
|
||||||
|
if res.frz then trgt=killtag("frz",trgt) end
|
||||||
|
if res.frx then trgt=killtag("frx",trgt) end
|
||||||
|
if res.fry then trgt=killtag("fry",trgt) end
|
||||||
|
if res.fax then trgt=killtag("fax",trgt) end
|
||||||
|
if res.fay then trgt=killtag("fay",trgt) end
|
||||||
|
if res.anna then trgt=killtag("an",trgt) end
|
||||||
|
if res.align then trgt=killtag("a",trgt) end
|
||||||
|
if res.wrap then trgt=killtag("q",trgt) end
|
||||||
|
if res["return"] then trgt=trgt:gsub("\\r.+([\\}])","%1") end
|
||||||
|
if res.kara then trgt=trgt:gsub("\\[Kk][fo]?[%d%.]+([\\}])","%1") end
|
||||||
|
if res.ital then repeat trgt,r=trgt:gsub("\\i[01]?([\\}])","%1") until r==0 end
|
||||||
|
if res.bold then repeat trgt,r=trgt:gsub("\\b[01]?([\\}])","%1") until r==0 end
|
||||||
|
if res.under then repeat trgt,r=trgt:gsub("\\u[01]?([\\}])","%1") until r==0 end
|
||||||
|
if res.stri then repeat trgt,r=trgt:gsub("\\s[01]?([\\}])","%1") until r==0 end
|
||||||
|
if res.trans then trgt=trgt:gsub("\\t%b()","") end
|
||||||
|
trgt=trgt:gsub("\\t%([%d%.,]*%)","") :gsub("{%**}","")
|
||||||
|
if tg==1 then tags=trgt elseif tg==2 then inline=trgt elseif tg==3 then text=trgt end
|
||||||
|
if trgt~=text then text=tags..inline end
|
||||||
|
if res.onlyt then text=text:gsub("{%*?|[^}]-}",function(t) return t:gsub("|","\\") end) end
|
||||||
|
line.text=text
|
||||||
|
subs[i]=line
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
function killtag(tag,t) repeat t,r=t:gsub("\\"..tag.."[%d%.%-]-([\\}])","%1") until r==0 return t end
|
||||||
|
function killctag(tag,t) t=t:gsub("\\"..tag.."&H%x+&","") repeat t,r=t:gsub("\\"..tag.."([\\}])","%1") until r==0 return t end
|
||||||
|
|
||||||
|
|
||||||
|
-- hide tags
|
||||||
|
function hide_tags(subs,sel)
|
||||||
|
hide=true
|
||||||
|
if res.inverse then hide=nil end
|
||||||
|
local numbers="\\i\\b\\u\\s\\q\\a\\be\\blur\\bord\\fs\\fscx\\fscy\\shad\\an\\frz\\fry\\frx\\fsp\\fax\\fay\\"
|
||||||
|
local alphacol="\\1a\\2a\\3a\\4a\\1c\\2c\\3c\\4c\\alpha\\"
|
||||||
|
local parent="\\fad\\pos\\move\\org\\clip\\"
|
||||||
|
local fontret="\\r\\fn\\"
|
||||||
|
if hide then
|
||||||
|
hidem={}
|
||||||
|
for k,v in ipairs(GUI) do
|
||||||
|
if v.x>4 and v.y>0 and v.name~='onlyt' and v.name~='kara' then
|
||||||
|
nom=v.label:gsub("c, 1c","1c"):gsub("%(i%)","")
|
||||||
|
if res[v.name] then table.insert(hidem,nom) end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
for x,i in ipairs(sel) do
|
||||||
|
line=subs[i]
|
||||||
|
text=line.text:gsub("\\c&","\\1c&")
|
||||||
|
startg=text:match("^{\\[^}]-}") or ""
|
||||||
|
startg=trem(startg)
|
||||||
|
t2=text:gsub("^{\\[^}]-}","")
|
||||||
|
|
||||||
|
if hide then
|
||||||
|
for t=1,#hidem do
|
||||||
|
local tag='\\'..hidem[t]
|
||||||
|
local htag='//'..hidem[t]
|
||||||
|
local chk=tag..'\\'
|
||||||
|
tg=nil
|
||||||
|
if numbers:match(chk) then
|
||||||
|
tg=startg:match(tag.."([%d.-]+)")
|
||||||
|
if tg then t2=t2.."{"..htag..tg.."}" end
|
||||||
|
startg=startg:gsub(tag.."[%d.-]+","")
|
||||||
|
if not tg and tag=="\\shad" then
|
||||||
|
tg1=startg:match("\\xshad([%d.-]+)")
|
||||||
|
tg2=startg:match("\\yshad([%d.-]+)")
|
||||||
|
if tg1 then t2=t2.."{//xshad"..tg1.."}" end
|
||||||
|
if tg2 then t2=t2.."{//yshad"..tg2.."}" end
|
||||||
|
startg=startg:gsub("\\[xy]shad[%d.-]+","")
|
||||||
|
end
|
||||||
|
elseif alphacol:match(chk) then
|
||||||
|
tg=startg:match(tag.."(&H%x+&)")
|
||||||
|
if tg then t2=t2.."{"..htag..tg.."}" end
|
||||||
|
startg=startg:gsub(tag.."&H%x+&","")
|
||||||
|
elseif parent:match(chk) then
|
||||||
|
tg=startg:match(tag.."(%b())")
|
||||||
|
if not tg and tag=="\\clip" then tg=startg:match("\\iclip(%b())") tag='\\iclip' htag='//iclip' end
|
||||||
|
if not tg and tag=="\\fad" then tg=startg:match("\\fade(%b())") tag='\\fade' htag='//fade' end
|
||||||
|
if tg then t2=t2.."{"..htag..tg.."}" end
|
||||||
|
startg=startg:gsub(tag.."%b()","")
|
||||||
|
elseif fontret:match(chk) then
|
||||||
|
tg=startg:match(tag.."([^\\}]*)")
|
||||||
|
if tg then t2=t2.."{"..htag..tg.."}" end
|
||||||
|
startg=startg:gsub(tag.."[^\\}]*","")
|
||||||
|
elseif tag=='\\t' then
|
||||||
|
t2=t2.."{"..trnsfrm:gsub("\\t","//t").."}"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if res.hidline then
|
||||||
|
-- hide inline
|
||||||
|
inT=inline_pos(t2)
|
||||||
|
t2=t2:gsub(ATAG,"")
|
||||||
|
for k,v in ipairs(inT) do
|
||||||
|
t2=t2..v.t:gsub("{%*?\\","{"..v.n.."//")
|
||||||
|
end
|
||||||
|
end
|
||||||
|
else
|
||||||
|
local vis1,vis2=t2:gsub("%b{}","")
|
||||||
|
local c=0
|
||||||
|
repeat
|
||||||
|
-- Unhide regular
|
||||||
|
if res.skill then
|
||||||
|
for hidden in t2:gmatch("{(//.-)}") do
|
||||||
|
t2=t2:gsub("{"..esc(hidden).."}","")
|
||||||
|
hidden=hidden:gsub("//","\\")
|
||||||
|
startg=startg.."{"..hidden.."}"
|
||||||
|
end
|
||||||
|
end
|
||||||
|
-- unhide inline
|
||||||
|
if t2:match("{%d+//[^}]+}") and res.ikill then
|
||||||
|
inT={}
|
||||||
|
stT=''
|
||||||
|
for num,tag in t2:gmatch("{(%d+)//([^}]+)}") do
|
||||||
|
table.insert(inT,{n=num,t=tag})
|
||||||
|
end
|
||||||
|
for tag in t2:gmatch("{//[^}]+}") do stT=stT..tag end
|
||||||
|
table.sort(inT,function(a,b) return tonumber(a.n)<tonumber(b.n) end)
|
||||||
|
t2=t2:gsub("{%d+//[^}]+}","")
|
||||||
|
if t2:match"{" then orig=t2 t2=t2:gsub("%b{}","") end
|
||||||
|
t2=inline_ret2(t2,inT)
|
||||||
|
if orig then t2=textmod(orig,t2) orig=nil end
|
||||||
|
t2=t2..stT
|
||||||
|
end
|
||||||
|
vis2=t2:gsub("%b{}","")
|
||||||
|
c=c+1
|
||||||
|
until vis1==vis2 or c==666
|
||||||
|
if vis1~=vis2 then logg('Error:\n '..vis1..'\n> '..vis2) end
|
||||||
|
end
|
||||||
|
|
||||||
|
if not hide or hide and not res.trans then startg=startg.."{"..trnsfrm.."}" end
|
||||||
|
text=duplikill(startg:gsub("}{",""):gsub("\\1c","\\c"))..t2
|
||||||
|
text=text:gsub("{}",""):gsub("\\1c","\\c")
|
||||||
|
if line.text~=text then line.text=text subs[i]=line end
|
||||||
|
end
|
||||||
|
return sel
|
||||||
|
end
|
||||||
|
|
||||||
|
-- save inline tags
|
||||||
|
function inline_pos(t)
|
||||||
|
inTags={}
|
||||||
|
tl=t:len()
|
||||||
|
if tl==0 then return {} end
|
||||||
|
p=0
|
||||||
|
t1=''
|
||||||
|
repeat
|
||||||
|
seg=t:match("^(%b{})") -- try to match tags/comments
|
||||||
|
if seg then
|
||||||
|
if seg:match("{%*?\\") then table.insert(inTags,{n=p,t=seg}) end
|
||||||
|
else
|
||||||
|
seg=t:match("^([^{]+)") -- or match text
|
||||||
|
if not seg then t_error("Error: There appears to be a problem with the brackets here...\n"..t1..t,1) end
|
||||||
|
SL=re.find(seg,".")
|
||||||
|
p=p+#SL -- position of next '{' [or end]
|
||||||
|
end
|
||||||
|
t1=t1..seg
|
||||||
|
t=t:gsub("^"..esc(seg),"")
|
||||||
|
tl=t:len()
|
||||||
|
until tl==0
|
||||||
|
return inTags
|
||||||
|
end
|
||||||
|
|
||||||
|
-- rebuild inline tags
|
||||||
|
function inline_ret2(t,tab)
|
||||||
|
tl=t:len()
|
||||||
|
nt=''
|
||||||
|
kill='_Z#W_' -- this is supposed to never match
|
||||||
|
for k,v in ipairs(tab) do
|
||||||
|
N=tonumber(v.n)
|
||||||
|
if N==0 then nt=nt..v.t
|
||||||
|
else
|
||||||
|
m='.'
|
||||||
|
-- match how many chars at the start
|
||||||
|
m=m:rep(N)
|
||||||
|
RS=re.find(t,m)
|
||||||
|
seg=RS[1].str
|
||||||
|
seg=re.sub(seg,'^'..kill,'')
|
||||||
|
nt=nt..seg..'{\\'..v.t..'}'
|
||||||
|
kill=m -- how many matched in the last round
|
||||||
|
end
|
||||||
|
end
|
||||||
|
-- the rest
|
||||||
|
seg=re.sub(t,'^'..kill,'')
|
||||||
|
nt=nt..seg
|
||||||
|
return nt
|
||||||
|
end
|
||||||
|
|
||||||
|
-- reanimatools -------
|
||||||
|
function esc(str) str=str:gsub("[%%%(%)%[%]%.%-%+%*%?%^%$]","%%%1") return str end
|
||||||
|
function rnd2dec(num) num=math.floor((num*100)+0.5)/100 return num end
|
||||||
|
function logg(m) m=m or "nil" aegisub.log("\n "..m) end
|
||||||
|
function wrap(str) return "{"..str.."}" end
|
||||||
|
function nobra(t) return t:gsub("%b{}","") end
|
||||||
|
function nobrea(t) return t:gsub("%b{}",""):gsub("\\[Nh]","") end
|
||||||
|
function nobrea1(t) return t:gsub("%b{}",""):gsub(" *\\[Nh] *"," ") end
|
||||||
|
function tagmerge(t) repeat t,r=t:gsub("({\\[^}]-)}{(\\[^}]-})","%1%2") until r==0 return t end
|
||||||
|
function progress(msg) if aegisub.progress.is_cancelled() then ak() end aegisub.progress.title(msg) end
|
||||||
|
function t_error(message,cancel) ADD({{class="label",label=message}},{"OK"},{close='OK'}) if cancel then ak() end end
|
||||||
|
|
||||||
|
function duplikill(tagz)
|
||||||
|
local tags1={"blur","be","bord","shad","xbord","xshad","ybord","yshad","fs","fsp","fscx","fscy","frz","frx","fry","fax","fay"}
|
||||||
|
local tags2={"c","2c","3c","4c","1a","2a","3a","4a","alpha"}
|
||||||
|
tagz=tagz:gsub("\\t%b()",function(t) return t:gsub("\\","|") end)
|
||||||
|
for i=1,#tags1 do
|
||||||
|
tag=tags1[i]
|
||||||
|
repeat tagz,c=tagz:gsub("|"..tag.."[%d%.%-]+([^}]-)(\\"..tag.."[%d%.%-]+)","%1%2") until c==0
|
||||||
|
repeat tagz,c=tagz:gsub("\\"..tag.."[%d%.%-]+([^}]-)(\\"..tag.."[%d%.%-]+)","%2%1") until c==0
|
||||||
|
end
|
||||||
|
tagz=tagz:gsub("\\1c&","\\c&")
|
||||||
|
for i=1,#tags2 do
|
||||||
|
tag=tags2[i]
|
||||||
|
repeat tagz,c=tagz:gsub("|"..tag.."&H%x+&([^}]-)(\\"..tag.."&H%x+&)","%1%2") until c==0
|
||||||
|
repeat tagz,c=tagz:gsub("\\"..tag.."&H%x+&([^}]-)(\\"..tag.."&H%x+&)","%2%1") until c==0
|
||||||
|
end
|
||||||
|
repeat tagz,c=tagz:gsub("\\fn[^\\}]+([^}]-)(\\fn[^\\}]+)","%2%1") until c==0
|
||||||
|
repeat tagz,c=tagz:gsub("(\\[ibusq])%d(.-)(%1%d)","%2%3") until c==0
|
||||||
|
repeat tagz,c=tagz:gsub("(\\an)%d(.-)(%1%d)","%3%2") until c==0
|
||||||
|
tagz=tagz:gsub("(|i?clip%(%A-%))(.-)(\\i?clip%(%A-%))","%2%3")
|
||||||
|
:gsub("(\\i?clip%b())(.-)(\\i?clip%b())",function(a,b,c)
|
||||||
|
if a:match("m") and c:match("m") or not a:match("m") and not c:match("m") then return b..c else return a..b..c end end)
|
||||||
|
tagz=tagz:gsub("|","\\"):gsub("\\t%([^\\%)]-%)","")
|
||||||
|
return tagz
|
||||||
|
end
|
||||||
|
|
||||||
|
function extrakill(text,o)
|
||||||
|
local tags3={"pos","move","org","fad"}
|
||||||
|
for i=1,#tags3 do
|
||||||
|
tag=tags3[i]
|
||||||
|
if o==2 then
|
||||||
|
repeat text,c=text:gsub("(\\"..tag.."[^\\}]+)([^}]-)(\\"..tag.."[^\\}]+)","%3%2") until c==0
|
||||||
|
else
|
||||||
|
repeat text,c=text:gsub("(\\"..tag.."[^\\}]+)([^}]-)(\\"..tag.."[^\\}]+)","%1%2") until c==0
|
||||||
|
end
|
||||||
|
end
|
||||||
|
repeat text,c=text:gsub("(\\pos[^\\}]+)([^}]-)(\\move[^\\}]+)","%1%2") until c==0
|
||||||
|
repeat text,c=text:gsub("(\\move[^\\}]+)([^}]-)(\\pos[^\\}]+)","%1%2") until c==0
|
||||||
|
return text
|
||||||
|
end
|
||||||
|
|
||||||
|
function trem(tags)
|
||||||
|
trnsfrm=""
|
||||||
|
for t in tags:gmatch("\\t%b()") do trnsfrm=trnsfrm..t end
|
||||||
|
tags=tags:gsub("\\t%b()","")
|
||||||
|
return tags
|
||||||
|
end
|
||||||
|
|
||||||
|
function cleantr(tags)
|
||||||
|
trnsfrm=""
|
||||||
|
zerotf=""
|
||||||
|
for t in tags:gmatch("\\t%b()") do
|
||||||
|
if t:match("\\t%(\\") then
|
||||||
|
zerotf=zerotf..t:match("\\t%((.*)%)$")
|
||||||
|
else
|
||||||
|
trnsfrm=trnsfrm..t
|
||||||
|
end
|
||||||
|
end
|
||||||
|
zerotf="\\t("..zerotf..")"
|
||||||
|
tags=tags:gsub("\\t%b()",""):gsub("^({[^}]*)}","%1"..zerotf..trnsfrm.."}"):gsub("\\t%(%)","")
|
||||||
|
return tags
|
||||||
|
end
|
||||||
|
|
||||||
|
function retextmod(orig,text)
|
||||||
|
local v1,v2,c,t2
|
||||||
|
v1=nobrea(orig)
|
||||||
|
c=0
|
||||||
|
repeat
|
||||||
|
t2=textmod(orig,text)
|
||||||
|
v2=nobrea(text)
|
||||||
|
c=c+1
|
||||||
|
until v1==v2 or c==666
|
||||||
|
if v1~=v2 then logg("Something went wrong with the text...") logg(v1) logg(v2) end
|
||||||
|
return t2
|
||||||
|
end
|
||||||
|
|
||||||
|
function textmod(orig,text)
|
||||||
|
if text=="" then return orig end
|
||||||
|
tk={}
|
||||||
|
tg={}
|
||||||
|
text=text:gsub("{\\\\k0}","")
|
||||||
|
text=tagmerge(text)
|
||||||
|
vis=nobra(text)
|
||||||
|
ltrmatches=re.find(vis,".")
|
||||||
|
if not ltrmatches then logg("text: "..text..'\nvisible: '..vis)
|
||||||
|
logg("If you're seeing this, something really weird is happening with the re module.\nTry this again or rescan Autoload.")
|
||||||
|
end
|
||||||
|
for l=1,#ltrmatches do
|
||||||
|
table.insert(tk,ltrmatches[l].str)
|
||||||
|
end
|
||||||
|
stags=text:match(STAG) or ""
|
||||||
|
text=text:gsub(STAG,"") :gsub("{[^\\}]-}","")
|
||||||
|
orig=orig:gsub("{([^\\}]+)}",function(c) return wrap("\\\\"..c.."|||") end)
|
||||||
|
count=0
|
||||||
|
for seq in orig:gmatch("[^{]-{%*?\\[^}]-}") do
|
||||||
|
chars,as,tak=seq:match("([^{]-){(%*?)(\\[^}]-)}")
|
||||||
|
pos=re.find(chars,".")
|
||||||
|
if pos==nil then ps=0+count else ps=#pos+count end
|
||||||
|
tgl={p=ps,t=tak,a=as}
|
||||||
|
table.insert(tg,tgl)
|
||||||
|
count=ps
|
||||||
|
end
|
||||||
|
count=0
|
||||||
|
for seq in text:gmatch("[^{]-{%*?\\[^}]-}") do
|
||||||
|
chars,as,tak=seq:match("([^{]-){(%*?)(\\[^}]-)}")
|
||||||
|
pos=re.find(chars,".")
|
||||||
|
if pos==nil then ps=0+count else ps=#pos+count end
|
||||||
|
tgl={p=ps,t=tak,a=as}
|
||||||
|
table.insert(tg,tgl)
|
||||||
|
count=ps
|
||||||
|
end
|
||||||
|
newline=""
|
||||||
|
for i=1,#tk do
|
||||||
|
newline=newline..tk[i]
|
||||||
|
newt=""
|
||||||
|
for n,t in ipairs(tg) do
|
||||||
|
if t.p==i then newt=newt..t.a..t.t end
|
||||||
|
end
|
||||||
|
if newt~="" then newline=newline.."{"..as..newt.."}" end
|
||||||
|
end
|
||||||
|
newtext=stags..newline:gsub("(|||)(\\\\)","%1}{%2"):gsub("({[^}]-)\\\\([^\\}]-)|||","{%2}%1")
|
||||||
|
text=newtext:gsub("{}","")
|
||||||
|
return text
|
||||||
|
end
|
||||||
|
|
||||||
|
|
||||||
|
function cleanup(subs,sel,act)
|
||||||
|
ADD=aegisub.dialog.display
|
||||||
|
ak=aegisub.cancel
|
||||||
|
if #sel==0 then t_error("No selection",1) end
|
||||||
|
ATAG="{[*>]?\\[^}]-}"
|
||||||
|
STAG="^{>?\\[^}]-}"
|
||||||
|
if act==0 then act=sel[1] end
|
||||||
|
chng=0 kleen=0
|
||||||
|
GUI={
|
||||||
|
{x=0,y=0,class="checkbox",name="nots",label="Remove TS timecodes",hint="Removes timecodes like {TS 12:36}"},
|
||||||
|
{x=0,y=1,class="checkbox",name="clear_a",label="Clear Actor field"},
|
||||||
|
{x=0,y=2,class="checkbox",name="clear_e",label="Clear Effect field"},
|
||||||
|
{x=0,y=3,class="checkbox",name="layers",label="Raise dialogue layer by 5"},
|
||||||
|
{x=0,y=4,class="checkbox",name="cleantag",label="Clean up tags",hint="Fixes duplicates, \\\\, \\}, }{, and other garbage"},
|
||||||
|
{x=0,y=5,class="checkbox",name="ctrans",label="Clean up transforms"},
|
||||||
|
{x=0,y=6,class="checkbox",name="overlap",label="Fix 1-frame gaps/overlaps"},
|
||||||
|
{x=0,y=7,class="checkbox",name="nocomline",label="Delete commented lines"},
|
||||||
|
{x=0,y=8,class="checkbox",name="noempty",label="Delete empty lines"},
|
||||||
|
{x=0,y=9,class="checkbox",name="alphacol",label="Try to fix alpha / colour tags"},
|
||||||
|
{x=0,y=10,class="checkbox",name="spaces",label="Fix start/end/double spaces"},
|
||||||
|
{x=0,y=12,class="checkbox",name="info",label="Print info"},
|
||||||
|
{x=0,y=13,class="checkbox",name="all",label="ALL OF THE ABOVE"},
|
||||||
|
|
||||||
|
{x=1,y=0,class="label",label=" "},
|
||||||
|
|
||||||
|
{x=2,y=0,width=2,class="checkbox",name="allcol",label="Remove all colour tags"},
|
||||||
|
{x=2,y=1,class="checkbox",name="allphas",label="Remove all alphas"},
|
||||||
|
{x=3,y=1,class="checkbox",name="alpha14",label="Only 1a-4a"},
|
||||||
|
{x=2,y=2,class="checkbox",name="allrot",label="Remove all rotations",hint="frx, fry, frz"},
|
||||||
|
{x=3,y=2,class="checkbox",name="xyrot",label="Only x, y",hint="remove frx, fry"},
|
||||||
|
{x=2,y=3,class="checkbox",name="allsize",label="Remove size/scaling",hint="fs, fscx, fscy"},
|
||||||
|
{x=3,y=3,class="checkbox",name="scales",label="Only scaling",hint="remove fscx, fscy"},
|
||||||
|
{x=2,y=4,class="checkbox",name="allshad",label="Remove all shadows",hint="shad, xshad, yshad"},
|
||||||
|
{x=3,y=4,class="checkbox",name="xyshad",label="Only x, y",hint="remove xshad, yshad"},
|
||||||
|
{x=2,y=5,class="checkbox",name="parent",label="Remove parentheses",hint="fad(e), (i)clip, pos, move, org\n(but not t)"},
|
||||||
|
{x=3,y=5,class="checkbox",name="parent2",label="Except \\pos",hint="fad(e), (i)clip, move, org\n(but not t or pos)"},
|
||||||
|
{x=2,y=6,width=2,class="checkbox",name="allpers",label="Remove all perspective",hint="frx, fry, frz, fax, fay, org"},
|
||||||
|
|
||||||
|
{x=2,y=7,width=2,class="label",label=" ~ Script Cleanup v"..script_version.." ~"},
|
||||||
|
|
||||||
|
{x=2,y=8,width=2,class="checkbox",name="hspace",label="Remove hard spaces - \\h"},
|
||||||
|
{x=2,y=9,class="checkbox",name="nobreak",label="Remove line breaks"},
|
||||||
|
{x=3,y=9,class="checkbox",name="nobreak2",label="...no space",hint="Remove line breaks, leave no spaces"},
|
||||||
|
{x=2,y=10,class="checkbox",name="nostyle",label="Delete unused styles"},
|
||||||
|
{x=3,y=10,class="checkbox",name="nostyle2",label="Except Def.",hint="Delete unused styles except Default"},
|
||||||
|
{x=2,y=11,class="checkbox",name="inline",label="Remove inline tags"},
|
||||||
|
{x=3,y=11,class="checkbox",name="inline2",label="Except last",hint="Remove inline tags except the last one"},
|
||||||
|
{x=2,y=12,width=2,class="checkbox",name="nocom",label="Remove comments from lines",hint="Removes {comments} (not tags)"},
|
||||||
|
{x=2,y=13,width=2,class="checkbox",name="notag",label="Remove all {\\tags} from selected lines"},
|
||||||
|
|
||||||
|
{x=4,y=0,height=14,class="label",label="| \n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|\n|"},
|
||||||
|
|
||||||
|
{x=5,y=0,class="checkbox",name="skill",label="[start]",value=true},
|
||||||
|
{x=6,y=0,class="checkbox",name="ikill",label="[inline]",value=true,hint="only kill, not hide"},
|
||||||
|
{x=7,y=0,width=2,class="checkbox",name="inverse",label="[inverse/unhide]",hint="kill all except checked ones\n\n'Unhide' for 'Hide Tags'"},
|
||||||
|
{x=7,y=1,width=2,class="checkbox",name="onlyt",label="[from \\t]",hint="remove only from transforms\n\n n/a for 'Hide Tags'"},
|
||||||
|
|
||||||
|
{x=5,y=1,class="checkbox",name="blur",label="blur"},
|
||||||
|
{x=5,y=2,class="checkbox",name="border",label="bord",hint="includes xbord and ybord [not for Hide]"},
|
||||||
|
{x=5,y=3,class="checkbox",name="shadow",label="shad",hint="includes xshad and yshad for Hide"},
|
||||||
|
{x=5,y=4,class="checkbox",name="fsize",label="fs"},
|
||||||
|
{x=5,y=5,class="checkbox",name="fspace",label="fsp"},
|
||||||
|
{x=5,y=6,class="checkbox",name="scalex",label="fscx"},
|
||||||
|
{x=5,y=7,class="checkbox",name="scaley",label="fscy"},
|
||||||
|
{x=5,y=8,class="checkbox",name="fname",label="fn"},
|
||||||
|
{x=5,y=9,class="checkbox",name="ital",label="i"},
|
||||||
|
{x=5,y=10,class="checkbox",name="bold",label="b"},
|
||||||
|
{x=5,y=11,class="checkbox",name="under",label="u"},
|
||||||
|
{x=5,y=12,class="checkbox",name="stri",label="s"},
|
||||||
|
{x=5,y=13,class="checkbox",name="wrap",label="q"},
|
||||||
|
|
||||||
|
{x=6,y=1,class="checkbox",name="bee",label="be"},
|
||||||
|
{x=6,y=2,class="checkbox",name="color1",label="c, 1c"},
|
||||||
|
{x=6,y=3,class="checkbox",name="color2",label="2c"},
|
||||||
|
{x=6,y=4,class="checkbox",name="color3",label="3c"},
|
||||||
|
{x=6,y=5,class="checkbox",name="color4",label="4c"},
|
||||||
|
{x=6,y=6,class="checkbox",name="alpha",label="alpha"},
|
||||||
|
{x=6,y=7,class="checkbox",name="alfa1",label="1a"},
|
||||||
|
{x=6,y=8,class="checkbox",name="alfa2",label="2a"},
|
||||||
|
{x=6,y=9,class="checkbox",name="alfa3",label="3a"},
|
||||||
|
{x=6,y=10,class="checkbox",name="alfa4",label="4a"},
|
||||||
|
{x=6,y=11,class="checkbox",name="align",label="a"},
|
||||||
|
{x=6,y=12,class="checkbox",name="anna",label="an"},
|
||||||
|
{x=6,y=13,class="checkbox",name="clip",label="(i)clip"},
|
||||||
|
|
||||||
|
{x=7,y=2,class="checkbox",name="fade",label="fad"},
|
||||||
|
{x=7,y=3,class="checkbox",name="posi",label="pos"},
|
||||||
|
{x=7,y=4,class="checkbox",name="move",label="move"},
|
||||||
|
{x=7,y=5,class="checkbox",name="org",label="org"},
|
||||||
|
{x=7,y=6,class="checkbox",name="frz",label="frz"},
|
||||||
|
{x=7,y=7,class="checkbox",name="frx",label="frx"},
|
||||||
|
{x=7,y=8,class="checkbox",name="fry",label="fry"},
|
||||||
|
{x=7,y=9,class="checkbox",name="fax",label="fax"},
|
||||||
|
{x=7,y=10,class="checkbox",name="fay",label="fay"},
|
||||||
|
{x=7,y=11,width=2,class="checkbox",name="kara",label="k/kf/ko"},
|
||||||
|
{x=7,y=12,class="checkbox",name="return",label="r"},
|
||||||
|
{x=7,y=13,class="checkbox",name="trans",label="t"},
|
||||||
|
|
||||||
|
{x=8,y=12,height=2,class="checkbox",name="hidline",label="hide\ninline",hint='Hide ALL inline tags'},
|
||||||
|
}
|
||||||
|
P,res=ADD(GUI,
|
||||||
|
{"Run selected","Comments","Tags","Dial 5","Clean Tags","^ Kill Tags","Hide Tags","Cancer"},{ok='Run selected',cancel='Cancer'})
|
||||||
|
if P=="Cancer" then ak() end
|
||||||
|
if P=="^ Kill Tags" then killemall(subs,sel) end
|
||||||
|
if P=="Hide Tags" then hide_tags(subs,sel) end
|
||||||
|
if P=="Comments" then res.nocom=true cleanlines(subs,sel) end
|
||||||
|
if P=="Tags" then res.notag=true cleanlines(subs,sel) end
|
||||||
|
if P=="Dial 5" then res.layers=true cleanlines(subs,sel) end
|
||||||
|
if P=="Clean Tags" then res.cleantag=true cleanlines(subs,sel) end
|
||||||
|
if P=="Run selected" then
|
||||||
|
C=0 for key,v in ipairs(GUI) do if v.x<=3 and res[v.name] then C=1 end end
|
||||||
|
if C==0 then t_error("Run Selected: Error - nothing selected",1) end
|
||||||
|
if res.all then
|
||||||
|
for key,v in ipairs(GUI) do if v.x>0 and v.name then res[v.name]=false end end
|
||||||
|
cleanlines(subs,sel)
|
||||||
|
sel=noemptycom(subs,sel)
|
||||||
|
else cleanlines(subs,sel)
|
||||||
|
if res.nocomline and res.noempty then sel=noemptycom(subs,sel)
|
||||||
|
else
|
||||||
|
if res.nocomline then sel=nocom_line(subs,sel) end
|
||||||
|
if res.noempty then sel=noempty(subs,sel) end
|
||||||
|
end
|
||||||
|
table.sort(sel)
|
||||||
|
if res.nostyle or res.nostyle2 then sel=nostyle(subs,sel) end
|
||||||
|
end
|
||||||
|
end
|
||||||
|
if act>#subs then act=#subs end
|
||||||
|
return sel,act
|
||||||
|
end
|
||||||
|
|
||||||
|
if haveDepCtrl then depRec:registerMacro(cleanup) else aegisub.register_macro(script_name,script_description,cleanup) end
|
|
@ -0,0 +1,43 @@
|
||||||
|
local tr = aegisub.gettext
|
||||||
|
|
||||||
|
script_name = tr"unkf"
|
||||||
|
script_description = tr"replace kf/ko tags in selected lines by regular k tags"
|
||||||
|
script_author = "amoethyst"
|
||||||
|
script_version = "1.0"
|
||||||
|
|
||||||
|
|
||||||
|
function split_line(subs, sel)
|
||||||
|
local expr_kof = "^(.-{[^}]*\\k)[of](.*)$"
|
||||||
|
local expr_K = "^(.-{[^}]*\\)K(.*)$"
|
||||||
|
local before, after
|
||||||
|
|
||||||
|
for _, i in ipairs(sel) do
|
||||||
|
line = subs[i]
|
||||||
|
|
||||||
|
-- replace ko and kf tags
|
||||||
|
while true do
|
||||||
|
before, after = line.text:match(expr_kof)
|
||||||
|
if before == nil then
|
||||||
|
break
|
||||||
|
else
|
||||||
|
line.text = before .. after
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
-- replace K tags
|
||||||
|
while true do
|
||||||
|
before, after = line.text:match(expr_K)
|
||||||
|
if before == nil then
|
||||||
|
break
|
||||||
|
else
|
||||||
|
line.text = before .. "k" .. after
|
||||||
|
end
|
||||||
|
end
|
||||||
|
|
||||||
|
subs[i] = line
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.set_undo_point(script_name)
|
||||||
|
end
|
||||||
|
|
||||||
|
aegisub.register_macro(script_name, script_description, split_line)
|
|
@ -29,7 +29,7 @@
|
||||||
|
|
||||||
Aegisub Project http://www.aegisub.org/
|
Aegisub Project http://www.aegisub.org/
|
||||||
-->
|
-->
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
|
||||||
<!-- Build credit text -->
|
<!-- Build credit text -->
|
||||||
<ItemDefinitionGroup Condition="'$(AegisubBuildCredit)'==''">
|
<ItemDefinitionGroup Condition="'$(AegisubBuildCredit)'==''">
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<!-- VC boilerplate -->
|
<!-- VC boilerplate -->
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{9DDDB9E5-E4A1-423D-A224-F6D4E5AAC06A}</ProjectGuid>
|
<ProjectGuid>{9DDDB9E5-E4A1-423D-A224-F6D4E5AAC06A}</ProjectGuid>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Commands">
|
<Filter Include="Commands">
|
||||||
<UniqueIdentifier>{b5d22cd4-b7ec-48ad-b78b-948b41e5dc15}</UniqueIdentifier>
|
<UniqueIdentifier>{b5d22cd4-b7ec-48ad-b78b-948b41e5dc15}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ImportGroup Label="PropertySheets" />
|
<ImportGroup Label="PropertySheets" />
|
||||||
<PropertyGroup Label="UserMacros" />
|
<PropertyGroup Label="UserMacros" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" DefaultTargets="Build" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
<Import Project="$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props" Condition="Exists('$(MSBuildExtensionsPath)\$(MSBuildToolsVersion)\Microsoft.Common.props')" />
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
<Configuration Condition=" '$(Configuration)' == '' ">Debug</Configuration>
|
||||||
|
|
|
@ -28,9 +28,10 @@ namespace BuildTasks {
|
||||||
private const string versionHTemplate =
|
private const string versionHTemplate =
|
||||||
@"#define BUILD_GIT_VERSION_NUMBER {0}
|
@"#define BUILD_GIT_VERSION_NUMBER {0}
|
||||||
#define BUILD_GIT_VERSION_STRING ""{1}""
|
#define BUILD_GIT_VERSION_STRING ""{1}""
|
||||||
#define TAGGED_RELEASE {2}
|
#define RELEASE_VERSION ""{2}""
|
||||||
#define INSTALLER_VERSION ""{3}""
|
#define TAGGED_RELEASE {3}
|
||||||
#define RESOURCE_BASE_VERSION {4}
|
#define INSTALLER_VERSION ""{4}""
|
||||||
|
#define RESOURCE_BASE_VERSION {5}
|
||||||
";
|
";
|
||||||
private const string versionXmlTemplate =
|
private const string versionXmlTemplate =
|
||||||
@"<?xml version=""1.0"" encoding=""utf-8""?>
|
@"<?xml version=""1.0"" encoding=""utf-8""?>
|
||||||
|
@ -84,11 +85,25 @@ namespace BuildTasks {
|
||||||
string installerVersion = "0.0.0";
|
string installerVersion = "0.0.0";
|
||||||
string resourceVersion = "0, 0, 0";
|
string resourceVersion = "0, 0, 0";
|
||||||
string versionStr = null;
|
string versionStr = null;
|
||||||
|
Tag releaseVersion = null;
|
||||||
bool taggedRelease = false;
|
bool taggedRelease = false;
|
||||||
using (var repo = new Repository(Root + ".git")) {
|
using (var repo = new Repository(Root + ".git")) {
|
||||||
commits += repo.Commits.TakeWhile(c => !c.Id.Equals(LastSVNCommit)).Count();
|
commits += repo.Commits.TakeWhile(c => !c.Id.Equals(LastSVNCommit)).Count();
|
||||||
|
|
||||||
foreach (var tag in repo.Tags) {
|
foreach (var tag in repo.Tags) {
|
||||||
|
if (releaseVersion == null) {
|
||||||
|
releaseVersion = tag;
|
||||||
|
} else {
|
||||||
|
var filter = new CommitFilter()
|
||||||
|
{
|
||||||
|
Since = tag.Target.Sha,
|
||||||
|
Until = releaseVersion.Target.Sha
|
||||||
|
};
|
||||||
|
|
||||||
|
if (repo.Commits.QueryBy(filter).ToList().Count > 0)
|
||||||
|
releaseVersion = tag;
|
||||||
|
}
|
||||||
|
|
||||||
if (!tag.Target.Id.Equals(repo.Head.Tip.Id)) continue;
|
if (!tag.Target.Id.Equals(repo.Head.Tip.Id)) continue;
|
||||||
|
|
||||||
taggedRelease = true;
|
taggedRelease = true;
|
||||||
|
@ -108,7 +123,7 @@ namespace BuildTasks {
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
WriteIfChanged(versionHPath, versionHTemplate, commits, versionStr, taggedRelease ? "1" : "0", installerVersion, resourceVersion);
|
WriteIfChanged(versionHPath, versionHTemplate, commits, versionStr, releaseVersion.Name.TrimStart('v'), taggedRelease ? "1" : "0", installerVersion, resourceVersion);
|
||||||
WriteIfChanged(versionXmlPath, versionXmlTemplate, commits, versionStr);
|
WriteIfChanged(versionXmlPath, versionXmlTemplate, commits, versionStr);
|
||||||
|
|
||||||
return true;
|
return true;
|
||||||
|
|
|
@ -31,7 +31,7 @@
|
||||||
|
|
||||||
$Id$
|
$Id$
|
||||||
-->
|
-->
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
|
||||||
<!-- Default settings for build-time options -->
|
<!-- Default settings for build-time options -->
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
|
@ -46,8 +46,8 @@
|
||||||
<AegisubUseUpdateChecker>true</AegisubUseUpdateChecker>
|
<AegisubUseUpdateChecker>true</AegisubUseUpdateChecker>
|
||||||
<CsriLibraryName>vsfilter.lib</CsriLibraryName>
|
<CsriLibraryName>vsfilter.lib</CsriLibraryName>
|
||||||
<StartupLog>false</StartupLog>
|
<StartupLog>false</StartupLog>
|
||||||
<UpdateCheckerServer>updates.aegisub.org</UpdateCheckerServer>
|
<UpdateCheckerServer>mugen.karaokes.moe</UpdateCheckerServer>
|
||||||
<UpdateCheckerURL>/trunk</UpdateCheckerURL>
|
<UpdateCheckerURL>/downloads/aegisub-japan7</UpdateCheckerURL>
|
||||||
|
|
||||||
<VendorRoot>$([System.IO.Path]::GetFullPath($(MSBuildThisFileDirectory)..\vendor))</VendorRoot>
|
<VendorRoot>$([System.IO.Path]::GetFullPath($(MSBuildThisFileDirectory)..\vendor))</VendorRoot>
|
||||||
<BoostPath>$(VendorRoot)\boost</BoostPath>
|
<BoostPath>$(VendorRoot)\boost</BoostPath>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{5B0E9978-E76F-4BBC-8194-228323F59B53}</ProjectGuid>
|
<ProjectGuid>{5B0E9978-E76F-4BBC-8194-228323F59B53}</ProjectGuid>
|
||||||
<RootNamespace>PortableInstaller</RootNamespace>
|
<RootNamespace>PortableInstaller</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Automation">
|
<Filter Include="Automation">
|
||||||
<UniqueIdentifier>{2c1914de-647f-44ab-a698-a289b10ec29c}</UniqueIdentifier>
|
<UniqueIdentifier>{2c1914de-647f-44ab-a698-a289b10ec29c}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_PropertySheetDisplayName>Aegisub project</_PropertySheetDisplayName>
|
<_PropertySheetDisplayName>Aegisub project</_PropertySheetDisplayName>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{A649D828-A399-4D81-ADEF-94CFDBA7847F}</ProjectGuid>
|
<ProjectGuid>{A649D828-A399-4D81-ADEF-94CFDBA7847F}</ProjectGuid>
|
||||||
<RootNamespace>boost</RootNamespace>
|
<RootNamespace>boost</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="regex">
|
<Filter Include="regex">
|
||||||
<UniqueIdentifier>{e091980d-4374-41b8-aa61-1b07695e1b17}</UniqueIdentifier>
|
<UniqueIdentifier>{e091980d-4374-41b8-aa61-1b07695e1b17}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<!-- VC boilerplate -->
|
<!-- VC boilerplate -->
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{C832EAF3-860D-4373-A02C-933626B47A5E}</ProjectGuid>
|
<ProjectGuid>{C832EAF3-860D-4373-A02C-933626B47A5E}</ProjectGuid>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{D6BA6815-0AAC-48FA-8372-D32CDE8BF07A}</ProjectGuid>
|
<ProjectGuid>{D6BA6815-0AAC-48FA-8372-D32CDE8BF07A}</ProjectGuid>
|
||||||
<RootNamespace>expat</RootNamespace>
|
<RootNamespace>expat</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{F934AB7B-186B-4E96-B20C-A58C38C1B819}</ProjectGuid>
|
<ProjectGuid>{F934AB7B-186B-4E96-B20C-A58C38C1B819}</ProjectGuid>
|
||||||
<RootNamespace>ffmpeg</RootNamespace>
|
<RootNamespace>ffmpeg</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="$(FfmpegSrcDir)\libavdevice\alldevices.c">
|
<ClCompile Include="$(FfmpegSrcDir)\libavdevice\alldevices.c">
|
||||||
<Filter>libavdevice</Filter>
|
<Filter>libavdevice</Filter>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{AA137613-96A1-4388-8905-71345B4F8F87}</ProjectGuid>
|
<ProjectGuid>{AA137613-96A1-4388-8905-71345B4F8F87}</ProjectGuid>
|
||||||
<RootNamespace>ffms2</RootNamespace>
|
<RootNamespace>ffms2</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Audio">
|
<Filter Include="Audio">
|
||||||
<UniqueIdentifier>{ed366ac0-ef41-4c15-b40e-4db3c76b17db}</UniqueIdentifier>
|
<UniqueIdentifier>{ed366ac0-ef41-4c15-b40e-4db3c76b17db}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{EA3DCC95-2423-4EA0-A508-7A427B4C0594}</ProjectGuid>
|
<ProjectGuid>{EA3DCC95-2423-4EA0-A508-7A427B4C0594}</ProjectGuid>
|
||||||
<RootNamespace>fftw</RootNamespace>
|
<RootNamespace>fftw</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}</ProjectGuid>
|
<ProjectGuid>{78B079BD-9FC7-4B9E-B4A6-96DA0F00248B}</ProjectGuid>
|
||||||
<RootNamespace>freetype</RootNamespace>
|
<RootNamespace>freetype</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{b4c15893-ec11-491d-9507-0ac184f9cc78}</UniqueIdentifier>
|
<UniqueIdentifier>{b4c15893-ec11-491d-9507-0ac184f9cc78}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{FB8E8D19-A4D6-4181-943C-282075F49B41}</ProjectGuid>
|
<ProjectGuid>{FB8E8D19-A4D6-4181-943C-282075F49B41}</ProjectGuid>
|
||||||
<RootNamespace>fribidi</RootNamespace>
|
<RootNamespace>fribidi</RootNamespace>
|
||||||
|
|
|
@ -1,2 +1,2 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003" />
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{FBE51B37-8B12-41E8-B5E0-F00A06B4BCD2}</ProjectGuid>
|
<ProjectGuid>{FBE51B37-8B12-41E8-B5E0-F00A06B4BCD2}</ProjectGuid>
|
||||||
<RootNamespace>googletest</RootNamespace>
|
<RootNamespace>googletest</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{CC791693-6B28-40AC-879D-64A6C16468E3}</ProjectGuid>
|
<ProjectGuid>{CC791693-6B28-40AC-879D-64A6C16468E3}</ProjectGuid>
|
||||||
<RootNamespace>hunspell</RootNamespace>
|
<RootNamespace>hunspell</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{F934AB7B-186B-4E96-B20C-A58C38C1B818}</ProjectGuid>
|
<ProjectGuid>{F934AB7B-186B-4E96-B20C-A58C38C1B818}</ProjectGuid>
|
||||||
<RootNamespace>icu</RootNamespace>
|
<RootNamespace>icu</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="$(IcuSrcDir)\common\appendable.cpp">
|
<ClCompile Include="$(IcuSrcDir)\common\appendable.cpp">
|
||||||
<Filter>common</Filter>
|
<Filter>common</Filter>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
|
||||||
<ItemDefinitionGroup>
|
<ItemDefinitionGroup>
|
||||||
<InstallHeader>
|
<InstallHeader>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{BB3FED86-DB7A-4DC7-964A-260FB86CDE61}</ProjectGuid>
|
<ProjectGuid>{BB3FED86-DB7A-4DC7-964A-260FB86CDE61}</ProjectGuid>
|
||||||
<RootNamespace>libaegisub</RootNamespace>
|
<RootNamespace>libaegisub</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{8804F253-DA67-4CC4-926B-0CD2AEE5778D}</ProjectGuid>
|
<ProjectGuid>{8804F253-DA67-4CC4-926B-0CD2AEE5778D}</ProjectGuid>
|
||||||
<RootNamespace>libass</RootNamespace>
|
<RootNamespace>libass</RootNamespace>
|
||||||
|
@ -23,7 +23,7 @@
|
||||||
<AdditionalIncludeDirectories>
|
<AdditionalIncludeDirectories>
|
||||||
$(LibassSrcDir)\libass;
|
$(LibassSrcDir)\libass;
|
||||||
$(MSBuildThisFileDirectory);
|
$(MSBuildThisFileDirectory);
|
||||||
$(FribidiSrcDir)\fribidi;
|
$(FribidiSrcDir)\lib;
|
||||||
%(AdditionalIncludeDirectories)
|
%(AdditionalIncludeDirectories)
|
||||||
</AdditionalIncludeDirectories>
|
</AdditionalIncludeDirectories>
|
||||||
<PreprocessorDefinitions>
|
<PreprocessorDefinitions>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{965054D2-44F2-4EB2-9879-051CC3D7EF08}</ProjectGuid>
|
<ProjectGuid>{965054D2-44F2-4EB2-9879-051CC3D7EF08}</ProjectGuid>
|
||||||
<RootNamespace>libiconv</RootNamespace>
|
<RootNamespace>libiconv</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{5CABCBEF-E79A-4D27-94A5-CF4EAAF1DD96}</ProjectGuid>
|
<ProjectGuid>{5CABCBEF-E79A-4D27-94A5-CF4EAAF1DD96}</ProjectGuid>
|
||||||
<RootNamespace>libpng</RootNamespace>
|
<RootNamespace>libpng</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{BD00D65F-24DA-4784-8860-3B972EA125FC}</ProjectGuid>
|
<ProjectGuid>{BD00D65F-24DA-4784-8860-3B972EA125FC}</ProjectGuid>
|
||||||
<RootNamespace>libresrc</RootNamespace>
|
<RootNamespace>libresrc</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{A7A30702-8162-4E1A-A010-EF51B590C121}</ProjectGuid>
|
<ProjectGuid>{A7A30702-8162-4E1A-A010-EF51B590C121}</ProjectGuid>
|
||||||
<RootNamespace>luabins</RootNamespace>
|
<RootNamespace>luabins</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Headers">
|
<Filter Include="Headers">
|
||||||
<UniqueIdentifier>{0A33FF05-970D-49a7-B722-73E8EA350084}</UniqueIdentifier>
|
<UniqueIdentifier>{0A33FF05-970D-49a7-B722-73E8EA350084}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{7CA6A4EB-A11B-4975-8F3A-F633111C6213}</ProjectGuid>
|
<ProjectGuid>{7CA6A4EB-A11B-4975-8F3A-F633111C6213}</ProjectGuid>
|
||||||
<RootNamespace>luajitbuildvm</RootNamespace>
|
<RootNamespace>luajitbuildvm</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="$(SrcDir)src\host\buildvm.c" />
|
<ClCompile Include="$(SrcDir)src\host\buildvm.c" />
|
||||||
<ClCompile Include="$(SrcDir)src\host\buildvm_asm.c" />
|
<ClCompile Include="$(SrcDir)src\host\buildvm_asm.c" />
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{FCAED410-90EF-4EF9-916C-4B86DC13A3CF}</ProjectGuid>
|
<ProjectGuid>{FCAED410-90EF-4EF9-916C-4B86DC13A3CF}</ProjectGuid>
|
||||||
<RootNamespace>luajitminilua</RootNamespace>
|
<RootNamespace>luajitminilua</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<ClCompile Include="..\..\vendor\luajit\src\host\minilua.c" />
|
<ClCompile Include="..\..\vendor\luajit\src\host\minilua.c" />
|
||||||
</ItemGroup>
|
</ItemGroup>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{5391A8B1-9C70-4DC4-92AD-D3E34C6B803F}</ProjectGuid>
|
<ProjectGuid>{5391A8B1-9C70-4DC4-92AD-D3E34C6B803F}</ProjectGuid>
|
||||||
<RootNamespace>luajit</RootNamespace>
|
<RootNamespace>luajit</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Internal headers">
|
<Filter Include="Internal headers">
|
||||||
<UniqueIdentifier>{dfbe0704-0805-42a9-b221-0eb02d38e473}</UniqueIdentifier>
|
<UniqueIdentifier>{dfbe0704-0805-42a9-b221-0eb02d38e473}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_PropertySheetDisplayName>Path definitions</_PropertySheetDisplayName>
|
<_PropertySheetDisplayName>Path definitions</_PropertySheetDisplayName>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<MiniLuaCommand>$(AegisubBinaryDir)luajit-minilua$(AegisubPlatformSuffix)</MiniLuaCommand>
|
<MiniLuaCommand>$(AegisubBinaryDir)luajit-minilua$(AegisubPlatformSuffix)</MiniLuaCommand>
|
||||||
<ResPackCommand>$(AegisubSourceBase)tools\respack.lua</ResPackCommand>
|
<ResPackCommand>$(AegisubSourceBase)tools\respack.lua</ResPackCommand>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{D6EA54FD-F15C-42F6-929B-A83F299A4582}</ProjectGuid>
|
<ProjectGuid>{D6EA54FD-F15C-42F6-929B-A83F299A4582}</ProjectGuid>
|
||||||
<RootNamespace>scintilla</RootNamespace>
|
<RootNamespace>scintilla</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_PropertySheetDisplayName>Output directories</_PropertySheetDisplayName>
|
<_PropertySheetDisplayName>Output directories</_PropertySheetDisplayName>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_PropertySheetDisplayName>Compiler settings</_PropertySheetDisplayName>
|
<_PropertySheetDisplayName>Compiler settings</_PropertySheetDisplayName>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_PropertySheetDisplayName>Custom Tasks</_PropertySheetDisplayName>
|
<_PropertySheetDisplayName>Custom Tasks</_PropertySheetDisplayName>
|
||||||
</PropertyGroup>
|
</PropertyGroup>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{49766286-2B5D-4177-A860-BD7CE1846EEF}</ProjectGuid>
|
<ProjectGuid>{49766286-2B5D-4177-A860-BD7CE1846EEF}</ProjectGuid>
|
||||||
<RootNamespace>tests</RootNamespace>
|
<RootNamespace>tests</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Support">
|
<Filter Include="Support">
|
||||||
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
<UniqueIdentifier>{93995380-89BD-4b04-88EB-625FBE52EBFB}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{7B56955D-5162-4698-AA5B-47484EDC8783}</ProjectGuid>
|
<ProjectGuid>{7B56955D-5162-4698-AA5B-47484EDC8783}</ProjectGuid>
|
||||||
<RootNamespace>universalchardet</RootNamespace>
|
<RootNamespace>universalchardet</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<ItemGroup>
|
<ItemGroup>
|
||||||
<Filter Include="Source Files">
|
<Filter Include="Source Files">
|
||||||
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
<UniqueIdentifier>{4FC737F1-C7A5-4376-A066-2A32D752A2FF}</UniqueIdentifier>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Sample build customisation file for Aegisub.
|
Sample build customisation file for Aegisub.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Sample build customisation file for Aegisub.
|
Sample build customisation file for Aegisub.
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
|
||||||
<!--
|
<!--
|
||||||
Sample build customisation file for Aegisub.
|
Sample build customisation file for Aegisub.
|
||||||
|
|
|
@ -44,10 +44,13 @@ else
|
||||||
tagged_release=0
|
tagged_release=0
|
||||||
fi
|
fi
|
||||||
|
|
||||||
|
last_release=$(git describe --tags)
|
||||||
|
|
||||||
|
|
||||||
new_version_h="\
|
new_version_h="\
|
||||||
#define BUILD_GIT_VERSION_NUMBER ${git_revision}
|
#define BUILD_GIT_VERSION_NUMBER ${git_revision}
|
||||||
#define BUILD_GIT_VERSION_STRING \"${git_version_str}\"
|
#define BUILD_GIT_VERSION_STRING \"${git_version_str}\"
|
||||||
|
#define RELEASE_VERSION \"${last_release#v}\"
|
||||||
#define TAGGED_RELEASE ${tagged_release}
|
#define TAGGED_RELEASE ${tagged_release}
|
||||||
#define INSTALLER_VERSION \"${installer_version}\"
|
#define INSTALLER_VERSION \"${installer_version}\"
|
||||||
#define RESOURCE_BASE_VERSION ${resource_version}"
|
#define RESOURCE_BASE_VERSION ${resource_version}"
|
||||||
|
@ -70,7 +73,7 @@ export VERSION_SOURCE="from git"
|
||||||
|
|
||||||
cat << EOF > build/git_version.xml
|
cat << EOF > build/git_version.xml
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<GitVersionNumber>${git_revision}</GitVersionNumber>
|
<GitVersionNumber>${git_revision}</GitVersionNumber>
|
||||||
<GitVersionString>${git_version_str}</GitVersionString>
|
<GitVersionString>${git_version_str}</GitVersionString>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{0518D6C0-7BF6-4FD1-91FB-191BD10DB2AC}</ProjectGuid>
|
<ProjectGuid>{0518D6C0-7BF6-4FD1-91FB-191BD10DB2AC}</ProjectGuid>
|
||||||
<RootNamespace>wxWidgets</RootNamespace>
|
<RootNamespace>wxWidgets</RootNamespace>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
|
|
||||||
<PropertyGroup>
|
<PropertyGroup>
|
||||||
<_PropertySheetDisplayName>Yasm compile targets</_PropertySheetDisplayName>
|
<_PropertySheetDisplayName>Yasm compile targets</_PropertySheetDisplayName>
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
<?xml version="1.0" encoding="utf-8"?>
|
<?xml version="1.0" encoding="utf-8"?>
|
||||||
<Project DefaultTargets="Build" ToolsVersion="12.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
<Project DefaultTargets="Build" ToolsVersion="14.0" xmlns="http://schemas.microsoft.com/developer/msbuild/2003">
|
||||||
<PropertyGroup Label="Globals">
|
<PropertyGroup Label="Globals">
|
||||||
<ProjectGuid>{10F22A5A-DD9E-44A1-BA2E-2A9A7C78B0EE}</ProjectGuid>
|
<ProjectGuid>{10F22A5A-DD9E-44A1-BA2E-2A9A7C78B0EE}</ProjectGuid>
|
||||||
<RootNamespace>zlib</RootNamespace>
|
<RootNamespace>zlib</RootNamespace>
|
||||||
|
|
14
configure.ac
14
configure.ac
|
@ -429,13 +429,15 @@ AS_IF([test $with_system_luajit = no],
|
||||||
[AC_SUBST([LUAJIT_CFLAGS], ['-I$(TOP)vendor/luajit/include'])
|
[AC_SUBST([LUAJIT_CFLAGS], ['-I$(TOP)vendor/luajit/include'])
|
||||||
AC_SUBST([LUAJIT_LIBS], ['$(TOP)vendor/luajit/src/libluajit.a'])])
|
AC_SUBST([LUAJIT_LIBS], ['$(TOP)vendor/luajit/src/libluajit.a'])])
|
||||||
|
|
||||||
|
AC_SUBST(with_system_luajit)
|
||||||
|
|
||||||
# We also need a Lua binary to run part of the build system
|
# We also need a Lua binary to run part of the build system
|
||||||
# Which version doesn't matter as the scripts are portable between them
|
# Which version doesn't matter as the scripts are portable between them
|
||||||
AC_CHECK_PROGS([LUA], [lua luajit lua5.3 lua-5.3 lua5.2 lua-5.2 lua5.1 lua-5.1])
|
AC_PATH_PROGS([LUA], [luajit lua lua5.3 lua-5.3 lua5.2 lua-5.2 lua5.1 lua-5.1])
|
||||||
|
|
||||||
# If the user doesn't have an installed copy of Lua, just use the one built
|
# If the user doesn't have an installed copy of Lua, just use the one built
|
||||||
# as part of building LuaJIT
|
# as part of building LuaJIT
|
||||||
AS_IF([test -z $LUA], [LUA="$srcdir/vendor/luajit/src/host/minilua"])
|
AS_IF([test -z $LUA], [LUA='$(TOP)vendor/luajit/src/host/minilua'])
|
||||||
|
|
||||||
######################################################
|
######################################################
|
||||||
# Debugging support
|
# Debugging support
|
||||||
|
@ -521,16 +523,16 @@ AC_MSG_CHECKING([for update checker server])
|
||||||
AC_ARG_WITH(update-server,
|
AC_ARG_WITH(update-server,
|
||||||
AS_HELP_STRING([--with-update-server=HOSTNAME],
|
AS_HELP_STRING([--with-update-server=HOSTNAME],
|
||||||
[Server to use for the update checker
|
[Server to use for the update checker
|
||||||
[updates.aegisub.org]]))
|
[mugen.karaokes.moe]]))
|
||||||
AC_MSG_RESULT(${with_update_server:=updates.aegisub.org})
|
AC_MSG_RESULT(${with_update_server:=mugen.karaokes.moe})
|
||||||
AC_DEFINE_UNQUOTED([UPDATE_CHECKER_SERVER], ["$with_update_server"],
|
AC_DEFINE_UNQUOTED([UPDATE_CHECKER_SERVER], ["$with_update_server"],
|
||||||
[Server for the update checker])
|
[Server for the update checker])
|
||||||
|
|
||||||
AC_MSG_CHECKING([for update checker base URL])
|
AC_MSG_CHECKING([for update checker base URL])
|
||||||
AC_ARG_WITH(update-url,
|
AC_ARG_WITH(update-url,
|
||||||
AS_HELP_STRING([--with-update-url=HOSTNAME],
|
AS_HELP_STRING([--with-update-url=HOSTNAME],
|
||||||
[Base path to use for the update checker [/trunk]]))
|
[Base path to use for the update checker [/downloads/aegisub-japan7]]))
|
||||||
AC_MSG_RESULT(${with_update_url:=/trunk})
|
AC_MSG_RESULT(${with_update_url:=/downloads/aegisub-japan7})
|
||||||
AC_DEFINE_UNQUOTED([UPDATE_CHECKER_BASE_URL], ["$with_update_url"],
|
AC_DEFINE_UNQUOTED([UPDATE_CHECKER_BASE_URL], ["$with_update_url"],
|
||||||
[Base path for the update checker])
|
[Base path for the update checker])
|
||||||
|
|
||||||
|
|
|
@ -13,7 +13,10 @@ subdirs := \
|
||||||
tests \
|
tests \
|
||||||
tools \
|
tools \
|
||||||
vendor/luabins \
|
vendor/luabins \
|
||||||
vendor/luajit
|
|
||||||
|
ifeq (no, $(SYSTEM_LUAJIT))
|
||||||
|
subdirs += vendor/luajit
|
||||||
|
endif
|
||||||
|
|
||||||
subdirs := $(addprefix $(TOP),$(addsuffix /Makefile,$(subdirs)))
|
subdirs := $(addprefix $(TOP),$(addsuffix /Makefile,$(subdirs)))
|
||||||
|
|
||||||
|
|
|
@ -36,10 +36,22 @@
|
||||||
|
|
||||||
[Files]
|
[Files]
|
||||||
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\cleantags-autoload.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\cleantags-autoload.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\karaoke-auto-leadin.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
|
||||||
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\kara-templater.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\kara-templater.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\select-overlaps.moon; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\select-overlaps.moon; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\strip-tags.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\cleantags-autoload.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\duetto-meika.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\karaoke-adjust-1sec.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\karaoke-split.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\kara-templater.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\ua.BlurAndGlow.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\ua.ChangeCase.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\ua.Colorize.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\ua.Cycles.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\ua.FadeWorks.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\ua.HYDRA.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\ua.ScriptCleanup.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
DestDir: {app}\automation\autoload; Source: ..\..\automation\autoload\unkf.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\bundled
|
||||||
|
|
||||||
|
|
||||||
DestDir: {app}\automation\demos; Source: ..\..\automation\demos\future-windy-blur.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\demos
|
DestDir: {app}\automation\demos; Source: ..\..\automation\demos\future-windy-blur.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\demos
|
||||||
DestDir: {app}\automation\demos; Source: ..\..\automation\demos\raytracer.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\demos
|
DestDir: {app}\automation\demos; Source: ..\..\automation\demos\raytracer.lua; Flags: ignoreversion overwritereadonly uninsremovereadonly; Attribs: readonly; Components: macros\demos
|
||||||
|
|
|
@ -34,8 +34,8 @@
|
||||||
|
|
||||||
[Files]
|
[Files]
|
||||||
; Avisynth
|
; Avisynth
|
||||||
DestDir: {app}; Source: vendor\AvisynthPlus64\devil.dll; Flags: ignoreversion; Components: main
|
DestDir: {app}; Source: ..\..\bin\devil.dll; Flags: ignoreversion; Components: main
|
||||||
DestDir: {app}; Source: vendor\AvisynthPlus64\avisynth.dll; Flags: ignoreversion; Components: main
|
DestDir: {app}; Source: ..\..\bin\avisynth.dll; Flags: ignoreversion; Components: main
|
||||||
DestDir: {app}; Source: vendor\AvisynthPlus64\DirectShowSource.dll; Flags: ignoreversion; Components: main
|
DestDir: {app}; Source: ..\..\bin\DirectShowSource.dll; Flags: ignoreversion; Components: main
|
||||||
; VSFilter
|
; VSFilter
|
||||||
DestDir: {app}\csri; Source: vendor\xy-vsfilter\xy-vsfilter-aegisub64.dll; Flags: ignoreversion; Components: main
|
DestDir: {app}\csri; Source: ..\..\bin\csri\xy-vsfilter-aegisub64.dll; Flags: ignoreversion; Components: main
|
||||||
|
|
|
@ -32,7 +32,8 @@
|
||||||
; Contact: mailto:nielsm@indvikleren.dk
|
; Contact: mailto:nielsm@indvikleren.dk
|
||||||
;
|
;
|
||||||
|
|
||||||
#include "../../build/git_version.h"
|
#define BUILD_GIT_VERSION_STRING "Japan7 0.9"
|
||||||
|
#define INSTALLER_VERSION 1
|
||||||
|
|
||||||
[Setup]
|
[Setup]
|
||||||
AppName=Aegisub
|
AppName=Aegisub
|
||||||
|
@ -62,27 +63,22 @@ UninstallDisplayIcon={app}\aegisub{#ARCH}.exe
|
||||||
WizardImageFile=welcome-large.bmp
|
WizardImageFile=welcome-large.bmp
|
||||||
WizardSmallImageFile=aegisub-large.bmp
|
WizardSmallImageFile=aegisub-large.bmp
|
||||||
|
|
||||||
OutputBaseFilename=Aegisub-{#BUILD_GIT_VERSION_STRING}-{#ARCH}
|
OutputBaseFilename=Aegisub-Japan7-x64
|
||||||
VersionInfoDescription=Aegisub {#BUILD_GIT_VERSION_STRING} {#ARCH}-bit
|
VersionInfoDescription=Aegisub {#BUILD_GIT_VERSION_STRING} x64
|
||||||
|
|
||||||
[Languages]
|
[Languages]
|
||||||
Name: "en"; MessagesFile: "compiler:Default.isl"
|
Name: "en"; MessagesFile: "compiler:Default.isl"
|
||||||
Name: "bg"; MessagesFile: "compiler:Languages\Bulgarian.isl"
|
|
||||||
Name: "ca"; MessagesFile: "compiler:Languages\Catalan.isl"
|
Name: "ca"; MessagesFile: "compiler:Languages\Catalan.isl"
|
||||||
Name: "cz"; MessagesFile: "compiler:Languages\Czech.isl"
|
Name: "cz"; MessagesFile: "compiler:Languages\Czech.isl"
|
||||||
Name: "da"; MessagesFile: "compiler:Languages\Danish.isl"
|
Name: "da"; MessagesFile: "compiler:Languages\Danish.isl"
|
||||||
Name: "de"; MessagesFile: "compiler:Languages\German.isl"
|
Name: "de"; MessagesFile: "compiler:Languages\German.isl"
|
||||||
Name: "el"; MessagesFile: "compiler:Languages\Greek.isl"
|
Name: "el"; MessagesFile: "compiler:Languages\Greek.isl"
|
||||||
Name: "es"; MessagesFile: "compiler:Languages\Spanish.isl"
|
Name: "es"; MessagesFile: "compiler:Languages\Spanish.isl"
|
||||||
Name: "eu"; MessagesFile: "compiler:Languages\Basque.isl"
|
|
||||||
Name: "fi"; MessagesFile: "compiler:Languages\Finnish.isl"
|
Name: "fi"; MessagesFile: "compiler:Languages\Finnish.isl"
|
||||||
Name: "fr_FR"; MessagesFile: "compiler:Languages\French.isl"
|
Name: "fr_FR"; MessagesFile: "compiler:Languages\French.isl"
|
||||||
Name: "gl"; MessagesFile: "compiler:Languages\Galician.isl"
|
|
||||||
Name: "hu"; MessagesFile: "compiler:Languages\Hungarian.isl"
|
Name: "hu"; MessagesFile: "compiler:Languages\Hungarian.isl"
|
||||||
Name: "id"; MessagesFile: "compiler:Languages\Indonesian.isl"
|
|
||||||
Name: "it"; MessagesFile: "compiler:Languages\Italian.isl"
|
Name: "it"; MessagesFile: "compiler:Languages\Italian.isl"
|
||||||
Name: "ja"; MessagesFile: "compiler:Languages\Japanese.isl"
|
Name: "ja"; MessagesFile: "compiler:Languages\Japanese.isl"
|
||||||
Name: "ko"; MessagesFile: "compiler:Languages\Korean.isl"
|
|
||||||
Name: "nl"; MessagesFile: "compiler:Languages\Dutch.isl"
|
Name: "nl"; MessagesFile: "compiler:Languages\Dutch.isl"
|
||||||
Name: "pl"; MessagesFile: "compiler:Languages\Polish.isl"
|
Name: "pl"; MessagesFile: "compiler:Languages\Polish.isl"
|
||||||
Name: "pt_BR"; MessagesFile: "compiler:Languages\BrazilianPortuguese.isl"
|
Name: "pt_BR"; MessagesFile: "compiler:Languages\BrazilianPortuguese.isl"
|
||||||
|
@ -91,8 +87,6 @@ Name: "ru"; MessagesFile: "compiler:Languages\Russian.isl"
|
||||||
Name: "sr_RS"; MessagesFile: "compiler:Languages\SerbianCyrillic.isl"
|
Name: "sr_RS"; MessagesFile: "compiler:Languages\SerbianCyrillic.isl"
|
||||||
Name: "sr_RS_latin"; MessagesFile: "compiler:Languages\SerbianLatin.isl"
|
Name: "sr_RS_latin"; MessagesFile: "compiler:Languages\SerbianLatin.isl"
|
||||||
Name: "uk_UA"; MessagesFile: "compiler:Languages\Ukrainian.isl"
|
Name: "uk_UA"; MessagesFile: "compiler:Languages\Ukrainian.isl"
|
||||||
Name: "zh_CN"; MessagesFile: "compiler:Languages\ChineseSimplified.isl"
|
|
||||||
Name: "zh_TW"; MessagesFile: "compiler:Languages\ChineseTraditional.isl"
|
|
||||||
|
|
||||||
[Files]
|
[Files]
|
||||||
; small bitmaps (used by beautify code)
|
; small bitmaps (used by beautify code)
|
||||||
|
|
|
@ -1,44 +1,24 @@
|
||||||
[CustomMessages]
|
[CustomMessages]
|
||||||
InstallRuntime=Installing runtime libraries...
|
InstallRuntime=Installing runtime libraries...
|
||||||
el.InstallRuntime=Εγκατάσταση βιβλιοθηκών...
|
el.InstallRuntime=Εγκατάσταση βιβλιοθηκών...
|
||||||
eu.InstallRuntime=Runtime liburutegiak ezartzen...
|
|
||||||
id.InstallRuntime=Memasang runtime libraries...
|
|
||||||
pt_PT.InstallRuntime=A instalar livrarias de runtime...
|
pt_PT.InstallRuntime=A instalar livrarias de runtime...
|
||||||
uk_UA.InstallRuntime=Встановлюю бібліотеки реального часу...
|
uk_UA.InstallRuntime=Встановлюю бібліотеки реального часу...
|
||||||
zh_CN.InstallRuntime=正在安装运行库……
|
|
||||||
zh_TW.InstallRuntime=正在安裝運行庫……
|
|
||||||
StartMenuIcon=Create a start menu icon
|
StartMenuIcon=Create a start menu icon
|
||||||
el.StartMenuIcon=Δημιουργία εικονιδίου στο μενού έναρξης
|
el.StartMenuIcon=Δημιουργία εικονιδίου στο μενού έναρξης
|
||||||
eu.StartMenuIcon=Sortu hasiera menuko ikur bat
|
|
||||||
id.StartMenuIcon=Buat ikon di menu awal
|
|
||||||
pt_PT.StartMenuIcon=Criar ícone no menu iniciar
|
pt_PT.StartMenuIcon=Criar ícone no menu iniciar
|
||||||
uk_UA.StartMenuIcon=Створити піктограму в меню Запустити
|
uk_UA.StartMenuIcon=Створити піктограму в меню Запустити
|
||||||
zh_CN.StartMenuIcon=创建开始菜单图标
|
|
||||||
zh_TW.StartMenuIcon=創建開始功能表圖示
|
|
||||||
CheckForUpdates=Automatically check for new versions of Aegisub
|
CheckForUpdates=Automatically check for new versions of Aegisub
|
||||||
el.CheckForUpdates=Αυτόματος έλεγχος για καινούριες εκδόσεις του Aegisub
|
el.CheckForUpdates=Αυτόματος έλεγχος για καινούριες εκδόσεις του Aegisub
|
||||||
eu.CheckForUpdates=Berezgaitasunez egiaztatu Aegisub-ren bertsio berririk dagoen
|
|
||||||
id.CheckForUpdates=Otomatis cek versi terbaru Aegisub
|
|
||||||
pt_PT.CheckForUpdates=Verifica automaticamente a existência de novas versões do Aegisub
|
pt_PT.CheckForUpdates=Verifica automaticamente a existência de novas versões do Aegisub
|
||||||
uk_UA.CheckForUpdates=Автоматично перевіряти Aegisub на нові версії
|
uk_UA.CheckForUpdates=Автоматично перевіряти Aegisub на нові версії
|
||||||
zh_CN.CheckForUpdates=自动检查Aegisub的新版本
|
|
||||||
zh_TW.CheckForUpdates=自動檢查Aegisub的新版本
|
|
||||||
UpdatesGroup=Update Checker:
|
UpdatesGroup=Update Checker:
|
||||||
el.UpdatesGroup=Έλεγχος Ενημερώσεων:
|
el.UpdatesGroup=Έλεγχος Ενημερώσεων:
|
||||||
eu.UpdatesGroup=Eguneraketa Egiaztatzailea:
|
|
||||||
id.UpdatesGroup=Pemeriksa Pembaharuan
|
|
||||||
pt_PT.UpdatesGroup=Verificar Actualizações:
|
pt_PT.UpdatesGroup=Verificar Actualizações:
|
||||||
uk_UA.UpdatesGroup=Модуль Перевірки на Оновлення:
|
uk_UA.UpdatesGroup=Модуль Перевірки на Оновлення:
|
||||||
zh_CN.UpdatesGroup=自动更新:
|
|
||||||
zh_TW.UpdatesGroup=自動更新:
|
|
||||||
|
|
||||||
; Replacement for License page, no need to bother the user with legal mumbo-jumbo
|
; Replacement for License page, no need to bother the user with legal mumbo-jumbo
|
||||||
[Messages]
|
[Messages]
|
||||||
WelcomeLabel2=This will install Aegisub {#BUILD_GIT_VERSION_STRING} on your computer.%n%nAegisub is covered by the GNU General Public License version 2. This means you may use the application for any purpose without charge, but that no warranties of any kind are given either.%n%nSee the Aegisub website for information on obtaining the source code.
|
WelcomeLabel2=This will install Aegisub {#BUILD_GIT_VERSION_STRING} on your computer.%n%nAegisub is covered by the GNU General Public License version 2. This means you may use the application for any purpose without charge, but that no warranties of any kind are given either.%n%nSee the Aegisub website for information on obtaining the source code.
|
||||||
el.WelcomeLabel2=Αυτό θα εγκαταστήσει το Aegisub {#BUILD_GIT_VERSION_STRING} στον υπολογιστή σας.%n%nΤο Aegisub καλύπτεται από τον άδεια GNU General Public License version 2. Αυτό σημαίνει ότι μπορείτε να χρησιμοποιήσετε την εφαρμογή για κάθε σκοπό χωρίς χρέωση, αλλά δεν υπάρχουν εγγυήσεις καμίας φύσης.%n%nΔείτε την ιστοσελίδα του Aegisub για πληροφορίες σχετικά με την απόκτηση του πηγαίου κώδικα.
|
el.WelcomeLabel2=Αυτό θα εγκαταστήσει το Aegisub {#BUILD_GIT_VERSION_STRING} στον υπολογιστή σας.%n%nΤο Aegisub καλύπτεται από τον άδεια GNU General Public License version 2. Αυτό σημαίνει ότι μπορείτε να χρησιμοποιήσετε την εφαρμογή για κάθε σκοπό χωρίς χρέωση, αλλά δεν υπάρχουν εγγυήσεις καμίας φύσης.%n%nΔείτε την ιστοσελίδα του Aegisub για πληροφορίες σχετικά με την απόκτηση του πηγαίου κώδικα.
|
||||||
eu.WelcomeLabel2=Honek Aegisub {#BUILD_GIT_VERSION_STRING} ezarriko du zure ordenagailuan.%n%nAegisub GNU Baimen Publiko Orokorra 2. bertsioa Baimenak estalia dago. Honek esanahi du aplikazio hau edozein asmotarako erabili dezakezula ordaindu behar izan gabe, baina ez da inolako berme motarik ematen.%n%nIkusi Aegisub webgunea iturburu kodea lortzeko argibideetarako.
|
|
||||||
id.WelcomeLabel2=Ini akan memasang Aegisub {#BUILD_GIT_VERSION_STRING} di komputer Anda.%n%nAegisub dilindungi oleh Lisensi Publik Umum GNU versi 2. Artinya Anda bisa menggunakan aplikasi ini untuk tujuan apa pun tanpad dipungut biaya, tapi tidak ada jaminan yang bisa diberikan.%n%nLihat laman situs Aegisub untuk memperoleh informasi sumber kode.
|
|
||||||
pt_PT.WelcomeLabel2=Irá ser instalado no seu computador a versão {#BUILD_GIT_VERSION_STRING} do Aegisub.%n%nO Aegisub está protegido sob a Licença Pública Geral GNU (GPL version 2). O que significa que poderá fazer uso da aplicação para qualquer propósito, sem que seja cobrado, mas não serão dadas quaisquer tipos de garantias.%n%nVeja a página do Aegisub para mais informações sobre como obter o código-fonte.
|
pt_PT.WelcomeLabel2=Irá ser instalado no seu computador a versão {#BUILD_GIT_VERSION_STRING} do Aegisub.%n%nO Aegisub está protegido sob a Licença Pública Geral GNU (GPL version 2). O que significa que poderá fazer uso da aplicação para qualquer propósito, sem que seja cobrado, mas não serão dadas quaisquer tipos de garantias.%n%nVeja a página do Aegisub para mais informações sobre como obter o código-fonte.
|
||||||
uk_UA.WelcomeLabel2=Зараз буде встанвлено Aegisub {#BUILD_GIT_VERSION_STRING} на ваш комп'ютер.%n%nAegisub захищено універсальною громадською ліцензією GNU, версія 2. Це означає, що ви можете використосувати цю програму для будь яких цілей безкоштовно, але, в будь-якому випадку, ми не даємо жодних гарантій.%n%nДивіться сайт Aegisub для інформації щодо отримання вихідного коду.
|
uk_UA.WelcomeLabel2=Зараз буде встанвлено Aegisub {#BUILD_GIT_VERSION_STRING} на ваш комп'ютер.%n%nAegisub захищено універсальною громадською ліцензією GNU, версія 2. Це означає, що ви можете використосувати цю програму для будь яких цілей безкоштовно, але, в будь-якому випадку, ми не даємо жодних гарантій.%n%nДивіться сайт Aegisub для інформації щодо отримання вихідного коду.
|
||||||
zh_CN.WelcomeLabel2=将会在您的电脑上安装Aegisub {#BUILD_GIT_VERSION_STRING} 。%n%n Aegisub适用于GNU通用公共许可证第二版(GPLv2),这意味着您可以将该应用程序用于任何目的而不需要支付费用,但同时也不会得到任何形式的担保。%n%n您可以到Aegisub官网获取源代码信息。
|
|
||||||
zh_TW.WelcomeLabel2=將會在您的電腦上安裝Aegisub {#BUILD_GIT_VERSION_STRING} 。%n%n Aegisub適用於GNU通用公共許可證第二版(GPLv2),這意味著您可以將該應用程式用於任何目的而不需要支付費用,但同時也不會得到任何形式的擔保。%n%n您可以到Aegisub官網獲取原始程式碼資訊。
|
|
||||||
|
|
|
@ -38,61 +38,61 @@
|
||||||
[Files]
|
[Files]
|
||||||
; localization (commented out ones are out of date; some don't have wxstd.mo)
|
; localization (commented out ones are out of date; some don't have wxstd.mo)
|
||||||
Source: ..\..\po\ar.mo; DestDir: {app}\locale\ar; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\ar.mo; DestDir: {app}\locale\ar; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-ar.mo; DestDir: {app}\locale\ar; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-ar.mo; DestDir: {app}\locale\ar; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\bg.mo; DestDir: {app}\locale\bg; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\bg.mo; DestDir: {app}\locale\bg; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
; Missing wxstd for Bulgarian
|
; Missing wxstd for Bulgarian
|
||||||
Source: ..\..\po\ca.mo; DestDir: {app}\locale\ca; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\ca.mo; DestDir: {app}\locale\ca; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-ca.mo; DestDir: {app}\locale\ca; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-ca.mo; DestDir: {app}\locale\ca; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\cs.mo; DestDir: {app}\locale\cs; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\cs.mo; DestDir: {app}\locale\cs; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-cs.mo; DestDir: {app}\locale\cs; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-cs.mo; DestDir: {app}\locale\cs; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\da.mo; DestDir: {app}\locale\da; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\da.mo; DestDir: {app}\locale\da; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-da.mo; DestDir: {app}\locale\da; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-da.mo; DestDir: {app}\locale\da; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\de.mo; DestDir: {app}\locale\de; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\de.mo; DestDir: {app}\locale\de; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-de.mo; DestDir: {app}\locale\de; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-de.mo; DestDir: {app}\locale\de; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\el.mo; DestDir: {app}\locale\el; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\el.mo; DestDir: {app}\locale\el; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-el.mo; DestDir: {app}\locale\el; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-el.mo; DestDir: {app}\locale\el; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\es.mo; DestDir: {app}\locale\es; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\es.mo; DestDir: {app}\locale\es; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-es.mo; DestDir: {app}\locale\es; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-es.mo; DestDir: {app}\locale\es; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\eu.mo; DestDir: {app}\locale\eu; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\eu.mo; DestDir: {app}\locale\eu; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-eu.mo; DestDir: {app}\locale\eu; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-eu.mo; DestDir: {app}\locale\eu; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\fa.mo; DestDir: {app}\locale\fa; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\fa.mo; DestDir: {app}\locale\fa; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
; Farsi wxstd missing
|
; Farsi wxstd missing
|
||||||
;Source: src\mo\wxstd-fa.mo; DestDir: {app}\locale\fa; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
;Source: ..\..\po\wxstd-fa.mo; DestDir: {app}\locale\fa; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\fi.mo; DestDir: {app}\locale\fi; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\fi.mo; DestDir: {app}\locale\fi; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-fi.mo; DestDir: {app}\locale\fi; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-fi.mo; DestDir: {app}\locale\fi; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\fr_FR.mo; DestDir: {app}\locale\fr_FR; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\fr_FR.mo; DestDir: {app}\locale\fr_FR; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-fr.mo; DestDir: {app}\locale\fr_FR; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-fr.mo; DestDir: {app}\locale\fr_FR; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\gl.mo; DestDir: {app}\locale\gl; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\gl.mo; DestDir: {app}\locale\gl; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-gl_ES.mo; DestDir: {app}\locale\gl; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-gl_ES.mo; DestDir: {app}\locale\gl; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\hu.mo; DestDir: {app}\locale\hu; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\hu.mo; DestDir: {app}\locale\hu; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-hu.mo; DestDir: {app}\locale\hu; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-hu.mo; DestDir: {app}\locale\hu; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\id.mo; DestDir: {app}\locale\id; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\id.mo; DestDir: {app}\locale\id; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-id.mo; DestDir: {app}\locale\id; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-id.mo; DestDir: {app}\locale\id; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\it.mo; DestDir: {app}\locale\it; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\it.mo; DestDir: {app}\locale\it; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-it.mo; DestDir: {app}\locale\it; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-it.mo; DestDir: {app}\locale\it; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\ja.mo; DestDir: {app}\locale\ja; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\ja.mo; DestDir: {app}\locale\ja; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-ja.mo; DestDir: {app}\locale\ja; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-ja.mo; DestDir: {app}\locale\ja; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\ko.mo; DestDir: {app}\locale\ko; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\ko.mo; DestDir: {app}\locale\ko; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-ko_KR.mo; DestDir: {app}\locale\ko; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-ko_KR.mo; DestDir: {app}\locale\ko; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\nl.mo; DestDir: {app}\locale\nl; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\nl.mo; DestDir: {app}\locale\nl; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-nl.mo; DestDir: {app}\locale\nl; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-nl.mo; DestDir: {app}\locale\nl; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\pl.mo; DestDir: {app}\locale\pl; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\pl.mo; DestDir: {app}\locale\pl; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-pl.mo; DestDir: {app}\locale\pl; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-pl.mo; DestDir: {app}\locale\pl; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\pt_BR.mo; DestDir: {app}\locale\pt_BR; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\pt_BR.mo; DestDir: {app}\locale\pt_BR; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-pt_BR.mo; DestDir: {app}\locale\pt_BR; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-pt_BR.mo; DestDir: {app}\locale\pt_BR; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\pt_PT.mo; DestDir: {app}\locale\pt_PT; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\pt_PT.mo; DestDir: {app}\locale\pt_PT; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-pt.mo; DestDir: {app}\locale\pt_PT; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-pt.mo; DestDir: {app}\locale\pt_PT; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\ru.mo; DestDir: {app}\locale\ru; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\ru.mo; DestDir: {app}\locale\ru; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-ru.mo; DestDir: {app}\locale\ru; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-ru.mo; DestDir: {app}\locale\ru; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\sr_RS.mo; DestDir: {app}\locale\sr_RS; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\sr_RS.mo; DestDir: {app}\locale\sr_RS; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\sr_RS@latin.mo; DestDir: {app}\locale\sr_RS@latin; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\sr_RS@latin.mo; DestDir: {app}\locale\sr_RS@latin; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
; Missing wxstd for Serbian
|
; Missing wxstd for Serbian
|
||||||
Source: ..\..\po\uk_UA.mo; DestDir: {app}\locale\uk_UA; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\uk_UA.mo; DestDir: {app}\locale\uk_UA; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-uk_UA.mo; DestDir: {app}\locale\uk_UA; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-uk_UA.mo; DestDir: {app}\locale\uk_UA; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\vi.mo; DestDir: {app}\locale\vi; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\vi.mo; DestDir: {app}\locale\vi; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-vi.mo; DestDir: {app}\locale\vi; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-vi.mo; DestDir: {app}\locale\vi; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\zh_CN.mo; DestDir: {app}\locale\zh_CN; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\zh_CN.mo; DestDir: {app}\locale\zh_CN; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-zh_CN.mo; DestDir: {app}\locale\zh_CN; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-zh_CN.mo; DestDir: {app}\locale\zh_CN; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: ..\..\po\zh_TW.mo; DestDir: {app}\locale\zh_TW; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\zh_TW.mo; DestDir: {app}\locale\zh_TW; DestName: aegisub.mo; Flags: ignoreversion; Components: translations
|
||||||
Source: src\mo\wxstd-zh_TW.mo; DestDir: {app}\locale\zh_TW; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
Source: ..\..\po\wxstd-zh_TW.mo; DestDir: {app}\locale\zh_TW; DestName: wxstd.mo; Flags: ignoreversion; Components: translations
|
||||||
|
|
||||||
|
|
|
@ -111,11 +111,16 @@ src_OBJ := \
|
||||||
$(d)video_provider_yuv4mpeg.o \
|
$(d)video_provider_yuv4mpeg.o \
|
||||||
$(d)video_slider.o \
|
$(d)video_slider.o \
|
||||||
$(d)visual_feature.o \
|
$(d)visual_feature.o \
|
||||||
$(LIBS_LUA) \
|
|
||||||
$(TOP)lib/libaegisub.a \
|
$(TOP)lib/libaegisub.a \
|
||||||
$(TOP)lib/libluabins.a \
|
$(TOP)lib/libluabins.a \
|
||||||
$(TOP)lib/libresrc.a \
|
$(TOP)lib/libresrc.a \
|
||||||
|
|
||||||
|
ifeq (no, $(SYSTEM_LUAJIT))
|
||||||
|
src_OBJ += $(LIBS_LUA)
|
||||||
|
else
|
||||||
|
src_LIBS += $(LIBS_LUA)
|
||||||
|
endif
|
||||||
|
|
||||||
ifeq (yes, $(BUILD_DARWIN))
|
ifeq (yes, $(BUILD_DARWIN))
|
||||||
src_OBJ += $(d)font_file_lister_coretext.o
|
src_OBJ += $(d)font_file_lister_coretext.o
|
||||||
src_OBJ += $(patsubst %.mm,%.o,$(sort $(wildcard $(d)osx/*.mm)))
|
src_OBJ += $(patsubst %.mm,%.o,$(sort $(wildcard $(d)osx/*.mm)))
|
||||||
|
|
|
@ -45,7 +45,7 @@
|
||||||
#include <wx/intl.h>
|
#include <wx/intl.h>
|
||||||
|
|
||||||
AssStyle::AssStyle() {
|
AssStyle::AssStyle() {
|
||||||
std::fill(Margin.begin(), Margin.end(), 10);
|
std::fill(Margin.begin(), Margin.end(), 30);
|
||||||
|
|
||||||
UpdateData();
|
UpdateData();
|
||||||
}
|
}
|
||||||
|
|
|
@ -40,11 +40,11 @@ class AssStyle final : public AssEntry, public AssEntryListHook {
|
||||||
|
|
||||||
public:
|
public:
|
||||||
std::string name = "Default"; ///< Name of the style; must be case-insensitively unique within a file despite being case-sensitive
|
std::string name = "Default"; ///< Name of the style; must be case-insensitively unique within a file despite being case-sensitive
|
||||||
std::string font = "Arial"; ///< Font face name
|
std::string font = "Amaranth"; ///< Font face name
|
||||||
double fontsize = 20.; ///< Font size
|
double fontsize = 60.; ///< Font size
|
||||||
|
|
||||||
agi::Color primary{ 255, 255, 255 }; ///< Default text color
|
agi::Color primary{ 255, 132, 0 }; ///< Default text color
|
||||||
agi::Color secondary{ 255, 0, 0 }; ///< Text color for not-yet-reached karaoke syllables
|
agi::Color secondary{ 255, 255, 255 }; ///< Text color for not-yet-reached karaoke syllables
|
||||||
agi::Color outline{ 0, 0, 0 }; ///< Outline color
|
agi::Color outline{ 0, 0, 0 }; ///< Outline color
|
||||||
agi::Color shadow{ 0, 0, 0 }; ///< Shadow color
|
agi::Color shadow{ 0, 0, 0 }; ///< Shadow color
|
||||||
|
|
||||||
|
@ -60,7 +60,7 @@ public:
|
||||||
int borderstyle = 1; ///< 1: Normal; 3: Opaque box; others are unused in Aegisub
|
int borderstyle = 1; ///< 1: Normal; 3: Opaque box; others are unused in Aegisub
|
||||||
double outline_w = 2.; ///< Outline width in pixels
|
double outline_w = 2.; ///< Outline width in pixels
|
||||||
double shadow_w = 2.; ///< Shadow distance in pixels
|
double shadow_w = 2.; ///< Shadow distance in pixels
|
||||||
int alignment = 2; ///< \an-style line alignment
|
int alignment = 8; ///< \an-style line alignment
|
||||||
std::array<int, 3> Margin; ///< Left / Right / Vertical
|
std::array<int, 3> Margin; ///< Left / Right / Vertical
|
||||||
int encoding = 1; ///< ASS font encoding needed for some non-unicode fonts
|
int encoding = 1; ///< ASS font encoding needed for some non-unicode fonts
|
||||||
|
|
||||||
|
|
Some files were not shown because too many files have changed in this diff Show More
Loading…
Reference in New Issue