Bug 150336 - Shift + Up/Left no longer works to select cells in LO 7.4 beta 2 (using the Tabbed UI)
Summary: Shift + Up/Left no longer works to select cells in LO 7.4 beta 2 (using the T...
Status: RESOLVED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: Calc (show other bugs)
Version:
(earliest affected)
7.4.0.0 beta1+
Hardware: All All
: high major
Assignee: Caolán McNamara
URL:
Whiteboard: target:7.5.0 target:7.4.1
Keywords: bibisected, bisected, regression
: 150051 150412 (view as bug list)
Depends on:
Blocks: Notebookbar Sparklines
  Show dependency treegraph
 
Reported: 2022-08-10 18:21 UTC by Rafael Lima
Modified: 2022-09-09 10:24 UTC (History)
7 users (show)

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 Rafael Lima 2022-08-10 18:21:07 UTC
Today I noticed that holding Shift and pressing Up to select cells no longer works in Calc. Shift + Down does work.

Can anyone else confirm this?

System info

Version: 7.4.0.2 / LibreOffice Community
Build ID: 1512ce97d7ed39dce3121f7e15651fd8895f950e
CPU threads: 16; OS: Linux 5.15; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Calc: threaded

Not present in

Version: 7.3.5.2 / LibreOffice Community
Build ID: 30(Build:2)
CPU threads: 16; OS: Linux 5.15; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Ubuntu package version: 1:7.3.5-0ubuntu0.22.04.1
Calc: threaded
Comment 1 Rafael Lima 2022-08-10 18:29:54 UTC
Also don't work with gen and gtk3.

Also repro in LO 7.5+
Comment 2 Rafael Lima 2022-08-10 18:39:09 UTC
Shift + Left also does not work.
Comment 3 Rafael Lima 2022-08-10 19:06:01 UTC
With clear user profile it works again.

But installing some extensions will break the shortcuts again.

I need to investigate a bit further.
Comment 4 Xisco Faulí 2022-08-11 08:29:46 UTC
it works in

Version: 7.5.0.0.alpha0+ / LibreOffice Community
Build ID: 4e2ce2a460458f17ee4360c45a2da2fc4b4d753e
CPU threads: 8; OS: Linux 5.10; UI render: default; VCL: gtk3
Locale: es-ES (es_ES.UTF-8); UI: en-US
Calc: threaded Jumbo

Setting to NEEDINFO until futher info is provided
Comment 5 Rafael Lima 2022-08-16 14:19:58 UTC
*** Bug 150412 has been marked as a duplicate of this bug. ***
Comment 6 Rafael Lima 2022-08-16 14:24:23 UTC
(In reply to Xisco Faulí from comment #4)
> Setting to NEEDINFO until futher info is provided

Hi Xisco, considering that we have two other similar and recent bug reports about the same problem (see bug 150051 and bug 150412 - both in 7.4 beta), I believe there's something wrong we should look into.

One thing I figured out is that the problem is not related to extensions since the user in bug 150051 did not have any additional extensions installed.

From bug 150412 I found out that the problem may be related to the UI variant. When I switch to the standard toolbar (and then restart LO), all returns to normal. Selection starts working again as expected.
Comment 7 Rafael Lima 2022-08-16 14:29:16 UTC
Steps to reproduce

1) On a new installation of LO 7.4 beta, notice it is using the standard toolbar; In Calc selecting with Shift + Up / Left works fine

2) Switch to the Tabbed UI variant (Apply to all); before restarting selecting with Shift + Up / Left still works

3) Now restart LO and open Calc; Selecting with Shift + Up / Left no longer works

4) Switch back to the Standard toolbar and restart; now selecting works again

System info

