From a152dab81f647853aa8f2ceab692b0960e02471e Mon Sep 17 00:00:00 2001 From: yusufmntm Date: Mon, 30 Nov 2026 22:43:07 +0300 Subject: [PATCH] feat(documents): open Word backup copies (.wbk) A .wbk holds either a DOCX (ZIP with word/document.xml) or, when the original was a .doc, a Word 97-2003 OLE file. The built-in word-backup engine is an IEnvelopeOpener: it reads the first bytes, passes the unchanged copy on as docx or doc, and the planner continues along the usual routes. Anything else is refused with error.wbk_not_word. Preset availability looks through such an opener's inner formats, so 4-step and direct-only DOCX presets stay usable; .p7m is left as it was. Schema v107 teaches existing libraries .wbk. Fixes #1840 Co-Authored-By: Claude Opus 5.5 --- CHANGELOG.md | 8 + README.md | 2 +- docs/ENGINES.md | 17 ++ src/Filee.App/Assets/i18n/ar.json | 3 + src/Filee.App/Assets/i18n/bn-BD.json | 3 + src/Filee.App/Assets/i18n/de.json | 3 + src/Filee.App/Assets/i18n/en.json | 3 + src/Filee.App/Assets/i18n/es.json | 3 + src/Filee.App/Assets/i18n/fa.json | 3 + src/Filee.App/Assets/i18n/fr.json | 3 + src/Filee.App/Assets/i18n/hi.json | 3 + src/Filee.App/Assets/i18n/id.json | 3 + src/Filee.App/Assets/i18n/it.json | 3 + src/Filee.App/Assets/i18n/ja.json | 3 + src/Filee.App/Assets/i18n/ko.json | 3 + src/Filee.App/Assets/i18n/mn.json | 3 + src/Filee.App/Assets/i18n/ne.json | 3 + src/Filee.App/Assets/i18n/pl.json | 3 + src/Filee.App/Assets/i18n/pt-BR.json | 3 + src/Filee.App/Assets/i18n/pt-PT.json | 3 + src/Filee.App/Assets/i18n/ru.json | 3 + src/Filee.App/Assets/i18n/th.json | 3 + src/Filee.App/Assets/i18n/tr.json | 3 + src/Filee.App/Assets/i18n/vi.json | 3 + src/Filee.App/Assets/i18n/zh-CN.json | 3 + src/Filee.App/Assets/i18n/zh-TW.json | 3 + src/Filee.App/Services/PresetAvailability.cs | 49 ++++-- src/Filee.Core/Formats/FormatFields.cs | 2 +- src/Filee.Core/Formats/FormatRegistry.cs | 9 + src/Filee.Core/Settings/AppSettings.cs | 2 +- src/Filee.Core/Settings/UserDataStore.cs | 3 + src/Filee.Engines/EngineRegistry.cs | 1 + .../Office/WordBackupConverter.cs | 92 ++++++++++ tests/Filee.App.Tests/ToolbarEditorTests.cs | 38 +++++ tests/Filee.Core.Tests/FormatFieldsTests.cs | 2 +- tests/Filee.Core.Tests/WbkFormatTests.cs | 53 ++++++ tests/Filee.Engines.Tests/WordBackupTests.cs | 161 ++++++++++++++++++ 37 files changed, 488 insertions(+), 20 deletions(-) create mode 100644 src/Filee.Engines/Office/WordBackupConverter.cs create mode 100644 tests/Filee.Core.Tests/WbkFormatTests.cs create mode 100644 tests/Filee.Engines.Tests/WordBackupTests.cs diff --git a/CHANGELOG.md b/CHANGELOG.md index e0932320c..12c8ced9b 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -86,6 +86,8 @@ ko: 전체 화면 게임이나 동영상, 프레젠테이션 중에는 업데이 en: The update notice doesn't appear over full-screen games, videos or presentations: it waits until you next use Filee ko: 업데이트 알림에 '나중에'(3일 뒤 다시 알림)와 '이 버전 건너뛰기'가 생겼고, 처음 실행할 때 알림을 끄는 방법도 알려 줘요 en: The update notice has Later (reminds you in 3 days) and Skip this version, and first run says how to turn it off +ko: Word 백업 파일(.wbk)을 문서 도넛에서 열어 DOCX나 DOC로 인식하고 변환할 수 있어요 +en: Word backup copies (.wbk) open on the documents donut and convert as the DOCX or DOC inside --> - **No update notice over full-screen games** (#1897). The "new version" card in the bottom-right corner could appear @@ -380,6 +382,12 @@ en: The update notice has Later (reminds you in 3 days) and Skip this version, a named `--json`. Everything after `--` is a file to convert, even if it starts with `-`. The examples in `filee help` use Windows paths on Windows and `~/` paths on macOS and Linux. +- **Read Word backup copies (.wbk)** (#1840). Word backup files (`.wbk`, written when "Always create backup copy" is + on) now open on the documents donut. Filee checks the first bytes to tell a DOCX backup (ZIP containing + `word/document.xml`) from a Word 97–2003 DOC backup (OLE) and passes the unchanged copy on under that format, so + DOCX backups convert out of the box and DOC backups convert through LibreOffice. Files that don't hold a Word + document are refused with a clear reason. + ## 2.5.0