1. 17 Jul, 2019 5 commits
    • Oliver Sander's avatar
      Make the page outline one physical pixel wide · a0bd9c4d
      Oliver Sander authored
      Pages get a black rectangle around them as 'outline' after
      being rendered.  This rendering was not pixel-perfect at
      fractional scalings: apparently, fractional line widths and
      positions get rounded differently.  The result was that
      sometimes there was a small gap between outline and page.
      
      This pages fixes the problem by making the pen for the
      outline 'cosmetic', i.e., one physical pixel wide.
      With that, its position can be such that it encloses
      the page without any gap.
      a0bd9c4d
    • Oliver Sander's avatar
      Make page boundary rendering more robust · 9b34bfb4
      Oliver Sander authored
      Okular renders a simple 'shadow' at the right and the bottom of each
      page.  The code for this is a bit fragile:  After the page is rendered,
      Okular paints a black outline, and then the shadow.  The shadow is
      a hand-implemented gradient, painted line by line.  Finally, the
      remaining area is painted in the background color.  No pixel is
      ever touched twice.  Unfortunately, the code is buggy, and in hidpi /
      fractional scaling situations, some pixels are never touched.
      This results in rendering glitches as reported in
      
        https://bugs.kde.org/show_bug.cgi?id=383943
      
      Instead of trying to fix the previous approach, this patch makes the
      code more robust by changing the order of the painting operations.
      After painting the page, the code now first paints the background,
      which is now enlarged to cover everything off the page.  Finally,
      the black outline and shadow are drawn on the previously drawn
      background.  This makes sures that no pixel is ever left uninitialized.
      It also allows to simplify the shadow drawing operation a bit.
      
      BUG: 383943
      9b34bfb4
    • Oliver Sander's avatar
      Use range-based for to iterate over a QRegion · f681fb0e
      Oliver Sander authored
      According to
      
        https://doc.qt.io/qt-5/qregion-obsolete.html#rects
      
      the method QRegion::rects is obsolete and should be avoided.
      Let's do that by moving to a range-based for over the QRegion.
      That is easier to read anyway.
      f681fb0e
    • Yuri Chornoivan's avatar
      19186016
    • Nate Graham's avatar
      Add "Open Containing Folder" feature · ea0ea9c9
      Nate Graham authored
      Summary:
      This patch adds an "Open Containing Folder" menu item to the file menu, similar to
      other KDE apps like Gwenview that have it there. This action is especially useful
      for the case when you've downloaded a PDF from the internet that opens itself in
      Okular. The location of this file may not be clear or easy to find without this
      feature, and on several occasiona I have found myself wishing for it when this
      happens.
      
      Test Plan:
      - Delete or move aside `~/.local/config/kxmlgui5/okular/part.rc`
      - Menu item is enabled and works when there is an open document: {F6940449, size=full}
      - Menu item is disabled when there is no open document: {F6940448, size=full}
      
      Reviewers: #okular, aacid, sander
      
      Reviewed By: #okular, aacid
      
      Subscribers: shubham, davidhurka, okular-devel
      
      Tags: #okular
      
      Differential Revision: https://phabricator.kde.org/D22145
      ea0ea9c9
  2. 15 Jul, 2019 1 commit
  3. 14 Jul, 2019 2 commits
  4. 04 Jul, 2019 1 commit
  5. 03 Jul, 2019 5 commits
  6. 02 Jul, 2019 2 commits
  7. 25 Jun, 2019 2 commits
  8. 24 Jun, 2019 2 commits
  9. 23 Jun, 2019 1 commit
    • Bhushan Shah's avatar
      Don't hide the mobile app · 0991819a
      Bhushan Shah authored
      otherwise it doesn't get shown on Plasma Mobile as well, most
      distribution doesn't enable mobile app or splits it in seperate package
      so this should not be problem
      0991819a
  10. 22 Jun, 2019 6 commits
  11. 12 Jun, 2019 1 commit
  12. 10 Jun, 2019 2 commits
  13. 06 Jun, 2019 5 commits
    • Noah Davis's avatar
      Change Text Selection icon to edit-select-text · 2c39981b
      Noah Davis authored
      Summary:
      The current icon (draw-text) is semantically incorrect. This patch makes the Text Selection tool use the icons added in D21632.
      
      BUG: 408391
      FIXED-IN: 1.8.0
      
      Test Plan: {F6874885, size=full}
      
      Reviewers: #vdg, #okular, ngraham
      
      Reviewed By: #vdg, ngraham
      
      Subscribers: okular-devel
      
      Tags: #okular
      
      Differential Revision: https://phabricator.kde.org/D21633
      2c39981b
    • Noah Davis's avatar
      Change Browse icon back to the hand shape · 9310bed6
      Noah Davis authored
      Summary: I changed the `input-mouse` icon so that it would look more like a real mouse. In order to keep the proper icon for the Browse tool, I have to change the icon to `transform-browse`.
      
      Test Plan: {F6874739, size=full}
      
      Reviewers: #okular, #vdg, ngraham
      
      Reviewed By: #vdg, ngraham
      
      Subscribers: ngraham, okular-devel
      
      Tags: #okular
      
      Differential Revision: https://phabricator.kde.org/D21630
      9310bed6
    • Nate Graham's avatar
      In Toolbar's selection mode menu, show "Text Selection" tool by default · e8473354
      Nate Graham authored
      Summary:
      Currently, the Toolbar's selection mode menu shows the rectangular selection mode
      by default, which is not the most useful or commonly used selection mode.
      
      This patch makes the Text Selection tool the one that's shown by default, since that's
      the kind of selection that's the most useful given the sort of document that Okular
      is typically used to view.
      
      Test Plan:
      - Delete `~/.config/okularrc` and `~/.config/okularpartrc`
      - Open Okular
      - See that the selection mode toolbar button shows Text Selection by default:
      {F6874497, size=full}
      
      Reviewers: #okular, #vdg, ndavis
      
      Reviewed By: #vdg, ndavis
      
      Subscribers: ndavis, okular-devel
      
      Tags: #okular
      
      Differential Revision: https://phabricator.kde.org/D21624
      e8473354
    • Nate Graham's avatar
      Use a more conventional dropdown menu style instead of press-and-hold · c7924445
      Nate Graham authored
      Summary:
      Currently, `ToolAction` menus (of which there is only one, the selection tool menu)
      activate the current tool on click, and require a click-and-hold to choose a new tool.
      This is a somewhat unfamiliar user interface that I myself struggled with when initially
      encountering it, and I've encountered user complaints about it as well.
      
      This patch adjusts the behavior so that clicking on the arrow on the right side of the
      button will open the pop-up and allow choosing another tool, which is a more common
      method of implementing the feature. The patch also adjusts the tooltop accordingly.
      
      Test Plan: {F6874466, size=full}
      
      Reviewers: #okular, #vdg, ndavis
      
      Reviewed By: #vdg, ndavis
      
      Subscribers: ndavis, abetts, filipf, okular-devel
      
      Tags: #okular
      
      Differential Revision: https://phabricator.kde.org/D21622
      c7924445
    • Nate Graham's avatar
      Regularize tool names · c325cb41
      Nate Graham authored
      Summary:
      Currently, some of the items in the {nav Tools} menu have "tool" in the name, and some
      do not. This is in any event redundant since they're in a menu with that word in it
      already. In the toolbar, these actions become more inconsistent since their names change
      and can even differ between what's shown in the pop-up menu and what's shown on the
      button text.
      
      This patch regularizes the names, stops changing the names for the toolbar versions, and
      updates the docbook accordingly.
      
      Test Plan:
      {F6874459, size=full}
      
      {F6874458, size=full}
      
      Reviewers: #okular, #vdg, filipf
      
      Reviewed By: #vdg, filipf
      
      Subscribers: filipf, okular-devel, kde-doc-english
      
      Tags: #okular, #documentation
      
      Differential Revision: https://phabricator.kde.org/D21621
      c325cb41
  14. 04 Jun, 2019 2 commits
  15. 03 Jun, 2019 3 commits