-
Notifications
You must be signed in to change notification settings - Fork 272
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Chat Updater Rewrite + GUI frontend, QOL changes (#442)
* Move chatupdate functions to Core, prepare for additional update options, shorten chatupdate file/class names * Make chatdownload obey custom temp folder * Fixed all embeds being doubled with arg --embed-missing, fixed crash when embeddedData is null, made embed fetching async * Continue before processing the new embedded item * Implement chat crop moving * Rename an arg, add input = output warning, typo * Update readme * Prepare for fetching missing comments (needs #440), cleanup * Update readme * Make ChatUpdater task based * Add missing comment fetching, make default true bools nullable, add more progress reporters * Move chat crop above embed fetching due to dependency, cleanup * Fix comment appending not being fully thread-safe, add comment count report, ensure temp file is deleted, cleanup * Update readmes * Typo * Clarify ReportType enum, fix chatupdate progress reports, clamp chat crops, cleanup * Fix first party emotes not proprely checking for already added embedded emotes, fix emoji count check for Linux * Rename 'DownloadFormat' to 'ChatFormat', add exception for catching unsupported chatupdate formats * Fix future chat crop error when using non-json formats * Simplify switch expressions with pattern matching * Add GUI frontend for ChatUpdate, more UI consistency, cleanup * Fix clip chat updating, add enqueuing support * Add chat update to default settings * Didn't mean to stage that * Add output format conversion (input must still be json), cleanup * Add step counter to progress chatupdate reports * Add percent and universal constructor to ProgressReport class, add percent reports to chatupdate * Use async methods with text chat writer, combine ParseChatJson and ParseChatJsonInfo, cleanup * Update 'what can it do' section in readme * Cleanup PreParseArgs, fix #448 * Fix NRE caused by 4867ddb, fix catch block in TwitchHelper * Better solution than 552ba3b, add additional icon sizes * Add build instructions to README, remove last traces of .Net Framework, other README improvements * Fix StatusInfo not fully overwriting the previous status, Move json, html, txt chat operations to dedicated classes, Fix sample text height being computed every render tick as it is expensive, Rewrite SubstringToTextWidth() to use spans, Cleanup * Sealed core runmode classes, minor TwitchHelper optimizations, convert emoji check from LINQ to foreach (faster), use arrays instead of lists, stringbuilders instead of strings where possible, combine some Rtl and non-Rtl functions, cleanup * Only use DrawShapedText() with messages containing RTL
- Loading branch information
Showing
57 changed files
with
3,099 additions
and
1,813 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
33 changes: 0 additions & 33 deletions
33
TwitchDownloaderCLI/Modes/Arguments/ChatDownloadUpdaterArgs.cs
This file was deleted.
Oops, something went wrong.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
using CommandLine; | ||
using TwitchDownloaderCore.Options; | ||
|
||
namespace TwitchDownloaderCLI.Modes.Arguments | ||
{ | ||
|
||
[Verb("chatupdate", HelpText = "Updates the embeded emotes, badges, bits, and crops of a chat download and/or converts a JSON chat to another format.")] | ||
public class ChatUpdateArgs | ||
{ | ||
[Option('i', "input", Required = true, HelpText = "Path to input file. Valid extensions are: json.")] | ||
public string InputFile { get; set; } | ||
|
||
[Option('o', "output", Required = true, HelpText = "Path to output file. File extension will be used to determine new chat type. Valid extensions are: json, html, and txt.")] | ||
public string OutputFile { get; set; } | ||
|
||
[Option('E', "embed-missing", Default = false, HelpText = "Embed missing emotes, badges, and cheermotes. Already embedded images will be untouched.")] | ||
public bool EmbedMissing { get; set; } | ||
|
||
[Option('R', "replace-embeds", Default = false, HelpText = "Replace all embedded emotes, badges, and cheermotes in the file. All embedded images will be overwritten!")] | ||
public bool ReplaceEmbeds { get; set; } | ||
|
||
[Option('b', "beginning", Default = -1, HelpText = "New time in seconds for chat beginning. Comments may be added but not removed. -1 = No crop.")] | ||
public int CropBeginningTime { get; set; } | ||
|
||
[Option('e', "ending", Default = -1, HelpText = "New time in seconds for chat ending. Comments may be added but not removed. -1 = No crop.")] | ||
public int CropEndingTime { get; set; } | ||
|
||
[Option("bttv", Default = true, HelpText = "Enable BTTV embedding in chat download.")] | ||
public bool? BttvEmotes { get; set; } | ||
|
||
[Option("ffz", Default = true, HelpText = "Enable FFZ embedding in chat download.")] | ||
public bool? FfzEmotes { get; set; } | ||
|
||
[Option("stv", Default = true, HelpText = "Enable 7TV embedding in chat download.")] | ||
public bool? StvEmotes { get; set; } | ||
|
||
[Option("timestamp-format", Default = TimestampFormat.Relative, HelpText = "Sets the timestamp format for .txt chat logs. Valid values are: Utc, Relative, and None")] | ||
public TimestampFormat TimeFormat { get; set; } | ||
|
||
[Option("temp-path", Default = "", HelpText = "Path to temporary folder to use for cache.")] | ||
public string TempFolder { get; set; } | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.