Bug 155243 - EDITING: keyboard, or most combinations, are dead when document opens. And no blinking cursor in writer. But there are ways to get around.
Summary: EDITING: keyboard, or most combinations, are dead when document opens. And no...
Status: UNCONFIRMED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Writer (show other bugs)
Version:
(earliest affected)
unspecified
Hardware: All All
: medium normal
Assignee: Not Assigned
URL:
Whiteboard:
Keywords:
Depends on:
Blocks: Text-Cursor
  Show dependency treegraph
 
Reported: 2023-05-11 13:04 UTC by u34
Modified: 2025-03-03 10:43 UTC (History)
0 users

See Also:
Crash report or crash signature:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description u34 2023-05-11 13:04:22 UTC
Continuing https://ask.libreoffice.org/t/must-click-the-mouse-when-opening-a-writer-doc-otherwise-keyboard-short-cut-ctrl-f-does-not-work/91269/10:

With 

Version: 7.5.3.2 (X86_64) / LibreOffice Community
Build ID: 50(Build:2)
CPU threads: 2; OS: Linux 6.3; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
7.5.3-1
Calc: threaded

xorg-server: 21.1.8-1

in most cases there is no response to most key strokes when a document, either mine or a new blank document, is opened. Neither do I get a blinking cursor in writer. I also think there is the same problem with calc. I haven't tried the other applications from the libreoffice suit.

I will try to bisect, though I doubt I succeed as I need my desktop fully functional.

I am 100% sure a mouse click gets things back to order. It could be that choosing a menu item with ALT+a menu letter, and navigating to the desired option with the down arrow key works.
Comment 1 u34 2023-05-12 20:53:48 UTC
After a reboot, and possibly upgrading some packages, but not the software mentioned before, I had the following experience:

Launched a bare X server, running only a terminal. Within the terminal, run a handful of commands, including using the mouse to copy-paste. Then run 

    SAL_USE_VCLPLUGIN=gen soffice --writer

The following 2 lines were printed to the terminal:

    javaldx: Could not find a Java Runtime Environment!
    Warning: failed to read path from javaldx

