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

Clipboard preference orders prefers text/html over UTF-8 when using plain-text #365

Open
zusorio opened this issue Feb 12, 2025 · 3 comments
Labels
clipboard enhancement New feature or request

Comments

@zusorio
Copy link
Contributor

zusorio commented Feb 12, 2025

When I try to copy some text that's only available as UTF-8 and text/html, text/html is preferred when I have plain-text selected as preferred. I think copying the text as UTF-8 would be the more expected behavior.

@totaam
Copy link
Collaborator

totaam commented Feb 12, 2025

text that's only available as UTF-8 and HTML5

Do you mean text/html?

Do you have an example app I can use to test this?

@totaam totaam added enhancement New feature or request clipboard labels Feb 12, 2025
@zusorio
Copy link
Contributor Author

zusorio commented Feb 12, 2025

Do you mean text/html?

Yup, sorry I meant text/html

Do you have an example app I can use to test this?

Yes, it's a bit involved but here's a full reproduction

  • Use this to start the container
docker run \
  -e CONNECTION_METHOD=xpra \
  -e AUTOSTART_CAPELLA=1 \
  -e XPRA_SUBPATH=/xpra/ \
  -p 8888:10000 \
  -v /workspace \
  ghcr.io/dsd-dbs/capella-dockerimages/capella/remote:7.0.0-selected-dropins-main
  • Open http://localhost:8888/xpra/
  • In Capella, click on File > New > Capella Project
  • Name it test and click Finish
  • Expand test > test.aird > test > Logical Architecture
  • Right click on Capabilities, then Add new Capella Element > Capability Realization
  • Double-click on CapabilityRealization1
  • Put some text in the Pre-Condition field
  • Copy the text -> It's copied as HTML despite the clipboard preferred format being text/plain
  • Go to http://localhost:8888/xpra/?clipboard_preferred_format=UTF8_STRING and try again, now the text is copied correctly

Let me know if that reproduction works for you

@zusorio zusorio changed the title Clipboard preference orders prefers HTML5 over UTF-8 when using plain-text Clipboard preference orders prefers text/html over UTF-8 when using plain-text Feb 12, 2025
@totaam
Copy link
Collaborator

totaam commented Feb 12, 2025

That's way too complicated for me to test.

I need a simple test application, no containers.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
clipboard enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants