1. 14 Nov, 2018 1 commit
    • Jehan's avatar
      app, libgimpbase: add GIMP_SELECT_CRITERION_LINE_ART selection type. · 8ed12b1b
      Jehan authored
      This commit implements part of the research paper "A Fast and Efficient
      Semi-guided Algorithm for Flat Coloring Line-arts" from the GREYC (the
      people from G'Mic). It is meant to select regions from drawn sketchs in
      a "smart" way, in particular it tries to close non-perfectly closed
      regions, which is a common headache for digital painters and colorists.
      
      The implementation is not finished as it needs some watersheding as well
      so that the selected area does not leave "holes" near stroke borders.
      The research paper proposes a new watersheding algorithm, but I may not
      have to implement it, as it is more focused on automatic colorization
      with prepared spots (instead of bucket fill-type interaction).
      
      This will be used in particular with the fuzzy select and bucket fill
      tools.
      
      Note that this first version is a bit slow once we get to big images,
      but I hope to be able to optimize this.
      Also no options from the algorithm are made available in the GUI yet.
      8ed12b1b
  2. 10 Nov, 2018 2 commits
    • Ell's avatar
      Issue #2470 - Spacing between grid lines does not stay at 1px ... · 658d9f3a
      Ell authored
      ... as I would like it to.
      
      Use GimpSpinButton, added in the previous commit, in GimpSizeEntry,
      instead of GtkSpinButton.  This avoids updating the spin-buttons'
      adjustment values when they lose focus, truncating the value if it
      can't be accurately displayed using the corresponding spin-button's
      digit count.  Since size-entries can have multiple spin-buttons
      using different units, this prevents the value from changing when
      entring a value using one unit, and then shifting the focus to, but
      not changing, another unit.
      658d9f3a
    • Ell's avatar
      libgimpwidgets: add GimpSpinButton · 7ab9ee26
      Ell authored
      GimpSpinButton is a drop-in replacement for (and a subclass of)
      GtkSpinButton.  Unlike GtkSpinButton, it avoids updating the
      adjustment value when losing focus, unless the entry text has
      changed.  This prevents accidental loss of precision, when the
      adjustment value can't be accurately displayed in the entry.
      7ab9ee26
  3. 24 Oct, 2018 1 commit
  4. 19 Oct, 2018 1 commit
  5. 18 Sep, 2018 2 commits
    • Simon Budig's avatar
      f7ac0337
    • Ell's avatar
      app, libgimp*, modules: don't use g_type_class_add_private() ... · 3b0040c0
      Ell authored
      ... and G_TYPE_INSTANCE_GET_PRIVATE()
      
      g_type_class_add_private() and G_TYPE_INSTANCE_GET_PRIVATE() were
      deprecated in GLib 2.58.  Instead, use
      G_DEFINE_[ABSTRACT_]TYPE_WITH_PRIVATE(), and
      G_ADD_PRIVATE[_DYNAMIC](), and the implictly-defined
      foo_get_instance_private() functions, all of which are available in
      the GLib versions we depend on.
      
      This commit only covers types registered using one of the
      G_DEFINE_FOO() macros (i.e., most types), but not types with a
      custom registration function, of which we still have a few -- GLib
      currently only provides a (non-deprecated) public API for adding a
      private struct using the G_DEFINE_FOO() macros.
      
      Note that this commit was 99% auto-generated (because I'm not
      *that* crazy :), so if there are any style mismatches... we'll have
      to live with them for now.
      3b0040c0
  6. 11 Sep, 2018 1 commit
    • Jehan's avatar
      libgimpwidgets: do not assume a GimpFrame has a child. · 7448c7f8
      Jehan authored
      This fixes 2 CRITICALs when creating a GimpFrame without a child. There
      are reasons to create empty frames (for instance to conditionnally add
      contents later, and use it as a label only otherwise).
      7448c7f8
  7. 02 Sep, 2018 1 commit
    • Ell's avatar
      app, icons, menus: add performance-log recording to the dashboard · 36477bb2
      Ell authored
      Add an option to record a performance log through the dashboard.
      The log contains a series of samples of the dashboard variables, as
      well as the full program backtrace, when available.  As such, it
      essentially acts as a built-in profiler, which allows us to
      correlate program execution with the information available through
      the dashboard.  It is meant to be used for creating logs to
      accompany perofrmance-related bug reports, as well as for profiling
      GIMP during development.
      
      The sample frequency defaults to 10 samples per second, but can be
      overridden using the GIMP_PERFORMANCE_LOG_SAMPLE_FREQUENCY
      environment variable.  Backtraces are included by default when
      available, but can be suppressed using the
      GIMP_PERFORMANCE_LOG_NO_BACKTRACE environment variable.
      
      Logs are created through the new "record" button at the bottom of
      the dashboard dialog.  When pressed, a file dialog is opened to
      select the log file, and, once confirmed, data is being recorded to
      the selected file.  Recording is stopped by pressing the "record"
      button again (we use a highlight to indicate that recording is
      active.)
      
      While recording, the "reset" button is replaced with an "add marker"
      button, which can be used to add event markers to the log.  These
      can be used to mark events of interest, such as "started painting"
      and "stopped painting", which then appear in the log as part of the
      sample stream.  Markers are numbered sequentually, and the number
      of the next (to-be-added) marker appears on the button.  Shift-
      clicking the button adds an empty (description-less) marker, which
      is only identified by its number; this can be used when markers
      need to be added quickly.
      
      The log is an XML file, containing some extra information (such as
      the output of "$ gimp -v", and symbol information) in addition to
      the samples.  The data in the file is delta-encoded to reduce the
      file size, meaning that samples (as well as some other elements)
      only specify the changes since the previous sample.  This adds a
      necessary decoding step before data can be processed; the next
      commit adds a tool that does that.
      
      There are currently no tools to actually analyze the data -- that's
      still TBD -- but at least we can start gathering it.
      36477bb2
  8. 12 Aug, 2018 1 commit
    • Jehan's avatar
      configure: GLIB_COMPILE_RESOURCES is wrong when cross-compiling. · 8e453330
      Jehan authored
      AM_PATH_GLIB_2_0 m4 macro actually computes this value using
      $PKG_CONFIG. Yet $PKG_CONFIG variable is the pkg-config tool looking for
      target libraries (not host), hence it would return the executable
      `glib-compile-resources` built for the target.
      
      Also using the same variable name invalidates our test: our own
      AC_PATH_PROG was never run as the variable was already set. And no
      environment variable could override this test anymore either. This is
      why I rename the test variable to HOST_GLIB_COMPILE_RESOURCES.
      
      (cherry picked from commit d1d9eb17)
      8e453330
  9. 06 Aug, 2018 1 commit
    • Jehan's avatar
      libgimpwidgets, app: change "stock-size" property of... · d1372c6c
      Jehan authored
      ... GimpCellRendererToggle into "icon-size".
      
      In particular making it a pixel size instead of a GtkIconSize. This enum
      is limited to a few presets (registering new values is deprecated since
      GTK+ 3.10), with names completely semantically wrong. It is better to
      specify icon sizes (before scaling) in pixels directly, which goes also
      with named icons instead of stock ones.
      d1372c6c
  10. 30 Jul, 2018 1 commit
    • ONO Yoshio's avatar
      MR !19: Add support for vertical text writing. · 587d9bbb
      ONO Yoshio authored
      Squashed commit of the following:
      
      commit ee1ff7d502658cfa1248a13a3f0348495db07eda
      Author: ONO Yoshio <ohtsuka.yoshio@gmail.com>
      Date:   Sun Jul 29 00:31:47 2018 +0900
      
          Fixed that gimp-text-dir-ttb-* icons are lacked in Symbolic.
      
      commit d87d012d697628da28fe90199cc04b95b72ba8ef
      Author: ONO Yoshio <ohtsuka.yoshio@gmail.com>
      Date:   Sat Jul 28 16:23:10 2018 +0900
      
          Fix a typo.
      
      commit cf0238bf7df56c384cdf3b7ec69557d14740f853
      Author: ONO Yoshio <ohtsuka.yoshio@gmail.com>
      Date:   Sat Jul 28 15:50:57 2018 +0900
      
          Fixed seg fault error.
      
      commit b07f60d0
      Author: ONO Yoshio <ohtsuka.yoshio@gmail.com>
      Date:   Fri Jul 27 17:15:34 2018 +0900
      
          Add support for vertical text writing.
      
          #641
      587d9bbb
  11. 28 Jul, 2018 1 commit
  12. 27 Jul, 2018 1 commit
  13. 24 Jul, 2018 1 commit
    • Ell's avatar
      */Makefile.am: add *marshal.h files to BUILT_SOURCES · a5102a7d
      Ell authored
      In subdirs containing a generated foomarshal.h header, add the
      generated sources to BUILT_SOURCES, so that they're generated
      before the rest of the source files are built.  Otherwise, since
      there is no rule specifying the dependency between the rest of the
      source files and foomarshal.h, and since foomarshal.h is not
      checked into git (and hence doesn't exist when doing a clean
      build), compilation of the said source files may fail if they're
      built before foomarshal.h is generated.
      a5102a7d
  14. 20 Jul, 2018 1 commit
  15. 14 Jul, 2018 2 commits
  16. 13 Jul, 2018 1 commit
    • Michael Natterer's avatar
      libgimpwidgets: fix GimpIntComboBox popup-shown appearance · af44a516
      Michael Natterer authored
      The old hack doesn't work any longer, there is only one cell layout in
      GTK+ 3.x, not separate ones for the button and the popup. Switch back
      to recreating the cells in notify::popup-shown.
      
      Also simplify the code, we only need to remember one cell renderer in
      our struct, and remove manual resizing code that was only needed in
      older GTK+ 2.x vrsions.
      af44a516
  17. 11 Jul, 2018 1 commit
  18. 08 Jul, 2018 2 commits
  19. 01 Jul, 2018 1 commit
  20. 24 Jun, 2018 4 commits
    • Jehan's avatar
      libgimpwidgets: do not free the GtkAdjustment when finalizing... · 792b27af
      Jehan authored
      ... GimpMemsizeEntry.
      A GtkAdjustment is a GInitiallyUnowned, which means it is created as a
      floating reference. GtkSpinButton assumes its ownership by calling
      g_object_ref_sink() in gtk_spin_button_new() implementation. Thus it
      will take care of freeing it and when we try to unref it in finalize(),
      the object already doesn't exist.
      
      Alternatively we could keep another ref (by calling g_object_ref_sink()
      ourselves) but since the spin button is a child of the entry, it will
      live all the way until the entry is freed. There is no need to increment
      the references. So instead, simplify the code, and don't try to free an
      object we don't own anymore.
      
      This fixes CRITICAL assertions:
      > g_object_unref: assertion 'G_IS_OBJECT (object)' failed
      792b27af
    • Michael Natterer's avatar
      Remove most GTK_ADJUSTMENT() and (GtkAdjutment *) casts · 80997a86
      Michael Natterer authored
      they are obsolete in GTK+ 3.x because GtkAdjustment cannot be passed
      around as GtkObject any longer, GtkObject is gone.
      80997a86
    • Michael Natterer's avatar
      Clean up color selector styling · acd3a6f1
      Michael Natterer authored
      - remove redundant frames, 3d-frames are gone anyway, so no need to
        keep double out/in frames around
      - give all color selector classes CSS names
      - add/fix some theme CSS styles
      acd3a6f1
    • Michael Natterer's avatar
      app, libgimpwidgets: all GimpColorHexEntries should have the same tooltip · 2b8b780b
      Michael Natterer authored
      Set the tooltip in GimpColorHexEntry itself and remove all other
      tooltip setting. This just moves the translatable string sround in
      libgimpwidgets/, and even removes it from app/.
      2b8b780b
  21. 20 Jun, 2018 2 commits
  22. 13 Jun, 2018 2 commits
  23. 12 Jun, 2018 1 commit
  24. 08 Jun, 2018 2 commits
  25. 06 Jun, 2018 1 commit
    • Michael Natterer's avatar
      app, libgimp*: remove the config option to disable tooltips · b3620517
      Michael Natterer authored
      Also remove all traces of it from the plug-in protocol and raise the
      protocol version to 0x0100 (we now allow features and therefore
      version bumps in stable, and the master protocol version should always
      be higher). Fix the code that aborts plug-in startup on protocol
      version mismatch, we can't use gimp_message() because we have no
      protocol.
      b3620517
  26. 01 Jun, 2018 2 commits
  27. 31 May, 2018 1 commit
  28. 30 May, 2018 2 commits
    • Jehan's avatar
      libgimpwidgets: fix default icon. · 0ac3cd01
      Jehan authored
      gtk_window_set_default_icon_name() apparently isn't able to properly
      fallback to symbolic or non-symbolic variant. So let's test both.
      There is also gtk_window_set_icon_list() but it takes a list of pixbuf,
      so I really doubt it is the best solution either. The proposed solution
      is working ok for now, even though I feel it is again a bit hackish.
      0ac3cd01
    • Jehan's avatar
      libgimpwidgets: making GimpCellRenderer symbolic and DPI aware. · f3347d69
      Jehan authored
      This commit makes 2 improvements to this renderer. First it will allow
      it to find symbolic variants of icons. Second it properly renders icons
      when the display is scaled, by producing pixbuf size double to logical
      drawing size and making cairo rendering it at the expected logical size.
      f3347d69