Version: 7.4.0.2 / LibreOffice Community
Build ID: 1512ce97d7ed39dce3121f7e15651fd8895f950e
CPU threads: 16; OS: Linux 5.15; UI render: default; VCL: kf5 (cairo+xcb)
Locale: pt-BR (pt_BR.UTF-8); UI: en-US
Calc: threaded
Comment 8 Xisco Faulí 2022-08-16 14:32:32 UTC
(In reply to Rafael Lima from comment #7)
> Steps to reproduce
> 
> 1) On a new installation of LO 7.4 beta, notice it is using the standard
> toolbar; In Calc selecting with Shift + Up / Left works fine
> 
> 2) Switch to the Tabbed UI variant (Apply to all); before restarting
> selecting with Shift + Up / Left still works
> 
> 3) Now restart LO and open Calc; Selecting with Shift + Up / Left no longer
> works
> 
> 4) Switch back to the Standard toolbar and restart; now selecting works again
> 
> System info
> 
> Version: 7.4.0.2 / LibreOffice Community
> Build ID: 1512ce97d7ed39dce3121f7e15651fd8895f950e
> CPU threads: 16; OS: Linux 5.15; UI render: default; VCL: kf5 (cairo+xcb)
> Locale: pt-BR (pt_BR.UTF-8); UI: en-US
> Calc: threaded

Reproduced in

Version: 7.5.0.0.alpha0+ / LibreOffice Community
Build ID: da46f3db22814c03fbc303275342f7182ea288b4
CPU threads: 8; OS: Linux 5.10; UI render: default; VCL: gtk3
Locale: en-US (C); UI: en-US
Calc: threaded
Comment 9 Xisco Faulí 2022-08-16 14:38:42 UTC
Regression introduced by:

author	Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk>	2022-04-03 09:02:38 +0900
committer	Tomaž Vajngerl <quikee@gmail.com>	2022-04-06 02:59:02 +0200
commit c6fecc628a60a3955c022f04020cdb515cc4fb6e (patch)
tree 64debf2d425982dc37cf6b06e305e7707739fe97
parent ec18c7bf707e85d85f362d43454d35b1636de40f (diff)
sc: add Group and Ungroup to context menu for sparklines

Bisected with: bibisect-linux64-7.4

Adding Cc: to Tomaž Vajngerl
Comment 10 Rafael Lima 2022-08-18 00:46:55 UTC
*** Bug 150051 has been marked as a duplicate of this bug. ***
Comment 11 Xisco Faulí 2022-08-18 12:54:28 UTC
@Caolán, @Heiko,
any idea why this is only happening with the tabbed UI ?
Comment 12 Rafael Lima 2022-08-18 13:26:18 UTC
For some reason the commands .uno:GoLeftSel and .uno:GoUpSel are disabled in the tabbed interface. If you run the following macro in LO 7.4 using the Tabbed interface, LibreOffice will stop responding and you'll have to kill its process.

Sub SelectLeft
  dispatcher = CreateUnoService("com.sun.star.frame.DispatchHelper")
  provider = ThisComponent.CurrentController.Frame
  dispatcher.executeDispatch(provider, ".uno:GoLeftSel", "", 0, Array())
End Sub

The macro above will work if you return to the standard toolbar and restart LibreOffice.

So basically switching the interface is disabling these commands.

I'm not sure if this is related, but I got these messages in the terminal after launching LO 7.4 from the terminal:

