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

Pasting of multiline text adds extra newlines #28181

Closed
raorn opened this issue Jul 18, 2024 · 25 comments
Closed

Pasting of multiline text adds extra newlines #28181

raorn opened this issue Jul 18, 2024 · 25 comments

Comments

@raorn
Copy link

raorn commented Jul 18, 2024

Steps to reproduce

Copy multiline text from a terminal or text editor:

111
222
333

Paste into telegram desktop message input box

Expected behaviour

111
222
333
_

_ - cursor position

Actual behaviour

111

222

333

_

_ - > cursor position

However, this does not happen iff multiline text is copied from code-formatted message from telegram itself.

Operating system

Fedora Linux 39

Version of Telegram Desktop

5.2.3

Installation source

Static binary from official website

Crash ID

No response

Logs

No response

@raorn raorn added the bug label Jul 18, 2024
@Marku555
Copy link

Same story on Ubuntu 22.04.4 LTS with Telegram Desktop 5.2.1 - 5.2.3.

@saddedmoroz
Copy link

Tg 5.2.3 x64 portable windows version, copy/paste works as expected

@raorn
Copy link
Author

raorn commented Jul 19, 2024

5.0.4 Fedora Liniux 39 - works as expected

@Aokromes
Copy link
Collaborator

Aokromes commented Jul 19, 2024

can't reproduce on 5.2.3 static binary running on fedora 40 nor on ubuntu 23.04..

@perpostas
Copy link

The same issue is on Telegram Desktop v5.2.3
Ubuntu 22.04.4 LTS

@ilya-fedin
Copy link
Contributor

Can't confirm, there's no such issue

@sejtevgenij
Copy link

facing the same issue on Ubuntu 22.04.4 LTS, Telegram v5.2.3 (Linux x64 static binary)

@sejtevgenij
Copy link

Fedora 40, Telegram v5.2.3 (Linux x64 static binary)

  • Wayland Session: the issue is not present
  • Xorg Session: the issue is present

@ilya-fedin
Copy link
Contributor

Can't confirm on Wayland nor X11.

@sadm2014
Copy link

The same issue is on Telegram Desktop v5.2.3
Ubuntu 22.04.4 LTS
Xorg session (xubuntu)

@cyberknight777
Copy link

can confirm on Telegram Desktop v5.2.3 on Arch Linux running X11 with i3WM. However it only happens with terminals, if I copy from my editor (GNU Emacs), it's fine.

@ilya-fedin
Copy link
Contributor

However it only happens with terminals, if I copy from my editor (GNU Emacs), it's fine.

This seem to point to the fact that steps to reproduce aren't full. As I try with a random text editor/terminal and can't reproduce while some exact text editor/terminal has to be used?

@cyberknight777
Copy link

However it only happens with terminals, if I copy from my editor (GNU Emacs), it's fine.

This seem to point to the fact that steps to reproduce aren't full. As I try with a random text editor/terminal and can't reproduce while some exact text editor/terminal has to be used?

FWIW, it happened on both lxterminal and xterm.

@ilya-fedin
Copy link
Contributor

Can't reproduce with the first one and can't copy from the second one at all

@ilya-fedin
Copy link
Contributor

Maybe you folks have some kind of clipboard manager that is not compatible with Qt 6 (the toolkit tdekstop is based on)?

@cyberknight777
Copy link

Can't reproduce with the first one and can't copy from the second one at all

It also happens on tilix btw.

@ilya-fedin
Copy link
Contributor

As tdesktop doesn't handle clipboard, this should be a bug in either some system component or Qt. And other Qt applications using the same Qt version (Qt 6.7.2 for tdesktop 5.2.3) should be affected just as well (but it could be a problem to get other applications using Qt 6.7.2 to test depending on the distro)

@ilya-fedin
Copy link
Contributor

But I can't even confirm such a bug even exists yet, though.

@ilya-fedin
Copy link
Contributor

ilya-fedin commented Jul 24, 2024

What I mean is, this report will be closed either because no developers able to confirm or because it's not a tdesktop bug as clipboard is not tdesktop's area of responsibility so nothing could be done on it.

@ilya-fedin
Copy link
Contributor

It also happens on tilix btw.

no, can't confirm with tilix either

@cyberknight777
Copy link

Idk how else could I help reproduce this tbh.

@cyberknight777
Copy link

Okay I have verified something.

It does not happen on v5.1.7. Whatever changed in tdesktop started happening since v5.1.8

@cyberknight777
Copy link

@raorn can you confirm this?

@sejtevgenij
Copy link

sejtevgenij commented Jul 24, 2024

Okay I have verified something.

It does not happen on v5.1.7. Whatever changed in tdesktop started happening since v5.1.8

Have checked the same and can confirm it.

Also I've tried different applications as copy source
Telegram v5.2.3, Ubuntu 22.04 LTS, X11:

  • Gnome Terminal, Tilix, Gedit - the issue is present
  • Kitty - the issue is not present

@timatet
Copy link

timatet commented Jul 24, 2024

I observe the same behavior in Telegram Desktop 5.2.3. I use Ubuntu 20.04.6 LTS. It occurs when typing multi-line text with breaks as a single line before inserting it, e.g. in Notepad.

After pasting into the message input field in Telegram, each single line line break is replaced by three lines.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

10 participants