2004-10-25 Michael Natterer <mitch@gimp.org>
Don't store human readable and translatable enum/flag strings in
GEnumValue's and GTypeValue's fields but attach them to their
GType using separate structs and utility functions:
* tools/gimp-mkenums: added params and perl voodoo to support
generating a second array of values, which is used by the
Makefiles below to create and register arrays of value
descriptions.
* libgimpbase/gimpbasetypes.[ch]: added API to attach/retreive
arrays of translatable strings to/from enum and flags types. Added
structs GimpEnumDesc and GimpFlagsDesc for that purpose.
* libgimpbase/gimputils.[ch]: changed existing enum utility
functions, added new ones and added a symmetric API for flags.
* app/base/Makefile.am
* app/core/Makefile.am
* app/display/Makefile.am
* app/paint/Makefile.am
* app/text/Makefile.am
* app/tools/Makefile.am
* app/widgets/Makefile.am
* libgimp/Makefile.am
* libgimpbase/Makefile.am: changed *-enums.c generation rules
accordingly.
* app/base/base-enums.c
* app/core/core-enums.c
* app/display/display-enums.c
* app/paint/paint-enums.c
* app/text/text-enums.c
* app/tools/tools-enums.c
* app/widgets/widgets-enums.c
* libgimpbase/gimpbaseenums.c: regenerated.
* app/widgets/gimpenumstore.c
* app/widgets/gimpenumwidgets.c
* app/widgets/gimptemplateeditor.c
* libgimpwidgets/gimppreviewarea.c: follow the enum utility
function API changes.
2004-09-22 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayout.c (gimp_text_get_pango_context):
workaround Pango bug #143542 (PangoFT2Fontmap leak, see also bug
#148997). Based on a patch by Robert Ögren.
2004-07-28 Michael Natterer <mitch@gimp.org>
* app/core/core-enums.h: added still unused flags type
GimpDirtyMask.
* app/base/Makefile.am
* app/core/Makefile.am
* app/display/Makefile.am
* app/paint/Makefile.am
* app/text/Makefile.am
* app/tools/Makefile.am
* app/widgets/Makefile.am
* libgimpthumb/Makefile.am: changed calls to gimp-mkenums to
support GTypeFlags and to make the value arrays private to the
get_type() functions.
* app/base/base-enums.c
* app/core/core-enums.c
* app/display/display-enums.c
* app/paint/paint-enums.c
* app/text/text-enums.c
* app/tools/tools-enums.c
* app/widgets/widgets-enums.c: regenerated.
2004-07-13 Sven Neumann <sven@gimp.org>
* app/core/gimp-utils.[ch]: added new function
gimp_g_value_get_memsize() that attempts to calculate the memory
requirements for a GValue.
* app/text/gimptextundo.c (gimp_text_undo_get_memsize): use the
new function to obtain a better estimate for the size of the text
undo.
2004-07-12 Michael Natterer <mitch@gimp.org>
* app/text/gimptextundo.[ch]: removed member "guint time"...
* app/core/gimpundo.[ch]: ...and added it here.
* app/tools/gimptexttool.c (gimp_text_tool_apply): changed
accordingly. Reordered undo compression code to look like other
pieces of code which do undo compression.
2004-07-12 Michael Natterer <mitch@gimp.org>
* app/core/gimpundo.[ch]
* app/core/gimpitemundo.[ch]
* app/text/gimptextundo.[ch]: removed all _new() functions and
added properties and GObject::constructor() implementations
instead.
* app/core/gimpimage-undo.[ch] (gimp_image_undo_push): added
"GType undo_gtype" parameter and allow to pass name-value pairs as
"...". Une the new GParameter utility functions to construct the
appropriate undo step with g_object_newv().
(gimp_image_undo_push_item): removed.
(gimp_image_undo_push_undo): removed. Merged its code back into
gimp_image_undo_push(), where it originally came from.
* app/core/gimpimage-undo-push.c
* app/core/gimpundostack.c
* app/paint/gimppaintcore-undo.c
* app/tools/gimptransformtool-undo.c
* app/widgets/gimpundoeditor.c: changed accordingly.
2004-06-05 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer-transform.[ch]: updated the (still unused)
unused text transformation code.
* app/text/gimptext-bitmap.c: removed a redundant transformation.
2004-05-28 Michael Natterer <mitch@gimp.org>
* app/text/gimpfont.c (gimp_font_get_popup_size)
(gimp_font_get_new_preview): take both logical and ink rectangle
into account to avoid clipping away parts of the font preview.
Fixes bug #142277.
2004-04-15 Manish Singh <yosh@gimp.org>
* tools/Makefile.am
* app/Makefile.am
* configure.in: app, tools, and user dir bumped to version 2.1 names.
* app/text/gimpfontlist.c: since we now depend on pango 1.4, we can
use pango_fc_font_description_from_pattern() instead of our
cut-n-paste function, gimp_font_list_font_desc_from_pattern().
2004-04-15 Michael Natterer <mitch@gimp.org>
* app/core/gimpitem.[ch]: added "const gchar *stroke_desc" to
the GimpItemClass struct and always push an undo group
around GimpItem::stroke().
* app/core/gimpchannel.c
* app/core/gimpselection.c
* app/vectors/gimpvectors.c: set the stroke_desc accordingly
and don't push undo groups.
* app/text/gimptextlayer.c (gimp_text_layer_class_init): set
all of GimpItemClass' undo_descs.
* app/text/gimptextlayer-transform.c: don't push undo groups here.
2004-04-13 Sven Neumann <sven@gimp.org>
* app/core/gimp-utils.[ch] (gimp_get_default_language): added a
category parameter to make this function more flexible.
* app/text/gimptext.c: changed accordingly.
* app/widgets/gimphelp.c (gimp_help): localize the help pages
according to the value of LC_MESSAGES. Fixes bug #139917.
2004-04-11 Hans Breuer <hans@breuer.org>
* app/makefile.msc : build sanity.obj
app/text/makefile.msc : gimptextundo.obj
app/widgets/makefile.msc : gimppatternfactoryview.obj
* plug-ins/common/winclipboard.c : don't call
gimp_image_undo_enable() when it's not switched off.
Otherwise the undo history would be destroyed with
Gimp-Core-CRITICAL **: file gimpimage.c: line 1579: assertion
`gimage->undo_freeze_count > 0' failed
2004-04-03 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.c (gimp_text_layer_new): create the
initial text layer with a size of 1 x 1 since tile_manager_new()
does not any longer accept 0 x 0.
* app/core/gimpdrawable.c (gimp_drawable_configure): check that
width and height are > 0.
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.
2004-03-28 Sven Neumann <sven@gimp.org>
* app/text/gimpfontlist.c (gimp_font_list_add_font): validate the
font name. This should work around the crashes that Windows users
were experiencing on startup (bug #132366). The real problem needs
to be fixed elsewhere though.
2004-03-22 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.c (gimp_text_layer_duplicate): put some
code back in that I removed accidentally.
(gimp_text_layer_render) freeze/thaw notifications to avoid that
two "notify::modified" signals are emitted.
2004-03-21 Sven Neumann <sven@gimp.org>
* app/core/gimpundo.[ch]: added gimp_undo_type_to_name() a similar
function used to live in gimpimage-undo.[ch].
* app/core/gimpitemundo.c (gimp_item_undo_new): allow NULL as name
and generate it from the undo_type then.
* app/core/gimpimage-undo.[ch]: added gimp_image_undo_push_undu(),
new function that allows to push an undo on the image.
* app/text/Makefile.am
* app/text/text-types.h
* app/text/gimptextundo.[ch]: added GimpTextUndo, derived from
GimpItemUndo.
* app/core/gimpimage-undo-push.c (gimp_image_undo_push_text_layer):
use the new code and simply push a text undo here.
* app/tools/gimptexttool.c: compress text undos by peeking at the
undo stack. Fixes bug #137766.
2004-03-20 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.c: it wasn't such a good idea to let
GimpConfig take care of the text when duplicating a text layer; it
didn't create a copy. Do that manually again; fixes bug #137786.
2004-03-20 Sven Neumann <sven@gimp.org>
* app/widgets/gimppropwidgets.c (gimp_prop_size_entry_callback):
avoid to set the unit property with every size change; only set it
if it actually changed.
* app/core/gimpimage-undo-push.c (gimp_image_undo_push_text_layer):
allow to pass a GParamSpec that identifies a single text property
to be changed. In this case, don't store a GimpText object on the
undo stack but only the changed value.
* app/tools/gimptexttool.c: use the new undo feature to reduce the
memory footprint of text undo for the common case.
* app/text/gimptextlayer.c: changed accordingly.
2004-03-20 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.c (gimp_text_layer_set): use the same
undo group logic as in the text tool. Not really necessary since
this function must not be called on modified text layers, but it's
more consistent this way.
2004-03-20 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.c (gimp_text_layer_render): don't fiddle
with the item size, gimp_drawable_set_tiles() does the right thing.
2004-03-20 Sven Neumann <sven@gimp.org>
* app/core/gimpimage-undo-push.c (undo_pop_text_layer): don't
exchange the text_layer's text object but sync it with the text
object from the undo step.
* app/text/gimptextlayer.c (gimp_text_layer_set): in case the
layer has a mask, push an undo group around the text modifications.
* app/tools/gimptexttool.c (gimp_text_tool_idle_apply): push a
text layer undo before applying the text changes.
2004-03-19 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.[ch]: added gimp_text_layer_set(), a
function that calls g_object_set() on the text-layer's text object
and pushes an undo step.
* app/display/gimpdisplayshell-dnd.c (gimp_display_shell_bucket_fill):
use the new function.
2004-03-19 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.c (gimp_text_layer_render): if there's a
layer mask, resize it with the layer.
* app/tools/gimptexttool.c: don't change text_tool->layer before
calling gimp_text_tool_connect().
2004-03-18 Sven Neumann <sven@gimp.org>
* app/gui/layers-commands.c (layers_text_tool)
* app/gui/layers-menu.c (layers_menu_update): treat modified text
layers like normal layers.
* app/gui/layers-commands.c (layers_edit_layer_query): added a
check button that gives access to the "auto-rename" property of a
text layer.
* app/text/gimptextlayer.c: typo.
* app/widgets/gimppreviewrendererlayer.c
(gimp_preview_renderer_layer_render): show the text layer icon for
unmodified text layers only.
2004-03-18 Sven Neumann <sven@gimp.org>
* app/display/gimpdisplayshell-dnd.c (gimp_display_shell_bucket_fill):
added a missing call to gimp_image_flush().
* app/tools/gimptexttool.c: propagate text changes to the tool
options.
* app/text/gimptextlayer.c: made "text", "auto-rename" and
"modified" properties of the text layer and copy them when
duplicating a text layer.
* app/text/gimptextlayer-xcf.[ch]: added utility functions to
convert the new properties to flags to be saved in the XCF file.
* app/xcf/xcf-load.c
* app/xcf/xcf-private.h
* app/xcf/xcf-save.c: load and save text layer properties.
Disabled warnings about unknown properties for stable branches.
2004-03-17 Sven Neumann <sven@gimp.org>
Changes for help i18n in the core, the rest will take place in the
help plug-in:
* app/text/gimptext.[ch]: removed gimp_text_get_default_language()
* app/core/gimp-utils.[ch]: ... and added it here as
gimp_get_default_language().
* app/config/gimprc-blurbs.h
* app/config/gimpdisplayconfig.[ch]: added property "help-locales".
* app/widgets/gimphelp.c: use the new property and pass it to the
help plug-in.
* app/core/gimpselection.c (gimp_selection_invalidate_boundary):
removed unused variable.
2004-03-15 Michael Natterer <mitch@gimp.org>
* app/core/gimpdrawable.c (gimp_drawable_set_tiles_full): emit
"update" signals from the drawable before and after setting tiles
and offsets.
* app/core/gimpdrawable-offset.c (gimp_drawable_offset)
* app/core/gimpdrawable-transform.c (gimp_drawable_transform_paste)
* app/core/gimpimage-undo-push.c (undo_pop_layer_mod, _channel_mod)
* app/text/gimptextlayer.c (gimp_text_layer_render)
* app/tools/gimptransformtool.c (gimp_transform_tool_doit):
removed calls to gimp_drawable_update().
* app/core/gimpdrawable-offset.c (gimp_drawable_offset): don't
push an undo step before calling gimp_drawable_set_tiles()
but simply pass push_undo == TRUE and the undo_desc.
2004-03-15 Michael Natterer <mitch@gimp.org>
* app/core/gimpdrawable.[ch]: added "offset_x" and "offset_y"
parameters to GimpDrawable::set_tiles().
(gimp_drawable_set_tiles): removed the "GimpImageType" parameter.
(gimp_drawable_set_tiles_full): new function adding type, offset_x
and offset_y parameters.
(gimp_drawable_real_set_tiles): set the drawable's offsets from
the offset parameters and its size from the passed TileManager's
size. Emit "size_changed" accordingly.
* app/core/gimpchannel.c
* app/core/gimpdrawable-offset.c
* app/core/gimpdrawable-transform.c
* app/core/gimpimage-convert.c
* app/core/gimpimage-undo-push.c
* app/core/gimplayer.c
* app/text/gimptextlayer.c
* app/tools/gimptransformtool.c: changed accordingly: removed
calls to gimp_viewable_size_changed() and all sorts of hackish
assignments of the drawable's width/height/offset_x/offset_y
properties.
2004-03-15 Michael Natterer <mitch@gimp.org>
* app/text/gimptextlayer.c (gimp_text_layer_render): don't call
gimp_image_flush().
* app/tools/gimpxttool.c (gimp_text_tool_apply): call it here
instead.
Now that we have a common place that exchanges drawable->tiles,
we can abstract away boundary invalidation for this operation:
* app/core/gimpdrawable.c (gimp_drawable_real_set_tiles):
call gimp_drawable_invalidate_boundary() before setting
the new tiles.
* app/core/gimpchannel.c (gimp_channel_set_tiles)
* app/core/gimpdrawable-transform.c (gimp_drawable_transform_paste)
* app/core/gimpimage-undo-push.c (undo_pop_layer_mod)
* app/core/gimplayer.c (gimp_layer_scale) (gimp_layer_resize)
(gimp_layer_flip) (gimp_layer_rotate) (gimp_layer_transform)
* app/text/gimptextlayer.c (gimp_text_layer_render): removed
calls to gimp_drawable_invalidate_boundary() from all functions
which finally call gimp_drawable_real_set_tiles().
* app/tools/gimptransformtool.c (gimp_transform_tool_doit): no
need to set channel->bounds_known to FALSE, because
gimp_drawable_set_tiles() already did this.
2004-03-15 Michael Natterer <mitch@gimp.org>
Closer to text layer undo:
* app/core/gimpchannel.c (gimp_channel_set_tiles): invalidate the
channel's boundary and bounds.
* app/text/gimptextlayer.c: implement GimpDrawable::swap_pixels()
and set text_layer->modified = TRUE after upchaining.
(gimp_text_layer_render): use gimp_drawable_set_tiles() and
set text_layer->modified = FALSE afterwards.
* app/core/gimpimage-undo-push.c: cleaned up variable declarations
and initializations.
(undo_pop_layer_mod)
(undo_pop_channel_mod): use gimp_channel_set_tiles() instead of
touching drawable->tiles manually. Now all pixel manipulation
(at least on layers) should be virtualized and can be detected by
the text layer.
2004-03-14 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.[ch]: removed all idle handling here.
Changes to the text-layer's text object all applied synchronously.
* app/display/gimpdisplayshell-dnd.c
* app/text/gimptextlayer-transform.c: removed now obsolete calls
to gimp_text_layer_flush().
* app/tools/gimptexttool.[ch]: queue up changes to the proxy text
object and apply them in one go from a low-priority idle handler.
This is basically what GimpTextLayer used to do.
2004-03-13 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayer.[ch]: implement GimpDrawable functions
that affect the tiles and mark the text layer as modified. Added
new function gimp_drawable_is_text_layer() that checks whether a
drawable is an unmodified text layer.
* app/display/gimpdisplayshell-dnd.c (gimp_display_shell_bucket_fill):
use gimp_drawable_is_text_layer() and only set the text color if the
text layer is unmodified. Fixes bug #136623.
2004-03-11 Sven Neumann <sven@gimp.org>
* app/config/gimpconfig-utils.c: made gimp_config_sync() and
gimp_config_connect() also work on objects of different types.
Properties with the same name and the same type are synced /
connected.
* app/core/gimpcontext.[ch]: added convenience functions to get/set
the font by name.
* app/tools/gimptextoptions.[ch]: don't hold a GimpText object
that duplicates properties like font and color which are in
GimpContext already. Instead added all text properties that are
controlled from the text tool options. Handling of the foreground
color is somewhat broken and needs a GimpContext wizard (Mitch!).
* app/text/gimptext.c: blurbs are not any longer needed now that
the property widgets are created from the GimpTextOptions.
* app/tools/gimptexttool.c: changed accordingly.
* app/widgets/gimptexteditor.[ch]: use an internal GtkTextBuffer
and emit "text-changed" when it changes.
2004-02-23 Michael Natterer <mitch@gimp.org>
* app/core/core-types.h: added #defines for GimpCoords' default
pressure, tilt and wheel values.
* app/display/gimpdisplayshell-callbacks.c
* app/paint/gimppaintcore-stroke.c
* app/text/gimptext-vectors.c
* tools/pdbgen/pdb/paint_tools.pdb: use them. Fixes lots more
buggy default values for tilt (in fact all of them were wrong).
* app/pdb/paint_tools_cmds.c: regenerated.
2004-02-09 Manish Singh <yosh@gimp.org>
* app/file/Makefile.am
* app/paint/Makefile.am
* app/text/Makefile.am
* app/xcf/Makefile.am: changed GTK_CFLAGS to GDK_PIXBUF_CFLAGS, since
we don't use any gtk/gdk functions here. This especially helps in the
text directory, since it avoids problems on broken setups with old
fontconfig stuff in the X11 directory lying around.
2004-02-07 Hans Breuer <hans@breuer.org>
* gimpdefs.msc : new file to keep common definitions for the msc build
* **/makefile.msc : use common defintions, e.g. GIMP_VER
* Makefile.am : add the former to EXTRA_DIST
2004-02-01 Michael Natterer <mitch@gimp.org>
Disallow to rename the layer mask. Instead, always name the mask
"<layer name> mask". Fixes bug #133112 along with some other
unreported ones.
* app/core/gimpitem.[ch]: added a boolean return value indicating
success to GimpItem::rename().
(gimp_item_real_rename): push an undo step only if the item is
attached.
* app/core/gimplayer.c (gimp_layer_rename): refuse renaming if
the layer is a floating selection floated from a channel
(renaming a layer's floating selection makes a new layer out
of the floating selection).
(gimp_layer_duplicate): use gimp_layer_add_mask() to attach the
mask's duplicate. Fixes mask refcount brokenness for duplicated
layer masks.
(gimp_layer_name_changed): new function. Automatically renames the
layer mask when the layer's name changes.
* app/core/gimplayermask.c (gimp_layer_mask_rename): new function
which refuses renaming.
(gimp_layer_mask_name_changed): skip the unique name voodoo
GimpItem does by not chaining up.
(gimp_layer_mask_set_layer): change the mask's name whenever it is
attached to a layer.
* app/text/gimptextlayer.c (gimp_text_layer_rename): fiddle with
text_layer->auto_rename only if renaming was successful.
* app/widgets/gimpitemtreeview.c (gimp_item_tree_view_name_edited):
restore the old name if renaming failed.
* tools/pdbgen/pdb/drawable.pdb (set_name): return an execution
error if renaming failed.
* app/pdb/drawable_cmds.c: regenerated.
2004-01-26 Sven Neumann <sven@gimp.org>
* app/text/gimptext-xlfd.c (gimp_text_font_size_from_xlfd):
account for the fact that XLFD stores point sizes in decipoints.
* app/text/gimptext-vectors.c: s/TEXT_DEBUG/GIMP_TEXT_DEBUG/
2004-01-26 Michael Natterer <mitch@gimp.org>
* plug-ins/script-fu/scripts/unsharp-mask.scm: add the layer to
the image before pasting to it. Fixes bug #132504.
Fixed the underlying problem: make it impossible to attach
floating selections to drawables which are not currently part of
the image's layer or channel stacks.
Also cleaned up image <-> floating_sel interaction:
* app/core/gimplayer-floating-sel.[ch] (floating_sel_attach):
added assertion that the drawable is part of the image (see below).
Don't call gimp_image_floating_selection_changed(), it's emitted
by gimp_image_add_layer() now.
(floating_sel_remove)
(floating_sel_anchor): don't emit "floating_selection_changed",
it's emitted by gimp_image_remove_layer() now.
(floating_sel_anchor): removed the fix for bug #132162 because
gimp_image_remove_layer() behaves correctly now (see below).
Renamed floating_sel_reset() to floating_sel_activate_drawable().
Added g_return_if_fail() all over the place.
* app/core/gimpimage.[ch]: added new function gimp_image_owns_item()
which return TRUE if the passed item is part of the image.
(gimp_image_add_layer): emit "floating_selection_changed" here if
needed.
(gimp_image_remove_layer): emit "floating_selection_changed" if
needed, don't try to activate a layer if we called
floating_sel_activate_drawable().
This is the real fix for bug #132162.
* app/core/gimpimage-undo-push.c (undo_pop_layer): apply the same
fixes as to gimp_image_add,remove_layer(). Don't call
gimp_drawable_invalidate_preview() on the previously active layer
because that's done by gimp_image_set_active_layer() now.
* app/xcf/xcf-load.c: remember the "floating_sel_drawable" in the
XcfInfo struct and attach it *after* all layers and channels are
loaded to avoid attaching the floating selection to an
out-of-image drawable.
* app/core/gimp-edit.c (gimp_edit_paste)
* app/core/gimpdrawable-transform.c (gimp_drawable_transform_affine,
gimp_drawable_transform_flip, gimp_drawable_transform_rotate)
* app/core/gimpselection.c (gimp_selection_float)
* app/text/gimptext-compat.c (text_render): added checks for
gimp_image_owns_item() in all functions which can produce
floating selections.
* tools/pdbgen/pdb/edit.pdb
* tools/pdbgen/pdb/floating_sel.pdb
* tools/pdbgen/pdb/selection.pdb
* tools/pdbgen/pdb/text_tool.pdb
* tools/pdbgen/pdb/transform_tools.pdb: added checks for
gimp_item_owns_image() and return an execution error if invoked
with a drawable which is not part of the image.
* app/pdb/edit_cmds.c
* app/pdb/floating_sel_cmds.c
* app/pdb/selection_cmds.c
* app/pdb/text_tool_cmds.c
* app/pdb/transform_tools_cmds.c: regenerated.
2004-01-25 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayout.c (gimp_text_layout_position): fixed
text positioning for fonts where glyphs extend the logical
rectangle (bug #132495).
2004-01-15 Manish Singh <yosh@gimp.org>
* app/text/gimpfontlist.c: Minor cleanup, add note about using
pango_fc_font_description_from_pattern from pango 1.4 when we
can.
2004-01-15 Manish Singh <yosh@gimp.org>
* app/text/gimpfontlist.c: Set PangoStretch from FC_WIDTH. This
partially addresses #131561 (namely, the gimp side).
2004-01-06 Michael Natterer <mitch@gimp.org>
Enabled skipping enum values for either the PDB or GType
registration (don't always skip both targets):
* tools/gimp-mkenums: skip enum values only if there is a literal
"skip" (don't match "pdb-skip").
* tools/pdbgen/enumgen.pl: skip only "pdb-skip" values, not "skip"
ones.
* app/base/base-enums.h
* app/core/core-enums.h
* app/paint/paint-enums.h
* libgimpbase/gimpbaseenums.h: use the right "pdb-skip"/"skip"
combination to skip enum values. Changed comments accordingly.
Cleaned up the fill functions:
* app/core/core-enums.[ch]: added GIMP_PATTERN_FILL enum value to
the GimpFillType enum. Don't export GIMP_NO_FILL to the PDB
because it's completely useless to export a NOP.
* app/core/gimp-edit.c (gimp_edit_fill, gimp_edit_fill_internal):
handle pattern fill requests.
* app/core/gimpdrawable.[ch] (gimp_drawable_fill): added GimpPattern
parameter and fill with it if it's non-NULL.
(gimp_drawable_fill_by_type): handle pattern fill and pass the
current pattern to gimp_drawable_fill().
* app/text/gimptextlayer.c: changed accordingly.
* app/gui/edit-commands.c
* app/gui/image-menu.c: use gimp_edit_fill() instead of
gimp_drawable_bucket_fill() for FG, BG and pattern filling.
* libgimp/gimpcompat.h
* plug-ins/script-fu/siod-wrapper.c: removed NO_IMAGE_FILL compat
enum value. It should have never been exported to the PDB.
* app/pdb/drawable_cmds.c
* app/pdb/edit_cmds.c
* libgimp/gimpenums.h
* plug-ins/pygimp/gimpenums.py
* plug-ins/script-fu/script-fu-constants.c
* tools/pdbgen/enums.pl: regenerated.
2004-01-05 Sven Neumann <sven@gimp.org>
* app/core/core-enums.[ch]: added GIMP_UNDO_TEXT_LAYER to
GimpUndoType enum.
* app/core/gimpimage-undo-push.[ch]: added new undo function
gimp_image_undo_push_text_layer().
* app/text/gimptextlayer.[ch]: renamed gimp_text_layer_render() to
gimp_layer_text_layer_flush().
Added new function gimp_text_layer_discard().
* app/text/gimptextlayer-transform.c: changed accordingly.
* app/gui/image-menu.c
* app/gui/layers-commands.[ch]
* app/gui/layers-menu.c: added menu entries that allow to discard
the text information of a text layer (bug #118547).
* app/widgets/gimppreviewrendererlayer.c
(gimp_preview_renderer_layer_render): treat text layers without a
text object like ordinary layers.
* app/widgets/gimppreviewrenderer-utils.c: include gimplayer.h
instead of gimptextlayer.h.
2003-12-16 Michael Natterer <mitch@gimp.org>
* app/text/gimptextlayout-render.c (gimp_text_layout_render):
multiply the layout's offsets with PANGO_SCALE, not -PANGO_SCALE.
Fixes bug #129405.
2003-12-12 Hans Breuer <hans@breuer.org>
[
I've postponed my reservations against pangoft2/fontconfig/freetype2
usage, so The Gimp should now build with msvc without patching it.
]
* app/makefile.msc app/text/makefile.msc : use $(PANGOFT2_CFLAGS) etc.
* libgimpthumb/makefile.msc : (new file)
* makefile.msc : added libgimpthumb
* libgimpthumb/gimpthumbnail.c : include gimpwin32-io.h
* libgimpthumb/gimpthumb-utils.c : don't compare size pointer
with GIMP_THUMB_SIZE_FAIL but *size
* plug-ins/makefile.msc : handle libgimpoldpreview
* plug-ins/common/decompose.c : define cbrt() if not __GLIBC__
* plug-ins/common/winclipboard.c : make it compile without gimpcompat.h
* plug-ins/imagemap/imagemap_csim_lex.c : its a generated file
but still win32/msvc has no unistd.h
* plug-ins/pygimp/makefile.msc : (new file) to use the binary you
need to patch glib, see bug #98737
* plug-ins/libgimpoldpreview.c : use <libgimp/gimp.h> instead of "gimp.h"
* **/Makefile.am : added makefile.msc to EXTRA_DIST
2003-11-16 Hans Breuer <hans@breuer.org>
* app/text/*.c : still unacceptable patched to compile
without FT2, see bug #113681
* **makefile.msc : updated
* app/config/gimpconfig-dump.c : include gimpwin32-io.h
* app/plug-in/plug-ins.c : don't depend on g_print handling
%s with NULL pointers, it doesn't anymore with glib cvs at
least not on win32
* app/widgets/gimppropwidgets.c
libgimpbase/gimputils.c
libgimpwidgets/gimpmemsizeentry.c :
sorry about the mess, need to work-around a stupi not able
to cast from guint64 to double
* app/widgets/gimppropwidgets.c (gimp_prop_memsize_entry_new) :
avoid 'overflow in floating-point constant arithmetic' by disabling
an imho alays questionable g_return_val_if_fail() for _MSC_VER only
* libgimpmodule/gimpmodule.def : sorted
* libgimpwidgets/gimpfileselection.c : removed unused S_ISDIR
definition
* app/gui/themes.c : filenames in rc files need to be escaped
2003-11-08 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayout-render.c (gimp_text_layout_render)
* app/text/gimptextlayout.c (gimp_text_layout_position): handle
the case where the ink rectangle exceeds the logical rectangle.
Fixes bug #126480.
2003-11-05 Sven Neumann <sven@gimp.org>
* app/tools/gimptextoptions.c (gimp_text_options_gui): use
GTK_STOCK_SELECT_FONT stock icon instead of text tool icon.
* app/text/gimpfont.c: fixed default stock id.
* app/text/gimp-fonts.c (gimp_fonts_load): don't leave gimp busy
and the fonts container frozen in case of error.
2003-11-05 Sven Neumann <sven@gimp.org>
* app/main.c: added new command-line option --no-fonts. Might be
useful to reduce startup time or if there are problems with the
font configuration.
* app/app_procs.[ch]
* app/main.c
* app/core/gimp.[ch]
* app/text/gimp-fonts.c: don't load any fonts when gimp is started
with --no-fonts.
* docs/gimp-1.3.1.in: documented the new command-line option.
Updated some outdated information.
2003-11-05 Sven Neumann <sven@gimp.org>
* app/app_procs.c: register a log handler for the Gimp-Text domain.
* app/text/gimpfont.c: code cosmetics.
* app/text/gimptext-compat.c: removed debugging output.
Let GIMP work w/o any fonts. Of course you won't get any text
functionality then:
* app/text/gimpfontlist.c: don't install any font aliases if no
fonts were found.
* app/text/gimptextlayer.c: refuse to render any text layers when
the GIMP fonts list is empty.
* app/tools/gimptexttool.c: removed redundant includes.
* app/tools/gimptextoptions.c: removed the font selection widget.
This is a temporary regression that will be cured by improving the
GimpFontView widget.
* app/widgets/Makefile.am
* app/widgets/gimpfontselection-dialog.[ch]
* app/widgets/gimpfontselection.[ch]
* app/widgets/gimppropwidgets.[ch]: removed the font selection and
all references to it. Fixes bug #119267.
2003-11-03 Manish Singh <yosh@gimp.org>
* app/text/gimptext-vectors.c: use recommended freetype include
system of #include <ft2build.h> and #include FT_GLYPH_H things.
2003-10-27 Sven Neumann <sven@gimp.org>
* app/text/Makefile.am
* app/text/gimptextlayer-xcf.[ch]: new files that load and save
text layers to/from XCF.
* app/xcf/xcf-load.c
* app/xcf/xcf-save.c
* app/text/gimptextlayer.c: removed that code here and use the new
functions instead.
* app/text/gimptext-parasite.[ch] (gimp_text_from_parasite): added
a GError parameter.
* app/text/gimptextlayer.[ch]: store the name of the parasite that
the text layer was created from (if read from XCF). Remove the
parasite when the text layer is edited. If a text layer wasn't
touched, the original parasite is written back to the XCF file.
* app/text/gimptextlayout.c (gimp_text_layout_new): handle a NULL
text string.
* app/tools/gimptextoptions.c: implement GimpToolOptions::reset
and save the text across a reset.
2003-10-26 Sven Neumann <sven@gimp.org>
* app/text/gimptext.[ch]
* app/text/gimptextlayout.c: added back "box-unit" property; it
makes sense to have an extra unit for it.
2003-10-26 Sven Neumann <sven@gimp.org>
* app/config/gimpconfig-deserialize.c
(gimp_config_deserialize_fundamental): handle negative float and
double values similar to how this is done for integers and the
like.
* app/config/gimpconfig-params.h: added two new param flags and
documented all flags in the header file (for now).
* app/config/gimpconfig-serialize.h: handle the new param flags
GIMP_PARAM_DEFAULTS and GIMP_PARAM_IGNORE.
* app/text/text-enums.[ch]
* app/text/gimptext.[ch]: added some properties that we will need
sooner or later. Mark the new properties and a lot of the existing
ones as GIMP_PARAM_DEFAULTS so that their values are not
serialized unless changed from the default value.
* app/text/gimptextlayout.c
* app/tools/gimptextoptions.c: made all length properties in
GimpText depend on a single unit.
2003-10-25 Sven Neumann <sven@gimp.org>
* configure.in (ALL_LINUGUAS): added "ms" (Malay) now that all po
files are there.
(PANGOFT2_REQUIRED_VERSION) depend on PangoFT2 >= 1.2.2. There are
a couple of bug-fixes that are needed to make the text tool work.
Actually you should use at least version 1.2.4.
(GTK_REQUIRED_VERSION): depend on GTK+ >= 2.2.2. Earlier versions
had bugs that we don't want to work around any longer.
* INSTALL: document this change.
* app/gui/gui.c (gui_post_init): removed the GTK+ version check.
* app/text/gimptext.[ch]: added properties for letter spacing and
kerning for compatibility with future GIMP versions implementing
these features.
2003-10-18 Michael Natterer <mitch@gimp.org>
* app/text/gimp-fonts.c (gimp_fonts_load): added
gimp_container_freeze() / _thaw() around font list reloading.
* app/tools/gimp-tools.c (gimp_tools_init): added missing
gimp_container_freeze().
* app/widgets/gimpcontainerview.c: connect to the container's
"freeze" and "thaw" signals and empty / refill the view
accordingly. Ignore "add", "remove" and "reorder" signals while
the container is frozen. Fixes font list sorting after refresh and
speeds up refreshing of fonts, brushes, patterns etc.
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimpfontview.[ch]: new widget for the font list/grid.
* app/widgets/gimphelp-ids.h: added GIMP_HELP_FONT_REFRESH.
* app/gui/dialogs-constructors.c: changed accordingly.
* app/gui/Makefile.am
* app/gui/fonts-commands.[ch]
* app/gui/fonts-menu.[ch]: new files: a menu for the font view.
* app/gui/menus.c (menus_init): register the new <Fonts> menu.
* app/gui/preferences-dialog.c (prefs_dialog_new): removed the
fonts refreshing hack from the "Environment" page.
2003-10-14 Sven Neumann <sven@gimp.org>
* app/config/gimpconfig-utils.[ch]: removed
gimp_config_copy_properties() and added the more intelligent
gimp_config_sync() instead.
* app/config/Makefile.am
* app/config/config-types.h
* app/config/gimpcoreconfig.[ch]
* app/config/gimprc-blurbs.h: replaced default image properties
with a single GimpTemplate object property. Changed the
set_property function to not replace aggregate objects but call
gimp_config_sync() instead.
* app/tools/gimptextoptions.c (gimp_text_options_set_property):
same change here.
* app/config/gimpconfig.[ch]: changed return value of
gimp_config_duplicate() to gpointer to avoid some casts that only
made the code harder to read.
* app/widgets/gimptemplateeditor.[ch]: don't keep an internal copy
here but edit the GimpTemplate passed when the editor was
constructed.
* app/gui/preferences-dialog.c: use a GimpTemplateEditor to allow
editing of the default image paramaters.
* app/config/gimprc.c
* app/core/core-types.h
* app/core/gimp.c
* app/core/gimpimage-duplicate.c
* app/core/gimpimage-grid.c
* app/core/gimpimage-new.c
* app/core/gimpimage-undo-push.c
* app/core/gimpimage.c
* app/core/gimptemplate.[ch]
* app/gui/file-new-dialog.c
* app/gui/grid-dialog.c
* app/gui/info-window.c
* app/gui/resize-dialog.c
* app/gui/templates-commands.[ch]
* app/gui/tool-options-commands.c
* app/text/gimptextlayer.c
* app/text/gimptextlayer.c
* app/tools/gimptexttool.c
* app/widgets/gimptemplateview.c
* app/xcf/xcf-load.c: changed accordingly.
2003-10-09 Sven Neumann <sven@gimp.org>
* app/core/gimpobject.[ch]: added new function
gimp_object_name_collate() which compares two object names for
ordering using the linguistically correct rules for the current
locale and does some caching to speed up subsequent calls.
* app/core/gimpdatalist.c (gimp_data_list_data_compare_func): use
gimp_object_name_collate() from here.
* app/core/gimplist.[ch]: added convenience function
gimp_list_sort_by_name.
* app/text/gimpfontlist.c (gimp_font_list_restore): use
gimp_list_sort_by_name() instead of g_utf8_collate.
2003-10-09 Michael Natterer <mitch@gimp.org>
* app/core/gimpviewable.h: added GIMP_VIEWABLE_MAX_BUTTON_SIZE
GIMP_VIEWABLE_MAX_MENU_SIZE.
* app/core/gimpviewable.c (gimp_viewable_get_popup_size): smarter
popup size limitation: limit each axis to 2 * MAX_POPUP_SIZE
and the area to MAX_POPUP_SIZE ^ 2.
* app/core/gimpbuffer.c
* app/core/gimpimage-preview.c
* app/core/gimpitem-preview.c
* app/text/gimpfont.c (GimpViewable::get_popup_size): removed
all limitations.
* app/widgets/gimpcontainermenu.c
* app/widgets/gimpcontainermenuimpl.c
* app/widgets/gimpmenuitem.c
* app/widgets/gimpviewablebutton.c: use the new button and menu
size defines.
2003-10-01 Sven Neumann <sven@gimp.org>
* app/text/gimptextlayout.c: pango_font_description_set_size()
takes points not pixels as the old code assumed.
* app/text/gimptext.c
* app/text/gimptextlayout-render.c: fixed includes.
2003-10-01 Sven Neumann <sven@gimp.org>
* app/text/gimptext-compat.c (text_get_extents): set a default
resolution on the fontmap since Pango doesn't seem to do this for us.
2003-09-22 Sven Neumann <sven@gimp.org>
* app/core/gimpviewable.c (gimp_viewable_get_popup_size):
constrain popup size to GIMP_VIEWABLE_MAX_POPUP_SIZE but keep the
aspect ratio intact. Fixes bug #122923.
* app/text/gimpfont.c: use a smaller font size for popups so we
don't exceed the maximum size.
2003-09-11 Sven Neumann <sven@gimp.org>
* app/text/Makefile.am: removed PANGO_DISABLE_DEPRECATED again since
we have to use Pango API that is deprecated in the HEAD branch.
2003-09-06 Michael Natterer <mitch@gimp.org>
To optimize duplicate and/or wrong image updates away, introduced
new policy that a child object must never explicitly update or
invalidate its parent object (just like the GUI is not updated
explicitly by the core):
* app/core/gimpdrawable.[ch]: added new signal
GimpDrawable::update(). Never update or invalidate the image when
the drawable is updated or invalidated.
(gimp_drawable_set_visible): don't gimp_drawable_update() the
drawable since its pixels have not changed.
* app/core/gimpimage.[ch]: connect to the "add" and "remove"
signals of the layers and channels containers. Also connect to the
"update" and "visibility_changed" signals of all drawables in
these containers (optimizes away updates issued by drawables which
are not yet added to the image and updates of the selection
mask). Also, don't propagate updates to the image if the emitting
drawable is invisible (optimizes away updates issued by invisible
drawables).
(gimp_image_add_layer,channel)
(gimp_image_remove_layer,channel): don't update the image since
that's done by our "add" and "remove" handlers now.
(gimp_image_position_layer,channel): update just the image, not
the drawable since its pixels have not changed.
(gimp_image_real_colormap_changed)
(gimp_image_set_component_visible): always call
gimp_image_update() *and* gimp_viewable_invalidate_preview() to
get everything updated, since update and invalidate of images are
not connected.
* app/core/gimpimage-undo-push.c (undo_pop_layer,channel): don't
update the drawable since (a) its pixels don't change and (b) the
image updates itself upon adding/removing now.
(undo_pop_layer_mod): replaced gimp_image_update() by
gimp_drawable_update() (just for consistency with other similar
functions).
* app/core/gimplayer.c: connect to "update" of the layer mask and
issue updates on the layer if the mask update has any effect on
the projection.
(gimp_layer_create_mask): don't set the mask's offsets here since
they may be different when we later add the mask to the layer.
* app/core/gimplayermask.c (gimp_layer_mask_set_layer): set the
mask offsets here instead.
* app/core/gimpchannel.c (gimp_channel_translate): update the
channel even if push_undo == FALSE.
* app/paint/gimppaintcore.c (gimp_paint_core_finish)
* app/tools/gimpinktool.c (ink_finish): invalidate both the
drawable and the image preview since invalidating the drawable
doesn't invalidate the image any more.
* app/text/gimptextlayer.c (gimp_text_layer_render_now): also
update the new extents of the text layer, not only the old one.
(gimp_text_layer_render_layout): don't update the drawable since
gimp_drawable_fill() already updated it.
2003-09-04 Michael Natterer <mitch@gimp.org>
* app/core/gimpdrawable.[ch]: added new pure virtual function
GimpDrawable::invalidate_boundary().
* app/core/gimplayer.[ch]: implement it and removed public
function gimp_layer_invalidate_boundary().
* app/core/gimpchannel.[ch]: implement it.
* app/core/gimpselection.[ch]: implement it and removed public
function gimp_selection_invalidate().
* app/core/gimpimage-mask.c (gimp_image_mask_invalidate)
* app/core/gimpimage-undo-push.c
* app/core/gimpimage.c
* app/core/gimplayer-floating-sel.c
* app/text/gimptextlayer.c: changed accordingly.
* app/core/gimpchannel.[ch]: made gimp_channel_push_undo() a
public function and made it call
gimp_drawable_invalidate_boundary(). Added undo_desc strings for
all undo pushing functions to GimpChannelClass.
* app/core/gimpselection.[ch]: removed gimp_selection_push_undo()
since after the change above it was identical to
gimp_channel_push_undo(). Don't push any undo here since
upchaining does the right thing now. Override GimpChannelClass'
undo_desc strings to say "Selection".
* app/core/gimpimage-mask.c (gimp_image_mask_push_undo): changed
accordingly.
2003-09-01 Manish Singh <yosh@gimp.org>
Font configuration stuff: You can rescan for fonts on the fly now.
A couple caveats: the text tool font dialog doesn't get updated, but
that's supposed to be going away. The new font dock doesn't resort
on update, but mitch is supposed to fix that. :)
Some nice stuff for advanced font users: GIMP local font directories,
and an optional site and user fonts.conf.
I thought about supporting the auto-resan feature in fontconfig,
but it might take too much time to do a scan so I haven't implemented
it. Another thing I want to do is create fontconfig caches in the
local dirs.
* text/gimpfonts.[ch]: gimp_fonts_init/load/reset implementation.
* text/Makefile.am: added gimpfonts.[ch]
* app/core/gimp.c: use gimp_fonts_init/reset.
* app/config/gimpcoreconfig.[ch]
* app/config/gimprc-blurbs.h: added font-path config setting.
* app/gui/preferences-dialog.c: Add a Font Folders section for the
above. Also added a Rescan Font List button, which goes in the
Environment section. Not sure if this is the right place...
it also looks kinda ugly all by its lonesome.
* app/gui/user-install-dialog.c: mention the fonts directory.
* themes/Default/images/preferences/Makefile.am
* themes/Default/images/preferences/folders-fonts.png: dummy icon for
font folders pref, probably a folder with a little "T" in the corner
would be good.
2003-09-01 Sven Neumann <sven@gimp.org>
* app/xcf/xcf-load.c: removed excessive path debugging output.
* app/text/gimptext-vectors.c: always close strokes created from
text outlines.
2003-09-01 Sven Neumann <sven@gimp.org>
* app/text/gimptext-vectors.c: use the new bezier stroke API.
* app/vectors/gimpbezierstroke.c (gimp_bezier_stroke_new_moveto):
pass a NULL anchor to the first call of gimp_bezier_stroke_extend().
2003-08-31 Sven Neumann <sven@gimp.org>
* app/gui/layers-commands.[ch]
* app/gui/layers-menu.c: added "Merge Visible Layers..." and
"Flatten Image" menu entries as suggested in bug #120959.
* app/text/gimptext-vectors.c: fixed function declaration; we are
passing a PangoGlyph here, not a (PangoGlyph*).
2003-08-28 Larry Ewing <lewing@ximian.com>
* app/text/gimptext-vectors.c (conicto): interpolate the position
of the cubic control points correctly and set the previous control
point.
(cubicto): set the previous control point to the new value then
add remaining points.
2003-08-20 Sven Neumann <sven@gimp.org>
* app/gui/preferences-dialog.c
* app/text/gimptextlayer-transform.c
* app/widgets/gimpitemfactory.c: some changes for legacy compilers
based on a patch from Avi Bercovich (bug #120251).
2003-08-17 Simon Budig <simon@gimp.org>
* app/vectors/gimpstroke.[ch]
* app/vectors/gimpbezierstroke.[ch]: Virtualized
gimp_bezier_stroke_extend, added gimp_stroke_is_extendable.
* app/text/gimptext-vectors.c: changed accordingly.
* app/vectors/gimpvectors.[ch]: added gimp_vectors_anchor_select.
* app/tools/gimpvectoroptions.[ch]: dummy switch for future
extensions
* app/tools/gimpvectortool.[ch]: Major overhaul. Made use of
gimp_vector_tool_oper_update, cleaned up
gimp_vector_tool_button_press a lot and finally have a
working cursor_update. Still buggy, but I wanted to have it
in CVS.