Free, open-source file converter. Convert 263 formats offline by drag & drop — images, PDF, Word, Excel, PowerPoint, HWP/HWPX, video, audio, e-books and archives. No upload, no Office needed.
C# audio-converteravaloniabatch-conversionconvertercsharpdocument-converterdocx-to-pdfdotnetdrag-and-dropfile-conversionfile-converterheic-converterhwphwpximage-converterlinuxmacospdf-convertervideo-converterwindows
Request a format Filee can't read, from the donut and the toast
KnifeLemon1f7623cfb0bd
diff --git a/.github/ISSUE_TEMPLATE/feature_request.md b/.github/ISSUE_TEMPLATE/feature_request.mdindex 31a3b620..9972da85 100644--- a/.github/ISSUE_TEMPLATE/feature_request.md+++ b/.github/ISSUE_TEMPLATE/feature_request.md@@ -1,6 +1,6 @@---name: Feature request-about: A new format, preset option or idea+about: A preset option, engine or idea (a file type Filee can't open goes in "Format request")labels: enhancement---diff --git a/.github/ISSUE_TEMPLATE/format_request.yml b/.github/ISSUE_TEMPLATE/format_request.ymlnew file mode 100644index 00000000..9776cea2--- /dev/null+++ b/.github/ISSUE_TEMPLATE/format_request.yml@@ -0,0 +1,49 @@+name: Format request+description: A file type Filee can't open yet+title: "Format request: "+labels: ["enhancement"]+body:+ - type: markdown+ attributes:+ value: |+ > [!IMPORTANT]+ > **Filee can't convert files that are encrypted or copy-protected (DRM), whatever their format.** Converting them means breaking that protection, so these requests are closed.+ >+ > Some examples, not a complete list:+ > - music downloaded in a streaming app (NetEase Cloud Music `.ncm`, QQ Music `.qmc` / `.mflac` / `.mgg`, Kugou `.kgm`, Apple Music, Spotify)+ > - e-books bought with DRM (Kindle `.azw` / `.kfx`, Adobe DRM EPUB or PDF)+ > - videos saved by streaming apps or sites that don't allow downloading+ > - files locked with a password you don't have+ >+ > If the app that made the file can export or save it in a common format, that is the way to go.+ - type: input+ id: extension+ attributes:+ label: File extension+ placeholder: ".xyz"+ validations:+ required: true+ - type: input+ id: source+ attributes:+ label: What makes these files?+ description: The program, device or website.+ validations:+ required: true+ - type: input+ id: target+ attributes:+ label: What should Filee convert them to?+ placeholder: "PDF, MP3, PNG…"+ - type: textarea+ id: details+ attributes:+ label: Anything else?+ description: A sample file if you can share one, a link to the format's documentation, or an open-source tool that reads it.+ - type: checkboxes+ id: not-protected+ attributes:+ label: Protection+ options:+ - label: These files aren't encrypted or copy-protected (DRM), and I can open them without a password.+ required: truediff --git a/src/Filee.App/Assets/i18n/en.json b/src/Filee.App/Assets/i18n/en.jsonindex df514816..ccc172b1 100644--- a/src/Filee.App/Assets/i18n/en.json+++ b/src/Filee.App/Assets/i18n/en.json@@ -56,6 +56,9 @@"toast.cancel": "Cancel","error.unsupported_source": "This file type isn't supported",+ "format_request.request": "Request this format",+ "format_request.notice_title": "Filee can't convert {0} files yet",+ "format_request.notice_text": "Tell us which format you need.\nRequests decide what Filee supports next.\nEncrypted or copy-protected (DRM) files can't be converted, whatever the format.","error.no_route": "No engine can do this conversion","error.cannot_turn": "Rotate and flip work on images only","error.conversion_failed": "The engine reported an error",diff --git a/src/Filee.App/Assets/i18n/ko.json b/src/Filee.App/Assets/i18n/ko.jsonindex 911d0f3b..7a8895b4 100644--- a/src/Filee.App/Assets/i18n/ko.json+++ b/src/Filee.App/Assets/i18n/ko.json@@ -56,6 +56,9 @@"toast.cancel": "취소","error.unsupported_source": "지원하지 않는 파일 형식이에요",+ "format_request.request": "이 형식 요청하기",+ "format_request.notice_title": "아직 {0} 파일은 변환할 수 없어요",+ "format_request.notice_text": "필요한 형식을 알려주세요.\n요청을 보고 다음에 지원할 형식을 정해요.\n암호화되거나 DRM이 걸린 파일은 변환할 수 없어요.","error.no_route": "이 변환을 할 수 있는 엔진이 없어요","error.cannot_turn": "회전·반전은 이미지에만 할 수 있어요","error.conversion_failed": "엔진에서 오류가 발생했어요",diff --git a/src/Filee.App/Assets/i18n/zh-CN.json b/src/Filee.App/Assets/i18n/zh-CN.jsonindex d6f4f5b8..b2b065ce 100644--- a/src/Filee.App/Assets/i18n/zh-CN.json+++ b/src/Filee.App/Assets/i18n/zh-CN.json@@ -56,6 +56,9 @@"toast.cancel": "取消","error.unsupported_source": "不支持此文件类型",+ "format_request.request": "请求支持此格式",+ "format_request.notice_title": "Filee 暂时无法转换 {0} 文件",+ "format_request.notice_text": "告诉我们你需要的格式。\n我们会根据请求决定接下来支持哪些格式。\n加密或有复制保护 (DRM) 的文件,无论什么格式都无法转换。","error.no_route": "没有引擎可以完成此转换","error.cannot_turn": "只能旋转和翻转图片","error.conversion_failed": "转换引擎出错",diff --git a/src/Filee.App/Services/FormatRequest.cs b/src/Filee.App/Services/FormatRequest.csnew file mode 100644index 00000000..17a8b0c8--- /dev/null+++ b/src/Filee.App/Services/FormatRequest.cs@@ -0,0 +1,37 @@+// "Request this format": a file type Filee can't read becomes a GitHub issue (the "Format request" form) with its+// extension filled in. Only the extension goes in the link, never a file name; the user reads it and submits it.++using Filee.Core.Formats;++namespace Filee.App.Services;++public static class FormatRequest+{+ /// <summary>Extensions shown in one request at most; the rest of a big mixed drop is left out.</summary>+ private const int MaxExtensions = 3;++ /// <summary>+ /// The extensions (".ncm") of <paramref name="paths"/> that Filee doesn't know, lower-case and each once. Folders+ /// and files without an extension have nothing to request.+ /// </summary>+ public static IReadOnlyList<string> UnknownExtensions(IEnumerable<string> paths) =>+ paths.Where(p => FormatRegistry.Detect(p) is null && !Directory.Exists(p))+ .Select(p => FormatRegistry.ExtensionOf(p).ToLowerInvariant())+ .Where(e => e.Length > 0)+ .Distinct()+ .Take(MaxExtensions)+ .Select(e => "." + e)+ .ToList();++ /// <summary>".ncm" or ".ncm, .qmc".</summary>+ public static string Label(IReadOnlyList<string> extensions) => string.Join(", ", extensions);++ /// <summary>The new-issue page of the "Format request" form, its title and extension field filled in.</summary>+ public static Uri Url(IReadOnlyList<string> extensions)+ {+ var label = Label(extensions);+ return new Uri(UpdateService.RepositoryUrl.TrimEnd('/') + "/issues/new?template=format_request.yml" ++ "&title=" + Uri.EscapeDataString("Format request: " + label) ++ "&extension=" + Uri.EscapeDataString(label));+ }+}diff --git a/src/Filee.App/Services/RadialController.cs b/src/Filee.App/Services/RadialController.csindex 202d9bc4..3212a406 100644--- a/src/Filee.App/Services/RadialController.cs+++ b/src/Filee.App/Services/RadialController.cs@@ -19,6 +19,7 @@ using Filee.App.ViewModels;using Filee.App.Views;using Filee.Core.Conversion;using Filee.Core.Platform;+using Filee.Core.Profiles;using Filee.Core.Settings;using Microsoft.Extensions.Logging;@@ -46,6 +47,8 @@ public sealed class RadialController(private JobViewModel? _lastRingJob; // for "click the ✓ to open the folder"private IDisposable? _handOffTimer;private int _dragGeneration;+ private bool _converted; // a conversion started from the files on the donut now+ private readonly HashSet<string> _formatRequestsOffered = new(StringComparer.OrdinalIgnoreCase);/// <summary>/// How long a drag that never brought files may keep the invisible window up, in case the button release is@@ -69,6 +72,7 @@ public sealed class RadialController(// A ring from an earlier conversion (finished or handed to the toast) must not keep this gesture's window up.window.DonutControl.LeaveProgressMode();_dropped = false;+ _converted = false;viewModel.ResetForDrag();window.DonutControl.AllowContextEdit = false;PlaceAndShow(window, x, y, activate: false);@@ -89,6 +93,7 @@ public sealed class RadialController(ReleaseProgressToToast();var window = EnsureWindow();_dropped = false;+ _converted = false;viewModel.Load(files, clickMode: true);viewModel.FitToThisDonut();window.DonutControl.AllowContextEdit = true;@@ -144,6 +149,22 @@ public sealed class RadialController(});elsewindow.Hide();+ OfferFormatRequest();+ }++ /// <summary>+ /// The donut closed on files Filee can't read at all (".ncm"): offer to request the format, once per extension+ /// while Filee runs. Files it reads, even mixed with unknown ones, get a conversion and the toast instead.+ /// </summary>+ private void OfferFormatRequest()+ {+ if (_converted || viewModel.Files.Count == 0 || ProfileSelector.DetectFormats(viewModel.Files).Count > 0)+ return;+ var extensions = FormatRequest.UnknownExtensions(viewModel.Files).Where(_formatRequestsOffered.Add).ToList();+ if (extensions.Count == 0)+ return;+ log.LogInformation("Donut closed on files Filee can't read: {Extensions}", FormatRequest.Label(extensions));+ windows.ShowFormatRequestNotice(extensions);}private RadialWindow EnsureWindow()@@ -214,6 +235,7 @@ public sealed class RadialController(Close();return;}+ _converted = true;ShowProgress(job);}diff --git a/src/Filee.App/Services/WindowService.cs b/src/Filee.App/Services/WindowService.csindex 1c23eec7..6044a3b9 100644--- a/src/Filee.App/Services/WindowService.cs+++ b/src/Filee.App/Services/WindowService.cs@@ -22,6 +22,9 @@ public sealed class WindowService(ILocalizer loc, IServiceProvider services)private UpdateNoticeWindow? _updateNotice;private EngineUpdateNoticeWindow? _engineNotice;private FeedbackNoticeWindow? _feedbackNotice;+ private FormatRequestNoticeWindow? _formatRequestNotice;++ internal FormatRequestNoticeWindow? FormatRequestNotice => _formatRequestNotice;public MainWindow? Main => _main;@@ -130,6 +133,22 @@ public sealed class WindowService(ILocalizer loc, IServiceProvider services)_feedbackNotice.Show();}+ /// <summary>+ /// Shows the "Filee can't convert .ncm files yet" card with "Request this format", replacing an earlier one.+ /// </summary>+ public void ShowFormatRequestNotice(IReadOnlyList<string> extensions)+ {+ _formatRequestNotice?.Close();+ var notice = new FormatRequestNoticeWindow(extensions, loc.Format("format_request.notice_title", FormatRequest.Label(extensions)));+ notice.Closed += (_, _) =>+ {+ if (_formatRequestNotice == notice)+ _formatRequestNotice = null;+ };+ _formatRequestNotice = notice;+ notice.Show();+ }+/// <summary>Opens the preset popup. Returns true when the user saved (the preset object was updated).</summary>public async Task<bool> EditPresetAsync(Preset preset, Window? owner){diff --git a/src/Filee.App/ViewModels/JobViewModel.cs b/src/Filee.App/ViewModels/JobViewModel.csindex 3044df29..b0000016 100644--- a/src/Filee.App/ViewModels/JobViewModel.cs+++ b/src/Filee.App/ViewModels/JobViewModel.cs@@ -2,6 +2,7 @@using CommunityToolkit.Mvvm.ComponentModel;using CommunityToolkit.Mvvm.Input;+using Filee.App.Services;using Filee.Core.Conversion;using Filee.Core.Localization;using Filee.Core.Platform;@@ -41,6 +42,13 @@ public sealed partial class JobViewModel : ObservableObject[ObservableProperty] private string? _errorDetails;[ObservableProperty] private bool _canRetry;+ /// <summary>Extensions of failed files Filee can't read (".ncm"), for "Request this format".</summary>+ [ObservableProperty]+ [NotifyPropertyChangedFor(nameof(CanRequestFormat))]+ private IReadOnlyList<string> _unknownExtensions = [];++ public bool CanRequestFormat => UnknownExtensions.Count > 0;+/// <summary>Source files that failed.</summary>public IEnumerable<string> FailedSources => Job.Files.Where(f => f.State == FileState.Failed).Select(f => f.SourcePath);@@ -60,6 +68,10 @@ public sealed partial class JobViewModel : ObservableObjectErrorDetails = failed.Count == 0 ? null : string.Join(Environment.NewLine,failed.Select(f => $"{Path.GetFileName(f.SourcePath)} — {FailureText.Reason(_loc, f.ErrorKey, f.ErrorDetail)}"));CanRetry = _retry is not null && !IsRunning && failed.Count > 0;+ IReadOnlyList<string> unknown = IsRunning ? [] : FormatRequest.UnknownExtensions(+ failed.Where(f => f.ErrorKey == "error.unsupported_source").Select(f => f.SourcePath));+ if (!unknown.SequenceEqual(UnknownExtensions))+ UnknownExtensions = unknown;Status = Job.State switch{diff --git a/src/Filee.App/Views/FormatRequestNoticeWindow.axaml b/src/Filee.App/Views/FormatRequestNoticeWindow.axamlnew file mode 100644index 00000000..1c563bdf--- /dev/null+++ b/src/Filee.App/Views/FormatRequestNoticeWindow.axaml@@ -0,0 +1,35 @@+<!-- "Filee can't convert .ncm files yet" card in the bottom-right corner, shown when the donut closes on files of a type+ Filee doesn't know (RadialController): "Request this format" opens the GitHub form with the extension filled in. -->+<Window xmlns="https://github.com/avaloniaui"+ xmlns:x="http://schemas.microsoft.com/winfx/2006/xaml"+ x:Class="Filee.App.Views.FormatRequestNoticeWindow"+ Title="Filee"+ Width="440"+ SizeToContent="Height"+ WindowDecorations="None"+ Background="Transparent"+ TransparencyLevelHint="Transparent"+ Topmost="True"+ ShowInTaskbar="False"+ ShowActivated="False"+ CanResize="False">+ <Border Classes="card" Margin="12" Padding="16,14">+ <DockPanel>+ <Image DockPanel.Dock="Left" Source="avares://Filee/Assets/Icons/filee.png" Width="36" Height="36"+ VerticalAlignment="Top" Margin="0,2,12,0" />+ <StackPanel Spacing="8">+ <DockPanel>+ <Button DockPanel.Dock="Right" Classes="icon" Padding="4" VerticalAlignment="Top" Click="OnClose">+ <PathIcon Width="12" Height="12" Data="{StaticResource Icon.Close}" />+ </Button>+ <TextBlock x:Name="TitleText" FontWeight="SemiBold" TextWrapping="Wrap" VerticalAlignment="Center" />+ </DockPanel>+ <TextBlock Classes="caption" Text="{DynamicResource format_request.notice_text}" TextWrapping="Wrap" />+ <StackPanel Orientation="Horizontal" Spacing="8" Margin="0,2,0,0">+ <Button Classes="accent" Click="OnRequest" Padding="12,5" Content="{DynamicResource format_request.request}" />+ <Button Content="{DynamicResource common.close}" Click="OnClose" Padding="12,5" />+ </StackPanel>+ </StackPanel>+ </DockPanel>+ </Border>+</Window>diff --git a/src/Filee.App/Views/FormatRequestNoticeWindow.axaml.cs b/src/Filee.App/Views/FormatRequestNoticeWindow.axaml.csnew file mode 100644index 00000000..8317bfc0--- /dev/null+++ b/src/Filee.App/Views/FormatRequestNoticeWindow.axaml.cs@@ -0,0 +1,44 @@+using Avalonia;+using Avalonia.Controls;+using Avalonia.Interactivity;+using Filee.App.Services;++namespace Filee.App.Views;++/// <summary>Bottom-right card for files of a type Filee doesn't know: "Request this format" opens the GitHub form.</summary>+public partial class FormatRequestNoticeWindow : Window+{+ private const int ScreenMargin = 12;++ public FormatRequestNoticeWindow() => InitializeComponent();++ /// <param name="extensions">The unknown extensions, e.g. ".ncm" (see <see cref="FormatRequest.UnknownExtensions"/>).</param>+ public FormatRequestNoticeWindow(IReadOnlyList<string> extensions, string title) : this()+ {+ Extensions = extensions;+ TitleText.Text = title;+ Motion.Track(this);+ SizeChanged += (_, _) => PlaceBottomRight();+ }++ public IReadOnlyList<string> Extensions { get; } = [];++ private async void OnRequest(object? sender, RoutedEventArgs e)+ {+ await Launcher.LaunchUriAsync(FormatRequest.Url(Extensions));+ Close();+ }++ private void OnClose(object? sender, RoutedEventArgs e) => Close();++ private void PlaceBottomRight()+ {+ var screen = Screens.Primary;+ if (screen is null)+ return;+ var area = screen.WorkingArea;+ var width = (int)Math.Ceiling(Bounds.Width * screen.Scaling);+ var height = (int)Math.Ceiling(Bounds.Height * screen.Scaling);+ Position = new PixelPoint(area.Right - width - ScreenMargin, area.Bottom - height - ScreenMargin);+ }+}diff --git a/src/Filee.App/Views/ToastWindow.axaml b/src/Filee.App/Views/ToastWindow.axamlindex 390c9f91..7562790d 100644--- a/src/Filee.App/Views/ToastWindow.axaml+++ b/src/Filee.App/Views/ToastWindow.axaml@@ -83,6 +83,9 @@</DockPanel><TextBlock Classes="caption danger" Text="{Binding ErrorDetails}" TextWrapping="Wrap" MaxLines="4"IsVisible="{Binding HasErrors}" />+ <!-- Files of a type Filee doesn't know: open the GitHub "Format request" form (FormatRequest). -->+ <Button HorizontalAlignment="Left" Padding="10,4" Click="OnRequestFormat"+ IsVisible="{Binding CanRequestFormat}" Content="{DynamicResource format_request.request}" /></StackPanel></Border></DataTemplate>diff --git a/src/Filee.App/Views/ToastWindow.axaml.cs b/src/Filee.App/Views/ToastWindow.axaml.csindex b4f911e6..26fc9a80 100644--- a/src/Filee.App/Views/ToastWindow.axaml.cs+++ b/src/Filee.App/Views/ToastWindow.axaml.cs@@ -1,8 +1,10 @@using System.Collections.Specialized;using Avalonia;using Avalonia.Controls;+using Avalonia.Interactivity;using Avalonia.Threading;using Filee.App.Services;+using Filee.App.ViewModels;namespace Filee.App.Views;@@ -19,6 +21,12 @@ public partial class ToastWindow : Window}private ConversionService? _service;++ private async void OnRequestFormat(object? sender, RoutedEventArgs e)+ {+ if ((sender as Control)?.DataContext is JobViewModel { CanRequestFormat: true } job)+ await Launcher.LaunchUriAsync(FormatRequest.Url(job.UnknownExtensions));+ }private bool _closed;protected override void OnDataContextChanged(EventArgs e)diff --git a/tests/Filee.App.Tests/FormatRequestTests.cs b/tests/Filee.App.Tests/FormatRequestTests.csnew file mode 100644index 00000000..059bd26b--- /dev/null+++ b/tests/Filee.App.Tests/FormatRequestTests.cs@@ -0,0 +1,131 @@+// "Request this format" (issue #117): files of a type Filee can't read lead to the GitHub "Format request" form with+// the extension filled in, from the toast of a failed conversion and when the donut closes on such files.++using Avalonia.Headless;+using Avalonia.Headless.XUnit;+using Avalonia.Threading;+using Filee.App.Services;+using Filee.Core.Settings;++namespace Filee.App.Tests;++public sealed class FormatRequestTests : IDisposable+{+ private readonly string _folder = Path.Combine(Path.GetTempPath(), "filee-format-request-" + Guid.NewGuid().ToString("N"));++ public FormatRequestTests() => Directory.CreateDirectory(_folder);++ public void Dispose()+ {+ try { Directory.Delete(_folder, true); } catch (IOException) { }+ }++ /// <summary>An extension no test has offered yet: the donut offers each one once while Filee runs.</summary>+ private static string NewExtension() => "q" + Guid.NewGuid().ToString("N")[..6];++ private string File(string name)+ {+ var path = Path.Combine(_folder, name);+ System.IO.File.WriteAllText(path, "data");+ return path;+ }++ private static void Pump()+ {+ for (var i = 0; i < 10; i++)+ {+ Dispatcher.UIThread.RunJobs();+ AvaloniaHeadlessPlatform.ForceRenderTimerTick();+ }+ }++ [Fact]+ public void Only_unknown_extensions_are_requested_once_each_in_lower_case()+ {+ var folder = Path.Combine(_folder, "album.ncm");+ Directory.CreateDirectory(folder);+ var paths = new[]+ {+ File("song.NCM"), File("other.ncm"), File("photo.jpg"), File("README"), File("track.kgm"), folder,+ File("a.qmc0"), File("b.mflac"),+ };++ // Known types, a folder and a file without an extension have nothing to request; at most three per request.+ Assert.Equal([".ncm", ".kgm", ".qmc0"], FormatRequest.UnknownExtensions(paths));+ }++ [Fact]+ public void The_link_opens_the_format_request_form_with_only_the_extension()+ {+ var url = FormatRequest.Url([".ncm", ".kgm"]).AbsoluteUri;++ Assert.StartsWith(UpdateService.RepositoryUrl.TrimEnd('/') + "/issues/new?template=format_request.yml&", url);+ Assert.Contains("&title=Format%20request%3A%20.ncm%2C%20.kgm", url);+ Assert.Contains("&extension=.ncm%2C%20.kgm", url);+ }++ [AvaloniaFact]+ public async Task A_conversion_that_fails_on_an_unknown_type_offers_the_request_in_the_toast()+ {+ TestServices.EnsureInitialized("en");+ var store = AppHost.Get<UserDataStore>();+ var extension = NewExtension();+ var job = AppHost.Get<ConversionService>().Start([File("song." + extension)], store.FindPreset("to-pdf")!, showInToast: false)!;+ try+ {+ var deadline = DateTime.UtcNow.AddSeconds(30);+ while (job.IsRunning && DateTime.UtcNow < deadline)+ {+ await Task.Delay(20);+ Pump();+ }++ Assert.False(job.IsRunning);+ Assert.True(job.CanRequestFormat);+ Assert.Equal(["." + extension], job.UnknownExtensions);+ }+ finally+ {+ job.DismissCommand.Execute(null);+ }+ }++ [AvaloniaFact]+ public void The_donut_closing_on_unknown_files_offers_the_request_once()+ {+ TestServices.EnsureInitialized("en");+ var radial = AppHost.Get<RadialController>();+ var windows = AppHost.Get<WindowService>();+ var extension = NewExtension();+ var song = File("song." + extension);+ try+ {+ radial.ShowForFiles(400, 400, [song]);+ radial.Close(animate: false);+ Pump();++ var notice = windows.FormatRequestNotice;+ Assert.NotNull(notice);+ Assert.True(notice.IsVisible);+ Assert.Equal(["." + extension], notice.Extensions);+ notice.Close();+ Pump();++ // Once per extension while Filee runs.+ radial.ShowForFiles(400, 400, [song]);+ radial.Close(animate: false);+ Pump();+ Assert.Null(windows.FormatRequestNotice);++ // Files Filee reads: nothing to request, even mixed with an unknown type (the toast covers that one).+ radial.ShowForFiles(400, 400, [File("notes.txt"), File("song." + NewExtension())]);+ radial.Close(animate: false);+ Pump();+ Assert.Null(windows.FormatRequestNotice);+ }+ finally+ {+ windows.FormatRequestNotice?.Close();+ }+ }+}diff --git a/tests/Filee.App.Tests/RenderTests.cs b/tests/Filee.App.Tests/RenderTests.csindex aabfe58b..36b71464 100644--- a/tests/Filee.App.Tests/RenderTests.cs+++ b/tests/Filee.App.Tests/RenderTests.cs@@ -1109,6 +1109,21 @@ public class RenderTests}}+ [AvaloniaTheory]+ [InlineData("en")]+ [InlineData("ko")]+ [InlineData("zh-CN")]+ public void Format_request_notice_renders(string language)+ {+ TestServices.EnsureInitialized(language);+ var loc = AppHost.Get<ILocalizer>();+ var notice = new FormatRequestNoticeWindow([".ncm"], loc.Format("format_request.notice_title", ".ncm"));+ notice.Show();+ Pump();+ Save(notice, $"window-format-request-{language}.png");+ notice.Close();+ }+private static void Pump(){// Let layout, bindings and a few animation frames run.