Bug 149050 - .uno:Gallery should open the Gallery deck
Summary: .uno:Gallery should open the Gallery deck
Status: VERIFIED FIXED
Alias: None
Product: LibreOffice
Classification: Unclassified
Component: UI (show other bugs)
Version:
(earliest affected)
7.4.0.0 alpha0+
Hardware: All All
: medium normal
Assignee: Jim Raykowski
URL:
Whiteboard: target:7.4.0
Keywords: needsUXEval
: 148124 (view as bug list)
Depends on:
Blocks: Gallery Sidebar-UI-UX
  Show dependency treegraph
 
Reported: 2022-05-12 12:20 UTC by sdc.blanco
Modified: 2022-07-17 00:54 UTC (History)
4 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 sdc.blanco 2022-05-12 12:20:14 UTC
1. Open Gallery in Sidebar
2. View > Gallery  (Gallery/Sidebar disappears - NOK)
3. Open Properties in Sidebar
4. View > Gallery  (Sidebar disappears)
5. View > Gallery (Sidebar appears on Properties)
6. etc.

In short: 

Actual: .uno:Gallery appears to operate like .uno:Sidebar (Ctrl+F5) 

Expected: .uno:Gallery should behave like .uno:ViewSidebarStyles (F11), and also show the open Sidebar at Gallery.

Version: 7.4.0.0.alpha0+ (x64) / LibreOffice Community
Build ID: 4ea44fdb19e568093ab1e0549c3ffa33296a486b
CPU threads: 8; OS: Windows 10.0 Build 19043; UI render: Skia/Raster; VCL: win
Locale: da-DK (da_DK); UI: en-US
Calc: CL
Comment 1 Heiko Tietze 2022-05-12 13:06:25 UTC
Maybe we better remove View Gallery / .uno:Gallery. Along with View > Sidebar toggling the sidebar with all tabs and View > Navigator showing an extra window (and the other options there) this command seems to be alien.

Stuart, what do you think?
Comment 2 V Stuart Foote 2022-05-12 15:03:54 UTC
Yes, the command resident on the View -> Gallery is somehow incorrect. Assigning the .uno:Gallery to keyboard shortcut it behaves as I'd expect--refocusing an open (collapsed or expanded) SB onto the Gallery Deck

The menu entry for the command will open and close the SB, but it does not open to the expanded Gallery deck, just the collapsed SB.  And then it is not clear the SB Gallery deck is getting focus in response to the .uno launch from menu.

Not clear that the <F11> toggle is behaving either. It will toggle open the SB Style deck from closed SB, and it will close SB when <F11> again used.  But if the SB is opened to Gallery from menu or if .uno:Gallery is assigned to shortcut--the Style shortcut <F11> is non-functional and SB remains on Gallery.

