Begin to consider GimpObject::name as private and always use
gimp_object_get_name(). Change gimp_object_get_name() to take an
untyped pointer so we don't have to do so awfully many casts. There is
a runtime check for the type inside the function anyway.
2009-01-17 Michael Natterer <mitch@gimp.org>
* all files with a GPL header and all COPYING files:
Change licence to GPLv3 (and to LGPLv3 for libgimp).
Cleaned up some copyright headers and regenerated the parsers in
the ImageMap plugin.
svn path=/trunk/; revision=27913
2007-03-04 Michael Natterer <mitch@gimp.org>
* app/core/gimpobject.c (gimp_object_get_memsize): don't pass
random strings to g_print() without running them through %s.
Fixes crash/warning when the string contains '%'.
svn path=/trunk/; revision=22042
2006-04-07 Michael Natterer <mitch@gimp.org>
* app/core/gimpobject.h: added "guint disconnected : 1", we
have enough space for flags now.
* app/core/gimpobject.c (gimp_object_dispose): use the new
object->disconnected flag instead of attaching that boolean to the
object.
2006-04-05 Tor Lillqvist <tml@novell.com>
* app/core/gimpobject.c (gimp_object_get_memsize): Check if
object->name is NULL before attempting to pass it to
g_strdup_printf(). Use "anonymous" for unnamed objects.
2006-01-18 Michael Natterer <mitch@gimp.org>
* app/config/config-types.c: define GIMP_PARAM_STATIC_STRINGS
which is G_PARAM_STATIC_NAME|NICK|BLURB. Also define
GIMP_PARAM_READABLE, _WRITABLE and _READWRITE which include
GIMP_PARAM_STATIC_STRINGS.
* app/*/*.c: use them for all object properties so their
strings are not copied.
2005-12-10 Michael Natterer <mitch@gimp.org>
* app/config/*.c
* app/core/*.c
* app/display/*.c
* app/text/*.c
* app/vectors/*.c: port to G_DEFINE_TYPE() and friends. Some related
core reordering and cleanup.
2005-10-10 Michael Natterer <mitch@gimp.org>
* app/core/gimpviewable.c (gimp_viewable_get_description): set the
"tooltip" return value to NULL before calling the virtual function.
* app/core/gimpbrush.c
* app/core/gimpbuffer.c
* app/core/gimpchannel.c
* app/core/gimplayer.c
* app/core/gimppaintinfo.c
* app/core/gimppalette.c
* app/core/gimppattern.c
* app/core/gimptoolinfo.c (get_description): don't do it here.
* app/core/gimpbuffer.c
* app/core/gimppaintinfo.c: untabbify, cleanup.
* app/core/gimpobject.c: emit "notify::name" whenerver the name
changes, clenup.
2003-11-25 Michael Natterer <mitch@gimp.org>
* app/core/gimpobject.[ch]: removed gimp_g_object_get_memsize()...
* app/core/gimp-utils.[ch]: ...and added it here along with
some other memsize utilities for GHashTables and G(S)Lists.
* app/core/gimp.c
* app/core/gimpimage.c
* app/core/gimpparasitelist.c
* app/core/gimpviewable.c
* app/vectors/gimpstroke.c (GimpObject::get_memsize): use the new
functions.
2003-11-16 Sven Neumann <sven@gimp.org>
* app/core/gimpobject.[ch]: exposed gimp_object_name_free() and
added documentation.
* app/core/gimplist.[ch] (gimp_list_uniquefy_name): use
gimp_object_name_free() when changing the object name silently.
Renamed "use_set_name" parameter to "notify" and documented the
function.
2003-11-16 Sven Neumann <sven@gimp.org>
* app/core/gimpobject.c: fixed a bad oversight in the
implementation of normalized object names. Introduced the helper
function gimp_object_name_free() that takes care of freeing
the normalized name. Fixes bug #127075.
2003-10-20 Sven Neumann <sven@gimp.org>
* app/core/gimpobject.c (gimp_object_name_collate): must use
strcmp() not strcoll() on the collation keys obtained from
g_utf8_collate_key().
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-08-25 Michael Natterer <mitch@gimp.org>
* app/core/gimpobject.[ch]: changed GimpObject::get_memsize() to
return a second value named "gui_size", where the primary return
value is the "constant" actual size (as long as no operation is
performed on the object), and the second "gui_size" return value
is the size of temporary stuff like preview caches or boundary
segments (which may change asynchronously, even if the object is
on the undo stack).
* app/core/gimp.c
* app/core/gimpbrush.c
* app/core/gimpbrushpipe.c
* app/core/gimpbuffer.c
* app/core/gimpchannel.c
* app/core/gimpcontainer.c
* app/core/gimpcontext.c
* app/core/gimpdata.c
* app/core/gimpdatafactory.c
* app/core/gimpdrawable.c
* app/core/gimpgradient.c
* app/core/gimpimage-undo.c
* app/core/gimpimage.c
* app/core/gimpitem.c
* app/core/gimplayer.c
* app/core/gimplist.c
* app/core/gimppalette.c
* app/core/gimpparasitelist.c
* app/core/gimppattern.c
* app/core/gimpundo.c
* app/core/gimpundostack.c
* app/core/gimpviewable.c
* app/text/gimptextlayer.c
* app/vectors/gimpstroke.c
* app/vectors/gimpvectors.c: changed get_memsize() implementations
accordingly.
* app/display/gimpdisplayshell-title.c
* app/gui/debug-commands.c
* app/widgets/gimppreview.c: changed callers accordingly.
* app/core/gimpimage-undo-push.c: changed layer, channel, vectors
and layer_mask undo steps to add/subtract the size of the
resp. objects whenever they take/drop ownership of them. Ignore
the objects' "gui_size" to get identical sizes on
adding/subtracting. Fixes bug #120429.
2003-02-05 Sven Neumann <sven@gimp.org>
* libgimpbase/Makefile.am
* libgimpbase/gimputils.[ch]: added new files that hold the new
gimp_utf8_strtrim() routine; it might be useful in more places.
* libgimpbase/gimpdatafiles.c (gimp_datafiles_read_directories):
silently ignore directories in the path that can't be opened.
* app/core/gimpobject.c (gimp_object_set_name_safe): use
gimp_utf8_strtrim().
* app/widgets/gimpwidgets-utils.[ch]
* app/tools/gimptextoptions.c: try to make the text tool options
look more like all other tool options. Still needs work; I'll
leave this up to Mitch ...
This byte --> <-- is the millionth in this file!
2003-02-05 Sven Neumann <sven@gimp.org>
* app/core/gimpobject.c (gimp_object_set_name_safe): replaced with
an UTF-8 safe rewrite.
* app/widgets/gimpwidgets-utils.c (gimp_table_attach_stock): hacked
to allow being used with non-existent stock_ids (for prototyping).
* app/widgets/gimpenummenu.c: set the radio button mode correctly.
* app/widgets/gimpfontselection.c: tweaked spacing.
* app/tools/gimptextoptions.c: added controls for justification and
indentation. Removed letter-spacing control for now.
* app/text/gimptextlayer.[ch]: rerender the text layer from a low
priority idle function.
2003-02-05 Sven Neumann <sven@gimp.org>
* app/core/gimpobject.[ch]
* app/text/gimptextlayer.c: improved the code that trims the text
before setting it as layer name and moved it to GimpObject as
gimp_object_set_name_safe().
* app/text/gimptext.[ch]: removed fixed_height and gravity again.
* app/text/gimptextlayout.c: much simpler positioning that has the
advantage that it actually works.
* libgimpproxy/gimpobject.[ch]: this crap was regenerated.
2003-01-05 Manish Singh <yosh@gimp.org>
* app/core/gimpobject.c: cast memsize to a guint instead of format
change. Problem perhaps if get_size really is > 4 GB?
2003-01-05 Manish Singh <yosh@gimp.org>
* many files in app, modules and libgimp*: cleanup, removed unecessary
G_OBJECT() casts. Should do the same for plug-ins, when more of them
get undeprecated.
2002-04-03 Manish Singh <yosh@gimp.org>
* app/core/gimpobject.c: use gobject marshaller names directly so
libgimpproxy doesn't need gimpmarshal.* around
2002-02-06 Michael Natterer <mitch@gimp.org>
* app/core/gimpobject.c: made the gimp_object_get_memsize()
debugging output configurable by a global "gimp_debug_memsize"
boolean.
* app/display/gimpdisplay.c: removed duplicated prototype.
* app/display/gimpdisplayshell.[ch]: renamed the various cursor
functions to be more consistent and shorter. Compress window title
updates by adding a "gboolean title_dirty" and updating the title
in gimp_display_shell_flush(). Added "%m" (memory size) to the
possible title string substitutions.
* app/display/gimpdisplay-foreach.c
* app/display/gimpdisplayshell-handlers.c
* app/tools/gimpfuzzyselecttool.c
* app/tools/gimptool.c: changed accordingly.
* app/display/gimpdisplayshell-callbacks.c: forgot to grab the
pointer when dragging guides from the rulers. Coincidentially,
this also fixes the buggy offset between guide and mouse
pointer...
Cleaned up the main tool event callback a but more.
* app/widgets/gimppreview.c
* app/gui/commands.c: set the new global "gimp_debug_memsize"
toggle to TRUE while calling gimp_object_get_memsize().
* app/gui/preferences-dialog.c: added a image title example
containing the new "%m" feature.
* docs/gimprc-1.3.5.in: document "%m" in the manpage.
* app/tools/gimpbezierselecttool.c: reordered some statements.
* app/tools/gimpdrawtool.[ch]: store the GimpDisplay passed to
gimp_draw_tool_start() in draw_tool->gdisp and use it for
coordinate transfomration. This way we can paint on a display
which is not tool->gdisp.
* app/tools/gimppainttool.c: changed the gimp_draw_tool_foo()
calls needed to make the straight_line preview work in a way
that does not interfere with paint_tool subclasses which want
to do their own drawing (like the clone tool).
Also changed the paint_tools PRETRACE_PAINT and POSTTRACE_PAINT
flags usage in a way that subclasses can use them without major
hackery: don't simply wrap gimp_display_flush_now() with
PRETRACE/POSTTRACE calls, but wrap the actual painting calls, so
subclasses are able to do useful things with paint_tool->*_coords.
* app/tools/gimpclonetool.c: removed poking around in draw_tool
internals and simply suspend()/resume() it in
PRETRACE_PAINT/POSTTRACE_PAINT to get the clone_src indicator
drawn correctly.
2001-11-23 Sven Neumann <sven@gimp.org>
* configure.in: bumped version number to 1.3.1.
Require Glib/GTK+-1.3.11 and Pango-0.22. Removed GDK_DISABLE_COMPAT_H
and GTK_DISABLE_COMPAT_H from our default CFLAGS since they don't
exist any longer.
* RELEASE-TO-CVS.patch: removed since the glib/gtk+ API is supposed to
be frozen now.
* HACKING: removed reference to RELEASE-TO-CVS.patch
* app/gui/menus.c
* app/tools/gimptexttool.c: applied RELEASE-TO-CVS.patch to conform
to the new GTK+/Pango API.
* app/core/Makefile.am: generate marshallers with gimp_marshal prefix.
* app/core/gimpmarshal.list: added all marshallers we use.
* app/core/gimpmarshal.[ch]: regenerated.
* app/[lots of .c files]: use gimp_marshal_* for all marshallers.
* data/images/
* app/app_procs.c
* app/gui/splash.c:
* libgimpbase/Makefile.am
* libgimpbase/gimpbase.h
* libgimpbase/gimputils.[ch]: removed since they are no longer needed.
* app/gimprc.c
* plug-ins/common/ps.c
* plug-ins/gdyntext/gdyntext.c
* plug-ins/gdyntext/gdyntextcompat.c
* plug-ins/gfig/gfig.c
* plug-ins/gflare/gflare.c
* plug-ins/script-fu/script-fu-scripts.c: use glib functions instead
of gimp_strescape() and gimpstrcompress().
* cleaned up all header files: use G_BEGIN_DECLS/G_END_DECLS, declared
all _get_type function as G_GNUC_CONST.
* tools/pdbgen/enumcode.pl
* tools/pdbgen/lib.pl: make them generate header files using
G_BEGIN_DECLS/G_END_DECLS.
* pixmaps/Makefile.am
* pixmaps/wilber3.xpm: removed ...
* data/images/tips_wilber.png: ... and added here as PNG
* app/gui/tips-dialog.c: load the Wilber on demand using GdkPixbuf.
* data/images/gimp_splash.ppm: removed ...
* data/images/gimp_splash.png: ... and added as PNG
* app/app_procs.c
* app/gui/splash.[ch]: load the splash image using GdkPixbuf.
* app/gui/about-dialog.c: sink the GtkPreview.
2001-08-14 Michael Natterer <mitch@gimp.org>
* app/gdisplay.h: an evil temp_hack which lets GimpContext managing
the active display withoug including "gdisplay.h". Will go away as
soon ad context properties are registered dynamically.
* app/module_db.c: cleaned up the object code in preparation of
moving it to core/.
* app/path.c: connect to GimpImage's
* app/core/gimpobject.[ch]: derive it from GObject, not from
GtkObject any more (yeah :-)
* app/core/*.c: #include <glib-object.h> instead of <gtk/gtk.h>,
removed some remaining GtkObject-isms.
(left in a few #include <gtk/gtk.h> where bigger changes are needed
to get rid of the UI dependency).
* app/core/core-types.h: #include <gdk-pixbuf/gdk-pixbuf.h> here
temporarily.
* app/core/gimp.c (gimp_create_display): unref the image after
creating it's first display.
* app/core/gimpbrush.[ch]: disabled the parts of the code which
depend on GimpPaintTool.
* app/core/gimpbrushgenerated.c
* app/core/gimpbrushpipe.c: changed accordingly.
* app/core/gimpcontext.[ch]: evil hack (see above) to manage the
active display without including "gdisplay.h"
* app/core/gimpimage-mask.[ch]: pass a context to
gimage_mask_stroke() and get the current tool's PDB string from
there.
* app/core/gimpedit.c: changed accordingly.
* app/core/gimpimage.c: use gimp_image_update() instead of
gdisplays_update_full().
* app/gui/color-area.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-constructors.c
* app/gui/edit-commands.c
* app/gui/image-commands.c
* app/gui/toolbox.c: changed accordingly (don't use Gtk methods on
GObjects).
* app/gui/menus.c: fix some const warnings by explicit casting.
* app/tools/*.[ch]: ported all tools to GObject, some minor
cleanup while i was on it.
* app/widgets/gimpdialogfactory.[ch]: ported to GObject.
* app/widgets/gimplayerlistview.h: added FOO_GET_CLASS() macro.
* tools/pdbgen/app.pl: added a "widgets_eek" hack like "tools_eek"
which inserts #include "widgets/widgets-types.h" before ordinary
includes.
* tools/pdbgen/pdb/brush_select.pdb
* tools/pdbgen/pdb/edit.pdb
* app/pdb/brush_select_cmds.c
* app/pdb/edit_cmds.c: changed according to the stuff above.
2001-08-12 Michael Natterer <mitch@gimp.org>
Switched to GObject reference counting:
* app/core/gimpcontainer.c: only ref(), not ref()/sink() children
of strong containers. Reordered gimp_container_remove() so we
don't need to ref the object while removing it.
* app/core/gimpcontext.c: misc fixes. Needs to be badly tortured...
* app/app_procs.c
* app/gdisplay.c
* app/gimprc.c
* app/core/gimp.c
* app/core/gimpbrush.c
* app/core/gimpbrushpipe.c
* app/core/gimpdatafactory.c
* app/core/gimpdocuments.c
* app/core/gimpgradient.c
* app/core/gimpimage.c
* app/core/gimplayer.c
* app/core/gimplist.c
* app/core/gimpobject.c
* app/core/gimpparasite.c
* app/core/gimppattern.c
* app/core/gimpundostack.c
* app/gui/dialogs.c
* app/tools/gimpbezierselecttool.c
* app/tools/gimpfuzzyselecttool.c: changed accordingly: don't
ref()/sink() any more, unref all (??) objects after adding them to
strong containers, misc. minor fixes.
* app/gui/dialogs-constructors.c
* app/widgets/gimpwidgets.c: use g_object_add_weak_pointer()
instead of simply crashing because g_object_weak_ref() was used
with gtk_widget_destroyed, brrr.
* app/widgets/gimpdnd.c: removed unneeded g_return_if_fail()'s.
2001-08-11 Michael Natterer <mitch@gimp.org>
* configure.in: fsck^^^ -- lovely autofoo wants "changequote([,])dnl"
* app/core/gimpcontext.[ch]: lots of GObject porting.
* app/core/gimpobject.[ch]: added a "disconnect" signal, which
like gtk's "destroy" is emitted in dispose(). This is ugly but
I don't see another "clean" way to implement weak containers.
* app/core/gimpcontainer.c: connect to the "disconnect" signal of
the children of weak containes.
* app/core/gimpimage.[ch]: replaced the "destroy" implementation
with "dispose" + "finalize". Removed gimage->undo_history.
* app/devices.c
* app/gui/dialogs-constructors.c
* app/gui/tools-commands.c
* app/tools/tool_manager.c
* app/widgets/gimpimagedock.c: changed accordingly.
2001-08-11 Michael Natterer <mitch@gimp.org>
* TODO.xml: added a TODO entry about additional image/file info.
* app/file-save.c: #include "core/gimpdocuments.h"
* app/core/gimpcontainer.[ch]: made virtual functions out of some
signals.
* app/core/*.[ch]: more GObject stuff: ported all
gimp_foo_get_type() functions and replaced almost all "destroy"
implementations with either "finalize" or "dispose" functions.
2001-07-24 Michael Natterer <mitch@gimp.org>
Port to glib/gtk+ 2.0 episode I (every segfault has it's beginning)
* configure.in: require glib/gtk+ >= 1.3.7, commented out the
gtkxmhtml stuff.
From now on, you will need glib, pango, atk and gtk+ HEAD from CVS
to hack or use GIMP HEAD.
Beware, it crashes randomly :)
* app/core/Makefile.am
* app/core/gimpmarshal.list: new file plus rules to generate
gimpmarshal.[ch] from it.
* app/core/*
* app/tools/*
* app/widgets/*
* libgimpwidgets/*: started to use the glib object system. All
core/ objects are still gtk objects however. All signals are
created using g_signal_new(). There are many gtk+ artefacts left.
Finally, we will _not_ use the gtk_signal_foo() wrappers and
friends any more.
* app/colormaps.c
* app/devices.[ch]
* app/disp_callbacks.c
* app/errorconsole.c
* app/file-save.[ch]
* app/interface.c
* app/module_db.c
* app/nav_window.c
* app/ops_buttons.c
* app/scroll.c
* app/user_install.c
* app/gui/about-dialog.c
* app/gui/brush-editor.c
* app/gui/brushes-commands.c
* app/gui/color-notebook.c
* app/gui/colormap-dialog.c
* app/gui/dialogs-commands.c
* app/gui/dialogs-constructors.c
* app/gui/file-commands.c
* app/gui/file-dialog-utils.c
* app/gui/file-new-dialog.c
* app/gui/file-open-dialog.[ch]
* app/gui/file-save-dialog.c
* app/gui/gradient-editor.c
* app/gui/gradients-commands.c
* app/gui/image-commands.c
* app/gui/info-dialog.[ch]
* app/gui/layer-select.c
* app/gui/layers-commands.c
* app/gui/menus.c
* app/gui/offset-dialog.c
* app/gui/palette-editor.c
* app/gui/palettes-commands.c
* app/gui/patterns-commands.c
* app/gui/preferences-dialog.c
* app/gui/resize-dialog.[ch]
* app/gui/splash.c
* app/gui/tips-dialog.c
* app/gui/tool-options-dialog.c
* app/gui/toolbox.c
* app/gui/tools-commands.c
* libgimp/gimpbrushmenu.c
* libgimp/gimpmenu.c
* libgimp/gimppatternmenu.c
* libgimp/gimpui.c
* libgimpbase/gimpenv.c: tons and tons of changes like "const
gchar*", switch from GdkDeviceInfo to GdkDevice (very incomplete
and currently disables), lots of s/gtk_signal/g_signal/,
removal/replacement of deprecated stuff,
s/GtkSignalFunc/GCallback/ and lots of small changes and fixes
while I was on it, zillions of warnings left...
* modules/Makefile.am: disabled the water color selector
temporarily (XInput issues).
* plug-ins/Makefile.am
* plug-ins/common/.cvsignore
* plug-ins/common/Makefile.am
* plug-ins/common/plugin-defs.pl: simply excluded all plug-ins
which did not build (including Script-Fu). They are trivial to
fix.
2001-04-25 Michael Natterer <mitch@gimp.org>
* app/gimpobject.c: : free all the pipe's brushes here.
* app/gimpparasite.c: gimp_personal_rc_file()'s return value has
to be g_free()'d.
* app/main.c: indentation.
Ported memleak fixes from 1.2:
* app/gimpbrush.c: don't leak all pixmaps.
* app/gimpbrushpipe.c: ported memleak fixes from 1.2