From 7fed1b6e93f175c4830670140326495082a2f3fd Mon Sep 17 00:00:00 2001 From: Massimo Valentini Date: Fri, 9 Mar 2012 19:21:44 +0100 Subject: [PATCH] Bug 651956: Text tool misremembers point size upon reloading file When setting the unit of a property shared with a gimp_prop_size_entry, a conversion is applied to the corresponding size property (to preserve size_entry's ref-value), but the conversion risks to change the size property already updated. To update, at the same time, size and unit, it is better to start updating size_entry's unit in order to trigger the useless conversion on the stale size. --- app/tools/gimptexttool.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/app/tools/gimptexttool.c b/app/tools/gimptexttool.c index 026c0d45b8..ddc674173b 100644 --- a/app/tools/gimptexttool.c +++ b/app/tools/gimptexttool.c @@ -1029,6 +1029,10 @@ gimp_text_tool_connect (GimpTextTool *text_tool, if (text) { + if (text->unit != text_tool->proxy->unit) + gimp_size_entry_set_unit (GIMP_SIZE_ENTRY (options->size_entry), + text->unit); + gimp_config_sync (G_OBJECT (text), G_OBJECT (text_tool->proxy), 0); if (text->markup)