-
Notifications
You must be signed in to change notification settings - Fork 139
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
GIF support may be going away on Linux using GDK in the future #1307
Comments
I can't even imagine Linux distro without support for gif files aka there might be some temp issues like the one seen one but they will (hopefully!) be resolved before this hits an LTS release. At least that's my hope! |
A user of our RCP app ran into this on NixOS with |
SWT already has GIFFileFormat (among others), so for me it seems more an issue of that we need to detect that an image format is not supported and then fall back to the "non native" java counterparts? |
Maybe related: I've recently updated my system to Fedora 41 (released last week), an by default BMP and XPM image formats are no longer supported. It's not specific to Eclipse but this impacts the The workaround is to install |
Thanks for the heads up @pcdavid ! Would you mind opening a separate issue (and even PRs?) to track the recommendation to drop BMP and XPM altogether in Platform? |
SWT also already has WinBMPFileFormat. XPM is a simple text format and there are already implementations for that, for example here So instead of any dropping for support, I think it is more worth to think about a proper fallback mechanism if there is no native support especially in the light of Initiative 31 (FYI @HeikoKlare @tfroment e.g AWT/Swing already have such (extensible) plain java support, I don't see any benefit in rely on the "native" support here as this is heavily platform dependent and also depends on the actual installed packages as shown here... |
The gif format support in SWT has its set of problems (https://bugs.eclipse.org/bugs/show_bug.cgi?id=115652 , https://bugs.eclipse.org/bugs/show_bug.cgi?id=560298 , etc.) and it was the reason why using native libs was done . Using third-party dependencies in swt is a can of worms that no one dared to open yet and it would be an adventure of its own when someone decides to go that path.
|
I understand there are pro and cons for all options, but limited support is better than no support (while I'm not sure if 1 color or animated gifs are really important these days), so I was more thinking about SWT is falling back to the "custom" implementation when the "native" does not (any longer) works, especially for XPM it seems a good opportunity to simply embeds the code (if allowed) into SWT as we most likley would require adjustment for SWT vs AWT anyways... The good thing for all these formats unlikely evolve anymore. |
There are no cons (other than time spent) in all the options IMO and they are even mutually beneficial. |
At least @pcdavid is/was talking about the icon (of the launcher), I though splahscreen is and always was a (special) BMP format.... |
citing him "but this impacts the icon.xpm application icon and the splash screens of my various Eclipse installs (the splash screens shows as a white square image)." So I started writing for one thing and went to the other - multitasking not working for me lately. But this means BMP files are not working under Linux for the splash for the reason I wrote previously and fallback will not help for the very same reason again. |
This is specified here: https://www.eclipse.org/articles/Article-Branding/branding-your-application.html#launcher_branding
so this is quite "baked in" I have no clue why xpm (maybe because it is scalable?) was chosen in the past, but actually SVG would be more appropriate than PNG here, at least on Debian all icons seem to be SVG for applications now. |
Describe the bug
On Linux, the GTK port uses gdk-pixbuf to decode image files. The gdk-pixbuf maintainers consider gif (and a few other formats) "fringe" and are looking to not support them anymore in the future. See this PR in gdk-pixbuf. For now gdk-pixbuf have simply disabled them by default, and we are relying on Distros to make them enabled. In the future they may split gif handling into a new package for distros.
The first version of gdk-pixbuf that changed this default is 2.42.11(versions >= 2.24.11 can still include gif support though)
Please see eclipse-packaging/packages#187 for more background.
To Reproduce
Not 100% sure how to reproduce, but opening gif files on a system with the missing decoder would do it.
Screenshots
See eclipse-packaging/packages#187 (comment) for screenshots and logs.
Environment:
Linux only, but see above description for additional environmental info.
Workaround (or) Additional context
Long term Eclipse may need to resolve gif support if it gets dropped fully. This seems unlikely in the near term. If it does get dropped, there are ~32K gif files in SimRel. It may be simpler to have a fallback Java based gif loader rather than expect all projects to change.
I have created this issue here to ensure that SWT maintainers are aware of the potential problem. We are not sure that the user in eclipse-packaging/packages#187 actually hit this problem or some other issue due to configuration in their Linux install. Their problem was resolved with a distro re-install.
The text was updated successfully, but these errors were encountered: