Skip to content

Unregister fonts upon package/module uninstall#5480

Merged
vadi2 merged 2 commits intodevelopmentfrom
uninstall-removes-package-fonts
Oct 4, 2021
Merged

Unregister fonts upon package/module uninstall#5480
vadi2 merged 2 commits intodevelopmentfrom
uninstall-removes-package-fonts

Conversation

@vadi2
Copy link
Copy Markdown
Member

@vadi2 vadi2 commented Oct 3, 2021

Brief overview of PR changes/additions

Unregister fonts upon package/module uninstall.

Motivation for adding to Mudlet

So packages/modules containing custom fonts can be reinstalled w/o having to restart Mudlet on Windows.

Other info (issues closed, discussion etc)

Fix #5479.

I suspect the issue is that Qt is hanging onto a file handle to the font file - so let's try calling the complementary QFontDatabase::removeApplicationFont function.

@demonnic can you test if this fixes it on Windows?

@vadi2 vadi2 added this to the 4.14.0 milestone Oct 3, 2021
@vadi2 vadi2 requested a review from a team as a code owner October 3, 2021 08:47
@vadi2 vadi2 requested a review from a team October 3, 2021 08:47
@add-deployment-links
Copy link
Copy Markdown

add-deployment-links bot commented Oct 3, 2021

Hey there! Thanks for helping Mudlet improve. 🌟

Test versions

You can directly test the changes here:

No need to install anything - just unzip and run.
Let us know if it works well, and if it doesn't, please give details.

@github-actions
Copy link
Copy Markdown
Contributor

github-actions bot commented Oct 3, 2021

clang-tidy review says "All clean, LGTM! 👍"

Copy link
Copy Markdown
Member

@demonnic demonnic left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Original comment didn't make sense even to me when I reread it.

Approved, issue is resolved on Windows in my testing.

@vadi2 vadi2 merged commit a9ca6d2 into development Oct 4, 2021
@vadi2 vadi2 deleted the uninstall-removes-package-fonts branch October 4, 2021 13:27
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.

Mudlet holds a lock on ttf files in packages, causing issues for removing and reinstalling the package

2 participants