Bug 137316 - Under X the middle mouse button usually pastes which is super nice but LO asks about language <everytime> which is horrible
Summary: Under X the middle mouse button usually pastes which is super nice but LO ask...
Status: ASSIGNED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All Linux (All)
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords: difficultyInteresting, easyHack
Depends on:
Blocks: CSV-Dialog
  Show dependency treegraph
 
Reported: 2020-10-07 16:35 UTC by ffs
Modified: 2024-01-20 04:46 UTC (History)
3 users (show)

See Also:
Crash report or crash signature:


Attachments
Screenshot of the import dialog (30.63 KB, image/png)
2020-10-14 06:49 UTC, Mike Kaganski
Details
import dialog with a checkbox saying "don't ask again" (18.45 KB, image/png)
2024-01-20 04:46 UTC, Sahil Gautam
Details

Note You need to log in before you can comment on or make changes to this bug.
Description ffs 2020-10-07 16:35:58 UTC
Description:
I have a hundred things to paste into seprate cells from another application.

Ideally I'd pick up and then middle-button paste - bang done super quick.

But... every time I get the super annoying "select the language to Use for Import" dialogue.  How do I turn this incredibly annoying non-option off?


Steps to Reproduce:
middle button paste into a cell from an application outside LO

Feel the annoyance of the pointless blocking dialogue

Do it severl hundred times to feel the burn

Actual Results:
pointless dialogue comes up <every time"

Expected Results:
Middle button "just pastes" no dialogue


Reproducible: Always


User Profile Reset: No



Additional Info:
[Information automatically included from LibreOffice]
Locale: en-GB
Module: SpreadsheetDocument
[Information guessed from browser]
OS: Windows (All)
OS is 64bit: no
Comment 1 Mike Kaganski 2020-10-08 06:20:17 UTC
Pasting multi-line plain text over a cell in Calc triggers text import dialog. This works as intended.

While configurability of this could be an enhancement request, you may easily change your actions to have it working as you need:

- either middle-click into formula-bar
- or double-click the target cell to enter its edit mode, then miggle-click it.

*** This bug has been marked as a duplicate of bug 65872 ***
Comment 2 ffs 2020-10-12 07:36:14 UTC
"Pasting multi-line plain text"

This problem does not involve multi-line text.
Comment 3 Mike Kaganski 2020-10-12 07:49:32 UTC
(In reply to ffs from comment #2)
> "Pasting multi-line plain text"
> 
> This problem does not involve multi-line text.

Then please clarify what exactly us selected and where, to see the problem in controlled conditions - like "open this web page (URL) in this specific browser; select characters from this to this; activate calc and middle-click over cell A1".
Comment 4 ffs 2020-10-12 21:43:26 UTC
I select one word no new lines, no spaces and it asks every time - in this case middle-click paste from konsole.  

Same from LO apps doesn't ask. 

Edit: just tested same from xterm - doesn't ask -
Comment 5 Mike Kaganski 2020-10-14 06:44:58 UTC
Reproducible with konsole and LibreOffice 7.0.2.2 run on Ubuntu 20.04 with Plasma DE.

This is reproducible with and without klipper (I disabled Clipboard in Configure System Tray's System Services, and restarted).

The dialog is not related to CSV import.
Comment 6 Mike Kaganski 2020-10-14 06:49:42 UTC
Created attachment 166360 [details]
Screenshot of the import dialog
Comment 7 Mike Kaganski 2020-10-14 07:46:23 UTC
This dialog is related to pasting as HTML.
Steps:
1. Select any word in konsole, right-click it, and choose "Copy".
2. In Calc, select any cell (do not enter cell edit mode), and use Edit->Paste Special->Paste Special
=> three options are shown: HTML, Unformatted text, and Use text import dialog.

Using "HTML", the dialog from attachment 166360 [details] appears. Using "Unformatted text", no dialog is shown. With "Use text import dialog", a CSV dialog is shown.

When several clipboard formats are available in the clipboard, LibreOffice tries to use the richest available -> naturally chooses HTML. The question is, why is the dialog needed here in HTML import at all, even if HTML in clipboard doesn't contain the language information. The number recognition is not an issue for single-line unformatted text paste, so why should it be an issue for HTML (at least single-line)?
Comment 8 Mike Kaganski 2020-10-14 08:00:12 UTC
Note also that the behaviour is not consistent across the platforms.

Steps:
1. Open this page (https://bugs.documentfoundation.org/show_bug.cgi?id=137316) in Chrome, and select word "Assignee" in the top metadata block; copy to clipboard (Ctrl+C).
2. In Calc, paste (Ctrl+V).

On Windows, this doesn't ask any questions. The clipboard format is reported as "Stripped HyperText Markup Language (Simple HTML)" (shown e.g. in Paste Special dialog).

On Linux, this shows the dialog from attachment 166360 [details]. The clipboard format is reported as "HyperText Markup Language (HTML)".
Comment 11 Eike Rathke 2023-03-30 15:03:19 UTC
(In reply to Mike Kaganski from comment #7)
> The question
> is, why is the dialog needed here in HTML import at all, even if HTML in
> clipboard doesn't contain the language information. The number recognition
> is not an issue for single-line unformatted text paste, so why should it be
> an issue for HTML (at least single-line)?
The single line text/plain is special-cased to not raise the Text Import dialog. Maybe the same could be done for text/html, though detection whether the actual data is single line or not is not as straight forward as all sort of HTML decoration may be around on multiple lines even if data is only a single word.
Comment 12 Abdallah Elhdad 2023-03-30 15:47:44 UTC
Is solving this problem about preventing the "import options" dialog from being called upon the paste of a Simple HTML? 

Another question, what is the expected behavior? it seems there are multiple cases, can someone address them?
Comment 13 Sahil Gautam 2024-01-20 04:44:44 UTC
When I tried to reproduce this bug, I found that the dialog now has another checkbox [x] keep asking during this session, which if unchecked, it doesn't show that dialog anymore.
Comment 14 Sahil Gautam 2024-01-20 04:46:15 UTC
Created attachment 192070 [details]
import dialog with a checkbox saying "don't ask again"