1
0
mirror of https://github.com/odrling/Aegisub synced 2025-04-11 22:56:02 +02:00

199 Commits

Author SHA1 Message Date
arch1t3cht
0b40de8bea
C++ modernization and boost removal (#182)
* Bump boost to 1.83

* Switch to building as C++20

Co-authored-by: Ryan Lucia <ryan@luciaonline.net>

* Fix many warnings

* Rip out boost::locale and just use ICU directly

* Fix

* Replace boost::filesystem with std::filesystem

* Fix

* Addditional c++ modernization

* Use string_view all over the place and rip out more boost stuff

* Simply BOM handling in charset conversions

* libaegisub: fix dispatch types

* Fix

* Bump subprojects

* Reorganize tests build file

* Fix remaining compilation errors on Linux

* Rip out the last bits of boost::filesystem

* Remove remaining uses of boost string joins

* Fix some errors introduced with refactors

* Revert "Simply BOM handling in charset conversions"

This reverts commit 2e6b26d5ffe69d7fb280bb1d18c6758112244b64.
Taking out the BOM handling broke tests, so it'll probably break more
stuff.

* Bring back IconvWrapper::RequiredBufferSize

This partially reverts 62befa996126659d139e9ad53e631780b6ed6122 .
This function is actually used in charset_conv_win.cpp

* Fix ifind after moving to ICU

The previous logic didn't check if the match was on parts of
decomposed characters, so it also failed the corresponding test.

* Remove incorrect karaoke_matcher test

This was clearly incorrect and probably just unfinished.

* Remove leftover boost::locale code

* Move iconv include to charset_conv.h

On newer mac sdks iconv_t is defined differently, so it's harder to
just have a typedef for it.

* Fix compilation on arm64 mac

wx uses a different string implementation here, and utf8_string()
doesn't exist there.

* Fix luajit dependency in luabins project

Since luajit always first tried using dependency(), further calls
of dependency() will also always return system luajit.
meson.override_dependency() won't work.
This makes luabins link system luajit where it's available while aegisub
itself uses the subproject's luajit, which causes all kinds of fun
issues and definitely didn't baffle me four hours...

The added solution for this is horribly ugly (and also has problems when
reconfiguring...) but it's the only one I found that works. Maybe it's
better to always require interal luajit after all, or make the user
choose with a meson option?

* Fix locale initialization

Previously this would fail on startup because the automation menu
uses boost::locale::comparator.
... Or maybe the locale init change should just be reverted entirely?
Or it should be something different? I don't really know.

* Revert "Fix luajit dependency in luabins project"

This reverts commit 340fb9c6125412d18f23c08c00f2bc8f46774b6d.

* Fix luajit dependency in luabins project, take 2

Thinking about it some more, just copying the detection logic is
probably the lesser evil here.

* Fix agi::split_iterator after refactor

is_end being removed caused it to not output an empty segment at the
end if the input ends with a delimiter, but existing usages relied
on it doing that.

* Fix style parsing after refactor

* Fix tons of implicit this captures

* Enable CI to test

* Update deprecated hunspell usage

* Fix tests compilation on mac

* Make sure wx subproject builds with c++14

* Fix compilation on Windows

* Revert "Bring back IconvWrapper::RequiredBufferSize"

This reverts commit 04f4b260a08de6497c583f025090ca4f9fe1ef6d.

* Pin libass wrap for now

Apparently dependency('iconv') breaks when iconv is overridden??

* Fix compilation with wx 3.0

* Fix startup crash on Windows

windows.h was defining the ERROR macro, which shadowed the
DialogueTokenType enum variant, which broke the lexer construction.

* Fix SplitText ICU logic

Include UBRK_WORD_IDEO and check the entire rules vec. This now matches
the logic of boost::locale.

* Add test for character_count with \N and friends

* Fix ass_dialogue parsing after refactor

* Revert "Pin libass wrap for now"

This reverts commit 3802bb7272a8bf4861c09b020c9eee9e643804fc.

* Remove iconv's stdbool.h

This was breaking things (libass) and doesn't seem to be
needed any more.

* Revert changes to to_wx

These broke some things, in particular FromUTF8Unchecked seems to not
like empty strings. Probably safer to just revert.

* Fix kara replacer after refactor

* Fix karaoke timing mode after refactor

* Revert "Enable CI to test"

This reverts commit 256cbebbfc9cf4eb5c497898670ac28ce24ce2fd.

---------

Co-authored-by: Ryan Lucia <ryan@luciaonline.net>
Co-authored-by: Thomas Goyne <plorkyeran@gmail.com>
2023-12-03 10:59:50 -08:00
Ryan Lucia
4c872ff4f5 Indentation 2023-11-22 11:46:36 -08:00
TRAMBO
4776ca9dd1
Fix errors when automation scripts being loaded and os.execute not working (#156)
* fix errors when automation scripts being loaded and os.execute not working

* Update unicode-monkeypatch.lua
2022-06-08 08:36:49 -07:00
woclass
52c8fef28c
Generate Win portable.zip (#124)
* [git] ignore IDE setting, Meson subprojects

* [win_installer] rename *.mo -> *.gmo

* [win_installer] only add aeg translations

* [win_installer] split aeg/wx translations

* [win_installer] gen & pack translations

* [git] ignore hunspell source dir

* [git] ignore uchardet source dir

* [win_installer\portable] add new target `meson win-portable`

+ meson install copy `include/unicode-monkeypatch.lua`

* [win_installer\portable] make aegisub-portable-64.zip

+ remove WinRAR deps

* [win_installer\portable] using powershell

* [git] upload portable.zip

* [win_installer\portable] rm freetype

* [repo] remove Optional dependencies: WinRAR

* [repo] Update README.md, add cmd to gen zip file

* [repo] use recommended build command

* [git] remove IDE dir

* [ci] add Windows portable installer build step
2021-05-23 04:37:54 -04:00
Ryan
8394f1adca Monkeypatch script fixes 2021-03-27 12:34:18 -04:00
Ryan
e929e4a75c meson: copy monkeypatch script 2021-03-27 12:34:18 -04:00
Ryan Lucia
b7f6ac42e4 Add lua monkeypatch for Unicode support on Windows 2021-03-27 12:34:18 -04:00
Ryan
f5122a3927 meson: copy automation files to build directory
This enables running Moonscript on Windows builds without relying on system files
2021-03-27 09:30:21 -04:00
Ryan
d583744b69 Merge in work from TypesettingTools fork 2021-01-16 02:12:31 -05:00
Ryan Lucia
e3826cb17e meson: initial attempt to generate Aegisub.app on macOS 2021-01-10 03:14:12 -05:00
Ryan Lucia
c965171663 Remove autotools build system 2021-01-10 03:14:12 -05:00
Ryan Lucia
83fcab0775 Switch to newer path concatenation syntax 2021-01-10 03:14:12 -05:00
Ryan Lucia
cde5778283 Make spacing around colons consistent 2021-01-10 03:14:12 -05:00
Martin Herkt
97b4dfb7f4 Meson: add install rules 2021-01-10 03:14:12 -05:00
Ryan Lucia
d660f7f2b0 Add support for setting status bar text from Lua 2019-09-22 17:39:43 -07:00
wangqr
42552e5efb Correctly handle memory free using Lua GC
Instead of manually free. Otherwise return value of `search' may refer to invalid memory.
Fix Aegisub/Aegisub#99
2019-09-22 19:12:23 -04:00
Ryan Lucia
10814a7d0b Add support for setting status bar text from Lua 2018-04-30 02:38:11 -04:00
rr-
4791222ab3 Add support for reading waveform selection in LUA 2018-03-03 12:51:49 -08:00
Ryan Lucia
3c5b61429a Update moonscript version
Current version is from
491f2352a2
2018-03-03 12:46:20 -08:00
Thomas Goyne
bc157d9bbc Also stub out the system lua module that newer versions of busted use 2018-03-03 12:44:31 -08:00
Martin Herkt
3594ade719 build: sort wildcard results for repeatable builds (#44) 2017-03-30 10:08:30 -07:00
Yao
931613381c Fix typo 2016-07-09 16:25:40 +08:00
Thomas Goyne
893b08a19c Add CFLAGS_PTHREAD/LIBS_PTHREAD to everything needing them
Closes #1903.
2016-03-05 11:23:46 -08:00
Thomas Goyne
fa2e3fb38f More cruft to support running busted on Travis 2015-12-22 17:43:25 -08:00
Thomas Goyne
26361c5003 Add support for using busted 2.0 to run automation tests
Supply a definition of socket.gettime() to remove the dependency on
LuaSocket, as installing binary deps from luarocks doesn't work with a
custom build of luajit.
2015-12-21 19:48:23 -08:00
Thomas Goyne
c49dd8bd96 Ensure luarocks env variables are set for make-automation 2015-09-13 11:54:32 +02:00
Thomas Goyne
8cd970eb53 Update moonscript to 0.3.1 2015-05-09 10:54:34 -07:00
Thomas Goyne
7a8fda007d Cancel karaoke templater execution immediately when an error occurs
Closes #1849.
2015-03-01 11:22:50 -08:00
Thomas Goyne
9466c98fd7 Remove trailing whitespace from kara-templater.lua 2015-03-01 11:20:15 -08:00
Niels Martin Hansen
0f3bca016e Fix bug introduced in 15d26dd 2015-01-23 19:28:40 +01:00
Thomas Goyne
6d74f22e92 Fix the legacy clipboard include 2014-12-25 21:09:06 -08:00
Thomas Goyne
15d26dd86f Slightly speed up karaskel.collect_head 2014-12-24 15:10:12 -08:00
Thomas Goyne
1fd44ea8da Add subtitles.script_resolution()
Returns the values from the headers if they're present, or does the
insane Gabest-logic if one or both are missing.
2014-12-24 15:10:12 -08:00
Thomas Goyne
57d66be785 Fix skipping trailing empty segments in re.split 2014-09-20 08:13:49 -07:00
Thomas Goyne
5b47758539 Convert the clipboard module to the ffi 2014-07-28 15:52:37 -07:00
Thomas Goyne
e3c60514cd Add lua argument checker 2014-07-28 12:30:45 -07:00
Thomas Goyne
74a215f642 Convert the re module over to the LuaJIT ffi 2014-07-28 12:30:44 -07:00
Thomas Goyne
0cf35894e1 Convert the lfs module to using the ffi 2014-07-28 12:30:44 -07:00
Thomas Goyne
4f08afd808 Convert the unicode lua module over to using the ffi 2014-07-28 12:30:44 -07:00
Thomas Goyne
eb0cf90433 Ensure the lua state gets closed when running tests
This is required for the gc metamethods to actually get run.
2014-07-23 15:29:55 -07:00
Thomas Goyne
4dc38447dc Check the return value from lua_open()
It always fails when running under valgrind because valgrind does not
implement mmap functionality that LuaJIT requires.
2014-07-11 09:26:58 -07:00
Thomas Goyne
365c04333c Install the unicode-compatible Lua module loader before loading moonscript
Closes #1760.
2014-07-07 09:23:36 -07:00
Thomas Goyne
6fab17d860 Add basic tests for lfs 2014-07-04 10:52:38 -07:00
Thomas Goyne
68eaab0f43 Convert the build system to non-recursive make
Speeds up a no-op build from 500ms to 60ms and significantly improves
dependency tracking.
2014-06-17 11:37:20 -07:00
Thomas Goyne
6500b379bd Remove all distfile stuff from the build system
It's unused and out of date.
2014-06-09 17:20:56 -07:00
Thomas Goyne
8d26c66d0f Remove a bunch of unused functionalty from agi::Exception 2014-05-30 11:53:14 -07:00
Thomas Goyne
6a8958f287 Delete the Clean Script Info macro
It doesn't actually do anything anymore.
2014-05-22 09:29:15 -07:00
tophf
01dc7f9294 Only process selected lines in the Select Overlaps macro
And skip over commented lines as the description claimed it did already.

Closes #1751.
2014-05-09 10:25:13 -07:00
Thomas Goyne
94a060a556 Add unicode case conversion functions to the automation module 2014-05-09 07:00:48 -07:00
Thomas Goyne
a5a6d5da86 Restore the BOM-skipping logic to the Lua script reader
And add BOM to one of the test files to verify it works.
2014-04-28 10:21:54 -07:00