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

Remove qt5 support and fix kf6 #556

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open

Conversation

Gigas002
Copy link

@Gigas002 Gigas002 commented Jul 23, 2024

This PR is arguable, and it's completely OK to banish it from existence if you don't feel it fits the project well

It does these things:

  • remove qt5 vars/code, so that we support only compilation with qt6
  • fixes the KDE_SUPPORT for Plasma 6 (which is dependent on qt6, so I don't see the point in supporting EOL qt5)
  • fixes some nasty gcc 14 warnings
  • Exiv2::enableBMFF(true); is deprecated and seems not needed anymore

gcc warnings stuff may be backported to a current version, that utilizes the qt5, but the kf6 fixes aren't, afaik

Also a note about mainwindow.cpp changes for kf6: the KWindowEffects::enableBlurBehind now takes QWindow instead of winId, and while the applyWindowedBackground was being called applyWindowedBackground with kf5 wasn't a bad thing, now it crashes, because the window not exists on a first call. That's why the check here is needed, though it's a bit nasty

@eddiezato
Copy link

FYI, with the move to Qt6, the qtraw plugin will stop working as it is seems abandoned by the author and needs to be fixed for Qt6.

@Gigas002
Copy link
Author

Thanks for info. Does this actually fails for you to open raw files without it? I can open DNG just fine

@eddiezato
Copy link

Yeah. It's failing. But I'm on Windows, not sure about Linux.

@Gigas002
Copy link
Author

I think that plugin builds with qt6, would be glad if someone could test it on windows. I only needed to change one line in main.cpp to build it on linux:

QImageIOPlugin::Capabilities
RawPlugin::capabilities(QIODevice *device, const QByteArray &format) const
{
    if (keys().contains(format) ||
        format == "tif" ||
        format == "tiff")
        return Capabilities(CanRead);
    if (!format.isEmpty())
-        return 0;
+        return {};

    Capabilities cap;
    if (device->isReadable() && RawIOHandler::canRead(device))
        cap |= CanRead;
    return cap;
}

@eddiezato
Copy link

It builds successfully on windows. But qimgv still won't display raw files with 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

Successfully merging this pull request may close these issues.

2 participants