* Don't generate our own marshallers if they are available in GLib
already
* Don't set the c_marshaller parameter in `g_signal_new()` if it's a
default marshaller provided by GLib. See commit message of commit
39e4aa3c57 on why this is the case.
Basically this commit makes sure that all return values that are marked
as "Returns:" also have a `(nullable)` annotation if it is mentioned on
the same line that NULL can also be returned.
This will prevent a few problems in GObject-introspection.
which means that it's now included normally via gimpbase.h
and not any longer via gimpbasetypes.h which we only did out
of lazyness. A *lot* of files in libgimp* and app/ now need to
... 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.
even if we don't have private members (yet). Also make class padding 8
pointers in all headers. This commit moves nothing to private, it just
makes all headers consistent and adjusts .c files accordigly.
Since the entry behaves differently based on whether the user
provided an explicit input or not, it makes sense to have a button
for clearing the entry.
... when focus is lost/enter is pressed
When a GimpNumberPairEntry loses focus, or when enter is pressed,
set its user-override property by calling
gimp_number_pair_entry_set_user_override(), instead of setting the
corresponding member directly, so that the entry's font is updated
correctly.
because it confuses gtk-doc and breaks some links. Also change the
"Index of new symbols in GIMP 2.x" sections to be what seems to be the
modern standard (looked at the GLib and GTK+ docs), and update some
other stuff.
* libgimpwidgets/gimpnumberpairentry.c: When testing if the value
changed on focus-out we shall test against the current values, not
the default values.
svn path=/trunk/; revision=27914
2009-01-17 Michael Natterer <mitch@gimp.org>
* all files with a GPL header and all COPYING files:
Change licence to GPLv3 (and to LGPLv3 for libgimp).
Cleaned up some copyright headers and regenerated the parsers in
the ImageMap plugin.
svn path=/trunk/; revision=27913
2007-10-09 Martin Nordholts <martinn@svn.gnome.org>
* app/tools/gimprectangleoptions.[ch]: Connect a new function
gimp_rectangle_options_string_current_updates() that updates the
Fixed: Aspect entry with a 'Current' string when aspect of the
current pending rectangle is used, and sets sensitivity FALSE on
aspect ratio changing buttons when that string is shown. Prevents
the confusion mentioned in bug #479999.
A new Rectangle Options property 'use-string-current' has been
added that should be refactored away from the options object along
with references to option widgets.
* app/tools/gimprectangleselecttool.c
(gimp_rect_select_tool_update_option_defaults): Set default Fixed:
Aspect ratio to that of the pending rectangle, and always have
default Fixed: Size as 100x100.
* app/tools/gimpcroptool.c
(gimp_crop_tool_update_option_defaults): Always have default
Fixed: Size 100x100.
* libgimpwidgets/gimpnumberpairentry.[ch]
(gimp_number_pair_entry_class_init): Add a new property
'default-text' that contains text to be shown instead of numbers
when default numbers are to be shown.
(gimp_number_pair_entry_get_default_text)
(gimp_number_pair_entry_set_default_text): Getter and setter for
it.
* libgimpwidgets/gimpwidgets.def: Updated.
svn path=/trunk/; revision=23788
2007-08-13 Sven Neumann <sven@gimp.org>
* libgimpwidgets/gimpnumberpairentry.c: use italic font if not in
user-override mode.
* app/tools/gimprectangleoptions.c: removed auto-mode icon.
* themes/Default/images/Makefile.am
* themes/Default/images/stock-auto-mode-16.png
* libgimpwidgets/gimpnumberpairentry.[ch]: removed
GIMP_STOCK_AUTO_MODE.
svn path=/trunk/; revision=23231
2007-08-10 Sven Neumann <sven@gimp.org>
* libgimpwidgets/gimpnumberpairentry.c: store separators as
gunichar array. Use the default separator in case that no
separator is set. Rewritten gimp_number_pair_entry_parse_text()
to handle non-ASCII separators.
svn path=/trunk/; revision=23195
2007-08-10 Martin Nordholts <martinn@svn.gnome.org>
* libgimpwidgets/gimpnumberpairentry.c
(gimp_number_pair_entry_parse_text): Remove code that has not with
parsing to do, so that clients that use this function can be more
flexible about what to do with parsing results.
(gimp_number_pair_entry_events): Handle results of parsing here
instead.
svn path=/trunk/; revision=23186
2007-08-10 Martin Nordholts <martinn@svn.gnome.org>
* libgimpwidgets/gimpnumberpairentry.[ch]: Some minor cleanup, and
(gimp_number_pair_entry_set_user_override)
(gimp_number_pair_entry_get_user_override): are now in the API.
* libgimpwidgets/gimpwidgets.def: Updated.
svn path=/trunk/; revision=23177
2007-08-09 Martin Nordholts <martinn@svn.gnome.org>
* libgimpwidgets/gimpnumberpairentry.[ch}: Added properties for
most of the instance members, and updated API.
(gimp_number_pair_entry_get_aspect)
(gimp_number_pair_entry_get_default_values)
(gimp_number_pair_entry_get_ratio)
(gimp_number_pair_entry_set_aspect)
(gimp_number_pair_entry_set_ratio): Added API functions.
* libgimpwidgets/gimpwidgets.def: Updated.
svn path=/trunk/; revision=23173
2007-08-08 Martin Nordholts <martinn@svn.gnome.org>
Renamed GimpRatioEntry to GimpNumberPairEntry, and generalized the
code a lot, so that it can be used both for 'Fixed: Aspect ratio'
and 'Fixed: Size'. Support is also added for having default values
and a 'user overrided' value mode.
* libgimpwidgets/gimpnumberpairentry.[ch]: Now contains the
rewrite and generalization of GimpRatioEntry.
(gimp_number_pair_entry_get_type)
(gimp_number_pair_entry_new)
(gimp_number_pair_entry_set_default_values)
(gimp_number_pair_entry_set_values)
(gimp_number_pair_entry_get_values): New libgimpwidget API.
* app/widgets/gimppropwidgets.[ch] (gimp_prop_size_2d_new): Added
new helper widget for setting up a GimpNumberPairEntry for the
Fixed: Size entry in the Rectangle Options.
* app/tools/gimprectangleoptions.c (gimp_rectangle_options_gui):
Use the new gimp_prop_size_2d_entry for the Fixed: Size entry.
* libgimpwidgets/gimpwidgets.def: Removed gimp_ratio_entry_* and
added gimp_number_pair_entry_*.
* libgimpwidgets/gimpwidgets.h * libgimpwidgets/gimpwidgetstypes.h
* libgimpwidgets/Makefile.am (libgimpwidgets_2_0_la_sources)
(libgimpwidgetsinclude_HEADERS): Updated accordingly.
svn path=/trunk/; revision=23154