Bug 213508 - Closing a navigation pane should shift focus to the document (away from the navigation panel)
Summary: Closing a navigation pane should shift focus to the document (away from the n...
Status: RESOLVED FIXED
Alias: None
Product: okular
Classification: Applications
Component: general (show other bugs)
Version: unspecified
Platform: Fedora RPMs Linux
: NOR wishlist
Target Milestone: ---
Assignee: Okular developers
URL:
Keywords: junior-jobs
Depends on:
Blocks:
 
Reported: 2009-11-07 04:02 UTC by Syam
Modified: 2020-05-27 13:37 UTC (History)
5 users (show)

See Also:
Latest Commit:
Version Fixed In: 1.11.0


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Syam 2009-11-07 04:02:24 UTC
Version:            (using KDE 4.3.1)
OS:                Linux
Installed from:    Fedora RPMs

Use case:
1. Open a PDF document
2. The navigation pane becomes active showing contents or thumbnails
3. The user doesn't want to see them, so clicks on the panel icon to hide the contents/thumbnail pane
4. To scroll the page, the user presses the up/down arrow keys
5. The navigation panes pop out because the navigation panel still has focus

It is now required to click on the document so that scrolling with up/down arrows work as expected. If the user clicks on a navigation panel icon to hide a pane, the intention is clear. So it shouldn't have focus anymore.
Comment 1 Albert Astals Cid 2009-11-09 00:01:32 UTC
I think Pino wanted it to behave this way, Pino can your confirm wheter you want it this way or not and I can work on patch for it?
Comment 2 Syam 2012-05-23 15:52:05 UTC
This (minor) bug exists with Okular 0.14.3 on KDE 4.8.3.
However, the navigation pane no longer pops out when the user presses PgUp/PgDn/Arrow keys.
Comment 3 Albert Astals Cid 2014-05-08 14:55:56 UTC
Ok, i can see the point of focus going back to the main page after clicking to toggle the visibility on an item, don't think it's a bug per se though.
Comment 4 Boris Egorov 2014-11-14 16:46:51 UTC
I think we need an option to show/hide left panel by mouse clicking. It is pretty easy to do with keyboard (F7 or something custom) and by clicking on Settings->Show Navigation Panel.
Hiding is pretty easy - we can add close icon at the bottom of left panel. But how can we show panel again if we want to? It would be nice to have some intuitive solution.
Comment 5 Mayank Choudhary 2019-06-27 10:51:07 UTC
As per Syam request, I have sent a patch here: https://phabricator.kde.org/D22118
Comment 6 Nate Graham 2020-05-27 13:37:46 UTC
Git commit b8b36ae529599da358f433fe23d7bac4dea79fa8 by Nate Graham.
Committed on 27/05/2020 at 13:37.
Pushed by ngraham into branch 'master'.

Improve the sidebar's navigation and UX

Okular's sidebar vertical view chooser toolbar suffers from a few issues:

* It's a nonstandard UI not used for category choosers in other pieces of KDE software,
  and not used in other FOSS document readers
* What is shown and what is hidden is simultaneously too configurable while still not
  offering the desirable UI common to other programs (i.e. no visible category chooser,
  but a sidebar capable of displaying thumbnails, table of contents, search results, etc.)
* With labels on it takes up quite a bit of horizontal space, while with labels off, the
  categories are less than clear
* UX is kind of clunky with nonstandard behaviors (e.g. clicking on the current category
  to hide that category's view while keeping the view chooser visible, showing mostly
  disabled items)
* It's made with custom painting code, which reduces maintainability and introduces bugs
  (e.g. https://bugs.kde.org/show_bug.cgi?id=408190)

This patch removes the vertical category chooser entirely and replaces it with a tabbed
view on the top of the sidebar itself. The tabs are icons-only and have large icons. A
button is added on the left side of the default toolbar to quickly hide or show the
sidebar. In order to make room for the new button, the Previous and Next buttons on the
toolbar are removed, as previous/next buttons are already present on the Page Bar on the
bottom of the window so there's no need to duplicate this functionality. This improves
the UX, fixes a variety of bugs, and deletes a lot of custom code of dubious long-term
maintainability.

![vokoscreenNG-2020-04-16_13-29-24](https://invent.kde.org/graphics/okular/uploads/a1f96a315b69282df51de9993b1befaf/vokoscreenNG-2020-04-16_13-29-24.webm)
Related: bug 334441, bug 344599, bug 408190, bug 335189

FIXED-IN: 1.11.0

CHANGELOG: The sidebar can now be easily shown or hidden with a toolbar button, and the category chooser no longer takes up so much space

M  +-    --    doc/annotations.png
M  +-    --    doc/bookmark-management.png
M  +8    -10   doc/index.docbook
M  +-    --    doc/mainwindow.png
M  +-    --    doc/signatures-panel.png
M  +34   -34   part.cpp
M  +4    -2    part.h
M  +2    -3    part.rc
M  +10   -1    ui/bookmarklist.cpp
M  +11   -1    ui/layers.cpp
M  +11   -1    ui/side_reviews.cpp
M  +21   -654  ui/sidebar.cpp
M  +1    -19   ui/sidebar.h
M  +14   -1    ui/signaturepanel.cpp
M  +23   -0    ui/thumbnaillist.cpp
M  +2    -3    ui/thumbnaillist.h
M  +10   -1    ui/toc.cpp

https://invent.kde.org/graphics/okular/commit/b8b36ae529599da358f433fe23d7bac4dea79fa8