After an evaluation, GNOME has moved from Bugzilla to GitLab. Learn more about GitLab.
No new issues can be reported in GNOME Bugzilla anymore.
To report an issue in a GNOME project, go to GNOME GitLab.
Do not go to GNOME Gitlab for: Bluefish, Doxygen, GnuCash, GStreamer, java-gnome, LDTP, NetworkManager, Tomboy.
Bug 137767 - Undoing a modification to a text layer doesn't reset modified flag
Undoing a modification to a text layer doesn't reset modified flag
Status: RESOLVED FIXED
Product: GIMP
Classification: Other
Component: Tools
git master
Other All
: Normal minor
: 2.0
Assigned To: GIMP Bugs
GIMP Bugs
Depends on:
Blocks: 136740
 
 
Reported: 2004-03-20 14:22 UTC by Sven Neumann
Modified: 2004-12-22 21:47 UTC
See Also:
GNOME target: ---
GNOME version: ---



Description Sven Neumann 2004-03-20 14:22:51 UTC
When changing a text layer with other tools, for example painting on it,
the text layer is being marked as modified. This is indicated in the layers
dialog where the preview changes from a textlayer icon to a layer preview.
When undoing this step, the modified flag isn't unset and the layer doesn't
appear as a text layer.
Comment 1 Sven Neumann 2004-03-20 14:23:47 UTC
Setting target milestone to 2.0. But we shouldn't delay the 2.0
release because of this relatively minor issue.
Comment 2 Michael Natterer 2004-03-25 09:21:46 UTC
Bumping 2.0 bugs to 2.0.1
Comment 3 Michael Natterer 2004-04-01 14:52:45 UTC
2004-04-01  Michael Natterer  <mitch@gimp.org>

	* app/core/core-enums.[ch] (enum GimpUndoType): added undo type
	GIMP_UNDO_TEXT_LAYER_MODIFIED and undo group types
	GIMP_UNDO_GROUP_DRAWABLE and GIMP_UNDO_GROUP_DRAWABLE_MOD.

	* app/core/gimpimage-undo-push.[ch]: added new new function
	gimp_image_undo_push_text_layer_modified() which makes
	modifications of the text_layer's "modified" boolean undoable.

	* app/core/gimpdrawable.[ch]: added new virtual function
	GimpDrawable::push_undo() and moved the actual undo pushing into
	the default implementation gimp_drawable_real_push_undo().

	* app/text/gimptextlayer.c (gimp_text_layer_push_undo): new
	function. Pushes the text_layer's modified state to the undo stack
	after upchaining and sets modified to TRUE.

	(gimp_text_layer_set_tiles): ditto.

	(gimp_lext_layer_apply_region)
	(gimp_text_layer_replace_region): removed because their default
	implementations already call gimp_drawable_push_undo().

	(gimp_text_layer_swap_pixels): removed because swap_pixels() is
	used by undo only and doesn't need to care about the text_layer's
	modified state.

	(gimp_text_layer_render): don't set modified to FALSE here because
	we can't push an undo step here.

	(gimp_text_layer_set): push the modified state to the undo stack
	and set it to FALSE here. Also push the layer's tiles if the
	layer was modified.

	* app/tools/gimptexttool.c (gimp_text_tool_apply): push "modified"
	to the undo stack and set it to FALSE here, too.

	Fixes bug #137767.