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
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 ***
"Pasting multi-line plain text" This problem does not involve multi-line text.
(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".
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 -
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.
Created attachment 166360 [details] Screenshot of the import dialog
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)?
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)".
Code pointers: https://opengrok.libreoffice.org/xref/core/sc/source/ui/unoobj/filtuno.cxx?r=1e97ca02#209 https://opengrok.libreoffice.org/xref/core/sc/source/ui/dbgui/textimportoptions.cxx?r=77c9c2c9#29
https://opengrok.libreoffice.org/xref/core/sc/source/ui/view/viewfun5.cxx?r=2d873932#316
(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.
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?
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.
Created attachment 192070 [details] import dialog with a checkbox saying "don't ask again"
"Debug patch submitted for review: https://gerrit.libreoffice.org/c/core/+/184099"
What are best practices for writing single-line HTML? Writing single-line HTML effectively requires clarity, simplicity, and adherence to coding conventions. Here are some best practices: Minimize Tags: Use only the necessary tags to keep the HTML concise. For example: html <span>Hello, World!</span> Avoid Inline Styles: Keep styles in a separate CSS file to maintain clean and reusable code. Use Semantic Tags: Choose tags that convey meaning, such as <strong> for emphasis instead of <b>. Quote Attribute Values: Always enclose attribute values in quotes for consistency: html <a href="https://example.com">Visit Example</a> Close Tags Properly: Even if some tags are optional to close, always close them for better readability: html <img src="image.jpg" alt="Description" /> Keep Accessibility in Mind: Include attributes like alt for images and title for links to improve accessibility. Avoid Excessive Whitespace: Keep the code compact without unnecessary spaces or line breaks. Validate Your Code: Use tools like the W3C Validator to ensure your HTML is error-free. These practices ensure your single-line HTML is clean, functional, and easy to maintain. Would you like to dive deeper into any of these points?