1. 20 May, 2021 2 commits
  2. 26 Apr, 2021 1 commit
  3. 26 Mar, 2021 1 commit
  4. 22 Mar, 2021 1 commit
  5. 18 Mar, 2021 2 commits
  6. 01 Feb, 2021 1 commit
  7. 09 Dec, 2020 1 commit
  8. 17 Nov, 2020 2 commits
  9. 02 Nov, 2020 1 commit
  10. 23 Oct, 2020 1 commit
  11. 13 Oct, 2020 1 commit
  12. 22 Sep, 2020 1 commit
    • Michael Augaitis's avatar
      Fix ESC key not exiting fullscreen when viewing image · f5cb19e8
      Michael Augaitis authored and Nate Graham's avatar Nate Graham committed
      The event filter was not catching the QEvent::ShortcutOverride
      event in browsemainpage.cpp and therefore when the ESC
      key was pressed, gwenview would browse images instead
      of leaving fullscreen. This commit ensures that when
      the ESC key is pressed the first time, gwenview will
      exit fullscreen and will browse images on second key
      press.
      
      BUG: 425479
      f5cb19e8
  13. 27 May, 2020 1 commit
  14. 09 Jan, 2020 1 commit
  15. 06 Sep, 2019 1 commit
  16. 12 Aug, 2019 1 commit
  17. 27 Feb, 2019 1 commit
  18. 13 Jan, 2019 1 commit
  19. 23 Dec, 2018 1 commit
    • Peter Mühlenpfordt's avatar
      Use FlowLayout for Crop toolbar · a420ba69
      Peter Mühlenpfordt authored and Nate Graham's avatar Nate Graham committed
      Summary:
      The Crop toolbar with enabled {nav Advanced settings} is very wide
      and it's not possible to make the Gwenview window smaller with this
      toolbar visible.
      Using a FlowLayout for the Crop toolbar avoids this issue and breaks
      the bar into multiple lines if there is not enough horizontal space.
      
      Before:
      {F6251679}
      
      After:
      {F6251681}
      
      Test Plan:
      * Check Crop toolbar behaviour while resizing Gwenview window
      * Check Crop toolbar with {nav Advanced settings} en-/disabled
      * Check RedEye toolbar (uses the same `SlideContainer`)
      * Check SaveBar after modifying images (uses `SlideContainer`)
      * Check Browse Mode {nav Add Filter} (uses `FlowLayout`)
      
      Reviewers: #gwenview, ngraham
      
      Reviewed By: #gwenview, ngraham
      
      Subscribers: shubham, loh.tar, ngraham
      
      Tags: #gwenview
      
      Differential Revision: https://phabricator.kde.org/D15398
      a420ba69
  20. 01 Nov, 2018 1 commit
  21. 21 Aug, 2018 1 commit
    • __ __'s avatar
      Improve keyboard handling for focused buttons in Crop and Reduce Red Eye tools · df8cb1ab
      __ __ authored
      Summary:
      Both {nav Crop} and {nav Reduce Red Eye} feature a {nav Cancel} button.
      While normally pressing {key Enter} or {key Space} while a button has
      keyboard focus should trigger the button's action, in this case
      incorrect actions were executed: {key Enter} accepted the modifications,
      i.e. it did the opposite of what the label said, and {key Space} even
      jumped to the next image.
      
      For {key Enter} this can be solved by explicitely checking for keyboard
      focus, which avoids the underlying problem, i.e. that
      `ViewMainPage::slotEnterPressed` calls `*Tool::keyPressEvent` before
      `QDialogButtonBox` had a chance to handle the event. For {key Space}
      forwarding in `ViewMainPage::eventFilter` is enough to override the
      default shortcut handler, since `*Tool::keyPressEvent` will implicitely
      call `event->accept()`.
      
      Note that this also prevents {key Space} from navigating to the next
      image even when the buttons are not focused. We could bring that back,
      but it would actually be more consistent if we did not, since the arrow
      keys are also blocked when a tool is active. To still navigate away
      while a tool is active, users can set a secondary shortcut for
      {nav Next} to avoid getting in conflict with how {nav Space} is supposed
      to work on buttons.
      
      FIXED-IN: 18.08.1
      
      Test Plan:
      Use {key Tab} to focus any of the buttons in the {nav Crop} and
      {nav Reduce Red Eye} tools, and press {key Enter} and {key Space}. Both
      shortcuts should trigger the appropriate action, i.e. either {nav OK} or
      {nav Cancel} depending on the button.
      
      Press the same shortcuts while the image is focused. {key Space} should
      do nothing, and {key Enter} should accept.
      
      Reviewers: #gwenview, muhlenpfordt
      
      Reviewed By: #gwenview, muhlenpfordt
      
      Subscribers: ngraham, muhlenpfordt
      
      Tags: #gwenview
      
      Differential Revision: https://phabricator.kde.org/D14925
      df8cb1ab
  22. 07 Aug, 2018 1 commit
  23. 26 Jul, 2018 1 commit
  24. 26 Jun, 2018 1 commit
  25. 02 Jun, 2018 1 commit
    • Huon Imberger's avatar
      Allow dragging files/folders to View mode · 131d2585
      Huon Imberger authored
      Summary:
      Specifically accepts drop events within the viewport of {nav View} mode.
      If a folder that contains images is dropped, it will open that folder
      and remain in {nav View} mode with the first image selected. If the
      folder doesn't contain images, it switches to {nav Browse} mode.
      Dragging multiple items is supported but only the first item is opened.
      
      BUG: 169408
      FIXED-IN: 18.08.0
      
      {F5781556}
      
      Test Plan:
      Test with different image formats, as well as unsupported format (Gwenview
      should display a nice error).
      Test with folder (with and without images within).
      {nav Browse} mode and the {nav Thumbnail Bar} drag drop should work as before.
      Drop operations should not be accepted anywhere else in the GUI where they aren't
      already supported. In other words, this should only add drop functionality to the
      {nav View} viewport.
      
      Ensure drops are only accepted for URL mimetypes (e.g. ignore text).
      
      Reviewers: #gwenview, rkflx, ngraham
      
      Reviewed By: #gwenview, rkflx
      
      Tags: #gwenview
      
      Differential Revision: https://phabricator.kde.org/D11879
      131d2585
  26. 09 May, 2018 1 commit
    • Huon Imberger's avatar
      Disable View mode shortcuts outside of View mode · f0edb69f
      Huon Imberger authored
      Summary:
      The document view zoom actions like {nav Zoom to Fit} only apply to
      {nav View} mode.
      In the case of {nav Zoom to Fit}, the default keyboard shortcut is
      {key F}, which interferes with single-letter keypresses in {nav Browse}
      mode (to skip to files starting with that letter).
      
      There is an existing function that enables or disables these {nav View}
      mode actions based on whether `ViewMainPage` is visible, however this
      function isn't called when leaving {nav View} mode. This patch ensures
      that these actions are updated when `ViewMainPage` is reset, ensuring
      these actions are disabled when {nav View} mode is not active.
      
      Test Plan:
      Ensure default {key F} shortcut for {nav Zoom to Fit} is set.
      Go to {nav Browse} in a folder containing at least one image starting with F.
      Press {key F} - selection to jump to that image.
      Go to {nav {View}, and ensure {key F} triggers {nav Zoom to Fit}.
      Go back to {nav Browse} and ensure {key F} still works as previously.
      
      Reviewers: #gwenview, rkflx
      
      Reviewed By: #gwenview, rkflx
      
      Subscribers: ngraham, rkflx
      
      Tags: #gwenview
      
      Differential Revision: https://phabricator.kde.org/D11633
      f0edb69f
  27. 08 May, 2018 1 commit
    • Huon Imberger's avatar
      Disable View mode shortcuts outside of View mode · 20b198b4
      Huon Imberger authored
      Summary:
      The document view zoom actions like {nav Zoom to Fit} only apply to
      {nav View} mode.
      In the case of {nav Zoom to Fit}, the default keyboard shortcut is
      {key F}, which interferes with single-letter keypresses in {nav Browse}
      mode (to skip to files starting with that letter).
      
      There is an existing function that enables or disables these {nav View}
      mode actions based on whether `ViewMainPage` is visible, however this
      function isn't called when leaving {nav View} mode. This patch ensures
      that these actions are updated when `ViewMainPage` is reset, ensuring
      these actions are disabled when {nav View} mode is not active.
      
      Test Plan:
      Ensure default {key F} shortcut for {nav Zoom to Fit} is set.
      Go to {nav Browse} in a folder containing at least one image starting with F.
      Press {key F} - selection to jump to that image.
      Go to {nav {View}, and ensure {key F} triggers {nav Zoom to Fit}.
      Go back to {nav Browse} and ensure {key F} still works as previously.
      
      Reviewers: #gwenview, rkflx
      
      Reviewed By: #gwenview, rkflx
      
      Subscribers: ngraham, rkflx
      
      Tags: #gwenview
      
      Differential Revision: https://phabricator.kde.org/D11633
      20b198b4
  28. 25 Apr, 2018 1 commit
    • Huon Imberger's avatar
      Display document count labels in View, Browse, and Full Screen modes · 14199f3b
      Huon Imberger authored
      Summary:
      {nav Browse} mode: The existing total count is now split into images
      and videos, e.g. "5 images, 3 videos". When 2 or more documents (that
      is, images or videos) are selected, the label changes to display how
      many are selected and their total size. E.g. "4 of 10 selected (3.4
      MiB).
      
      {nav View} mode: A new label in the status bar, showing the current
      document index, and total in the folder, e.g. "32 of 753". This label is
      hidden in Lighttable mode, and elided if there's no room for it.
      
      {nav Full Screen} mode: Similar to {nav View}, the current index and
      total count is displayed. This is in the format "32 of 753", and is
      anchored to the bottom right of the information panel.
      
      Each mode calculates these values independently. This is because for
      {nav View} and {nav Full Screen}, the thumbnail bar model has already
      filtered out any item that isn't viewable, therefore it's easy to simply
      get the current index and total items. In {nav Browse}, folders and
      archives are displayed, so there needs to be extra logic that filters
      them out appropriately.
      
      BUG: 203042
      FIXED-IN: 18.08.0
      
      Browse:
      {F5811297}
      
      Browse (with selection):
      {F5811298}
      
      View:
      {F5811299}
      
      View (compare):
      {F5811300}
      
      Full Screen:
      {F5814068}
      
      Full Screen (large thumbnails):
      {F5814069}
      
      Full Screen (thumbnail bar disabled):
      {F5814071}
      
      Test Plan:
      Browse:
        - Only images and videos should be counted (directories and archives
        ignored).
        - Label should change to "Selected..." when 2 or more images/videos
        selected
      
      View:
        - Count/index should match the thumbnail view, i.e., only items in the
        thumbnail bar should be counted.
        - Changes to documents should be reflected in the index and total:
          - Renaming causing a change in sort order
          - Adding/deleting documents
        - Document count label should be hidden in Compare/Lighttable mode to
        allow room for the Synchronize checkbox
      
      Full Screen View:
        - Same as View above, plus;
        - Enable/disable the thumbnail bar
        - Enable and resize the thumbnail bar
        - View images with long filesnames, and/or addition meta info enabled
        - In Compare/Lighttable mode, current document index should reflect the
        currently selected image
      
      Reviewers: #gwenview, rkflx
      
      Reviewed By: #gwenview, rkflx
      
      Subscribers: rkflx, muhlenpfordt
      
      Tags: #gwenview
      
      Differential Revision: https://phabricator.kde.org/D12301
      14199f3b
  29. 09 Apr, 2018 1 commit
    • Huon Imberger's avatar
      Improve Image View fade transitions · 25fb575e
      Huon Imberger authored
      Summary:
      This patch fixes three problems:
      
        # After D11630, fading to a raster image with alpha channel and 'None'
        background resulted in the old image showing through the transparent
        parts of the new image, then disappearing.
        # Switching to an SVG from a raster image resulted in the raster image
        not fading, then disappearing suddenly at the end of the animation.
        This was an issue before D11630.
        # When OpenGL is used for animations, the full screen background texture
        appears during animations then disappears.
      
      Problem 1 was due to `DocumentView::setEraseBorders`, which effectively
      filled the background of the document view, leaving the parts within
      the image transparent. This was okay before D11630 because the
      background behind the image was never visible, it was always filled with
      the image itself, or a solid color / checkerboard pattern.
      This patch fixes the problem by always filling the background with the
      default brush, not just the borders.
      
      Problem 2 is fixed at the same time because the code that erased the
      borders had no effect on SVGs because the calculated image rect was the
      same size as the document view.
      
      Problem 3 is fixed by using `QGraphicsOpacityEffect` instead of directoy
      setting the opacity using `setOpacity`.
      
      Depends on D11630
      
      BUG: 373161
      FIXED-IN: 18.08.0
      
      ## Problem 1 Before
      {F5776639}
      
      ## Problem 2 Before
      {F5776643}
      
      ## After
      (White background to show it doesn't shine through)
      {F5783594}
      
      Test Plan:
      Test the transition between images in Image {nav View}, with the 'None'
      transparent background option enabled. Should test between the folowing
      types of images:
      
        - Large raster with no alpha channel, e.g. a wallpaper
        - Raster image with alpha channel
        - SVG
      
      Animation should be smooth with no artifacts. The main view background
      shouldn't be visible behind the image during the fade.
      
      {nav View} with animations turned off should work as expected.
      
      Full screen should show a textured background with OpenGL animations, i.e.,
      no different than with Software animations.
      
      Reviewers: #gwenview, rkflx, ngraham
      
      Reviewed By: #gwenview, rkflx, ngraham
      
      Tags: #gwenview
      
      Differential Revision: https://phabricator.kde.org/D11795
      25fb575e
  30. 04 Apr, 2018 1 commit
    • Peter Mühlenpfordt's avatar
      Set focus back to image view after leaving edit tool · 7369f471
      Peter Mühlenpfordt authored
      Summary:
      If you click on the toolbar of an image edit tool (crop, redeye)
      the focus is lost after leaving the tool and you cannot switch images
      with cursor keys.
      This patch resets the focus to image view after leaving the edit tool.
      
      BUG: 321091
      
      Test Plan:
      * Open image in Gwenview View Mode (normal or fullscreen)
      * Start crop tool ({key Shift C})
      * Click on {nav Crop} or {nav Cancel}
      * Switching images with cursor keys should work as usual
      
      Reviewers: #gwenview, rkflx
      
      Reviewed By: #gwenview, rkflx
      
      Subscribers: rkflx, huoni
      
      Differential Revision: https://phabricator.kde.org/D11899
      7369f471
  31. 26 Feb, 2018 1 commit
    • Huon Imberger's avatar
      Fix thumbnail bar in View resetting to OFF when quitting in fullscreen · 75f1996c
      Huon Imberger authored and __ __'s avatar __ __ committed
      Summary:
      Quitting Gwenview was saving the current state of the {nav Thumbnail Bar}, which is always
      hidden in fullscreen, and therefore was always saving an OFF state to the config.
      This patch saves the state of the {nav Thumbnail Bar} before going to fullscreen.
      
      Test Plan:
      Go to {nav View}, toggle {nav Thumbnail Bar} on, go to fullscreen, press {key Ctrl Q} to quit.
      After launching Gwenview again, {nav View} {nav Thumbnail Bar} should be visible.
      
      Reviewers: #gwenview, rkflx
      
      Reviewed By: #gwenview, rkflx
      
      Differential Revision: https://phabricator.kde.org/D10785
      75f1996c
  32. 19 Feb, 2018 2 commits
    • Peter Mühlenpfordt's avatar
      Keep statusbar visibility in sync with KToggleAction and persist states · c2e8c892
      Peter Mühlenpfordt authored
      Summary:
      When switching to fullscreen view mode the statusbar is hidden but the
      `KToggleAction` is not updated. This leads to unhiding the statusbar
      after applying config dialog and forcing the user to press {key F3}
      twice to show the statusbar.
      This patch keeps visibility and action state in sync by using persistent
      `GwenviewConfig` values for browse mode and normal/fullscreen view
      modes like sidebar.
      
      Test Plan:
      Switch browse/view, normal/fullscreen modes.
      The statusbar state should always restore to previous setting.
      Three different states are (re)stored:
      * Browse mode (always equal in normal/fullscreen mode)
      * View mode normal (windowed) mode
      * View mode fullscreen mode
      
      Reviewers: #gwenview, rkflx
      
      Reviewed By: #gwenview, rkflx
      
      Subscribers: rkflx
      
      Differential Revision: https://phabricator.kde.org/D10577
      c2e8c892
    • Huon Imberger's avatar
      Improve selection and hover colors in the thumbnail bars · 543f0b9c
      Huon Imberger authored and __ __'s avatar __ __ committed
      Summary:
      The visual feedback when hovering, especially in the fullscreen thumbnail bar,
      was too weak. I've fixed this by improving the hover background color, and
      applying a stylesheet to the fullscreen thumbnail bar.
      
      Before:
      {F5713490, loop, autoplay}
      {F5713491, loop, autoplay}
      
      After:
      {F5717013, loop, autoplay}
      {F5717011, loop, autoplay}
      
      Test Plan:
      Thumbnail bar colors in both `View` mode and fullscreen `View` should provide
      good visual feedback (hover and select).
      
      Reviewers: #gwenview, rkflx
      
      Reviewed By: #gwenview, rkflx
      
      Subscribers: rkflx, ngraham
      
      Differential Revision: https://phabricator.kde.org/D10564
      543f0b9c
  33. 18 Feb, 2018 1 commit
    • Huon Imberger's avatar
      Fix color palette changing after saving config in fullscreen · 7dbda5ae
      Huon Imberger authored
      Summary:
      If one opens the config with a keyboard shortcut in fullscreen mode, changes something,
      and saves it, the color palette reverts to Normal (non-fullscreen), most noticeably changing
      the background color.
      
      This fix checks the fullscreen state when applying color palettes.
      
      Test Plan: Change config while in fullscreen - colors should stay the same.
      
      Reviewers: #gwenview, rkflx, muhlenpfordt
      
      Reviewed By: #gwenview, rkflx, muhlenpfordt
      
      Subscribers: muhlenpfordt
      
      Differential Revision: https://phabricator.kde.org/D10501
      7dbda5ae
  34. 15 Feb, 2018 1 commit
    • Peter Mühlenpfordt's avatar
      Fix squished toolbar buttons in fullscreen view mode · ce61ed46
      Peter Mühlenpfordt authored
      Summary:
      In fullscreen view mode the sidebar splitter can be moved to the right
      until the toolbar buttons are squished a bit.
      This is caused by a missing layout connection which would propagate
      the correct minimum size hints. Since the toolbar in view mode
      overlaps the image view a standard layout is not usable here.
      This patch sets a minimum size hint for the image view according to
      the internal layout of the overlay toolbar width.
      
      {F5690953}
      
      Test Plan:
      1. Open gwenview in fullscreen view mode
      2. Move sidebar splitter to right just before collapsing
      -> The buttons of the top toolbar should remain in original size
      
      Checked to correctly adjust width while:
      * Toggling status bar ({key F3})
      * Toggling {nav Show thumbnails}
      * Opening images with different length filenames (thumbnails off)
      
      Reviewers: rkflx, ngraham, #gwenview
      
      Reviewed By: rkflx
      
      Differential Revision: https://phabricator.kde.org/D10458
      ce61ed46
  35. 14 Feb, 2018 1 commit
  36. 11 Feb, 2018 1 commit
    • __ __'s avatar
      Clean up code tracking fullscreen state · 140393d0
      __ __ authored
      Summary:
      After syncing Gwenview's fullscreen mode with that of the window manager
      in 0d917337, we can just ask the window for its fullscreen state
      instead of having to track this for ourselves.
      
      This gets rid of a bunch of `bools` and reduces chances those might
      accidentally get out of sync at some point. In addition, we can
      eliminate duplication and dependence on execution order in
      `MainWindow::toggleFullScreen`.
      
      Test Plan:
      - `qDebug()` comparing `mFullScreenMode` and `window()->isFullscreen()`
      - Manual testing of every functionality affected:
        - Switching to and from fullscreen mode (both via Gwenview and window manager).
        - {key Esc} to exit fullscreen mode.
        - Special fullscreen toolbar works.
        - Toggling sidebar resizes fullscreen toolbar.
        - Sidebar state remembered separately for normal and fullscreen mode.
        - Savebar not visible in fullscreen mode.
        - Memory warning bar still works in fullscreen mode.
      
      Reviewers: muhlenpfordt
      
      Reviewed By: muhlenpfordt
      
      Differential Revision: https://phabricator.kde.org/D10412
      140393d0