Jim R. had done the set of shortcuts (<Ctrl><Alt> 1-9) for the SB deck Tabs for bug 84502, and those only function when the SB is active.  Did the SB Tab behavior from other UNO get crossed up there?
Comment 3 Jim Raykowski 2022-05-14 03:31:14 UTC
(In reply to V Stuart Foote from comment #2)
> Jim R. had done the set of shortcuts (<Ctrl><Alt> 1-9) for the SB deck Tabs
> for bug 84502, and those only function when the SB is active.
For me the shortcuts function when the SB is active or inactive.

> The menu entry for the command will open and close the SB, but it does not
> open to the expanded Gallery deck, just the collapsed SB.
I wonder if this worked when it was merged. Nevertheless, here is a patch to make it behave as expected:

https://gerrit.libreoffice.org/c/core/+/134297
 
> Not clear that the <F11> toggle is behaving either. It will toggle open the
> SB Style deck from closed SB, and it will close SB when <F11> again used. 
> But if the SB is opened to Gallery from menu or if .uno:Gallery is assigned
> to shortcut--the Style shortcut <F11> is non-functional and SB remains on
> Gallery.
F11 doesn't work in the sidebar when focus is in a deck other than the Styles deck. F11, .uno:DesignerDialog, isn't a toggle command, although we sort of made it so in enhancement bug 101915. When focus is in the Style deck and F11 is pressed the sidebar closes. But, if focus is in the edit window and the Styles deck is visible, pressing F11 will not toggle it closed. I think it's always been this behavior even back when it was a dialog and not a deck. One way to make F11 a toggle command is to use .uno:SidebarDeck.StyleListDeck for the keyboard shortcut. Menu > Tools> Customization > Keyboard tab Sidebar Decks StyleListDeck. 

Or we can hard code this in sfx2/source/sidebar/SidebarDockingWindow.cxx by doing this in SidebarDockingWindow::EventNotify:
  
  if (".uno:DesignerDialog" == aCommand)
  {
     comphelper::dispatchCommand(".uno:SidebarDeck.StyleListDeck", {});
     return true;
  }
Comment 4 Commit Notification 2022-05-15 22:25:35 UTC
Jim Raykowski committed a patch related to this issue.
It has been pushed to "master":

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

tdf#149050 fix .uno:Gallery not opening Gallery deck

It will be available in 7.4.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 5 Heiko Tietze 2022-05-16 12:00:42 UTC
Guess we can resolve fixed now.
Comment 6 V Stuart Foote 2022-05-17 15:40:34 UTC
Thanks Jim!  The Gallery menu entry behaves now. 

The <F11> toggle remains non-affecting when SB is on other decks, should probably adjust as Jim suggests comment 3; otherwise the <Ctrl><Alt>+2 for Styles deck, or better the <Ctrl><Alt>+4 for the Navigator are very handy--if unknown--shortcuts. 

An aside: looking in the Customize -> Keyboard panel at the 'Sidebar Decks' panel, not all the functions from bug 84502 are showing their assigned shortcut keys. The UNO responds to the shortcut, but the Customize dialog is missing the assignment.

2022-05-16 nightly...

Version: 7.4.0.0.alpha1+ (x64) / LibreOffice Community
Build ID: 817b8fe7001a83cb74910eb09b7c14a3b95b8a39
CPU threads: 8; OS: Windows 10.0 Build 19044; UI render: Skia/Vulkan; VCL: win
Locale: en-US (en_US); UI: en-US
Calc: CL
Comment 7 Jim Raykowski 2022-05-17 17:51:41 UTC
(In reply to V Stuart Foote from comment #6)
> An aside: looking in the Customize -> Keyboard panel at the 'Sidebar Decks'
> panel, not all the functions from bug 84502 are showing their assigned
> shortcut keys. The UNO responds to the shortcut, but the Customize dialog is
> missing the assignment.
Decks that are global show their key assignment when the module radio button is set on LibreOffice(Dev).
Comment 8 V Stuart Foote 2022-05-17 18:28:32 UTC
(In reply to Jim Raykowski from comment #7)
> Decks that are global show their key assignment when the module radio button
> is set on LibreOffice(Dev).

Duh, of course. Makes perfect sense for the module specific decks to be separate from the global decks--Properties, StyleList, Gallery, Navigator are global <Ctrl><Alt> 1-4, respectively. 

Shortcuts for Decks specific to the module start after those and are controlled by the radio button.

Thanks for reminiding me of how you'd set it up.
Comment 9 Jim Raykowski 2022-05-19 06:38:16 UTC
(In reply to V Stuart Foote from comment #6)
> ... otherwise the <Ctrl><Alt>+2 for
> Styles deck, or better the <Ctrl><Alt>+4 for the Navigator are very
> handy--if unknown--shortcuts. 
Here is a patch that shows the keyboard shortcut for sidebar tabbar tab buttons that have them:
https://gerrit.libreoffice.org/c/core/+/134594
Comment 10 Aron Budea 2022-07-17 00:54:48 UTC
*** Bug 148124 has been marked as a duplicate of this bug. ***