warn:sfx.control:15433:15433:sfx2/source/control/dispatch.cxx:1206: Childwindow slot missing: 25917
warn:sfx.control:15433:15433:sfx2/source/control/dispatch.cxx:1206: Childwindow slot missing: 26189
warn:sfx.control:15433:15433:sfx2/source/control/dispatch.cxx:1206: Childwindow slot missing: 26190
Comment 13 Heiko Tietze 2022-08-18 14:49:24 UTC
(In reply to Xisco Faulí from comment #11)
> @Caolán, @Heiko,
> any idea why this is only happening with the tabbed UI ?

Works for me with standard and tabbed UI

Version: 7.5.0.0.alpha0+ / LibreOffice Community
Build ID: bd6cecbae44f4adce6e245bab46a88e86f068d99
CPU threads: 8; OS: Linux 5.19; UI render: default; VCL: kf5 (cairo+xcb)
Locale: de-DE (en_US.UTF-8); UI: en-US
Calc: threaded
Comment 14 Xisco Faulí 2022-08-18 14:55:05 UTC
same behaviour with GEN and GTK3. Shift up/left don't work
Comment 15 Caolán McNamara 2022-08-18 20:55:05 UTC
It's possible that commit just added enough entries in sc/inc/sc.hrc to cause some other entries to be then numbered high enough to overlap some other range of include/sfx2/sfxsids.hrc and there is some collision there between multiple slots now with the same id. No idea why it would only affect the tabbar ui though.

It's possible that that e.g. removing those relatively new *SPARKLINE* entries from the block that ends with INSERT_MENU_END (and restoring INSERT_MENU_END to a lower number) and putting them instead down numbered after SID_CURRENT_FORMULA_RANGE would fix it. Or finding where the overlap is and what range reservation is the issue.
Comment 16 Caolán McNamara 2022-08-19 07:57:14 UTC
yeah, that's works. Lets try that as a presumably safe to backport to 7-4 fix.
Comment 17 Caolán McNamara 2022-08-19 09:07:47 UTC
seems that SID_CURSORLEFT_SEL and SID_PREVIEW_MARGIN (SID_CURSORUP_SEL and SID_PREVIEW_CLOSE) ended up with the same 26523 (26522) ids.

there is that seemingly arbitrary
#define SID_KEYFUNC_START                   (SID_SC_START + 521)
in include/sfx2/sfxsids.hrc

and adding entries in sc/inc/sc.hrc eventually pushed other slotids past the + 521 to create overlapping ids
Comment 18 Xisco Faulí 2022-08-19 09:13:54 UTC
(In reply to Caolán McNamara from comment #17)
> seems that SID_CURSORLEFT_SEL and SID_PREVIEW_MARGIN (SID_CURSORUP_SEL and
> SID_PREVIEW_CLOSE) ended up with the same 26523 (26522) ids.
> 
> there is that seemingly arbitrary
> #define SID_KEYFUNC_START                   (SID_SC_START + 521)
> in include/sfx2/sfxsids.hrc
> 
> and adding entries in sc/inc/sc.hrc eventually pushed other slotids past the
> + 521 to create overlapping ids

Hi Caolán,
is there any way to assert this kind of overlapping at build time ?
Comment 19 Commit Notification 2022-08-19 09:25:46 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/673bff36bc310252dd4d95ca9e31a0f69ba4454d

Resolves: tdf#150336 overlapping slot ids

It will be available in 7.5.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 20 Caolán McNamara 2022-08-19 09:45:38 UTC
(In reply to Xisco Faulí from comment #18)
> is there any way to assert this kind of overlapping at build time ?

yeah, I was wondering too:
https://gerrit.libreoffice.org/c/core/+/138515
seems to work and would have caught this problem

We have a related easy hack of bug 146150 to drop things that know the exact id number. it would be nice to be able to arbitrarily renumber these things, though I think the macro recorder records as "slot:", though again we marked that as experimental 10 years ago so its flagged that what that recorder does isn't desirable. In any case we should replace "slot:" in the odk if we could
Comment 21 Commit Notification 2022-08-19 10:22:32 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

https://git.libreoffice.org/core/commit/d3492e15dce1dc8448c6444a92e3e2f7ec19571c

Resolves: tdf#150336 overlapping slot ids

It will be available in 7.4.1.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 22 Commit Notification 2022-08-19 10:52:53 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "master":

https://git.libreoffice.org/core/commit/5dbd9a7bb934fbe182a3fa2423f506563bd1ef8f

tdf#150336 add a static_assert to catch that happening again

It will be available in 7.5.0.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.
Comment 23 Commit Notification 2022-08-19 12:47:51 UTC
Caolán McNamara committed a patch related to this issue.
It has been pushed to "libreoffice-7-4":

https://git.libreoffice.org/core/commit/01a59744e4ebed4e10bea308623afdb6223162da

tdf#150336 add a static_assert to catch that happening again

It will be available in 7.4.1.

The patch should be included in the daily builds available at
https://dev-builds.libreoffice.org/daily/ in the next 24-48 hours. More
information about daily builds can be found at:
https://wiki.documentfoundation.org/Testing_Daily_Builds

Affected users are encouraged to test the fix and report feedback.