2004-03-13 Michael Natterer <mitch@gimp.org>
Completed the fix for bug #136702:
* app/core/gimpitem.[ch]: added "gboolean supersample" and
"gint recursion_level" to GimpItem::transform().
* app/core/gimpitem-linked.[ch] (gimp_item_linked_transform): ditto.
* app/core/gimpdrawable-transform.[ch]: added "recursion_level"
parameters and removed the RECURSION_LEVEL #define.
* app/core/gimpchannel.c
* app/core/gimpdrawable.c
* app/core/gimplayer.c
* app/vectors/gimpvectors.c: changed accordingly.
* app/tools/gimptransformoptions.[ch]: added new property
"recursion_level" which is not serializable and has no GUI. Pretty
useless, but it's IMHO better to hardcode the default value here
than in gimpdrawable-transform.c
* app/tools/gimptransformtool.c: changed accordingly.
* tools/pdbgen/pdb/transform_tools.pdb: hardcode "recursion_level"
to 3.
* app/pdb/transform_tools_cmds.c: regenerated.
2003-09-11 Michael Natterer <mitch@gimp.org>
* app/core/gimpitem-linked.[ch]: made gimp_item_linked_get_list()
and the GimpItemLinkedMask enum public. Hiding them just causes
code duplication.
* app/tools/gimpdrawtool.[ch]: added a GList of GimpVectors and a
GimpMatrix3 transformation matrix for them. Just set them with
gimp_draw_tool_set_vectors() and gimp_draw_tool_set_transform()
and chain up in your tools's GimpdrawTool::draw() implementation
to get the vectors drawn.
* app/tools/gimpeditselectiontool.c: use
gimp_item_linked_get_list() instead of traversing image->layers,
->channels and ->vectors manually to find the linked items.
Use gimp_draw_tool_set_vectors() and _set_transform() to show
the linked vectors while moving.
(gimp_edit_selection_tool_arrow_key): transform all linked items,
not just the linked layers.
2003-05-20 Michael Natterer <mitch@gimp.org>
* app/core/gimpchannel.c (gimp_channel_rotate): don't default to
clip_result == TRUE (unlike the other transform functions).
* app/core/gimpdrawable-transform.c
(gimp_drawable_transform_tiles_rotate): fixed offset calculation.
* app/core/gimpimage-rotate.c: change the image size *after* all items
are rotated. Adjust all items' offsets after rotation. Rotate the
resolutions too. Seems to work now and fixes bug #6101.
* app/core/gimpimage.c (gimp_image_size_changed): emit
"size_changed" on all vectors.
* app/core/gimpitem-linked.[ch]: added gimp_item_linked_rotate().
* app/gui/drawable-commands.c: flip and rotate linked items too.
* app/vectors/gimpvectors.c (gimp_vectors_rotate): fixed rotation
angles.
Unrelated:
* app/core/gimpimage-merge.c: don't #include "path.h".
2003-05-13 Michael Natterer <mitch@gimp.org>
* app/core/gimpitem.[ch]: added "gboolean clip_result" to
GimpItem::flip().
* app/vectors/gimpvectors.c
* app/tools/gimpfliptool.c: changed accordingly.
* app/core/gimpdrawable.c: implement GimpItem::flip() and
GimpItem::transform().
* app/core/gimpchannel.c
* app/core/gimplayer.c: chain up in flip() and transform() and do
only the layer/channel specific stuff here.
* app/core/gimpdrawable-transform.[ch]: fixed indentation.
(gimp_drawable_transform_tiles_flip): added "gboolean clip_result"
and warn that it is not yet implemented.
(gimp_drawable_transform_tiles_affine): when transforming a
channel set bg_color to transparent. Clip channels (but not layer
masks) only if the passed tiles have bpp == 1 (the channel is
unfloated).
(gimp_drawable_transform_affine): clip all unfloated channels.
* app/core/gimpitem-linked.[ch]: added gimp_item_linked_get_list()
utility function to avoind iterating all layers/channels/vectors
in all functions.
* app/tools/gimptransformtool.c: clip all unfloated channels.
The clipping fixes above together fix bug #112858.
2003-05-12 Michael Natterer <mitch@gimp.org>
Added support for transforming linked layers, channels
and vectors. Fixes bug #86277.
* app/core/gimpdrawable-transform.[ch]
(gimp_drawable_transform_tiles_flip): added "gdouble axis" and
calculate the resulting drawable offset.
(gimp_drawable_transform_flip): calculate the axis and pass it to
the function above.
(gimp_drawable_transform_[tiles_]affine): reordered parameters.
* app/core/gimpitem.[ch]: added virtual functions GimpItem::flip()
and GimpItem::transform().
* app/core/gimpchannel.c
* app/core/gimplayer.c
* app/vectors/gimpvectors.c: implement flip() and transform().
Note that all functions always transform the whole item,
regardless of a present selection.
* app/core/Makefile.am
* app/core/gimpitem-linked.[ch]: new files containing utility
functions which translate, flip and transform all linked items.
* app/tools/gimpfliptool.c
* app/tools/gimptransformtool.c
* tools/pdbgen/pdb/layer.pdb: use the new gimp_item_linked_*()
functions to translate, flip and transform all linked items.
* tools/pdbgen/pdb/transform_tools.pdb: follow
gimp_drawable_transform_affine() API change.
* app/pdb/layer_cmds.c
* app/pdb/transform_tools_cmds.c: regenerated.