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

Folder selection doesn't work in flatpak Krita #3

Open
geekley opened this issue Jun 25, 2022 · 2 comments
Open

Folder selection doesn't work in flatpak Krita #3

geekley opened this issue Jun 25, 2022 · 2 comments

Comments

@geekley
Copy link

geekley commented Jun 25, 2022

The "Set References Folder" button doesn't use a proper open dialog on flatpak Krita. It uses the file selection instead of directory selection, so I can't select a folder (and selecting a file doesn't work either). This is probably a bug in Flatpak/Qt related to portals.

However, the issue is solved for me when disabling native open dialogs with QFileDialog.DontUseNativeDialog:
photobash_images_docker.py#L452

    def changePath(self):
        if self.directoryPath == "":
            path = QStandardPaths.writableLocation(QStandardPaths.PicturesLocation)
        else:
            path = self.directoryPath
        dialogOptions = QFileDialog.ShowDirsOnly | QFileDialog.DontUseNativeDialog
        title = "Change Directory for Images"
        self.directoryPath = QFileDialog.getExistingDirectory(self.mainWidget, title, path, dialogOptions)
        Application.writeSetting(self.applicationName, self.referencesSetting, self.directoryPath)
        # [etc...]

Krita 5.0.6 (from Flathub)
Operating System: Kubuntu 22.04
KDE Plasma Version: 5.24.4
KDE Frameworks Version: 5.92.0
Qt Version: 5.15.3

@veryprofessionaldodo
Copy link
Owner

First of all, thank you for the report! I haven't been on Linux in a while, so I'm going to test this in another OS, and if nothing fails, trust that it does indeed fix the issue. I'll try to add this today, and create a new bug fix release.

Thank you for your diligence!

@geekley
Copy link
Author

geekley commented Jun 25, 2022

Cool! By the way, it'd also be nice if middle-clicking an image opened it in a new tab, like in browser links (I see that the option is already there when you right-click it).

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

No branches or pull requests

2 participants