1. 17 Dec, 2017 3 commits
  2. 16 Dec, 2017 2 commits
    • Jehan's avatar
      plug-ins: add a SCREENSHOT_CAN_SHOOT_WINDOW capability. · 80490a2c
      Jehan authored
      And add the relevant option for when such capability is absent. Right
      now it is absent only from the new Freedesktop API.
      80490a2c
    • Jehan's avatar
      plug-ins: implementation of the Freedesktop portal for screenshot. · 53a03b38
      Jehan authored
      I am told by the GNOME/Flatpak people that this is what we will
      ultimately need to implement. Basically this portal is supposed to work
      everywhere, in sandboxes (Flatpak, hopefully Snap too?), but also out
      of sandboxes, i.e. in GNOME and KDE, whether Wayland or X11. So that
      should be the unique API we will have to implement in the end, and every
      desktop environment/sandbox will need to implement this API (which is
      good!).
      Apparently it is not part of default GNOME yet, but has to be installed
      separately (on Fedora, package is xdg-desktop-portal-gtk for GNOME and
      xdg-desktop-portal-kde for KDE).
      
      Now there are currently many shortcomings, and in particular, the
      screenshot API has apparently no advanced features (at all!). No window
      snap, no rectangular selection, no delaying, no choice on including
      cursor or decoration, nothing! Apparently this is normal that the API
      presents no feature, because "the API itself is not meant to specify the
      details how the screenshot is obtained. Instead the portal will present
      the user a dialog to take a screenshot, and that screenshot will be
      given back to the sandboxed app".
      This is acceptable behavior, except that currently, the dialog has none
      of the basic features so this is a very bad regression. This is why I
      test the freedesktop API last, which basically means it will likely
      never be actually used. That's on purpose. At least, the code is in and
      will be easy to improve later. Of course, when the Freedesktop portal
      for screenshot will finally be featureful, it is meant to be tested
      first.
      
      See: https://github.com/flatpak/xdg-desktop-portal/blob/master/data/org.freedesktop.portal.Screenshot.xml
      53a03b38
  3. 13 Dec, 2017 2 commits
    • Jehan's avatar
    • Jehan's avatar
      Bug 791397 - Gimp import multi page PDF only imports first page. · a207570c
      Jehan authored
      Poppler and poppler-data are now hard dependencies.
      PDF is a common-enough format nowadays that import support is likely
      considered as a granted feature by everyone. Moreover the current
      fallback to the PostScript plug-in for PDF support just gives a degraded
      experience with less features (and probably a lot of bugs since
      basically nobody uses this code).
      Poppler-data is also considered mandatory because non-western language
      support should never be considered an "option". People using non-western
      languages are not second class citizens and therefore if we say that PDF
      import is now a hard feature, it should also include PDF using CJK or
      Cyrillic languages.
      a207570c
  4. 12 Dec, 2017 1 commit
  5. 10 Dec, 2017 11 commits
    • Jehan's avatar
      plug-ins: auto-detect HGT variants. · e0c36f3e
      Jehan authored
      Since SRTM-1 and SRTM-3 data have a fixed image size, it is actually
      very easy to auto-detect these by checking the file size. There is no
      need to ask the user to select between the 2 variants (even though these
      values are made quite obvious by official download links).
      I still left the dropdown appear optionally if the detection fails for
      some reason (we never know, at least that makes a fallback, for instance
      to be able to load partial data!). Yet now by default, HGT file settings
      should be fully auto-detected.
      e0c36f3e
    • Jehan's avatar
      plug-ins: update file-hgt-load description... · 43f7a437
      Jehan authored
      ... and minor space and indentation fix.
      43f7a437
    • Jehan's avatar
      plug-ins: properly set returned error in pdb call. · 7fce78b2
      Jehan authored
      g_set_error() so that when samplespacing is not a valid argument for
      file-hgt-load, the error is properly propagated.
      Also add a g_warning() to get the error in the terminal as well.
      7fce78b2
    • Jehan's avatar
      plug-ins: s/GimpPluginPrintError/GimpPluginPDFError/ · 538590ed
      Jehan authored
      Likely a copy-paste typo. Nothing serious, but since I saw it, let's fix
      it.
      538590ed
    • Jehan's avatar
      plug-ins: register a separate load handler file-hgt-load for HGT files. · 35597db9
      Jehan authored
      This allows for it to show as a separate item in the open dialog, with
      proper naming. Also add proper arguments so that the handler works as a
      PDB function in non-interactive mode, unlike file-raw-load which works
      only interactively.
      35597db9
    • Jehan's avatar
    • Jehan's avatar
      plug-ins: macOS screenshot has both window pick and delay-after-pick... · dbf97dbc
      Jehan authored
      ... capabilities.
      This is untested, just reading the docs of "screencapture" tool we use
      for macOS support. Hopefully it's all fine! :-)
      dbf97dbc
    • Jehan's avatar
      plug-ins: force at least 0.5s delay to full-screen screenshots on KDE. · 9b82bc3e
      Jehan authored
      The plug-in dialog GUI was always visible in my full-screen screenshots
      on KDE, when no delay. It seems the culprit is their fading out effect
      which takes longer than the screenshot to happen, therefore the dialog
      was showing up with transparency.
      9b82bc3e
    • Jehan's avatar
      plug-ins: add SCREENSHOT_CAN_DELAY_WINDOW_SHOT capability to screenshot. · f9076ae2
      Jehan authored
      This indicates if a delay can be inserted in-between the window pick and
      the actual shot. This is indeed not always possible, for instance using
      KWin API. Obviously this feature is only meaningful if
      SCREENSHOT_CAN_PICK_WINDOW feature is enabled as well. For instance X11
      screenshot has the feature, but GNOME won't need it since there is no
      window selection (it simply snaps whatever is the active window).
      f9076ae2
    • Jehan's avatar
      plug-ins: oups duplicate select_delay with KWin screenshots. · 01c39c8f
      Jehan authored
      Small fix on previous commit.
      01c39c8f
    • Jehan's avatar
      plug-ins: differentiate a delay before the area/window selection... · b57c89dd
      Jehan authored
      ... and a delay before the screenshot.
      Until now, there was only delay before selection, which I changed in
      commits d9cd4b61 and 614bcf6d. Actually a delay before selection may
      also be useful, for instance when you use a tablet without keyboard (no
      alt-tab possible) and the window/area you wish to capture is behind GIMP
      window. Then you'd want to interact with the desktop with the pointer
      before the cursor changes for selection interaction.
      I add some logics so that the selection delay doesn't show when it is
      unecessary (for instance for full-screen screenshot, or when the window
      screenshot is based on the active window, not click selection, like with
      GNOME shell API).
      b57c89dd
  6. 09 Dec, 2017 8 commits
    • Jehan's avatar
      plug-ins: leave a message for translators. · 733b2344
      Jehan authored
      "Digital Elevation Model" (DEM) is a technical term which therefore
      cannot be translated just by its meaning.
      733b2344
    • Jehan's avatar
      plug-ins: let's special-case just a bit the HGT data. · b78b14b1
      Jehan authored
      - Display title "Digital Elevation Model data" instead of just "Image".
      - Don't show the type combo anymore, since HGT is always 16-bit signed
        integer in big endian.
      - Don't show the width and height either, but instead show a dropdown
        list to choose between either SRTM-1 or SRTM-3 data. There seems to be
        only these 2 types of data, and this will determine the width and
        height. This choice (SRTM-1 vs 3) will mostly likely be better known
        by people than knowing what image dimension they have to set,
        especially since official links for such files seem to all include the
        information.
      b78b14b1
    • Jehan's avatar
      plug-ins: minor cleaning and fixes. · 88ccdb4e
      Jehan authored
      - Add some parentheses to sizeof (*pointer). Maybe it's just me, but it
        is just a bit clearer to me.
      - Free in_raw when out_raw allocation failed.
      - Use strrchr() instead of strchr() to get the extension (I had a case
        when testing where the file was inside a folder named similarly with a
        ".hgt" and it would break the comparison test).
      - Do a case-insensitive comparison. Even though the original files from
        NASA use lowercase, just to be sure.
      88ccdb4e
    • Massimo Valentini's avatar
      Bug 771661: Extend the raw data import plugin to open .hgt files · c572bdf6
      Massimo Valentini authored
      add support to load single channel 16 bit, signed/unsigned,
      little/big endian 2d raster data as a 16 bit RGB gamma GIMP image
      c572bdf6
    • Jehan's avatar
      plug-ins: s/Windows.h/windows.h/. · 36daa6db
      Jehan authored
      I just cross-compiled for Windows after a long time. The header file is
      all lowercase on a cross-compilation MinGW-w64 environment. I'm not sure
      what is the case on Windows, but since this platform is case-insensitive
      for file names, I believe this won't break anything on native builds.
      36daa6db
    • Jehan's avatar
      plug-ins: fix a bunch of coding style. · bf13c13e
      Jehan authored
      The screenshot-win32.c file was absolutely not following our coding
      style. A lot of things are still wrong (like camelCase functions), but
      at least I fixed a bunch of indentations, space between function and
      arguments, alignments, curly brackets at start of lines, etc.
      bf13c13e
    • Jehan's avatar
      Bug 791352 - Screenshot delay is broken for region shots in GNOME. · 614bcf6d
      Jehan authored
      Delay should indeed happen before root and window screenshots, but must
      happen in-between region selection and region screenshot.
      
      One can notice that the logics is different for Windows screenshot in
      X11. The reason is that X11 window screenshot has an additional window
      selection step (and therefore delay must happen in between selection and
      actual screenshot). Window screenshot in Wayland doesn't have this step
      and simply screenshots whatever is the currently active Window.
      614bcf6d
    • Jehan's avatar
      Bug 791352 - Screenshot delay is broken for region-grab screenshot. · d9cd4b61
      Jehan authored
      Fix first the delay in X11.
      Actually both for region and window screenshots, it makes no sense to
      delay *before* region or window selection. Usually when one uses a
      delay, the point is to prepare in-between selection and shot. For
      instance, I often used a delay to snap the contents of a menu because
      PrintScreen key would not work when a menu is opened. So I would set a
      delay, select my window/region, then quickly open the menu before the
      delay is counting down. This would not be possible with the way delay
      occurred (before selection), which just has no use that I can see of.
      d9cd4b61
  7. 08 Dec, 2017 2 commits
  8. 06 Dec, 2017 1 commit
    • Ell's avatar
      plug-ins: in file-psd, insert layers to image after writing buffers · 67e68575
      Ell authored
      When loading PSDs, insert layers to the image as the last step of
      layer creation, after writing the pixel data to their buffers, so
      that the data of child layers is available when their parent
      group's projection is subseqeuently invalidated; otherwise, we'd
      need an additional gimp_drawable_update() call after writing the
      data to the buffers.
      67e68575
  9. 03 Dec, 2017 1 commit
  10. 26 Nov, 2017 1 commit
    • Jehan's avatar
      plug-ins: make Darktable version checking more generic. · 1e78d3d2
      Jehan authored
      I realize that on Fedora 27, the output of `darktable --version` is:
      "this is darktable darktable-2.2.5-4.fc27"
      This is different from the expected output in our plug-in ("this is
      darktable 2.2.5"). I assume this version string can be customized and
      distribution packagers will use the capability. So a regular expression,
      in a slightly more flexible fashion would be better. I still assume that
      the version string with start with "this is darktable", but then I
      accept any non-number string until I reach a common major.minor.patch
      version-looking string.
      1e78d3d2
  11. 20 Nov, 2017 1 commit
  12. 11 Nov, 2017 2 commits
    • Ell's avatar
      Bug 789981 - Wrong layer structure in PSDs with deeply nested layer groups · 54ec9373
      Ell authored
      Photoshop CS5 adds support for layer groups whose nesting depth is
      above 5.  The end markers of these groups use an undocumented
      "lsdk" key for their section dividers, rather than the usual
      "lsct".  This caused the PSD plugin to treat them as regular
      layers, resulting in wrong layer-tree structure.
      
      Add support for "lsdk" section dividers upon loading, and also
      generate "lsdk" section dividers upon saving sufficiently-deep
      groups.
      54ec9373
    • Ell's avatar
      plug-ins: in file-psd, repalce tabs with spaces · 6708af39
      Ell authored
      6708af39
  13. 29 Oct, 2017 1 commit
    • Ell's avatar
      Bug 786844 - Wavelet decompose plugin changes image slightly · 70881728
      Ell authored
      (AKA Issue with grain merge layer mode)
      
      Fall back to using the legacy grain-extract/merge modes when the
      input image precision is integer, and only use the non-legacy modes
      when the precision is floating point.  The midpoint intensity value
      of the non-legacy modes is 0.5, which isn't representable exactly
      using integer precision, causing small deviations between the input
      image and the reconstructed image.
      70881728
  14. 25 Oct, 2017 1 commit
  15. 24 Oct, 2017 1 commit
  16. 22 Oct, 2017 2 commits