MTGProxyPrinter

Timeline
Login

Timeline

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

2115 check-ins using file LICENSE.md version 67eabf4952

2024-10-28
14:05
Tests: Set a default timeout of 10s per test. Bump required pytest version to 6.0, which is the first version allowing configuration via pyproject.toml. Leaf check-in: 5a030918a1 user: thomas tags: trunk
13:57
Refactor test_page_config_widget.py: Use a pytest fixture to create PageLayoutSettings instances containing the default settings. check-in: 9abf9cb4e7 user: thomas tags: trunk
12:32
Fix resource warning at application start. Explicitly keep a reference to the open crash log file. check-in: b61b175b8b user: thomas tags: trunk
2024-10-26
11:17
Fix application settings migration code. Add unit tests for all settings file versions verifying that the migration code does not crash. check-in: e75d027f1f user: thomas tags: trunk
11:04
Fix settings migrations from really old versions. Closed-Leaf check-in: 18d5d2f33d user: thomas tags: fix_settings_migration
2024-10-19
09:00
Add changelog entry. check-in: f443f6bce3 user: thomas tags: fix_settings_migration
08:56
Fix crash in settings migration code when upgrading from 0.26.1 or older. check-in: 04001301b0 user: thomas tags: fix_settings_migration
08:46
Add test cases for the settings migration code, verifying that the code does not crash check-in: 75957cb012 user: thomas tags: fix_settings_migration
2024-10-18
15:54
Tests: Simplified asserts in test_document.py check-in: c9928b0eb7 user: thomas tags: trunk
2024-10-16
11:48
Merge with trunk Leaf check-in: 8b1031c310 user: thomas tags: port_pyside6
2024-10-09
13:08
Clarify the scope of the default card language option in the settings. Add a note about card language of imported deck lists. check-in: cf0e6f4403 user: thomas tags: trunk
2024-10-03
14:45
Implement asynchronous card database migrations with progress reporting. Implements [f460c3e0caf7b1dd] check-in: 40729f514a user: thomas tags: trunk
14:39
Add changelog entry Closed-Leaf check-in: cd08a846d6 user: thomas tags: async_migrations
14:30
Fix remaining database migration tests check-in: a5bf722e78 user: thomas tags: async_migrations
14:24
Code cleanup and more logging in the database migration code. check-in: a5de4eb6ee user: thomas tags: async_migrations
14:10
DatabaseMigrationRunner: Remove the database dumping code in run(), which was present to debug disappearing data during migrations. check-in: 1ac37e8ac9 user: thomas tags: async_migrations
14:08
Further improved @with_database_write_lock() by no longer assigning the application to a variable, which avoids a type hinting warning. check-in: 01e75d1d25 user: thomas tags: async_migrations
14:05
Improve the should_run attribute detection and logging output in the @with_database_write_lock decorator. check-in: 6317d7efd2 user: thomas tags: async_migrations
13:58
Application: Re-introduce the removed should_run attribute, which is used by the @with_database_write_lock decorator. The attribute is read before starting a task that was unblocked waiting on the database, and prevents starting long-running tasks during the application exit sequence. check-in: 12793dc4c7 user: thomas tags: async_migrations
13:47
Partial fix for the database migration tests. check-in: dcb11ec4b7 user: thomas tags: async_migrations
13:47
MigrationScriptRunner: Move the migration script parameter from run() to __init__(). The first is incompatible with pytest, which wraps QRunnable.run(), making it impossible to pass the parameter in test code. check-in: 8d98eb776c user: thomas tags: async_migrations
2024-10-01
15:54
Deck list downloaders for CubeCobra and Manabox.app now accepts the "http://www." prefix. check-in: e6312ee8a9 user: thomas tags: trunk
2024-09-26
08:16
Fix migration scripts running PRAGMA statements. Some scripts require turning off foreign key constraints, and that cannot happen within a transaction. The migration script runner now commits any transaction before running a PRAGMA statement, and starts a new transaction afterwards. check-in: da3236dd3f user: thomas tags: async_migrations
2024-09-25
08:04
DatabaseMigrationRunner: Release the runner instance when leaving run() check-in: 149fc9c088 user: thomas tags: async_migrations
2024-09-22
18:07
The Archidekt deck list downloader now accepts URLs starting with "https://www." check-in: 9deba291b1 user: thomas tags: trunk
16:42
Moved carddb_migrations.py out of the model package into the main package. check-in: 3a37939ad5 user: thomas tags: async_migrations
16:16
Implement asynchronous database migrations with progress reporting. Refactor handling of asynchronous application startup tasks. Run these sequentially by chaining them via the task end signal as a trigger to run the next. Run the three database-hitting tasks by first running the version migration, then the settings synchronisation, then the CLI argument handling. check-in: d27e4c90d2 user: thomas tags: async_migrations
2024-09-19
08:25
Extract the inner signal container class from the PrintingFilterUpdater class, and move it to runner.py check-in: 4733b68ea4 user: thomas tags: async_migrations
2024-09-18
08:02
Written class DatabaseMigrationRunner, derived from Runnable check-in: 8c70f69beb user: thomas tags: async_migrations
2024-09-17
10:29
Introduce dataclass container holding migration scripts. This simplifies the API a lot. Finish migrating the remaining migration scripts to the new data container. check-in: d1a7b7ee37 user: thomas tags: async_migrations
08:32
WIP: Started to transform the card database migration scripts into a declarative format, that can be loaded and processed by a to-be-written database migration worker. check-in: 1a52aa9938 user: thomas tags: async_migrations
2024-09-16
09:07
MainWindow: Fix a broken call to tr(), which was still using an f-string and wasn't picked up by lupdate. check-in: cd7aee3234 user: thomas tags: trunk
08:51
Packaging: Remove the MTGProxyPrinter.egg-info directory that is automatically generated during Python wheel file generation. check-in: 5f6cffb549 user: thomas tags: trunk
07:54
Merge fork Leaf check-in: bdcc28c7df user: thomas tags: duplex_printing
2024-09-15
18:34
Merge fork. check-in: af2df11c92 user: thomas tags: trunk
2024-09-14
12:57
Release v0.29.1 check-in: 45b2a6f419 user: thomas tags: port_pyside6
12:50
Release v0.29.1 check-in: 3ab2cec226 user: thomas tags: trunk, release, v0.29.1
12:47
Fix broken PDF export option check-in: d750582d74 user: thomas tags: trunk
2024-09-13
12:32
Release v0.29.0 check-in: 9f9cd9a1ab user: thomas tags: port_pyside6
12:29
Release v0.29.0 check-in: abdc6017f0 user: thomas tags: trunk, release, v0.29.0
12:19
tests/ui/test_page_config_container.py: Fixed bad import check-in: 0f75057af0 user: thomas tags: trunk
12:05
Fix missing signal emit code in PageConfigWidget. UI updates are now properly propagating to the PageConfigPreviewArea. check-in: 87fd3baee9 user: thomas tags: port_pyside6
12:01
PageConfigWidget: Use partial() instead of lambdas to emit the page_layout_changed signal check-in: f5c1d9ddb9 user: thomas tags: trunk
11:56
Tests: Verify PageConfigWidget does emit the page_layout_changed signal when widget values are changed. Add a test timeout of 100ms for each test check-in: 7b64dd2c97 user: thomas tags: trunk
11:21
Tests: Add unit tests for PageConfigContainer, verifying that the page layout signal connection to the preview area works as intended. check-in: 4ce68c77ad user: thomas tags: trunk
09:57
Tests: Fix changelog-reading tests running on non-UTF-8 systems by specifying the file encoding. check-in: 6575ec1870 user: thomas tags: trunk
09:20
Packaging: Remove the work-around for cx_Freeze 7.2. PySide6 is not affected by the resource loading issue, so no need to restrict the use to older cx_Freeze versions. check-in: 3cd6962482 user: thomas tags: port_pyside6
2024-09-11
07:35
PageConfigContainer & PageConfigWidget: Cleaned up code. Introduce some local variables to clean up calls and segment the code for better readability. PageConfigWidget: Use the existing helper methods to get all settings widgets per type, instead of hard-coding that in a second location. check-in: 470afc693c user: thomas tags: trunk
2024-09-10
18:15
Update the clean_windows_build.bat script to optimize the build with newer PySide6 6.7. Builds are down to the previous ~30MiB range check-in: 676c5789bc user: thomas tags: port_pyside6
17:59
Update scripts/update_translations.py for PySide6 check-in: 5a1039a069 user: thomas tags: port_pyside6
17:59
Remove additional dependencies on PySide2 or 6 for lrelease. This branch already depends on PySide6, making these redundant. check-in: 730ba1b61e user: thomas tags: port_pyside6
17:55
Merge with trunk check-in: a31fea0ba9 user: thomas tags: port_pyside6
17:54
Reduce build-time dependency on PySide6 to PySide6_Essentials. The Addons aren't required for the lupdate binary used from the package. check-in: 11de92d6eb user: thomas tags: trunk
16:06
Fix PySide6 package name in the build system requirements. check-in: 652e7c6a1b user: thomas tags: port_pyside6
16:01
Bump PySide6 required version to 6.7. That version flattens the internal structure of the package. check-in: ef1d1187f0 user: thomas tags: port_pyside6
15:26
Merge with trunk. check-in: 0b3f44cdf1 user: thomas tags: port_pyside6
15:07
Fixed rendering of a changelog entry. check-in: 39366e767c user: thomas tags: trunk
15:02
test_tappedout_csv_parser.py: Fixed broken test test_local_header_conforms_to_current_scryfall_return_data(). check-in: 5803f30c7b user: thomas tags: trunk
14:55
AboutDialog.ui: Remove the HTML text of the about text. Update translations from Crowdin. check-in: 51d47a3bad user: thomas tags: trunk
14:50
Update translations from Crowdin check-in: b4d3961960 user: thomas tags: trunk
14:48
Add an application icon, kindly provided by [https://www.reddit.com/user/islanders2013/]. check-in: 78953c0491 user: thomas tags: trunk
14:35
Add a small, "clean" icon version for use with window decorations. Closed-Leaf check-in: 6fff8ebccc user: thomas tags: app_icon
14:12
Set the icon in the cx_Freeze bundle. This causes the icon to show up on the Windows start menu and task bar. check-in: 5fef131b02 user: thomas tags: app_icon
12:30
Merge with trunk check-in: d372cefcda user: thomas tags: app_icon
12:26
Fix issue [723e7ac33028e403]. The deck import wizard now prefers cards to tokens when the name is ambiguous with cards that create token copies of themselves. check-in: 7f0517b848 user: thomas tags: trunk
12:16
Tests: Fix _validate_saved_document_settings() in test_document.py check-in: bd6bb0a239 user: thomas tags: trunk
12:09
Unify multiple definitions of a close_to_() matcher. check-in: 87f2628134 user: thomas tags: trunk
12:01
Tests: Fix test_renderer_zoom_action_triggers_zoom(). check-in: f148d86b59 user: thomas tags: trunk
10:01
Add an application icon contributed by [https://www.reddit.com/user/islanders2013/]. check-in: 56b39ec2e2 user: thomas tags: app_icon
2024-09-09
19:28
PageRenderer: Moved the generation of the keyboard shortcut texts used for the help tooltip into _setup_zoom_action(), which further de-duplicates the code. check-in: 08bdbd7ac3 user: thomas tags: trunk
19:23
PageRenderer: Refactor QAction creation for zoom actions, by encapsulating the logic in a method. Use partial() instead of lambdas. Fixed usage of some Qt enum constants used directly from the Ui element class. Add a missing tr() call for the tooltip displaying the available keyboard shortcuts. check-in: 93efc31fef user: thomas tags: trunk
16:56
test_page_layout_settings.py: Move test data into a parametrized variable, and add a variant testing with the full "millimeter" suffix instead of just "mm". check-in: 2b35da6c81 user: thomas tags: trunk
16:48
Fix broken document saving. check-in: aeaf525f12 user: thomas tags: trunk
16:39
WIP file extension registration for Windows cx_Freeze bundles. Leaf check-in: bc8c838602 user: thomas tags: bundle_improvements
08:30
PrintPreviewDialog: Reset the minimum size in the showEvent() event handler. The delayed reset via timer was unreliable. check-in: a751355872 user: thomas tags: trunk
08:11
Increase the initial size of the print preview dialog, by a request from Reddit. check-in: 317e503711 user: thomas tags: trunk
2024-09-08
21:16
Dependencies: Fixed bug in the development dependencies: Use PySide6 for Python 3.12+, and not PySide2. This brings the development and packaging requirements in line. check-in: 75a51a3a86 user: thomas tags: trunk
21:09
Dependencies: Lower bound for pint is 0.22, due to the use of QuantityT and UnitT. Add a work-around for 0.21, which is required on Python 3.8. check-in: 3ad77b3c3d user: thomas tags: trunk
20:43
Add tests for the version strings in the changelog. One test verifies that the version in the top-most changelog entry matches the one in metadata.py. The other test verifies that the version string in the header matches the HTML name of the section header. check-in: 01e58ba24e user: thomas tags: trunk
20:10
Merge with trunk. check-in: 7bdfc712a8 user: thomas tags: port_pyside6
13:04
Fix a wrong word in a translation. check-in: 1fc16dc218 user: thomas tags: trunk
12:58
Replace HTML in a What's This? help with Markdown, and format it as HTML during runtime. This reduces the word count by 400 and eases the translation work. check-in: 22d21e3f88 user: thomas tags: trunk
12:57
Update translations from Crowdin Closed-Leaf check-in: e4fd4fc2f9 user: thomas tags: markdown_tooltips
12:29
Replace the HTML tooltip in the SelectDeckParserPage with the equivalent Markdown-formatted plaintext. Use a QTextEdit to convert it to HTML for formatting purposes. Also delete a duplicate tooltip. Reduces the word-count determined by Crowdin by ~400 words. This also makes it significantly easier to translate, as the markdown is much more human readable. check-in: 892e31c7d2 user: thomas tags: markdown_tooltips
2024-09-07
18:31
PageConfigWidget: Use functools.partial instead of lambda expressions to emit the page_layout_changed signal. Also rename variables to avoid shadowing names from an outer scope. Leaf check-in: b7fa230546 user: thomas tags: enum_based_paper_size
2024-09-06
23:55
Merge with trunk check-in: aac4f4c172 user: thomas tags: enum_based_paper_size
12:00
Merge with trunk. check-in: d5020ef899 user: thomas tags: port_pyside6
2024-09-05
18:24
Fix a Qt enum misuse. Use QEvent.Type instead of the aliases in the base class. check-in: c5470f2c88 user: thomas tags: trunk
18:06
Add a missing tr() call. check-in: 2750f49593 user: thomas tags: trunk
15:26
Update translations from Crowdin check-in: 2780ad2e7e user: thomas tags: trunk
15:24
PageConfigContainer.ui: Remove window title and geometry information. check-in: 59482a242d user: thomas tags: trunk
15:10
Add a live preview to the page layout settings UI. Implements [69cc651d32bfcd5f]. It re-uses existing components, and shows the preview using black-bordered solid gray placeholder images. check-in: 9af3bac22b user: thomas tags: trunk
15:02
PageConfigPreviewArea: Give the placeholder cards a name, as the card name is logged when changing the card count. This improves readability of the log file. Also log the initial numbers of regular, and oversized cards. Closed-Leaf check-in: ce3a462c21 user: thomas tags: page_layout_preview
15:00
PageConfigWidget: Initialize the internal page layout from the application settings. This avoids a brief period with an invalid page layout. check-in: b4173e21d9 user: thomas tags: page_layout_preview
07:09
PageConfigPreviewArea: Pre-populate the preview pages with half the maximum card count fitting on them. check-in: 2e08fa5a4c user: thomas tags: page_layout_preview
07:06
PageConfigPreviewArea: Set UI layout top, bottom and right margins to zero, so that it aligns with the PageConfigWidget, and is no longer visibly smaller. The containing widget already has those margins. check-in: 3f005625a1 user: thomas tags: page_layout_preview
2024-09-04
16:08
DocumentSettingsDialog: Hide the button to hide/show the preview area. For this dialog, the preview area should always be visible. check-in: 4624d1e4f0 user: thomas tags: page_layout_preview
16:05
Add a button to the PageConfigWidget that hides the preview area. Refactored the size-adaption logic in the settings to work with the page config preview hiding button, as that affects the minimum window width. check-in: 33174faf08 user: thomas tags: page_layout_preview
08:41
Remove the now unused default_document_layout_settings_page.ui UI file. check-in: 20a200f2bc user: thomas tags: page_layout_preview
08:40
Introduce the page layout preview functionality in the application settings window. check-in: 95f017926b user: thomas tags: page_layout_preview
08:38
Fix settings migration to not fail on migrated settings files. check-in: 07eec78c64 user: thomas tags: page_layout_preview
2024-09-02
14:56
PageConfigPreviewArea: Move numerical constants into an enum class. check-in: f6a1df52f5 user: thomas tags: page_layout_preview
2024-09-01
16:37
Implemented drawing preview cards. check-in: cfe07ca676 user: thomas tags: page_layout_preview
14:55
The preview document now has two pages, one for regular, and one for oversized cards. That makes switching between card sizes for preview purposes easier. check-in: 822e20ed96 user: thomas tags: page_layout_preview
2024-08-31
17:00
Fix a typo in a PageConfigPreviewArea Ui variable. Add stub slots for the ui element change signals. check-in: b92a67a30d user: thomas tags: page_layout_preview
16:44
PageConfigPreviewArea: Select "Regular" card size by default. check-in: 6230f874bd user: thomas tags: page_layout_preview
16:42
PageConfigContainer: Connect the page_layout_changed signal with the preview area's on_page_layout_changed slot. check-in: 075ed5377e user: thomas tags: page_layout_preview
16:32
Add changelog entry. check-in: 5d9cbfccdc user: thomas tags: page_layout_preview
16:08
PageConfigWidget: Emit the page_layout_changed signal when loading a layout from settings or from other instances. check-in: a641127881 user: thomas tags: page_layout_preview
16:05
DocumentSettingsDialog: Fixed the installed EventFilter to not crash when hovering over the Restore or Reset button check-in: 1fb8d21998 user: thomas tags: page_layout_preview
16:03
Update the preview area whenever values in the PageLayoutSettings are updated. check-in: 5db86ed654 user: thomas tags: page_layout_preview
16:02
PageConfigWidget: Introduce Qt signal page_layout_changed, which is emitted whenever the interanl PageLayoutSettings instance is altered. check-in: ade0bcb0dd user: thomas tags: page_layout_preview
15:06
Update the DocumentSettingsDialog to show a preview area. The new PageConfigContainer wraps the old PageConfigWidget, and the new PageConfigPreviewArea. It uses a separate Document instance, and the already existing PageRenderer to implement the rendering. check-in: 1afe2e3b71 user: thomas tags: page_layout_preview
09:58
Renamed two settings sections: "images" to "cards", and "application" to "update-checks". The new names better reflect the actual section contents. check-in: 4fdaab1d30 user: thomas tags: trunk
09:38
Merge with trunk. check-in: d57d8142fa user: thomas tags: port_pyside6
09:25
Improve application exit behavior while waiting on a broken network socket. quit() now properly hides the main window, so that the waiting on the socket timeout can occur in the background, without a user-visible, hanging window. check-in: 3b4b6d9088 user: thomas tags: trunk
2024-08-30
15:28
Merge with trunk. check-in: acb8044504 user: thomas tags: enum_based_paper_size
15:27
Completed merge with trunk. Closed-Leaf check-in: 2e9590e93f user: thomas tags: WIP
2024-08-29
18:03
Merged in l10n support. check-in: a780b366ce user: thomas tags: WIP
18:01
Merged up to just before l10n support. check-in: bb19752fd8 user: thomas tags: WIP
17:51
Merge with trunk, Round 1. Merged in decimal document settings support. check-in: 5be445c009 user: thomas tags: WIP
17:11
Adjust tests in test_page_config_widget.py. Also add test cases for previously untested boolean settings. check-in: eec2f2c378 user: thomas tags: enum_based_paper_size
16:56
Adjust test_resources.py::test_all_resource_files_are_listed_in_resources_qrc(). Ignore compiled translation files. check-in: f45acdfa47 user: thomas tags: enum_based_paper_size
16:54
Adjusted tests in test_page_layout_settings.py. check-in: c9464d944c user: thomas tags: enum_based_paper_size
2024-08-28
16:04
DocumentLoader: Ensure that _migrate_paper_size_settings() passes when presented with an empty DocumentSettings table. check-in: 129c5e40bf user: thomas tags: enum_based_paper_size
15:18
Fix broken import caused by PyCharm check-in: 10afc4b917 user: thomas tags: enum_based_paper_size
15:17
DocumentLoader: Actually properly migrate the save file from paper sizes. The migration script parses the paper size in the document, and replaces them with enum values, if it detects a pre-defined paper size. check-in: 4c37e9bb09 user: thomas tags: enum_based_paper_size
12:45
Adjusted test test_valid_page_layout_settings_load_correctly(). Reduced test case count from ~43000 to 328. Instead of building a cross product of each setting, instead set them individually while leaving other settings as defaults. The new approach increases the expressiveness, as the four margin values and three boolean settings are now tested individually. check-in: 9e1a77d140 user: thomas tags: enum_based_paper_size
2024-08-26
20:23
Refactor internals to be fully unit-aware. Lengths in document settings are now unit-aware and carry a length unit as pint Quantities. The PageLayoutSettings, and the configuration file now support setting values with length units. For now, the save file format continues to contain plain floating point numbers. This will be refactored with the next large save-file rewrite. Also, the only allowed length unit is millimeter. Once the save file is unit-aware, additional length units like inches can be allowed and supported via UI. check-in: aad0870a27 user: thomas tags: trunk
17:29
Add test for PageLayoutSettings.to_save_file_data(), validating that all keys are present, and that values only contain acceptable types. Closed-Leaf check-in: 16413f5b7a user: thomas tags: embrace_pint
15:22
PageLayoutSettings: Add helper method converting instances into a format suitable for storage in document save files. check-in: 11c4de2254 user: thomas tags: embrace_pint
15:16
Adjust tests for MainWindow. check-in: 90e225d47a user: thomas tags: embrace_pint
15:11
Adjusted tests for PageLayoutSettings. check-in: edbd2f991b user: thomas tags: embrace_pint
14:58
Adjusted the remaining failing DocumentLoader tests. check-in: 5ff84f024f user: thomas tags: embrace_pint
07:37
PageConfigWidget: Ensure the local PageLayoutSettings and the value spinboxes are in sync when loading from another PageLayoutSettings instance. Also adapt tests for use of pint. check-in: 6da9c35785 user: thomas tags: embrace_pint
2024-08-25
16:38
Adjusted a few PageConfigWidget tests. check-in: 156678c018 user: thomas tags: embrace_pint
15:40
test_page_config_widget.py: Add missing tests for boolean settings check boxes. check-in: 199e3a7061 user: thomas tags: embrace_pint
15:33
Adapt tests in tests/ui/test_page_scene.py check-in: 8ccabe9d49 user: thomas tags: embrace_pint
15:26
Fixed issue in the save file validation: The document settings are updated from the save file. So it can contain pint.Quantity instances for keys not present in the save file. The type checker now allows for Quantity instances to cover these cases. check-in: f707f21f7a user: thomas tags: embrace_pint
15:09
Fix tests in tests/test_document.py. check-in: a28eafa77e user: thomas tags: embrace_pint
14:42
Fixed type errors where Quantity instances were re-written as plain floats or where code did not handle Quantity instances yet. check-in: 1b90bb52aa user: thomas tags: embrace_pint
13:52
Fix errors caused by a seemingly bad merge in [4953098a17f77467]. check-in: 225628075b user: thomas tags: embrace_pint
13:49
More in-depth defense against invalid document dimension settings. Only allow millimeter as length units, and convert values in other length units to millimeter. In the future, further length units like inches can be allowed by simply adding them to the ALLOWED_LENGTH_UNITS set. Non-length units or invalid expressions trigger a default value restoration. check-in: cde6331fae user: thomas tags: embrace_pint
2024-08-23
15:34
Merge with trunk. Also replace all usages of pint.Quantity in type annotations with the pint.facets.plain.registry.QuantityT, which is the abstract type that carries the API. This enhances the type hinter's ability to auto-complete the conversion methods. check-in: 4953098a17 user: thomas tags: embrace_pint
14:58
SettingsWindow: Rename HoverEventFilter to HighlightDifferingSettingsHoverEventFilter. check-in: 011ca71441 user: thomas tags: trunk
10:39
Add missing translation support for the cache cleanup wizard. check-in: c6f3a42038 user: thomas tags: trunk
10:38
Update translations from Crowdin. Closed-Leaf check-in: 02927ba380 user: thomas tags: l10n
2024-08-22
15:03
Reduce diff size with the port_PySide6 branch. Delete duplicates in about_dialog.ui. check-in: 6fb56e6a8b user: thomas tags: trunk
14:49
AboutDialog.ui: Remove an unsupported property, which caused an AttributeError in compiled code run under PySide6. check-in: ee0ff54921 user: thomas tags: port_pyside6
14:31
Minor adjustments for the cache cleanup wizard column widths. Also use enum.auto() for enum constants, and introduce a local variable for a constant that is used multiple times. check-in: 4e5a1c4e5a user: thomas tags: l10n
07:42
Implement localization support for the CacheCleanupWizard. This was somehow forgotten in the previous l10n branch check-in: 3fd282aec6 user: thomas tags: l10n
07:02
Merge with trunk. check-in: b21eed30ec user: thomas tags: port_pyside6
2024-08-21
07:39
Application: Use the QLibraryInfo.LibraryLocation enum proper. check-in: fec8be4b1a user: thomas tags: trunk
07:33
Fix reported style issues check-in: cc66fe5d13 user: thomas tags: trunk
2024-08-19
18:46
Merge with trunk check-in: 2d5ac15bcd user: thomas tags: embrace_pint
17:12
Localization support. Supports formatting strings for plural forms via Qt's translation framework. Includes translations into US English and German. Implements [e73efc5badc8c217]. check-in: a2f843e87a user: thomas tags: trunk
16:59
Dialogs: Add a comment. Closed-Leaf check-in: 18db52e041 user: thomas tags: l10n
15:17
Work around issues with pylupdate5, which does not detect strings, if parameters are passed via object attribute access. Update translations with those affected strings from Crowdin. check-in: 3cfa25ee9f user: thomas tags: l10n
14:07
Update translations from Crowdin. check-in: ffc0e5ce0b user: thomas tags: l10n
14:07
Adjusted file type strings in dialogs check-in: 55364cc95c user: thomas tags: l10n
12:28
Simplify the context parameter of translate()-calls in DocumentAction classes. check-in: 615bc2a601 user: thomas tags: l10n
11:06
Merge with trunk. check-in: 984d726a07 user: thomas tags: l10n
11:06
Limit cx_Freeze to version 7.1 for now. 7.2 seems to break the compiled resources module somehow. check-in: 863c8e44c5 user: thomas tags: trunk
11:05
Fallback to PySide6 for lrelease on Windows with newest Python3, as PySide2 is unavailable there. check-in: 1d685e1367 user: thomas tags: l10n
2024-08-16
11:05
tox.ini: Fix weird issues with Python3.8, which started rejecting Path instances in shutil. check-in: 456c47032c user: thomas tags: l10n
2024-08-15
15:48
Update translations from Crowdin. check-in: bd75ae0595 user: thomas tags: l10n
15:47
Reworked some document action tooltip generation. Move formatting page ranges into the base class. check-in: f831a030f3 user: thomas tags: l10n
15:24
Load- and SaveAsDialog: De-duplicate setting the default file suffix by pulling the call into the base class. check-in: c8d73093a4 user: thomas tags: l10n
15:21
SaveLoadDialog: Replace f-String with normal string literal inside a tr() call. The f-string is undetected by lupdate. check-in: b46b9b2755 user: thomas tags: l10n
07:57
ActionLoadDocument: Fix exception raised in tooltip formatting code. One of the string parameters was not provided by format(). check-in: effe46d4d8 user: thomas tags: l10n
07:56
ActionAddCard: Fix off-by-one error in the tooltip formatting code. It did not properly translate from zero-based page indices to human-readabe page numbers for newly added pages. check-in: 05e8c642bb user: thomas tags: l10n
2024-08-14
14:47
Implement localisation support for ActionImportDeckList, ActionLoadDocument, ActionMoveCards, ActionNewDocument, ActionNewPage, and ActionDeletePage. check-in: 86ba17f60f user: thomas tags: l10n
14:23
Implement localisation for ActionNewPage, ActionDeletePage, ActionReplaceCard and ActionShuffleDocument check-in: 3cb7a61796 user: thomas tags: l10n
14:22
Remove en-GB locale, as the project starts to hit the Crowdin free tier word limit. check-in: 2008ecb8cf user: thomas tags: l10n
13:56
Implement localisation support for ActionCompactDocument and ActionEditDocumentSettings. check-in: ea248dea6b user: thomas tags: l10n
13:55
DocumentAction: Assign QCoreApplication.translate to the action base class, without the requirement to import QCoreApplication in each module. check-in: a4cbe51279 user: thomas tags: l10n
11:33
Update translations from Crowdin. check-in: 1b4c8d029a user: thomas tags: l10n
11:32
Marked the DeckImportWizard window title for translation. Fixed tab stop order of the first wizard page. check-in: 3bce7870b9 user: thomas tags: l10n
09:03
Fixed multiple typos and grammar issues in UI texts. check-in: 09d3267a61 user: thomas tags: l10n
08:40
DeckImportWizard: Fixed a plural form in _update_accept_button_on_oversized_card_count_changed() check-in: 035f27febb user: thomas tags: l10n
08:36
Merge with trunk. check-in: b2f18be941 user: thomas tags: l10n
08:12
scripts/compile_ui_files.py: Improve error handling: Log the offending file name, if compilation fails due to errors in the input file. check-in: e61781bb35 user: thomas tags: trunk
2024-08-13
18:51
tox.ini: Disable building cx_Freeze bundles on Linux for now when packaging. The tests for it are still run, but the packaging part is skipped, since they aren't distributed anyways. This significantly speeds up the packaging step. check-in: 941f438589 user: thomas tags: trunk
18:34
Add translations from Crowdin. check-in: 1d789c808e user: thomas tags: l10n
18:23
MainWindow: Fixed a bad substitution in a UI string. check-in: 3ae62bb37b user: thomas tags: l10n
17:54
Fix a typo in a UI string. check-in: 0f66722951 user: thomas tags: l10n
17:44
Add a few translation notes check-in: e378f8672d user: thomas tags: l10n
17:43
Renamed the source file for translations to mtgproxyprinter_sources.ts. The en-US file is no longer considered the source, which allows translating it via crowdin, enabling plural forms. check-in: b4c9309ae0 user: thomas tags: l10n
16:39
PageConfigWidget: Implement localisation of the resulting page capacity text. check-in: 2922e60ecb user: thomas tags: l10n
16:10
AboutDialog: Fixed fallback path to ThirdPartyLicenses.md check-in: 9164c2f418 user: thomas tags: l10n
16:04
Properly load qtbase localization based on [https://doc.qt.io/qtforpython-6/tutorials/basictutorial/translations.html] check-in: 25b5333660 user: thomas tags: l10n
16:03
scripts/update_translations.py: Fix get_lrelease() to allow it to pass the test. check-in: 3d8e6d27f9 user: thomas tags: l10n
14:57
Fix a missing whitespace in a logging message check-in: 3b59cfaf46 user: Thomas tags: l10n
14:53
scripts/update_translations.py: Only try to compile existing translation files. check-in: 0440bb5a18 user: thomas tags: l10n
14:48
Fix test_all_resource_files_are_listed_in_resources_qrc. It should skip .ts files, as those are not meant to be included in the compiled archive. Only compiled translations (suffix .qm) should be tested. check-in: 21cc3a812b user: Thomas tags: l10n
14:46
Fix running the unit tests, which now have a dependency on lrelease, so add PySide2 as a dependency for the "dev" extra. Unconditionally compile translations whenever running the unit tests check-in: d973151ae9 user: Thomas tags: l10n
14:24
WIP packaging for Windows. Add PySide2 as a packaging dependency, as PyQt5 does not provide the required lrelease binary. If lrelease is not on the $PATH, try to pry the binary path from the venv. check-in: 4aa5f62a4f user: Thomas tags: l10n
13:13
Add changelog entry. Fixed wording in another entry. check-in: 42650c702e user: thomas tags: trunk
13:04
CardDB migrations: Always run ANALYZE after running at least one migration script. check-in: 59d6b5e071 user: thomas tags: trunk
13:01
CardDatabase: Add another index to CardFace, aiding name translation. Bump schema version to 33. check-in: d7ef33826d user: thomas tags: trunk
12:49
Improve type inference. check-in: 3ee623fabe user: thomas tags: trunk
2024-08-12
12:54
Tests: Add test verifying that the document save file user_version flag matches the version in the file name. Also remove leading zeros in the SQL file. check-in: 28dd5d9aae user: thomas tags: embrace_pint
12:36
Ignore PNG files in the checkout. check-in: e3be1c3009 user: thomas tags: embrace_pint
2024-08-11
15:03
DocumentLoader: Do not store Quantity as text in the database within migration scripts. For consistency, older save versions must contain numbers. Quantity storage as text will be enabled in save version 7. check-in: 5930c2013a user: thomas tags: embrace_pint
14:48
Register a converter function for pint.Quantity to str for sqlite3, enabling the code to directly INSERT Quantity instances check-in: 1dd02ec4f2 user: thomas tags: embrace_pint
14:22
Started fixing tests check-in: 9228ac755c user: thomas tags: embrace_pint
14:18
Document/DocumentLoader: Convert pint.Quantity to float when writing to document save files. check-in: 4df8cda083 user: thomas tags: embrace_pint
13:43
Fix ConfigParser and SectionProxy type hints. Consistently use the custom subclasses from units_and_sizes module, instead of the default classes from the standard library. This enables proper type hinting support for the get_quantity() method. check-in: ff3195186a user: thomas tags: embrace_pint
13:23
ConfigParser: Annotate that parser[section] returns a SectionProxy that has the get_quantity() method. check-in: e5f1ce95b3 user: thomas tags: embrace_pint
2024-08-10
20:59
PrintCountUpdater: Move the write lock acquisition to the inner method. Extend the docstring describing the class. Also remove all attributes holding references to the class in the print dialog classes. The runner managing it's own instance tracking is sufficient. check-in: 8cf86ac4f0 user: thomas tags: trunk
20:33
PrintCountUpdater: Store print data in __init__, which stores the data synchronously from the main thread. Fixes race condition [bf93c2d3f5906085]. Also improve type hinting, and only store references to the required data, instead of the whole document instance. check-in: b905e53b5f user: thomas tags: trunk
17:24
Implement downloading Scryfall searches as CSV from the Scryfall API. Integrate into the deck list import wizard, adding a text field for Scryfall searches that can be directly imported as deck lists. Implements [d6085a9f5c42470a]. check-in: 3ac672ea94 user: thomas tags: trunk
17:23
ScryfallCSVDownloader: Enable downloading "extras", like tokens, planes, etc. Closed-Leaf check-in: 0a24e6d490 user: thomas tags: import_from_scryfall_api_search
17:20
Add changelog entry. Limit the Scryfall search query length to 900 characters. The API has a hard limit of 1000 characters, so stay below that. check-in: c53374c308 user: thomas tags: import_from_scryfall_api_search
17:13
ScryfallCSVDownloader: Enable multi-lingual support when fetching from the card search API. check-in: 0798c91285 user: thomas tags: import_from_scryfall_api_search
17:09
MeteredSeekableHTTPFile: Fail fast with HTTP status codes 403 and 404. The latter lets the Scryfall search downloader fail gracefully on queries returning zero cards. check-in: 9209237d4d user: thomas tags: import_from_scryfall_api_search
17:05
Implement downloading the entered Scryfall query when pressing the download query button. Amended MeteredSeekableHTTPFile to explicitly handle HTTP 400 Bad Request errors, and not re-try the connection on those. Instead fail fast, and propagate the exception to the calling code. check-in: 45ed90ef6a user: thomas tags: import_from_scryfall_api_search
16:45
DeckImportWizard: Implemented showing the current Scryfall search on the Scryfall website. check-in: 152c4882e8 user: thomas tags: import_from_scryfall_api_search
16:40
LoadListPage: Add a text field for Scryfall queries and a "view" and "download" button. The view button should show the query on the Scryfall website, the "download" button should donwload the query result as a deck list. Enable/Disable the view search and download search result buttons based on the entered Scryfall query. Only enable the buttons, if the text field has content. check-in: bf7362126f user: thomas tags: import_from_scryfall_api_search
16:02
Add changelog entry. check-in: 330d01fafe user: thomas tags: import_from_scryfall_api_search
15:55
Implemented downloading Scryfall search API links. The URL validator now accepts links to the search API that contain a non-empty query parameter (q=), and enforces CSV output. check-in: 5a42879f9c user: thomas tags: import_from_scryfall_api_search
15:33
ScryfallCSVParser: Hardened the parser against insufficient data when selecting a printing. If neither a card name nor both set code and collector number are available, skip the input lines. check-in: efcc761055 user: thomas tags: import_from_scryfall_api_search
15:21
ScryfallCSVParser: Adjusted parsing logic to work with API search results. check-in: f4ea673954 user: thomas tags: import_from_scryfall_api_search
15:07
ScryfallCSVParser: Add test cases for the new API search. check-in: 7337fefd6c user: thomas tags: import_from_scryfall_api_search
15:00
Add test case verifying that the sample data for the tappedout CSV parser is consistent with the actual live API results. check-in: 91311da813 user: thomas tags: import_from_scryfall_api_search
2024-08-08
21:15
PageConfigWidget: Fix updating the PageLayoutSettings when the UI updates. The raw floats from the QDoubleSpinBox instances have to get (un-) boxed in pint.Quantity, instead of directly set as is. check-in: 7f27d442c8 user: thomas tags: embrace_pint
09:25
Implement localization support for the document compacting action. check-in: 220ddf8845 user: thomas tags: l10n
08:06
Merge with trunk. check-in: 17b2a898a0 user: thomas tags: l10n
08:02
Fix translation of deck list file types. The previous approach was unsuitable, because the translations were requested from a static context without parser class instances, but the implementation required having class instances. It now translates via QCoreApplication.translate(). check-in: ba2a3833bd user: thomas tags: l10n
2024-08-07
21:03
Port loading document settings to use pint. Port PageLayoutSettings attributes to pint.Quantity. Port the PageScene to use pint.Quantity as parameters, where it previously took distances as raw float values. check-in: 6b82fda160 user: thomas tags: embrace_pint
19:32
Add custom ConfigParser and SectionProxy subclasses that implement get_quantity(), parsing INI config values to pint.Quantity. Use that to store document settings with units in the configuration file. check-in: 0aaf08f84d user: thomas tags: embrace_pint
17:55
units_and_sizes: Create the unit registry via a setup method. Register a conversion context for length ⇔ pixel conversions. The latter allows conversion without the need of an external function. check-in: 285cd70c39 user: thomas tags: embrace_pint
17:48
Allow floating point values for numerical document settings. Also clamp these values to the [0, 10000] range. Implements [25c5698daf89fc54] and [34f7de80cb8b803e] check-in: 8d9398b3cf user: thomas tags: trunk
17:46
DocumentSettings: Clamp all values to the [0, 10000] range, both when reading from the settings file and from loaded documents. This handles range violations more gracefully than resetting to defaults (settings file) or refusing to load (saved documents). Closed-Leaf check-in: bf1a830afd user: thomas tags: decimal_spacings
15:39
Remove rounding of decimal document settings to the nearest 1/12th. It wasn't playing nice with the UI. check-in: bae3d2bfc0 user: thomas tags: decimal_spacings
2024-08-04
18:38
DocumentLoader: Handle floats in loaded document settings. Also cap all values to 10000, to prevent DoS attacks via excessively large paper sizes. check-in: d1b1104d77 user: thomas tags: decimal_spacings
17:24
Replace the PageConfigWidget QSpinBox instances with QDoubleSpinBox instances. Update the PageLayoutSettings annotation type to float. Replace all related settings.getint() with .getfloat(). Automatically round decimal settings to the nearest permissible value. That behavior is quite strict and has to be tuned, because it is annoying right now. check-in: cd82a5590e user: thomas tags: decimal_spacings
16:35
Settings: Numerical document settings are now stored as floating point numbers that get rounded to nearest multiple of 1/12, which is 1px at 300 DPI. Add unit tests validating the rounding logic. check-in: 2f207555c2 user: thomas tags: decimal_spacings
15:24
Implement method round_to_nearest_multiple(value, multiple), which will be used to round fractional spacing values to values corresponding to full pixels. check-in: c71c27eb18 user: thomas tags: decimal_spacings
09:29
Fix accidental breakage in tests/test_settings.py introduced in [d5146895a0fa2850]. Somehow, a random keypress sneaked in unnoticed. check-in: 8149ef9703 user: thomas tags: l10n
2024-08-03
17:39
scripts/update_translations.py: Port to PyQt5 / pylupdate5. check-in: f9fe7a06a3 user: thomas tags: l10n
15:53
resources.qrc: List all localization files in alphabetical order. Incomplete entries are commented out. check-in: c25445758a user: thomas tags: l10n
15:40
scripts/update_translations.py: Add "clean" action that deletes compiled translation files. check-in: 82c4d422d1 user: thomas tags: l10n
2024-08-02
13:44
Reworded some UI text regarding print guessing, which is replaced with "print selection". Add a few input method hint flags to text fields, where appropriate. check-in: a59215f0b1 user: thomas tags: l10n
12:45
Application: Rework translation loading. The logging now logs both system locale and configured locale. check-in: c326f93a97 user: thomas tags: l10n
12:44
tox.ini: Add language compilation to the build steps. check-in: 51d5d1ddec user: thomas tags: l10n
11:42
Implemented loading the language based on the language set in the settings. check-in: 2ba27b64f0 user: thomas tags: l10n
11:33
Add setting and UI to select the application language. check-in: d5146895a0 user: thomas tags: l10n
11:31
scripts/update_translations.py: Create directory mtg_proxy_printer/resources/translations, if it does not exist. This allows pyside6-lupdate to run on a fresh checkout. check-in: 89dbc53f4b user: thomas tags: l10n
11:08
Add changelog entry. check-in: 001042ee20 user: thomas tags: l10n
2024-07-29
14:59
MainWindow: Fix typo in a tooltip. check-in: 65eac412d6 user: thomas tags: l10n
14:39
Implemented localization for progress bar texts. check-in: 977170348f user: thomas tags: l10n
13:36
Fix tr() calls for plural forms. lupdate does not support the keyword argument form, so it must be called as tr("%n", "disambiguation", count). check-in: aee2cb14d9 user: thomas tags: l10n
11:54
Dialogs: Fix RuntimeError by replacing localized string parameters to __init__ with setting them after parent __init__() returned. self.tr() only works after the Qt base class __init__() returned. check-in: 730e6124d3 user: thomas tags: l10n
2024-07-28
14:06
CentralWidget: Add localization support for the context menu actions. check-in: a40c14450c user: thomas tags: l10n
2024-07-24
12:59
Implemented localization support for the deck list parser file type displays. check-in: 544af09a92 user: thomas tags: l10n
07:42
Document: Implement localization support. check-in: 4a82236013 user: thomas tags: l10n
07:14
CardListModel: Implement localization support. check-in: d23b21f7cf user: thomas tags: l10n
2024-07-23
15:02
Replaced all f-strings within tr() calls with regular strings, and call format() outside of tr(). That makes the formatted strings translatable. check-in: ba5b2f3bad user: thomas tags: l10n
07:34
Ui string fixes. check-in: 2050ad6dff user: thomas tags: trunk
07:33
Additional UI string fixes. check-in: 9aa5a808c1 user: thomas tags: l10n
2024-07-22
12:06
Pick Ui string improvements from the l10n branch check-in: 44dfb78320 user: thomas tags: trunk
12:03
Fix UI string issues. Unset window titles for non-window widgets in UI files. check-in: 3c17ced1fc user: thomas tags: l10n
2024-07-15
15:24
Fixed a typo in a main window tooltip. check-in: 958939e0a3 user: thomas tags: trunk
14:44
Wrapped more UI strings in tr() calls. check-in: 324fdb1daa user: thomas tags: l10n
13:31
Merge with trunk check-in: e44653f0dd user: thomas tags: l10n
12:41
Merge with trunk. check-in: 8ab1ddc092 user: thomas tags: enum_based_paper_size
12:33
Merge with trunk check-in: caa7921983 user: thomas tags: port_pyside6
12:23
Merge branch v0.28.x into trunk check-in: 285bc9866c user: thomas tags: trunk
2024-07-07
13:36
Release v0.28.3 Closed-Leaf check-in: 51055abda3 user: thomas tags: v0.28.x_PySide6
13:02
Release v0.28.3 Closed-Leaf check-in: 04fa7b3ad7 user: thomas tags: release, v0.28.x, v0.28.3
12:44
Prepare Release v0.28.3 check-in: 72075ca415 user: thomas tags: v0.28.x
2024-06-25
08:28
Changelog: Removed duplicate section header. check-in: 088007bd1c user: thomas tags: v0.28.x
08:23
Fix garbage in the changelog, caused by a bad merge. check-in: c5b6450e59 user: thomas tags: trunk
08:21
Pick fix from trunk check-in: 0608b3a6ae user: thomas tags: v0.28.x
08:20
CardDatabase.get_available_sets_for_card(): Round-trip the input set, if the result is empty. check-in: 2f047aba17 user: thomas tags: trunk
08:06
Pick bug fixes from trunk check-in: eea41bb512 user: thomas tags: v0.28.x
08:05
Pick bugfix from the v0.28.x branch, fixing the MTGTop8 URL re to accept the optional www. subdomain. check-in: 0835442b0a user: thomas tags: trunk
2024-06-24
18:01
Add changelog entry. check-in: f06eec9479 user: thomas tags: v0.28.x
17:55
Fix MTGTop8Downloader rejecting valid links pointing to the "www" subdomain. www.mtgtop8.com is valid, too. check-in: 42c2c3d1b9 user: thomas tags: v0.28.x
2024-05-23
07:42
Encapsulate page size and orientation data in a new class PageSizeManager, located in units_and_sizes.py. This will allow hooking into Qt signals to update the acceptable page sizes based on configured margins. check-in: 4d6d717e71 user: thomas tags: enum_based_paper_size
2024-05-21
13:05
Merge with trunk. check-in: 3b115f5a02 user: thomas tags: enum_based_paper_size
13:05
Fix failing document tests. check-in: 4b34ab15ed user: thomas tags: enum_based_paper_size
12:22
Fix inclusion of ijson backends. Leaf check-in: 441de2ce03 user: thomas tags: cx_Freeze_via_pyproject_toml
12:12
Move cx_Freeze config to pyproject.toml, and delete setup_cx_freeze.py. This requires cx_Freeze version 7.0.0 check-in: 4cac67dec7 user: thomas tags: cx_Freeze_via_pyproject_toml
11:57
Tests: Remove a compatibility workaround with PyHamcrest 1.x, which is no longer supported. check-in: b3b3b31a01 user: thomas tags: trunk
2024-05-18
11:43
AddCardWidget: Honor any card name filter when switching the selected language. Fixes [0ead0455412fe659] check-in: 7c05a95a15 user: thomas tags: trunk
11:29
Improve print switching. Fixes [549fa41374aa99fa] and [91a01402742ea685]. check-in: 1709ec68e3 user: thomas tags: trunk
2024-05-17
14:06
Changelog: Re-worded an entry. Closed-Leaf check-in: 82c2a9cdd8 user: thomas tags: fix_print_switching
13:10
Fix crash when switching the card language, if all printings in the source language are hidden by card filters. check-in: a0b4fefcfa user: thomas tags: fix_print_switching
11:27
Properly round-trip data of hidden printings in get_available_sets_for_card() and get_available_sets_for_card() check-in: e9b25b7721 user: thomas tags: fix_print_switching
2024-05-16
08:30
WIP attempt at designing a query that round-trips the data of hidden printings, in case those are present in the document. check-in: aeab82e433 user: thomas tags: fix_print_switching
07:37
tests: Add helper update_database_printing_filters(), which implements updating the printing filters of the given card database to provided values. check-in: 08ca847ca6 user: thomas tags: fix_print_switching
2024-05-15
15:48
Add changelog entry. check-in: 50ae206700 user: thomas tags: fix_print_switching
14:57
Sort the returned set codes by release date. check-in: 2b89f47729 user: thomas tags: fix_print_switching
14:56
Fix another typo in test data. check-in: 25d5bedbbe user: thomas tags: fix_print_switching
14:54
Fix an error in test data. A JSON sample was loaded twice, instead of loading two distinct samples. check-in: d5199f7860 user: thomas tags: fix_print_switching
14:51
Properly handle card language, and de-duplicate results. check-in: 486c5a2d26 user: thomas tags: fix_print_switching
14:42
CardDatabase: Add WIP methods get_available_sets_for_card() and get_available_collector_numbers_for_card_in_set(). First returns the sets the given card is available in, the second returns the collector numbers the printing is available in within it's own set. check-in: 0a2f54fabd user: thomas tags: fix_print_switching
13:57
Add three JSON samples for Spirit tokens, that will be used in test cases. check-in: 3cc40b4577 user: thomas tags: fix_print_switching
2024-05-14
12:04
CardDatabase: Improve docstring for find_related_cards, updating it to the new semantics. check-in: 655d6af3bb user: thomas tags: trunk
2024-05-09
15:49
Add new card filter for Art Series cards. check-in: a0a2162a5a user: thomas tags: trunk
15:07
Improve the related card search: The search now finds token cards created by Dungeons. check-in: 4336a63d4e user: thomas tags: trunk
14:03
Removed instance tracking of MeteredSeekableHTTPFile instances. check-in: d99a0d7769 user: thomas tags: trunk
11:19
Use a dict to store instances in the Runner base class. check-in: 5cea0b88aa user: thomas tags: trunk
09:32
Add a few comments to the card info downloader. check-in: 310d05bbfd user: thomas tags: trunk
07:39
Merge bugfix from v0.28.x branch check-in: c3064fb3be user: thomas tags: trunk
2024-05-07
17:24
Release version 0.28.2 check-in: 740ea9fe95 user: thomas tags: port_pyside6
17:23
Release version 0.28.2 check-in: 651a2ce3c0 user: thomas tags: release, v0.28.x, v0.28.2
15:59
Implement fully automatic basic land removal in the deck import setting, and a settings option to enable/disable this. Implements [b2f3c8206d645eb6]. check-in: 138dc9d107 user: thomas tags: trunk
13:18
settings: validation and migration functions updated to use a different parameter name that does not shadow the settings object from module scope. check-in: 99cc4706b8 user: thomas tags: trunk
13:08
Add a label showing the last database update to the About dialog. Implements [380e741c5de8624d]. check-in: 6ebf65c941 user: thomas tags: trunk
2024-05-06
14:15
Release v0.28.1 Optimize bundle size by removing the unused Qt6 SQL drivers. check-in: d095077aaf user: thomas tags: port_pyside6
12:01
Prepare release v0.28.1 check-in: 331f2b9889 user: thomas tags: port_pyside6
11:49
Release version 0.28.1 check-in: d8bad16b5c user: thomas tags: trunk, release, v0.28.1
11:21
tests/test_document.py: Replace use of TemporaryDirectory context manager with the tmp_path PyTest fixture. This mitigates permission denied errors in the test suite on Win10. check-in: ac7cdaf56f user: thomas tags: trunk
10:56
Merge with trunk. check-in: ac60380b05 user: thomas tags: port_pyside6
10:53
tests/ui/test_page_scene.py: Remove all unused qtbot fixture uses. check-in: 176a3efad3 user: thomas tags: trunk
10:41
Actually use the ijson use_float API parameter to enable use of faster float() numbers. It seems to have been dropped previously, somehow. check-in: 3067d19708 user: thomas tags: trunk
08:14
Merge with trunk. check-in: 4ba81f1386 user: thomas tags: port_pyside6
07:39
scripts/compile_ui_files.py: Fix DeprecationWarning. check-in: 40a840ba4f user: thomas tags: trunk
07:24
Rework requirements compilation script. Leaf check-in: fbdc5d77ec user: thomas tags: recompile_requirements
06:31
Move compilation of requirements*.txt files into a dedicated script for reusability. check-in: f60659ea00 user: thomas tags: recompile_requirements
06:06
Also install the packaging tools into the development virtual environments. check-in: 29c29d008a user: thomas tags: trunk
06:04
create_development_environment.sh: Use the venv module to create the virtual environment, instead of virtualenv. check-in: 2736ca37f0 user: thomas tags: trunk
2024-05-05
19:21
Fix [3d7336c562aa18f7]. Downloading images via the MissingImagesManager properly emits the document dataChanged signals, causing the PageScene to update as intended. check-in: f80a76e87f user: thomas tags: trunk
18:47
Improve wording in the changelog. check-in: add7ebd38b user: thomas tags: trunk
18:00
Add changelog entry. check-in: e28d339eb5 user: thomas tags: trunk
17:57
Implement fix for [ad0d4560d70f7d04], including unit tests. check-in: 8e9d7275b6 user: thomas tags: trunk
17:54
Implement fix for [ad0d4560d70f7d04], including unit tests for card bleeds with two images. Closed-Leaf check-in: fa94deabdb user: thomas tags: fix_card_bleed
16:39
Tests: Add test case verifying that the CardItem origin point is equal to the origin of the contained card pixmap item. Also a few cleanups in another test. check-in: 221ea7ec8c user: thomas tags: fix_card_bleed
16:05
Tests: Add test_card_bleed_with_single_card test case verifying the card bleed rendering with a single card on the page. check-in: 53c6e3a340 user: thomas tags: fix_card_bleed
12:18
Add tests for sharp corner rendering. check-in: 4cfb5c524b user: thomas tags: fix_card_bleed
2024-05-02
12:59
Implement crude "round corners" for generated pixmaps. check-in: 6ddb0532bb user: thomas tags: fix_card_bleed
12:42
Tests: Replace boolean oversized parameter in create_card_with_pixmap() helper with a size parameter taking in a CardSize instance. check-in: 6f9be8556d user: thomas tags: fix_card_bleed
2024-05-01
14:28
Tests: Simplify and unify action application in tests/ui/test_page_scene.py. Always use document.apply(action). Also stop using the wait_signal() context manager, since action application is fully synchronous. check-in: 2746000e7a user: thomas tags: trunk
14:11
pyproject.toml: Add Python 3.12 to the supported versions classifier list. check-in: 37e46c7abd user: thomas tags: trunk
14:05
Dependencies: Require ijson 3.2.1 when running on Python 3.12. Also preemptively exclude "ijson.benchmark" from built packages, which will be included in future ijson versions. check-in: c6e1b9ab9f user: thomas tags: trunk
13:53
Dependencies: Bump minimum required version of PyHamcrest to 2.0.0. Tests already required it, so running the application only on 2.0 or later is reasonable. check-in: 8ad0978325 user: thomas tags: trunk
13:50
Add dependency on typing_extensions, when running under Python 3.10 or older. It was previously a transitive dependency of pint. Use typing_extensions for Self and NotRequired, instead of hacking something together. check-in: f578ec5ec9 user: thomas tags: trunk
2024-04-27
13:01
Fix a typo in a variable name check-in: 7774985a79 user: thomas tags: trunk
2024-04-26
13:39
test_page_scene: Refactor create_card_with_pixmap() helper. Remove the document parameter. Make the pixmap color configurable, defaulting to transparent. Use the CardSize enum to determine the image size, instead of hard-coding the dimensions in pixels for oversized cards. check-in: b4e0cecc45 user: thomas tags: trunk
2024-04-23
07:04
Merge fork check-in: 1057bac760 user: thomas tags: enum_based_paper_size
2024-04-22
09:11
WIP test loading various page layout settings from a save file. check-in: 7e45dc12dc user: thomas tags: enum_based_paper_size
2024-04-21
18:58
Sync with trunk check-in: dcacf3ca39 user: thomas tags: enum_based_paper_size
18:50
Reduce diff size with trunk branch. check-in: 4f380d4f49 user: thomas tags: port_pyside6
18:40
Mostly whitespace changes to reduce the diff between trunk and the port_pyside6 branch check-in: b925736397 user: thomas tags: trunk
18:29
Use the proper Qt enums in HoverEventFilter.eventFilter() check-in: 5c09339851 user: thomas tags: trunk
18:28
Pull Ui compiler improvements and class name / ui class name alignment improvements from branch [port_pyside6]. check-in: 55b69bba3a user: thomas tags: trunk
18:19
Merge fork. check-in: 9e133072a2 user: thomas tags: enum_based_paper_size
18:17
Align the class names in Python code with the class names defined in the Ui files. check-in: 971c1c3a7e user: thomas tags: port_pyside6
17:51
Rename the About dialog class to AboutDialog, to be consistent with the definition in the UI file. check-in: 13bf15e37d user: thomas tags: port_pyside6
17:47
Fix linter warning in HoverEventFilter.eventFilter(). check-in: 663367cfd3 user: thomas tags: port_pyside6
17:40
Improvements to the UI file compiler: Generated type hinting stubs now contain relative imports for the used classes and annotations for method parameters. check-in: 60692d9b25 user: thomas tags: port_pyside6
17:30
Improve type hinting imports: Deduplicate the found class usages by using a set instead of a list. Closed-Leaf check-in: 1e5f88d658 user: thomas tags: improve_ui_compiler
17:27
compile_ui_files.py: Use the class registry to locate used classes and generate type hinting imports for those during stub generation check-in: 0c82e96de8 user: thomas tags: improve_ui_compiler
16:59
Improve generation of the class registry. check-in: 6623df7d89 user: thomas tags: improve_ui_compiler
16:14
compile_ui_files.py: Build a class registry when creating type hinting stubs. It maps class names to FromImport statements. check-in: c383398645 user: thomas tags: improve_ui_compiler
15:55
Improve generation of type hinting stubs: Annotate function arguments with types, instead of using the types as is as argument names. I.e. replace (self, TypeName) with (self, arg1: 'TypeName') check-in: 65ce03d4b6 user: thomas tags: improve_ui_compiler
15:09
scripts/compile_ui_files.py: Re-order some definitions. check-in: 96b8bb7774 user: thomas tags: port_pyside6
15:05
Update the compile_ui_files script. De-duplicate the source and target paths by putting them into the global scope at the beginning of the script. check-in: 30d0af5b6c user: thomas tags: port_pyside6
11:47
test_document_loader.py: Further reduced boilerplate code. All tests now use helper functions _load_from_memory_database_expecting_success() or _load_from_memory_database_expecting_failure() to load data from an in-memory database. check-in: 0fa534983b user: thomas tags: enum_based_paper_size
11:19
test_document_loader: Decompose a complex test into 3 separate tests. Refactor common code into re-usable functions to reduce boilerplate code. One test is still WIP. check-in: 6d155b36ad user: thomas tags: enum_based_paper_size
11:16
test_document_loader: Reduce verbosity in test parameter generation. check-in: 256b338409 user: thomas tags: enum_based_paper_size
2024-04-19
13:23
Use the correct PageSizeId for "Custom" paper sizes, instead of using -1. check-in: ada8ebbc94 user: thomas tags: enum_based_paper_size
13:22
settings: Attempt at reading the default paper size from the default printer, instead of hard-coding it to A4. check-in: c42ccb2ecf user: thomas tags: enum_based_paper_size
13:21
units_and_sizes.py: Extract the test if a page size is acceptable into a re-usable function. check-in: 4ed219c92d user: thomas tags: enum_based_paper_size
12:47
units_and_sizes.py: Fix style warnings check-in: fcee8f673f user: thomas tags: enum_based_paper_size
10:15
Use localized paper size names when displaying them to the user in the PageConfigWidget check-in: d3e883b2cd user: thomas tags: enum_based_paper_size
10:08
Revert last change. The reverted code used potentially localized names as entries in the configuration file/save file, making both non-portable. check-in: 683811de76 user: thomas tags: enum_based_paper_size
2024-04-18
18:05
Add changelog entry. check-in: be31f5895f user: thomas tags: enum_based_paper_size
15:56
Use the paper size names obtained from QPageSize.name() as the string-representation of paper sizes. check-in: 3702a96bb0 user: thomas tags: enum_based_paper_size
15:44
Move page size and orientation enum dicts from settings.py to units_and_sizes.py. check-in: 7278a372ee user: thomas tags: enum_based_paper_size
10:22
PageConfigWidget: Implemented saving the page orientation to application settings, and highlighting the ui element when changed. check-in: dbf1d06107 user: thomas tags: enum_based_paper_size
10:17
PageConfigWidget: Populate the orientation combo box, and implement loading the current state from the application or document settings. check-in: 0d66526b29 user: thomas tags: enum_based_paper_size
2024-04-17
21:33
Settings: Add key paper-orientation to the documents setting. It stores if the document is in Portrait or Landscape mode. PageLayoutSettings: Add property page_orientation. Handle portrait/landscape handling in the page_height/page_width properties. check-in: a85dcd97a6 user: thomas tags: enum_based_paper_size
20:57
DEFAULT_SETTINGS: Lookup the A4 paper size from the PageSizeReverse dict, instead of hard-coding the string value. check-in: ef86234f90 user: thomas tags: enum_based_paper_size
20:51
settings: Refactor enum-reading code: Split logic for reading arbitrary enums inside PyQt classes from the post-processing code needed for the QPageSizeId enum. check-in: a6b5f1e0e1 user: thomas tags: enum_based_paper_size
19:56
settings: Remove paper sizes that cannot fit a single oversized card. check-in: d4f31b50d2 user: thomas tags: enum_based_paper_size
19:41
PageConfigWidget: Actually update the paper_size property in _on_paper_size_changed() check-in: 2af4de2732 user: thomas tags: enum_based_paper_size
19:30
PageLayoutSettings: Use the static QPageSize.size() in the page_height and page_width properties. check-in: a5cfaea8af user: thomas tags: enum_based_paper_size
19:29
PageLayoutSettings.to_page_size(): Add two logging lines. check-in: 4d083dbd11 user: thomas tags: enum_based_paper_size
19:22
Actually validate and update the paper size setting when changed by the combo box in the settings UI. check-in: 849dec4ec2 user: thomas tags: enum_based_paper_size
2024-04-11
14:41
PageLayoutSettings.to_page_layout(): Implement two code paths. One for predefined paper sizes and one for custom paper sizes. check-in: 925a1cf0e5 user: thomas tags: enum_based_paper_size
14:39
settings: The PageSize lookup dicts now use QPageSize.PageSizeId, instead of QPrinter.PageSize. Both are semantically the same, but the type system requires the first. check-in: a9273cb70d user: thomas tags: enum_based_paper_size
14:38
PageConfigWidget: Rename the custom page size widgets in the Ui class by adding the "custom_" prefix. check-in: 78b661a353 user: thomas tags: enum_based_paper_size
14:04
PageLayoutSettings now returns the paper dimensions for non-custom paper sizes by querying the Qt QPageSize class. check-in: 6331013c55 user: thomas tags: enum_based_paper_size
13:56
Update the verification logic when loading settings from a document to check the custom page dimension fields for valid values. check-in: 895a845bc5 user: thomas tags: enum_based_paper_size
13:54
PageLayoutSettings: Rename page_height to custom_page_height and page_width to custom_page_width. Add properties page_height and page_width with setters, delegating to the custom values. check-in: e18dae2cdd user: thomas tags: enum_based_paper_size
13:38
Add paper_size attribute to the PageLayoutSettings class. check-in: 9fa3c4bc86 user: thomas tags: enum_based_paper_size
13:28
settings.py now uses the TypeVar from units_and_sizes.py check-in: ee79d80a1d user: thomas tags: enum_based_paper_size
13:27
Add a generic type variable to units_and_sizes.py check-in: e84a0f8702 user: thomas tags: enum_based_paper_size
13:09
Settings: Add "paper-size" to the default document settings. Move the QPrinter.PageSize enum parsing into settings.py. Setting "paper-size" defaults to "A4". If not "Custom", it will take precedence over the paper-height-mm and paper-width-mm settings. Validation checks, if the value is one of the known constants. check-in: dd67b7958f user: thomas tags: enum_based_paper_size
09:49
Add a drop-down to the PageConfigWidget, listing all known, common paper sizes. The paper size table is filled by iterating over QPrinter. See [https://stackoverflow.com/questions/39676200] check-in: 040ac4fab7 user: thomas tags: enum_based_paper_size
09:01
Remove two debug logging lines in the PageConfigWidget. check-in: 19b91df610 user: thomas tags: trunk
2024-04-10
18:44
Improvements to the compilation scripts. Improve module docstrings, and type annotations. check-in: 924cf956c2 user: thomas tags: trunk
17:04
Dependencies: Adjust name of the PySide6 package to PySide6_Essentials (with an underscore), as that seems to be the canonical name of the wheel. check-in: 90b80bbc45 user: thomas tags: port_pyside6
2024-04-09
21:42
Merge with trunk. check-in: 6e92bc1233 user: thomas tags: port_pyside6
21:24
Reorder imports in scripts/compile_resources.py and use from-imports for pathlib.Path check-in: 455fdc9f68 user: thomas tags: trunk
21:08
Add a landscape bug workaround to the PDF and printer settings. If enabled, PDF exports / direct prints of landscape documents are rotated by 90° internally. check-in: f00db60353 user: thomas tags: trunk
21:06
Add changelog entry. Closed-Leaf check-in: 5302908350 user: thomas tags: landscape_workaround
20:42
Reword the PDF landscape workaround tooltip in the settings window. check-in: 985a3a2b73 user: thomas tags: landscape_workaround
20:13
Implemented rotating direct printouts when landscape workaround in the printer settings is enabled. check-in: cb96d6c46f user: thomas tags: landscape_workaround
18:13
Add landscape workaround setting to the printer settings. Add checkbox for toggling this to the printer settings UI. check-in: 5ca45a7a17 user: thomas tags: landscape_workaround
18:05
Add a checkbox toggle to the PDF settings to change the landscape workaround for PDF exports. check-in: 9c515bfde3 user: thomas tags: landscape_workaround
17:44
Add boolean setting "landscape-compatibility-workaround" to the pdf-export settings section. If set to True and the document is in landscape format, the PDF export is rotated 90°. check-in: c89cdae748 user: thomas tags: landscape_workaround
17:36
Merge with trunk. check-in: ad8f614d2b user: thomas tags: landscape_workaround
17:25
Refactor settings: Move PDF-export related settings into their own config section named "pdf-export". check-in: cf5b51e82d user: thomas tags: trunk
16:50
hasgetter.py: Improve type hinting, according to [https://github.com/hamcrest/PyHamcrest/pull/209]. check-in: 13edcea509 user: thomas tags: trunk
2024-04-01
13:51
Use Path.with_name()/Path.with_stem() where appropriate. check-in: 7686c43c12 user: thomas tags: trunk
2024-03-31
19:53
Dependencies: Fix dependency specification on pint: Use pint < 0.22 on Python 3.8. Do not compare the platform, so that Windows builds using newer Python can also use newer pint versions. check-in: 45d635eec1 user: thomas tags: trunk
18:52
MANIFEST.in: Fix path to doc/ThirdPartyLicenses.md check-in: f6bf63b29d user: thomas tags: trunk
2024-03-29
19:57
WIP port to typed-config. Still incomplete! Leaf check-in: b85ca6947c user: thomas tags: typed_config
2024-03-28
17:41
Dependencies: Bump typed-config to >= 1.4, which adds boolean_cast to typedconfig.casts, implementing support for boolean configuration values. check-in: 1183f78180 user: thomas tags: typed_config
12:16
Rename settings objects: The legacy settings and default settings are now named with suffix _old/_OLD. The new typed config took the previous names. check-in: 1588f467fb user: thomas tags: typed_config
11:49
settings.migrate_settings() now returns a boolean. Returns True, if at least one migration script performed a transformative action, False otherwise. check-in: 98f8413c7a user: thomas tags: typed_config
11:22
Add a copy of the application settings using typed-config. check-in: 7bf03fd3f8 user: thomas tags: typed_config
09:08
Add dependency "typed-config" [https://pypi.org/project/typed-config/]. check-in: eee92673d5 user: thomas tags: typed_config
00:24
Update the build system and cleaned up the repository root a bit. check-in: c3d963bc18 user: thomas tags: trunk
00:22
tox.ini: Use the same one-liner also on Linux. With this, drop the dependency on external commands move (Windows) and mv (Linux). Closed-Leaf check-in: 846094c302 user: thomas tags: refactor_build_system
00:16
tox.ini: Windows move command seems to not work, so use a Python one-liner instead. check-in: b29dcbe5d7 user: thomas tags: refactor_build_system
2024-03-27
23:45
Fix moving the resources directory on Windows. check-in: 85553db8ba user: thomas tags: refactor_build_system
23:45
Move ThirdPartyLicenses.md into the doc directory. check-in: bba9f64356 user: thomas tags: refactor_build_system
23:29
tox.ini: Move the raw resources out of tree after compiling them. Move them back into place in teardown code. With this, the unit tests running under the "compiled" factor do not have access to the raw resource/UI files, mimicking the state inside a frozen application bundle. check-in: 0a0c68be84 user: thomas tags: refactor_build_system
22:57
The packaging scripts now only use the native Python 3 version to package, and not any additional versions that may be around. check-in: 882e6bf7d5 user: thomas tags: refactor_build_system
22:47
Fixed tox invocation in packaging scripts. check-in: 5f1139aa16 user: thomas tags: refactor_build_system
22:44
tox.ini: Introduce the "plain/compiled" factors. Compiled runs the resource and UI compilers in setup code, and restores the tree in teardown code. Plain simply runs the test with the in-tree resources and UI files. check-in: cb786c52ab user: thomas tags: refactor_build_system
22:43
The packaging scripts now use tox run --factor, which allows selecting the packaging tox environment by only specifying the "package" factor. check-in: 1bec447423 user: thomas tags: refactor_build_system
22:30
compile_resources.py: Remove debug path output. check-in: 2ed8c4c264 user: thomas tags: refactor_build_system
22:19
Replace setup.py with a dedicated script to compile the Qt resources. This gets rid of setup.py in the repository root directory. check-in: f1f2c1d91a user: thomas tags: refactor_build_system
21:15
tox.ini: Removed testing for platformdirs==2.6, as that is currently broken. The new setup locks dependencies in generated requirements, preventing the previous way of installing the two variants with 2.6 or >= 3.3. check-in: 838de9c889 user: thomas tags: refactor_build_system
17:51
Try silencing warnings about potentially missing packages, emitted by setuptools. The resources are not part of the to-be-distributed files when building packages. check-in: 68e4f5f178 user: thomas tags: refactor_build_system
17:32
Requirements: Include tox >= 4.0 in the development requirement, ensuring it is put into the virtual environment on systems without a system-wide installation. check-in: c6266f2388 user: thomas tags: refactor_build_system
17:12
tox.ini: Move cleanup tasks in packaging environments from the commands list to commands_post list. The UI files cleanup now runs in teardown code. check-in: 8daf4ef16f user: thomas tags: refactor_build_system
16:57
Use the tox run command in the unit test runner scripts. check-in: e6c1e4981e user: thomas tags: refactor_build_system
16:52
Use the generated requirements.txt files inside tox.ini to ensure consistent versions across environments. This also de-duplicates the requirements, as another copy was also hard-coded in tox.ini. Bump minimum tox version to 4.0 and use the new subcommands to run the tox environments in the build* scripts. check-in: a8470273af user: thomas tags: refactor_build_system
16:51
Use pip-tools to automatically generate the requirements.txt variants. Use the requirements-dev.txt variant to create the development virtual environment. check-in: 06cbdabfc1 user: thomas tags: refactor_build_system
16:36
tox.ini: Use long form options, like pass_env, instead of passenv. Add environment descriptions that are shown when listing tox environments. check-in: acf73e15e7 user: thomas tags: refactor_build_system
15:56
Remove requirements.txt. Also add it to the ignore-glob. The requirements.txt duplicates the requirements also stated in pyproject.toml. It will be automatically generated in the future. check-in: 56c3698f8f user: thomas tags: refactor_build_system
15:53
Move tox.ini out of pyproject.toml. tox still does not support pulling config from pyproject.toml natively, so pull the config out for better syntax highlighting. check-in: a32c0920af user: thomas tags: refactor_build_system
15:52
Fix cx_Freeze builds on non-Windows platforms. Optimizations applied in [b7967a44a77e31ec] stripped parts of platformdirs not used on Windows. But this affected all builds globally. So put the excludes into a module-level list and strip the parts only when the current platform is Windows. check-in: f63a6ba146 user: thomas tags: trunk
12:42
Rotate landscape PDFs by 90°. This makes all landscape documents export as portrait pages with rotated content. check-in: 6eb6ee9729 user: thomas tags: landscape_workaround
2024-03-25
14:31
ComboBoxItemDelegate: Re-order source model resolution to avoid a type hinter warning in setEditorData(). check-in: 33d2c46379 user: thomas tags: trunk
13:04
Settings: Reorganize some settings. Moved PDF export options and printer options to their dedicated settings pages. Refactor how the page model is populated. check-in: ee1f7ab967 user: thomas tags: trunk
13:03
DecklistDownloader: Improve type annotations Closed-Leaf check-in: 5dec7a06dd user: thomas tags: reorganize_settings
13:03
SettingsWindow: Improve type annotations and remove an unused local variable check-in: 90e130d061 user: thomas tags: reorganize_settings
13:02
DeckImportWizard: Fix type warnings. check-in: 0b054d25f0 user: thomas tags: reorganize_settings
13:01
MainWindow: Fix typo in show_application_update_available_message_box(). check-in: 4eceb760fe user: thomas tags: reorganize_settings
13:00
ProgressBar: Fix typo in _set_retain_size_policy(). check-in: bbadb23bab user: thomas tags: reorganize_settings
12:59
Remove PageRenderer.scene() re-implementation, as it no longer serves a purpose. check-in: d0175b2cbc user: thomas tags: reorganize_settings
12:47
BlockedSignals: Rename variables, so that they are no longer treated as typos. check-in: fc54e87e59 user: thomas tags: reorganize_settings
12:40
Settings: Reformat some long lines and add logging messages when the user selected a wrong type in the debug settings download/import buttons. check-in: 7319ee1666 user: thomas tags: reorganize_settings
12:20
Settings: Move the PDF export path setting to the PDF settings page. check-in: 7f3307642d user: thomas tags: reorganize_settings
11:08
Settings: Add button to the Debug settings that opens the Cutelog website when clicked. check-in: a15b7130e5 user: thomas tags: reorganize_settings
10:39
Move the settings page metadata shown in the pages view into the individual settings pages. Now, the type system warns on incomplete data, because the required metadata is defined as an abstract property in the Page base class. check-in: c171a7bd90 user: thomas tags: reorganize_settings
10:19
Moved PDF export and printer settings to new settings pages. check-in: 7203e50371 user: thomas tags: reorganize_settings
2024-03-24
22:09
Further optimizations for the MSI build size, by stripping a few more PyQt5 components the app does not use. check-in: b7967a44a7 user: thomas tags: trunk
20:17
Optimize Windows build size check-in: b1a4d9c3d4 user: thomas tags: release, port_pyside6
18:05
Release v0.28.0 check-in: 2496cf31f0 user: thomas tags: port_pyside6
18:02
Release v0.28.0 check-in: a148d5b6fb user: thomas tags: trunk, release, v0.28.0
18:01
Release v0.28.0 Edit: Undo release tags. Next check-in fixes the bad reference in the changelog.) check-in: 8bf2c82897 user: thomas tags: trunk
17:29
Merge with trunk. check-in: d1fcdfc588 user: thomas tags: port_pyside6
17:27
Remove an unused import check-in: 66edb9ca6c user: thomas tags: trunk
16:15
Support automatic deck list downloads from Manabox.app. See [b76a375bc3f622fe] check-in: 205d04dff1 user: thomas tags: trunk
15:38
MeteredSeekableHTTPFile: Use a dict to store instances, instead of a list. check-in: 6ef061b972 user: thomas tags: trunk
15:33
PageConfigWidget: The paper size is now the reference point and imposes restrictions on the margin sizes. Increasing the margins no longer automatically increases the paper size to make the margins fit. check-in: 9c53dd5750 user: thomas tags: trunk
13:09
Fixed page capacity display in the settings lagging behind by one change. Culprit was the signal connection via UI files: These caused the validation and display update slots to be called first, before the actual PageLayoutSettings instance got updated. The signal connections are now defined in code and the validation slots are called last. check-in: f03b17d3b6 user: thomas tags: trunk
11:33
hasgetter.py: Improved error message if the hasgetter() hamcrest matcher detects a failure. check-in: a7551b89fb user: thomas tags: trunk
2024-03-21
14:24
Fix package name of dependency cx_Freeze in the requirements. While the official documentation states "cx_Freeze", the canonical package name is "cx-Freeze". While the underscore variant does re-direct to the proper package, it causes PyCharm's dependency monitoring to complain. check-in: be4626583e user: thomas tags: trunk
2024-03-20
13:56
Tests: Refactor tests/ui/test_page_config_widget.py to create the PageConfigWidget via a pytest fixture. check-in: 6ba8aadad7 user: thomas tags: trunk
13:43
Add feature to flip the paper width and height values via a single button click. It allows toggling between portrait and landscape mode. check-in: fbb4b1a4cb user: thomas tags: trunk
13:42
Add button to the PageConfigWidget that flips the page height and page width values. This toggles between landscape and portrait mode. Closed-Leaf check-in: d53c8b1e89 user: thomas tags: flip_paper
13:17
Add icon transform-rotate to the internal icon theme. check-in: 7793f5d773 user: thomas tags: flip_paper
13:03
Add changelog entry for the square corner lines issue. check-in: 14d2b7445a user: thomas tags: trunk
2024-03-19
15:28
Merge with trunk. check-in: 8af3ef4438 user: thomas tags: port_pyside6
15:21
Merge with trunk check-in: 11e3c7f5ab user: thomas tags: l10n
15:15
Update display strings based on notes on crowdin. check-in: 359e1d63e7 user: thomas tags: trunk
14:42
Fully hide zero-width card bleeds. Likely fixes [51862cdc87d0b9ae]. check-in: 4b588c7851 user: thomas tags: trunk
13:52
Merge fork in trunk. check-in: f19cb2d17d user: thomas tags: trunk
2024-03-14
14:08
Add missing signal connection between the DebugSettingsPage and the SettingsDialog. Downloading card data to file works again. Fixes [76ffc931a7047e1f]. check-in: 3e61b0f8cd user: thomas tags: trunk
2024-03-11
20:52
PrintingFilterWidget: Use the QUrl.ParsingMode enum, instead of bare constants. check-in: bd6e68ece8 user: thomas tags: trunk
20:41
Reducing diff size with trunk, round 3. check-in: 33b5ec2dec user: thomas tags: port_pyside6
19:38
Changelog: Removed a duplicated entry. check-in: 7c63a3cbd9 user: thomas tags: port_pyside6
2024-03-08
16:48
Update README.md. check-in: 755e84278d user: thomas tags: trunk
2024-03-01
16:47
PageConfigWidget: Display the page capacity for both regular and oversized cards. check-in: 4bc1afbfc9 user: thomas tags: trunk
2024-02-29
16:44
Merge with trunk. check-in: 6de151087e user: thomas tags: port_pyside6
11:23
Properly handle double-faced tokens and Dungeon cards. These are now hidden by the "hide-tokens" filter and the related cards search stops at them. Fixes excessive related cards results with Incubator tokens, The Ring emblem, "venture into the Dungeon", and "Take the initiative." Fixes [aad4fb275224cc6e]. check-in: ab80f94db8 user: thomas tags: trunk
11:15
Implement removal of obsolete related printings by purging the entire RelatedPrintings table before writing new entries. Closed-Leaf check-in: 94a1bc67c2 user: thomas tags: df_tokens
09:55
Add import test case for the 3 double-faced tokens in the JSON samples. check-in: 323391b5b1 user: thomas tags: df_tokens
09:51
Add a description to an assert in test_carddb.py check-in: 11b31addbb user: thomas tags: df_tokens
08:13
Tests: Rename JSON sample from double_faced_card_without_top_level_oracle_id.json to reversible_card.json check-in: 2231d103f0 user: thomas tags: df_tokens
2024-02-28
18:28
Add changelog entry. check-in: bf32a1121a user: thomas tags: df_tokens
18:21
Handle double-faced tokens and treat Dungeon cards as tokens during the card data import. Fixes the token card filter, and causes the related card search to stop at these. The app still needs to rebuild the related cards table and remove the relations from existing databases. check-in: e3060aeaca user: thomas tags: df_tokens
13:22
Runner script: Add CardDatabase.find_related_cards() to the list of profiled methods. check-in: d3f50be54b user: thomas tags: trunk
11:59
crowdin.yml: Remove a leading slash in a path. check-in: eda3b88a87 user: thomas tags: l10n
2024-02-27
11:14
pyproject.toml: Add link to the translation project to the URLs section. check-in: 8466159fdd user: thomas tags: l10n
2024-02-26
16:59
AddCardWidget: Unify punctuation in display text between both variants. check-in: 9dd3fe94da user: thomas tags: l10n
15:54
AboutDialog: Mark some labels as non-translatable, and add a few context comments. check-in: 1173c7c4bf user: thomas tags: l10n
15:53
Fix string upload. Also drop obsolete strings when updating the source strings from code. check-in: dd48f9e4a1 user: thomas tags: l10n
15:45
Enable string extraction for UI files. check-in: 4b35fdcd34 user: thomas tags: l10n
15:39
Fix mapping between locales provided by Crowdin and locale names loaded by Qt. Implement loading translations in the Application class. For now, register en_US and de as languages included in the compiled resources. check-in: 683c39cb22 user: thomas tags: l10n
14:42
Add crowdin.yml and scripts/update_translations.py to manage the project translations on Crowdin.com. check-in: 9669d98d02 user: thomas tags: l10n
14:23
Project settings: Ignore .qm files, containing compiled translations in a binary format used by Qt. check-in: 361d63b6f3 user: thomas tags: l10n
2024-02-24
22:55
SettingsWindow: Wrap UI strings in tr() calls, which allows the extraction via Qt's lupdate tool. check-in: 9dfaf2b878 user: thomas tags: l10n
13:21
Merge with trunk check-in: 08ec3f3c83 user: thomas tags: port_pyside6
12:12
Refactor the settings window: - Replace the tabs with a list view showing the pages - Add icons to pages - Highlight changes when hovering over the Reset and Restore Defaults buttons - When clicking those, ask the user if they want to apply the reset/restore to the current or all pages - Also add the highlighting feature to the DocumentSettingsDialog check-in: 71dcabf978 user: thomas tags: trunk
12:07
Added links in the changelog for recently added card filters. Closed-Leaf check-in: 65cf221ce8 user: thomas tags: refactor_settings_window
11:49
Reworded a changelog entry. check-in: cea54f25c6 user: thomas tags: refactor_settings_window
11:41
Add changelog entry mentioning the highlighting. check-in: dad430f6e7 user: thomas tags: refactor_settings_window
11:41
SettingsWindow: Remove the highlighting when the user clicks the Reset or Restore Defaults button. check-in: 2107015205 user: thomas tags: refactor_settings_window
11:26
Implement change highlighting for the DocumentSettingsDialog. check-in: 699d0bfcfa user: thomas tags: refactor_settings_window
2024-02-23
14:46
Set highlight effect strength to 0.75, improving rendering of dark, highlighted text on light background. check-in: aef535e916 user: thomas tags: refactor_settings_window
14:43
Query the current color palette for the highlight color and use that for the widget highlight. This may need some tweaking to make it look better. check-in: 0719462d1a user: thomas tags: refactor_settings_window
14:09
Move function highlight_widget() into ui.common.py, as it is used by different classes in the same way. This unifies the handling across the whole application. check-in: 41d1797f8d user: thomas tags: refactor_settings_window
14:05
Implemented change highlighting for the PageConfigWidget for changes against the application settings. check-in: 5f89f0100d user: thomas tags: refactor_settings_window
13:21
Implemented change highlighting for the printing filter widget classes. check-in: c2da86667d user: thomas tags: refactor_settings_window
11:59
Page: Rename set_highlight() to highlight_differing_settings() check-in: b688b5663c user: thomas tags: refactor_settings_window
11:55
Implement set_highlight() for the remaining pages. This currently does not work on widgets in subclasses, which is still TODO. check-in: 2faf914c75 user: thomas tags: refactor_settings_window
11:22
Directy implement clear_highlight() in the Page base class. Use QObject.findChildren() for this, and simply remove all effects from all child QWidgets. check-in: 703a0f5c80 user: thomas tags: refactor_settings_window
10:40
Add docstrings to the Page class. check-in: e01f93f173 user: thomas tags: refactor_settings_window
10:34
Refactor highlight effect creation: Move the logic into a dedicated method, instead of duplicating the same lines all over the module. check-in: 68bb4a283e user: thomas tags: refactor_settings_window
10:27
Implement highlighting on the DecklistImportSettingsPage. Mark the highlighting methods in the base class as abstract. check-in: 62f3df9897 user: thomas tags: refactor_settings_window
10:14
Implement API for highlighting changed settings and clearing the highlight. The highlighting is implemented by adding a QGraphicsColorizeEffect on the widgets, which tints them blue. The trigger is implemented by using an event filter on the Reset and Restore Defaults buttons, which triggers the highlighting on hover events. check-in: e013cb694a user: thomas tags: refactor_settings_window
09:29
Dialogs: Resolve file system paths stored in the settings on access. This allows using shortcuts, like "~/Documents" on Linux. check-in: ecf0066056 user: thomas tags: trunk
2024-02-22
15:38
SettingsWindow: Unify button labels in reset() and restore_defaults(). They now use a unified templating. check-in: 51cff04681 user: thomas tags: refactor_settings_window
15:22
SettingsWindow: restore_defaults() and reset() now ask, if they should apply to the currently shown page or all pages. check-in: c35c1c24c9 user: thomas tags: refactor_settings_window
15:18
Fix test that referenced the no longer existing tab widget to refer to the page stack instead. Rename the test and test module to no longer refer to tabs. check-in: fca6650fef user: thomas tags: refactor_settings_window
14:20
SettingsWindow: reject() no longer calls reset(), instead performs the reset itself. check-in: 439128c891 user: thomas tags: refactor_settings_window
14:19
settings_window.py: Put both QMessageBox.StandardButton and QDialogButtonBox.StandardButton into the global scope and rename them, so that both can live together in the same scope. Reduces verbosity in the usage locations. check-in: 447c1a244f user: thomas tags: refactor_settings_window
13:58
Rename variables in SettingsWindow.accept() to more expressive. check-in: e471d80ad5 user: thomas tags: refactor_settings_window
2024-02-19
18:07
Add changelog entry. check-in: a877c2f354 user: thomas tags: refactor_settings_window
17:16
Implemented syncing the two page selection widgets, completing the refactoring. check-in: bc115924e5 user: thomas tags: refactor_settings_window
16:38
Link the page_selection_list_view with the stacked pages. Selecting a page now switches to it. Also select the first page when instantiating the dialog to have a consistent view. check-in: 2c18941f3e user: thomas tags: refactor_settings_window
16:29
SettingsWindow: Select the first item in the page selection list view. check-in: a64e3e7bc5 user: thomas tags: refactor_settings_window
14:25
Settings Window: Set up reactive design. The page list view is shown when the window is more than 750 pixel wide. Otherwise, the page list drop-down is used. Adjusted the horizontal expands in the UI so that the configuration widgets get a bit more space. check-in: f305fad8b7 user: thomas tags: refactor_settings_window
13:33
SettingsWindow: mark the icon name parameter in item_factory() as optional. check-in: ecf108dae0 user: thomas tags: refactor_settings_window
13:32
SettingsWindow UI: set property uniformItemSizes to True. check-in: 1c6882e5e9 user: thomas tags: refactor_settings_window
13:22
Add icon view-hidden.svg to the icon theme. It is used by the settings window for the print hiding page. check-in: 32554ab1fa user: thomas tags: refactor_settings_window
13:06
DeckImportWizard: Fix log line in on_deck_list_browse_button_clicked(). The line indicating the user replaces an existing deck list should only be logged, if the deck list is actually non-empty. check-in: 0a5adffe8c user: thomas tags: trunk
12:46
SettingsWindow: Implement a page model based on QStandardItemModel and QStandardItem. The model is not yet connected with the stacked pages widget, and a few icons are not yet decided on. check-in: 7466e6f158 user: thomas tags: refactor_settings_window
12:44
Settings Window UI: Set the page list view icon size to 22x22. check-in: 7b727ff81d user: thomas tags: refactor_settings_window
11:47
SettingsWindow: Convert UI to use a QStackedWidget, instead of a QTabWidget for settings pages. The model required for page switching is not yet in place. check-in: e939812ee4 user: thomas tags: refactor_settings_window
11:46
Tests: Remove unused imports check-in: f4b11d0e5a user: thomas tags: refactor_settings_window
2024-02-18
17:37
Refactor tests/ui/settings/test_set_filter.py to work with the new settings window structure. The tests now test the specific page, without instantiating the whole settings dialog, thus run a good bit faster. check-in: e118aa6154 user: thomas tags: refactor_settings_window
17:23
Resolve circular imports by moving the settings Page subclasses into a new, separate module. check-in: 13c31f4b32 user: thomas tags: refactor_settings_window
17:09
Decompose the SettingsWindow class by extracting all pages into individual classes. check-in: 44f7aa2f81 user: thomas tags: refactor_settings_window
16:46
Fix module paths for custom widgets set in settings_window.ui. check-in: 2b55ece870 user: thomas tags: refactor_settings_window
15:28
Extracted tab contents of the SettingsWindow into individual UI files. check-in: d0c9c55371 user: thomas tags: refactor_settings_window
2024-02-14
16:51
ImageDatabase: Remove module constant IMAGE_SIZE, replacing usages with CardSizes.REGULAR, defined in units_and_sizes.py. Tests: Replace "white" blank image with a transparent one, to be in line with changes introduced in [8e8346ca98b4313e]. check-in: b1d7ab960c user: thomas tags: trunk
16:31
Remove a long-broken and disabled test for check card rendering. check-in: 0464c217d7 user: thomas tags: trunk
16:28
Fix a few reported style issues. check-in: d818cd65b8 user: thomas tags: trunk
16:01
Remove explicit parameters passed to super() calls. These are not required and get filled automatically. check-in: e1063f026b user: thomas tags: trunk
15:45
Cache cleanup wizard: The image tooltip now shows the card name translated into the preferred language, if the card language does not match the preferred language. Implements [dacf73a1304303f5]. check-in: de36a62811 user: thomas tags: trunk
2024-02-07
09:34
Merge with trunk check-in: b9395505f1 user: thomas tags: duplex_printing
09:20
Merge with trunk Leaf check-in: 15bcb5d42b user: thomas tags: decklist_export
09:19
Merge with trunk Leaf check-in: 51e9305d88 user: thomas tags: additional_deck_list_websites
09:16
Merge with trunk Leaf check-in: abf38abb29 user: thomas tags: first_launch_wizard
09:08
Merge with trunk check-in: 4679d186d9 user: thomas tags: port_pyside6
2024-02-04
18:20
Release v0.27.0 check-in: 0fb5f602a5 user: thomas tags: trunk, release, v0.27.0
18:02
Implement drawing thick outlines around cards. check-in: 5095c6ad51 user: thomas tags: trunk
17:57
Serialize image downloads. This prevents multiple progress reports from overwriting each other. check-in: dcaf1aa3cb user: thomas tags: trunk
17:57
Fix name clashes during card image download, if the downloader concurrently fetches both sides of a DFC. check-in: 8dc245eed0 user: thomas tags: trunk
17:20
Add changelog entry. Closed-Leaf check-in: 62282c06ee user: thomas tags: card_bleed
17:04
Implemented corner bleeds. check-in: c0cafcb56c user: thomas tags: card_bleed
16:12
CardBleeds: Renamed from_image() to from_card() and replace the QPixmap parameter with the Card instance. check-in: 84dd2ce161 user: thomas tags: card_bleed
15:37
CardItem.create_corners(): Refactor position computation code by factoring out the coordinate math into local variables. check-in: acdf5ff51c user: thomas tags: card_bleed
14:24
CardItem: Replace the corner_area attribute with the static CORNER_SIZE_PX attribute. check-in: 0d77524cf2 user: thomas tags: card_bleed
13:08
CardItem: Refactor create_corners() to not use itertools.starmap(). Instead, call _create_corner() directly inside a list literal, which improves type hinting and reduces complexity. check-in: 6ccb299a59 user: thomas tags: card_bleed
09:58
Improve variable handling in update_bleed_size(). Use tuple unpacking to assign scaling to named scalars. check-in: 292dee8d63 user: thomas tags: card_bleed
2024-02-03
17:00
Explicitly set a Z value for card corners. They now stack between card images and card bleeds. check-in: d7387d4061 user: thomas tags: card_bleed
16:39
Move the text elements below the area occupied by card bleeds. check-in: 1a8e4f93c2 user: thomas tags: card_bleed
16:34
The adaptive bleed widths now handle row/column spacings larger than 2* bleed width. In that case, the configured bleed width is used, instead of filling the entire space. check-in: a8feaba094 user: thomas tags: card_bleed
16:32
Implemented adaptive bleed widths. Bleeds on edges facing neighboring cards now use half the image spacing, instead of the full bleed width, preventing overlapping bleeds. check-in: 6d12c8c24a user: thomas tags: card_bleed
2024-02-02
14:41
Use enum.auto() to declare subsequent render layers, instead of hard-coding Z values. check-in: 3d22869c3f user: thomas tags: card_bleed
14:38
Refactored bleed handling: Encapsulate the behavior in the new CardBleedItem class. check-in: b23a1515be user: thomas tags: card_bleed
2024-02-01
16:17
Revert [30b5a1d484e22b], because it looks bad with borderless cards. Sampling closer to the image edge works better with those cards. check-in: 874207484b user: thomas tags: card_bleed
15:57
Implemented updating the card bleed width when the page layout settings change. check-in: 390fdb6719 user: thomas tags: card_bleed
13:08
Sample the 3rd/3rd last pixel row/column in the card images to generate the bleed. This should avoid potential issues with artifacts in the border pixels. check-in: a94ab464d6 user: thomas tags: card_bleed
13:05
Use the transformation matrix to shift the top/left bleeds outside the card image area. check-in: 30b5a1d484 user: thomas tags: card_bleed
12:58
First, working draft implementation. Does not support dynamic resizing and does not honor neighboring images with positive image spacing settings. check-in: af6329d076 user: thomas tags: card_bleed
2024-01-31
12:24
Add a numerical card-bleed-mm setting to the document settings. It allows setting the card bleed width as a non-negative integer in millimeters. check-in: c1cce395e5 user: thomas tags: card_bleed
11:38
Merge with trunk check-in: ea344b143b user: thomas tags: card_bleed
08:39
PageConfigWidget: Reduce code verbosity a bit by putting the ui attribute into method local scopes first. check-in: 1993ff2a31 user: thomas tags: trunk
08:35
Merge with trunk check-in: 8e7951fd4b user: thomas tags: card_bleed
08:28
Merge with trunk. check-in: 7b3df924ef user: thomas tags: duplex_printing
2024-01-30
21:59
Style fixes on the port_pyside6 side. Removed a duplicate test case. Removed the unused CLI paramater in the benchmark script argument parser. State PySide6-Essentials as the build system requirement, instead of the full PySide6 package. check-in: 05e002d8ad user: thomas tags: port_pyside6
21:24
Merge with trunk check-in: 0c89361958 user: thomas tags: first_launch_wizard
21:00
Round 3 of syncing trunk with port_pyside6 branch. This should complete the trunk side. All changes worth importing should be imported by this check-in. check-in: 2e052061de user: thomas tags: trunk
20:42
Merge with trunk check-in: e10dd20e18 user: thomas tags: port_pyside6
19:59
A few further adjustments reducing the diff between trunk and port_pyside6 branches. check-in: bda38e06f4 user: thomas tags: trunk
19:38
Backported changes from the port_pyside6 branch. Notably, usage of Qt enums, which are available in Qt5. And some other formatting adjustments to reduce the diff size. check-in: ebe29d5f33 user: thomas tags: trunk
15:01
Merge with trunk. check-in: afa4188afd user: thomas tags: port_pyside6
14:37
Use a transparent blank image in the ImageDatabase. This improves the rendering with dark application themes. check-in: 8e8346ca98 user: thomas tags: trunk
2024-01-28
11:16
Implement some scaffolding code for card bleeds in CardItem. check-in: 11aae8973b user: thomas tags: card_bleed
11:07
CardItem: Use multiplication to to convert the sharp corner enabled boolean to an opacity value. Also rename the variable in on_page_layout_changed() from "value" to "opacity" check-in: d0b05a7e4d user: thomas tags: card_bleed
2024-01-27
16:10
Release 0.26.1 check-in: ae52fab480 user: thomas tags: trunk, release, v0.26.1
16:05
Update year in copyright notices to 2024. check-in: 3e1a1cd323 user: thomas tags: trunk
15:49
Improve wording in the changelog. check-in: 1c145c1735 user: thomas tags: trunk
10:39
Merge with trunk. check-in: eac83e9c0a user: thomas tags: duplex_printing
10:19
Stabilize the re-flow algorithm used when the page capacity decreases. It no longer re-orders cards within the document. Implements [fae56bc9b847f2c0] check-in: 6770e36952 user: thomas tags: trunk
10:12
Add changelog entry. Closed-Leaf check-in: 7b10386405 user: thomas tags: reflow_pages
09:52
ActionEditDocumentSettings: Name a variable in the reflow algorithm check-in: 0405ff2e2c user: thomas tags: reflow_pages
09:43
ActionNewPage: Extend docstring to clarify behavior. check-in: e2fdbfa803 user: thomas tags: reflow_pages
2024-01-26
18:45
Implement order-stable document reflowing. Remove a broken test. check-in: 53406883bd user: thomas tags: reflow_pages
16:59
Remove tests/test_document.py::test_page_layout_compute_page_card_capacity, which is outdated. A better test for the card capacity computation is in tests/test_page_layout_settings.py. check-in: d0d8c6171d user: thomas tags: reflow_pages
16:48
Merge with trunk check-in: cd10b78ef1 user: thomas tags: reflow_pages
16:24
PageLayoutSettings: Fixed bug in the row/column count computation. Those are now tested and work properly. Fixes [f2f8b5cc6b79f7a6]. check-in: 15abc995ce user: thomas tags: trunk
2024-01-25
09:29
Fix type annotation. check-in: 6aeb3900a7 user: thomas tags: reflow_pages
09:28
ActionEditDocumentSettings: Extracted page type filtering in _reflow_pages_of_type() into a separate method. check-in: 61cbea08b9 user: thomas tags: reflow_pages
2024-01-24
15:25
ActionMoveCard: Complete handling of the target_row parameter in undo(). And fix a wrong value in a test case. check-in: ce351a7727 user: thomas tags: reflow_pages
15:13
WIP: ActionMoveCard gains parameter target_row. It can be used to move cards into the middle of the target page. apply() already supports the new parameter. undo() still needs extension, and tests for undo() currently fail. check-in: c8905bb8bb user: thomas tags: reflow_pages
08:18
ActionMoveCards: Rename parameter target to target_page. check-in: d69b777827 user: thomas tags: reflow_pages
08:14
Merge fork. check-in: e7d5fa0a05 user: thomas tags: reflow_pages
2024-01-21
14:11
Clarify docstring for ActionRemoveCards. Indicate that the index range parameter uses inclusive ends. check-in: faa8f6c769 user: thomas tags: reflow_pages
13:56
Add class BackFace used for SFC back sides. Introduce a common "interface" base class for cards, card faces, and back faces, that defines the required attributes for UI display. check-in: 0097eff371 user: thomas tags: duplex_printing
2024-01-18
16:29
_interface.py: Fix missing TypeVar that wasn't moved correctly in the previous check-in. check-in: 8e7eb174d7 user: thomas tags: reflow_pages
16:24
Move split_iterable() from card_actions.py into _interface.py. check-in: 3ff626ed95 user: thomas tags: reflow_pages
15:18
Simplify loop in ActionEditDocumentSettings._reflow_pages_of_type(). check-in: 2c11bd9bb7 user: thomas tags: reflow_pages
13:01
MeteredSeekableHTTPFile: Remove a warning if read() returns less than the requested amount of bytes. Some readers probe the file by repeated calls to read() to determine if EOF is reached, triggering this multiple times. check-in: 6344b3eda8 user: thomas tags: trunk
12:58
MeteredSeekableHTTPFile: Handle AttributeError when calling file.read(). This may occur, if the app force-closes the read file from another thread during application shutdown. This should prevent infrequent crashes that can occur during exit, while a card data update runs. check-in: 2c8d98956f user: thomas tags: trunk
12:52
CardDatabase: Use SAVEPOINTs in get_all_cards_from_image_cache(), instead of restarting the database transaction at the end of the method. check-in: 48a000a9c7 user: thomas tags: trunk
10:09
Merge with trunk. check-in: aefb139aa6 user: thomas tags: duplex_printing
09:57
Page now internally handles CardContainer creation. ActionAddPage can take a content parameter and create pages filled with cards, to reduce Qt model overhead. check-in: 8a3e12a3d9 user: thomas tags: trunk
09:54
Refactor ActionAddCard to use the new capabilities of ActionAddPage. When cards spill over to newly created pages, the logic now creates pre-populated pages, instead of performing two steps to add empty pages and then fill them. Closed-Leaf check-in: a759a3ed86 user: thomas tags: add_page_with_content
09:52
Broaden type annotations for Page and ActionNewPage. The content parameters are now annotated to accept Iterable[AnyCardType], instead of List[Card]. check-in: cf3fac7975 user: thomas tags: add_page_with_content
2024-01-17
16:38
ActionLoadDocument: Use the new ability of ActionNewPage to directly add pages with cards. check-in: 380990a5b7 user: thomas tags: add_page_with_content
16:25
ActionNewPage: Add "content" parameter, that allows setting the page content for newly created pages. check-in: 5ea6a47e72 user: thomas tags: add_page_with_content
12:05
Extend class Page to internally handle CardContainer creation. check-in: a0a6ee9cca user: thomas tags: add_page_with_content
09:16
Add a TODO. check-in: 3205b2d751 user: thomas tags: duplex_printing
09:12
Began work on supporting Duplex mode in the Document: ActionEditDocumentSettings now inserts/removes pages for the duplex back sides. check-in: 0df6690306 user: thomas tags: duplex_printing
09:09
Fix NameErrors in print.py. check-in: a59fb367f1 user: thomas tags: duplex_printing
08:46
Fix a crash in the application update checker. It occurred, if the connected network requires a login and replaces the expected JSON document with the authentication HTML website. check-in: bcafd0d919 user: thomas tags: trunk
08:26
Deduplicate a type hinting definition in card_list.py. check-in: 3f53393fed user: thomas tags: duplex_printing
2024-01-15
15:47
CardDatabase: Implement a TODO note. check-in: 41e2caf4e5 user: thomas tags: trunk
09:48
Adjust a few type annotations. check-in: c1fc13a580 user: thomas tags: duplex_printing
2024-01-14
23:20
Introduce distinction between Card and CardFace. This is currently a simple alias, but is meant to be eventually split into distinct classes. check-in: 4aa723984f user: thomas tags: duplex_printing
17:11
Remove unused method introduced in recent check-in [49acf0b68b1860bb]. check-in: c0dd364a21 user: thomas tags: trunk
16:42
CardInfoDownloader: Update PrintingDisplayFilter in-place, instead of deleting the complete table content and re-populating it during the import. This saves ~ 15% of the database writes when updating the database with a same-version dump. CPU time usage stays roughly the same, because it replaces 1 B-Tree write with 1 B-Tree read in case of in-place updates. check-in: 49acf0b68b user: thomas tags: trunk
10:58
Fix benchmark script throwing an exception during the card data import. The breakage was merged into trunk in [4e623b8aa41d3341]. Starting with that commit, the importer relies on the PrintingFilters table being filled with the values from the settings, as that task was moved into a separate worker. Thus, the benchmark script has to run the PrintingFilterUpdater before importing the card data. check-in: b1f4b90247 user: thomas tags: trunk
10:40
Fix benchmark script not running by removing the global database semaphore. It also checked the QApplication instance if it should start, which does not work in the context of the benchmark script. check-in: 5ac9e961a1 user: thomas tags: trunk
10:26
Mark the benchmark script as executable. check-in: 291fde8254 user: thomas tags: trunk
2024-01-13
10:35
sqlite_helpers: Rename _read_current_database_schema_version() to _get_target_database_schema_version(). Rename internal variables in check_database_schema_version() to use better, less confusing names. check-in: 4983258f7e user: thomas tags: trunk
00:26
CardDatabase: Add two TODO entries. Edit: On ~ 1000 images, these queries complete in under 5ms each. For now, there is no need to worry about optimizing them. Closed-Leaf check-in: 1004a584d7 user: thomas tags: bogus
00:08
CardDatabase: Add a FIXME for a potential bug in translate_card() when tranlating check cards. check-in: 2c2772182f user: thomas tags: duplex_printing
2024-01-11
16:24
Merge with trunk. check-in: 0537a7ee47 user: thomas tags: duplex_printing
16:23
Fix CardInfoDatabaseImportWorker._insert_card_back_id() using the wrong database connection. It used the logic from before [db560eb766a99124] with a shared database connection. Closed-Leaf check-in: e916aa42c8 user: thomas tags: WIP
15:57
Let errors in _download_from_scryfall() propagate to the calling function, which was originally intended to handle these errors. This causes the correct signals to be emitted at the correct time. check-in: cf16793f7c user: thomas tags: WIP
15:39
Fixed remaining tests. check-in: 2a09d34648 user: thomas tags: WIP
2024-01-10
20:02
ImageDatabase: Fix _fetch_and_set_image() not populating the loaded_images map and images_on_disk set. Additionally, fix a few broken tests. check-in: 52e9aa41b1 user: thomas tags: WIP
18:24
Improve type hinting in tests/test_image_downloader.py. check-in: f4aa76d402 user: thomas tags: WIP
15:32
Fix syntax error that was checked-in by accident. check-in: 2ed4264c02 user: thomas tags: WIP
12:15
Fix a few tests in tests/test_image_downloader.py check-in: bf21ecee95 user: thomas tags: WIP
2024-01-09
17:54
Fix test_unknown_save_version_raises_exception(). check-in: 80aad3ca57 user: thomas tags: WIP
17:50
tests/test_card_info_downloader.py: Fix handling of card layouts in class TestCaseData. check-in: 4b6752113d user: thomas tags: WIP
17:10
Merge with trunk. check-in: 72fb51e5e7 user: thomas tags: WIP
17:05
ActionRemoveCards: Move the static method to_list_of_ranges into the module scope. Update it to perform the input value sorting internally. Adjust the test cases to test the function directly, instead of through ActionRemoveCard.__init__(). Add a few test cases for zero and negative numbers. check-in: 8589dbf049 user: thomas tags: trunk
16:32
Fix a crash in ActionAddCard.as_str(). The action now handles distributing multiple copies across multiple, already existing pages. check-in: 3cdf9d94c4 user: thomas tags: trunk
2024-01-08
16:58
Resolve a merge in tests/ui/test_page_scene.py. check-in: 8aac1255fb user: thomas tags: WIP
2024-01-07
10:14
Fix two test cases in tests/test_card_info_downloader.py. check-in: f2bea666d4 user: thomas tags: WIP
2024-01-06
23:13
Fix a few tests in tests/test_image_downloader.py check-in: 4b4042b955 user: thomas tags: WIP
23:12
Remove unused import check-in: 6e112dc16d user: thomas tags: WIP
22:49
Fix a NameError in the PageConfigWidget class. check-in: 2ff3ccd036 user: thomas tags: WIP
2024-01-05
22:18
Rename JSON sample double_faced_card_without_top_level_oracle_id.json to reversible_card.json check-in: 52317b46c1 user: thomas tags: WIP
22:12
Fix TestCaseData property back_face_id. check-in: 5cb119bb6c user: thomas tags: WIP
22:08
ImageDatabase: Remove the ImageDownloader instance created in __init__(). Add the missing_image_obtained(QModelIndex) signal. Properly handle the missing image signals when obtaining missing images. The ImageDownloader instance created when fetching missing images now properly relays both signals to the Document and UI. check-in: c4d4b43b81 user: thomas tags: WIP
21:53
Fix pytest fixture document_light. check-in: 9b44e8bb0a user: thomas tags: WIP
21:42
Fix syntax errors in tests/test_document_loader.py caused by an invalid merge. check-in: 399c5c90be user: thomas tags: WIP
21:29
Fix tests/test_check_card_rendering.py. check-in: d906409b38 user: thomas tags: WIP
2024-01-03
19:39
Continue fixing tests. check-in: 24a5dd962a user: thomas tags: WIP
19:25
Fix database schema migration script for the 32 to 33 update. The script no longer causes the deletion of rows in tables dependent on the Card table. check-in: c484f8767b user: thomas tags: WIP
2024-01-02
21:36
Merge page_config_widget.ui check-in: 68e5fd04dd user: thomas tags: WIP
21:30
Remove remaining uses of the removed CardSizes enum. check-in: 38c44f8348 user: thomas tags: WIP
2024-01-01
03:20
Potentially complete the merge in card_info_downloader.py. check-in: 21cd8f0421 user: thomas tags: WIP
02:59
Encode UUID format correctness in the type system: Introduce class UUID(str), which ensures that UUIDs have the proper format. check-in: 7afd4afc21 user: thomas tags: trunk
01:54
Fix two broken merges in document.py and document_loader.py check-in: d86179c5b6 user: thomas tags: WIP
2023-12-30
18:11
Large, WIP merge with trunk. This needs post-merge clean-ups. There is still a merge conflict in one UI file, which has to be resolved manually. check-in: bddcd3ab40 user: thomas tags: WIP
2023-12-26
19:19
Fix a bunch of style warnings and remove unused imports. check-in: 5d720d677d user: thomas tags: trunk
15:24
DocumentLoader: Rework signal connections. Use a BlockingQueuedConnection to let the loader runner wait until the document action is applied. With this, finishing the loading is within the scope of the run() method, instead of delaying it after run() finished. check-in: 450fd420f2 user: thomas tags: trunk
15:20
DocumentLoader: Rework signal connections. Use a BlockingQueuedConnection to let the loader runner wait until the document action is applied. With this, finishing the loading is within the scope of the run() method, instead of delaying it after run() finished. check-in: ddef04ff58 user: thomas tags: port_pyside6
2023-12-25
23:20
Merge with trunk. check-in: 96afe6d2bc user: thomas tags: port_pyside6
22:47
Improve task cancel behavior. in quit(), wait for the QThreadPool to finish. This avoids a bunch of Runtime errors related to Qt deleting objects too early. With this, the exit behavior is improved when exiting directly after starting the app, while the system has a really slow internet connection. check-in: c102cd1860 user: thomas tags: trunk
15:56
Replace all instances of QThread with a QRunnable-based approach. This removes all long-running, manually managed QThreads. All asynchronous tasks are now contained in short-lived workers. Remove the stop_thread module, as it is no longer needed. MeteredSeekableHTTPFile now registers itself in an instance list, so that the application exit code can easily access all open connections for termination. check-in: 8c775f8538 user: thomas tags: trunk
15:51
Fix tests. Closed-Leaf check-in: 99d9a66288 user: thomas tags: stop_using_qthread
14:07
ImageDownloader: Restructured image fetching. The three loading steps (from memory, disk, and Scryfall) are now performed sequentially in one location. The call structure is now flat, instead of being nested. check-in: f298233e08 user: thomas tags: stop_using_qthread
10:51
Add a global registry for MeteredSeekableHTTPFile instances. Use it to abort all open file transfers on application exit. check-in: a66afb21e2 user: thomas tags: stop_using_qthread
2023-12-24
23:08
Remove now unused module stop_thread.py together with its unit tests. check-in: d572fb33be user: thomas tags: stop_using_qthread
23:06
WIP replacing the ImageDownloader background thread with QRunnable-based runners. check-in: d88a767958 user: thomas tags: stop_using_qthread
17:29
Fix unit tests. The QThreadpool needs more careful, per-test mocking, as some tests require a working thread pool. check-in: 3a3e161891 user: thomas tags: stop_using_qthread
2023-12-23
22:22
DocumentLoader: Add method cancel() to directly cancel a running loading process. Adjust the tests, as the worker thread no longer exists. check-in: c29c1769ab user: thomas tags: stop_using_qthread
21:57
Unify a few type hinting aliases. Define them in units_and_sizes.py and import them were used, instead of re-defining them in multiple locations. check-in: 4a69ac2c0e user: thomas tags: stop_using_qthread
21:45
Update checker: Directly run check_for_updates(), instead of enqueueing it with a QTimer. It internally enqueues its tasks via the global thread pool, so it doesn't make much sense to delay the execution. check-in: 031cd2fd9d user: thomas tags: stop_using_qthread
18:18
Refactored QRunnable-based classes. Use a custom base class that encapsulates a common instance-tracking and cancelling interface. check-in: ff03dea115 user: thomas tags: stop_using_qthread
17:01
ImageDatabase: Move read_disk_cache_content() into the module scope. Move population of the images_on_disk set into a QRunnable. check-in: 567a58db91 user: thomas tags: stop_using_qthread
11:37
Remove unused definition check-in: f891a36ff7 user: thomas tags: stop_using_qthread
10:25
The GUI now properly unlocks after loading a document finishes. This requires a direct signal connection, because the loader resides in a stopped thread. check-in: 4ce02b60cd user: thomas tags: stop_using_qthread
2023-12-22
21:58
WIP Refactoring of DocumentLoader to use a QRunnable as the background worker. This currently does not properly unlock the UI after finishing the loading process. check-in: 4078f6f41b user: thomas tags: stop_using_qthread
20:58
WIP refactoring of DocumentLoader to use the global QThreadPool, instead of a worker thread. This version still emits warnings "QObject: Cannot create children for a parent that is in a different thread.", and crashes when closing the app while an image download runs in the document loader. check-in: 9002352a71 user: thomas tags: stop_using_qthread
20:36
Refactor the Update checker logic to use two independent QRunner-based update checkers, instead of using a QThread. Both checks now run independently in parallel in the global QThreadPool. check-in: 73e35e69eb user: thomas tags: stop_using_qthread
20:34
Extend the @with_database_write_lock decorator to work with the QApplication instance created by pytestqt. check-in: 2e5cb56075 user: thomas tags: trunk
18:31
decorator @with_database_write_lock now uses @functools.wraps() for the inner function. check-in: 073c360598 user: thomas tags: trunk
18:25
Application: Add boolean should_run, that indicates if tasks should start. Extend decorator @with_database_write_lock to check this boolean. If the app is in the shutdown state, all enqueued database-writing tasks are skipped, instead of being started. check-in: a0be793320 user: thomas tags: trunk
18:14
Add two more logging lines, that log the beginning of the download and import actions. check-in: f5d53461bf user: thomas tags: trunk
11:51
Add button to the Debug settings to import an existing card data file. Implements [8fc0e1bc593fee14]. check-in: 87c5abc3e2 user: thomas tags: trunk
2023-12-21
18:44
Implemented better support for dark mode rendering on Windows. Set the Qt style to 'fusion' on Windows platforms. The fusion style offers a better dark mode palette, which does not look like a Windows 98 high contrast style. check-in: 84ed6281f8 user: thomas tags: port_pyside6
18:38
Fix tests/test_carddb.py. The PrintCountUpdater gained the ability to be used synchronously with a pre-existing database connection. check-in: 19fe902d43 user: thomas tags: trunk
18:22
Merge with trunk. Revert clearing __dict__s in the test suite implemented in [cc5d067f15395d86], as that causes segmentation faults with PySide6. Another memory usage optimization will be needed. check-in: b13cc12f88 user: thomas tags: port_pyside6
2023-12-20
19:59
Properly serialize database write transactions. Fixes [98bf63219f09652f]. check-in: 24a6e830b5 user: thomas tags: trunk
19:53
Update changelog, add entry for the lifted restriction on what can run in parallel. Closed-Leaf check-in: 013c4d4e50 user: thomas tags: serialize_db_writes
19:20
Implemented cancelling PrintingFilterUpdater.run(). With this, the app can be closed without crashing, while the printing filter updater works on the database. In that case, the transaction is rolled back. check-in: 17414d1a7d user: thomas tags: serialize_db_writes
18:56
UI: Allow PDF export, printing, settings access while a card data update runs. No longer disable the actions. check-in: 7e309c3b79 user: thomas tags: serialize_db_writes
18:51
Move the print count updater logic into a separate QRunnable-derived class. With this, the printing and PDF export no longer write to the database synchronously, but rather enqueue a write task. That task is also serialized by the database write semaphore, thus enabling safe operation while a card database update runs. check-in: 8d8a1dc681 user: thomas tags: serialize_db_writes
18:49
Add logging to the with_database_write_lock decorator. check-in: 70e1984524 user: thomas tags: serialize_db_writes
18:48
PrintingFilterUpdater: Resolve deadlock during card data import. The import process uses the PrintingFilterUpdater. So split the QRunnable.run() method, which is guarded by the database write semaphore, and the actual logic. The card data import now uses the updater logic without the write lock, thus avoiding locking the semaphore twice. check-in: c7ded6eaf4 user: thomas tags: serialize_db_writes
18:44
Add logging line to the UpdateChecker BackgroundWorker.db property. check-in: dd6f3fadb9 user: thomas tags: serialize_db_writes
18:43
Tests: Remove an outdated test, that seems to no longer test what the test name suggests. check-in: 60e69c75db user: thomas tags: serialize_db_writes
16:52
PrintingFilterUpdater: Guard the database update with the database write lock. check-in: a866cdf3c2 user: thomas tags: serialize_db_writes
16:44
Rewritten card data downloader to use QRunnable classes for the three tasks implemented (download to file, import from file, import from API). These three use a semaphore to protect the database from simultaneous write access. The card info downloader API class no longer holds a QThread instance. It schedules to run the tasks in the global QThreadPool instead. check-in: 75ad95b357 user: thomas tags: serialize_db_writes
09:06
Remove signal CardInfoDownloader.request_download_to_file. Directly connect the source trigger to the slot method instead. check-in: f36e99647e user: thomas tags: serialize_db_writes
09:02
CardInfoFileDownloadWorker: Update the empirically determined compression ratio. check-in: 5ead60463b user: thomas tags: trunk
08:42
Merge with trunk. check-in: 74088e5e28 user: thomas tags: serialize_db_writes
08:38
CardInfoFileDownloader: Remove worker attribute, as it was never accessed. check-in: 01b16a80c6 user: thomas tags: serialize_db_writes
08:26
Add semaphore and management decorator to carddb.py. check-in: edefbd35fe user: thomas tags: serialize_db_writes
2023-12-19
13:22
Release v0.26.0 check-in: 2c5548a7fe user: thomas tags: trunk, release, v0.26.0
13:16
Tests: Fix imports in tests/ui/test_item_delegate.py being placed in the copyright header. This was done by PyCharm's automatic refactoring tool. check-in: 17b5ab2172 user: thomas tags: trunk
13:07
Clean-up license headers: Put # in empty lines, to hopefully prevent PyCharm from automatically placing imports into the empty lines when performing automated refactoring tasks. check-in: 39ffd648fe user: thomas tags: trunk
10:33
Ensure compatibility with Python 3.8. This fixes the Windows builds. check-in: e09a2ae5fb user: thomas tags: trunk
10:24
Replace itertools.chain with typing.Iterable in type annotations. Closed-Leaf check-in: 04c6d5e72e user: thomas tags: py38_compat
10:19
Tests: Python 3.8 compatibility fix. Replace actual container types in type annotations ('list[str]') with the ones from typing ('List[str]'). check-in: 69dff50b97 user: thomas tags: py38_compat
10:15
Tests: Python 3.8 compatibility fix. Replace type union using '|' with typing.Union[]. check-in: 30c0cbf653 user: thomas tags: py38_compat
10:02
Remove unittest library from cx_Freeze exclusion list. This should fix the standalone builds. check-in: 9637ae021a user: thomas tags: trunk
2023-12-18
21:35
Center the printing area on the paper (See [abdb5df1fec475c0]) and add option to toggle between explicit and implicit margin handling when printing pages. (Potential fix for [b80a3f6992e94b82]) check-in: 7974e6091a user: thomas tags: trunk
21:33
Update changelog. Closed-Leaf check-in: 8c6c9ac5c9 user: thomas tags: explicit_margins
21:20
The borderless printing option now toggles the created QPrinter between explicit and implicit margin handling. check-in: b4a36f02d9 user: thomas tags: explicit_margins
20:57
Add Printer settings section, and option to enable/disable borderless printing. Add a checkbox to the Settings window to toggle the option. check-in: dcc5ab7924 user: thomas tags: explicit_margins
2023-12-17
17:24
Fix PEP8 style warnings. check-in: 038382666b user: thomas tags: explicit_margins
15:33
Updated changelog. check-in: fd41a9c553 user: thomas tags: explicit_margins
14:46
Add unit tests for image location computation. Fix card image placement. The spacing parameters were swapped (column spacing used for rows and vice versa). It now also handles excessive margins properly. check-in: ee39bca628 user: thomas tags: explicit_margins
2023-12-15
12:27
Extended changelog. check-in: 024bbab202 user: thomas tags: explicit_margins
12:07
Refactored QPrinter creation. Values are now set via a QPageLayout instance. The QPageLayout instance creation is done by the PageLayoutSettings class, which holds all required information. Additionally, an error message is logged, if setting the page layout in the QPrinter instance fails. check-in: 7fef93718b user: thomas tags: explicit_margins
12:02
Fix invalid values in tests/ui/test_page_config_widget.py, that were invalidated by the change in the default page margins. check-in: 3199f3657b user: thomas tags: explicit_margins
11:18
Tests: Refactored test_page_layout_settings.py. Tests no longer use the heavy "document" fixture just to access the page layout within. Instead, a dedicated fixture returning a page layout instance is used. check-in: f5572164e5 user: thomas tags: explicit_margins
2023-12-14
15:49
Fix test case for test_page_layout_compute_page_card_capacity(), which was broken after reducing the default margins to 5mm. check-in: 431b84a712 user: thomas tags: explicit_margins
13:01
Fixed error in test_vertical_cut_line_locations_when_enabled(), which caused unexpected test failures. All tests now pass check-in: 88b8bbe175 user: thomas tags: explicit_margins
12:51
Improved location computation for horizontal cut line locations. All cases for test_horizontal_cut_line_locations_when_enabled() now pass. check-in: 60d4d8ebf6 user: thomas tags: explicit_margins
12:07
Fix cut marker positioning with implicit margins for normal margin sizes. This currently does not handle huge margins that cause the rendering area to shift. check-in: 66c5aba431 user: thomas tags: explicit_margins
00:19
Tests: Decomposed test cases for cut markers in the PageScene class. Test function test_cut_line_locations_when_enabled() split into multiple, independent tests: Horizontal line positions, vertical line positions, type correctness of the cut_lines property, bounding box sizes for cut lines. check-in: a7278b5483 user: thomas tags: explicit_margins
00:15
Remove unused import check-in: 78ce000228 user: thomas tags: explicit_margins
2023-12-13
23:21
Fixed broken settings migration code, introduced into trunk in [251b2a3abd362e4c]. check-in: c370cf7bfd user: thomas tags: explicit_margins
12:56
Fix default suggested file name when exporting a loaded document as a PDF. Fixes [3843fbfeb04ccb37]. The logic now strips the file extension to be implicitly replaced by ".pdf". If the file name stem includes a dot, explicitly add ".pdf". check-in: e081be8036 user: thomas tags: trunk
11:53
Set the default document margins to 5mm in all directions. Add changelog entry for this and for centered printing support. check-in: 2e054b2af9 user: thomas tags: explicit_margins
11:46
Implemented centered printing. The 3x3/2x2 printing area is now centered on the page. Implements [abdb5df1fec475c0]. check-in: daecb5dbe4 user: thomas tags: explicit_margins
11:36
Fix tests for cut line locations. Closed-Leaf check-in: 400a1e51d6 user: thomas tags: center_printings
2023-12-07
15:32
Center cut line locations. check-in: b375e42404 user: thomas tags: center_printings
2023-12-03
15:36
Merge with trunk. check-in: d57ceec85d user: thomas tags: center_printings
15:33
Rename image spacing document settings to be easier understandable. Implements [6ca7a559951e0117]. Fix crash when loading documents with numerical document titles. check-in: 251b2a3abd user: thomas tags: trunk
15:26
Add changelog entry for the settings rename. Closed-Leaf check-in: 37dd04c0d7 user: thomas tags: rename_spacing_settings
15:18
Moved save file database migration code to document_loader.py. The document loader now uses the migration code to migrate save files to the latest version, before accessing the data. This removes the need for different code paths based on the save file version at hand. Fix a crash when loading a document with a pure numerical document title, e.g. "1", as that was coerced to an integer type. Handle migrating the image spacing settings stored in old documents to use the new names. With this, the refactoring is complete. check-in: 8d0effd9bd user: thomas tags: rename_spacing_settings
12:50
Rename spacing-related attributes in the PageLayoutSettings class. check-in: 8ac638b637 user: thomas tags: rename_spacing_settings
11:56
Renamed widgets in the PageConfigWidget to reflect the image spacing rename. Also updated the UI strings and tooltips. check-in: 8ae2a07ae2 user: thomas tags: rename_spacing_settings
11:31
Renamed document settings for image spacing. Added migration code for the application settings file. Renamed "image-spacing-horizontal-mm" to "row-spacing-mm". Renamed "image-spacing-vertical-mm" to "column-spacing-mm". check-in: da304840e1 user: thomas tags: rename_spacing_settings
2023-12-01
09:29
Fix requirements. Bump PySide6 to 6.5 everywhere check-in: 5a879e136a user: thomas tags: port_pyside6
2023-11-30
12:56
PageScene: Changed _compute_position_for_image() to center images on the page. check-in: c67358bd4d user: thomas tags: center_printings
2023-11-29
11:09
Implement explicit margin handling in the printing code. When IMPLICIT_MARGINS is enabled in the PageScene, it reduces the rendering area to the center, removing the margins. check-in: 989df585fd user: thomas tags: explicit_margins
2023-11-23
15:06
Merge with trunk check-in: a160004cce user: thomas tags: explicit_margins
2023-11-22
13:53
Reduce memory usage of the test suite, by clearing object's __dict__ in pytest fixture teardown code. This reduces memory usage to about 40%-50% of the previous level. I.e. 2GiB -> 900MiB check-in: fba7cca802 user: thomas tags: trunk
13:45
Clear objects yielded by pytest fixtures. Simply call clear() on the __dict__ attribute, which causes the garbage collector to delete the object contents. This frees memory held by those, instead of holding it until pytest completes. Closed-Leaf check-in: cc5d067f15 user: thomas tags: optimize_test_memory_usage
13:43
ImageDatabase: Do not connect the worker thread "finished" signal to a lambda. Instead, use a method, so that the connection can be broken in test teardown code. check-in: 449f62d140 user: thomas tags: optimize_test_memory_usage
13:40
test_page_scene: Explicitly list the RenderMode values. check-in: 05ba99c50c user: thomas tags: optimize_test_memory_usage
12:22
test_check_card_rendering.py no longer uses the ImageDatabase fixture for the blank image. The tests now use a minimal fixture that only provides that pixmap. check-in: f27eb56017 user: thomas tags: optimize_test_memory_usage
11:04
Fix style issues in test_page_scene.py check-in: 4565b0c2f1 user: thomas tags: explicit_margins
09:02
Convert RenderMode enum into a Flag enum. Add value IMPLICIT_MARGINS to it. Preparations for [b80a3f6992e94b82]. check-in: d4ca6e52e5 user: thomas tags: explicit_margins
2023-11-16
15:50
Remove hard-coded program name in setup_cx_freeze.py check-in: 7aa8a6ec7a user: thomas tags: trunk
15:24
Move PageScene and direct dependencies from page_renderer.py into a new module page_scene.py. check-in: 72abb3e08f user: thomas tags: trunk
12:23
Fix imports in printing_filter_updater.py check-in: fd7dbb696c user: thomas tags: trunk
11:48
Merge with trunk. check-in: 7645c25ca4 user: thomas tags: port_pyside6
10:25
Add card filters for extended art cards and cards banned in Oathbreaker. Refactored the use of card data samples in most tests: Instead of hard-coding the card data, duplicating the JSON values, load them from the JSON instead. Updated most JSON samples to a newer version, to reflect changes in the data format done by Scryfall in the test data. check-in: b380dde951 user: thomas tags: trunk
10:23
Add card filter for extended art cards. Implements [cfd07193956f93c5]. Closed-Leaf check-in: f6e1fd46f9 user: thomas tags: update_card_import_tests
2023-11-15
11:44
Add card filter for cards banned in Oathbreaker. Implements [67c671e2f8e5695b]. check-in: 0b6cb088ce user: thomas tags: update_card_import_tests
08:12
Fix remaining failing tests in tests/ui/test_deck_import_wizard.py. check-in: 82993ec1ac user: thomas tags: update_card_import_tests
2023-11-14
18:24
Removed hard-coded card data from tests/test_carddb.py. Updated most of the JSON test data to the newest versions each. check-in: c46eb9dd9c user: thomas tags: update_card_import_tests
2023-11-13
18:43
Whitespace changes in the database schema. Replace tabs with spaces. check-in: 6a1a304870 user: thomas tags: update_card_import_tests
18:43
Add test cases validating the set release date update logic. check-in: f5f684dded user: thomas tags: update_card_import_tests
18:23
CardInfoDatabaseImportWorker: Fix wrong number of SQL binding in _insert_card_faces(). The UPDATE branch was not working correctly. check-in: 4fe4fa9992 user: thomas tags: update_card_import_tests
17:58
Fixed broken card filter for reversible cards. The test looked for the wrong card layout, thus failed to identify the cards it should match. check-in: 79101e733e user: thomas tags: update_card_import_tests
17:52
Refactor tests/test_card_info_downloader.py. No longer hard-code values from the card data JSON samples. The TestCaseData class now loads the required elements directly from the JSON. This makes it easier to extend and update the underlying JSON samples. Also merge a few individual tests into a single parametrized test. check-in: 2c3cdb9a2c user: thomas tags: update_card_import_tests
17:49
Merge the card data json type hinting classes into CardDataType. The static checker seems to not support merging it from multiple TypedDicts via multiple inheritance. check-in: 2eaa7bae00 user: thomas tags: update_card_import_tests
12:56
Update the card data type annotations to cover the entire dataset as specified by the Scryfall API documentation. check-in: c0183e4f5d user: thomas tags: update_card_import_tests
2023-11-12
13:08
Extract the printing filter update logic from the CardDatabase class into a separate class. The new PrintingFilterUpdater is derived from QRunnable and thus allows running the update in a separate thread. The updater now runs asynchronously during app startup, if the filters were edited in the configuration file, and when the user edits the filter in the settings window. This removes several hacks, like monkey-patching the card database during the card import, calling QApplication.processEvents() in the Settings window, and improves app startup time. check-in: 4e623b8aa4 user: thomas tags: trunk
13:04
Do not run the PrintingFilterUpdater synchronously in CardDatabase.__init__(). Instead run it in a separate thread once the event loop runs. This improves app startup time when the printing filters need update due to an edited configuration file. Closed-Leaf check-in: 6d38fcafe2 user: thomas tags: split_carddb
10:29
PrintingFilterUpdater: Improve __init__ docstring. check-in: ba04676552 user: thomas tags: split_carddb
10:24
PrintingFilterUpdater.run(): Fix another location checking if the db connection was passed in via __init__ parameter check-in: 400e3cfb0d user: thomas tags: split_carddb
10:07
PrintingFilterUpdater: Fixed database connection closure in run(). Refactor logic to determine if an explicit database connection was passed in, so that it is more robust under testing. check-in: 4e39894561 user: thomas tags: split_carddb
10:06
Document: Fixed transaction management in store_image_usage(). This now takes into account that there is an always-active read transaction in the main card database instance. check-in: bceff4fd62 user: thomas tags: split_carddb
2023-11-11
17:44
ImageDB: Remove duplicate download_finished signal emit. check-in: 8805bed438 user: thomas tags: trunk
17:40
Fix crash when loading multiple documents in a row. The database used by the documment loader has to be closed in between, because it is locked to the current thread and multiple loads use different threads. check-in: 084b89f6c7 user: thomas tags: trunk
17:37
Fix exception when loading a document. check-in: 511273ac7b user: thomas tags: trunk
17:31
WIP move PrintingFilterUpdater to a separate module. Some tests still need fixing. check-in: 56e0bfacdf user: thomas tags: split_carddb
16:37
Moved the logic updating the printing filters into a separate class PrintingFilterUpdater(QRunnable). The CardDatabase and the card data updater use it synchronously. The settings window starts it asynchronously, if the user updated the printing filters. With this, the settings window no longer runs the update in the main UI thread and also no longer has to call processEvents() check-in: f54e9dabc4 user: thomas tags: split_carddb
13:24
Rephrased recent changelog entries. check-in: da0e253488 user: thomas tags: trunk
2023-11-09
16:16
Sync with trunk. check-in: 3ae260764d user: thomas tags: port_pyside6
16:02
Optimize card database imports by splitting complex queries into smaller ones that only do the minimum require work. This also reduces disk I/O by avoiding unneccessary overwrites. check-in: 6fe008de32 user: thomas tags: trunk
15:27
Optimize _insert_card_faces(). Split the complex INSERT … ON CONFLICT DO UPDATE … query into 3 lighter queries, to only do work if actually required. This saves a few seconds. Closed-Leaf check-in: 7cbd69a350 user: thomas tags: optimize_import
12:42
Cache _insert_face_name(), as the cache can have roughly 150k hits during the import. Also refactor the LRU cache cleaning. It now automatically discovers present caches by iterating the __dict__ attribute. check-in: e9008abbc3 user: thomas tags: optimize_import
10:31
Fix branch in _parse_single_printing(). The set id may be zero, so actually check if it is None, instead of the truthyness. check-in: 59b8890b0f user: thomas tags: optimize_import
2023-11-08
19:35
Highly experimental split of the card data import logic. It works, but seems to be slower. Tests need fixing. Split reading and parsing of the JSON input stream into separate classes that run asynchronously as QRunnable instances in the global thread pool. The import loop in the database importer is now split into a 3 segments, pre-processing, post-processing and parsing a single printing. The data input and database importer are connected via queued Qt connections. The semaphore used ensures that the fast JSON parser does not accumulate too many card objects in the queue. Closed-Leaf check-in: 5434587deb user: thomas tags: optimize_import
15:00
Increase card data queue size to 2 elements. check-in: 128760fe00 user: thomas tags: optimize_import
14:39
Whitespace change check-in: 1185a7994c user: thomas tags: optimize_import
14:32
Move reading card data from a file on disk into a specialized worker class derived from QRunnable. check-in: 27e2202871 user: thomas tags: optimize_import
12:49
Convert the card data to file downloader to the QRunnable interface and run it in the global Qt thread pool. check-in: e3524e4323 user: thomas tags: optimize_import
2023-11-06
22:49
Further re-structured _insert_printing() and renamed it to _handle_printing(). Checking for printing presence and update need is extracted into the new _is_printing_present() method. check-in: 84d0300c59 user: thomas tags: optimize_import
22:15
First pass of optimizing _insert_printing(). Instead of doing a complex INSERT ON CONFLICT DO UPDATE query, query if the printing exists and needs updating in Python code, then only run a simple insert or update. This seems to save quite a few seconds on initial import and still a bit on database updates. check-in: 6cb1e9c6c7 user: thomas tags: optimize_import
21:21
CardInfoDatabaseImportWorker: Remove a dead branch from _populate_database() and correct the number of post-processing steps to fix progress reporting on that. check-in: feb9c40d84 user: thomas tags: trunk
15:50
Card data downloader: Move all static methods from CardInfoDatabaseImportWorker into the module scope. check-in: f54117d85d user: thomas tags: trunk
14:24
Fix test for the AddCardWidget. check-in: 5b46f2620c user: thomas tags: port_pyside6
11:37
Add comment to Application.__init__ on a corner case in the style override handling. Closed-Leaf check-in: 678d60bbae user: thomas tags: pyside6_dark_mode
11:35
Bump PySide6 requirement to 6.5, which improves dark mode handling. check-in: 2ccf726df1 user: thomas tags: pyside6_dark_mode
09:23
Update dependency on Pint, which dropped Py 3.8/Win7 support in 0.22. So use 0.21 on Windows. Fixes [f27f9d80a693ddd6] check-in: c90b441231 user: thomas tags: trunk
2023-11-05
22:22
Merge with trunk check-in: f3bebdc3f7 user: thomas tags: port_pyside6
16:09
PEP8 check-in: 8e0212cfd4 user: thomas tags: trunk
15:35
Do not block the cache cleanup wizard during the card data update process, as it can run concurrently without causing exceptions. check-in: 1b4d43a57c user: thomas tags: trunk
14:16
Extended wording in the changelog. check-in: 0db0485a1d user: thomas tags: trunk
14:00
Fix link in the changelog. check-in: b85c2acf6c user: thomas tags: trunk
13:53
Optimize batch card insertion logic, like deck list importer and document loader. These now avoid O(n²) searches for empty pages to insert cards on, and also avoid unnecessary updates to the PageScene. check-in: ade591bf27 user: thomas tags: trunk
13:44
Add changelog entry. Closed-Leaf check-in: 1c57962bf0 user: thomas tags: optimize_adding_multiple_cards
13:41
PageScene: Deduplicate a computation. check-in: 642c1fe2cf user: thomas tags: optimize_adding_multiple_cards
13:27
PageScene: Fix on_rows_inserted() and on_rows_removed(). Now, it only updates the page number text element, if a page is inserted/deleted. check-in: ecc4599efa user: thomas tags: optimize_adding_multiple_cards
13:19
Optimize applying ActionImportDeckList. It now caches the last page operated on, so that the ActionNewCard instances used internally no longer have to scan the document for free spots. This reduces runtime from O(n²) to O(n). check-in: 4fd1e87482 user: thomas tags: optimize_adding_multiple_cards
13:15
Fix ActionAddCard.apply() when using the target_page argument. check-in: 3ec2230d6f user: thomas tags: optimize_adding_multiple_cards
13:13
Fix test test_allow_updating_card_data_on_stale_populated_database_returns_true check-in: 48fc0fc354 user: thomas tags: optimize_adding_multiple_cards
12:07
ActionAddCard: Attribute first_added_page is now None by default. Cleaned up conditionals in as_str(). check-in: 4dd6e1960c user: thomas tags: optimize_adding_multiple_cards
10:54
Optimize adding cards to the document during the document loading process. check-in: 6c4ad8a133 user: thomas tags: optimize_adding_multiple_cards
10:45
Add keyword argument target_page to ActionAddCard. With this, the class gains the ability start searching for a page to add the given cards on at any arbitrary index. check-in: 5e4e511cd1 user: thomas tags: optimize_adding_multiple_cards
09:47
Fix typo in a tooltip in the settings window. check-in: 99ac2f025a user: thomas tags: trunk
2023-11-04
23:44
Fixed flakiness of CardDatabase.allow_updating_card_data() between 00:00 and 01:00. Fixes [1b9dbcaaef4cb716]. check-in: ae281e5e27 user: thomas tags: trunk
10:20
Use one database connection per accessing thread. Improve transaction management. All database writes are now wrapped in IMMEDIATE transactions and committed early. The main, read-only transaction is rolled back and restarted when the card data update completes. Do not lock most of the UI during a card data update. Only lock functions that write to the database. Implements [c6284a8182ae1917]. check-in: db560eb766 user: thomas tags: trunk
10:07
Improve progress bar hiding: Only the inner progress bar retains it's size when hidden. An in-progress, stand-alone card image download now uses the entire available space, as it was before merging [67dd6c8fc490ed1c]. Closed-Leaf check-in: 3dabf8673b user: thomas tags: per_thread_db_connections
09:32
Add changelog entry check-in: 3804508d92 user: thomas tags: per_thread_db_connections
2023-11-02
15:48
Fix tests check-in: dd19d643c8 user: thomas tags: per_thread_db_connections
13:14
Keep everything not writing to the database enabled during card data downloads. This allows continuing work on a document, while the card data updates. Everything writing to the database remains disabled. check-in: 7f00db0711 user: thomas tags: per_thread_db_connections
12:56
Add third progress bar for asynchronous card data updates. check-in: 553dd12f48 user: thomas tags: per_thread_db_connections
2023-10-31
11:28
Merge with trunk. check-in: a2efb93a32 user: thomas tags: per_thread_db_connections
11:13
Implement progress reporting for document loading and deck list imports. Both tasks now show a general progress bar, in addition to one for individual card image downloads. check-in: 67dd6c8fc4 user: thomas tags: trunk
11:10
Fix tests for MainWindow. Closed-Leaf check-in: ece2d2495f user: thomas tags: tiered_progress_bars
10:51
ImageDatabase: Reduced image progress display text verbosity. check-in: e96120e33f user: thomas tags: tiered_progress_bars
10:33
Add changelog entry. check-in: 80c2bb26ef user: thomas tags: tiered_progress_bars
10:24
MainWindow: Fixed wrong Qt signal connection. check-in: 05fa0469d6 user: thomas tags: tiered_progress_bars
10:24
ImageDatabase: Improved logging by stating the batch operation item count in messages. check-in: d31a809723 user: thomas tags: tiered_progress_bars
10:06
DocumentLoader: Remove testing code. check-in: 6ec1f731be user: thomas tags: tiered_progress_bars
10:06
ProgressBar: Do not reset the progress label texts when hiding a progress bar. This avoids re-sizing another shown progress bar. check-in: a29ac5fbc1 user: thomas tags: tiered_progress_bars
10:02
Increase timeouts in stop_thread(). This should avoid most crashes occurring when cancelling image downloads. check-in: db1396e4df user: thomas tags: tiered_progress_bars
09:41
Fixed potential crash when cancelling the document loading. It was only possible to trigger this by quitting the application immediately after triggering the loading action. check-in: 1fd7c67c84 user: thomas tags: tiered_progress_bars
2023-10-30
09:03
Improved handling of showing/hiding inner progress bars. The outer no longer automatically fills the entire space, reducing the jumpyness check-in: 58d086ee57 user: thomas tags: tiered_progress_bars
2023-10-27
16:03
WIP 2-tiered progress reporting. Wrorks for deck loading. Doesn't render properly for deck list imports. check-in: acc4ff9b1d user: thomas tags: tiered_progress_bars
14:52
Encapsulate the progress reporting for long-running processes in the ProgressBar class, instead of using individual widgets in the status bar. The ProgressBar class offers two progress bars, so that layered progress reporting becomes possible. check-in: 0dfc729eb5 user: thomas tags: tiered_progress_bars
2023-10-26
11:23
Mark scripts/compile_ui_files.py as executable check-in: 3a330b3540 user: thomas tags: trunk
11:08
MainWindow: Split list of items to disable during long-running processes into two lists: One to disable while a card data update runs, and one to disable during document loading and deck list imports. check-in: cef17115bf user: thomas tags: per_thread_db_connections
2023-10-25
11:15
Fix relevant typo in a comment. check-in: 9b93a6c1f8 user: thomas tags: per_thread_db_connections
11:01
CardDatabase: Rename signal card_filter_updated to card_data_updated. It is now emitted whenever the card data changes significantly. Remove unused parameter in store_current_printing_filters() check-in: fc5fac1220 user: thomas tags: per_thread_db_connections
08:11
CardDatabase: Remove internal transaction and emitting UI update signal from store_current_printing_filters(). Instead, return the boolean indicating if the UI should be updated. This cleans up the control flow. The method now depends on external transaction management, which is already in place in the card data downloader. __init__() and the settings window now explicitly create transactions when card filters are updated. check-in: d9ea17635d user: thomas tags: per_thread_db_connections
07:11
CardDatabase class no longer uses delegateto to delegate commit() and rollback() to the internal database connection. check-in: f42a5b42dd user: thomas tags: per_thread_db_connections
2023-10-18
10:28
Reworded text in MainWindow.ask_user_about_empty_database(), which still implied that the card filters worked by filtering the download stream, as it suggested that the user may want to configure the filters before downloading the card data. It now states that only printing custom cards is possible without the data present. check-in: b48a3f127f user: thomas tags: trunk
07:42
Add fetching cube lists from cubecobra.com. check-in: 5cd2fa27aa user: thomas tags: trunk
07:23
Reworded automatic image selection UI texts in the cache cleanup wizard. check-in: a14ac04af9 user: thomas tags: trunk
2023-10-15
09:23
Remove the temporary table in get_all_cards_from_image_cache() by rolling back the transaction, instead of dropping the table. This is beneficial, as it ends the transaction, which at that point is elevated to a write transaction. check-in: a214e50a77 user: thomas tags: per_thread_db_connections
2023-10-14
16:29
Improve performance of CardDatabase.get_all_cards_from_image_cache(). This improves the inconsistent performance of the cache cleanup wizard. On the developer PC, with ~250 images, runtime drops from ~8s to ~400ms. check-in: 246fbbb9b5 user: thomas tags: per_thread_db_connections
16:24
Fix a type warning in document.py check-in: 979b51fcc6 user: thomas tags: per_thread_db_connections
16:23
Register sqlite type conversion adapters for Path instances. check-in: fa5f92cb4b user: thomas tags: per_thread_db_connections
13:48
Fix tests check-in: d677b9d3e5 user: thomas tags: per_thread_db_connections
13:29
The Card data importer now has it's own database connection. check-in: c824b35aaa user: thomas tags: per_thread_db_connections
13:18
UpdateChecker: Open the database connection when first accessed, instead of when the thread it runs in starts. This is better for testing. check-in: 8839aee8da user: thomas tags: per_thread_db_connections
13:17
Switch database journaling mode to WAL mode. check-in: dfa2c22e34 user: thomas tags: per_thread_db_connections
09:21
The UpdateChecker now creates it's own connection to the card database file. Moved a method from the CardDatabase to the UpdateChecker, which was only used there. check-in: 4cedc3eca1 user: thomas tags: per_thread_db_connections
2023-10-12
12:56
Refactored MeteredSeekableHTTPFile and ported unit tests from another project. check-in: 151ebc5256 user: thomas tags: trunk
12:51
Catch exceptions when downloading a deck list fails. Show an error message in that case. Fixes [03b31f107d695544]. check-in: b76e4a71b9 user: thomas tags: trunk
2023-10-11
18:41
Fixed tests. The set code parsers operate on sets, which are not order-preserving. Thus use contains_inanyorder in tests, instead of contains_exactly. check-in: 10c380fdf2 user: thomas tags: trunk
18:38
Fixed processing the cached is_hidden columns when changing the set code filter. Also, the cached data update is no longer run at each start. With that, application startup time is back to normal. check-in: e57bf433d6 user: thomas tags: trunk
17:44
Add set-code based card filter. It is now possible to hide specific MTG sets, by entering their set codes in the set code blacklist in the settings. Implements [627376982eb8d8c4]. check-in: 99ca97f285 user: thomas tags: trunk
17:40
Clarified wording in the changelog entry. Closed-Leaf check-in: e93c19edd5 user: thomas tags: set_filter
17:31
Add changelog entry. check-in: b3a7132c0a user: thomas tags: set_filter
17:24
Implemented set code filtering. check-in: 821a3364f4 user: thomas tags: set_filter
09:34
Implemented high-level test cases for the set filter logic. Those currently fail, because the actual logic is not yet implemented. check-in: c3dcf7df49 user: thomas tags: set_filter
2023-10-10
16:24
Implemented function to parse the raw set filter setting into a sorted and deduplicated list of uppercase set codes. check-in: 0300adc112 user: thomas tags: set_filter
15:53
Implemented storing/loading the set filters in the application settings. check-in: 631c8bfc6d user: thomas tags: set_filter
15:20
SettingsWindow: Renamed methods _save_downloads_settings and _load_download_settings to _save_card_filter_settings and _load_card_filter_settings. The names still reflected legacy behavior and were no longer accurate. check-in: 4e4c0a1879 user: thomas tags: set_filter
14:44
Settings window: Add plain text editor that will contain the set codes for the set code filter. check-in: 59728e4cef user: thomas tags: set_filter
14:43
Settings window: Reordered the general printing filters to be rectangular and save vertical space in the settings window. check-in: d910abaf5b user: thomas tags: set_filter
14:08
Fix crash when updating the text element colors in the PageScene when a system theme change event occurs. Fixes [495c2d51e63f53e8]. check-in: 7270b90f7e user: thomas tags: trunk
2023-08-25
10:43
Restore compatibility with Python 3.8 Closed-Leaf check-in: cbd9eb4843 user: thomas tags: unit_tests
10:36
Actually add tests for main() check-in: b93103bc3b user: thomas tags: unit_tests
10:35
Add tests for main(). check-in: a2ced4438b user: thomas tags: unit_tests
10:01
Add tests for the argument parser. check-in: 33b419c29f user: thomas tags: unit_tests
08:28
Add tests for natsort.py check-in: 263be804c3 user: thomas tags: unit_tests
08:28
Add tests for stop_thread.py. check-in: 2a5298ee6b user: thomas tags: unit_tests
08:26
Refactored MeteredSeekableHTTPFile. Add tests for it with 100% statement coverage. check-in: 759769c387 user: thomas tags: unit_tests
2023-08-16
18:36
WIP implementation for a aetherhub.com deck list downloader. The downloader works and is tested, but the UI integration does not yet work. check-in: 910d02ab7c user: thomas tags: additional_deck_list_websites
13:59
Implement direct downloads from cubecobra.com. check-in: 69c4014d93 user: thomas tags: additional_deck_list_websites
13:09
Switch default virtual environment name to "venv-PySide6". This makes it easier to work on the PySide6 port, because PyQt5 and PySide6 have to be in separate virtual environments to not break stuff within PyCharm. Now, the scripts like run_tests.sh work directly with the PySide6 port. check-in: 2f155aff35 user: thomas tags: port_pyside6
13:00
Merge with trunk. check-in: e0e3b5e1bd user: thomas tags: port_pyside6
2023-07-21
11:41
Release v0.25.0 check-in: ce676a04be user: thomas tags: trunk, release, v0.25.0
11:28
Fix test_document.py on Windows. Delete the database connection to a temporary file to lift a file lock before the parent directory is cleaned up. Without this, the tests raise a PermissionError on Windows. check-in: 8180c71418 user: thomas tags: trunk
11:18
Do not use typing.Union instances in isinstance() calls for Python 3.8 compatibility check-in: b779d05b95 user: thomas tags: trunk
11:05
Application: rename run_startup_tasks to enqueue_startup_tasks, because it enqueues the tasks for later execution. Also log the icon theme name used, if the system theme is in use. check-in: b3287e52ef user: thomas tags: trunk
2023-07-20
14:04
Fix card removal, if cards are selected from bottom to top. Reason for failure is that groups in Qt multi-selections are not ordered by start, but rather selection timestamp. This broke the range merging algorithm in the ActionRemoveCards class. Fixes [9098350c2b88c42c]. check-in: cde1f5a44a user: thomas tags: trunk
2023-07-19
21:20
Merge with port_pyside6. check-in: 1d97c54cd7 user: thomas tags: pyside6_dark_mode
2023-07-18
17:32
Cleanup usage of Qt enums. check-in: b8fc3d12cf user: thomas tags: port_pyside6
17:18
Merge with trunk check-in: 3419adfd46 user: thomas tags: port_pyside6
16:54
PageScene: Reduce text font size from 50 to 40, as 50 is quite large. May need further tweaking. check-in: a29d18b3e9 user: thomas tags: trunk
16:52
Reworded a changelog entry. check-in: 46d6b695c6 user: thomas tags: trunk
2023-07-15
18:08
CardDatabase: Order by highres_image column in get_cards_from_data(). This improves print guessing card selection during spoiler season to not use the newest spoiled printing with lowres images over better printings with high-res images. check-in: 39af3d8897 user: thomas tags: trunk
2023-07-14
11:40
Added two new document settings: Adding a document name that is printed on each sheet and an option to enable printing a running page number on each sheet. Both options help organizing stacks of printed and uncut sheets. check-in: b7fcbc4eca user: thomas tags: trunk
2023-07-13
19:03
SettingsWindow: Update tooltip for the main window layout combo box. check-in: 87a740779b user: thomas tags: trunk
16:50
Added keyboard shortcuts for the Undo and Redo actions. check-in: 44789d5db1 user: thomas tags: trunk
16:34
Tests: Verify that DocumentLoader._read_document_settings_version_4_5() is not order-dependant. Closed-Leaf check-in: 0b857df656 user: thomas tags: document_name_setting
16:02
fix linter warning. check-in: 0a9e20d40f user: thomas tags: document_name_setting
15:59
DocumentLoader: Fix type conversion for booleans in _read_document_settings_version_4_5(). All expected boolean values are now an instance of bool. check-in: 00dd6ac1b2 user: thomas tags: document_name_setting
14:55
Added changelog entry. Completes [7e2d18f1d6fc24ce] check-in: d396bc3441 user: thomas tags: document_name_setting
14:40
Render document name and page numbers when loading a document via command line parameter check-in: a258e9f70a user: thomas tags: document_name_setting
14:34
Removed a debug logging line check-in: ad61a5f0e3 user: thomas tags: document_name_setting
14:33
Settings: Fix documents section validation. It now properly handles the default-document-name setting with a str value. check-in: 3312762725 user: thomas tags: document_name_setting
14:27
Fixed validation in DocumentLoader._read_document_settings_version_4_5(). Added multiple logging lines at debug level. check-in: e65b2f55c2 user: thomas tags: document_name_setting
13:29
Refactored DocumentLoader._read_document_settings_version_4_5(). It now dynamically replaces settings defined in the PageLayoutSettings that are not stored in the database with the default values. The implementation is now independent of the attributes defined in the PageLayoutSettings and supports attribute addition/deletion without further modification. check-in: 90891385d3 user: thomas tags: document_name_setting
11:02
Properly update the page number text when inserting/deleting pages. check-in: 4032432d71 user: thomas tags: document_name_setting
10:51
Implemented a basic line wrap for the document name. It will split the document name at word boundaries so that the text stays within the visible area. The current implementation breaks on really long words that are longer than the page width. In those cases, the "word" will be placed on it's own line and the end is cut off. check-in: 3a74dcc436 user: thomas tags: document_name_setting
10:19
Implemented proper right-adjust for the page number text. check-in: f27a61ce46 user: thomas tags: document_name_setting
2023-07-12
18:02
Implemented basic rendering for the document title and page numbers. check-in: 9ba2013523 user: thomas tags: document_name_setting
2023-07-11
18:16
PageScene: Add property text_items, returning all QGraphicsTextItem instances. Add get_text_color(), returning the text color to use. check-in: 9dfdbb5795 user: thomas tags: document_name_setting
17:57
Adjust tests for the new fields. check-in: 2cc3213d50 user: thomas tags: document_name_setting
17:47
PageConfigWidget: Handle settings with textual values in load_from_page_layout(). check-in: e0ade6b194 user: thomas tags: document_name_setting
17:46
Document: Add logging line at end of __init__() check-in: fb08ec84c9 user: thomas tags: document_name_setting
17:45
Fixed wrong settings name in PageLayoutSettings.create_from_settings(), causing crashes when opening the DocumentSettingsDialog. check-in: c263ffd4ea user: thomas tags: document_name_setting
17:32
Fix argument order in PageLayoutSettings.create_from_settings() check-in: c6995232cf user: thomas tags: document_name_setting
17:28
Merge with trunk, pulling a fix for a crash affecting the DocumentSettingsDialog. check-in: 923ef627b6 user: thomas tags: document_name_setting
17:09
Fixed off-by-one error in CardListModel._request_replacement_card(). check-in: bafd6444e9 user: thomas tags: trunk
16:21
Fixed crashes when opening te PageConfigDialog. check-in: 73e6fc506f user: thomas tags: trunk
14:08
Remove an unused import. check-in: 62e1a99052 user: thomas tags: trunk
14:07
Implemented translating cards added to the Document or CardListModel instances. Implements [490f65b51f942c7f]. The Language column is now editable, both in the Document and in the deck import wizard. check-in: e22365acae user: thomas tags: trunk
14:01
Fix crash when trying to translate a custom card Closed-Leaf check-in: efe3aea945 user: thomas tags: translate_added_cards
12:27
Implemented translating cards in the CardListModel. This enables translating cards in the SummaryPage of the DeckImportWizard. check-in: 89e9a5bfc3 user: thomas tags: translate_added_cards
2023-07-10
20:08
Added changelog entry. check-in: f8151c89e1 user: thomas tags: translate_added_cards
19:56
Use the new capability of Document._data_card() to return the Card instance using the UserRole, replacing usage of the internalPointer() method throughout the codebase. This entails a small performance penalty, but uses the Qt model API properly and is thus transparent through layered filter models, etc. check-in: 6607d7006c user: thomas tags: translate_added_cards
19:36
Document: Add PageColumns.Language to the editable columns. Handle those in setData(). Additionally, card indices now return the Card instance when calling data(Qt.ItemDataRole.UserRole), which is used by the editor delegate. check-in: f2fce9132b user: thomas tags: translate_added_cards
19:32
CardDatabase: translate_card() now handles CheckCard instances. Also use a type variable to indicate that the output type is the same as the input type. check-in: 23797e10ec user: thomas tags: translate_added_cards
19:23
CentralWidget: Set the ComboBoxItemDelegate as the editor for the PageColumns.Language column check-in: 7b32b169ab user: thomas tags: translate_added_cards
19:19
ComboBoxItemDelegate: Implement handling the PageColumns.Language column. check-in: b1ad7ebe0c user: thomas tags: translate_added_cards
19:13
CardDatabase: Introduce type variable AnyCardType as a Union of Card and CheckCard. Use it across the code base, where applicable. check-in: 7fa611d4c5 user: thomas tags: translate_added_cards
17:56
Document: Fix linter type warning in compute_pages_saved_by_compacting(). check-in: 004258808d user: thomas tags: translate_added_cards
17:55
document_loader.py: Add CardType to __all__. check-in: 6a8f47d5ef user: thomas tags: translate_added_cards
17:48
CardDatabase: Minor re-format of translate_card_name() check-in: d162300eb2 user: thomas tags: translate_added_cards
17:36
Optimize database query for get_available_languages_for_card(). Cuts execution time from ~80ms down to ~10ms. check-in: d0b01a17cd user: thomas tags: translate_added_cards
13:50
CardDatabase: Add method get_available_languages_for_card(Card), which returns the sorted list of languages the given card is available in. check-in: 89d240a34d user: thomas tags: translate_added_cards
12:10
Tests: Implement DummyAction.as_str property to fix a linter warning about not implementing all required abstract methods. check-in: 4c6428fe84 user: thomas tags: trunk
2023-07-07
15:51
WIP saving/loading the document name and print page numbers setting check-in: e9c17b7e22 user: thomas tags: document_name_setting
2023-07-06
19:44
PageConfigWidget: Added document_name line edit and draw_page_numbers check box. The document_name can hold a printable name that is added to each page to aid distinguishing different printed sheets. The draw_page_numbers toggle shall enable printing the page number onto each page, to make it easier to spot missing printouts. See [7e2d18f1d6fc24ce] check-in: 785f002701 user: thomas tags: document_name_setting
2023-07-05
18:00
Ui: Update class names specified in Ui files, removing the need for renaming on import of the compiled modules. check-in: 418a3871fb user: thomas tags: trunk
13:40
Merge with trunk. check-in: 6a8f025994 user: thomas tags: port_pyside6
13:35
Remove unneccessary type annotations. check-in: 72f50143c9 user: thomas tags: trunk
08:32
main(): Put the appdirs migration after calling the argument parser. This prevents any system-altering code from running, if the user merely used the --help switch. check-in: c84bf71bd2 user: thomas tags: trunk
2023-07-04
14:50
Merge with port_pyside6 branch, importing fixes for the QWizards, improving dark mode rendering. check-in: 5dd88caa75 user: thomas tags: pyside6_dark_mode
14:43
Merge with trunk check-in: 9c43150efa user: thomas tags: port_pyside6
14:31
Improvements for the QWizard-based wizards. Improved positioning on screen, like improved centering and avoiding placing parts of the window outside the screen border. Use a darkmode-compatible style on Windows, instead of the Aero style. This also fixes the style switching that occurred on Windows 7. Fixes [3e5f17f1eb5bf319]. check-in: 2445789c1f user: thomas tags: trunk
14:22
Added changelog entry. Closed-Leaf check-in: c3ba069788 user: thomas tags: improve_wizard_init
14:06
Use a better centering algorithm that works on both Linux and Windows. check-in: 3fccb6a456 user: thomas tags: improve_wizard_init
13:35
Clamp the initial wizard position on screen in a way that it stays within the screen. check-in: 974fcfa793 user: thomas tags: improve_wizard_init
12:15
Move button icon setup into the base class. Subclasses now specify icons to use on buttons as a static mapping. check-in: ed8ac2d492 user: thomas tags: improve_wizard_init
12:05
Move _set_default_size() on both wizards into the base class. Introduce a size parameter in __init__() that replaces the hard-coded sizes within the method bodies. check-in: 7ac730163c user: thomas tags: improve_wizard_init
12:02
Move _set_default_size() on both wizards into the base class. Introduce a size parameter in __init__() that replaces the hard-coded sizes within the method bodies. Edit: Forgot to remove calls to self._set_default_size(), causing crashes on opening wizards. Closed-Leaf check-in: 5c3e02e9d8 user: thomas tags: bogus
11:57
Wizards: Override the default style on Windows with WizardStyle.ModernStyle. This fixes issues with dark mode rendering. The default uses AeroStyle, which is completely incompatible with dark mode rendering, so avoid that on Windows. check-in: 27b6185f38 user: thomas tags: improve_wizard_init
11:53
QWizard-based wizards now inherit from a common base class. Explicitly name the Qt Wizard arguments (parent, flags) instead of specifying them as generic *args, **kwargs. check-in: 3d8d931e04 user: thomas tags: improve_wizard_init
2023-07-02
17:42
Use a different approach for supporting dark mode on Windows 10/11. PySide 6.5 supports dark mode rendering when using a compatible Qt Style. So set the style to "fusion", which is such a style, if the app runs on Windows and no explicit style is set. check-in: 1986813987 user: thomas tags: pyside6_dark_mode
15:59
Log application version at startup. check-in: 454f3a9c50 user: thomas tags: trunk
2023-06-29
17:02
Implemented saving/loading DFC check cards. check-in: e8dfec41a4 user: thomas tags: trunk
16:48
Add changelog entry. Closed-Leaf check-in: 9edd46c3c5 user: thomas tags: generate_check_cards
16:42
Implemented loading check cards check-in: 8c3a3db2f6 user: thomas tags: generate_check_cards
15:06
Implemented saving check cards check-in: 3599de8365 user: thomas tags: generate_check_cards
2023-06-27
17:04
setup.py: Remove bad, unused PyQt5 import that got merged into the PySide6 branch by accident. check-in: 5990385490 user: thomas tags: port_pyside6
16:56
Merge with trunk check-in: dc67659682 user: thomas tags: port_pyside6
15:47
Release v0.24.1 check-in: ffeac3ce7a user: thomas tags: trunk, release, v0.24.1
15:45
Add changelog entry. check-in: 70bf1540ef user: thomas tags: trunk
15:38
Document: Improve IsFront card column rendering. The column was accidentally included for display in 0.23. The column now has a proper header ("Side") and display text ("Front" or "Back"). check-in: 94d4f58439 user: thomas tags: trunk
13:55
Add test cases for issue fixed in [19e7e12e8022e5dc] check-in: bc19577943 user: thomas tags: trunk
13:36
CentralWidget: Fixed broken check card generation and addition of related cards. Both features failed to fetch the required images, causing the document to render them as white rectangles, instead of showing the expected card images. check-in: 19e7e12e80 user: thomas tags: trunk
13:00
Merge with trunk. check-in: 31d6a92a53 user: thomas tags: port_pyside6
12:04
Merge with trunk. check-in: 93ced84ce8 user: thomas tags: port_pyside6
2023-06-26
12:19
Release v0.24.0 check-in: 362549a89f user: thomas tags: trunk, release, v0.24.0
12:17
README: Add custom cards feature to the feature list check-in: 585a96bb5e user: thomas tags: trunk
12:11
Changelog: increase indentation of second-level list entries check-in: ac24825836 user: thomas tags: trunk
11:59
tox: Fix tox.ini allowlist_externals for Windows. check-in: f73a990621 user: thomas tags: trunk
11:57
Accept dropping files onto the main window. Dropped document saves are loaded and dropped images are added as custom cards to the document. Partially implements [418371f8a10e3649]. check-in: 668191d156 user: thomas tags: trunk
11:17
Fix exceptions when adding additional copies of custom cards via the context menu actions. Closed-Leaf check-in: a0ce81a0ba user: thomas tags: drop_files
10:56
Added basic support for adding custom images via drag&drop onto the main window. Partially implements [418371f8a10e3649]. check-in: 6c13769644 user: thomas tags: drop_files
09:15
DocumentLoader: Protect against loading invalid databases. Catch the sqlite3.DatabaseError and report the error instead of crashing, if the user tries to load a file that is not an SQLite3 database. check-in: d05ecd142d user: thomas tags: drop_files
09:09
Loading documents via drag & drop mechanism. If a single file with .mtgproxies file extension is dropped onto the main window, it is loaded. check-in: caf9f40d24 user: thomas tags: drop_files
08:34
Declare the defaul document save file extension in one place, instead of hard-coding it in several locations. check-in: a711541cdf user: thomas tags: trunk
2023-06-25
14:04
README: Added recent feature additions to the feature overview check-in: 4faaabfeb8 user: thomas tags: trunk
13:18
Implemented generating check cards and exporting images as files. Both features are added to the card table context menu. Implements [f0af61b7bb1215a0] check-in: e6370ef7c7 user: thomas tags: trunk
13:15
Tests: Pass variable XDG_RUNTIME_DIR to the py3-test_create_bundle-* tox test environments. This fixes a warning emitted during the program execution check-in: 53458f3cc6 user: thomas tags: generate_check_cards
13:04
CardDatabase: Fix incomplete comment in find_related_cards(). Added two comments to the SQL query. check-in: 2e535288d1 user: thomas tags: generate_check_cards
10:16
Restore compatibility with platformdirs >= 2.6. Extend the tox environments to test with both 2.6 and 3.3. This is done to improve compatibility with currently supported Ubuntu systems, which all still ship platformdirs < 3.3 As a fallback for the user pictures directory, the home directory is used on systems with platformdirs < 3.3 check-in: a30df703e8 user: thomas tags: generate_check_cards
2023-06-24
23:21
Add changelog entry. check-in: 5e8dccaed8 user: thomas tags: generate_check_cards
22:54
Export images as files to a user-specified directory. This uses platformdirs.user_pictures_path, which was added in platformdirs 3.3.0, so bump the required version to 3.3.0. Image export is added to the right-click context menu for the current page table. The suggested file name is derived from the card name, stripped of characters not allowed on FAT32, for increased compatibility with Windows systems. Implements [5265af42b7f94e65] check-in: 3c2f4b5b9d user: thomas tags: generate_check_cards
15:45
CardDatabase: Define proper return type for get_all_cards_from_image_cache(). check-in: a4c020f379 user: thomas tags: generate_check_cards
15:36
CardDatabase: Replaced manually constructing a transparent QColor, use the one from the QColorConstants enum instead. check-in: 89808847fe user: thomas tags: generate_check_cards
13:40
Added changelog entry. check-in: b05539fa4e user: thomas tags: generate_check_cards
13:22
Fixed remaining issue with check cards not fitting on pages with regular cards. check-in: 66836e4c7c user: thomas tags: generate_check_cards
13:13
Tests: Potentially fix crashing the Python interpreter in the document_light fixture. Creating a QPixmap instance without the qtbot fixture present seems to have caused spurious crashes. check-in: 9ab62eb40d user: thomas tags: generate_check_cards
13:00
Tests: Properly setup the document_light pytest fixture check-in: 051c5ace1f user: thomas tags: generate_check_cards
12:33
Implemented adding check cards via the context menu. It currently causes adding new pages, which still has to be fixed check-in: 39da91e3a7 user: thomas tags: generate_check_cards
11:43
Merge with trunk check-in: 453359751e user: thomas tags: generate_check_cards
2023-06-08
16:23
Release v0.23.0 check-in: 1a7a9d026c user: thomas tags: trunk, release, v0.23.0
16:18
When looking up other sets a card was reprinted in for the purpose of switching printings, also take the front/back property into account. This is required for the SLD reversible cards. Partial fix for [8513cf57bba8e695]. check-in: 9b0ed0e999 user: thomas tags: trunk
15:37
Properly ROLLBACK the card database during the card data import, if the import fails because of an error in the input data stream. check-in: 8d5efc428c user: thomas tags: trunk
14:17
Increase Qt signal timeouts in tests from 100ms to 1s. This makes the test suite more robust under heavy system load check-in: 7158e10d1e user: thomas tags: trunk
13:25
Update ThirdPartyLicenses.md for the Appdirs → platformdirs transition check-in: e68f22e383 user: thomas tags: trunk
13:21
Improve handling of hidden printings by the cache cleanup wizard. Implements [f8864e4145a223aa] check-in: f49bea08f9 user: thomas tags: trunk
13:21
Add changelog entry Closed-Leaf check-in: d5d61908d7 user: thomas tags: cache_cleanup_hidden_printings_filter
12:36
Pre-select hidden printings in the CardFilterPage, if automatic selection of unknown or hidden printings is enabled in the FilterSetupPage. check-in: 4ba79c521d user: thomas tags: cache_cleanup_hidden_printings_filter
12:19
Added column IsHidden to the KnownCardImageModel used by the CacheCleanupWizard. Refactored loading Card instances for given ImageDatabase CacheContent instances: The CardDatabase gained method get_all_cards_from_image_cache(cache_content), which partitions the content into 3 sets, the visible printings, the hidden printings and the unknown printings. check-in: e3e7616ed3 user: thomas tags: cache_cleanup_hidden_printings_filter
2023-06-06
21:13
Increased progress reporting rate during card data downloads. On platforms, where QProgressBar supports sub-percent display, the bar should be filled more smoothly now. check-in: c3a143f658 user: thomas tags: trunk
2023-06-05
15:13
Added context menu to the page card table view. It allows adding 1-3 (or a custom number of) copies of an already added card to the document by right clicking the card. In addition, it allows directly adding 1-4 copies of cards related to it, like other meld pieces or tokens. Implements [0662054dc8856377] and [15864f4d4d6495d8]. check-in: 7322497588 user: thomas tags: trunk
15:10
Added "Add 4 copies" option to related cards. For already added cards, 1-3 copies is sufficient because of the "max 4 copies" deck construction rule, but for potentially not present related cards, an option to add 4 is beneficial. Closed-Leaf check-in: 4a3d3e3e84 user: thomas tags: context_menu_actions
15:03
Implemented adding related cards to the document via the right-click context menu. If a card has related cards set, the context menu offers to add all or individual cards. The related cards are discovered recursively, stopping at tokens. Tokens cannot have outgoing related cards, because of their potentially huge fan-out. (Additionally, the card Academy Manufactor links Clue, Treasure and Food tokens, so any card creating one of those tokens would pull in all cards related to any of those "evergreen" tokens. Since this is not desirable, the recursive discovery stops at tokens.) check-in: 29a9fe6438 user: thomas tags: context_menu_actions
14:50
Performance optimization: Drop the PRAGMA analysis_limit=1000 database connection setting. It causes SQLite to create sub-optimal query plans and with this performance issues. Without this setting, the card data import runs a full ANALYZE, which mitigates these performance issues. Closed-Leaf check-in: 0d7753e232 user: thomas tags: related_printings
14:29
Implemented adding related cards via the right-click context menu. check-in: a010cfceb2 user: thomas tags: related_printings
10:28
Implemented fetching related cards from the card database. check-in: e95eb8babb user: thomas tags: related_printings
09:44
Fix crash in log file storage migration code that occurs after an older version is launched at least once after the migration already took place. check-in: 36b1412d4b user: thomas tags: related_printings
08:44
Store the "related printings" card relation in the database. This allows fetching tokens created by cards or other cards referenced by name. check-in: f49062c80e user: thomas tags: related_printings
2023-05-24
15:47
Add changelog entry. check-in: 78c0189787 user: thomas tags: context_menu_actions
14:25
Add a forth "Add copies" option to the context menu that lets the user specify a number via an input dialog. check-in: 0abb1c4b9c user: thomas tags: context_menu_actions
13:44
Implemented context menu actions to add 1, 2, or 3 copies of the card right clicked on. check-in: 0420830482 user: thomas tags: context_menu_actions
13:13
Ui_CentralWidget: Set the page card table view context menu policy to CustomContextMenu. Connect the customContextMenuRequested signal to a handler in the CentralWidget class. check-in: bbef077496 user: thomas tags: context_menu_actions
12:19
Ui_CentralWidget: Set the page card table view context menu policy to ActionsContextMenu. Closed-Leaf check-in: 5e443526be user: thomas tags: bogus
12:15
Add icon "list-add" to the internal icon theme. check-in: fc325736bf user: thomas tags: context_menu_actions
12:12
Icons: Fix inconsistencies in the 24px SVG icons check-in: f6b341cfea user: thomas tags: trunk
10:21
Added tests for ProgressMeter. Extended ProgressMeter: Parametrize advance() with the step size, guard against negative total progress, log an error when advance() overshoots the target progress. check-in: 12d16fa9a3 user: thomas tags: trunk
2023-05-23
17:45
Refactored progress reporting when post-processing downloaded card data or updating card filters. The new approach encapsulates the progress within an object. Progress reporting no longer requires hard-coded progress values. During the card data import, also cover the post-download cleanup and ANALYZE/COMMIT steps. check-in: 1f9b3fcafe user: thomas tags: trunk
17:01
Use a variable to count progress during card data post-processing. This removes hard-coded numbers and allows insertion of steps anywhere in the chain without needing to re-adjust all later progress values. Edit: Superseded by a better implementation in [1f9b3fcafe167797]. Closed-Leaf check-in: 5ae5893792 user: thomas tags: bogus
14:08
Added card filter for reversible cards. Those are Secret Lair double-sided printings of otherwise single-sided cards. They can cause issues when unexpectedly imported. Implements [4fa477f3d47c6573] check-in: d82c80a2a4 user: thomas tags: trunk
14:01
Added card filter for hiding borderless cards. Implements user request [39c761f37e3edef0]. check-in: 0c69b3d54e user: thomas tags: trunk
13:41
Added card filter for hiding borderless cards. Implements user request [39c761f37e3edef0]. Closed-Leaf check-in: 541be6f4df user: thomas tags: bogus
2023-05-22
16:29
Validate the CardDatabase schema on connect. Log an error if the card database does not match the expected schema. Do not crash the application and try to keep running with the modified schema. check-in: 3658eb464e user: thomas tags: trunk
2023-05-20
15:15
Written test for ImageDownloader._download_image_from_scryfall(). Simplified some logic in _download_image_from_scryfall() by flattening a branch inside the finally block into the try block check-in: 2c580ffba3 user: thomas tags: duplex_printing
2023-05-18
14:18
Merge CardSizes enum and CardSize NamedTuple classes. Also replace the IMAGE_SIZE constant in the imagedb module with the CardSize enum. check-in: 59aa937bd5 user: thomas tags: duplex_printing
2023-05-16
07:15
Verify that the download_finished signal is emitted. check-in: 975e9099eb user: thomas tags: duplex_printing
07:05
Added tests for obtain_missing_images(). Validate behavior under network failure conditions. Fix handling of error messages in _handle_network_error_during_download() according to spec. check-in: 3e1a8783eb user: thomas tags: duplex_printing
05:07
Merge with trunk. check-in: 2cf033b027 user: thomas tags: duplex_printing
2023-05-15
15:36
Merge with trunk check-in: 9f43748776 user: thomas tags: port_pyside6
14:30
Replace deprecated pkg_resources dependency with importlib.resources from the standard library. check-in: f04e33833b user: thomas tags: trunk
14:01
Fix tests check-in: b63067361a user: thomas tags: trunk
12:02
Dependencies: Migrated from deprecated appdirs to the newer platformdirs library. Fixes [37c88db740a4ffd6]. check-in: 55955590d1 user: thomas tags: trunk
2023-05-14
12:50
Merge with trunk. check-in: 16ba3d4bb8 user: thomas tags: port_pyside6
2023-05-13
12:55
Added a few test cases for the card image downloader. check-in: a30a45e1de user: thomas tags: duplex_printing
2023-05-10
14:53
Implement storing the card layout, which is required for proper handling of meld card back sides. check-in: ed5f15273c user: thomas tags: duplex_printing
14:52
Implement generating human-readable names for back sides. Closed-Leaf check-in: dab999e9e4 user: thomas tags: store_card_layout
2023-05-09
18:37
Improve generation of back side names, by generating a proper name for Meld card back sides. check-in: 480890532e user: thomas tags: store_card_layout
17:22
Moved WIP code updating the BackFace.name database column to the card info downloader module, where it belongs. check-in: 9cba463954 user: thomas tags: store_card_layout
17:19
Settings UI: Renamed methods _{save|load}_download_settings(), replacing download with card_filter, because that fits the code better. The old name still reflected legacy behaviour, skipping hidden cards during the card data download process. check-in: 10d99f8b98 user: thomas tags: store_card_layout
13:06
Store a layout override in the Printing table for reversible cards. check-in: a9b40d4731 user: thomas tags: store_card_layout
2023-05-08
15:35
Style fixes check-in: d6a0eeb0d7 user: thomas tags: store_card_layout
15:10
Update the card layout column during the card data import. check-in: 91365d22f2 user: thomas tags: store_card_layout
13:35
Added a meld card to the test cases. check-in: 6c35fbca2b user: thomas tags: store_card_layout
13:28
Fix importing the card layout field. Added verification to the existing test cases. check-in: b06a14678a user: thomas tags: store_card_layout
12:54
Tests: Centralize specifying test case data in one place. De-duplicates test data, eases updating the used JSON samples and extension. check-in: 99b7a5412a user: thomas tags: store_card_layout
12:52
Update the Card.card_layout column during the card data import. check-in: 0f4b40bcc2 user: thomas tags: store_card_layout
11:13
Update the card database schema to allow storing the card layout. check-in: 6100d2cbb1 user: thomas tags: store_card_layout
2023-05-07
19:58
Partial implementation for updating the BackFace name attribute. This needs more design work to handle meld back faces. check-in: fcf8f960f8 user: thomas tags: duplex_printing
19:14
Properly update the Printing.back_face_id column when updating the card data. check-in: 269ca5acf9 user: thomas tags: duplex_printing
17:44
Implemented storing back faces of single-faced cards in the card database. check-in: 100f19b0ea user: thomas tags: duplex_printing
15:24
Fix test test_cut_line_locations_when_enabled check-in: a51db495bf user: thomas tags: duplex_printing
13:46
Fixed rendering of front/back sides on paper/PDF when duplex mode is active. Renamed the DuplexType enum constants from ODD/EVEN to FRONT/BACK for improved clarity. check-in: a2f0801ec5 user: thomas tags: duplex_printing
12:30
Fixed type mismatches when loading PageLayoutSettings from documents in version 4 or 5. check-in: 5dbdc9db1e user: thomas tags: duplex_printing
11:18
Optimize PageScene.draw_card() check-in: d4d8373add user: thomas tags: duplex_printing
11:02
Parametrize test function test_valid_data_loads_correctly() with the PageLayoutSettings to use. check-in: 7254e8a2a9 user: thomas tags: duplex_printing
10:57
Use the correct QPrinter.DuplexMode enum member when printing with duplex enabled. It should use long edge binding, instead of short edge binding. check-in: 4d598514f0 user: thomas tags: duplex_printing
10:53
Removed an outdated comment check-in: 51d4db1d69 user: thomas tags: duplex_printing
2023-05-06
14:07
PageScene: Implemented positioning images on duplex back sides check-in: 84679e1903 user: thomas tags: duplex_printing
2023-05-04
15:09
PageScene: Compute cut marker locations using range() operations. Closed-Leaf check-in: 107b2f70da user: thomas tags: bogus
13:41
PageScene: Update drawn cut marker positions when switching pages from odd to even or even to odd pages while duplex mode is active. check-in: f3835760e4 user: thomas tags: duplex_printing
13:31
PageScene: Implemented computation of vertical cut line locations for even duplex pages. check-in: 1a4f380c29 user: thomas tags: duplex_printing
11:10
Refactored test test_cut_line_locations_when_enabled() for better extensibility. Also test cut line locations for both odd and even pages. check-in: 9dff680aa7 user: thomas tags: duplex_printing
10:13
Unified tests for application settings, reducing boilerplate setup code. check-in: b57e133c6c user: thomas tags: duplex_printing
2023-05-03
16:57
Add method PageLayoutSettings.paper_size(), returning the paper size in mm as a QSizeF. Slightly reduces boilerplate and unifies code in print.py check-in: f7f6962b21 user: thomas tags: duplex_printing
16:43
print.py: Set duplex mode when creating the QPrinter based on the DuplexMode set in the PageLayoutSettings. check-in: ed0549573e user: thomas tags: duplex_printing
14:57
Fixed existing tests and added tests that verify the PageLayoutSettings types. check-in: 606afda15d user: thomas tags: duplex_printing
14:19
Implemented setting the duplex mode in the page config widget. check-in: d8e825d61d user: thomas tags: duplex_printing
13:37
Ensure that PageLayoutSettings attributes are always cast to the expected types when loading them from documents. check-in: 11138de0db user: thomas tags: duplex_printing
13:19
Add duplex_mode to the PageLayoutSettings. Store the value in saved documents and restore it when loading a document. check-in: 2d910bd272 user: thomas tags: duplex_printing
13:16
Store the DuplexMode enum value in the DEFAULT_SETTINGS configparser. check-in: 3c34cafb69 user: thomas tags: duplex_printing
12:25
Pull bugfix from trunk. check-in: a4069ef56e user: thomas tags: duplex_printing
12:06
Fixed use of changed method get_scryfall_bulk_card_data_url(). Updating card data from Scryfall works again. The issue was introduced in [46cc36de15df7098]. check-in: 94c7e49ed6 user: thomas tags: trunk
11:14
Added DuplexMode enum and duplex-mode settings key to to the default document settings stored in the configuration file. The DuplexMode enum holds three modes: off, dfc-only, and full. Off prints in simplex mode, the other two values enable duplex mode. dfc-only only prints backs of double-faced cards, and keeps regular ones with a white back. "full" additionally prints card backs of regular cards. check-in: ec27b44e2e user: thomas tags: duplex_printing
2023-05-02
14:06
README: Updated the list with supported deck list database websites. check-in: 12ddb64b88 user: thomas tags: trunk
13:50
Restored displaying the download progress when using the “Download card data as file” option in the Debug settings. This was non-functional, because the new CDN does not offer a workable download size. The downloader now estimates the compressed file size from the uncompressed size reported by the API. check-in: 46cc36de15 user: thomas tags: trunk
13:11
Proper type hinting for JSON card data obtained from the Scryfall bulk data API. The new approach uses the typing.TypedDict class to define which keys are available, and which types these keys hold. check-in: 78cc7f568f user: thomas tags: trunk
11:55
Use pyenv-win and tox-pyenv to run unit tests on all supported Python versions. Closed-Leaf check-in: 44640ba465 user: thomas tags: test_multiple_pythons
2023-04-27
09:03
New document save version 6. Stores document settings as key-value pairs for extensibility. Added a type column to the Card table. check-in: 9df9714ed6 user: thomas tags: port_pyside6
09:03
Release v0.22.0. check-in: 590942e64c user: thomas tags: port_pyside6
09:02
New document save version 6. Stores document settings as key-value pairs for extensibility. Added a type column to the Card table. check-in: 608a17929b user: thomas tags: trunk
09:00
Added changelog entry. Closed-Leaf check-in: c2dfa7cd96 user: thomas tags: key_value_document_format
2023-04-26
14:56
Implement saving and loading document file format 6. check-in: 24180003a8 user: thomas tags: key_value_document_format
11:44
Fix tests. check-in: 639f343bb9 user: thomas tags: key_value_document_format
11:00
Move Worker class out of the DocumentLoader class. check-in: e2e5df7c98 user: thomas tags: key_value_document_format
09:01
Added version 6 of the document save format. This format saves document settings as key-value pairs and adds a type column to the Card table. check-in: 684eb0e694 user: thomas tags: key_value_document_format
2023-04-18
18:23
Release v0.22.0 check-in: d4e1a2e6e7 user: thomas tags: trunk, release, v0.22.0
18:03
Improved the "funny cards" card filter. In no longer excludes tournament-legal cards from Un-sets. Fixes [bd2832d212ff3b8d]. check-in: 833f0c3cf8 user: thomas tags: port_pyside6
18:03
Improved the "funny cards" card filter. In no longer excludes tournament-legal cards from Un-sets. Fixes [bd2832d212ff3b8d]. check-in: 157ee2bba3 user: thomas tags: trunk
14:58
Ensure Python 3.8 compatibility. check-in: 147c5d9e0d user: thomas tags: port_pyside6
14:53
Ensure Python 3.8 compatibility check-in: 1a1a1a5b0b user: thomas tags: trunk
14:37
Compiling UI stubs is unsupported on Python 3.8 with PyQt5, because the required ast.unparse is not available. Changes in [5898720dcbf89a7d] caused the stubs to be generated during the packaging process. This broke building on PyQt5 + Py 3.8, because the compiler script fails. Mark this as a non-critical error, so that builds don't fail because of it. Closed-Leaf check-in: ff03c5ab3b user: thomas tags: py3.8-compat
14:20
Fix 3.8 compatibility, round 2. check-in: fb510133a1 user: thomas tags: py3.8-compat
14:06
Fix type annotations for Python 3.8 compatibility. check-in: 3e000b29e9 user: thomas tags: py3.8-compat
13:09
Decklist downloader: Properly escape separators in URL matchers. Dots have to be escaped like \. check-in: a67e79f132 user: thomas tags: port_pyside6
13:08
Decklist downloader: Properly escape separators in URL matchers. Dots have to be escaped like \. check-in: 98c7cce2d3 user: thomas tags: trunk
13:03
Implemented downloading deck lists from 5 deck list database websites. check-in: bb6e4648ab user: thomas tags: port_pyside6
12:59
Implemented downloading deck lists from 5 deck list database websites. check-in: 53537b8ff0 user: thomas tags: trunk
12:46
Add support for downloading decks from mtgazone.com Closed-Leaf check-in: e40faeca88 user: thomas tags: support_additional_deck_list_websites
11:11
Implemented downloading decks from mtgtop8.com check-in: 598aa15d8a user: thomas tags: support_additional_deck_list_websites
10:49
Improved display of supported file types in the deck import wizard. It now shows "Scryfall CSV export" and "Tappedout CSV export" instead of two times the generic "CSV-Document" entry. check-in: 901afe0257 user: thomas tags: support_additional_deck_list_websites
10:44
Implemented importing Magic Workstation deck lists. check-in: e110f13d2e user: thomas tags: support_additional_deck_list_websites
10:16
The XMage parser now uses the new prefix skipping implemented in the RE parser base class. check-in: 8b0d29f4b0 user: thomas tags: support_additional_deck_list_websites
10:09
Implemented deck list parser for Magic Workstation deck lists (.mwDeck file extension). check-in: 733444306d user: thomas tags: support_additional_deck_list_websites
2023-04-17
17:01
Backport adjustments for scripts/compile_ui_files.py check-in: d12ce065c5 user: thomas tags: trunk
15:39
Exclude QtNetwork and QtLanguageServer. Package is down to 28 MiB using Python 3.11.3 and SQLite 3.41.2. check-in: 906d3d99ec user: thomas tags: port_pyside6
15:01
Additional MSI package build optimizations. Result is ~29.5 MiB. check-in: 97ea8bbea2 user: thomas tags: port_pyside6
15:00
Additional optimizations Closed-Leaf check-in: 4fa42de3e3 user: thomas tags: optimize_pyside6_packaging
14:32
Exclude some fully contained components via excludes in setup_cx_freeze.py, instead of manually deleting them in clean_windows_build.bat check-in: 4096d77fdd user: thomas tags: optimize_pyside6_packaging
14:16
Optimized packaging. The resulting MSI package is slightly below 30 MiB. check-in: 3bda1d68ac user: thomas tags: optimize_pyside6_packaging
12:41
Ported scripts/clean_windows_build.bat to work with PySide6. Packaging to MSI packages now works with PySide6, producing only slightly larger packages compared to PyQt5. (31MiB using PySide6 vs 26 MiB using PyQt5) With this change, the PySide6 port is feature-complete check-in: 6423973012 user: thomas tags: port_pyside6
12:37
Fixed arguments passed to compiler functions check-in: f001d69108 user: thomas tags: port_pyside6
10:36
Fix building the Windows application bundle. Extend scripts/compile_ui_files.py with command line flags to purge existing generated code and switch between generating stubs or full modules. Use that to ensure that fresh modules are present before creating the application bundle. check-in: 5898720dcb user: thomas tags: port_pyside6
2023-04-12
16:59
Pull fixes from trunk. check-in: 2256c3003c user: thomas tags: port_pyside6
15:10
Pull packaging and SSL fixes from trunk check-in: a5d24df87a user: thomas tags: port_pyside6
14:35
Explicitly set SSL certificates for HTTPS connections on application start. On Python >= 3.10, use the truststore library to access the system-native trust storage. On Python < 3.10, use certifi instead. This prevents connection failures that occur on a fresh Windows 10 installation. check-in: 999b8336bf user: thomas tags: trunk
13:24
Build system: Add clean_windows_build.bat to the allowed commands for tox on Windows. This fixes an incompatibility with newer tox versions. check-in: 7416ee19f9 user: thomas tags: trunk
2023-04-08
16:11
Sync with trunk check-in: 6f6df45a01 user: thomas tags: generate_check_cards
2023-04-05
18:30
Fix a grammar mistake in the Deck import wizard UI. check-in: dba1dbc40a user: thomas tags: support_additional_deck_list_websites
18:22
DocumentLoader: option PageLayoutSettings.draw_sharp_corners is now sourced from the global settings when loading a document with schema version 4, instead of force-enabling it in that case. check-in: b9e0b93960 user: thomas tags: trunk
18:08
Added changelog entry for bugfix [b33546aa1cbd62f3]. check-in: ee4bf351fe user: thomas tags: trunk
18:03
Fixed links in changelog.md check-in: a307df682b user: thomas tags: support_additional_deck_list_websites
17:37
Sorted the available downloaders list. This sorts the site listing in the UI tooltip. check-in: de0d7e7a11 user: thomas tags: support_additional_deck_list_websites
17:34
Add support for downloading decks from infinite.tcgplayer.com check-in: ee39431a39 user: thomas tags: support_additional_deck_list_websites
14:02
Improved a test function name check-in: 4fbcc01693 user: thomas tags: support_additional_deck_list_websites
13:59
Implement fetching decks from archidekt.com. check-in: 756254b296 user: thomas tags: support_additional_deck_list_websites
13:29
Added negative test cases for the deck url matchers. Hardened the DeckstatsDownloader URL matcher. check-in: 87ca062f3f user: thomas tags: support_additional_deck_list_websites
13:01
Added test cases for DECKLIST_PATH_RE.match() for classes MoxfieldDownloader, TappedOutDownloader, and DeckstatsDownloader check-in: 6a6a26be4c user: thomas tags: support_additional_deck_list_websites
12:40
Refactored test_decklist_downloader.py: Unified tests for the DECKLIST_PATH_RE.match() function. The test case now takes two arguments, the DecklistDownloader class and a URL. With this, one parametrized test is sufficient, instead of one per DecklistDownloader subclass. Additionally, the test test_IsIdentifyingDeckUrlValidator_validate now operates on the same dataset, keeping it in sync automatically. check-in: e64fe8335c user: thomas tags: support_additional_deck_list_websites
2023-04-01
14:42
Simplify CardInfoDatabaseImportWorker._read_printing_filters_from_db(). The dict() constructor accepts a tuple stream, so use that instead of a manual dict comprehension. Also use functools.lru_cache to cache the result instead of a manually passing the result around. check-in: 362a32d187 user: thomas tags: port_pyside6
14:40
Fix crash in PageScene when compacting the document moves cards onto the currently shown page. Fixes [b33546aa1cbd62f3]. check-in: 16ca873726 user: thomas tags: port_pyside6
14:38
Fix crash in PageScene when compacting the document moves cards onto the currently shown page. Fixes [b33546aa1cbd62f3]. check-in: ab18223738 user: thomas tags: trunk
12:57
Actually perform the card data update if the user accepts the offer in the update notification message box. Fixes [6e0580002bc333cc]. check-in: 98e4d81f30 user: thomas tags: port_pyside6
11:47
Use QDialog’s parameterless open(), instead of QPrintDialog's open(receiver, slot) method. This fixes the crash in MainWindow.on_action_print_triggered(). Fixes [a90e0052d03aa291]. check-in: 4c1bab1829 user: thomas tags: port_pyside6
2023-03-21
14:24
Simplify CardInfoDatabaseImportWorker._read_printing_filters_from_db(). The dict() constructor accepts a tuple stream, so use that instead of a manual dict comprehension. Also use functools.lru_cache to cache the result instead of a manually passing the result around. check-in: 211696cb56 user: thomas tags: trunk
2023-02-11
16:36
Add support for downloading deck lists from mtgdecks.net check-in: 4e58134f43 user: thomas tags: support_additional_deck_list_websites
16:14
Skipping network-hitting tests is now governed by the environment variable MTGPROXYPRINTER_RUN_NETWORK_TESTS. If set to a non-zero integer, the tests pinging network servers are run. By default, these remain skipped. check-in: 212addbc48 user: thomas tags: support_additional_deck_list_websites
12:17
Sync with trunk check-in: f81b644d41 user: thomas tags: port_pyside6
2023-02-08
16:05
Release v0.21.0 check-in: f9a3eea7e6 user: thomas tags: trunk, release, v0.21.0
16:01
Fix Python 3.8 compatibility. check-in: 3e5846bc3c user: thomas tags: trunk
14:21
Prepare Release v0.21.0 check-in: 26cd5d837e user: thomas tags: trunk
14:16
Update and unify copyright notices for 2023 check-in: 115e8dee0a user: thomas tags: trunk
13:32
Temporarily disable dark mode rendering on Windows 10, which avoids rendering issues in the QWizards. When application dark mode was active, they rendered with white text on white background, making them unusable. Dark mode rendering can return, after vendoring in the Breeze Dark color scheme. check-in: 6a46e8bcb6 user: thomas tags: trunk
13:14
Rephrased some changelog entries. check-in: 67cd4aaf61 user: thomas tags: trunk
13:03
CardListModel.remove_all_basic_lands(): Log removed land count. check-in: 78c9b8a21f user: thomas tags: trunk
2023-02-03
12:25
Add changelog entry. check-in: b6958c0b50 user: thomas tags: trunk
08:58
Merge with trunk check-in: 59cbe5f4ff user: thomas tags: first_launch_wizard
08:43
Merge with trunk check-in: eedb14afbb user: thomas tags: generate_check_cards
2023-02-02
22:56
Fixed wrong CSV dialect name in the TappedOutCSVParser check-in: 9a72bd4f8c user: thomas tags: trunk
22:56
Fixed wrong CSV dialect name in the TappedOutCSVParser check-in: 2d20e263de user: thomas tags: port_pyside6
22:53
Fix a few more Qt scoped enum uses. check-in: 1e94642897 user: thomas tags: port_pyside6
22:46
Fix TypeError in the CacheCleanupWizard when trying to open a card image tooltip while using PyPy. check-in: 3c13f2a674 user: thomas tags: port_pyside6
22:24
Remove duplicate signal emit of modelAboutToBeReset in the UnknownCardImageModel and KnownCardImageModel classes. check-in: 4e2978c887 user: thomas tags: trunk
22:24
Remove duplicate signal emit of modelAboutToBeReset in the UnknownCardImageModel and KnownCardImageModel classes. check-in: efb05e6a2b user: thomas tags: port_pyside6
22:22
Fixed usage of Qt scoped enums across the project. This should remove all deprecated uses of enum constants in the top level Qt namespace. check-in: e3f733f925 user: thomas tags: port_pyside6
21:37
Optimize rendering the PageScene. It no longer re-draws the entire canvas when cards are added/removed or the page is switched. Additionally, coordinate computations are cached for as long as the document page layout does not change. check-in: fadcb5865a user: thomas tags: port_pyside6
21:13
Optimize rendering the PageScene. It no longer re-draws the entire canvas when cards are added/removed or the page is switched. Additionally, coordinate computations are cached for as long as the document page layout does not change. check-in: 16463fce97 user: thomas tags: trunk
21:11
Replace QColor("white") with QColorConstants.White Closed-Leaf check-in: b7aeb98745 user: thomas tags: optimize_page_scene
21:04
Refactor PageScene.on_current_page_changed() to only re-draw the parts that are required. Use PageScene.on_current_page_changed() to switch between pages when rendering to paper/PDF. Remove the now obsolete and unused PageScene.redraw() method. check-in: fc94f86a85 user: thomas tags: optimize_page_scene
21:02
Fix TypeError when setting QPrinter resolutions. This was caused by the RESOLUTION magnitude value returning floating point 300.0 instead of the expected 300 integer. check-in: 975f1b9885 user: thomas tags: optimize_page_scene
20:37
CardItem instances now explicitly set their Z value. check-in: 9d9b53c845 user: thomas tags: optimize_page_scene
20:34
Several events no longer cause a PageScene redraw: Changing the application color scheme, changing the page layout, and updating the page type of the current page. Also, elements are now explicitly ordered on distinct layers using the Z axis. Cards are placed above cut lines, which are above the background. The background is now always present, but is rendered transparent when rendering on paper/PDF. check-in: 3aea0c14e7 user: thomas tags: optimize_page_scene
18:00
Improved PageScene.on_data_changed() to handle the case when multiple, consecutive cards are replaced on the current page. This is not used currently, but required to properly implement the signal handler. It now conforms to the Qt API, which allows this use case. check-in: bd59235be7 user: thomas tags: optimize_page_scene
17:47
Replace the image on the PageScene when a printing is replaced, instead of redrawing the entire page. check-in: 1423723b13 user: thomas tags: optimize_page_scene
17:33
Avoid re-drawing the PageScene when inserting cards in the middle of the page. check-in: 085c790e30 user: thomas tags: optimize_page_scene
16:47
PageScene: Instead of redrawing the entire page, remove individual cards that were removed from the current page. Adjust positions of the remaining cards. check-in: 243c09d46a user: thomas tags: optimize_page_scene
16:45
Document: data(Qt.UserType) now returns the PageType for indices pointing to Pages. check-in: fd59eb8646 user: thomas tags: optimize_page_scene
2023-02-01
16:53
Fixed AddCardWidget not updating the card names when updating the card filters. Uses the new signal in the CardDatabase. Additionally to the common case of updating filters in the settings, the new approach also covers edge cases when updating card data. For example, if a card name is selected, which is then hidden because of a ban filter affecting it after a card data update. Fixes [1293ad6af9798e81]. check-in: f53e3a93af user: thomas tags: optimize_page_scene
16:49
CardDatabase now derives from QObject. Added signal card_filter_updated that is emitted when processing the card filters finishes. check-in: 81922d05dd user: thomas tags: optimize_page_scene
2023-01-31
13:40
Refactored PageScene._compute_cut_marker_positions() check-in: 816ec411d5 user: thomas tags: optimize_page_scene
12:55
CardItem now always adds sharp corners, but hides them via opacity when the option to draw them is disabled. It also directly listens on the Document.page_layout_changed signal to update its state automatically. check-in: 85a1371593 user: thomas tags: optimize_page_scene
2023-01-27
11:06
Moved tests for PageLayoutSettings into a separate test module. check-in: 53ae30b058 user: thomas tags: optimize_page_scene
2023-01-25
17:22
Introduce class CardItem, derived from QGraphicsItemGroup, which handles drawing of cards and optional sharp corners. This groups the corners together with the image they belong to, making it easier to move the group of items around. check-in: e9dbbeeafd user: thomas tags: optimize_page_scene
2023-01-24
16:06
Cache computed card coordinates. Add CardSize as a mixin to CardSizes, which avoids having to access the value via the enum .value property. Reduces boilerplate code and improves type inference. check-in: dda1bca17a user: thomas tags: optimize_page_scene
14:59
Store card size constants in pixels, instead of millimeters. Refactor computation of positions to convert individual components, like margins and spacings to pixels first and round those to full pixels. This places all images and lines on full pixels, avoiding subsampling and sub-pixel overlaps that were still present in the page rendering. check-in: 2e7009645a user: thomas tags: optimize_page_scene
2023-01-22
18:01
Separate computation of cut marker locations and actual drawing of cut markers into different methods. The locations are now computed once at instantiation and when the page layout changes. Generalized the location computation algorithm and merged the computation of horizontal and vertical markers into one algorithm check-in: 1fa09f7c87 user: thomas tags: optimize_page_scene
11:37
Refactored creation of cut lines. These no longer have a bounding box covering the entire page scene. Instead, they are one pixel thick and are moved to the appropriate position. check-in: 784024e5cf user: thomas tags: optimize_page_scene
11:36
Refactored wording in hasgetters matcher to be more concise. check-in: 26137503f3 user: thomas tags: optimize_page_scene
00:11
Tests: Added test cases for cut marker locations when image spacing is active. Fixed variable names in the matcher list comprehensions, as X and Y axis were swapped in the variable names. check-in: f5d301be1c user: thomas tags: optimize_page_scene
2023-01-21
21:55
Add tests for drawing cut markers in the PageScene. Fixed type mismatch in the PageScene cut marker drawing logic that caused the drawing of an additional, off-scene row and column of cut markers. The PageScene now only draws lines within the scene rectangle. check-in: f1b794b602 user: thomas tags: optimize_page_scene
21:50
Add hasgetter and hasgetters Hamcrest matchers. These are derived from the PyHamcrest hasproperty and hasproperties matchers. They work the same, except that they expect a callable getter without parameters. These are useful for Qt objects (like QRect) which make their state available via getter methods, instead of Python properties. check-in: ce741c66ad user: thomas tags: optimize_page_scene
11:27
Cleaned up settings related Signals: Removed MainWindow.settings_changed and CentralWidget.settings_changed signals. The AddCardWidget now receives the preferred language via an explicit signal carrying the new value. The PageRenderer now receives changed page layout settings via the Document.page_layout_changed_signal, which now holds the new settings as the signal value. check-in: 8fb0aa6c9e user: thomas tags: optimize_page_scene
10:58
Cleaned up settings related Signals: Removed MainWindow.settings_changed and CentralWidget.settings_changed signals. The AddCardWidget now receives the preferred language via an explicit signal carrying the new value. The PageRenderer now receives changed page layout settings via the Document.page_layout_changed_signal, which now holds the new settings as the signal value. Closed-Leaf check-in: b545d11f6f user: thomas tags: bogus
09:47
Add test modules for the PageScene and PageRenderer. check-in: aaedb41653 user: thomas tags: optimize_page_scene
01:06
PageScene: Fix Page index validation and fix detection of append vs insert in on_rows_inserted. Appending cards no longer re-draws the page twice. check-in: 4ace9f4a37 user: thomas tags: optimize_page_scene
00:14
The PageScene.selected_page persistent index is now created when setting the Document. To enable that, Document gained method get_current_page_index(self) -> QPersistentModelIndex. The PageScene no longer requires a Document.current_page_changed signal to be emitted at least once to be able to render the current document page. check-in: d7b5bf6f77 user: thomas tags: optimize_page_scene
2023-01-19
16:45
Replace use of QDialog.exec_() with the recommended QDialog.open(). See [https://doc.qt.io/qt-6/qdialog.html#exec]. Replaced overridden exec_() methods with equivalent slots on_accept() and on_reject(), connected to the respective signals accepted and rejected. check-in: 5ed7039bc1 user: thomas tags: port_pyside6
16:34
Replace use of QDialog.exec_() with the recommended QDialog.open(). See [https://doc.qt.io/qt-6/qdialog.html#exec]. Replaced overridden exec_() methods with equivalent slots on_accept() and on_reject(), connected to the respective signals accepted and rejected. check-in: f4b4edb968 user: thomas tags: trunk
16:04
Port the interactions with the Document class to the Command design pattern. All modifications to the Document are now performed through DocumentAction subclass instances. Add capability to apply and undo these instances. Add Undo and Redo actions to the main window. Implements [5e36672791b960e3]. Fixes [5feb35ee3d7576de]. check-in: a9ca28985e user: thomas tags: port_pyside6
15:34
Port the interactions with the Document class to the Command design pattern. All modifications to the Document are now performed through DocumentAction subclass instances. Add capability to apply and undo these instances. Add Undo and Redo actions to the main window. Implements [5e36672791b960e3]. Fixes [5feb35ee3d7576de]. check-in: 0cd2f324ee user: thomas tags: trunk
15:11
Remove legacy Document.total_cards_per_page property. Closed-Leaf check-in: 4cbe2ed14d user: thomas tags: document_command_pattern
15:05
Fix broken index validation in Document._data_page() and Document._data_card() check-in: a2b6ce3805 user: thomas tags: document_command_pattern
14:38
Fix broken index validation in Document._data_page() and Document._data_card() Closed-Leaf check-in: 87bdd98ae2 user: thomas tags: bogus
14:03
Added changelog entry check-in: a7aad73ed6 user: thomas tags: document_command_pattern
13:27
Fix reported style issues, unused imports and removed some unintended import indirections. check-in: b1d8d43247 user: thomas tags: document_command_pattern
12:29
MainWindow: Improve context menu "show toolbar" display text check-in: f65626caeb user: thomas tags: document_command_pattern
11:20
Fix reporting network errors during document load. Leverage the mechanism built into the ImageDownloader class, instead of duplicating it in the DocumentLoader class. check-in: 8eb994703a user: thomas tags: document_command_pattern
10:29
Fixed wrong PageLayoutSettings.__gt__() and PageLayoutSettings.__lt__(). check-in: cd48401a5f user: thomas tags: document_command_pattern
2023-01-18
21:51
Implement dynamic tooltips for the Undo and Redo buttons. They now show what is done when clicked. check-in: 0310166b70 user: thomas tags: document_command_pattern
18:13
Properly update the model when missing images are obtained: Document now emits dataChanged for each downloaded image. check-in: 6c79bd515d user: thomas tags: document_command_pattern
17:31
Raise exception when trying to apply an ActionLoadDocument or ActionCompactDocument twice in a row. check-in: 04a5f3444d user: thomas tags: document_command_pattern
17:25
Promote Document.set_currently_edited_page() to a public method. Unify return value annotations across all DocumentAction classes. check-in: 52de1508a5 user: thomas tags: document_command_pattern
16:54
Removed unused QueueContentTypes definition in imagedb.py check-in: 2249ecbe8e user: thomas tags: document_command_pattern
16:32
Fixed the MissingImagesManager, which is now working again. Removed the legacy Qt signals and slots in the ImageDatabase. check-in: 01e108376c user: thomas tags: document_command_pattern
15:50
Tests: Convert multiple tests in test_document.py to use the more lightweight document_light fixture. This reduces reduntant test calls and memory consumption. check-in: 56c80a1009 user: thomas tags: document_command_pattern
14:45
Document: Remove legacy methods now covered by the DocumentAction classes. check-in: 5444032705 user: thomas tags: document_command_pattern
12:29
Implement ActionImportDeckList, which is used by the deck import wizard to import a deck list into the current document. check-in: 32721192fe user: thomas tags: document_command_pattern
12:22
Fixed another crash-causing issue in CentralWidget.on_document_rows_about_to_be_removed(). check-in: b09f5ae475 user: thomas tags: document_command_pattern
2023-01-17
13:59
Fixed crash in ActionAddCard.undo(), if apply() failed to find at least one free slot on existing pages. check-in: 852faf179c user: thomas tags: document_command_pattern
2023-01-16
18:18
Add tests for ActionCompactDocument. I forgot to add the module in commit [a604438f42b50c93]. check-in: dd9a8ce878 user: thomas tags: document_command_pattern
18:15
Tests: Moved all helpers functions for document controller tests into a central helpers.py module. This unifies the helper function usage and removes redundant copies of those. check-in: 9c0ac5eb11 user: thomas tags: document_command_pattern
16:10
Refactored document loading in order to avoid race conditions causing random test failures. check-in: ecfc4e2b30 user: thomas tags: document_command_pattern
14:58
Fixed CentralWidget.on_document_rows_about_to_be_removed(). It now properly handles removal of multiple pages in one action. This is now required when undoing an ActionLoadDocument. check-in: b8bfa055d4 user: thomas tags: document_command_pattern
2023-01-13
12:00
Implemented replacing cards via ActionReplaceCard. check-in: c0eaa8654b user: thomas tags: document_command_pattern
08:07
Remove call to moveToThread() in ActionLoadDocument. This should have been removed in [d9ef79fd9ef67159]. check-in: f4f53f90c5 user: thomas tags: document_command_pattern
2023-01-11
11:39
Update dependencies: Exclude incompatible Python version 3.11.1. Require ijson 3.2 on Python >= 3.11, as ijson 3.2 supports the fast yajl2_c backend on Py 3.11. check-in: 393afd900d user: thomas tags: port_pyside6
11:38
Update dependencies: Exclude incompatible Python version 3.11.1. Require ijson 3.2 on Python >= 3.11, as ijson 3.2 supports the fast yajl2_c backend on Py 3.11. check-in: 80679a3391 user: thomas tags: trunk
2023-01-08
18:49
Use ActionAddCard to add cards to the document from the AddCardWidget. Modify the ImageDatabase to access the data via ActionAddCard instead. check-in: 4d5a2bbf65 user: thomas tags: document_command_pattern
18:46
Do not inherit DocumentAction from QObject. The base class wasn’t used at all and makes it impossible to send instances across threads. (It is not possible by design to send QObject instances across threads via Signal/Slot connections). Also use string-based type annotations for Document in more action class definitions to decrease coupling. check-in: d9ef79fd9e user: thomas tags: document_command_pattern
14:55
Implemented compacting the document via a new ActionCompactDocument. check-in: a604438f42 user: thomas tags: document_command_pattern
2023-01-07
17:00
ActionMoveCards: Fix CardContainer parent reference when moving cards across pages. check-in: 771c05ff22 user: thomas tags: document_command_pattern
13:33
Add changelog entry. check-in: 4b1bc95e19 user: thomas tags: document_command_pattern
13:21
Cleanup unused imports, added copyright headers check-in: c53c2bd37f user: thomas tags: document_command_pattern
13:09
Fixed failing test case test_undo_restores_old_page_content for ActionEditDocumentSettings check-in: 35f296eaf5 user: thomas tags: document_command_pattern
12:22
Remove Document.shuffle_document() and related helper method _get_all_card_indices(). Replaced usage with ActionShuffleDocument. Fixes [5feb35ee3d7576de] check-in: 327de0e177 user: thomas tags: document_command_pattern
12:20
Completed ActionShuffleDocument and tests check-in: 1ad17affa1 user: thomas tags: document_command_pattern
2023-01-06
14:16
Added partial implementation of ActionShuffleDocument, which shuffles the current document. check-in: ee1e0210b7 user: thomas tags: document_command_pattern
2022-12-29
21:23
Implemented ActionLoadDocument. Moved fixing mixed-size pages from Document to the DocumentLoader. The loader now uses the action to load a document after sanitizing the input data, instead of emitting a sequence of signals that procedurally reconstruct the document. check-in: 206ccb95fb user: thomas tags: document_command_pattern
20:23
ActionEditDocumentSettings has to copy the passed in page layout settings to prevent modifications via externally held references. check-in: 7051c8efec user: thomas tags: document_command_pattern
2022-12-27
21:05
Add type definition ActionList to the document action interface. check-in: b5707d9e0f user: thomas tags: document_command_pattern
20:46
Tests: Replaced some calls to deprecated Document method update_page_layout with ActionEditDocumentSettings. check-in: faa2deaee5 user: thomas tags: document_command_pattern
19:51
Directly implement __eq__() in the DocumentAction base class. Subclasses now only have to specify a list of attributes to compare, instead of implementing __eq__() in each class individually. check-in: 5033786999 user: thomas tags: document_command_pattern
19:13
Implemented ActionNewDocument that can be used to create a new document by clearing all relevant state. As this makes the "New Document" action undoable, remove the confirmation message box. check-in: a36a0e1321 user: thomas tags: document_command_pattern
2022-12-26
21:44
ActionEditDocumentSettings: Fixed issue with trailing empty pages when re-flowing larger documents. check-in: 2aef25f50f user: thomas tags: document_command_pattern
21:11
Use the ActionEditDocumentSettings action to apply changed document settings via the settings dialogs. check-in: 9c6fc3aa50 user: thomas tags: document_command_pattern
19:14
ActionAddCard.undo() and ActionRemoveCards.undo(): Clear additional state gathered during apply(). check-in: 61c6d9e513 user: thomas tags: document_command_pattern
19:06
ActionRemovePage.undo(): Clear additional state gathered in apply() check-in: 8e259db6bc user: thomas tags: document_command_pattern
18:56
Remove additional state in ActionEditDocumentSettings.undo() that was collected during apply(). This is required to be able to undo and redo the same action multiple times without accumulating invalid state transaction data. check-in: 559477a9db user: thomas tags: document_command_pattern
18:49
Document: Add deprecation warnings to several methods that are or will be covered by the new command pattern classes. check-in: 5f12a45323 user: thomas tags: document_command_pattern
15:33
Optimize the re-flow algorithm by inserting blank pages if the accumulated excess cards fill an entire page. This reduces the amount of cards moving around. check-in: 1c6f2089ad user: thomas tags: document_command_pattern
15:22
Implemented ActionEditDocumentSettings.undo() check-in: 00a84d8c54 user: thomas tags: document_command_pattern
2022-12-25
22:09
Added partial implementation of new ActionEditDocumentSettings. The action handles changing document settings, including the handling of overflowing pages, if the page capacity decreases. Implemented is apply(), undo() is still TDB. Also requires a few more test cases. Additional TODO is inserting cards at arbitrary indices in ActionMoveCards for a proper re-flow of cards. apply() currently appends cards moved to the end of the next valid page, instead of inserting them at index 0. check-in: cdfb4441a0 user: thomas tags: document_command_pattern
2022-12-24
20:48
Implemented ActionMoveCards.undo() check-in: 63dcde5242 user: thomas tags: document_command_pattern
2022-12-23
19:59
Add ActionMoveCards, which can be used to move a range of cards from one page and append it to another. Can be used as a building block for the document compacting action or for moving cards between pages via drag&drop. Currently only apply() is implemented, undo() is still TBD. Partially implements [851b0af285008db4] check-in: d84e85c5a3 user: thomas tags: document_command_pattern
19:52
Fixed style issues. check-in: 4035bdcacc user: thomas tags: document_command_pattern
2022-12-20
06:11
Tests: Fixed code warnings in test_document.py imports. check-in: 73278b3ceb user: thomas tags: document_command_pattern
06:04
Ported tests for Document.remove_cards() to ActionRemoveCards and moved them to test_action_remove_cards.py. Fixed a bug (Signal page_type_changed not properly emitted) in ActionRemoveCards.apply(). check-in: 72ee51a4c0 user: thomas tags: document_command_pattern
05:36
Tests: Removed Document tests already covered by other Action tests. Added explicit tests for Document.rowCount(), which was implicitly tested by the removed tests. check-in: a1ed7467d7 user: thomas tags: document_command_pattern
05:00
Moved several tests ported from Document.add_card() to ActionAddCard from test_document.py to test_action_add_card.py. Also ported these tests to use the lightweight document fixture. check-in: a250c487dd user: thomas tags: document_command_pattern
04:26
The Document class now keeps the rest of the redo stack if the action in apply() is equal to the top of the redo stack. Implemented __eq__() in all action classes for this. check-in: f61198f913 user: thomas tags: document_command_pattern
03:39
Tests: Replaced usage of document.add_page() with .apply(ActionNewPage()) check-in: 31fcf14882 user: thomas tags: document_command_pattern
03:38
Added docstrings to Action classes. Moved some of the existing ones from __init__ to the class, which causes them to show up in PyCharm. check-in: 1f9bc38c18 user: thomas tags: document_command_pattern
2022-12-18
22:48
Replaced calls to Document.add_card() with apply(ActionAddCard(...)) in tests. check-in: 98e5313996 user: thomas tags: document_command_pattern
18:57
PageRenderer: Fixed rendering when undoing an ActionRemoveCards action that inserts cards between already present cards. check-in: 07d4812c42 user: thomas tags: document_command_pattern
18:50
Removed commented out code from document_controller/__init__.py check-in: b2ff84876c user: thomas tags: document_command_pattern
18:39
ActionRemovePage: Fixed wrong signal values carried by rowsAboutToBeRemoved and rowsRemoved signals. check-in: 155242c8cd user: thomas tags: document_command_pattern
18:27
ActionRemovePage: Fixed bug in undo(). It now handles the case when the user requests to remove the sole page of the document and then undo that. In this case, the removal implicitly creates a new page, so that page creation has to be reverted properly, too. check-in: 756658db32 user: thomas tags: document_command_pattern
11:39
The add page and discard page buttons now use the ActionNewPage and ActionRemovePage classes to perform the actions. check-in: fdd634be11 user: thomas tags: document_command_pattern
00:03
Fixed bug in ActionRemovePage.undo(). The end parameter of the rowsAboutToBeInserted and rowsInserted signals were off by one. The unit tests now verify that the numerical values are accurate. check-in: 79b7305f92 user: thomas tags: document_command_pattern
2022-12-16
08:36
MainWindow: Added Undo and Redo actions and connected them with the Document signals and slots. check-in: b9c0efc973 user: thomas tags: document_command_pattern
2022-12-14
19:17
CentralWidget now uses the ActionRemoveCards action to remove cards when the user click on the delete selected images button. check-in: a84282ceb1 user: thomas tags: document_command_pattern
18:44
Document: Added methods apply(), undo() and redo(), and an undo stack, and a redo stack. The interface operates on DocumentAction objects. check-in: 77ede07fce user: thomas tags: document_command_pattern
2022-12-13
17:53
Implemented ActionRemoveCards. Completed ActionAddCard.undo(). check-in: d3ae301d27 user: thomas tags: document_command_pattern
2022-12-11
19:03
Added Partial implementation for the ActionAddCard class. Implementation of undo() incomplete, missing removal of cards on existing pages. check-in: 4169d7c629 user: thomas tags: document_command_pattern
14:18
ActionNewPage: Added capability to add multiple consecutive pages. check-in: 6823b1257c user: thomas tags: document_command_pattern
11:24
Fixed apply() and undo() of ActionNewPage and ActionRemovePage not returning the declared self reference. check-in: 416c8bda76 user: thomas tags: document_command_pattern
10:32
Tests: Verify that ActionRemovePage properly updates the Document.currently_edited_page attribute and emits the current_page_changed signal. check-in: 517bdd779a user: thomas tags: document_command_pattern
10:21
Fixed some code style issues check-in: 09efd131d4 user: thomas tags: document_command_pattern
2022-12-10
11:52
Started implementing a new interface for the Document model using the Command design pattern. Implemented are commands for the page addition and deletion. check-in: 92c6739c19 user: thomas tags: document_command_pattern
11:50
Fixed inaccuracy in a Document docstring. check-in: 9261dbf0d7 user: thomas tags: trunk
2022-12-07
16:39
DeckImportWizard: Simplify button access by importing the WizardButton enum into the global scope. check-in: eb9bc21d6c user: thomas tags: port_pyside6
15:02
Fixed Enum-related issues in the deck import wizard. Fixes several warnings and the broken custom button handler. Fixes [f2178716e00015ed]. check-in: 6444af6865 user: thomas tags: port_pyside6
14:43
DeckImportWizard: Added test case verifying that the selected cards removal button works as expected. check-in: 1e94b8c4c4 user: thomas tags: trunk
14:14
DeckImportWizard: Added test case verifying that the basic land removal button works as expected. check-in: 3706c2bae2 user: thomas tags: trunk
2022-12-04
22:19
Merge with trunk check-in: 33900d3fcb user: thomas tags: first_launch_wizard
2022-11-30
17:29
Pull latest changes from trunk. check-in: 51b68ca70b user: thomas tags: port_pyside6
16:35
Fixed test breakage introduced in [ac2006281bceabcd]. check-in: e0b127bf25 user: thomas tags: trunk
16:28
Unified startup one-shot tasks in one method and call it from main() between Application instantiation and entering the event loop. check-in: bf79d3e8ba user: thomas tags: trunk
2022-11-25
13:07
Moved enqueueing the update check run from the UpdateChecker class to the Application class. The UpdateChecker no longer automatically enqueues the update check when instantiated. check-in: 458e6149f9 user: thomas tags: trunk
2022-11-23
17:25
Improved wording in the update check page. check-in: b4b4ae05d2 user: thomas tags: first_launch_wizard
17:25
Increased the wizard base window size and made it application modal. check-in: 6272862ca2 user: thomas tags: first_launch_wizard
14:23
Moved call to exec_() from Application.__init__ to main(). This allows instantiating the Application class without implicitly starting the Qt event loop. check-in: 593cba511e user: thomas tags: trunk
14:16
Streamlined application exit code. check-in: ac2006281b user: thomas tags: trunk
13:40
Append "+PySide6" to the version string. This allows differentiating trunk builds on PyQt5 from PySide6 builds check-in: 91855c6e4d user: thomas tags: port_pyside6
2022-11-22
15:38
Refactored SQL in CardDatabase.translate_card_name: Don’t mix two-parameter COALESCE() and ifnull() in the same query. Instead use COALESCE() everywhere. check-in: 9f808bd38e user: thomas tags: trunk
2022-11-19
14:37
Wire up the first start wizard in the Application class. The wizard is created and shown when no configuration file is found on disk. At first start, this supercedes the individual update policy questions, and the empty database message box. This streamlines the experience, as the user is no longer bombarded with multiple message boxes at the first start. These are still present and will be shown, if the user cancels the wizard or doesn’t set values for the update policy settings. check-in: 6f13657771 user: thomas tags: first_launch_wizard
14:32
Set a window title for the first start wizard. check-in: e2b0c6c9fe user: thomas tags: first_launch_wizard
14:07
Updated an outdated message box text. The card data import no longer skips hidden printings, the given reason for unknown cards in a loaded document is thus invalid. check-in: e3014c4363 user: thomas tags: port_pyside6
14:06
Updated an outdated message box text. The card data import no longer skips hidden printings, the given reason for unknown cards in a loaded document is thus invalid. check-in: d972753adf user: thomas tags: trunk
13:51
Added option to completely disable the card data download button in the first start wizard. This can be used to prevent two concurrent card data imports, if the user uses the --card-data flag to import card data from file during the first launch. check-in: eae71df278 user: thomas tags: first_launch_wizard
13:41
Disable the card data download button on the CardDBPage on click. check-in: a2b64405ef user: thomas tags: first_launch_wizard
11:55
Fixed crash in settings._validate_documents_section(), introduced in [5b30a46b7f527230]. check-in: 914f59e986 user: thomas tags: port_pyside6
11:54
Fixed crash in settings._validate_documents_section(), introduced in [5b30a46b7f527230]. check-in: b7e2801171 user: thomas tags: trunk
11:27
Added function is_first_start() to the settings module. Returns True, if no config file is found on disk, False otherwise. check-in: c112cfdc32 user: thomas tags: first_launch_wizard
11:13
The first start wizard now writes the settings to disk on completion check-in: e5d7eac071 user: thomas tags: first_launch_wizard
10:24
Some cleanups in the UI files. Removed default window title and geometry attributes, as these are set by the parent Wizard. check-in: f41d6686b9 user: thomas tags: first_launch_wizard
2022-11-18
23:28
Partial implementation of the first launch wizard logic, including unit tests. The wizard includes the option to start downloading card data (requests that via a Qt Signal) and a page to enable automatic update checks. check-in: 1f0e8c6ff8 user: thomas tags: first_launch_wizard
2022-11-16
17:04
Updated the phrasing in the UI texts to reflect changes in the application since the original texts were written. Also named the QLabel objects. check-in: c8d66a32ad user: thomas tags: first_launch_wizard
14:06
Merge with trunk check-in: 716513007b user: thomas tags: first_launch_wizard
2022-11-13
14:55
CardDatabase: Removed all @profile decorators. Profiling the CardDatabase is now done by dynamically injecting the profile decorator by the mtg-proxy-printer-runner.py launcher, if it is run using kernprof. This improves profiling output, as only relevant profiling information is printed for each profiling task. check-in: 39a20667c8 user: thomas tags: port_pyside6
14:50
Extended some asserts in tests/ui/test_main_window.py. This ensures that methods are called the expected amount of times instead of just "multiple times" check-in: 68c796b7ef user: thomas tags: port_pyside6
14:39
Moved all parts of the parser into the CardInfoDatabaseImportWorker class. check-in: 5c31be7575 user: thomas tags: port_pyside6
13:26
CardDatabase: Removed all @profile decorators. Profiling the CardDatabase is now done by dynamically injecting the profile decorator by the mtg-proxy-printer-runner.py launcher, if it is run using kernprof. This improves profiling output, as only relevant profiling information is printed for each profiling task. check-in: d06f8940d8 user: thomas tags: trunk
12:46
Moved all parts of the parser into the CardInfoDatabaseImportWorker class. Replaced multiple try-except blocks with or-chained dict.get() calls. Inlined some one-liner helper methods that were only used in one location. check-in: 31837b34bb user: thomas tags: trunk
10:25
Simplify obtaining the bulk data json. check-in: 939769cddc user: thomas tags: trunk
10:25
Extended some asserts in tests/ui/test_main_window.py. This ensures that methods are called the expected amount of times instead of just "multiple times" check-in: cb4b7e3614 user: thomas tags: trunk
10:19
Fixed TypeError introduced in [349038acd7eb0e3d]. Closed-Leaf check-in: 242b0a3fa1 user: thomas tags: refactor_bulk_url_handling
2022-11-11
11:08
Improved comments in the DownloaderBase class check-in: f4320f9a1d user: thomas tags: refactor_bulk_url_handling
11:01
Removed the ability to choose which bulk data item is downloaded from the API. With last check-in, it became non-functional and was completely unused previously. check-in: cd4576cca4 user: thomas tags: refactor_bulk_url_handling
10:50
Simplify obtaining the bulk data url. The Scryfall API has a direct link to the required object, it is thus not neccessary to iterate over all available bulk data objects. check-in: 349038acd7 user: thomas tags: refactor_bulk_url_handling
2022-11-04
09:07
Fix benchmark script to work under kernprof again. Closed-Leaf check-in: e3621ea81e user: thomas tags: refactor_card_data_import
08:41
Moved all parts of the parser into the CardInfoDatabaseImportWorker class. Replaced multiple try-except blocks with or-chained dict.get() calls. Inlined some one-liner helper methods that were only used in one location. check-in: 000ff9229e user: thomas tags: refactor_card_data_import
2022-11-02
14:42
Improved type hinting for compile_ui_files.type_filter check-in: 1a86310acf user: thomas tags: port_pyside6
12:56
MainWindow: Removed duplicate logging line in show_card_data_update_available_message_box() check-in: 31fae97ea1 user: thomas tags: port_pyside6
2022-10-31
20:18
Release v0.20.1 check-in: a9322b9e1c user: thomas tags: port_pyside6
20:18
Fixed crash in the card data importer. It now handles double faced cards with missing back face images. check-in: f3e8e5f521 user: thomas tags: port_pyside6
2022-10-27
16:55
Fix dependencies: cx_Freeze 6.12 and 6.13 are incompatible, so enforce 6.11 for now. Edit: Enforcing 6.11 doesn’t work, as it is incompatible with required setuptools Closed-Leaf check-in: d257462be7 user: thomas tags: bogus
16:04
Release v0.20.1 check-in: 3648268240 user: thomas tags: trunk, release, v0.20.1
15:56
Add workaround for PyQt5 bug in PyQt5.uic.compileUiDir(). check-in: 8f190237b8 user: thomas tags: trunk
14:41
Fixed crash in the card data importer. It now handles double faced cards with missing back face images. check-in: 694f6c7a09 user: thomas tags: trunk
13:40
Split UIs from controller classes. check-in: 66c47e64ed user: thomas tags: trunk
13:35
Added changelog entry. Closed-Leaf check-in: 4accc062d2 user: thomas tags: backport_fixes
13:33
Split all UIs into separate ui attributes. check-in: 5ab88430b5 user: thomas tags: backport_fixes
13:24
Split Ui from controller classes for CentralWidget and AddCardWidget check-in: 1b49e37d92 user: thomas tags: backport_fixes
12:49
Refactored AddCardWidget._setup_language_combo_box(): Moved signal connections to the end, thus avoiding the need to use the BlockedSignals context manager. check-in: 2119aa47f8 user: thomas tags: backport_fixes
12:36
Simplified load_ui_from_file(): Removed ui_file local variable and use the static QFile.exists() method to determine if the given Ui file exists. check-in: d8abdf1534 user: thomas tags: backport_fixes
12:27
Move type tuple unpacking into load_ui_from_file(). This simplifies Ui type loading across the UI classes. check-in: 97d714129c user: thomas tags: backport_fixes
12:22
Rewritten how UI classes are created. Instead of merging the Ui into the controller class using multiple inheritance, instantiate the ui in a ui attribute. This is in line with how all Qt tutorials promote the usage of Qt Designer ui classes. This leads to cleaner code in cases with multiple available ui layouts, like the CentralWidget and AddCardWidget. check-in: e41d60d827 user: thomas tags: port_pyside6
12:19
Added changelog entry. Closed-Leaf check-in: f09063fca2 user: thomas tags: move_ui_to_separate_attribute
12:16
Added changelog entry Closed-Leaf check-in: d1ec770f7b user: thomas tags: bogus
12:06
Split all UIs into separate ui attributes. check-in: 272ac4c638 user: thomas tags: move_ui_to_separate_attribute
2022-10-26
17:42
Split AddCardWidget ui into a separate ui attribute. Fixed failing tests. check-in: 41f4d7bef7 user: thomas tags: move_ui_to_separate_attribute
17:26
Removed explicitly set QLayout on the CentralWidget in main_window.ui. The presence caused a Qt warning, which is now fixed. check-in: 0ba37b2dd9 user: thomas tags: move_ui_to_separate_attribute
16:37
Set the CentralWidget class as a custom type in the main window UI file. This is now possible, because CentralWidget is no longer an abstract class. check-in: a32475c483 user: thomas tags: move_ui_to_separate_attribute
16:25
Split CentralWidget ui into a separate ui attribute, following the typical handling of Qt Ui classes, instead of merging the UI into the base class via multiple inheritance check-in: d2c7fb00be user: thomas tags: move_ui_to_separate_attribute
15:54
Refactored AddCardWidget._setup_language_combo_box(): Moved signal connections to the end, thus avoiding the need to use the BlockedSignals context manager. check-in: 51ce189788 user: thomas tags: port_pyside6
2022-10-21
14:15
Simplified load_ui_from_file(): Removed ui_file local variable and use the static QFile.exists() method to determine if the given Ui file exists. check-in: 8a686eb56b user: thomas tags: port_pyside6
14:07
Move type tuple unpacking into load_ui_from_file(). This simplifies Ui type loading across the UI classes. check-in: 39c6552f3b user: thomas tags: port_pyside6
10:22
MainWindow: When handling the window close event, call accept() instead of ignore(). This seems to mitigate hanging on close when running under PyPy. check-in: 288d1720a6 user: thomas tags: port_pyside6
10:20
Fixed benchmark script when running with PyPy. Accessing an unavailable global name raises NameError, so catch that in addition to AttributeError when determining if "profile" is in the global variables. check-in: 9719214dc4 user: thomas tags: port_pyside6
10:08
AboutDialog: Simplify QByteArray to str conversion by using QByteArray.toStdString(). This fixes a crash when using PyPy. check-in: 5fb06775d6 user: thomas tags: port_pyside6
2022-10-19
10:12
Raise minimum required version of PySide6 to 6.4.0. The fix from [983f2dd2a9faed10] requires functionality implemented in 6.4.0 and crashes on lower versions. check-in: 993abfc326 user: thomas tags: port_pyside6
2022-10-18
17:04
Backported handling of UI files from the PySide6 port. UI classes are no longer generated at runtime each start using the PyQt5 ui compiler (uic). Instead, compiled builds (wheel/cx_Freeze) include them as static Python modules under mtg_proxy_printer.ui.generated* Additionally, optional type hinting stubs can be generated using the script in the scripts directory. This greatly improves type inference and also slightly decreases the application startup time. check-in: 781bdb3452 user: thomas tags: trunk
16:58
Removed most of the manual type hints spread across UI code, together with now-unused imports. These were placed to annotate attributes originating from runtime-generated Ui classes. With type hinting stubs now available, these are no longer needed and can be removed. Closed-Leaf check-in: 1303808b47 user: thomas tags: backport_new_ui_handling
16:55
Fixed generation of type hinting stubs. check-in: 228b53a8f8 user: thomas tags: backport_new_ui_handling
16:36
Simplified writing the compiled resources file in setup.py. Fixed building application bundles with cx_Freeze. check-in: b2b8dfd2f9 user: thomas tags: backport_new_ui_handling
16:18
Added script to generate Python stubs for type hinting generated Ui classes. check-in: 97e029d252 user: thomas tags: backport_new_ui_handling
15:33
The application now tries to import the UI classes from automatically generated files under mtg_proxy_printer.ui.generated.* If that fails, it loads the Ui types directly from the UI files. This required extracting the card filter widgets into a separate module to break a circular import. check-in: e75a84d49c user: thomas tags: backport_new_ui_handling
15:10
Ignore all files below mtg_proxy_printer/ui/generated. This prevents adding any generated code to the repository by accident. check-in: 7c66a44d2c user: thomas tags: backport_new_ui_handling
15:08
Extend BuildWithQtResources to also compile all UI files into Python classes. These are placed in mtg_proxy_printer.ui.generated check-in: 364e108c52 user: thomas tags: backport_new_ui_handling
12:33
Removed the UI files from the resources registry. These will no longer be included in the compiled resources blob. check-in: 93f5b38a17 user: thomas tags: backport_new_ui_handling
12:24
Fixed use of QPrinter enums in print.py check-in: e5d4e7ba2c user: thomas tags: port_pyside6
2022-10-17
16:43
Removed most of the manual type hints spread across UI code, together with now-unused imports. These were placed to annotate attributes originating from runtime-generated Ui classes. With type hinting stubs now available, these are no longer needed and can be removed. check-in: b127c42429 user: thomas tags: port_pyside6
2022-10-16
19:59
Further fixes for the cx_Freeze bundle creation check-in: 018da24fb9 user: thomas tags: port_pyside6
19:29
Simplified writing the compiled resources file in setup.py check-in: 8b1e1e9177 user: thomas tags: port_pyside6
19:23
Fixed building application bundles with cx_Freeze. check-in: bf763e0716 user: thomas tags: port_pyside6
15:30
Replaced occurrences of PyQt5 in README.md and ThirdPartyLicenses.md with PySide6. check-in: 166e6d8686 user: thomas tags: port_pyside6
14:45
Fixed packaging with PySide6. It is now possible to build working wheels that depend on PySide6. check-in: accce34d33 user: thomas tags: port_pyside6
14:22
Fixed failing test funcion test_all_resource_files_are_listed_in_resources_qrc(). check-in: 29327131ad user: thomas tags: port_pyside6
14:16
Fixed boolean property sync in PageConfigWidget. A type mismatch between the QCheckbox.stateChanged signal and the Qt.CheckState enum caused the comparisons to fail. Closed-Leaf check-in: 983f2dd2a9 user: thomas tags: pyside6_packaging
13:46
Fixed failing test funcion test_all_resource_files_are_listed_in_resources_qrc(). check-in: a73a03c4f2 user: thomas tags: pyside6_packaging
13:06
scripts/compile_ui_files.py: Fixed default paths. Create typing stubs when executed as a script. check-in: 618797d700 user: thomas tags: pyside6_packaging
12:55
Implemented generating function stubs. check-in: 76b05fbc2b user: thomas tags: pyside6_packaging
11:45
Added WIP script to generate Python stubs for type hinting generated Ui classes. check-in: bae482c47b user: thomas tags: pyside6_packaging
11:40
Ignore all files below mtg_proxy_printer/ui/generated. This prevents adding any generated code to the repository by accident. check-in: 5d96eef497 user: thomas tags: pyside6_packaging
2022-10-15
22:36
Fixed packaging for PySide6. The application now tries to import the UI classes from automatically generated files under mtg_proxy_printer.ui.generated.* If that fails, it loads the Ui types directly from the UI files. This required extracting the card filter widgets into a separate module to break a circular import. check-in: d7adce65a2 user: thomas tags: pyside6_packaging
20:48
Extend BuildWithQtResources to also compile all UI files into Python classes. These are placed in mtg_proxy_printer.ui.generated check-in: 24f5e8bb1a user: thomas tags: pyside6_packaging
18:32
Removed the UI files from the resources registry. These will no longer be included in the compiled resources blob, because the compiled UI files can’t be loaded into Python types at runtime with PySide6. check-in: 3c895a450e user: thomas tags: pyside6_packaging
18:24
Merge with trunk. check-in: 43b86cfd8d user: thomas tags: port_pyside6
10:08
README.md: Small additions. Fixes a missing letter. check-in: f70dfe3829 user: thomas tags: trunk
2022-10-11
11:03
Extended the README with the feature set and supported deck list database websites. check-in: b931e2d797 user: thomas tags: trunk
2022-10-10
18:05
Modernize metadata management: Store project metadata in pyproject.toml, complying with PEP 621. This gets rid of setup.cfg, and raises the minimum required version of setuptools to 61.0.0 check-in: 3ebf935673 user: thomas tags: trunk
2022-10-09
18:39
Release v0.20.0 check-in: b690976023 user: thomas tags: trunk, release, v0.20.0
15:03
MTGGoldfishDownloader: Implemented downloading of /archetype links, which requires downloading the website HTML to extract the deck id. Both forms, /deck and /archetype are now supported. check-in: bd7b8177af user: thomas tags: trunk
14:58
MTGGoldfishDownloader: Implemented downloading of /archetype links. Both forms, /deck and /archetype are now supported. It requires downloading the website HTML and extracting the deck id. Closed-Leaf check-in: 954fa27518 user: thomas tags: bogus
13:18
Improved type hints in MeteredSeekableHTTPFile. check-in: b4cfe4fd1e user: thomas tags: trunk
2022-10-07
13:10
Refactored the deck list import. Added automatic deck list downloads from a range of supported deck list database websites. Implements [02e1284752899685]. check-in: 9c8be86374 user: thomas tags: trunk
13:03
Added changelog entry. Closed-Leaf check-in: 7b19bdafef user: thomas tags: refactor_decklist_import
12:34
Implemented automatically selecting an appropriate parser when downloading a deck list. check-in: 3a77da68c5 user: thomas tags: refactor_decklist_import
11:09
Monkey-patch the deck list downloaded by MTGWTFDownloader to be compatible with the MTGArenaParser parser. At some point, a proper parser for the deck list format should be implemented, though. check-in: 3e3af9378d user: thomas tags: refactor_decklist_import
09:52
Hardened deck list downloader tests against changes in the returned data. The tests no longer validate the full deck list text, but rather check that the output contains the name of an expected card. check-in: a884db3309 user: thomas tags: refactor_decklist_import
09:34
Added downloader for deckstats.net check-in: 18d385b20c user: thomas tags: refactor_decklist_import
2022-10-06
19:13
Fixed MoxfieldDownloader to also include Commanders in the post-processed deck list output. check-in: 65236db7a1 user: thomas tags: refactor_decklist_import
18:50
Added a post-processing step to the deck list download process. The MoxfieldDownloader class performs a conversion to the Scryfall CSV format as the post-processing step. This allows re-using the existing ScryfallCSVParser. The other downloader classes perform the bytes to string decoding as an explicit post-processing step. check-in: aa2127a176 user: thomas tags: refactor_decklist_import
17:41
Implemented a basic downloader for Moxfield. It accesses the API and currently downloads a huge, raw JSON document. check-in: b779070786 user: thomas tags: refactor_decklist_import
17:03
Implemented a downloader for tappedout.net. check-in: cf90525dc3 user: thomas tags: refactor_decklist_import
16:35
Added test case for MTGGoldfishDownloader. Convert CRLF line endings to plain LF line endings. check-in: 9069a92bf4 user: thomas tags: refactor_decklist_import
16:11
Added test function for the deck list downloader. Added a test case for mtg.wtf and scryfall.com. These tests are skipped by default, because they do perform the actual deck list download. check-in: 45dcedd6a7 user: thomas tags: refactor_decklist_import
2022-10-04
12:58
Fixed AttributeError in scripts/benchmark_card_data_import.py. The script wasn’t properly updated during recent refactorings check-in: 0ce400c7e3 user: thomas tags: trunk
12:29
Added class CheckCard, which implements the representation of check cards. It holds two card references, the front and back side of a DFC card. Implemented rendering the check card using the split card layout. check-in: 00d729ce06 user: thomas tags: generate_check_cards
2022-10-03
10:24
Merge with trunk. Extended CardDatabase test to also verify the new Card.is_dfc attribute. check-in: e4d0ba1dec user: thomas tags: generate_check_cards
2022-10-02
19:43
Merge with trunk check-in: 2720831522 user: thomas tags: decklist_export
19:41
Merge with trunk check-in: 96c24d1c5e user: thomas tags: first_launch_wizard
19:37
Merge with trunk check-in: ac4e9794b9 user: thomas tags: refactor_decklist_import
19:35
Merge with trunk check-in: d754400762 user: thomas tags: port_pyside6
13:48
Release v0.19.0 check-in: b18efafff7 user: thomas tags: trunk, release, v0.19.0
13:29
Fix new Windows bundle bloat. Duplicates of Qt DLLs appeared in lib/PyQt5/Qt5/plugins/styles/, so remove them to keep the bundle at around 24MiB. check-in: 3f0efafbe0 user: thomas tags: trunk
13:02
Fixed broken card data import progress reporting, caused by a change in the Scryfall hosting provider. check-in: 38673e617e user: thomas tags: trunk
12:59
Fixed progress reporting when updating the card data from the Scryfall API. Progress reporting is now implemented at the card item loop level, instead of monitoring the network socket. Fixes [988923b382811b8e]. Closed-Leaf check-in: 7465c240f1 user: thomas tags: fix_data_dl_progress
10:23
Started decomposing the CardInfoDownloadWorker class into multiple, single-purpose classes. Extracted the download of raw JSON card data to file into a single class. This is done, because different operations (like import from URL and import from file) now require different styles of progress reporting. check-in: 544ef6fc29 user: thomas tags: fix_data_dl_progress
2022-10-01
23:18
Moved the code determining the available card count from the update checker BackgroundWorker class to the CardInfoDownloadWorker class. check-in: d7cf2a117c user: thomas tags: fix_data_dl_progress
22:51
Bump minimal required version of cx_Freeze to 6.11.1. This version fixes the build issues and is able to create a working bundle on Windows with recent versions of setuptools. check-in: 07d4e6a43b user: thomas tags: trunk
22:19
Add changelog entry. check-in: abb121ba20 user: thomas tags: trunk
22:15
About dialog: The homepage link is now configurable and is set to the value defined in meta_data.py check-in: ee1d6f7de7 user: thomas tags: trunk
22:14
Explicitly set a HTTP User-Agent header when requesting data via HTTP. The user agent string is dynamically constructed from the application name and version. The homepage is added as a comment value in parenthesis. This fixes Scryfall denying the data download. Fixes [4c83d35c95a3d953]. check-in: d879792bfa user: thomas tags: trunk
22:04
Removed the master repository from the mirror list in the update checker. It can’t handle much load and may be unavailable regularly. check-in: 12da947f75 user: thomas tags: trunk
21:21
Refactored CardDatabase tests. Each test for methods that create Card instances now verifies that all attributes are set correctly. Added tests for previously untested, but used methods. Removed two unused methods. check-in: a6ba8b59fa user: thomas tags: port_pyside6
21:18
Refactored CardDatabase tests. Each test for methods that create Card instances now verifies that all attributes are set correctly. Added tests for previously untested, but used methods. Removed two unused methods. check-in: 70ed7c6e19 user: thomas tags: trunk
21:12
CardDatabase.translate_card_name(): Remove the explicit source language guessing step. The query works the same without that step, so remove it as an optimization. Closed-Leaf check-in: 625e60f222 user: thomas tags: refactor_carddb_tests
19:38
Refactored 3 test functions to use the common card database filler helpers instead of performing that task manually check-in: 5f58c4016d user: thomas tags: refactor_carddb_tests
19:24
Added test for CardDatabase.get_opposing_face(). check-in: 31bdbc0185 user: thomas tags: refactor_carddb_tests
18:50
Removed CardDatabase.find_all_translated_printings() and related tests. The method was not used by any application code. check-in: 7599bc4d44 user: thomas tags: refactor_carddb_tests
18:41
Removed CardDatabase.find_all_translated_printings() and related tests. The method was not used by any application code. Closed-Leaf check-in: 039546ab70 user: thomas tags: bogus
18:35
Removed CardDatabase.is_scryfall_id_known(). The method was untested and unused in application code. check-in: d7c95b1425 user: thomas tags: refactor_carddb_tests
18:34
Fixed an incorrect type annotation. The "expected" parameter can be None, so declare it as Optional. check-in: bc35f01f38 user: thomas tags: refactor_carddb_tests
18:27
Added test function for CardDatabase.get_card_with_scryfall_id(), which was completely untested previously. It was used in tests, but was not actually verified to return correct results. check-in: 6f034e6ca2 user: thomas tags: refactor_carddb_tests
17:08
Converted two test methods into simple test parameters for other tests. check-in: d8a9c0781b user: thomas tags: refactor_carddb_tests
16:27
Removed unused data structures that were used by replaced test functions. Also fixed some PEP8 style warnings. check-in: 7fbe75c330 user: thomas tags: refactor_carddb_tests
2022-09-29
15:35
Test test__translate_card() now uses the same set of parameters as test_find_all_translated_printings(). check-in: 165f3dc03b user: thomas tags: refactor_carddb_tests
12:52
Unify tests for find_all_translated_printings(). check-in: f6e52c4e11 user: thomas tags: refactor_carddb_tests
11:52
Added module comment to tests/test_custom_hamcrest_matchers.py check-in: 3270899c02 user: thomas tags: refactor_carddb_tests
2022-09-27
19:43
Improved is_dataclass_equal_to hamcrest matcher. Refactored the code into multiple methods and re-implemented the describe_mismatch() method for better assertion messages. check-in: a842fe36cf user: thomas tags: refactor_carddb_tests
18:44
Unified tests for get_cards_from_data() into a single test function. check-in: 1de4c3ae1e user: thomas tags: refactor_carddb_tests
17:16
Added custom PyHamcrest matchers for dataclasses: Add an equal to matcher and a type annotation checker. check-in: 514ad0e415 user: thomas tags: refactor_carddb_tests
2022-09-25
14:54
Added Property is_dfc to the Card class. Updated the AllPrintings and VisiblePrintings database views to include the computation of the is_dfc property. It is a boolean that is true, if the card has two fces, false otherwise. check-in: 8cf8f12173 user: thomas tags: generate_check_cards
2022-09-23
17:35
Implemented configuring the basic land removal in the deck import wizard. It is now possible to optionally remove Wastes and Snow-Covered basic lands. check-in: 46c40d1cfd user: thomas tags: port_pyside6
2022-09-22
22:45
Implemented configuring the basic land removal in the deck import wizard. It is now possible to optionally remove Wastes and Snow-Covered basic lands. Implements [2e59bec388d8f4bd]. check-in: 263375b80f user: thomas tags: trunk
22:41
Added changelog entry. Closed-Leaf check-in: 24782576d3 user: thomas tags: configurable_deck_list_basic_land_removal
22:10
Settings window UI: Moved the preferred language selection to the first page. Re-brand the second one, because it now only contains deck import wizard options. Moved the default deck list location to the second page. Added UI options to control the basic land removal feature. check-in: d3fb3106f9 user: thomas tags: configurable_deck_list_basic_land_removal
22:05
Added setting to control the removal of Wastes and Snow-covered basic lands. Use that to control the removal in the deck import wizard. check-in: 8353f935f7 user: thomas tags: configurable_deck_list_basic_land_removal
20:38
CardListModel.remove_all_basic_lands(): Added parameters remove_wastes and remove_snow_basics. These enable to also remove Wastes and Snow basic lands, in addition to the five regular Basic lands. check-in: 42a3987744 user: thomas tags: configurable_deck_list_basic_land_removal
20:01
Tests: Fixed type warnings and a wrongly placed import check-in: 25cdd25ff4 user: thomas tags: configurable_deck_list_basic_land_removal
19:50
Tests: Unified tests for CardListModel.has_basic_lands() in a single, parametrized test function. check-in: 972cf588f6 user: thomas tags: configurable_deck_list_basic_land_removal
18:05
CardListModel.has_basic_lands(): Added parameters include_wastes and include_snow_basics. check-in: 7bf5514bfd user: thomas tags: configurable_deck_list_basic_land_removal
17:04
CardListModel: Do not cache the oracle_ids of basic lands. Query the card database each time instead. check-in: f160bec5ba user: thomas tags: configurable_deck_list_basic_land_removal
16:59
Parametrize CardDatabase.get_basic_land_oracle_ids() with two optional parameters include_wastes and include_snow_basics. These booleans toggle the inclusion of Wastes (type-less basic lands) and Snow basic lands, respectively. check-in: 93f04e9311 user: thomas tags: configurable_deck_list_basic_land_removal
16:35
Refactored CardDatabase.get_basic_land_oracle_ids() to use a parametrized query instead of hard-coding the card names in the query text. check-in: fb36b7de3a user: thomas tags: configurable_deck_list_basic_land_removal
16:29
Added test case for CardDatabase.card_db.get_basic_land_oracle_ids(). check-in: 37581eb4c7 user: thomas tags: configurable_deck_list_basic_land_removal
15:38
Added JSON samples for basic Wastes and Snow basic lands check-in: ed821d4d02 user: thomas tags: configurable_deck_list_basic_land_removal
2022-09-15
17:22
Fixed the "Browse deck list" button in the deck import wizard. The functionality was broken since reordering the wizard pages in [a8ebedda2c5aea06]. check-in: 4cfaa7cbf1 user: thomas tags: refactor_decklist_import
16:41
Implemented deck list fetcher for [https://mtg.wtf]. check-in: e9d3a34fbf user: thomas tags: refactor_decklist_import
16:39
Fixed TypeError in MeteredSeekableHTTPFile.read(), that occurred if the count argument was None. This case is now properly handled. check-in: bfb44f2132 user: thomas tags: refactor_decklist_import
15:52
Implemented automatic deck list downloads from Scryfall and MTGGoldfish. The deck import wizard now has an input field for URLs and a download button to fetch the given deck list. check-in: 24954bf2d4 user: thomas tags: refactor_decklist_import
14:52
Added unit tests for the URL RE matching. Fixed the validator so that it actually checks all registered downloader classes. Extended the MTGGoldfish RE so that it also accepts the actual download URLs. check-in: 20e4c3bd8a user: thomas tags: refactor_decklist_import
14:00
Implemented a QValidator for deck list URLs. Also fixed the MTGGoldfish RE. It no longer accepts trailing garbage at the end of the URL. check-in: d258705852 user: thomas tags: refactor_decklist_import
11:31
Reordered the deck import wizard pages: The LoadListPage is now the first page. check-in: a8ebedda2c user: thomas tags: refactor_decklist_import
09:26
Added three logging statements to the DecklistDownloader class. check-in: bcc8049edd user: thomas tags: refactor_decklist_import
09:20
Implemented downloader for MTGGoldfish.com check-in: ded52b09ba user: thomas tags: refactor_decklist_import
07:46
Added a decklist_downloader module. It can currently fetch deck lists from Scryfall. check-in: aa7f5c7021 user: thomas tags: refactor_decklist_import
2022-07-26
17:40
Fixed TypeError exception when accepting to open the application download website in the update available notification message. check-in: dcd9adc3c4 user: thomas tags: trunk
2022-07-25
14:45
Implemented drawing 90° sharp card corners. Also fixed 1 pixel card image overlap. check-in: abdf8cf018 user: thomas tags: port_pyside6
14:39
Implemented drawing 90° sharp card corners. Also fixed 1 pixel card image overlap. check-in: 87ccc737d1 user: thomas tags: trunk
14:37
Added changelog entry. Closed-Leaf check-in: 60e7187be4 user: thomas tags: draw_sharp_corners
14:28
Fixed one pixel overlap between card images when images spacing is set to zero. Also adjusted the cut marker locations to match. check-in: 3157f5704f user: thomas tags: draw_sharp_corners
13:56
Improved drawing location of corner backgrounds. check-in: d2f47751bb user: thomas tags: draw_sharp_corners
13:54
Use smooth transformation when determining the sampling area average color. This yields better results than the default fast transformation. check-in: f6c8c6fcfa user: thomas tags: draw_sharp_corners
13:27
Implemented better color sampling. The code now computes the average color of a 10x10 pixel area near the corner to determine the corner’s average color. check-in: c18211e49d user: thomas tags: draw_sharp_corners
13:26
Removed a logging line that is no longer needed. check-in: 6352043a8e user: thomas tags: draw_sharp_corners
12:59
Tuned the corner color sampling locations to be near the actual corner. This yields much better results. check-in: c226ee8d99 user: thomas tags: draw_sharp_corners
2022-07-24
17:32
Implemented rendering of sharp, 90° corners. The color sampling needs further improvements. check-in: 19012e4bf5 user: thomas tags: draw_sharp_corners
15:42
Updated save file schema version to include the new setting in the DocumentSettings table. check-in: f746c3f817 user: thomas tags: draw_sharp_corners
15:39
Add new document save schema (version 5). Forgot to add that in [cee050805b38f3bf]. Closed-Leaf check-in: 535e7f7eab user: thomas tags: bogus
2022-07-23
12:02
Updated save file schema version to include the new setting in the DocumentSettings table. check-in: cee050805b user: thomas tags: bogus
10:46
Added new setting "draw-sharp-corners" to the documents section. If enabled, this will cause the application to draw 90° sharp corners behind cards, instead of the default round ones as given by the PNG source images. check-in: 268575bfe9 user: thomas tags: draw_sharp_corners
2022-07-16
15:44
Fixes for PEP 8 style violations. check-in: 2307d15b26 user: thomas tags: port_pyside6
15:18
Fixed dependencies in setup.cfg: Replaced instance of PyQt5 with PySide6-Essentials. check-in: 5849fcf272 user: thomas tags: port_pyside6
2022-07-12
11:08
Removed unnecessary @profile decorator in the CardDatabase class. check-in: 6d37b16c2b user: thomas tags: trunk
2022-07-11
15:09
Merge with trunk. check-in: 6b5c576ef2 user: thomas tags: port_pyside6
2022-07-09
19:09
Release v0.18.0 check-in: 0f73ceb38b user: thomas tags: trunk, release, v0.18.0
16:19
Clarified a changelog entry. check-in: 0be8d6d1cf user: thomas tags: trunk
16:18
Fixed broken card image upgrade code. It immediately removed the freshly-downloaded low-resolution image, instead of storing it in the image cache. With this fix, low-resolution images are purged when a high-resolution replacement image is downloaded. check-in: 24e7f6f9e9 user: thomas tags: trunk
13:01
CentralWidget: Disable the “Remove selected” buttons, if no cards are selected. It can only be clicked, if there is something selected to delete. check-in: b3b0105df3 user: thomas tags: trunk
2022-07-08
17:46
Optimized the card database size by only storing positive printing filters. Completes [4d9d5ad8f05730a5]. See [/wiki?name=branch/carddb_optimization&p] for benchmark details. check-in: c54adb5109 user: thomas tags: trunk
17:42
Added changelog entry Closed-Leaf check-in: 98551c9879 user: thomas tags: carddb_optimization
17:30
Further optimization during card data import: Instead of deleting excess entries in PrintingDisplayFilter individually, simply clear the whole table and re-populate it. check-in: 1dc70b4ec9 user: thomas tags: carddb_optimization
16:56
Database schema: Removed duplicate release_date column in the AllPrintings view. check-in: 04f30c24ae user: thomas tags: carddb_optimization
16:52
Optimize the handling of printing filters. The database no longer stores the full cross product in the PrintingDisplayFilter table. Instead, only positive values (a filter applies to a printing) is stored. The negative case is now implied. This reduces the total table size from ~6.6 million to ~126 thousand entries. This reduces the database file size from ~230 MiB to 160 MiB. check-in: 0b50f651ab user: thomas tags: carddb_optimization
13:12
Document.save_to_disk(): Added three logging lines. check-in: 4efb66cf41 user: thomas tags: trunk
2022-07-07
18:48
Fixed an exception when a card with position greater than the number of document pages is deleted. Issue was introduced in [e7c36b589c0596a5]. check-in: 15b35e98c6 user: thomas tags: trunk
18:42
Fixed an exception when a card with position greater than the number of document pages is deleted. Issue was introduced in [e7c36b589c0596a5]. Edit: This fix was invalid. While it satisfied the added test cases, it brought back the original issue the changed method was supposed to prevent. This slipped, because I forgot to run the full test suite. Closed-Leaf check-in: 24bf9ede78 user: thomas tags: bogus
2022-07-05
11:25
Proper usage of the pint library objects: Use the magnitude property, instead of using the to_tuple() method with index access. check-in: 0c2769bea0 user: thomas tags: trunk
11:24
Removed now-unused constants in units_and_sizes.py check-in: 0b804a91eb user: thomas tags: trunk
08:07
Fixed a forgotten case that needs to be handled: Switching printings can potentially cause an image size change. check-in: 749477ecb6 user: thomas tags: trunk
08:04
Handle card size change when replacing printings. This can only happen with oversized commander cards included in older pre-constructed Commander decks. Closed-Leaf check-in: 5f30acbcd8 user: thomas tags: oversized_pages
2022-07-04
14:34
Implemented full support for oversized cards. Completes [d364c3a9c49fc685]. Regular and oversized cards are kept on dedicated pages to ensure that cut markers are 100% accurate under all circumstances. check-in: cbc3729445 user: thomas tags: trunk
14:30
Added changelog entry check-in: 09566f54fc user: thomas tags: oversized_pages
14:21
Handle loading documents that contain pages with mixed-size images. When such a document is loaded, for all mixed pages, the smaller number of each size is moved away to other pages. check-in: e7e507b7d4 user: thomas tags: oversized_pages
12:07
Remove already implemented TODO comment. check-in: c8c8346cfd user: thomas tags: oversized_pages
10:18
Increased minimal page size so that it can fit at least one oversized image. check-in: 5b30a46b7f user: thomas tags: oversized_pages
09:42
PageConfigWidget: Use functools.partial instead of lambda functions where possible. check-in: 938c740050 user: thomas tags: trunk
2022-07-03
18:58
Page overflow logic now handles oversized cards. When the page capacity decreases because of increased margins or image spacings, the overflow handler now keeps the different image sizes separate. It also triggers properly when only oversized pages overflow. check-in: 90f1a543d0 user: thomas tags: oversized_pages
16:55
Added test verifying that all page overflows are correctly identified, both for regular and oversized cards. check-in: 92a0262c19 user: thomas tags: oversized_pages
16:37
The Document class now handles updating the page layout settings internally via a setter method. Using code no longer has to set values and then call a handler method. Loading defaults also uses the same system, instead of setting the values in-place. This is a cleaner approach that facilitates further refactoring. check-in: ca2354dae7 user: thomas tags: oversized_pages
13:50
Improved page selection logic when the currently selected page is deleted. check-in: c433180455 user: thomas tags: oversized_pages
2022-07-01
12:24
Merge with trunk. check-in: ca921c13cf user: thomas tags: oversized_pages
12:21
DeckImportWizard: The “Remove selected” button now disables itself under all circumstances. Previously it was possible for it to stay active unexpectedly, when multiple cells of the same row in the card table were selected. check-in: 564ffd660c user: thomas tags: trunk
09:13
Removed unused imports. check-in: abb1cf6e0b user: thomas tags: oversized_pages
07:43
Document: Removed Qt signal total_cards_per_page_changed(int), because it was never used by application code. check-in: b0c310da01 user: thomas tags: oversized_pages
07:14
Document loader: Refactored handling of the application ID magic number and extracted it into a named constant. check-in: a0c63fe21d user: thomas tags: trunk
2022-06-30
20:23
Removed unused imports check-in: f228169ca9 user: thomas tags: oversized_pages
14:26
Document.add_card_to_page() no longer overfills empty pages with oversized cards. check-in: 19a1accc8e user: thomas tags: oversized_pages
09:23
Tests: Hide the main window in the main_window pytest fixture cleanup code. This reduces the time the main window instances stay visible. check-in: 4c36dc2803 user: thomas tags: oversized_pages
09:18
Tests: Removed the document_with_filled_card_db pytest fixture, because it was essentially the same as the document fixture. check-in: d329152779 user: thomas tags: oversized_pages
09:17
Tests: The image_db pytest fixture (and dependend fixtures like document) now has an empty oversized image. check-in: ac6fd9b792 user: thomas tags: oversized_pages
2022-06-29
19:19
Added a comment. check-in: 1fff6af9bb user: thomas tags: oversized_pages
19:10
Fixed exceptions that occurred when the document compacting removed the last page, while that was selected. Also fixed an old TODO entry and workaround the same issue that was also present when dropping the last page, while it was selected. check-in: e7c36b589c user: thomas tags: oversized_pages
19:08
Document: Simplified remove_pages() and removal of trailing empty pages in compact_pages() check-in: 30d6025179 user: thomas tags: oversized_pages
19:04
Tests: Suppress logging to stdout when tests run. This greatly removes output when tests fail. check-in: 620b357278 user: thomas tags: oversized_pages
15:01
Fixed an exception in the PageScene, if the current page is invalid, because the user created a new document. check-in: 96e3a9fc7d user: thomas tags: oversized_pages
12:58
Document.add_card() no longer produces pages with mixed image sizes. If a request would produce such a page, the offending card is moved to a fitting or new page. check-in: 3c78b5a9f6 user: thomas tags: oversized_pages
12:13
Added additional test cases that verify that the page_type_changed Signal is not emitted when the value does not change. check-in: 985810ca1c user: thomas tags: oversized_pages
11:59
Document: Added a Signal that signals when a page type changes. The PageScene uses that to redraw the pages when the type of the current page changes. Most notably, it updates the cut marker grid when an oversized card is added to an empty page or all oversized cards are removed from the currently shown page. check-in: c1017c03fe user: thomas tags: oversized_pages
09:28
Document: Use the already available method find_page_list_index(Page) instead of re-implementing the logic in three places. check-in: 396ff468de user: thomas tags: oversized_pages
2022-06-28
13:08
Refactored Document.compute_pages_saved_by_compacting() to work with oversized cards pages. check-in: d4df9d6c10 user: thomas tags: oversized_pages
12:29
Implemented image-size aware document compacting. check-in: ba069b6578 user: thomas tags: oversized_pages
11:03
PageRenderer: Fixed positioning of cards on oversized cards pages. check-in: 4c7f2835cb user: thomas tags: oversized_pages
10:56
Parametrize the page capacity computation with the image size. check-in: cf13ba99b6 user: thomas tags: oversized_pages
07:19
Renamed variables in a test to be more descriptive. check-in: 6a6ae9f709 user: thomas tags: trunk
2022-06-23
15:25
Added a comment explaining why a zoom on the page renderer clears the tooltip text. check-in: 43ef5bff29 user: thomas tags: trunk
2022-06-21
10:33
Improved display texts in the cache cleanup wizard. check-in: be22cd860f user: thomas tags: trunk
10:05
MainWindow: Replaced the display text for the action triggering the cache cleanup wizard. check-in: 7d4ad19512 user: thomas tags: trunk
07:45
Removed the page capacity computation methods in the Document class. The code now uses the methods in the PageLayout class instead. check-in: 2dec62923a user: thomas tags: oversized_pages
2022-06-20
14:36
Implemented drawing cut markers for oversized pages. Oversized images on pure oversized pages no longer overlap and have the correct cut helper lines. Page with mixed content no longer render cut helper lines. check-in: 1ac18ddefc user: thomas tags: oversized_pages
13:28
Database migration: Removed an unreachable code branch in migrate_card_database() check-in: 5247c7c648 user: thomas tags: trunk
13:15
Document: Replaced the CardList type definition with an explicit Page class derived from list. check-in: 8bfba9303c user: thomas tags: oversized_pages
13:12
Card: Added method requested_page_type() that determines on what kind of page the card should be placed (a page with regular images or oversized images) check-in: c34fd5c6dd user: thomas tags: oversized_pages
13:11
Added PageType enum that can be used to state what kind of images are present in any given Page. check-in: 4c7c15a04a user: thomas tags: oversized_pages
2022-06-14
07:56
Added size definitions for oversized cards and put both into an enum. This allows clear access by name. check-in: 9ca628ef8e user: thomas tags: oversized_pages
07:26
MainWindow: Unify handling of Message box return value check-in: 03511578a2 user: thomas tags: trunk
07:22
Unified invalid QModelIndex names across all model classes. check-in: 6e76f177e8 user: thomas tags: trunk
2022-06-13
20:20
Fixed wrong release date of version 0.16.1 in the changelog. check-in: 48ca0af902 user: thomas tags: trunk
20:00
Release v0.17.0 check-in: 1c393279dd user: thomas tags: trunk, release, v0.17.0
19:49
Dependencies: Mark cx_Freeze 6.11 and later as incompatible for now. 6.11 contains larger changes and breaks the build, so avoid it for now. check-in: d598c5a15b user: thomas tags: trunk
13:10
Merge with trunk. check-in: 4ef1007553 user: thomas tags: port_pyside6
12:39
Fixed exceptions thrown when quitting the application while an image download runs. Issue was introduced in [49bd46d6d6f8b9f7], which is part of v0.16.1 Fixes [60bae6ab1bd7ec8b]. check-in: 289fc8732f user: thomas tags: trunk
2022-06-11
11:36
Disable the action_shuffle_document QAction while batch operations run. check-in: 1ca8d36a22 user: thomas tags: trunk
11:26
Implemented shuffling the images in the document. Can be used to reduce shuffling effort required after putting the freshly cut proxies in sleeves. Implements [6927a1d3bf4d8579]. check-in: 7ed502e504 user: thomas tags: trunk
2022-06-06
15:25
Merge with trunk. check-in: 9ffe092969 user: thomas tags: decklist_export
15:25
Merge with trunk. check-in: a185c0d0ab user: thomas tags: first_launch_wizard
11:28
Fixed broken file type filters in the deck import wizard when selecting a deck list from disk. Fixes [bc48d643b1a6402c]. check-in: 784c2cecb4 user: thomas tags: trunk
11:19
Use greater than or equal when comparing the current read attempt with the retry limit. This prevents eventual infinite loops, if the attempt count or retry limit is modified somehow. check-in: dcdc7ef8a5 user: thomas tags: trunk
2022-06-05
12:56
Implemented card removal in the deck import wizard. Implements [7ef582ebb20e5078] check-in: 205501a1dc user: thomas tags: trunk
12:46
Added changelog entry. Closed-Leaf check-in: 293726d7e1 user: thomas tags: deck_import_card_removal
12:43
Implemented removing basic lands from the parsed deck list. check-in: 41217aad22 user: thomas tags: deck_import_card_removal
11:40
Removed unneccessary signal/slot connections. check-in: cb18f91e13 user: thomas tags: deck_import_card_removal
11:33
The Remove selected cards button is now disabled when no cells are selected. Also the Finish button gets disabled if the user deletes the whole deck list. check-in: 677cd32f28 user: thomas tags: deck_import_card_removal
2022-06-04
17:57
Implemented removing cards from the deck import wizard parser result table. check-in: 8b7af8ff7e user: thomas tags: deck_import_card_removal
14:45
SettingsWindow: Removed an unused method. check-in: 400a127f75 user: thomas tags: trunk
12:10
The New Document action will now ask for confirmation before replacing the current document with a new one. Implements [658bb9757a4a0c3f]. check-in: 3f87ddd8c5 user: thomas tags: trunk
11:51
Settings: Renamed section print-guessing to decklist-import, because these settings are mostly relevant to the decklist importer. check-in: 54c645ee65 user: thomas tags: trunk
11:30
Settings: Refactored section validation code by de-duplicating the section name string constant, which was referenced in multiple locations. The section name is now specified only once in each validation function. check-in: 5a1548a50b user: thomas tags: trunk
11:23
Settings: Renamed section default-save-paths to default-filesystem-paths for consistency, because it does not contain only save paths. check-in: 4eef59f38d user: thomas tags: trunk
2022-06-03
08:50
Added an RE building block button for the card language to the deck import wizard. check-in: f834dbd69a user: thomas tags: trunk
08:35
Changed the preset RE building block for the card copies to only match digits instead of any word character. Contrary to the collector number, the card count has to be numerical check-in: 3c48afca6c user: thomas tags: trunk
08:32
Added changelog entry. check-in: 4cab496ce2 user: thomas tags: trunk
08:21
Improved the custom RE deck list parser validator: It now only accepts the entered RE, if it contains a superset of any group combination that is deemed sufficient for card identification. For example, an RE matching card name and count is acceptable, but an RE only matching the set code or collector number is not. Completes [1baae7001203e833]. check-in: 42fc826d6c user: thomas tags: trunk
2022-06-02
09:54
Tests: Removed some lines from a test that are already executed by the main_window fixture. check-in: 9678370b73 user: thomas tags: trunk
09:49
Tests: Annotated a dynamically used import as not unused. If removed, pytest will fail to find the main_window fixture, so make sure it isn’t removed accidentally. check-in: e546aa9a99 user: thomas tags: trunk
09:43
Tests: Simplified the main_window pytest fixture by composing it using already defined fixtures. Removed duplicate main_window fixture in test_action_discard_page module by importing the cleaned up instance from the test_main_window module. check-in: f90800c6fd user: thomas tags: trunk
2022-05-30
13:47
Sync with trunk check-in: 0a56fd3b0e user: thomas tags: port_pyside6
13:26
Import PyQt5 signal, slot and property declarations using the PySide names. This should make it easier to keep the PySide6 port in sync. check-in: 5a1d57acd9 user: thomas tags: trunk
12:57
Tests: Prevent unwanted network access during Document tests. check-in: 882dd451d1 user: thomas tags: trunk
12:28
Properly quit background workers in test fixtures check-in: 2e7bc5026f user: thomas tags: port_pyside6
2022-05-25
09:54
DeckImportWizard: Added a bunch of buttons to the SelectDeckParserPage that insert pre-defined RE building blocks to the custom RE input field. This makes it easier to use the custom RE feature, because the user doesn’t have to type out the full RE. check-in: a993585a10 user: thomas tags: port_pyside6
09:52
DeckImportWizard: Added a bunch of buttons to the SelectDeckParserPage that insert pre-defined RE building blocks to the custom RE input field. This makes it easier to use the custom RE feature, because the user doesn’t have to type out the full RE. check-in: 8cfabfefab user: thomas tags: trunk
2022-05-24
10:53
Updated copyright years in various file headers check-in: 07725d3a24 user: thomas tags: trunk
2022-05-23
14:18
Release v0.16.1 check-in: 543ff87efa user: thomas tags: trunk, release, v0.16.1
12:35
Use the QMessageBox.StandardButton enum to access the button constants. check-in: bb6892772b user: thomas tags: port_pyside6
12:22
Replaced using exec_() with exec() to start Qt event loops. check-in: a82f44cdd0 user: thomas tags: port_pyside6
12:01
The application update checker now offers visiting the project website, if an update is available and update checks are enabled. Implements [2141db415f142789]. check-in: ff602985bc user: thomas tags: trunk
10:13
The application update checker now offers visiting the project website, if an update is available and update checks are enabled. Implements [2141db415f142789]. check-in: c42c889bae user: thomas tags: port_pyside6
2022-05-22
21:46
Incorporate various fixes and refactorings from the PySide6 port branch. check-in: 5f110eaeaf user: thomas tags: trunk
21:41
Fixed accepting the offer to download new card data does not actually perform the card data download. Added two test cases for MainWindow.ask_user_about_empty_database(). Re-written tests from test module test_action_download_card_data.py in test_main_window.py. The new tests are cleaner and cover more cases. Closed-Leaf check-in: b8bdc57f69 user: thomas tags: backport_fixes
21:34
Re-written tests from test module test_action_download_card_data.py in test_main_window.py. The new tests are cleaner and cover more cases. check-in: cba018d72b user: thomas tags: port_pyside6
21:09
Added two test cases for MainWindow.ask_user_about_empty_database(). check-in: 461be44642 user: thomas tags: port_pyside6
21:07
Fixed accepting the offer to download new card data does not actually perform the card data download. check-in: 84eeeea020 user: thomas tags: port_pyside6
20:54
Added two test cases for MainWindow.ask_user_about_empty_database(). Closed-Leaf check-in: 8fba518537 user: thomas tags: bogus
20:50
Fixed accepting the offer to download new card data does not actually perform the card data download. check-in: 261aa7593b user: thomas tags: bogus
18:25
Tests: Simplify tests for the MainWindow class by re-using an existing Pytest fixture. check-in: 5b7ba531f5 user: thomas tags: backport_fixes
18:15
Tests: Simplify tests for the MainWindow class by re-using an existing Pytest fixture. check-in: 9072c1624f user: thomas tags: port_pyside6
16:14
Refactored stop_thread() function: Moved the logger argument to the end of the parameter list and made it optional. check-in: 1de9bca8c7 user: thomas tags: backport_fixes
16:11
Use the stop_thread() function to stop QThreads in the test cleanup code. check-in: 7d7674e325 user: thomas tags: backport_fixes
16:09
Replaced the queue used for communication between the ImageDatabase and the ImageDownloader worker with Qt Signals/Slots. check-in: 49bd46d6d6 user: thomas tags: backport_fixes
15:58
Tests: Fix for the flaky ImageDatabase test. check-in: 5c0dbb719b user: thomas tags: backport_fixes
15:57
DocumentLoader.Worker: Removed incorrect signal connection. check-in: 57a8230e91 user: thomas tags: backport_fixes
15:55
Removed a superfluous signal/slot connection in the AddCardWidget class. check-in: 76e5b6c592 user: thomas tags: backport_fixes
15:50
Unified stopping of QThreads. All worker threads are now stopped using the same logic. Also properly close the ImageDownloader background worker when exiting the application. check-in: 03dd1d2b76 user: thomas tags: backport_fixes
15:45
Stop the UpdateChecker background thread, if it is still running when quitting the main event loop. check-in: 23685122d6 user: thomas tags: backport_fixes
15:44
MainWindow: Avoid calling the shutdown logic multiple times when using the --test-exit-on-launch option or the Quit action in the main window. check-in: 6d94a6f4c4 user: thomas tags: backport_fixes
15:37
Rename several methods so that they don’t match the naming schema used by QMetaObject.connectSlotsByName(). check-in: 648f4599fa user: thomas tags: backport_fixes
2022-05-21
22:53
Ported resource compilation in setup.py from PyQt5 pyrcc5 to PySide6 pyside6-rcc tool. check-in: dda2629c75 user: thomas tags: port_pyside6
22:15
Fixed that the card data download action is not properly re-enabled, if downloading fails. This fixes the remaining test failures. check-in: 6a8b9c2353 user: thomas tags: port_pyside6
17:37
Actually quit the ImageDatabase background worker when closing the application. This fixes the crash at application exit. check-in: 34781a8668 user: thomas tags: port_pyside6
09:05
Refactored stop_thread() function: Moved the logger argument to the end of the parameter list and made it optional. check-in: 6c4e1b0d6b user: thomas tags: port_pyside6
2022-05-20
20:41
Tests: Cleaned up a pytest fixture. check-in: 066ec6b7ac user: thomas tags: port_pyside6
20:36
Fixed a few failing tests check-in: 73b5a0ad4e user: thomas tags: port_pyside6
20:15
Tests: Potential fix for the flaky ImageDatabase test. check-in: 34997c8641 user: thomas tags: port_pyside6
19:59
DocumentLoader.Worker: Removed incorrect signal connection. check-in: 8d047d4a19 user: thomas tags: port_pyside6
19:52
Use the stop_thread() function to stop QThreads in the test cleanup code. check-in: 0f350ce481 user: thomas tags: port_pyside6
2022-05-19
15:26
AddCardWidget: Fixed Qt warning emitted by connecting to QPushButton.setEnabled(). The connection wasn’t needed at all, so simply removing it fixed the issue. check-in: 9e6015da37 user: thomas tags: port_pyside6
09:21
When terminating non-responding QThreads, enable termination via setTerminationEnabled() before calling terminate() on it. check-in: 338f992909 user: thomas tags: port_pyside6
09:12
Removed sip from dependencies in requirements.txt, because it is part of PyQt5. check-in: 3a3ad5834f user: thomas tags: port_pyside6
2022-05-18
20:33
Unified stopping of QThreads. All worker threads are now stopped using the same logic. check-in: 4e585b3a14 user: thomas tags: port_pyside6
19:09
Unify handling the closing of background threads. Also log each background thread that is closed when the application is closed. check-in: 9e0a31bad2 user: thomas tags: port_pyside6
18:39
Fixed printing and PDF export. check-in: e7dbe46c69 user: thomas tags: port_pyside6
18:13
Fixed signal/slot connections in the DeckImportWizard. check-in: 4859e25a31 user: thomas tags: port_pyside6
18:07
Stop the UpdateChecker background thread, if it is still running when quitting the main event loop. check-in: a7f25f37c8 user: thomas tags: port_pyside6
17:55
MainWindow: Avoid calling the shutdown logic multiple times when using the --test-exit-on-launch option or the Quit action in the main window. check-in: 61945eded8 user: thomas tags: port_pyside6
17:42
Fixed several Qt warnings “QMetaObject::connectSlotsByName: No matching signal for <method name>“ by renaming the offending methods. check-in: 931ad86592 user: thomas tags: port_pyside6
16:10
Continued porting the application to PySide6. Ported imports in the test suite and fixed a few issues reported by failing tests. check-in: 73873f2033 user: thomas tags: port_pyside6
16:09
Removed PyQt5 and related packages from the dependency lists. check-in: f7903aa5b1 user: thomas tags: port_pyside6
13:38
WIP, port ongoing. MTGProxyPrinter starts with PySide6. Some tests are failing and the application crashes when using the deck import wizard. Works: Loading UI definition from plain files, basic main window usage. check-in: 0a46ee54ae user: thomas tags: port_pyside6
12:54
Added PySide6-Essentials as a new dependency. check-in: 138c65a2d3 user: thomas tags: port_pyside6
12:21
Improve translation of cards with updated localized names. See [759dbf1f1f12a84e]. check-in: 2ac575d345 user: thomas tags: trunk
12:20
Added changelog entry Closed-Leaf check-in: dac399cd9a user: thomas tags: improve_translation_accuracy
12:17
Improved card translation accuracy when localized names were updated. Uses exact translation when context information is available. Otherwise uses the card name of the newest printing. Completes [759dbf1f1f12a84e]. check-in: 3a69dfb8a0 user: thomas tags: improve_translation_accuracy
10:23
Added the set release date to the AllPrintings and VisiblePrintings database views. check-in: fc2179f7f6 user: thomas tags: improve_translation_accuracy
2022-05-17
17:56
Enable basic dark mode rendering on Windows. Implements [a84c51b94239559c]. check-in: 2efd42fa28 user: thomas tags: trunk
17:55
Added changelog entry Closed-Leaf check-in: 727c57ecac user: thomas tags: windows_darkmode_simple
17:52
Merge with trunk. check-in: 51c91f8751 user: thomas tags: windows_darkmode_simple
17:22
Fix platform check on application start, used to enable the optional, automatic dark mode rendering on Windows. QApplication.platformName() can’t be used before the super() call, so use the platform module instead. check-in: 6e61211be5 user: thomas tags: windows_darkmode_simple
15:48
Moved all SQL statements run while saving a document into a single transaction by replacing the db.executescript() call with a series of db.execute() calls. The migration code no longer implicitly commits the transaction. check-in: 7b27a153c6 user: thomas tags: trunk
15:45
Added changelog entry. check-in: 0fb5d52928 user: thomas tags: trunk
15:45
Implemented two ways to attempt downloading missing images: When printing or exporting to PDF, the application will now automatically attempt to download any images still missing. Also added an action to the main window to manually trigger this. check-in: f125bb4b99 user: thomas tags: trunk
15:43
Use a date sentinel far in the future when adding the release_date column to the MTGSet table. Update previously added sentinel values to the new one. With commit [5127a885d28d17b4], updating from the sentinel value in the past does no longer work, so replace it with one from the future. check-in: 3debe0230c user: thomas tags: trunk
10:55
Added changelog entry. Closed-Leaf check-in: e31d3355db user: thomas tags: bogus
10:48
Implemented two ways to attempt downloading missing images: When printing or exporting to PDF, the application will now automatically attempt to download any images still missing. Also added an action to the main window to manually trigger this. check-in: 9eb5d47c07 user: thomas tags: bogus
10:36
MissingImagesManager: Only emit warnings, if there are cards with missing images left. Closed-Leaf check-in: 803aceccc0 user: thomas tags: handle_offline_state
10:36
ImageDatabase: Added get_card_list_asynchronous(). The MissingImagesManager no longer uses get_deck_asynchronous(), because it’s interface de-duplicates cards. But the code has to emit the dataChanged signals for each card instance added to the document to properly update the rendering. check-in: cd8f22df94 user: thomas tags: handle_offline_state
10:26
MissingImagesManager: on_batch_processing_runs() now sets the callback function to None after calling it, so that it doesn’t hold a reference to it indefinitely. check-in: 1e4fa512b5 user: thomas tags: handle_offline_state
10:24
MissingImagesManager: Refactored on_batch_processing_runs. It now always emits the warning signal when images are still missing, even if no callback function is given. check-in: 0f40052259 user: thomas tags: handle_offline_state
10:19
ImageDatabase: Clear any stored error messages when beginning a new batch job. check-in: 21f80f5ea6 user: thomas tags: handle_offline_state
08:17
Added an action to download missing images to the main window. check-in: 8dd9c2172f user: thomas tags: handle_offline_state
08:17
Added some logging messages to the MissingImagesManager class. check-in: db68f434ef user: thomas tags: handle_offline_state
07:33
Implemented fetching missing images when the user wants to print or export PDFs. If fetching images fails, a warning is displayed, but the action is carried out nonetheless. check-in: dbb501758f user: thomas tags: handle_offline_state
07:10
ImageDatabase: Only store the last error message, if a batch download job is running in the queue. Otherwise, the error is re-raised, if a batch job starts, right after a singular request failed. check-in: 6cfac10126 user: thomas tags: handle_offline_state
2022-05-16
13:01
Fixed Document.get_missing_image_cards(). It was broken previously, because it tried to operate on the CardContainer wrapper around the Card objects, which does not work. check-in: ec8eb5db72 user: thomas tags: handle_offline_state
12:55
Tests: document fixture now uses the image_db fixture, so that the created Document instance holds a proper ImageDatabase, instead of a MagicMock. check-in: fd6ace27aa user: thomas tags: handle_offline_state
10:12
Use a date sentinel far in the future when adding the release_date column to the MTGSet table. Update previously added sentinel values to the new one. With commit [5127a885d28d17b4], updating from the sentinel value in the past does no longer work, so replace it with one from the future. Edit: A missing comma concatenates two SQL statements, causing SQL syntax errors in the migration function. check-in: 1d1521b530 user: thomas tags: bogus
09:46
Merge with trunk. check-in: 711dc97a9a user: thomas tags: handle_offline_state
09:45
Merge with trunk. check-in: 0636c1f32b user: thomas tags: first_launch_wizard
09:44
Merge with trunk. check-in: 48cc36936f user: thomas tags: decklist_export
2022-05-13
08:56
Improved translation of deck lists using non-English card names. Fixes [53c9bcca608b8d53]. check-in: 1db0042fa6 user: thomas tags: trunk
08:51
CardDatabase: Removed unneccessary GROUP BY clause in get_card_names(). The query always filters by language and (language, card_name) is unique. Thus grouping by card_name does nothing. Closed-Leaf check-in: d816e94b64 user: thomas tags: translate_nonenglish_deck_lists
08:34
Renamed database view AllPrintings to VisiblePrintings, because the underlying query only shows visible printings. Added a new AllPrintings View that actually shows all printings. The new AllPrintings view has an additional is_visible column, showing if the printing is affected by a card filter or not. check-in: b6c4da0705 user: thomas tags: translate_nonenglish_deck_lists
06:16
Added two database indexes to speed up card translation check-in: 8ffd8e2cb2 user: thomas tags: translate_nonenglish_deck_lists
2022-05-12
16:02
Simplified the RE deck list parser implementation. It now uses CardDatabase.get_cards_from_data() to obtain printings. check-in: 9b02458ed1 user: thomas tags: translate_nonenglish_deck_lists
14:33
Only try to translate a card, if the language override is different from the parsed language. check-in: d6496ef667 user: thomas tags: translate_nonenglish_deck_lists
14:31
Renamed method _match_card to _parse_line, because that is clearer. check-in: 885bca8b7f user: thomas tags: translate_nonenglish_deck_lists
14:28
Added profiling decorators to some deck list parsing methods. check-in: 5af19a087c user: thomas tags: translate_nonenglish_deck_lists
09:26
Removed now-unused method ParserBase._translate_parsed_deck(). check-in: 8618dcceba user: thomas tags: translate_nonenglish_deck_lists
2022-05-11
13:39
CardDatabase: Use exact matching when guessing a language, because Portuguese and Spanish sometimes only differs in case. This fixes wrong results caused by using case-insensitive LIKE. check-in: 67fb401c9c user: thomas tags: translate_nonenglish_deck_lists
13:11
Fixed wrong test case function name for the MTG Arena deck list parser. check-in: aa13863d50 user: thomas tags: translate_nonenglish_deck_lists
11:24
Improved the deck list translation accuracy, when given a non-English deck list. This commit improves the results by a good amount, but there are still a few cases of unidentified cards left. See ticket [53c9bcca608b8d53]. check-in: a3fb19c031 user: thomas tags: translate_nonenglish_deck_lists
2022-05-09
15:22
Also use a temporary directory for the image database when using the --test-exit-on-launch parameter. Completes [6154e8f71f7cbd82]. check-in: a2abd09daf user: thomas tags: trunk
15:05
Do not connect to the production card database when starting the application with the --test-exit-on-launch parameter. It will create a new database in a temporary directory instead, which is cleaned up at application exit. Implements [6154e8f71f7cbd82]. Running the full test suite via tox no longer runs potentially broken and destructive database migration tasks on the production database. check-in: dbe8576da5 user: thomas tags: trunk
14:59
Supress an invalid unresolved reference error reported by PyCharm check-in: 6d91ff9c55 user: thomas tags: trunk
09:32
Replaced digit ranges [0-9] in regular expressions with \d. check-in: f0d20a29d3 user: thomas tags: trunk
09:16
Fixed code style issues. check-in: a8edf0c606 user: thomas tags: trunk
09:15
Removed unused imports check-in: 911e147611 user: thomas tags: trunk
2022-05-07
14:36
Added a hardcoded dark palette and set it at application start. It was created by dumping the values from the Breeze Dark system theme. This seems to work, except for icons and texts in the toolbar, which are still dark and thus unreadable. See ticket [a84c51b94239559c]. Closed-Leaf check-in: 94f5736911 user: thomas tags: windows_darkmode_palette
09:19
Add simple dark mode support for Windows by setting the darkmode option in the windows platform plugin to 2. The rendering is kind-of bad, but at least works and is actually dark, while dark mode is active. See ticket [a84c51b94239559c]. check-in: 8248fafcd4 user: thomas tags: windows_darkmode_simple
2022-05-06
14:02
Release v0.16.0 check-in: dd22bfe61b user: thomas tags: trunk, release, v0.16.0
10:54
Changelog: Removed trailing empty bullet point. check-in: 09acb29de4 user: thomas tags: trunk
10:51
Added changelog entries for recent fixes. Also moved some entries around and improved wordings. check-in: 55b131ab1a user: thomas tags: trunk
06:24
Re-introduce progress monitoring when importing card data from an on-disk file. check-in: 14d278a126 user: thomas tags: trunk
06:15
Re-introduce progress monitoring when importing the card data from file using the --card-data command line argument. Fixes [d4044daa7d3b6ecf]. Closed-Leaf check-in: 90dbf1cddb user: thomas tags: file_import_progress
05:56
Pulled the metered_file module back from the project history check-in: 84eed37eb3 user: thomas tags: file_import_progress
2022-05-05
14:36
CSV deck list parsers no longer crash when selecting the wrong deck list type. Fixes [f907d9e1abb1a3f4]. check-in: 1a469e0c3f user: thomas tags: trunk
09:29
Settings: Enable the print-guessing option by default. check-in: fbe81a4f39 user: thomas tags: trunk
09:28
Card data importer: search for the oldest set release date within the dataset. check-in: 5127a885d2 user: thomas tags: trunk
2022-05-04
12:53
PageRenderer: Removed a logging line from the changeEvent handler. check-in: 468ccf0b7d user: thomas tags: trunk
12:40
The deck list parser now prefers the newest, black-bordered, tournament-legal printing of cards over other printings, if it has to guess a printing. Implements [abb76278ac028c85] check-in: bbafaecd95 user: thomas tags: trunk
12:37
Added changelog entry. Closed-Leaf check-in: 28cc2c2e7f user: thomas tags: reasonable_guessed_printing_order
11:52
Fixed typo in a progress report message. check-in: 4902de2e61 user: thomas tags: trunk
11:48
Discourage selecting promotional printings, like pre-release promo cards and similar. check-in: 04b1981442 user: thomas tags: reasonable_guessed_printing_order
11:29
Increased verbosity of log messages in CardListModel._request_replacement_card(). check-in: 1ad62abd28 user: thomas tags: reasonable_guessed_printing_order
11:01
CardDatabase.get_card_from_data() now orders the result to prefer more regular, tournament-legal cards over other ones. Also prefers newer printings over older ones. check-in: 32ab225594 user: thomas tags: reasonable_guessed_printing_order
10:18
Add the set release date and wackiness score columns to the AllPrintings view. Also fix the foreign key reference in the Printing table. check-in: 7116fd990e user: thomas tags: reasonable_guessed_printing_order
2022-05-03
12:12
Fixed returning the wrong value from _get_set_wackiness_score(), caused by missing parentheses. check-in: f33864f5b4 user: thomas tags: reasonable_guessed_printing_order
11:53
Added a score to the MTGSet table that describes how desirable a printing from a given set is. Higher scores mean less desirable. Printings with highest assigned scores are art series cards and oversized cards. Regular, black-bordered, tournament legal cards have the lowest score of zero. check-in: 8036dc4e05 user: thomas tags: reasonable_guessed_printing_order
10:56
Renamed the Set table to MTGSet and the set column to set_code. This avoids the clash with the SQL keyword SET. This also increases the consistency, because it was already named set_code in the AllPrintings view and in Python code. check-in: 91f8571427 user: thomas tags: reasonable_guessed_printing_order
10:42
Include the MTG set release date in the Set table. check-in: e013b8cf74 user: thomas tags: reasonable_guessed_printing_order
2022-05-02
13:46
Settings: Implemented validation for default file paths. File paths are required to point to existing directories, because that’s the intended use. Fixes [abc20f4607b588b7]. check-in: 9236e75a2c user: thomas tags: trunk
12:16
CardDatabase.translate_card_name(): Removed unneccessarily selected columns in the outer SQL query. check-in: b56a2865e5 user: thomas tags: trunk
09:54
Added new setting to select the default deck list location in the deck import wizard. It defaults to the user’s default Downloads location, where I expect that downloaded deck lists are located. check-in: 1a5f85aacc user: thomas tags: trunk
09:07
Fixed dependencies in requirements.txt check-in: fc5aed5771 user: thomas tags: trunk
2022-05-01
11:23
Hardened the CSV deck list parsers against invalid numeral values in the card count column. check-in: 095c91c5f3 user: thomas tags: trunk
2022-04-30
20:37
Improved card translation accuracy. The card name translation can now use context information (the set code or scryfall id) to use the accurate translation in case of name clashes. If no context information is available, it uses a majority vote to avoid unexpected translation results. Part of fixing [759dbf1f1f12a84e] check-in: 8d544e0a13 user: thomas tags: trunk
2022-04-29
09:23
CardDatabase: Prefer guessing "English" when the guessed card language is ambiguous. Wrongly identifying English names as non-English is most likely caused by English placeholder names in non-English cards, so discourage selecting these as valid translations. check-in: 87fd54359d user: thomas tags: trunk
06:15
Application: Refactored creation of the SettingsWindow instance by extracting the logic into a self-contained method. check-in: 96754d7819 user: thomas tags: trunk
06:05
Show the card filter update progress in the main window, when saving the settings and card filters need to be updated. So the settings window no longer hangs without indication when saving changed card filters. check-in: 8be1970a08 user: thomas tags: trunk
06:03
CardDatabase: Added type hints for the process_signal method parameter check-in: b4b03bbfc8 user: thomas tags: trunk
2022-04-28
14:14
Enhanced some code comments in CardDatabase._update_cached_data(). check-in: 261a15750c user: thomas tags: trunk
2022-04-27
18:46
Cache cleanup wizard: Show the image tooltip only in the card name column and the scryfall id column of the unknown cards table. Show the full path in the tooltip. Implements [362cec94056a2438]. check-in: 23eba1e02c user: thomas tags: trunk
10:48
Update checker: Move the background worker to the worker thread before connecting the signals. This causes Qt to use queued signals instead of direct, synchronous method calls. The update checker now works asynchronously in the background, as intended. Fixes [ddf5c9e9a9642cfa]. check-in: 681d66872e user: thomas tags: trunk
10:34
Show a short description next to the progress bar in the main window, while a background task runs. Implements [3dc6352141ef6d44]. check-in: c8b6d1809a user: thomas tags: trunk
10:27
Implemented showing progress while the card filters are processed after the card data download finishes. This avoids "hanging" at 100% progress, while the card filters are processed. Closed-Leaf check-in: 000e68105a user: thomas tags: label_progress_bar
09:51
Added changelog entry. check-in: 5d8b906381 user: thomas tags: label_progress_bar
09:43
Added progress description when updating the internal card database using the bulk data from Scryfall. check-in: bb2905bae5 user: thomas tags: label_progress_bar
09:14
Added progress description when downloading the raw card data to a file on disk. check-in: 2aa80dbf06 user: thomas tags: label_progress_bar
09:09
Added QLabel next to the hidden progress bar in the main window status bar. Downloading card images now show a message stating which download is currently in progress. check-in: aaad3dde69 user: thomas tags: label_progress_bar
08:01
RE-Parser: Removed super() call parameters, because these aren’t needed on Python3 check-in: e923a0d2c2 user: thomas tags: trunk
2022-04-26
19:26
Magic Arena deck parser: Added support for the simple format that does not specify the exact printings. check-in: 35b515e77a user: thomas tags: trunk
15:39
Added Deck file name suffix filters to the deck list parsers. The deck list import wizard uses these to show only matching files by default. Implements [05ef57dabd588690]. check-in: 9641ba95b1 user: thomas tags: trunk
15:34
Added a file type filter for the Magic Arena deck list parser. Closed-Leaf check-in: 86f13ca346 user: thomas tags: deck_list_type_filters
15:33
Refactored how predefined lines are skipped. The GenericRegularExpressionDeckParser now skips lines based on the content of the LINES_TO_SKIP set. check-in: d05a171c8b user: thomas tags: deck_list_type_filters
13:58
Added file type filter to the Magic Online deck list parser. check-in: 270feffdb1 user: thomas tags: deck_list_type_filters
13:48
Implemented file type filters for the CSV and XMage deck list parsers. The deck import wizard sets the default filter to the one provided by the selected parser. check-in: 68c48f9b56 user: thomas tags: deck_list_type_filters
07:51
PageRenderer: Pass the QResizeEvent to the superclass implementation after handling it. check-in: 4721d1d27b user: thomas tags: trunk
07:35
Handle the QResizeEvent directly in the PageRenderer class, instead of passing it down from the main window via a Qt signal. Fixes [ebe8964ed96baeed]. Also simplifies the implementation of TabbedCentralWidget, the base CentralWidget and the main window classes. check-in: 1710efef35 user: thomas tags: trunk
2022-04-25
14:39
Optimized setting data in the CheckBoxItemDelegate class. Only update the model, if a different value is selected. This avoids finding replacement cards when not required. Fixes [833c4b141b7a0ff0]. check-in: 1946401f27 user: thomas tags: trunk
14:30
Shortened a text displayed in the deck import wizard, because it was clipped off. check-in: bf76ac35ab user: thomas tags: trunk
12:40
Moved the card database location to the user data directory. Also renamed the database file. Added a migration function that moves existing database files. Implements [4fa81b50aadf5532]. check-in: 66d2138872 user: thomas tags: trunk
07:43
PageConfigDialog: Use the Cancel button instead of the Abort button to be consistent with the Settings dialog. check-in: f547335884 user: thomas tags: trunk
2022-04-24
20:21
Ensure that the document settings dialog has button icons on Windows and other platforms without icon theme support. check-in: ea4e6f4c90 user: thomas tags: trunk
20:13
Cleaned up some project meta data check-in: 943dbd0327 user: thomas tags: trunk
18:14
Replaced the "dev extra" defining the development dependencies with a standard-conforming requirements.txt file. The scripts that create a development environment are updated to use that instead. Closed-Leaf check-in: b47fa31739 user: thomas tags: metadata_cleanup
18:13
setup.py: Removed the obsolete test_suite parameter in the setup() parameters. check-in: 12f7248c01 user: thomas tags: metadata_cleanup
17:57
Added Python 3.9 and 3.10 to the classifiers list in setup.cfg check-in: 4f3483b584 user: thomas tags: metadata_cleanup
17:31
PageRenderer: Use a ColorRole with slightly increased contrast for the backgroud brush. check-in: 549f48d6d5 user: thomas tags: trunk
17:30
Fixed an unresolved reference in PageScene.on_settings_changed(). check-in: b580fb7cc3 user: thomas tags: trunk
16:41
The PageScene now follows the system color theme, when drawing on screen. Implements [cb4a9f45451be490]. check-in: f88b2be6a4 user: thomas tags: trunk
16:40
Added changelog entry. Closed-Leaf check-in: 6882174f77 user: thomas tags: honor_theme_in_renderer
16:11
The PageRenderer now uses a color for the background brush that is based on the QPalette.AlternateBase value instead of a hard-coded medium gray. This causes the free space around the rendered page to follow the system theme. check-in: 04655c162c user: thomas tags: honor_theme_in_renderer
16:07
The PageScene now follows the system theme when drawing on screen. Replaced the draw_background boolean flag parameter with the enum-based render_mode parameter, because the values are more expressive. check-in: 3b79eecbd8 user: thomas tags: honor_theme_in_renderer
13:55
Removed render_background parameter and attribute in the PageRenderer class, because it is no longer used. check-in: 01431ea59c user: thomas tags: honor_theme_in_renderer
13:51
Directly use PageScene instead of PageRenderer to print or render PDFs. check-in: 40c0a62167 user: thomas tags: honor_theme_in_renderer
13:44
Moved on_settings_changed() and dependencies from PageRenderer to PageScene. This reduces coupling of both classes. check-in: 5bdf098604 user: thomas tags: honor_theme_in_renderer
13:11
Ensure that the ZoomDirection enum values are unique. check-in: b832d59369 user: thomas tags: trunk
11:25
Implemented zooming in the page preview renderer. Implements [94b95a98afe6394c]. check-in: ca65856db8 user: thomas tags: trunk
11:23
Added changelog entry Closed-Leaf check-in: 144f21312b user: thomas tags: zoom_page_renderer
11:14
Use a different mouse cursor while in automatic zoom mode, as a further indicator that zooming is possible. check-in: 9bcff42bb8 user: thomas tags: zoom_page_renderer
11:14
Add a tooltip explaining the zoom triggers. The tooltip is automatically removed for the application runtime, when the user triggers a zoom action. check-in: 618c143fff user: thomas tags: zoom_page_renderer
10:23
Fixed broken mouse wheel zoom. check-in: 68ee91a23c user: thomas tags: zoom_page_renderer
09:52
Implemented zooming using the default Zoom shortcuts (QKeySequence.ZoomIn and QKeySequence.ZoomOut). check-in: 713f0c6c29 user: thomas tags: zoom_page_renderer
2022-04-23
22:31
Implemented an upper bound for the scaling factor. Zoom is now limited to 16x magnification. check-in: b2a4aac2b6 user: thomas tags: zoom_page_renderer
22:18
Rewritten wheelEvent(). Enable mouse dragging while not in automatic scaling mode. check-in: 79cfe3bd89 user: thomas tags: zoom_page_renderer
22:05
Rewritten scaling logic. The page scene can now be zoomed using <Ctrl>+<Mouse Wheel>. When the complete page is visible, automatic scaling is automatically turned on. check-in: fc319331b2 user: thomas tags: zoom_page_renderer
15:27
Enable mouse dragging, if the view is not in scale-to-fit mode. check-in: 2036cf4101 user: thomas tags: zoom_page_renderer
15:06
Implemented setting the scaling in the PageRenderer. Uses the automatic scaling mode, if set to zero. check-in: 62946045ef user: thomas tags: zoom_page_renderer
11:58
Suppress the card data update check, if the card database is empty. There is a dedicated message box for this case, so don’t show both, if the card data update check is enabled. Fixes [e747db235c8cf6f7]. check-in: a0bd80b204 user: thomas tags: trunk
11:03
Improved multiple code issues in the card info downloader. Also optimize the card database schema, significantly reducing the file size on disk. check-in: 7400d249cd user: thomas tags: trunk
11:02
Test: Increased timeout for showing the printing filter widgets. 100 ms was too low and caused unexpected timeout errors. So wait up to a full second. check-in: 4af8e8309b user: thomas tags: trunk
11:00
Removed confusing and unneccessary passing of the face_ids list via parameter of _parse_single_printing(). Closed-Leaf check-in: 89b533fb7e user: thomas tags: card_info_downloader_cleanup
2022-04-22
13:39
Replaced single quotes with double quotes where possible. check-in: 47ac1b865b user: thomas tags: card_info_downloader_cleanup
13:13
Added an explicit transaction to the Document migration for schema upgrade from version 2 to 3. check-in: e4e3494a68 user: thomas tags: card_info_downloader_cleanup
13:09
Replaced uses of db.executescript(), because it implicitly executes an SQL COMMIT; statement. Begin each script with an explicit BEGIN TRANSACTION where it is still in use. check-in: d38000bd45 user: thomas tags: card_info_downloader_cleanup
12:59
Database schema: Declare table PrintingDisplayFilter as WITHOUT ROWID. This reduces database size and import time by ~33%. (From ~320MiB, 60 seconds to store the filters, down to ~200 MiB and 40 seconds.) This also halves the runtime required to compute the HiddenPrintings view. check-in: 8f9b71a0b4 user: thomas tags: card_info_downloader_cleanup
09:22
Removed _read_json_card_data_from_open_file() because it did basically nothing except renaming ijson.items() by wrapping it. check-in: 54e3a974d8 user: thomas tags: card_info_downloader_cleanup
09:17
Refactored _get_oracle_id() to avoid a warning issued by the type checker. check-in: 0d4b20a5ac user: thomas tags: card_info_downloader_cleanup
09:16
Replaced the one usage of the built-in json module with ijson. Now all json processing is done using ijson. check-in: 1451185351 user: thomas tags: card_info_downloader_cleanup
09:13
Add a button to the Debug tab in the Settings window that allows downloading the raw, compressed JSON card data array to disk. check-in: 433da6c24b user: thomas tags: trunk
2022-04-20
12:42
Implement showing cards affected by printing filters by opening a corresponting Scryfall query in the default web browser. Implements [3b4c9af6b663e0b0]. check-in: c2d70ee131 user: thomas tags: trunk
12:39
Implemented showing the banned cards for each banned card filter. Closed-Leaf check-in: d6e8c74554 user: thomas tags: view_filter_on_scryfall
11:32
Tests: Removed dumping the card database during a test run. This was used to debug a failing test case and is no longer needed. check-in: fae29fdfa4 user: thomas tags: view_filter_on_scryfall
2022-04-19
15:50
Added buttons to the GeneralPrintingFilterWidget that open a Scryfall web site search showing the cards affected by each printing filter. check-in: a8961d1c48 user: thomas tags: view_filter_on_scryfall
14:16
Removed an unused function in the card_info_downloader module. check-in: e0b7ae32e8 user: thomas tags: trunk
13:57
Implemented dynamically hiding printings. Changing the printing filters no longer requires re-downloading the card data. Implements [f2d639b535d7ce10]. check-in: 3d142c026a user: thomas tags: trunk
13:52
Reworded a changelog entry. Closed-Leaf check-in: cc764e0983 user: thomas tags: dynamically_hide_printings
13:47
Removed an SQL statement in the database migration code that was obsoleted by [28221b913635a766]. check-in: 6573a444da user: thomas tags: dynamically_hide_printings
2022-04-18
19:02
Added changelog entry. check-in: 03a13a707b user: thomas tags: dynamically_hide_printings
18:40
Inverted the printing filter storage and display. Renamed the settings section from “downloads” to “card-filter”. Renamed all settings keys from “download-XXX” to “hide-XXX”, inverting the boolean value Renamed the checkbox widgets in the Settings window. Updated the display texts. check-in: 28221b9136 user: thomas tags: dynamically_hide_printings
11:15
Added a comment to the SQL query updating the RemovedPrintings table. check-in: e53d102938 user: thomas tags: dynamically_hide_printings
2022-04-17
23:00
Reduced disk writes when updating the RemovedPrintings table by only removing or adding changed entries, instead of re-populating the whole table. check-in: 1e2e259a84 user: thomas tags: dynamically_hide_printings
22:42
Fixed broken query to update RemovedPrintings table. It only listed scryfall ids where all printings were hidden, but expected is that it contains the ids of all hidden printings. check-in: 05f14a9cb3 user: thomas tags: dynamically_hide_printings
22:18
Optimized finding replacement printings by materializing the replacement id mapping into the RemovedPrintings table. check-in: fc0137f52a user: thomas tags: dynamically_hide_printings
21:57
Restored functionality to find replacement cards for hidden or removed printings. check-in: b20e30eb98 user: thomas tags: dynamically_hide_printings
20:25
Use the new FaceName.is_hidden column, where applicable to speed up queries. The column is part of a frequently used index, so using it in queries helps reducing data set sizes earlier. check-in: d27c10ba7a user: thomas tags: dynamically_hide_printings
13:52
Added is_hidden column to the FaceName database table. This is an additional optimization to aid card name filtering. check-in: 17bdfaadce user: thomas tags: dynamically_hide_printings
13:48
Reworded Strings in the Settings window, updated to reflect that re-downloading the card data is no longer required to update the filter settings. check-in: 55b1838182 user: thomas tags: dynamically_hide_printings
13:31
Fixed wrong base class defined in UI file of class GeneralPrintingFilterWidget. check-in: e5e2fc66d0 user: thomas tags: dynamically_hide_printings
2022-04-16
23:29
Optimized CardInfoDownloader._insert_card_filters() by caching the mapping from card filter name to filter ID. check-in: 4dc0d6e452 user: thomas tags: dynamically_hide_printings
22:54
Optimized the filtering by adding a new is_hidden column to the Printing table. It caches a boolean indicating if the given Printing is hidden or not. This reduces the runtime of queries by an order of magnitude. There are still more optimizations required. check-in: 0154ca340d user: thomas tags: dynamically_hide_printings
13:12
Update/store the printing filters when connecting the card database. Also wrap the statement in a transaction. check-in: b2da226ee2 user: thomas tags: dynamically_hide_printings
13:08
Store/Update the printing filters in the database when saving the settings. check-in: 1a94f4b21f user: thomas tags: dynamically_hide_printings
2022-04-15
20:50
Implemented printing filtering for many of the remaining CardDatabase query methods. check-in: 80039748b6 user: thomas tags: dynamically_hide_printings
20:41
Removed unneccessary JOIN in view VisiblePrintLanguage. check-in: dad5ac973f user: thomas tags: dynamically_hide_printings
20:37
Implemented hiding card names of hidden printings. check-in: f99dbf8255 user: thomas tags: dynamically_hide_printings
20:18
Partially implemented hiding printings instead of removing them during the import step. Implemented: Storing all printings (except for those that have no images, because these can’t be stored in the database). Hiding all languages that only contain hidden printings. Storing which filter applies to which printing. check-in: e039ca00ff user: thomas tags: dynamically_hide_printings
20:09
Tests: Replaced the card used for test_is_removed_printing_with_removed_printing_returns_true() with a different printing. check-in: c7eaff45e7 user: thomas tags: dynamically_hide_printings
17:26
Tests: Force-disable all printing filters during testing to prevent unintended interactions. Only active filters are those explicitly requested. check-in: b9cdc75595 user: thomas tags: dynamically_hide_printings
17:22
Tests: Refactored fill_card_database_with_json_card() and fill_card_database_with_json_cards() to use a dict to specify card filter options to overwrite. check-in: 6c569bb282 user: thomas tags: dynamically_hide_printings
2022-04-14
19:52
Removed the UsedDownloadSettings database table and all related code. check-in: 9c100acc5b user: thomas tags: dynamically_hide_printings
15:49
The default document and PDF save path now defaults to the user’s local, platform dependent Documents directory. check-in: aa26891ee0 user: thomas tags: trunk
2022-04-13
17:28
Release v0.15.1 check-in: 7981960a87 user: thomas tags: trunk, release, v0.15.1
17:25
Fixed a grammar mistake in a tooltip in the Settings window. check-in: 45a2ecf47f user: thomas tags: trunk
16:19
Added changelog entry. check-in: d439bb9488 user: thomas tags: trunk
16:15
DeckImportWizard: Hardened the deck file loading logic against user mistakes. Ask the user for confirmation, when a large file (> 200KiB) is selected. Report an error, if decoding the file fails. Implements [01dd1b6ed10ede6b]. check-in: 118c8fcfad user: thomas tags: trunk
14:50
MeteredSeekableHTTPFile: Catch all types of URLError in _url_open(). This catches additional error conditions on unstable networks, increasing the reliability. check-in: 9d8f0d8797 user: thomas tags: trunk
2022-04-12
16:46
Fixed packaging again. The sdist was missing the changelog document. Thus built wheels created from the sdist package were missing the changelog in the About window and showed an empty text field. check-in: d0bed07c74 user: thomas tags: trunk
16:26
Removed unused imports. Fixed warnings reported by the linter. Mostly whitespace changes. check-in: 64b8bd7a7d user: thomas tags: trunk
16:00
Added unit tests for classes added in [d2a77a63116df798]. Completes implementation of [258843acd03b0d1b]. check-in: d30fa97ead user: thomas tags: trunk
10:36
Extracted the card download filter widgets from the SettingsWindow class into their own classes. check-in: f57b761316 user: thomas tags: trunk
10:09
Moved the settings_window.ui file into the settings_window subdirectory. Closed-Leaf check-in: 7710d8ef19 user: thomas tags: extract_card_filter_widget
10:06
Added new UI files to qresources.qrc check-in: 77479cbbb6 user: thomas tags: extract_card_filter_widget
07:27
Extracted the card filter group boxes in the settings widget and encapsulated them in dedicated classes. check-in: d2a77a6311 user: thomas tags: extract_card_filter_widget
2022-04-11
13:30
Merge with trunk. check-in: 1d814a80bc user: thomas tags: handle_offline_state
13:28
Merge with trunk. check-in: 9d6dc9332c user: thomas tags: first_launch_wizard
13:28
Added the wizard page UI files to the resource registry resources.qrc. check-in: 1b570c7ed1 user: thomas tags: first_launch_wizard
13:23
Merge with trunk. check-in: b90bfde1fa user: thomas tags: decklist_export
13:13
CardInfoDownloader: Removed LRU cache around _insert_face_name(). It had no measurable runtime benefit, yet costed around 40-50 MiB RAM during the import. check-in: aa24ed33fc user: thomas tags: trunk
09:44
Fixed multiple issues with the deck list parser and improved the GUI of the deck list import wizard. check-in: 188c68256b user: thomas tags: trunk
09:35
SummaryPage: Adjusted column widths in the deck import wizard. Widened the card name and set columns, so that longer strings fit better. Closed-Leaf check-in: 1ec5ce07f0 user: thomas tags: fix_decklist_import
2022-04-10
21:26
Fixed CardInfoDownloader.read_json_card_data(). The method was broken when used with file system paths since [122d5203e5c12be3]. The bug doesn’t affect the regular operation, only loading the JSON from disk for benchmarking purposes. check-in: 27bbcbc92f user: thomas tags: trunk
21:15
Card data and image downloads can now resume, if the network connection breaks. This enhances the reliability of downloads on flaky connections. Fixes [d8b8b6a8a43a7a7e] check-in: 3402d61161 user: thomas tags: trunk
20:10
CardInfoDownloader: Removed LRU cache around function _insert_printing(), because it did nothing. (Always having zero hits total). This saves around 150 MiB RAM during the import. check-in: 0269bb6e78 user: thomas tags: trunk
19:39
Implemented re-trying failed network requests. The card data download should now complete, even if the network connection breaks temporarily. Closed-Leaf check-in: 08f17704d6 user: thomas tags: reconnect_broken_connections
19:37
http_file.py: Removed an unused type definition. Fixed bad wording in a docstring. check-in: 4d2c677256 user: thomas tags: reconnect_broken_connections
19:36
Replaced the MeteredFile class with MeteredSeekableHTTPFile class from another project. This class implements seeking within HTTP(S) data streams, and thus can be used to re-establish a connection mid-transfer. check-in: 122d5203e5 user: thomas tags: reconnect_broken_connections
2022-04-08
12:29
TappedOutCSVParser: Optimized handling of optional boards. Now uses a set of options to test the board against, instead of a series of boolean conditions. check-in: 483a6ed9d2 user: thomas tags: fix_decklist_import
06:27
Removed two debug logging lines that were added previously to reduce log clutter. check-in: cd99094c24 user: thomas tags: fix_decklist_import
06:09
Fixed bug in the ParserBase class that caused an unneccessary deck translation step, even if translation is disabled. Fixes [c9283f04b63fd898]. check-in: 6c1d6f3c13 user: thomas tags: fix_decklist_import
2022-04-07
20:17
Added changelog entry. check-in: 81e9764744 user: thomas tags: fix_decklist_import
20:15
Merge with trunk. check-in: 00b5d33dbb user: thomas tags: fix_decklist_import
20:13
Fixed Scryfall CSV deck list parser to work better when printings are removed by download filters. The affected printings are now replaced, where possible. Implements [15fc6ee2e2631057]. check-in: d443a10d68 user: thomas tags: fix_decklist_import
14:09
Tests: Refactored assert_model_is_empty() to also check RemovedPrintings if no test case data object is passed in. check-in: ca1c2adcea user: thomas tags: fix_decklist_import
2022-04-06
09:55
Tests: Added assert statements to image_db fixture to verify cleanup code works as intended. check-in: 560204a0b1 user: thomas tags: fix_decklist_import
09:54
Tests: Moved image_db pytest fixture to conftest.py to make it available globally. check-in: 639989bdeb user: thomas tags: fix_decklist_import
09:42
CardDatabase: Rename _get_card_form_data() to _get_cards_from_data, because it can return multiple cards. check-in: bab4ecd380 user: thomas tags: fix_decklist_import
2022-04-05
16:00
Added changelog entry. check-in: 86a944417c user: thomas tags: trunk
13:38
Improved UI of the image cache cleanup wizard. check-in: 1d0576c5f1 user: thomas tags: trunk
13:34
CardFilterPage: Remove the vertical header in both tables. It doesn’t do anything useful for the user, so remove it to make more space for relevant data. Closed-Leaf check-in: b29642d98e user: thomas tags: improve_cache_cleanup_wizard
13:19
CardFilterPage: Reworked the UI layout to use a QSplitter to separate the two tables. This allows the user to re-size the tables. check-in: b77830b1e4 user: thomas tags: improve_cache_cleanup_wizard
12:46
Increase the default wizard size to 1024x786, because the previous default value was way too small. check-in: 5762e12e32 user: thomas tags: improve_cache_cleanup_wizard
12:35
Adjust the column widths to better fit the content. check-in: d412736ada user: thomas tags: improve_cache_cleanup_wizard
12:09
CardFilterPage: Hide the Scryfall ID column for known cards. This property doesn’t hold much value for the user. check-in: 2fe383f655 user: thomas tags: improve_cache_cleanup_wizard
12:03
Refactored the CardFilterPage __init__ method by extracting two setup methods. check-in: 02b6eb8468 user: thomas tags: improve_cache_cleanup_wizard
2022-04-04
20:15
Changed CardDatabase.is_removed_printing() to return the oracle_id or None instead. It can still be used as a boolean, but the result is now more useful in general. check-in: 5d2bdaf56a user: thomas tags: fix_decklist_import
19:51
CardDatabase: Added method is_removed_printing(scryfall_id). It returns True, if the given scryfall id belongs to a known-removed printing. check-in: 24fd696697 user: thomas tags: fix_decklist_import
19:49
CardDatabase: Added @profile decorator to all potentially expensive methods. By default it does nothing, but is implicitly replaced with a real profiling function when the application is run using kernprof. check-in: 61c1418a20 user: thomas tags: fix_decklist_import
16:34
Add tests to validate the content of mtg_proxy_printer/resources/resources.qrc check-in: 88e51d7771 user: thomas tags: trunk
16:33
Converted line endings of run_tests.bat script to Windows-native CRLF style. check-in: 2d965e5bef user: thomas tags: trunk
14:25
Benchmark script: Add method CardInfoDownloadWorker._parse_single_printing() to the measured functions. check-in: cecb6c6160 user: thomas tags: trunk
13:42
Test the resource file registry resources.qrc. Implements [cd3d553b7abf099d]. Closed-Leaf check-in: b71a681306 user: thomas tags: test_resources
2022-04-03
18:43
Release v0.15.0 check-in: 9078e65f80 user: thomas tags: trunk, release, v0.15.0
17:19
The DeckImportWizard now has button icons on Windows. The FinishRole button icon and tooltip is updated, depending whether the user wants to replace the document or append the deck list. The oversized card warning takes precedence over this. Added changelog entries. check-in: b9c0942530 user: thomas tags: trunk
17:18
AddCardWidget: Added icons to the buttons inside the ButtonBox, if the buttons don’t have icons on the current platform. check-in: 3b155c1e38 user: thomas tags: trunk
13:07
Improved the Settings window: Better grouping of relevant settings. Set button icons on Windows. Add a button to open a file manager at the log file location. check-in: de67946148 user: thomas tags: trunk
12:57
Fixed opening the log directory on Windows platform. Closed-Leaf check-in: 62ff1cf535 user: thomas tags: settings_revamp
11:54
Added icons edit-undo and edit-redo to the internal icon theme. Also set the Reset button icon in the settings window, if not set. check-in: 86d79415b2 user: thomas tags: settings_revamp
11:29
Set icons on buttons in the Settings window button box, if none are set. check-in: e154c055cd user: thomas tags: settings_revamp
11:27
Added icon document-revert to the internal icon theme. check-in: 95d2adf5fd user: thomas tags: settings_revamp
11:01
Tests: Explicitly disable writing the log file to disk when running the unit tests. Otherwise repeated runs of the unit test suite can write hundreds of megabytes of log messages to disk. check-in: 6028bc3f3c user: thomas tags: trunk
11:00
Added a push button to the debug settings that opens the log directory in the default file manager. This allows the user to easily browse the log files written to disk. check-in: 3f6a06fc35 user: thomas tags: settings_revamp
10:04
Renamed some of the layout objects to have names matching their container widget. check-in: bb4e23d08c user: thomas tags: settings_revamp
10:00
Removed the ”avoid low resolution images” option. Nothing was implemented using it and the option was disabled in the settings, so remove it. check-in: 977bf739c1 user: thomas tags: settings_revamp
09:56
Re-purposed the almost empty second tab to host all printing selection related settings. So moved the settings from the “Image selection” group box on the “General” page there. check-in: 8f329e486c user: thomas tags: settings_revamp
09:12
Added a vertical spacer to the card_database_page.ui to keep the text label from stretching out. check-in: 3c19324201 user: thomas tags: first_launch_wizard
2022-04-01
12:53
When loading a document containing prinings unavailable due to enabled download filters, the document loader will now try to replace them with available printings, if possible. A card without available printings (maybe removed by the funny/silver bordered card filter) will still be removed from the document. But as long as there is at least one printing available that does not fall under a download filter, the removed printing will be replaced. The logic prefers the card’s original language, then falls back to the user’s configured preferred language, then English, then any other language. Implements [132473390d0c40e7]. check-in: 2b2a292c42 user: thomas tags: trunk
2022-03-31
22:47
Added changelog entry. Closed-Leaf check-in: 14f3d2ecd1 user: thomas tags: replace_filtered_printings
22:39
Implemented replacing filtered printings when loading a document. The main window shows a message box, if printings are replaced. Implements [132473390d0c40e7]. check-in: d009c3a232 user: thomas tags: replace_filtered_printings
20:14
CardDatabase.get_cards_from_data(): The language attribute in the card identification data parameter is now optional. check-in: 05974f19e7 user: thomas tags: replace_filtered_printings
18:06
Also store the language of filtered out printings in the RemovedPrintings table. The language is required to keep the language when migrating unknown printings to known printings. Without this field, the source language is unknown, as the scryfall id by itself does not contain the information. check-in: c78b05cb93 user: thomas tags: replace_filtered_printings
17:44
CentralWidget: Adjusted labels in the Grouped CentralWidget layout to fill all spaces in the layout grid. check-in: 560f8c094d user: thomas tags: trunk
17:34
Remove the margins around the horizontal AddCardWidget layout. Because it is embedded in a layout that has margins on it’s own, the previous value of 6 pixels caused double wide margins around it. With margins set to zero, the borders of widgets in the CentralWidget and widgets in the AddCardWidget are flush. check-in: 5c403321c9 user: thomas tags: trunk
17:28
Revert adjustments to the CentralWidget layout margins to improve rendering. These explicit adjustments are no longer neccessary. check-in: 0d88451e2e user: thomas tags: trunk
16:48
Fixed crash in the card data importer, if the same card is excluded in multiple, consecutive imports. Fixed by adding an ON CONFLICT clause to the SQL statement failing. check-in: fb0ee659c8 user: thomas tags: replace_filtered_printings
16:36
Refactored tests: Verify that CardInfoDownloadWorker.populate_database() does not emit error signals. To do so, add the qtbot parameter that expects a QtBot instance passed down from calling code. Added the qtbot fixture parameter to all test functions using this indirectly. check-in: d0a91d4332 user: thomas tags: replace_filtered_printings
15:45
Clean up the RemovedPrintings table when an import finishes: Delete all entries of cards that were not filtered out during the last data import. check-in: e5666bf702 user: thomas tags: replace_filtered_printings
15:31
When importing card data, store the scryfall_id and oracle_id of all skipped printings in a separate table. Edit: This commit also reverts adjustments to the CentralWidget layout margins to improve rendering. This should have gone into a separate commit, but I forgot to actually commit it. check-in: 0cedd36fd4 user: thomas tags: replace_filtered_printings
10:22
Fixed potential IndexError, if card identification using exact matching fails in _translate_card(). check-in: 9b2684b029 user: thomas tags: decklist_export
10:19
Added a TODO entry that outlines missing handling of some edge cases. check-in: 0cdc619f37 user: thomas tags: decklist_export
2022-03-30
21:12
Specify tox as a requirement in the README.md file. check-in: 322840b0e9 user: thomas tags: trunk
18:53
Improvements and bug fixes for the deck list import wizard. check-in: 1e4ed9b97c user: thomas tags: trunk
18:37
The sort order in the deck list import wizard is now retained in the document. Closed-Leaf check-in: d9a49867d2 user: thomas tags: improve_import_wizard
18:36
The card list table containing the parser result in the deck import wizard can now be sorted. This currently has no impact on the order the cards are added to the document. Implements [936300cf85992ede]. check-in: dcf6fa6fa2 user: thomas tags: improve_import_wizard
2022-03-29
19:47
Fixed broken Generic RE deck list parser. The GUI created the parser when the option was selected, which was too early, because by then no RE was entered in the input field. Now the parsers are created when the user clicks the Next button. At that time, all data is available. Fixes [7f4ef75e36effbad]. check-in: ab2bdfd2bf user: thomas tags: improve_import_wizard
17:17
The deck import wizard now disables the Finish button, if the deck list entered contains exactly zero identified cards. check-in: 80f1f5fc00 user: thomas tags: improve_import_wizard
15:55
Tests: Extract DeckImportWizard setup code into a separate function. check-in: e9beca5348 user: thomas tags: improve_import_wizard
13:36
Improved sorting behaviour in the cache cleanup wizard, when sorting by collector number. The sorting now uses natural sorting, which is the expected sorting mode for mostly numerical data. Fixes [a96e4879fe993a4e]. check-in: c859cd013a user: thomas tags: trunk
09:49
Marked the settings window as modal. Being non-modal enables the user to trigger a card data download while a document is loading, so prevent that. Steps to trigger that: Open settings window and change a download filter. Then load a document or import a deck list. During loading process accept the settings dialog and accept the offer to re-download the card data. Doing so will at least break the progress bar in the status bar, so use window modality to enforce serialization of actions. check-in: dc2491f75d user: thomas tags: trunk
09:44
Reworded some strings in the Settings window. Also added a label explaining when update checks are performed. check-in: 6d4b20179f user: thomas tags: trunk
2022-03-28
15:23
Merge with trunk check-in: 9be01dc352 user: thomas tags: decklist_export
15:20
Merge with trunk check-in: 94c3491ae2 user: thomas tags: first_launch_wizard
14:58
Merge with trunk check-in: 912b5c3409 user: thomas tags: handle_offline_state
13:03
Adjusted the column widths of the page card table view: Widen the card name and set name columns, because these are a bit too small to fit the content. check-in: d49e4917c3 user: thomas tags: trunk
13:01
Adjusted the horizontal scaling weights in the columnar central widget UI for better space usage. check-in: 5c5e541246 user: thomas tags: trunk
2022-03-27
20:02
Changelog: Changed wording for recent entries. check-in: d229d76d94 user: thomas tags: trunk
19:54
Extracted the central part of the main window into a new class CentralWidget. It is available in multiple variants, one for each GUI layout. The MainWindow class definition is no longer programmatically dependent on the settings. Instead, it uses a specialized CentralWidget subclass based on the settings to show the main window content. check-in: d634e19dc4 user: thomas tags: trunk
19:48
Added changelog entry for the newly added tabular GUI layout. Closed-Leaf check-in: b8c4b61eb2 user: thomas tags: gui_layout_rework
19:28
Tests: All unit tests instantiating MainWindow instances now do this using all available CentralWidget subclasses. check-in: 3130bf8d22 user: thomas tags: gui_layout_rework
19:27
Fixed central_widget.py __all__ definition. check-in: 2b437e02c9 user: thomas tags: gui_layout_rework
16:33
TabbedVerticalCentralWidget: Properly scale the page renderer when it’s tab is activated to fill the available space. check-in: e5721d3fc8 user: thomas tags: gui_layout_rework
15:47
Change the default CentralWidget layout to the columnar layout. check-in: a77aa807b2 user: thomas tags: gui_layout_rework
15:45
Rename the central widget setting key from "search-widget-layout" to "central-widget-layout". Add migration code that migrates the old settings key to the new one. Replaced the string constant used for the columnar layout ("vertical") with "columnar". check-in: 60956a2444 user: thomas tags: gui_layout_rework
15:16
Made the CentralWidget layout configurable again. The ability to configure the layout was lost in early commits of this branch and is now restored. check-in: 8cc9ede516 user: thomas tags: gui_layout_rework
15:03
Fixed CentralWidgetTypes type definition in central_widget.py check-in: 5bb2dd9a6d user: thomas tags: gui_layout_rework
14:57
Implemented the GroupedCentralWidget class as a subclass of CentralWidget. This variant is optimized for taller screens with an aspect ratio of about 3:2 or 4:3. check-in: 9e2f0da1d8 user: thomas tags: gui_layout_rework
14:34
Refactored the definition of the AddCardWidget class. Now a subclass is created for each layout available. Also moved the individual UI files into a dedicated directory. check-in: 0e9a86fc06 user: thomas tags: gui_layout_rework
14:11
Rename CentralWidget subclass FlatVerticalCentralWidget to ColumnarCentralWidget, because that name is more fitting. check-in: 6b3121ea73 user: thomas tags: gui_layout_rework
2022-03-16
16:44
Added comments to the carddb_migrations module. check-in: f1c7b75732 user: thomas tags: trunk
16:24
Renamed module carddb_helpers.py to carddb_migrations.py, because it only contains the database schema update/migration code. The new name is more expressive than the previous generic “helpers”. check-in: 30f5f560db user: thomas tags: trunk
15:25
Cleaned up some test code and comments check-in: a630aac22b user: thomas tags: trunk
2022-03-15
16:07
Fixed wrong initial tab selection in the settings window. The dialog should show the first tab when opened, not the forth. Issue was introduced in [8298a649b2358e56]. check-in: 83730d8ad1 user: thomas tags: trunk
16:04
Tests: Added a short delay, because a file-system touching test for the image database seems to be flaky. check-in: d690b17488 user: thomas tags: trunk
14:37
Added new card download filter to optionally exclude all digital printings. Related to ticket [fc610234c6cf052b]. check-in: 8298a649b2 user: thomas tags: trunk
12:44
Experimental prototype for dynamic layout adjustments based on the main window aspect ratio. The code is quite buggy: Widgets break and lose internal state when a re-layout is triggered. Closed-Leaf check-in: b3729491f1 user: thomas tags: gui_layout_rework
2022-03-10
14:09
SaveDocumentAsDialog: Unified __init__ parameter order to be in line with the rest of the dialogs. check-in: 1faa266a9a user: thomas tags: trunk
2022-03-09
14:14
PageRenderer: Removed logging of resize events. check-in: 9a17429de2 user: thomas tags: gui_layout_rework
2022-03-08
13:23
ImageDatabase: Remove empty parent directories when deleting images from the disk cache. Implements [6cd37f6b3b8e12e3]. check-in: 8136e80eea user: thomas tags: trunk
2022-03-07
22:56
ComboBoxItemDelegate: Use the MTGSet.data() method to format the display of MTG sets shown in the combo box editor. check-in: 269341970a user: thomas tags: gui_layout_rework
21:59
MainWindow: Removed return values of 3 methods, because the returned booleans weren’t used by the calling code. check-in: 7c2e7ee8e2 user: thomas tags: gui_layout_rework
19:38
central_widget.py: Fixed definition of __all__. check-in: 6f4b1eacc5 user: thomas tags: gui_layout_rework
19:03
Merge changes from trunk. check-in: 4696b20e8a user: thomas tags: gui_layout_rework
13:14
Add unit test runner script for Windows OS. check-in: 218e27a676 user: thomas tags: trunk
13:06
Mitigate segmentation faults on Windows when running the test suite by not using the offscreen QPA plugin when the unit tests run on Windows OS. Fixes [5ac7571f6834bde5]. check-in: 94d84595a5 user: thomas tags: trunk
13:04
ImageDatabase: extracted logic to remove outdated low-resolution images into a separate method. check-in: 4e9b31fd18 user: thomas tags: trunk
2022-03-03
20:52
ImageDatabase: Implemented method to properly close the background worker thread. Tests: Properly close the background worker thread created in each test run that creates an ImageDatabase instance. check-in: 6bba756cee user: thomas tags: trunk
12:04
cx_Freeze bundle test now uses a dedicated command line switch to make it work on Windows. Previous attempt didn’t work, because the standard output channel is closed and inaccessible in built executables. Implements [ed0ca8f8581300e0] check-in: ce470889d5 user: thomas tags: trunk
2022-03-02
23:52
Implemented new command line option --test-exit-on-launch that quits MTGProxyPrinter immediately after the Qt event loop starts. This is used for the integration test that tests the cx_Freeze bundle creation. Closed-Leaf check-in: 1ae315340f user: thomas tags: fix_bundle_test_on_windows
14:39
Fixed typo in the changelog. check-in: 1909822822 user: thomas tags: trunk
14:38
Added changelog entry for feature merged in [532d8b0ba0b4301a]. check-in: 1d9cdc4b3b user: thomas tags: trunk
13:57
Dependencies: Also exclude setuptools 60.8.0. Version 60.8.1 fixed the issue causing build failures. check-in: 9d199a7d40 user: thomas tags: trunk
13:45
Fixed dependencies: Mark incompatibility with setuptools 60.7.*, as these break the application build. Raise PyHamcrest minimum version to 2.0.0 for unit tests, as these use the contains_exactly() matcher without the backwards compatibility fix applied in the main application package. check-in: 26ad8dd8cb user: thomas tags: trunk
13:14
Implemented ordering card prints by usage count when the option to prefer already downloaded images is enabled. Implements [57aee48cb1ad29a6]. check-in: 532d8b0ba0 user: thomas tags: trunk
12:07
Implemented preferring cards with higher usage count when translating cards while preferring already downloaded images is enabled. Closed-Leaf check-in: 4ac7f6da6b user: thomas tags: smarter_print_selection
2022-02-23
21:24
Deck list parser: Implemented the smarter printing choices for plain print guessing, without translations. In any ambiguous situation that can return a list of matches, order them by print count, if already downloaded images should be preferred. check-in: ce9aba6e6f user: thomas tags: smarter_print_selection
20:05
Reworded a recent changelog entry. Also re-formatted an entry that exceeded the 120 character line length limit. check-in: 4d912b915f user: thomas tags: trunk
19:57
Added some comments explaining a few constructs. Added docstrings to some classes and methods. check-in: e2b2bc6aaf user: thomas tags: trunk
18:27
CardDatabase: Added flag parameter order_by print_count to method get_cards_from_data(). If set to True, the method orders the returned cards by the recorded print count, preferring cards that were used more often over cards used less often. This way, printing choices done by the user affect the print guessing of future documents in a way that MTGProxyPrinter will automatically choose printings used more often, even if multiple choices are already in the image cache. check-in: 017d32597d user: thomas tags: smarter_print_selection
2022-02-22
22:20
CardDatabase: Expanded and re-worded some comments for better clarity. check-in: cf61eeb9a1 user: thomas tags: trunk
2022-02-19
20:37
Fixed MANIFEST.in. The Document save file SQL schema wasn’t present in built wheels, because it doesn’t match the old include directive. check-in: 36bb7964c2 user: thomas tags: trunk
15:02
README: Fixed Dependency listing. check-in: 103b74954d user: thomas tags: trunk
14:50
Settings: Fix a grammar mistake. check-in: 69b69371db user: thomas tags: trunk
14:49
Settings window: State that changing the Debug settings require an application restart. check-in: 44aff375d7 user: thomas tags: trunk
14:46
Fixed a typo in the Settings window. Re-phrased the tooltip for “funny” cards. check-in: afb11ab336 user: thomas tags: trunk
14:29
Decoupled the PageScene image position computation from the global settings. It now uses the document settings of the current document to compute the scaling factor. This fixed broken rendering if the paper dimensions of the current document differ from the default values in the settings. Fixes [5986392c187e1669]. check-in: e6b46b82c9 user: thomas tags: trunk
10:42
Implemented storing and loading document settings in the document save file. These are now part of the save file format. Implemented an editor dialog to allow the user to change these settings for the current document, without altering the default values in the global settings. Implements [a1f87d610c3eb32c]. check-in: 8475e2daf2 user: thomas tags: trunk
10:32
Added changelog entry. Closed-Leaf check-in: 0dfdb89438 user: thomas tags: store_size_in_document
10:30
PageConfigDialog: Implemented the Reset and RestoreDefaults buttons. The Reset button resets the changes to the values from the document. The RestoreDefaults button resets the changes to the values from the global configuration, reverting any changes loaded from the document itself. check-in: ac15fddcb6 user: thomas tags: store_size_in_document
00:33
Implemented setting the document settings for individual documents. Added a new action to the main window. When triggered, it shows a dialog window that allows setting all document settings for the given document. check-in: 83176dd25a user: thomas tags: store_size_in_document
2022-02-18
22:22
PageConfigWidget: Reordered signal connection order of signals defined in the UI file. check-in: fb4ee8a4b6 user: thomas tags: store_size_in_document
22:20
Added test that verifies handling of invalid saves that contain infinite document settings rows. check-in: fcdee4cf16 user: thomas tags: store_size_in_document
14:30
Tests: Improved test function naming check-in: b89f321ff9 user: thomas tags: store_size_in_document
14:29
Tests: Added tests to verify PageConfigWidget.save_document_settings_to_config() check-in: bfa8b2ab93 user: thomas tags: store_size_in_document
13:31
Tests: Improved tests for the PageConfigWidget. Properly test loading of values from the configuration file. check-in: 5c652a8864 user: thomas tags: store_size_in_document
2022-02-17
19:37
Fixed PageConfigWidget._get_document_settings_widgets(), .save_document_settings_to_config() and .load_document_settings_from_config() check-in: 4f0248e298 user: thomas tags: store_size_in_document
16:49
Unified the widget names in the PageConfigWidget class and the attributes in the PageLayoutSettings class. Added tests that verify the correct association of widgets with their corresponding attributes in PageLayoutSettings. check-in: a434216ad4 user: thomas tags: store_size_in_document
14:14
Disable the action added in [b1c8d63ad459b70b] during the document loading state. The action can cause a change in the page capacity, so has to be disabled while loading. check-in: ccaaabc7a8 user: thomas tags: store_size_in_document
13:50
Added a new Edit Document Settings QAction to the main window. Added a new icon to the integrated icon theme. check-in: b1c8d63ad4 user: thomas tags: store_size_in_document
11:11
Simplified ImageDatabase.blank_image property. Use functools.lru_cache instead of manually implementing the caching logic in the class. check-in: af1d5a68f5 user: thomas tags: trunk
11:01
Added docstrings to methods in the ImageDatabase class. check-in: d36a362c08 user: thomas tags: trunk
11:00
Simpified a conditional statement in the deck list parser ParserBase class. Also added a docstring. check-in: 3f37bbbc5b user: thomas tags: trunk
2022-02-16
22:55
Added changelog entry. check-in: c6d7563052 user: thomas tags: store_size_in_document
22:11
Fixed Settings window layout. The PDF split option was unintentionally split across two lines. The spinbox widget should be right of the label, not below it. check-in: e953941688 user: thomas tags: store_size_in_document
22:02
DeckImportWizard: Mention that card printing in the parsing result can be changed by double-clicking the appropriate cells in the table. check-in: e2873b6642 user: thomas tags: trunk
21:23
Properly update the stored Document settings when saving the document multiple times. check-in: 31d7432fc5 user: thomas tags: store_size_in_document
21:04
Update the PageScene when the document settings change. check-in: 6b437af328 user: thomas tags: store_size_in_document
20:34
Reset document settings to the default values when creating a new document, after a document with custom settings was loaded. check-in: 8bbc04314d user: thomas tags: store_size_in_document
20:01
Implemented loading document settings from save files. Moved the constants defined in the Document class into a separate module to reduce circular dependencies. For the same reason, moved the PageLayoutSettings into the document_loader module. The DocumentLoader class verifies the syntactical and semantical correctness of loaded document settings and updates the Document instance. Extracted the required update logic in the Document class into a separate method, so that it is directly callable by the DocumentLoader class. check-in: 3a77ab89b3 user: thomas tags: store_size_in_document
16:26
Implemented loading card data from document version 4. check-in: 281fbd65c1 user: thomas tags: store_size_in_document
16:19
Fixed and unified the tests for the DocumentLoader class, that are testing the protection against type errors in the stored data. check-in: 767de12d8c user: thomas tags: store_size_in_document
15:37
Implemented storing the document page settings in the save file. Also fixed the migration code for document version 2 to 3. It is now 100% accurate, so that it passes the strict validation implemented previously. check-in: 9eb212d4d6 user: thomas tags: store_size_in_document
15:33
Fixed invalid docstring in the DocumentLoader class. check-in: 7ca59e0d4e user: thomas tags: store_size_in_document
15:32
Fixed __all__ declaration in sqlite_helpers.py module. check-in: 7247340b27 user: thomas tags: store_size_in_document
2022-02-15
23:19
Added preliminary Version 4 of the Save file format. check-in: a8d0c92c63 user: thomas tags: store_size_in_document
22:57
Added some docstrings to the PageRenderer and PageScene classes. check-in: f1a9b12860 user: thomas tags: trunk
22:35
Added docstrings to classes in the current_page_view.py module. check-in: 8870380ce4 user: thomas tags: trunk
21:42
Extracted the QGroupBox containing the page layout settings into a separate class PageConfigWidget. check-in: 060a779fdc user: thomas tags: store_size_in_document
18:55
Relocated the PDF split option in the Settings window. Also added a few more tooltips. check-in: 3a67f09d7e user: thomas tags: trunk
13:08
Compatibility fix with PyHamcrest < 1.10. Versions below did not have contains_exactly() matcher. So use the semantically same contains() matcher, if running with versions below 1.10. check-in: d4bedd3ad1 user: thomas tags: trunk
12:22
Renamed method Document.find_overflowing_and_underflowing_pages() to find_overflowing_and_non_full_pages(). check-in: e09e17412c user: thomas tags: trunk
11:12
Fixed reported style and grammar issues. Cleaned up unused imports. check-in: abe4bdb417 user: thomas tags: trunk
10:48
Added changelog entry for recent changes. check-in: 722ac51328 user: thomas tags: trunk
2022-02-14
22:01
Validate loaded save files. The merged branch adds protection against invalid data types in the save file. It also adds protection against Denial of Service attacks via recursive CTEs, by validating the database schema against the known-good as shipped by the program. Validation is performed before the current document is cleared, so implements [fe20b1ba06570b55] check-in: 7a1445cb50 user: thomas tags: trunk
21:57
Tests: Increased timeouts from 10 or 100 ms to 1000ms. Otherwise, these tests may be flaky on slow CPUs, as the processing may actually take that much time. Closed-Leaf check-in: c59891c78e user: thomas tags: harden_document_loader
21:51
Show the failure reason to the user, if loading a save fails completely. This is done by adding a string reason parameter to the loading_file_failed signal. check-in: f6ece9bcab user: thomas tags: harden_document_loader
21:41
Moved the DocumentLoader class from the document.py module into its own module document_loader.py. check-in: ecde294e76 user: thomas tags: harden_document_loader
21:24
Added a docstring. Minor re-formatting (whitespace only) check-in: 22c186b6a4 user: thomas tags: harden_document_loader
20:49
Implemented Document save file schema validation. This re-uses code previously used in schema migration test code. To be able to test old save files, the application now also ships the version 2 of the document schema. check-in: ba2301d29e user: thomas tags: harden_document_loader
20:46
Added SQLite helper function dedicated to creating in-memory databases. check-in: af3673e1fb user: thomas tags: harden_document_loader
11:13
Renamed the document database schema: Appended the version number to the file name. check-in: 6cf53971ed user: thomas tags: harden_document_loader
2022-02-13
23:06
Fixed pytest fixture document_with_filled_card_db. The fixture now cleans up the potentially running background thread. This prevents crashes in Qt code. check-in: 1123b9ccf1 user: thomas tags: harden_document_loader
22:32
DocumentLoader: Validate data loaded from save files for consistency. This uses PyHamcrest to test the data types and range constraints, as defined in the "document" database schema. check-in: c520c6987e user: thomas tags: harden_document_loader
22:27
Dependencies: Added PyHamcrest to the main project dependencies. check-in: 74d6cad7bf user: thomas tags: harden_document_loader
22:25
Tests: Fixed empty_save_database() pytest fixture. The database connections created by it have to be accessible across different threads. check-in: 86776a3a21 user: thomas tags: harden_document_loader
22:23
Tests: cleaned up _create_save_file(temp_path) function that creates a save file for testing purposes. check-in: 976cb4a0ba user: thomas tags: harden_document_loader
20:02
Set minimal required version of pytest-qt to 2.0. check-in: 846147e4aa user: thomas tags: harden_document_loader
2022-02-12
23:11
Explicitly state the sort order for the page number when reading the data from database. check-in: 972a1c8191 user: thomas tags: harden_document_loader
23:11
Raise an exception, if the save file contains an unknown schema version number. check-in: 97e22fa2ae user: thomas tags: harden_document_loader
23:08
Added pytest fixture that creates in-memory databases with the document save file schema. check-in: 18d8b69dfe user: thomas tags: harden_document_loader
2022-02-11
18:16
Also ignore SQLite databases using the .db file extension. check-in: fd35f66396 user: thomas tags: trunk
17:52
Fixed issue [16dde0674c7a78da]. If the card data download aborts due to network issues, the action is enabled again to allow the user to re-try. check-in: 86f750ba92 user: thomas tags: trunk
2022-02-10
20:59
Ignore the .tox directory created by tox. check-in: c8072f9f96 user: thomas tags: trunk
20:58
Use tox to run unit tests and create redistributable packages. Implements [607b716419748de2]. check-in: a3dd69736b user: thomas tags: trunk
2022-02-06
21:47
Removed the wheel creation script and renamed the build scripts for Windows and Linux (again). Closed-Leaf check-in: b79e7e7142 user: thomas tags: use_tox_for_building
21:47
Enable Python dev mode when running unit tests via tox. check-in: f8b0893a48 user: thomas tags: use_tox_for_building
21:21
Fixed issue with tox config that prevented execution of platform-specific build commands. check-in: 4d78a74682 user: thomas tags: use_tox_for_building
21:00
Moved the import benchmark script into the scripts directory. check-in: ac6b5243fc user: thomas tags: use_tox_for_building
20:59
Moved the clean_windows_build.bat script into a new scripts directory. Use tox to create cx_Freeze bundles and other redistributable packages. check-in: cab9e58a5a user: thomas tags: use_tox_for_building
2022-02-05
23:13
Modified the testenv sections to have two dealing with bundle creation. One that tests if the build runs and one that builds the MSI package on windows. This seems neccessary, because the bdist_msi command doesn’t allow specifying the input data and the dynamically created path inside the build directory can’t be specified in the tox configuration. So split it in two passes. check-in: 1dc7c724cd user: thomas tags: use_tox_for_building
23:10
Refactored bundle creation on Windows. Instead of modifying the site-packages, only the final build is cleaned up after it is built. check-in: d6850bf311 user: thomas tags: use_tox_for_building
12:14
Refactored the tox configuration into multiple [testenv] sections. The app bundle creation environment is now platform-aware. Also added an optional section to run the unit tests with display of GUI widgets under test. check-in: 3f53371457 user: thomas tags: use_tox_for_building
2022-02-04
20:24
Use tox to verify that the application bundle created using cx_Freeze works. It only performs a basic plausibility test by running the built executable with the --version option to test if the executable runs at all. check-in: 9d9a5d9a78 user: thomas tags: trunk
2022-01-22
22:19
Release v0.14.2 check-in: 5c5f564c5a user: thomas tags: trunk, release, v0.14.2
22:08
setup.cfg: Do not include the Qt5 UI files and icons in compiled wheels, because these files are already included in a compiled form. The wheel started to include them since [55af59f1bf459fa6]. That commit fixed sdist packages by including these resources, which seemed to have also affected the wheel build process. check-in: 68492ce1aa user: thomas tags: trunk
21:29
setup.cfg: Replaced deprecated keyword license_file with new and supported license_files. Also include the third party licenses document in builds. check-in: 40dcba5996 user: thomas tags: trunk
15:53
Prepare release v0.14.2 check-in: f111813c31 user: thomas tags: trunk
14:35
Fixed issues with cards that store the oracle_id in the card_faces, instead of the card object itself. check-in: 741706d9ac user: thomas tags: trunk
14:27
Simplified code of CardDatabase.get_opposing_face() check-in: 7c56c0cbc8 user: thomas tags: trunk
14:25
Implemented fix for cards that contain the oracle_id in an object inside the card_faces array, instead of the top-level card object. It is now possible to successfully import recent card data again. Closed-Leaf check-in: 0dfabbf9b4 user: thomas tags: handle_missing_oracle_id
14:14
Handle parser errors by catching occurring exceptions and notifying the user. New changes to the Scryfall API apparently made the oracle_id property of cards optional at the top-level of card objects. This change catches any error and reports it to the user, instead of crashing the application. check-in: 0520f0c454 user: thomas tags: handle_missing_oracle_id
2021-12-28
18:31
Added configuration section for tox in pyproject.yaml. This allows running the test suite with multiple Python interpreters by simply running the "tox" command. It is currently configured to run the tests under CPython 3.8, 3.9 and 3.10. check-in: cac5b8ad3e user: thomas tags: trunk
11:52
Fixed generating sdist packages by including the resources directory in MANIFEST.in check-in: 55af59f1bf user: thomas tags: trunk
2021-10-08
21:22
MainWindow: Replaced on_action_compact_document_triggered() with directly connecting the document instance compact_pages() method. check-in: 4768e5803c user: thomas tags: trunk
13:35
Merge changes from trunk. check-in: 828a3d598c user: thomas tags: gui_layout_rework
2021-10-01
13:31
Tests: Refactored test_translate_card__card_attribute_is_oversized() into test__translate_card() and test all attributes of the returned Card object. Closed-Leaf check-in: 54ef14484c user: thomas tags: unify_carddb_tests
2021-09-29
16:24
Release v0.14.1 check-in: 9755a77878 user: thomas tags: trunk, release, v0.14.1
16:07
Fixed broken image cache cleanup for low resolution images, if the card database entry for that printing states that it is a high resolution image. Now, the front/back and resolution booleans read from the image database take precedence over the same values read from the card database. Fixes [9bc5f12d0e0445c9]. check-in: d89795a6c3 user: thomas tags: trunk
15:43
CardDatabase: Fixed wrong type in Card.highres_image boolean flag. It was set to a 0/1 integer instead of a proper boolean. check-in: 27d02112b3 user: thomas tags: trunk
14:28
Tests: Simplify mock image creation in test_main_window.py by re-using the blank image QPixmap present in the ImageDatabase instance. check-in: 4e353d40cf user: thomas tags: trunk
14:19
CacheCleanupWizard: Allow instantiation of KnownCardImageModel and UnknownCardImageModel classes by defaulting to None for the parent __init__ parameter. This brings it in line with other Qt classes. check-in: 19d60719b4 user: thomas tags: trunk
2021-09-27
14:29
MainWindow: Reworded the card data update message box, replacing the "card" with "printing" in the message text. The number includes all new international printings and not unique cards, thus using "card" is misleading. check-in: 543a1d6afa user: thomas tags: trunk
14:25
Reworked how CardDatabase migration scripts are stored. Added tests that verify the behavior of migration script _migrate_21_to_22() both with and without network access. check-in: eeaff8c22d user: thomas tags: trunk
2021-09-26
10:35
Tests: Create the mock card image in a different directory. The previous location clashed with the mocked image database root path, causing the image to be overwritten by itself unintendedly. check-in: 81d5a4064c user: thomas tags: trunk
10:29
Tests: Verify the indices of migrated card databases by comparing them against a database created from the newest schema version. check-in: 342c12d1e6 user: thomas tags: trunk
2021-09-25
19:39
Removed online requirement for the card database migration from 21 to 22. If the additional data required can not be fetched from the Scryfall API, a dummy value will be used instead. check-in: 39e83860d1 user: thomas tags: trunk
19:07
Added changelog entry check-in: 512021ecbb user: thomas tags: trunk
19:02
Fixed bug that caused the progress bar to stay indefinitely, if loading a document caused an image download. check-in: e751e653a1 user: thomas tags: trunk
18:15
Decoupled the ImageDownloader and CardInfoDownloadWorker classes. These two now share a common base class to share Internet access code, instead of creating a CardInfoDownloadWorker instance inside the ImageDownloader class. check-in: 94ce535035 user: thomas tags: trunk
13:36
Set SQLite PRAGMA trusted_schema = OFF when creating database connections. This is recommended, as per [https://www.sqlite.org/pragma.html#pragma_trusted_schema]. check-in: f810b7298d user: thomas tags: trunk
12:56
Tests: Verify the column definitions (except for CHECK constraints) of a migrated database by checking against a database created from the newest schema. check-in: 24cb2f28e9 user: thomas tags: trunk
11:54
Tests: Extended test_migrate_card_database() to also verify the presence of all expected database tables, indices and views. check-in: 787d14d32f user: thomas tags: trunk
10:50
Removed unused method from tests/helpers.py. check-in: 30e436cbd2 user: thomas tags: trunk
10:49
Added changelog entry. check-in: 206a4b220b user: thomas tags: trunk
10:43
Added test for the card database schema migration code. The test itself currently only tests that the user_version field in the database is correctly set to the current version after the migrations ran. Extracted the code that reads the current schema version from package data into it’s own function for re-use in test code. Fixed bugs in migration from schema version 9 to 10 that got introduced in [d9f19a90941aabaf] and [3981a5b6f5605014]. check-in: db0032466a user: thomas tags: trunk
2021-09-24
14:52
CardDatabase: Added test for get_total_cards_in_last_update(). check-in: b5c92bc748 user: thomas tags: trunk
14:41
Fix invalid SQL created in the last commit. check-in: a2cfa1ae3c user: thomas tags: trunk
14:40
CardInfoDownloader: Simplify storing the LastDatabaseUpdate. Make use of the fact that the update_timestamp column defaults to the CURRENT TIMESTAMP, if no value is provided. check-in: 67eba381fd user: thomas tags: trunk
12:09
CardDatabase: Simplify allow_updating_card_data(). Added tests for this method. check-in: 7d5bb67c04 user: thomas tags: trunk
11:13
CardDatabase: Added docstrings to the class definition and to __init__(). check-in: 36c9a5df89 user: thomas tags: trunk
2021-09-23
20:38
Release v0.14.0 check-in: c78be94107 user: thomas tags: trunk, release, v0.14.0
20:22
Improved changelog. Added latest changes. check-in: 971d5c0168 user: thomas tags: trunk
20:15
Further optimized the Windows bundle size. It is now down to ~ 24 MiB. Removed the (older) copy of OpenSSL that is shipped with PyQt5, keeping the newer version shipped with Python. Also remove all DLLs in the build directory lib/PyQt5. These are all duplicates created by cx_Freeze. check-in: 881cbd7d3d user: thomas tags: trunk
19:50
Reduce Windows bundle size by manually deleting duplicate python*.dll files from the created build. check-in: dc67f0dfff user: thomas tags: trunk
19:00
Fix Windows app bundle creation, which is apparently broken due to updates in PyQt5. Also try to battle the increased bundle size, which went up from 32 MiB to 42 MiB. Additional optimizations cut that back down to about 37 MiB. check-in: 51103b9c1e user: thomas tags: trunk
17:46
Specify SQLite 3.35.0 as the minimum required version, because that is the first version to support RETURNING, which is used by the card info downloader. check-in: 6ab08d67e7 user: thomas tags: trunk
16:19
Improve the accuracy of the Scryfall card data update checker. check-in: 282c1ce080 user: thomas tags: trunk
16:18
Added changelog entry. Closed-Leaf check-in: 0342899bbc user: thomas tags: improve_card_data_update_checker
16:16
Reworked the card data update checker. During the import, the card data importer stores the total number of items encountered. The Updater asks the API for all cards since 1970-01-01, including all extras and stuff, to get the total number of items currently available in the remote database. It then compares the reported number of results with the last stored item count to determine if new cards are available. This approach seems to yield accurate results. check-in: 2b5e8cdf2e user: thomas tags: improve_card_data_update_checker
12:00
Use the "release_date" attribute, instead of the "previewed_at" attribute, if the release date is in the past. check-in: fd4c964d1c user: thomas tags: improve_card_data_update_checker
11:15
CardDatabase: Fixed bug in check_if_download_settings_changed() causing the application start to fail. check-in: 6c11717d66 user: thomas tags: trunk
10:55
CardDatabase: Added comments to multi-line SQL statements that specify the containing method. Some already had these comments. They are useful to map SQL statements in an SQL dump to their origin. check-in: 455f4653bc user: thomas tags: trunk
10:44
Unified handling of multi-line SQL statements. All multi-line statements now use triple-quoted strings combined with textwrap.dedent() and an LRU cache to only perform the dedent operation once per runtime. Exception: The migration code does not cache the dedent result, because it is only ever executed once per installation. check-in: 3981a5b6f5 user: thomas tags: trunk
10:29
Tests: Merged fill_card_database_with_json_card() into fill_card_database_with_json_cards() to de-duplicate code. check-in: 5875dea015 user: thomas tags: trunk
2021-09-22
17:33
Split the multi card JSON document in the test data into individual card JSON documents. Removed the helper method that was used to load it. This approach makes it easier to compose a library with certain printings to test. The previous approach was difficult to extend, because adding a card to a multi-card JSON required to change multiple tests. check-in: 38acd005ca user: thomas tags: trunk
17:15
Fixed style issues and unused imports. check-in: 75b7c0978b user: thomas tags: trunk
16:38
CardInfoDownloader: Fixed removal of printings missing in the input data. Now, all printings that should be skipped or are completely missing in the input data are properly removed from the database. This required some restructuring of test code that relied on incremental updates not removing previously inserted data. I consider the previous behavior to be a bug, because it retained information not present in the last imported card data. The test data gained a helper that allows the import of multiple, individual cards from distinct JSON documents, so that it does not have to rely on incremental database updates. check-in: 18042525a9 user: thomas tags: trunk
2021-09-21
15:11
CardDatabase: Fixed potential issues with Card.is_front holding an integer instead of the annotated boolean value. check-in: 27d2b8e75f user: thomas tags: trunk
2021-09-18
15:14
Implemented importing/updating the card database from a downloaded Scryfall bulk data export file. check-in: 25e72025b7 user: thomas tags: trunk
15:08
Implemented importing card data via command line arguments. Also only perform the online card update check only if the user does not import card data via a local file. Closed-Leaf check-in: 8d17705ea7 user: thomas tags: update_card_db_from_bulk_data_file
13:52
Reworked how the update card data QAction is connected. It is no longer handled by a slot in the MainWindow class. check-in: db734871df user: thomas tags: update_card_db_from_bulk_data_file
13:34
Moved the CardInfoDownloader instance from MainWindow to Application class. check-in: b129bad08a user: thomas tags: update_card_db_from_bulk_data_file
13:20
Argument parser: Added command line argument that takes a file system path to a Scryfall bulk data export JSON file. check-in: 4bdc27b9df user: thomas tags: update_card_db_from_bulk_data_file
13:12
Improved benchmark script: It can now automatically handle functools.lru_cache()-wrapped functions. It is no longer required to manually handle them in a special way. check-in: 9812357409 user: thomas tags: trunk
12:47
CardInfoDownloader: Fixed returning the number of imported cards in _populate_database() when cancelling the import process. check-in: 9d69a18417 user: thomas tags: trunk
2021-09-16
09:56
Added changelog entry for [b8606bc47052277c]. check-in: 6f13b24ac3 user: thomas tags: trunk
09:52
Handle a locked database and other error conditions during the card data download process. The database exceptions are caught and the user is notified via a message box. The application now also properly leaves the "busy with background operation" state and clears the LRU caches, in case the error occurs somewhere in the middle of the import process. Fixes [b8606bc47052277c]. check-in: 99a8812648 user: thomas tags: trunk
2021-09-15
15:40
Updated the README.md file. check-in: e5fa5978be user: thomas tags: trunk
14:28
Fix for wrong card translation for multi-faced cards. check-in: 6c274bf500 user: thomas tags: trunk
14:26
Fixed wrong card translations for cards having multiple names, like double-faced cards or split cards. Previously a translation request for a back face returned the translated front face. Fixes [28dbd8181e64a3c2]. Closed-Leaf check-in: ddea2913d3 user: thomas tags: fix_multi_faced_card_translation
13:20
Database: Added face_number column to the CardFace table. This column enumerates the faces of each printing. Because the card faces have the same ordering across multiple reprints and languages for each card, this can be used to match a specific card face name across multiple languages. check-in: 86668efe66 user: thomas tags: fix_multi_faced_card_translation
2021-09-13
19:24
Implemented warning the user if they import oversized cards in the deck list import wizard. check-in: b1c66d334c user: thomas tags: trunk
19:07
DeckImportWizard: Fixed bug in print selection logic: The wizard ignored any edits done to the card list model and emitted the deck as received from the parser. Added unit test and changelog entry. This feature was broken since it got introduced in [1793b7eb83cebfa4]. Closed-Leaf check-in: 32db8d56ee user: thomas tags: display_oversized_cards
16:18
Card: Excluded fields image_uri, highres_image and is_oversized from the automatically generated __eq__() function. These are not neccessary to perform a card comparison. check-in: 70c65e7b2c user: thomas tags: display_oversized_cards
16:10
DeckImportWizard: Implemented a QMessageBox that asks the user if they want to continue, if oversized cards are found in the deck list. It is triggered when the user hits the "Finish" button. If the user declines, they can continue to edit the deck list. check-in: b997be06be user: thomas tags: display_oversized_cards
15:43
Added changelog entry. check-in: 2f062a18ce user: thomas tags: display_oversized_cards
15:23
DeckImportWizard: Set a warning icon and tooltip on the FinishButton, if there are oversized cards in the card list. This gives a second visual clue, even if the oversized card is currently not visible in the table, because of the scrolling position. check-in: a9ab879a45 user: thomas tags: display_oversized_cards
14:30
CardListModel: Added attribute oversized_card_count that tracks the number of oversized cards stored in the model instance. Added Qt signal oversized_card_count_changed(int) that is sent when the value changes. check-in: fb8d7d71a4 user: thomas tags: display_oversized_cards
14:01
CardDatabase: Fixed storing wrong type in Card.is_oversized. It should contain a boolean, but was set to an int. check-in: fb33213d10 user: thomas tags: display_oversized_cards
11:59
CardListModel: Add a tooltip and icon to rows containing oversized cards. This will show in the deck import wizard ui to warn the user about potentially unwanted oversized cards. check-in: a5ac80a527 user: thomas tags: display_oversized_cards
11:52
Added icon data-warning to the internal icon theme. check-in: 83aad0f2a0 user: thomas tags: display_oversized_cards
11:37
Fixed database performance regression introduced in [86d41f7e72149046]. It affected the cache cleanup wizard, which took several seconds to load card information for a few hundred images. This is now back to a couple of milliseconds. check-in: 9272975900 user: thomas tags: display_oversized_cards
2021-09-12
23:10
Added test cases that verify that Card.is_oversized is correctly set when creating Card instances. check-in: 406966cdee user: thomas tags: display_oversized_cards
22:40
Cleaned up the test code: Card databases are now created with a shared pytest fixture named "card_db" and located in tests/conftest.py. The fixture creates empty CardDatabase instances in two variants: Once with default SELECT behavior and once with reversed unordered SELECTs. If a test requires populating the database with test data, it is now done inside the test function. check-in: e2c27f6905 user: thomas tags: display_oversized_cards
16:58
Refactored the database schema: Split CardFace into CardFace and Printing. This new layout fits the actual data better. Also added the "is_oversized" column to the Printing relation. It holds a boolean indicating if the given printing of a card is larger than a regular card. These can not be included in a deck, so this boolean is stored to implement warning the user when they are about to add an oversized card to their deck via the deck list importer. check-in: 86d41f7e72 user: thomas tags: display_oversized_cards
2021-09-10
12:37
Added card database importer test case that verifies that stricter download filters remove previously imported cards that match the filter. check-in: 8360158095 user: thomas tags: trunk
2021-09-09
09:41
pyproject.toml: Fix build environment dependencies. According to [https://setuptools.readthedocs.io/en/latest/userguide/declarative_config.html#options], the used option [options.entry_points] in setup.cfg requires setuptools >= 51, so specify that as the minimum version required. check-in: a3f465dc28 user: thomas tags: trunk
09:40
setup.py: Removed dependencies for the "dev" extra, as these are already specified in setup.cfg. check-in: a75c3e851f user: thomas tags: trunk
2021-08-15
20:49
Changelog: Fixed truncated sentence. check-in: e1be3e755c user: thomas tags: trunk
20:47
Added module containing moved-away code. I forgot to add it for commit [46b28d4ff90015f2]. check-in: cb6480d588 user: thomas tags: trunk
19:08
Moved static project meta data from setup.py to setup.cfg check-in: 67fe90465f user: thomas tags: trunk
19:00
Fixed bug in the card data import, introduced in [7d9e4b0eb4bebbdd]. check-in: 120cac31c6 user: thomas tags: trunk
18:36
Fixed packaging with cx_Freeze. Closed-Leaf check-in: f12fe14203 user: thomas tags: setup_cfg
18:07
Moved most application meta data from setup.py to setup.cfg. This makes the dependencies discoverable by IDEs, which wasn’t the case previously, due to the definition via a dict instance. check-in: 3824a73f2c user: thomas tags: setup_cfg
18:04
Moved the application data directory definition via appdirs to it’s own module. Now, meta_data.py has no dependency on external libraries. check-in: 46b28d4ff9 user: thomas tags: setup_cfg
2021-08-12
12:42
Fixed a typo in a UI and removed two unused imports. check-in: bb2509a961 user: thomas tags: trunk
2021-08-11
18:17
Enable resource file compression when creating the compiled resources file. This reduces the application size a bit. check-in: 25032df58f user: thomas tags: trunk
17:35
Fixed some formatting in the third party license document. check-in: 764225afdc user: thomas tags: trunk
17:26
Display copyright notices for used libraries in the About dialog. check-in: 0acee3be97 user: thomas tags: trunk
17:25
Added changelog entry. Closed-Leaf check-in: 757c57c811 user: thomas tags: licensing_display
17:24
Added license note for cx_Freeze check-in: 74dddd14b2 user: thomas tags: licensing_display
17:09
Added PyQt5 to the third party license notes. check-in: 2c5f274e33 user: thomas tags: licensing_display
16:34
Updated license file name in setup.cfg. check-in: 1adb5be0e2 user: thomas tags: licensing_display
16:31
Updated MANIFEST.in to reflect the renamed license files. check-in: 0629c4d9d0 user: thomas tags: licensing_display
16:28
Simplyfied the About dialog layout. Removed a redundant (HTML) copy of the about text, which seemingly was added automatically by the Qt Designer application. check-in: db4ca30f7b user: thomas tags: licensing_display
15:27
Settings: Reduced default left and right paper margins from 10mm to 7mm. This is still sufficient to prevent printers from cropping images, but also frees up enough space to actually use horizontal image spacing greater than 0mm without reducing the page capacity from 9 to 6 cards immediately. check-in: ba7c3fbc62 user: thomas tags: licensing_display
14:39
Licenses: Converted the GPLv3 license text and the icon license text into Markdown documents. Renamed LICENSE-ICONS to ThirdPartyLicenses.md and included copyright notices for almost all used dependencies. Removed the embedded GPLv3 license text from the About UI file. Instead, include the GPLv3 markdown document as a separate entry in the compiled resources and load that. Added a new tab to the About dialog that shows the third party copyright notices. This should cover the requirement to actually display the dependency’s copyright notices somewhere in the UI. check-in: 51b1f02607 user: thomas tags: licensing_display