- don't include <gdk-pixbuf/gdk-pixbuf.h> in headers in app/
- instead, include it in many .c files instead of <glib-object.h>,
finally acknowledging the fact that app/ depends on gdk-pixbuf almost
globally
- fix up includes as if libgimpbase depended in GIO, which it soon will
- move the code that sets the tool options' "defined" and "serialize"
properties from GimpToolInto to GimpToolOptions so they are always
set correctly.
- make GimpToolOptions fix broken serialized NULL tools automatically.
- make sure a GimpToolPreset's tool options always has a tool set. If all
fails, set a NULL tool explicitly and let the logic in GimpToolOptions
find the right tool.
- set GimpToolPreset's "use" booleans to FALSE for context properties
that have no effect on the tool.
- set GimpToolPresetEditor's toggle insensitive for these properties.
Instead, keep around a GimpFilteredContainer in GimpToolInfo that
maintains a per-tool list of presets from the global preset factory.
Turn the tool options dialog's preset Save/Restore/Edit/Delete menus
and buttons into shortcuts for managing the active tool's presets.
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
2008-05-18 Michael Natterer <mitch@gimp.org>
* app/core/gimptoolinfo.[ch]: add
gimp_tool_info_build_options_filename() which creates a filename
under $GIMPDIR/tool-options/ with an optional suffix.
* app/core/gimptooloptions.c
* app/core/gimptoolpresets.c: use it and remove own build_filename()
functions.
svn path=/trunk/; revision=25701
2007-07-17 Sven Neumann <sven@gimp.org>
* app/core/gimptoolinfo.c (gimp_tool_info_new): use the tool-info
identifier as the name of the tool-options object.
* app/paint/gimppaintoptions.c (gimp_paint_options_new): use the
paint-info identifier as the name of the paint-options object.
* app/paint/gimp-paint.c (gimp_paint_register): added parameter check.
* app/tools/gimp-tools.c (gimp_tools_init): formatting.
svn path=/trunk/; revision=22941
2006-12-10 Sven Neumann <sven@gimp.org>
* app/core/Makefile.am
* app/core/core-types.h
* app/core/gimptoolpresets.[ch]: added GimpToolPresets, derived
from GimpList.
* app/core/gimptoolinfo.[ch]: use the new type, renamed
member "options_presets" to "presets".
* app/actions/tool-options-actions.c
* app/actions/tool-options-commands.c
* app/core/gimptooloptions.[ch]
* app/menus/tool-options-menu.c
* app/widgets/gimptooloptionseditor.c: changed accordingly.
* app/tools/gimp-tools.c: let the GimpToolPresets object deal
with
loading and saving the presets from ${gimpdir}/tool-options.
* app/core/gimpcontainer-filter.c
* app/core/gimpdocumentlist.c
* app/core/gimplist.c
* app/text/gimpfontlist.c: use canonical property names.
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-27 Michael Natterer <mitch@gimp.org>
Fixed incomplete core/ui separation of paint tools and paint
methods:
* app/core/core-enums.h
* app/core/gimpcontext.[ch]: added a "paint-info" property and API
so the current paint method can be selected without the need for
an active tool.
(gimp_context_real_set_tool): set the paint-info to
tool_info->paint_info so the paint method follows the active tool
just as the active image follows the active display.
* app/core/gimp.h (struct Gimp)
* app/core/gimppaintinfo.[ch]: added "standard_paint_info" API
and stuff to be consistent with other context object properties.
* app/paint/gimp-paint.c: set the paintbrush as
standard_paint_info.
* app/core/gimpstrokedesc.c (gimp_stroke_desc_new): removed the
hack of falling back to the paintbrush when there is no active
tool and use the active paint method instead. Fall back to the
standard paint method if there is no active one.
(nothing in the core uses the active tool any more now).
* app/widgets/gimpdeviceinfo.h: add the paint info to the
properties which are saved in devicerc.
Added identifiers (names) and stock-ids to GimpPaintInfo:
* app/core/gimppaintinfo.[ch] (gimp_paint_info_new): added
identifier and stock-id parameters.
* app/core/gimptoolinfo.c (gimp_tool_info_new): removed the hack
of setting the paint-info stock-id from the tool-info stock-id.
* app/paint/paint-types.h
* app/paint/gimp-paint.c: changed GimpPaintRegisterCallback
accordingly.
* app/tools/gimp-tools.c (gimp_tools_register): changed paint
info names accordingly.
* app/paint/*.c (gimp_*_register): pass identifier and stock-id
accordingly.
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.
2005-09-04 Michael Natterer <mitch@gimp.org>
Cleaned up and fixed the order in which default tool options and
user context values are initialized, and added loading / saving of
the global user context. Fixes bug #165078.
* app/core/Makefile.am
* app/core/gimp-contexts.[ch]: new files which manage the global
contexts. Contains gimp_contexts_init/exit/load/save/clear().
* app/core/gimp.c: use the new init/exit functions instead of
implementing the stuff here.
* app/tools/gimp-tools.c: load/save/clear the user context from
here so it follows the same logic as the tool options. Reset all
tool options before loading the user context and copy the user
context's property to all tool options before loading tool
options.
* app/core/gimptoolinfo.c (gimp_tool_info_new): don't initialize
the tool options with the users context's properties. It's way too
early here and they will be overwritten later.
* app/widgets/gimpdevices.c (gimp_devices_restore): initialize all
device contexts with the user context's properties before loading
the devices and copying the active one back to the user context.
2004-07-03 Michael Natterer <mitch@gimp.org>
* app/core/gimpcontext.[ch]: added context->serialize_props mask
which enables specifying exactly which properties will be
serialized. Also fixes a bug that prevented undefined properties
from being serialized, breaking tool_options and device status
serialization.
* app/core/gimptoolinfo.c (gimp_tool_info_new): make only the
properties in the tool_info->context_props mask serializable, also
configure/initialize tool_info->tool_options.
* app/tools/gimp-tools.c (gimp_tools_register): removed
tool_options initialization that is now done in
gimp_tool_info_new().
* app/widgets/gimpdeviceinfo.c: make only the properties in
GIMP_DEVICE_INFO_CONTEXT_MASK serializable.
* app/widgets/gimpdevicestatus.c: add the device table to its
parent container again. Fixes "missing" devices.
* app/core/gimptooloptions.c
* app/widgets/gimpdevices.c: cleanup / code review.
2004-05-24 Sven Neumann <sven@gimp.org>
* app/core/gimptoolinfo.[ch]: derive GimpToolInfo from
GimpViewable, it doesn't make sense for it to be a GimpData.
* app/widgets/gimptooloptionseditor.c
(gimp_tool_options_editor_get_title): do not append " Options" to
the tool name. Fixes bug #142280.
2004-05-24 Michael Natterer <mitch@gimp.org>
Long overdue core container cleanup:
* app/core/gimplist.[ch]: added "unique-names" and "sort-func"
properties and merged the resp. code from GimpDataList into
GimpList. Removed "policy" parameters from gimp_list_new() and
added "unique_names". Added new constructor gimp_list_new_weak().
Made public function gimp_list_uniquefy_name() private.
* app/core/Makefile.am
* app/core/core-types.h
* app/core/gimpdatalist.[ch]: removed. Its functionality is
entirely in GimpList now.
* app/core/gimpdata.[ch]: added gimp_data_name_compare() which
used to live in GimpDataList.
* app/core/gimp.c
* app/core/gimpdatafactory.c
* app/core/gimpimage.c
* app/core/gimptoolinfo.c
* app/core/gimpundostack.c
* app/paint/gimp-paint.c
* app/tools/gimp-tools.c
* app/widgets/gimpdevices.c
* app/widgets/gimptemplateeditor.c
* app/widgets/gimpundoeditor.c: changed list creation accordingly.
Made gimp->templates, gimp->named_buffers, tool_info->presets and
the image's lists of layers, channels and vectors automatically
ensure unique names.
* app/widgets/gimptemplateview.c
* app/actions/file-commands.c
* app/actions/templates-commands.c
* app/actions/tool-options-commands.c: removed calls to
gimp_list_uniquefy_name().
* app/core/gimpitem.c: removed major insanity where the items
themselves where ensuring their unique names. Bah!
* app/core/gimplayer.c (gimp_layer_name_changed): chain up
conditionally.
* app/core/gimplayermask.c (gimp_layer_mask_name_changed): removed
because there is no need any more to keep the parent
implementation from being invoked.
2004-05-18 Michael Natterer <mitch@gimp.org>
* app/core/gimptoolinfo.c: made the "visible" property serializable.
* app/tools/gimp-tools.c: store the tools' order and visibility
in a new config file called "toolrc".
2004-05-10 Michael Natterer <mitch@gimp.org>
Started making the toolbox configurable.
Addresses bug #105764. Not finished yet.
* app/core/gimptoolinfo.[ch]: renamed "in_toolbox" to "visible"
and made it a GObject property.
* app/tools/gimp-tools.[ch]: added new function
gimp_tools_get_default_order() which returns a GList of tool
identifiers.
* app/actions/tools-actions.c
* app/actions/tools-commands.[ch]: added actions & callbacks for
toggling the "visible" boolean and for resetting all tools.
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimptoolview.[ch]: new widget which allows to
toggle a tool's visibility and to reorder the tools.
* app/widgets/gimptoolbox.[ch]: removed member "GtkWidget *trash"
and pack all tool buttons into the same wrap box. Connect to
"reoder" of the tool container and to "notify::visible" of all
tool infos and update the toolbox accordingly.
* app/gui/dialogs-constructors.c: create a GimpToolView for the
tools list/grid.
* app/menus/menus.c: register a <Tools> menu for the dialog above.
* menus/Makefile.am
* menus/tools-menu.xml: added the menu.
2003-09-29 Michael Natterer <mitch@gimp.org>
* app/core/gimptoolinfo.[ch]: added a GimpContainer of tool
options presets.
* app/core/gimptooloptions.[ch] (gimp_tool_options_set_property):
silently accept setting the *same* tool_info again.
(gimp_tool_options_build_filename): is public now.
* app/tools/gimp-tools.c (gimp_tools_restore,save): load and save
the presets container.
* app/gui/tool-options-dialog.[ch]: removed.
* app/gui/tool-options-commands.[ch]
* app/gui/tool-options-menu.[ch]: new files implementing a menu
for the new GimpToolOptionsEditor widget. Has submenus for saving,
loading, and deleting tool options to/from the
tool_info->options_presets container.
* app/gui/Makefile.am
* app/gui/dialogs-constructors.c
* app/gui/menus.c: changed accordingly.
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimptooloptionseditor.[ch]: the tool options dialog
as proper widget. The "Load" and "Save" buttons still do the same
stuff as before. Will make them use the new presets since making
them do something useful was the reason for this whole change.
* app/widgets/gimphelp-ids.h: added missing help IDs for the tool
options dialog.
2003-09-27 Michael Natterer <mitch@gimp.org>
* app/core/gimppaintinfo.[ch]: derive it from GimpViewable.
* app/core/gimptoolinfo.c (gimp_tool_info_new): set the
paint_info's stock_id from the tool_info's stock_id.
* app/widgets/widgets-types.h: resurrected GimpItemStrokeFunc.
* app/widgets/gimpvectorstreeview.[ch]: added a item_stroke_func
pointer and use it instead of implementing stroking here.
* app/gui/vectors-commands.[ch]: added vectors_stroke_vectors()
which has the signature of a GimpItemStrokeFunc.
* app/gui/dialogs-constructors.c: use it for the paths dialog.
* app/gui/stroke-dialog.[ch]: extended to handle both libart and
GimpPaintCore stroking. Use a GimpContainerMenu view on the
gimp->paint_info_list container to select the paint core to use.
2003-08-30 Michael Natterer <mitch@gimp.org>
Fixed & cleaned up paint function registration to work without
GUI. Finishes core/GUI separation for the paint tools:
* app/core/gimppaintinfo.[ch]: removed "gchar *pdb_string" all over
the place since we don't stroke using the PDB any more.
(gimp_paint_info_new): create paint_info->paint_options here so
the paint system is fully initialized when there is no GUI.
* app/paint/paint.c: removed pdb_string stuff here, too.
* app/core/gimptoolinfo.[ch]: create tool_info->tool_options
only if tool_info->tool_options_type is not the same type
as paint_info->paint_options_type (if we are no paint tool).
* app/core/gimptooloptions.c: removed G_PARAM_CONSTRUCT_ONLY from
the "tool-info" property. Instead, changed
gimp_tool_options_set_property to ensure that it is only set once.
* app/core/gimp.c (gimp_initialize): moved paint_init() after
data_factory creation (was in gimp_init()), since GimpPaintInfo
now creates the GimpPaintOptions, which are GimpContexts, which
need gimp->*_factory to be constructed.
* app/tools/tool_manager.c: don't create tool_info->tool_options
here (it's not the job of the tool_manager to set up the core
paint system correctly, it must be already initialized before any
tool_manager function is called).
Made "Stroke Selection" and "Stroke Path" work the same way:
* app/paint/gimppaintcore-stroke.[ch]: added new function
gimp_paint_core_stroke_boundary() which strokes without using
the PDB.
* app/core/gimpimage-mask.c (gimp_image_mask_stroke): use it
instead of using the PDB. Enables all available paint options for
stroke operations. Fixes bug #119411.
* app/gui/vectors-commands.c (vectors_stroke_vectors)
* app/core/gimpimage-mask.c (gimp_image_mask_stroke): removed all
code which tries to figure how to stroke and simply look at the
active tool's tool_info->paint_info, since it is always set up
correctly now.
2003-08-23 Michael Natterer <mitch@gimp.org>
* libgimpwidgets/gimpwidgetstypes.h: changed GimpHelpFunc typedef:
- renamed "const gchar *help_data" to "const gchar *help_id".
- added "gpointer help_data".
* libgimpwidgets/gimphelpui.[ch]: added "gpointer help_data" to
gimp_help_connect(). Removed all fiddling with html links and
treat all help IDs as opaque identifiers.
* app/core/gimptoolinfo.[ch]: changed "help_data" member to
"help_id".
* app/widgets/gimpitemfactory.[ch]: removed the "help_path"
parameter from gimp_item_factory_new() since we don't fiddle with
html file paths any more. Simplifies menu item help a lot.
Renamed "help_data" member of struct GimpItemFactoryEntry to
"help_id".
* app/gui/plug-in-menus.c: changed accordingly. 3rd party
plug-ins' menu item help IDs are now encoded as
"help_path:help_id".
* app/gui/file-open-menu.c
* app/gui/file-save-menu.c: when constructing the <Load> and
<Save> menus, take the resp. procedures' locale_domain and
help_path into account. Fixes translation of 3rd party menu items.
Also do the right thing for load/save procs which are implemented
as temporary procedures (they are impossible to implement
currently but it's nice to do the right thing anyway...).
* app/widgets/gimphelp-ids.h: added GIMP_HELP_MAIN identifier.
* libgimpwidgets/gimpdialog.[ch]
* libgimpwidgets/gimpwidgets.[ch]
* libgimp/gimpui.c
* app/display/gimpdisplayshell.c
* app/gui/gui.c
* app/gui/about-dialog.c
* app/gui/color-notebook.c
* app/gui/dialogs-constructors.c
* app/gui/file-dialog-utils.[ch]
* app/gui/gradients-commands.c
* app/gui/help-commands.c
* app/gui/image-menu.c
* app/gui/menus.c
* app/gui/preferences-dialog.c
* app/gui/tips-dialog.c
* app/tools/gimpcolorpickertool.c
* app/tools/gimpcroptool.c
* app/tools/gimpcurvestool.c
* app/tools/gimphistogramtool.c
* app/tools/gimpimagemaptool.c
* app/tools/gimplevelstool.c
* app/tools/gimpmeasuretool.c
* app/tools/gimptransformtool.c
* app/widgets/gimperrorconsole.c
* app/widgets/gimphelp.[ch]
* app/widgets/gimpmenufactory.[ch]
* app/widgets/gimptexteditor.c
* app/widgets/gimptoolbox.c
* app/widgets/gimpviewabledialog.[ch]
* plug-ins/common/CEL.c
* plug-ins/common/CML_explorer.c
* plug-ins/common/gee.c
* plug-ins/common/gee_zoom.c
* plug-ins/common/gqbist.c
* plug-ins/common/spheredesigner.c
* plug-ins/flame/flame.c
* plug-ins/fp/fp_gtk.c
* plug-ins/helpbrowser/helpbrowser.c
* plug-ins/ifscompose/ifscompose.c
* plug-ins/imagemap/imap_main.c: changed accordingly. Removed
trailing whitespace all over the place.
2003-06-28 Michael Natterer <mitch@gimp.org>
* app/core/gimpcontext.h: removed enum GimpContextPropType and
enum GimpContextPropMask.
* app/core/core-enums.[ch]: added them here.
* app/core/gimptoolinfo.[ch]: replaced "gboolean tool_context"
member by "GimpContextPropMask context_props" so each tool can
specify exactly which context properties it wants to have
persistently remembered.
* app/tools/tools-types.h: changed typedef GimpToolRegisterCallback
accordingly.
* app/tools/tool_manager.[ch] (tool_manager_register_tool): ditto.
Removed the "global_tool_context" and initialize all tool info
objects from the user_context after creation. Removed the
PAINT_OPTIONS_MASK #define and use the new context_props stored in
tool_info insted.
* app/tools/gimppainttool.h: #define the common properties of the
paint tools as GIMP_PAINT_TOOL_OPTIONS_MASK (which is OPACITY |
PAINT_MODE | BRUSH).
* app/tools/[all tools].c (gimp_*_tool_register): replaced the
"use_context" boolean by the actual mask of context properties the
tools need.
2003-06-06 Sven Neumann <sven@gimp.org>
* app/core/gimptoolinfo.[ch]: added "in_toolbox"; defaults to TRUE.
* app/tools/tool_manager.c: set "in_toolbox" to FALSE for tools
derived from GimpImageTool.
* app/widgets/gimptoolbox.c: respect the new flag when constructing
the toolbox.
2003-04-08 Michael Natterer <mitch@gimp.org>
* app/core/gimpviewable.[ch]: added vitrual function
GimpViewable::get_description() which returns the string that
should be presented to the user plus an optional tooltip with more
information. The default implementation just returns the object's
name and no tooltip.
* app/core/gimpbrush.c
* app/core/gimpbuffer.c
* app/core/gimpimage.c
* app/core/gimppalette.c
* app/core/gimppattern.c
* app/core/gimptoolinfo.c: implement get_description().
* app/core/gimpimagefile.[ch]: ditto. Renamed
gimp_imagefile_get_description() to
gimp_imagefile_get_desc_string(). Well, um, gimme a better name...
* app/gui/file-open-dialog.c: changed accordingly.
* app/file/file-utils.[ch]: renamed readXVThumb() to
file_utils_readXVThumb().
* tools/pdbgen/pdb/fileops.pdb: changed accordingly.
* app/widgets/widgets-types.h: removed GimpItemGetNameFunc typedef.
* app/widgets/gimpcontainerview-utils.[ch]: removed the the actual
get_name_funcs. They now live in the core as
GimpViewable::get_description() implementations.
* app/widgets/gimpcontainermenu.[ch]
* app/widgets/gimpcontainergridview.c
* app/widgets/gimpcontainermenuimpl.c
* app/widgets/gimpcontainertreeview.c
* app/widgets/gimpcontainerview.[ch]
* app/widgets/gimpmenuitem.[ch]
* app/widgets/gimpviewabledialog.c: removed get_name_func stuff
and use gimp_viewable_get_description().
* app/widgets/gimpcontainermenu.[ch]: added "preview_border_width"
to gimp_container_menu_set_preview_size().
* app/widgets/gimpimagedock.c: changed accordingly.
* app/pdb/fileops_cmds.c: regenerated.
2003-02-26 Sven Neumann <sven@gimp.org>
* app/core/gimpdata.[ch]: added a writeable field to GimpData and
set it from gimp_data_set_filename().
* app/gui/brushes-menu.c
* app/gui/gradients-menu.c
* app/gui/palettes-menu.c
* app/gui/patterns-menu.c
* app/widgets/gimpbrushfactoryview.c
* app/widgets/gimpdatafactoryview.c
* app/widgets/gimpgradienteditor.c: look at data->writeable when
setting widgets sensitivity.
* app/gui/user-install-dialog.c (user_install_dialog_create): reduce
some of the dialog clutter by not showing the directories created for
plug-ins.
* app/core/gimpviewable.[ch]: added a default_stock_id to
GimpViewableClass so we don't need to hold a copy in each instance.
Added accessor functions to set and get the stock_id.
* app/core/gimptoolinfo.c
* app/gui/dialogs-constructors.c
* app/gui/image-menu.c
* app/tools/gimpcroptool.c
* app/tools/gimphistogramtool.c
* app/tools/gimpimagemaptool.c
* app/tools/gimpmeasuretool.c
* app/tools/gimptransformtool.c
* app/widgets/gimpcellrendererviewable.c
* app/widgets/gimppreview.c
* app/widgets/gimptoolbox.c: use gimp_viewable_get_stock_id().
* app/text/gimptextlayer.c: set a text icon as default stock_id.
2003-02-25 Michael Natterer <mitch@gimp.org>
* app/core/gimpviewable.[ch]: added "gchar *stock_id" to the
GimpViewable struct. It is used by the GUI if the get_preview()
functions return NULL. Default to GTK_STOCK_DIALOG_QUESTION.
* app/core/gimptoolinfo.[ch]: set the tool's stock_id. Removed
the cached GdkPixbuf. Don't implement any preview function
so the GUI uses the stock_id.
* app/tools/tool_manager.c: removed GdkPixbuf creation, removed
the #warning about the buggy way we created the pixbuf.
* app/gui/dialogs-constructors.c
* app/gui/image-menu.c
* app/tools/gimpcroptool.c
* app/tools/gimphistogramtool.c
* app/tools/gimpimagemaptool.c
* app/tools/gimpmeasuretool.c
* app/tools/gimptransformtool.c
* app/widgets/gimptoolbox.c: use viewable->stock_id instead
of tool_info->stock_id.
* app/core/gimpbrush.c
* app/core/gimpgradient.c
* app/core/gimpimagefile.c
* app/core/gimpundo.c: simplified get_preview() implementations:
- never scale previews up, only down.
- don't render white or checks backgrounds but simply return
TempBufs with alpha and let the preview system do its job.
- don't add padding but simply return previews smaller than
requested.
* app/display/gimpdisplayshell-render.[ch]: added
"render_blend_white", a 2d lookup table for blending on white,
just as the check lookup tables. Added "render_white_buf".
* app/widgets/gimppreview.[ch]: changed a lot:
- don't render the preview's border into the buffer.
- added "GdkGC *border_gc" and draw the preview's border in expose()
using gdk_draw_rectangle().
- added "GdkPixbuf *no_preview_pixbuf" and create it in
gimp_preview_real_render() if gimp_viewable_get_preview()
returned NULL.
- factored the actual preview rendering out to
gimp_preview_render_to_buffer(). Added configurable background
rendering for the preview itself and it's padding area
(the area the preview is larger than the buffer returned
by gimp_viewable_get_preview()).
- changed gimp_preview_render_and_flush() to
gimp_preview_render_preview() and added "inside_bg" and
"outside_bg" parameters.
- use the new render buffers for blending on white.
* app/widgets/gimpbrushpreview.c
* app/widgets/gimpbufferpreview.c
* app/widgets/gimpdrawablepreview.c
* app/widgets/gimpgradientpreview.c
* app/widgets/gimpimagepreview.c
* app/widgets/gimppalettepreview.c
* app/widgets/gimppatternpreview.c: don't create large white
TempBufs to center the previews in but simply set the TempBuf's
offsets to get them centered. Simplified & cleaned up many preview
render functions. Pass the correct GimpPreviewBG modes to
gimp_preview_render_preview().
* app/widgets/gimpcellrendererviewable.[ch]: new GtkCellRenderer
class derived from GtkCellRendererPixbuf which knows how
to use gimp_viewable_get_preview_size() and renders the
viewable's stock item if no preview can be created.
* app/widgets/gimpcontainertreeview.c: added a GtkTreeCellDataFunc
which creates the preview pixbuf if needed so we don't create it
unconditionally upon item insertion. Fixed preview size assertion
to use GIMP_PREVIEW_MAX_SIZE, not "64". Block "selection_changed"
while reordering the selected item.
* app/widgets/gimpcontainerview.c: cosmetic.
* app/widgets/gimpimagefilepreview.[ch]
* app/widgets/gimptoolinfopreview.[ch]
* app/widgets/gimpundopreview.[ch]: removed because the default
implementation is good enough.
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimppreview-utils.c: changed accordingly.
* app/gui/dialogs-constructors.[ch]
* app/gui/dialogs-menu.c
* app/gui/dialogs.c
* app/gui/image-menu.c
* app/gui/toolbox-menu.c: register grid and tree view variants
of the document history.
Unrelated:
* app/gui/gui.c (gui_exit_finish_callback): disconnect from
signals earlier.
* app/gui/user-install-dialog.c: create the "tool-options" subdir
of the user's ~/.gimp-1.3 directory.
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-06-17 Michael Natterer <mitch@gimp.org>
Separated tool_options creation from tool registration so we
don't implicitly create widgets before gui_init():
* libgimptool/gimptooltypes.h: removed GimpToolOptionsNewFunc
typedef here...
* app/core/core-types.h: ...and added it here.
* libgimpproxy/gimpproxytypes.h: regenerated.
* app/core/gimptoolinfo.[ch]: added a GimpToolOptionsNewFunc
pointer to remember the constructor. Fixed the finalize() method
(bug was never noticed because we leaked all tool infos)
* app/tools/tool_manager.[ch]: moved tool_options creation to the
new function tool_manager_restore(). Unref the tool infos after
adding them to their container. Added "brush" and "gradient" to
the context properties which are defined for tool contexts.
* app/app_procs.c: call tool_manager_restore() after gui_init().
* app/gui/gui.c: removed the hack introduced recently and call
render_setup() in gui_init() again, not in gui_themes_init().
Use the correct contexts now that they are properly initialized
at the time of tool_options creation:
* app/tools/gimpblendtool.c: use tool_info->context, not
gimp_get_user_context() to get/set the tool's gradient.
* app/paint/gimppaintcore.[ch] (gimp_paint_core_start): added a
GimpPaintOptions paramater and get the brush to use from
paint_options->context (instead of gimp_get_current_context()).
* app/paint/gimppaintcore-stroke.c
* app/tools/gimppainttool.c: changed accordingly.
* app/tools/paint_options.c: added a brush preview to the paint
options.
2002-03-14 Michael Natterer <mitch@gimp.org>
* app/core/gimptoolinfo.c: g_strdup() the stock_id passed to
gimp_tool_info_new() because the caller's memory may disappear
after registering the tool (tool modules).
Made a GimpDock out of the toolbox:
* app/gui/Makefile.am
* app/gui/color-area.[ch]
* app/gui/indicator-area.[ch]
* app/gui/toolbox.[ch]: removed...
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/widgets/gimptoolbox-color-area.[ch]
* app/widgets/gimptoolbox-indicator-area.[ch]
* app/widgets/gimptoolbox.[ch]: ...and added here.
* app/widgets/gimpdock.[ch]: don't set a minimal width. Added a
"destroy_if_empty" boolean so we can prevent destruction of the
toolbox if it's last dockable is removed. Added gimp_dock_construct()
which is called from GimpImageDock and GimpToolbox.
* app/widgets/gimpimagedock.[ch]: Default to not showing the image
menu, set a minimal width here, misc. minor cleanup.
* app/widgets/gimpdockbook.c: some more GIMP_IS_IMAGE_DOCK()
checks, fixed dnd widget creation.
* app/widgets/gimpdialogfactory.[ch]: changed
gimp_dialog_factories_toggle() to take just the toolbox_factory as
parameter. When restoring the session use the created dock's
dialog factory to create dockables, not the the factory we
created the dock from (for the toolbox).
* app/display/gimpdisplayshell-callbacks.c: changed accordingly.
* app/gui/dialogs.[ch]: create an own dialog factory for the toolbox
and set dialogs_toolbox_new() as it's new_dock_func.
* app/gui/dialogs-constructors.[ch]: changed dialogs_toolbox_get()
accordingly.
* app/gui/dialogs-commands.[ch]: added dialogs_show_toolbox(), ckeck
if a dock is really a GimpImageDock before casting.
* app/gui/gui.c
* app/gui/menus.c
* app/widgets/gimppaletteeditor.c: changed accordingly.
* app/gui/color-notebook.c
* app/gui/color-select.c
* app/gui/colormap-dialog.c
* app/gui/palette-editor-commands.c: removed useless inclusion of
"gui/color-area.h".
* themes/Default/gtkrc: set "gimp-dock-style" for GimpToolbox widgets.
2002-03-02 Sven Neumann <sven@gimp.org>
* app/core/gimptoolinfo.c
* app/widgets/gimptoolinfopreview.c: allow RGB previews and do proper
blending for RGBA. This is wasted effort since we will change the
GimpPreview system anyway, but I couldn't stand the awful look any
longer.
* app/display/gimpdisplayshell.c
* app/gui/file-save-dialog.c: added linebreaks to messages.
2002-02-27 Michael Natterer <mitch@gimp.org>
* app/core/Makefile.am
* app/core/gimppaintinfo.[ch]: new object for registering
GimpPaintCore subclasses, just like GimpToolInfo for tools.
* app/core/gimp.h: added gimp->paint_info_list to hold them.
* app/core/gimptoolinfo.[ch]: removed the "pdb_string" and
"paint_core_name" pointers and added a GimpPaintInfo pointer
instead.
* app/core/gimpimage-mask.c
* app/gui/vectors-commands.c
* app/tools/gimpbezierselecttool.c
* app/tools/tool_manager.c: changed accordingly.
* app/paint/paint-types.h
* app/paint/paint.c: added paint class registration stuff like
the tool_manager does.
* app/paint/gimpairbrush.[ch]
* app/paint/gimpclone.[ch]
* app/paint/gimpconvolve.[ch]
* app/paint/gimpdodgeburn.[ch]
* app/paint/gimperaser.[ch]
* app/paint/gimppaintbrush.[ch]
* app/paint/gimppencil.[ch]
* app/paint/gimpsmudge.[ch]: added register functions which are
called from paint_init().
The core object system lives not only in "core/", but in
core, paint, vectors, file, plug-in and xcf, so I had to hack
a bit to keep the deps working:
* app/pdb/pdb-types.h: don't include "paint/paint-types.h"...
* app/core/core-types.h: ...because it's included here. Moved
the inclusions of the core's subsystems' "foo/foo-types.h"
files to the end of the file.
* app/paint/Makefile.am: Some slimy radioactive uglyness.
* app/gui/drawable-commands.c
* app/tools/gimpblendtool.c: removed calling core functions via
the PDB because it makes no sense to do it manually in only a few
places. This needs to be done generically using generated
wrappers living in "app/commands/" or something...
2002-02-26 Michael Natterer <mitch@gimp.org>
Added some kind of paint core registry. It's ugly and will change...
* app/core/gimp.c: call paint_init() and paint_exit().
* app/core/gimptoolinfo.[ch]: added "gchar *paint_core_name" to
the GimpToolInfo structure and the contstructor.
* app/tools/tool_manager.c: pass the class names of the
GimpPaintCore subclasses to gimp_tool_info_new().
* app/paint/Makefile.am
* app/paint/paint.[ch]: new files. Simlply ref/unref all paint
core classes so we can find them using g_type_from_name().
* app/paint/gimppaintcore-stroke.[ch]: changed to take an array
of GimpCoords, not just gdouble.
* tools/pdbgen/pdb/paint_tools.pdb: convert the stroke array here.
* app/gui/vectors-commands.c: ad-hoc implementation of vectors
stroking. Double click now sets the active vectors in the vectors
tool.
* app/pdb/paint_tools_cmds.c: regenerated.
2001-12-07 Michael Natterer <mitch@gimp.org>
* app/Makefile.am
* app/devices.[ch]: removed, chopped...
* app/widgets/Makefile.am
* app/widgets/widgets-types.h
* app/gui/Makefile.am
* app/widgets/gimpdeviceinfo.[ch]
* app/widgets/gimpdevices.[ch]
* app/gui/device-status-dialog.[ch]
* app/gui/input-dialog.[ch]: ...and added here.
Made GimpToolInfo a GimpContext subclass. Create a GimpDeviceManager
struct in gimpdevices.c and attach it to the Gimp instance.
* app/core/gimp.[ch]: removed gimp_create_context(). It was a bad
idea in the first place beause it prevented GimpContext subclasses
from being be properly registered with their Gimp instance.
* app/core/gimpcontext.c: moved the stuff which used to be in
gimp_create_context() back here. Added a "gimp" property which
must be set on construction. Added a "dispose" implementation
which removes the context from it's Gimp's context_list.
* app/gimprc.c
* app/core/gimptoolinfo.[ch]
* app/display/gimpdisplayshell-callbacks.c
* app/gui/brush-select.c
* app/gui/dialogs-constructors.c
* app/gui/gradient-editor.c
* app/gui/gradient-select.c
* app/gui/gui.c
* app/gui/menus.c
* app/gui/palette-editor.c
* app/gui/palette-select.c
* app/gui/pattern-select.c
* app/gui/toolbox.c
* app/tools/gimppainttool.c
* app/tools/tool_manager.c
* app/widgets/gimpimagedock.c: changed accordingly.
* app/gui/tools-commands.[ch]: made all callback signatures
the same.
* app/gui/preferences-dialog.c: cleaned up the
display_format_string GtkCombo code.