And writer started fine. Blinking cursor, Ctrl+f fully working. But after quitting writer the terminal was completely unresponsive. Both the keyboard, and the mouse, were unresponsive. And the terminal cursor was an blanked rectangle. I had to kill the X environment from another VT.
After restarting X, this time with a window manager, things got back to what they used to be. Including the documents that are opened by writer without a blinking cursor, and without a response from Ctrl+f. Though it looks like not only a mouse click brings things back to their normal working order, but also pressing the down arrow key.
Comment 2 Dieter 2023-05-25 06:44:19 UTC
Thank you for reporting the bug. Have you tried it with a clean user profile? If not, could you please reset your Libreoffice profile (https://wiki.documentfoundation.org/UserProfile) and re-test?

Is it only a problem with writer or also with other modules?

=> NEEDINFO
Comment 3 u34 2023-05-29 23:12:19 UTC
My understanding is that I should have a blinking cursor when I open a writer document. And not having such a cursor is a bug. 

I
1. Closed any the LibreOffice application I had open.
2. Used the [Quick test for corrupted profiles: use a temporary, new user profile](https://wiki.documentfoundation.org/UserProfile) 
    
     soffice -env:UserInstallation=file:///tmp/test

   The terminal had 

   javaldx: Could not find a Java Runtime Environment!
   Warning: failed to read path from javaldx

   and I got LibreOffice welcome screen.

3. File -> New -> Text Document 

   gave me a writer screen, with a blinking cursor, and a tip of the day. I confirmed, OK, the tip.
   Blinking cursor still on the empty document. There was also a message, with a blue background before the empty document, I am using LibreOffice 7.5 for the first time. Would I like to learn what's new?

4. I inserted the letter a in the empty document, and exited LibreOffice, saving a.odt to /tmp/. I then noticed there is also a terminal message

(soffice:21828): Gtk-WARNING **: 22:47:10.191: Could not init tracker3 search engine: The name org.freedesktop.Tracker3.Miner.Files was not provided by any .service files

5. Next I rerun soffice -env:UserInstallation=file:///tmp/test. Got, again

   javaldx: Could not find a Java Runtime Environment!
   Warning: failed to read path from javaldx

and a LibreOffice opening screen, suggesting a small screen shot of the a document.

6. By clicking the a document small screen shot with the mouse, I got it opened. Without a blinking cursor. The alt+letter keystroke did opened the suitable menu. In the Edit menu, the Find... was grayed. But I still had no blinking cursor at the body of the document. As usual, I had to click the mouse in order to get the blinking cursor.

As for other applications from the LibreOffice suite, I am only actually using calc. I am not sure what is the expected calc behavior. Doing a similar test with a new spreadsheet, the A1 cell has blue borders, but no blinking cursor can be seen. Inserting a at A1 and exiting by saving /tmp/a.ods. Not sure If I had to somehow re-select the A1 cell before I could insert a into it. Rerunning LibreOffic now has a small screen shots of a.ods and a.odt. Choosing a.ods open it. The A1 cell has blue borders, but no cell is active. Striking the keyboard b key does not seem to do something. That looks to me similar broken behavior on the side of calc.
Comment 4 QA Administrators 2023-05-30 03:16:09 UTC Comment hidden (obsolete)
Comment 5 RichardT54 2025-01-28 21:58:44 UTC
I have also experienced this bug. In my case it affects the first existing Writer document or Calc spreadsheet I open after starting LibreOffice.

Typically I might want to search for text in a Writer document, so I press Ctrl+F. but all key presses are ignored unless I first click on something with the mouse. 

Alternatively, I might want to open a spreadsheet and use the arrow keys to move to a cell and start entering data, but again all key presses are ignored unless I first click on something with the mouse.

If I close the document or spreadsheet and reopen it (or open another file) without exiting from LibreOffice, then the keyboard works straight away.

However, if I do exit from LibreOffice and restart it, the bug will occur again in the first document or spreadsheet that I open.

Under some circumstances the bug also occurs if I open a NEW spreadsheet immediately after starting LibreOffice, but I haven't managed to identify the exact conditions that cause this.

I have tested resetting my user profile to the factory defaults, but the bug still occurs.

I am using Linux Mint 22.1 (which is based on Ubuntu 24.04). 

I don't remember the version of LibreOffice in which I first noticed the bug, but I have experienced it with 24.2.7.2 and 24.8.4.2. I am currently using the latter which I installed from the launchpad.net PPA.

Help -> About:
Version: 24.8.4.2 (X86_64) / LibreOffice Community
Build ID: 480(Build:2)
CPU threads: 12; OS: Linux 6.8; UI render: default; VCL: gtk3
Locale: en-GB (en_GB.UTF-8); UI: en-GB
Ubuntu package version: 4:24.8.4~rc2-0ubuntu0.24.04.1~lo1
Calc: threaded
Comment 6 RichardT54 2025-01-28 22:36:28 UTC
I have just noticed that in the case of the Writer document it does respond to the down arrow key. This causes the cursor to suddenly appear to the left of the first character in the document. After that the keys work as normal.

However, pressing the down arrow in Calc doesn't cause the keys to start working.

Also, I just downloaded the AppImage file: LibreOffice-fresh.standard-x86_64.AppImage. When I run it the bug occurs in the same way as for my installed version.

It's Help -> About:
Version: 24.8.4.2 (X86_64) / LibreOffice Community
Build ID: bb3cfa12c7b1bf994ecc5649a80400d06cd71002
CPU threads: 12; OS: Linux 6.8; UI render: default; VCL: gtk3
Locale: en-GB (en_GB.UTF-8); UI: en-GB
Calc: threaded
Comment 7 u34 2025-02-04 16:01:19 UTC
(In reply to RichardT54 from comment #6)

Reconfirming I still have this bug.

> I have just noticed that in the case of the Writer document it does respond
> to the down arrow key. This causes the cursor to suddenly appear to the left
> of the first character in the document.

Indeed, with the distinction it appears to the right of the the first 
character in the document for an RTL (Right To Left) document. English is 
written in a left to right manner. There are languages that are written in a right to left manner. LibreOffice accommodates such languages by appropriate
settings in Tools > Options... 

>                                         After that the keys work as normal.
> 
> However, pressing the down arrow in Calc doesn't cause the keys to start
> working.
> 

For me, pressing the down arrow twice in Calc causes the active cell, and the row indication, to move downwards as expected. By that I mean that if A1 was marked as the active cell after opening the sheet, pressing the down arrow 
twice will cause the active cell to become A2. In addition to the new setting 
for the active cell, the other keys start working.

> Also, I just downloaded the AppImage file:
> LibreOffice-fresh.standard-x86_64.AppImage. When I run it the bug occurs in
> the same way as for my installed version.
> 
> It's Help -> About:
> Version: 24.8.4.2 (X86_64) / LibreOffice Community
> Build ID: bb3cfa12c7b1bf994ecc5649a80400d06cd71002
> CPU threads: 12; OS: Linux 6.8; UI render: default; VCL: gtk3
> Locale: en-GB (en_GB.UTF-8); UI: en-GB
> Calc: threaded

My current version is
Version: 24.8.4.2 (X86_64) / LibreOffice Community
Build ID: 480(Build:2)
CPU threads: 2; OS: Linux 6.12; UI render: default; VCL: gtk3
Locale: en-US (en_US.UTF-8); UI: en-US
24.8.4-2
Calc: threaded