Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Save both status and importance flags #1030

Merged
merged 5 commits into from
Apr 3, 2022
Merged

Save both status and importance flags #1030

merged 5 commits into from
Apr 3, 2022

Conversation

vkbo
Copy link
Owner

@vkbo vkbo commented Apr 3, 2022

Summary:

In the old project file format, the status and importance flags were saved to the same setting in the project file, and interpreted as status or importance based on the class. This meant that if an item is moved from one class folder to another where the interpretation changes, and then back again, the setting is lost.

With the new file format, saving both is less of an issue, so the old setting is now preserved as long as the status or importance entry still exists in the project.

This PR also moves the handling of the status/importance icons from the main GUI class into the NWStatus class itself. This makes more sense, but was not done in the past in order to keep QtGui elements out of the novelWriter core subpackage. Since the issue there was mostly with testing, a quick hack has been added to the conftest.py file.

Related Issue(s):

Reviewer's Checklist:

  • The header of all files contain a reference to the repository license
  • The overall test coverage is increased or remains the same as before
  • All tests are passing
  • All flake8 checks are passing and the style guide is followed
  • Documentation (as docstrings) is complete and understandable
  • Only files that have been actively changed are committed

@vkbo vkbo added this to the Release 1.7 Beta 1 milestone Apr 3, 2022
@vkbo vkbo merged commit 23fd6b8 into main Apr 3, 2022
@vkbo vkbo deleted the status_importance branch April 3, 2022 20:43
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant