[go: up one dir, main page]

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

Loupe-copied image does not appear as image #323

Open
4 of 9 tasks
erin-desu opened this issue Oct 11, 2024 · 1 comment
Open
4 of 9 tasks

Loupe-copied image does not appear as image #323

erin-desu opened this issue Oct 11, 2024 · 1 comment
Assignees
Labels
bug Something isn't working

Comments

@erin-desu
Copy link

Description

Extension version:
Loupe (new GNOME Image Viewer) does not copy the image bitmap, instead it copies data for locating the file.

Problem Explanation

Pano interprets this as text and even makes control+v which normally works not working.

Expected Behavior

It interprets it as file / image.

Reprodution

Steps To Reproduce

Steps to reproduce, if applicable:

  1. Open image in Loupe
  2. Copy image from menu or using Control+C
  3. Open Pano (it interprets it as text)
  4. Or, try to paste it using Control+V (does not work as expected)

Details

Mark with [ ] all that applies:

It happens with any application?

  • Yes, it applies to any application.
  • No. Only with the following
  • It works with the following applications that I have tried:
    • Loupe

It happens only on one computer?

  • I don't know.
  • No. I have tried it on more than one computer.

It happens only with some specific gnome configuration?

  • I don't think that the configuration matters.
  • Yes. Only if the following config is set up:
    • Fill in a list with any configuration tha applies.

It happens only with some specific extension installed?

  • I don't think that the installed extensions affect the bug/behavior.
  • Yes. Only if the following gnome extension is installed:
    • Fill in a list with any extension tha applies.
    • Fill in also any detail about the extensions that applies.

Diagnostics

Fill in all information that applies:

Environment

  • GNOME Shell version: 46.4
  • Distro: Fedora
  • Distro version: 40 Workstation

Screenshots

N/A

Application Details

Clipboard content types

text/plain;charset=utf-8
text/uri-list
application/vnd.portal.files
application/vnd.portal.filetransfer
x-special/gnome-copied-files

Application Version

  • Loupe: 46.2

Output and Logs

Gnome

Irrelevant

Pano Configuration

Nothing relevant, only cosmetic things like shortcut.

Enabled Extensions

Irrelevant

@erin-desu erin-desu added the bug Something isn't working label Oct 11, 2024
@Totto16 Totto16 self-assigned this Oct 13, 2024
@Totto16
Copy link
Collaborator
Totto16 commented Oct 13, 2024

This is annoying, but the core problems doesn't lie in our extension. The core problem is how Gnome handles mime type sand how we have access to it. Without getting into too much technical detail, we only get a list of possible mime types, that a given "selection" can have, but not the current one, most if not all image "selections" (the official term in gnome terms, it has only vaguely to do with the normal selection term in the sense of text selection) only say, they have some image/png capabilities, but loupe says

["text/plain;charset=utf-8", "text/uri-list", "application/vnd.portal.files", "application/vnd.portal.filetransfer"]

So we check, if we have a text selection, and gnome says, that we have one, so we get the content.

There are no good solutions to this, as loupe doesn't provide an image as clipboard content, but only "text/plain;charset=utf-8" and "text/uri-list". We could try text/uri-list first (which loupe actually als has available) but that only results in us displaying a file, which is not perfect and checking for "text/uri-list" before normal text may cause some problems with other apps, I'll investigate more and also ask the loupe developers why they do such 💩 (IMO) 🤷🏼‍♂️

Edit: Loupe explicitly provides a uri-list, for whatever reason (See here)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
None yet
Development

No branches or pull requests

2 participants