Add new string members to GimpImageMapTool and use them instead of the
resp. fields of GimpToolInfo. Change ::get_operation() to return the
operation name and a lot of strings for the UI, and create both the
GeglNode and the config object in GimpOperationTool. Lots of various
cleanups in GimpImageMapTool subclasses. This is an intermediate state
on the way of making the whole filter applying mechanism more generic
and less depending on subclasses.
Add "title" and "help_id" parameters and members/properties to
GimpToolDialog, GimpToolGui, GimpOperationTool. Also make the order of
parameters more consistent.
Foreground and background are GIMP concepts; the annotations on GEGL ops
should be about how the operation makes use of the meta-data; not where
it comes from in one particular application using GEGL.
old names:
"role", "foreground-color",
"role", "background-color",
new names:
"role", "color-primary",
"role", "color-secondary",
On tool change, we used to simply halt tools before switching to the
new one, which meant losing ongoing live-previewed tool changes, like
transforms, warps and color corrections. This change makes them being
applied to the image instead before switching to the new tool:
Add enum value GIMP_TOOL_ACTION_COMMIT that is passed to
GimpTool::control() before tool switching. Handle the new enum value
in all tools, and actually commit the previewed stuff. This changes
the behavior of GimpCageTool, GimpImageMapTool, GimpTransformTool and
GimpWarpTool.
gimp_operation_tool_aux_selected() is called with a NULL drawable
when the combo is destroyed, but at that time the GeglNode we set
the buffer on is already gone. Instead of adding evil if()s,
connect_object() the combo's "select-item" signal to the node
instead of the tool, so it gets disconnected automatically.
If the operation has an aux input, add a combo that allows feeding
it one of the image's channels. This is all work in progress and
and should allow to use any drawable of any image.
so gimp_image_map_tool_color_picked() isn't called any longer on clicks.
Add a warning there in case it happens anyway because this is always a
programming error.
gimp_operation_tool_color_picked(): if the picker's identifier is of
the form "param_spec_name:param_spec_name" and the param specs both
exist and are of the same numeric type, set the pick coordinates on
these properties of the operation's config object.
gimp_operation_tool_set_operation(): set it to NULL when destroying
the previous operation's options_table (if it was non-NULL it was a
widget from that table).
It was misnamed from the beginning and has no relation to GimpImageMap
except that it happens to be used by GimpImageMapTools. Now it feels
less weird to potentially use it for other settings too.
- connect to the config object's notify generically and update the preview
- allow to properly exchange the operation at runtime to remove major
uglyness from GimpOperationTool
- return undo_desc from GimpImageMapTool::get_operation() so we have
proper strings in the undo history, not always "GEGL operation"
- simplify all get_operation() implementations