Giter Club home page Giter Club logo

Comments (7)

Simon-Laux avatar Simon-Laux commented on May 28, 2024

Find an animated GIF (say, giphy.com), copy and paste into the chat text box (note that it plays once pasted)

how do you copy it from giphy? when I try to copy it I get the current frame as png, the image seems to be webp and also does not work in other apps like discord for me.

from deltachat-desktop.

Simon-Laux avatar Simon-Laux commented on May 28, 2024

downloading the webp file and dropping it into deltachat desktop works (still animated), but if I copy from firefox or from chrome I get the image only as png, log output:

 Clipboard available formats: [ 'image/png', 'text/html' ]

maybe it is somewhere inside of the html as base64, I need to check that, but other than that there is not much we can do about it, maybe it's a bug in chrome or in electron? do you know any apps where this works?

Edit: found this, looks like chrome/electron does not support webp in clipboard yet: https://superuser.com/questions/1664216/why-does-google-chrome-and-safari-copy-image-as-png-representation

Edit2:

maybe it is somewhere inside of the html as base64, I need to check that

checked it, the html file only contains a link to the gif file, so it's useless (because we don't want to do network requests from deltachat desktop).

from deltachat-desktop.

Simon-Laux avatar Simon-Laux commented on May 28, 2024

So impossible to fix I'd say unless we want to write native code that extracts the clipboard contents, but even then IDK if browsers even copy to clipboard correctly or already convert to png while copying?

Note that I tested to get debug info on mainly on MacOS.
I added more log statements in #3574 if someone wants to try on linux and windows, but I don't expect the situation to be better there.

from deltachat-desktop.

binarydad avatar binarydad commented on May 28, 2024

I'll try and swing back on this tonight but I know this used to work, at least for a short while. I was able to copy GIFs (right-click, copy image) and paste into the chat box. Not only did it play in the chat box, but also in the message history once sent. It was actually really convenient.

This was on Firefox. I have not tried Chrome/Edge.

Even Win + . on Windows 11 didn't work as nicely.

from deltachat-desktop.

Simon-Laux avatar Simon-Laux commented on May 28, 2024

I suspect the electron upgrade more than the image compression because drag and dropping and attaching the image file (as image) still works perfectly for me. (though webp is not selectable in the image attachment chooser, maybe sth. for a dedicated issue?)

There seem to be some GUI tools to debug clipboard contents: #2323
DC desktop is based on electron which is based on chrome(sum), might be the chrome does not support pasting of different image types?

from deltachat-desktop.

farooqkz avatar farooqkz commented on May 28, 2024

I just tested with two GIFs:

https://tenor.com/view/catjam-cat-music-jam-vibing-gif-20520051
https://giphy.com/gifs/starwars-oQkEpeve8GcCSh9QcH

I've pasted them in Telegram's saved messages and DC's. The results were the same. The GIF is not animated anymore. So I guess the issue is invalid?

Edit: attaching GIF as an image works

from deltachat-desktop.

Simon-Laux avatar Simon-Laux commented on May 28, 2024

I think it's also a bug of the browsers, looks like sth we can not really solve, or only partially solve that it only works with some browsers (firefox in this case).
I'll close it and put it to project resurrection, as there is no real actionable item for us right now.

Feel free to add more info if you find out sth that could help us solve this then we can bring this issue back to life.

from deltachat-desktop.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.