summaryrefslogtreecommitdiff
path: root/gdk-pixbuf/io-bmp.c
Commit message (Collapse)AuthorAgeFilesLines
* Remove unnecessary NULL checks before g_free(). (#369666, Morten Welinder,Matthias Clasen2007-03-091-2/+1
| | | | | | | | | | | | | 2007-03-09 Matthias Clasen <mclasen@redhat.com> * Everywhere: Remove unnecessary NULL checks before g_free(). (#369666, Morten Welinder, Djihed Afifi) * configure.in: Check for ftw.h svn path=/trunk/; revision=17444
* Fix a compiler warningMatthias Clasen2007-01-041-1/+1
| | | | svn path=/trunk/; revision=17061
* Handle bmps with more than 8 bits per channel. (#172584, David Costanzo)Matthias Clasen2006-12-221-0/+17
| | | | | | | | 2006-12-22 Matthias Clasen <mclasen@redhat.com> * io-bmp.c (decode_bitmasks): Handle bmps with more than 8 bits per channel. (#172584, David Costanzo)
* Handle offsets more carefully. (#172188, David Costanzo)Matthias Clasen2006-12-221-19/+106
| | | | | | | | | | | 2006-12-22 Matthias Clasen <mclasen@redhat.com> * io-bmp.c: Handle offsets more carefully. (#172188, David Costanzo) * io-bmp.c: Handle v5 and OS/2 v2 bmps. * io-bmp.c: Handle alpha masks in v4 and v5 bmps.
* Enable having some gdk-pixbuf loaders built-in even if loading the othersTor Lillqvist2006-10-111-0/+6
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2006-10-11 Tor Lillqvist <tml@novell.com> * configure.in: Enable having some gdk-pixbuf loaders built-in even if loading the others dynamically. Define Automake conditional INCLUDE_FOO for each loader as TRUE if that loader is built-in. See also gdk-pixbuf/ChangeLog. 2006-10-11 Tor Lillqvist <tml@novell.com> Enable having some loaders built-in even if loading the others dynamically. Have loaders in the same order as in configure.in in all places where they are handled/listed. * Makefile.am: Define the STATIC_FOO_LIB and FOO_LIB macros conditionally depending on whether said loader is built-in or not. Use the names libstatic-pixbufloader-foo.la instead of libpixbufloader-static-foo.la for the built-in ones so that the "echo libpixbufloader-*.la" won't match them. * gdk-pixbuf-io.c: Reorganize code as to plumb the built-in loaders also if USE_GMODULE. Don't warn about a missing gdk-pixbuf.loaders file if we have at least one included loader. * gdk-pixbuf-private.h * io-*.c: Don't define a generic MODULE_ENTRY, as we can't use it in the loaders anyway. Each loader needs to check if INCLUDE_foo is defined.
* Accept the 108 byte header of BMP v4. (#168799)Matthias Clasen2005-05-271-1/+6
| | | | | | 2005-05-27 Matthias Clasen <mclasen@redhat.com> * io-bmp.c: Accept the 108 byte header of BMP v4. (#168799)
* Don't display too many broken images. (#169870, Roman Kagan, patch by IvanMatthias Clasen2005-04-091-1/+1
| | | | | | | | | | | | | | 2005-04-09 Matthias Clasen <mclasen@redhat.com> * gtk/gtkimage.c (gtk_image_calc_size, gtk_image_expose): Don't display too many broken images. (#169870, Roman Kagan, patch by Ivan Wong) * gtk/gtkwidget.c (gtk_widget_unparent): Remove debugging output. (#300013, Tommi Komulainen) * io-bmp.c (gdk_pixbuf__bmp_image_save_to_callback): Don't overflow the stack. (Jakub Jelinek, Arjan van de Ven)
* Initialize the colormap to zero. (#171762, David Costanzo)Matthias Clasen2005-04-071-1/+1
| | | | | | | 2005-04-07 Matthias Clasen <mclasen@redhat.com> * io-bmp.c (DecodeColormap): Initialize the colormap to zero. (#171762, David Costanzo)
* Avoid bus errors due to unaligned access. (#168173, Morten Welinder, IvanMatthias Clasen2005-03-301-12/+16
| | | | | | | 2005-03-30 Matthias Clasen <mclasen@redhat.com> * io-bmp.c: Avoid bus errors due to unaligned access. (#168173, Morten Welinder, Ivan Wong)
* Use the correct update regions for compressed bmps. (#150664, Owen Taylor,Matthias Clasen2005-03-281-1/+1
| | | | | | | | 2005-03-27 Matthias Clasen <mclasen@redhat.com> * io-bmp.c (DoCompressed): Use the correct update regions for compressed bmps. (#150664, Owen Taylor, test images provided by David Costanzo)
* reject 0-sized buffers as corrupt header data. Fixes bug #171707.Manish Singh2005-03-281-1/+14
| | | | | | | Sun Mar 27 19:59:52 2005 Manish Singh <yosh@gimp.org> * io-bmp.c (grow_buffer): reject 0-sized buffers as corrupt header data. Fixes bug #171707.
* Document BMP saving support.Matthias Clasen2005-02-241-1/+118
| | | | | | | | 2005-02-23 Matthias Clasen <mclasen@redhat.com> * gdk-pixbuf-io.c: Document BMP saving support. * io-bmp.c: Support saving as BMP. (168173, Ivan Wong)
* Some moreMatthias Clasen2005-01-041-3/+1
|
* Remove leftover debug printfMatthias Clasen2005-01-041-5/+0
|
* Error on compressed images with negative height. Also make uncompressedMatthias Clasen2005-01-041-8/+37
| | | | | | | | 2005-01-04 Matthias Clasen <mclasen@redhat.com> * io-bmp.c (DecodeHeader): Error on compressed images with negative height. Also make uncompressed images with data_offset != header_size work. (#150664, Owen Taylor)
* Changes to make gdk-pixbuf threadsafe (#157310, #157306, Colin Walters):Matthias Clasen2004-11-121-1/+1
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2004-11-12 Matthias Clasen <mclasen@redhat.com> Changes to make gdk-pixbuf threadsafe (#157310, #157306, Colin Walters): * gdk-pixbuf-io.h (enum GdkPixbufFormatFlags): Add GDK_PIXBUF_FORMAT_THREADSAFE to indicate that an image loader is threadsafe. * gdk-pixbuf-io.c (get_file_formats, _gdk_pixbuf_load_module): Use a lock to make initialization of global data structures threadsafe. * gdk-pixbuf-private.h: * gdk-pixbuf-io.c (_gdk_pixbuf_lock, _gdk_pixbuf_unlock): Auxiliary functions which use another lock to protect threadunsafe image loaders. * gdk-pixbuf-io.c (gdk_pixbuf_real_save): (save_to_callback_with_tmp_file): (gdk_pixbuf_real_save_to_callback): (gdk_pixbuf_new_from_xpm_data): (_gdk_pixbuf_generic_image_load): * gdk-pixbuf-animation.c (gdk_pixbuf_animation_new_from_file): * gdk-pixbuf-loader.c (gdk_pixbuf_loader_load_module): (gdk_pixbuf_loader_close): (gdk_pixbuf_loader_finalize): Use _gdk_pixbuf_lock() and _gdk_pixbuf_unlock(). * io-ani.c, io-bmp.c, io-gif.c, io-ico.c: * io-jpeg.c, io-pcx.c, io-png.c, io-pnm.c: * io-ras.c, io-tga.c, io-wbmp.c, io-xbm.c: * io-xpm.c: Mark as threadsafe. * io-tiff.c: Remove pointless locking, mark as threadunsafe.
* Fix infinite loop that can occur for bad image data (#150601, Chris Evans,Owen Taylor2004-08-201-1/+11
| | | | | | | Fri Aug 20 11:59:10 2004 Owen Taylor <otaylor@redhat.com> * io-bmp.c: Fix infinite loop that can occur for bad image data (#150601, Chris Evans, Manish Singh)
* Properly determine the number of colors in an OS/2 BMP file. (#150003,Matthias Clasen2004-08-131-1/+5
| | | | | | | Thu Aug 12 22:19:12 2004 Matthias Clasen <maclas@gmx.de> * io-bmp.c (DecodeHeader): Properly determine the number of colors in an OS/2 BMP file. (#150003, Jon-Kare Hellan)
* New functions to disable/enable individual loaders and to obtain licenseMatthias Clasen2004-07-081-0/+1
| | | | | | | | | | | | | | | | | | | | | Wed Jul 7 23:53:58 2004 Matthias Clasen <maclas@gmx.de> * gdk-pixbuf-io.h: * gdk-pixbuf-io.c (gdk_pixbuf_format_is_disabled): * gdk-pixbuf-io.c (gdk_pixbuf_format_set_disabled): * gdk-pixbuf-io.c (gdk_pixbuf_format_get_license): New functions to disable/enable individual loaders and to obtain license information about loaders. * gdk-pixbuf-io.h (GdkPixbufFormat): Add disabled and license fields. * gdk-pixbuf-io.c (_gdk_pixbuf_get_module): * gdk-pixbuf-io.c (_gdk_pixbuf_get_named_module): Skip disabled loaders. * io-*.c: Add license information in the fill_info functions.
* Don't try to load an alpha channel from the BMP, since there is noMatthias Clasen2004-03-051-2/+2
| | | | | | | | Fri Mar 5 22:22:25 2004 Matthias Clasen <maclas@gmx.de> * io-bmp.c (OneLine32): Don't try to load an alpha channel from the BMP, since there is no evidence that even 32bit BMPs have an alpha channel. (#135502)
* Remove debugging code.Matthias Clasen2004-02-221-3/+0
|
* Store and sanity-check the clrUsed field from the header for use inMatthias Clasen2004-02-201-12/+41
| | | | | | | | | Fri Feb 20 22:25:32 2004 Matthias Clasen <maclas@gmx.de> * io-bmp.c (DecodeHeader): Store and sanity-check the clrUsed field from the header for use in DecodeColormap. * io-bmp.c (DecodeColormap): Don't read more colormap entries than the header says are there. (#134235, Kazuho Okui)
* Make it possible to call gdk_pixbuf_loader_set_size (loader, 0, 0) byMatthias Clasen2004-01-071-23/+39
| | | | | | | | | | | | | | | | | | | | | | | | | | | Wed Jan 7 01:17:36 2004 Matthias Clasen <maclas@gmx.de> * gdk-pixbuf-loader.c (gdk_pixbuf_loader_size_func): * gdk-pixbuf-loader.c (gdk_pixbuf_loader_set_size): * gdk-pixbuf-loader.c (gdk_pixbuf_loader_init): Make it possible to call gdk_pixbuf_loader_set_size (loader, 0, 0) by changing the initial values of priv->width/height to -1. * io-tiff.c (tiff_image_parse): * io-ras.c (RAS2State): * io-pnm.c (gdk_pixbuf__pnm_image_load_increment): * io-pcx.c (gdk_pixbuf__pcx_load_increment): * io-jpeg.c (gdk_pixbuf__jpeg_image_load_increment): * io-png.c (png_info_callback): * io-ico.c (DecodeHeader): * io-bmp.c (DecodeHeader): Call size_func once the size is known, even if the module can't make use of the scaling information. If size_func returns 0, don't allocate a pixbuf and return, if necessary with an error. * gdk-pixbuf.h: * gdk-pixbuf-io.c (gdk_pixbuf_get_file_info): A new function to determine the type and size of an image file without loading it completely. (#53725)
* Support for separately installed loaders. (#77486)Matthias Clasen2002-10-031-12/+40
| | | | | | | | | | | | | | | | | * Makefile.am gdk-pixbuf-animation.c gdk-pixbuf-data.c gdk-pixbuf-io.c gdk-pixbuf-io.h gdk-pixbuf-loader.c gdk-pixbuf-loader.h gdk-pixbuf-private.h gdk-pixbuf.h gdk-pixdata.c io-ani-animation.h io-ani.c io-bmp.c io-gif-animation.c io-gif-animation.h io-gif.c io-ico.c io-jpeg.c io-png.c io-pnm.c io-ras.c io-tga.c io-tiff.c io-wbmp.c io-xbm.c io-xpm.c pixbufloader_ani.def pixbufloader_bmp.def pixbufloader_gif.def pixbufloader_ico.def pixbufloader_jpeg.def pixbufloader_png.def pixbufloader_pnm.def pixbufloader_ras.def pixbufloader_tga.def pixbufloader_tiff.def pixbufloader_wbmp.def pixbufloader_xbm.def pixbufloader_xpm.def test-gdk-pixbuf.c gdk-pixbuf-animation.h queryloaders.c: Support for separately installed loaders. (#77486)
* Fix the update region notification to handle top-to-bottom andFederico Mena Quintero2002-09-271-2/+4
| | | | | | | 2002-09-27 Federico Mena Quintero <federico@ximian.com> * io-bmp.c (OneLine): Fix the update region notification to handle top-to-bottom and bottom-to-top BMPs correctly.
* Don't leak memory if g_try_realloc fails.Matthias Clasen2002-09-031-2/+3
| | | | | | | | | * io-tga.c (io_buffer_append): * io-ico.c (DecodeHeader): * io-bmp.c (grow_buffer): Don't leak memory if g_try_realloc fails. * gdk-pixbuf-io.c (pixbuf_check_ico): Fix loading of .CUR files. (#91826)
* New function for loading an image from a file either via module->load orMatthias Clasen2002-07-071-40/+0
| | | | | | | | | * gdk-pixbuf-io.c (generic_image_load): New function for loading an image from a file either via module->load or incrementally. (prepared_notify): ModulePreparedNotifyFunc for generic_image_load. (gdk_pixbuf_new_from_file): Use generic_image_load. * io-bmp.c, io-ico.c, io-ras.c, io-wbmp.c: Remove trivial implementations of module->load. (#71266)
* Load-at-size functionality for gdk-pixbuf.Matthias Clasen2002-07-061-3/+5
|
* Miscellaneous bmp loader fixes (#85448, #86286, #86287):Matthias Clasen2002-07-021-162/+212
| | | | | | | | | | | | * io-bmp.c (grow_buffer): New function to avoid crashes on unchecked reallocs. (DecodeHeader, DecodeColormap, decode_bitmasks, DoCompressed): Use grow_buffer instead of g_realloc throughout. Change signatures where necessary to pass the errors up. (OneLine16): Fix loading of 16bpp BI_RGB bmps. (DoCompressed): Rewritten to properly support BI_RLE4 and skips and jumps.
* New functions to fetch 32 or 16-bit little-endian values starting at aFederico Mena Quintero2002-06-101-11/+28
| | | | | | | | | | | 2002-06-07 Federico Mena Quintero <federico@ximian.com> * io-bmp.c (lsb_32): (lsb_16): New functions to fetch 32 or 16-bit little-endian values starting at a specific memory location. We do this instead of GINT32_FROM_LE() as the latter is simply dereferences a cast, which doesn't work on platforms with alignment requirements. Fixes #84083.
* Replace a g_assert_not_reached () which could actually be reached by aMatthias Clasen2002-03-121-2/+8
| | | | | * io-bmp.c (DecodeHeader): Replace a g_assert_not_reached () which could actually be reached by a proper error status return.
* Fix docs.Matthias Clasen2002-03-051-1/+9
| | | | | | | | | | | | | | | | | * gtk/gtktreemodel.c (gtk_tree_row_reference_deleted): Fix docs. * gtk/gtkwindow.c (gtk_window_remove_mnemonic): (gtk_window_add_mnemonic): (gtk_window_mnemonic_activate): Add docs. * gtk/gtktreeview.c (gtk_tree_view_get_search_equal_func): Fix typo in docs. * test-loaders.c, test-images.h: More random tests. * io-bmp.c (DecodeHeader): Fail gracefully on OOM here. * gtk/gtk-sections.txt: Remove gtk_win32_get_installation_directory.
* Remove assorted G_OBJECT casts where unnecessary.Sebastian Wilhelmi2001-12-131-2/+2
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-12-13 Sebastian Wilhelmi <wilhelmi@ira.uka.de> * gdk-pixbuf-animation.c, gdk-pixbuf-loader.c, gdk-pixpuf.c, io-gif-animation.c, io-gif.c, io-tiff.c, test-loaders.c: Remove assorted G_OBJECT casts where unnecessary. * gdk-pixbuf-loader.c: Call g_object_ref and g_object_unref instead of gdk_pixbuf_animation_ref and gdk_pixbuf_animation_unref resp. * gdk-pixbuf-csource.c, io-bmp.c, io-gif-animation.c, io-ico.c, io-jpeg.c, io-png.c, io-pnm.c, io-ras.c, io-tga.c, io-wbmp.c, io-xbm.c, io-xpm.c, test-gdk-pixbuf.c: Dito for gdk_pixbuf_ref and gdk_pixbuf_unref. * Makefile.am, pixops/Makefile.am: Compile everything with -DG_DISABLE_DEPRECATED -DGDK_PIXBUF_DISABLE_DEPRECATED * gdk-pixdata.c: Use g_ascii_strup() instead of g_strup(). * io-xpm.c: Use g_ascii_strcasecmp() instead of g_strcasecmp(). * demos/testpixbuf-drawable.c, demos/testpixbuf-save.c, demos/testpixbuf-scale.c, demos/testpixbuf.c: Call g_object_ref and g_object_unref instead of gdk_pixbuf_ref and gdk_pixbuf_unref resp.
* Fill in missing error parameters to DecodeHeader and DecodeColormap.Manish Singh2001-11-291-3/+5
| | | | | | | 2001-11-28 Manish Singh <yosh@gimp.org> * gdk-pixbuf/io-bmp.c (gdk_pixbuf__bmp_image_load_increment): Fill in missing error parameters to DecodeHeader and DecodeColormap.
* Fix Ximian bug #12125; merged from gdk-pixbuf stable.Federico Mena Quintero2001-11-291-100/+266
| | | | | | | | | | | | | | | 2001-11-21 Federico Mena Quintero <federico@ximian.com> Fix Ximian bug #12125; merged from gdk-pixbuf stable. * gdk-pixbuf/io-bmp.c (gdk_pixbuf__bmp_image_load_increment): Use a simple state machine instead of a scary if/else chain. (DecodeHeader): Set the reading state. (DecodeColormap): Set the reading state. (decode_bitmasks): New function, decodes the bitmasks for BI_BITFIELDS coding. (OneLine32): Handle BI_BITFIELDS coding. (OneLine16): Likewise.
* io-bmp.c (OneLine): Emit area_updated signal with properMatthias Clasen2001-08-281-1/+1
| | | | area information. (#52002)
* Patch from Helmethead <hoshem@mel.comcen.com.au> to fix up bmp decoder to:Jonathan Blandford2001-05-281-259/+303
| | | | | | | | | | | | Mon May 28 14:21:35 2001 Jonathan Blandford <jrb@redhat.com> * io-bmp.c: Patch from Helmethead <hoshem@mel.comcen.com.au> to fix up bmp decoder to: - adds 16 bpp bmp support (bug #53884) - adds OS/2 1.x format bmp support (bug #54964) - adds 4 bpp RLE compressed bmp support - adds 1 bpp colormap support - fixes negative height (top down) bmp support.
* fix some shell typosHavoc Pennington2001-05-071-8/+4
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-05-04 Havoc Pennington <hp@redhat.com> * configure.in: fix some shell typos * gtk/gtkcolorsel.c (gtk_color_selection_destroy): warning fix * gtk/gtkimage.c: handle animations * gtk/gtkcheckbutton.c (gtk_check_button_size_request): request border_width * 2, not just border_width * gtk/gtkscale.c: add "format_value" signal to allow people to override the way values are drawn. (gtk_scale_get_value_size): fix width/height mistake, and compute size from actual displayed text, not from made-up text. * gtk/gtktexttag.c (gtk_text_tag_class_init): fix return type in signal registration * tests/testtext.c: Add "Remove all tags" menu item for testing * gtk/gtktextbuffer.c (gtk_text_buffer_remove_all_tags): implement * demos/gtk-demo/main.c (main): add hack so we can find modules without installing gtk * demos/gtk-demo/textview.c (insert_text): demo font scaling * gtk/gtkcellrenderertext.c: Add "scale" property (font scaling factor) (gtk_cell_renderer_text_set_property): remove some bogus g_object_notify * gtk/gtktexttag.c: add "scale" property which is a font scaling factor * gtk/gtktextlayout.c (add_text_attrs): add font scale attribute to layout * gtk/gtktextiter.c (gtk_text_iter_is_start): rename from gtk_text_iter_is_first 2001-05-04 Havoc Pennington <hp@redhat.com> * pixops/pixops.c (pixops_process): merge fix from stable: Patch from hoshem@mel.comcen.com.au to fix nonzero X offsets. Fixes bug #50371. * gdk-pixbuf/pixops/pixops.c (pixops_composite_nearest): merge from stable: Patch from OKADA Mitsuru <m-okada@fjb.co.jp> to fix confusion of using "src" instead of "p". (pixops_composite_color_nearest): Use a more accurate (and correct, to begin with) compositing method. This cures checks showing through on images with no alpha. * gdk-pixbuf.c (gdk_pixbuf_fill): fix bug that left some trailing bytes unfilled. * gdk-pixbuf-io.h: fix UpdatedNotifyFunc to use signed ints * gdk-pixbuf-loader.h (struct _GdkPixbufLoaderClass): Change area_updated signal to use signed ints. Removed animation-related signals. * io-gif.c, io-gif-animation.h, io-gif-animation.c: Massive rewrite action * gdk-pixbuf-animation.c: Add GdkPixbufAnimationIter to abstract all the pesky details. Remove old frame-based API. Make GdkPixbufAnimation an abstract base class, derived by the loaders.
* Add built marshaller files to support GdkPixbufLoader signalsHavoc Pennington2001-01-221-24/+54
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2001-01-22 Havoc Pennington <hp@redhat.com> * Makefile.am: Add built marshaller files to support GdkPixbufLoader signals * gdk-pixbuf-io.c (gdk_pixbuf_load_module): have GDK_PIXBUF_MODULEDIR unconditionally replace the compiled-in module location, rather than acting as a fallback, because we are using GDK_PIXBUF_MODULEDIR to use gdk-pixbuf before installing it. * gdk-pixbuf.h: include gdk-pixbuf-loader.h * gdk-pixbuf-loader.h, gdk-pixbuf-loader.c: Move back over here from gtk, and add error to close(), because stop_load may do parsing of the image. * pixops/have_mmx.S (_pixops_have_mmx): add newline at end of file * io-*.c: make individual operations static, and add fill_vtable functions which are exported. Fix the collection of type warnings that surfaced, including a number of functions that didn't properly take a GError and some that weren't const-correct. Involved adding error handling for a few loaders. * gdk-pixbuf-io.h: Add error reporting to stop_load function * gdk-pixbuf-io.c (gdk_pixbuf_load_module): change to just look up a function that fills in the GdkPixbufModule vtable, instead of looking up all the image functions individually; this means we can get type safety within modules for the loader functions. Also it means you don't have to keep the statically compiled and GModule versions in sync. * test-gdk-pixbuf.c (main): remove gdk_pixbuf_init() * make-inline-pixbuf.c (main): remove call to gdk_pixbuf_init() * gdk-pixbuf.h: nuke gdk_pixbuf_init() * gdk-pixbuf-animation.c (gdk_pixbuf_frame_get_type): g_type_init () here * gdk-pixbuf.c (gdk_pixbuf_get_type): g_type_init () here * gdk-pixbuf-animation.c (gdk_pixbuf_animation_get_type): g_type_init() here 2001-01-22 Havoc Pennington <hp@redhat.com> * demos/testanimation.c: fix to reflect gdk-pixbuf changes * demos/testpixbuf.c: fix to reflect gdk-pixbuf changes * gtk/gdk-pixbuf-loader.c, gtk/gdk-pixbuf-loader.h: Remove, move back to gdk-pixbuf * gtk/gtktextiter.c, gtk/gtktextiter.h: add sentence equivalents to all the word functions * gtk/gtktextview.c (gtk_text_view_start_cursor_blink): return before doing anything on NULL layout or if we don't have the focus * gtk/testtext.c (fill_example_buffer): "justification" * gtk/gtktexttag.h, gtk/gtktexttag.c: change the tag attribute to be called "justification" not "justify" * demos/gtk-demo/textview.c (create_tags): "justification" * gtk/gtktextlayout.c (set_para_values): Handle char-wise wrapping
* Some updatesHavoc Pennington2000-10-181-11/+23
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-10-18 Havoc Pennington <hp@redhat.com> * gtk/gtk-sections.txt: Some updates * gdk/gdk-sections.txt: remove GdkPixbufAlphaMode * gdk-pixbuf/gdk-pixbuf-sections.txt: Add new API, remove GdkPixbufClass/GdkAnimationClass since those are private * gdk-pixbuf/Makefile.am (IGNORE_HFILES): ignore more headers 2000-10-18 Havoc Pennington <hp@redhat.com> * gtk/gtktextiter.c (gtk_text_iter_forward_to_newline): Fix a bug where any number of empty lines would get skipped * gtk/gtktextiter.h: Remove padding from GtkTextIter; live on the edge. * gtk/gtktextiter.c (gtk_text_iter_make_surreal): enhance the warning about invalid iterators (explain more thoroughly) (gtk_text_iter_in_region): rename gtk_text_iter_in_range * gtk/gtktextview.c (FOCUS_EDGE_WIDTH): Make focus rectangle less big * demos/*.c: Add error handling * gtk/gtktextbuffer.c: don't modify const iterators * gtk/gdk-pixbuf-loader.c: Add full error handling here * gtk/gtkimage.c (gtk_image_set_from_file): ignore errors on file load * gtk/gtkiconfactory.c: Update to reflect addition of error handling to gdk-pixbuf loaders 2000-10-16 Havoc Pennington <hp@redhat.com> * gdk-pixbuf-io.c (gdk_pixbuf_get_module) (gdk_pixbuf_get_named_module) (gdk_pixbuf_load_module): add error reporting here also * make-inline-pixbuf.c (main): use GError * io-xpm.c: include unistd.h * gdk-pixbuf-util.c: include string.h * io-*.c: add error reporting * gdk-pixbuf-animation.c (gdk_pixbuf_animation_new_from_file): add error reporting * gdk-pixbuf-io.c (gdk_pixbuf_new_from_file): Add error reporting * gdk-pixbuf-io.h: Add GError** to load_increment and load methods * gdk-pixbuf-io.c (gdk_pixbuf_save) (gdk_pixbuf_savev): return a G_FILE_ERROR if we fail to write or close the file. * gdk-pixbuf.h: remove GDK_PIXBUF_ERROR_IO, instead we'll use G_FILE_ERROR_*. Rename enum to GdkPixbufError, properly following the GError naming rules. Add GError** to load functions.
* Check for <unistd.h>.Tor Lillqvist2000-08-011-0/+2
| | | | | | | | | | | | | | | | | 2000-08-02 Tor Lillqvist <tml@iki.fi> * configure.in: Check for <unistd.h>. 2000-08-02 Tor Lillqvist <tml@iki.fi> * io-bmp.c * io-ico.c * io-ras.c * io-tiff.c * io-wbmp.c: Conditionalise inclusion of <unistd.h>. * makefile.mingw.in: List loaders alphabetically. Add the wbmp one. Fix names of DLLs to have '-' instead of '_'.
* Add gdk_pixbuf_loader_new_with_type function, to allow handling imageElliot Lee2000-07-281-7/+1
| | | | | | | | | | | | | | | | | 2000-07-27 Elliot Lee <sopwith@redhat.com> * gtk/gdk-pixbuf-loader.[ch]: Add gdk_pixbuf_loader_new_with_type function, to allow handling image formats that cannot be detected by looking at content alone. gdk-pixbuf/ 2000-07-27 Elliot Lee <sopwith@redhat.com> * gdk-pixbuf-io.h, gdk-pixbuf-io.c: Add gdk_pixbuf_get_named_module() function to facilitate above change * io-bmp.c: Don't malloc a temporary buffer - use stack instead. * io-wbmp.c, pixbufloader_wbmp.defs, gdk-pixbuf-io.c, Makefile: Implement loader for WBMP format. **NOTE: I haven't tested this yet, I need to sync it to another machine, but it if it is broken I'm already working on fixing it
* applied patch from Andreas Persenius <ndap@swipnet.se> that updates theTim Janik2000-07-261-3/+3
| | | | | | | | Wed Jul 26 12:59:31 2000 Tim Janik <timj@gtk.org> * *.[hc]: applied patch from Andreas Persenius <ndap@swipnet.se> that updates the license headers to the GNU Lesser General Public License, as well as updating the copyright year to 2000.
* Most of this patch is based on a patch by Havoc Pennington (hp@redhat.com)Federico Mena Quintero2000-04-111-42/+35
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 2000-04-11 Federico Mena Quintero <federico@helixcode.com> Most of this patch is based on a patch by Havoc Pennington (hp@redhat.com) to make GdkPixbuf's structures opaque and to remove the libart dependency. * gdk-pixbuf/gdk-pixbuf.h: Removed the public structures. (GdkColorspace): New enum that for now only contains GDK_COLORSPACE_RGB. (GdkPixbufDestroyNotify): New type for the pixbuf's pixels destroy notification function. (GdkInterpType): New num with interpolation types. * *.[ch]: Replace the libart stuff with our own stuff. * pixops/*.[ch]: Likewise. * gdk-pixbuf/gdk-pixbuf-private.h: New file with the private declarations of the GdkPixbuf structures. * gdk-pixbuf/gdk-pixbuf.c (gdk_pixbuf_new_from_art_pixbuf): Removed function. (gdk_pixbuf_get_format): Constify. (gdk_pixbuf_get_n_channels): Constify. (gdk_pixbuf_get_has_alpha): Constify. (gdk_pixbuf_get_bits_per_sample): Constify. (gdk_pixbuf_get_pixels): Constify. (gdk_pixbuf_get_width): Constify. (gdk_pixbuf_get_height): Constify. (gdk_pixbuf_get_rowstride): Constify. * gdk-pixbuf/gdk-pixbuf.c (gdk_pixbuf_copy): New function to copy a pixbuf. * gdk-pixbuf/gdk-pixbuf-data.c (gdk_pixbuf_new_from_data): Added a bits_per_sample argument; currently only 8 bits per sample are supported. * gdk-pixbuf/gdk-pixbuf-animation.c (gdk_pixbuf_frame_get_pixbuf): New accessor. (gdk_pixbuf_frame_get_x_offset): New accessor. (gdk_pixbuf_frame_get_y_offset): New accessor. (gdk_pixbuf_frame_get_delay_time): New accessor. (gdk_pixbuf_frame_get_action): New accessor. * gdk-pixbuf/gdk-pixbuf-render.c (gdk_pixbuf_render_pixmap_and_mask): Instead of returning a solid mask rectangle for pixbufs without an alpha channel, set the *mask_return to NULL. * gdk-pixbuf/gdk-pixbuf-util.c (gdk_pixbuf_add_alpha): Constify. * gdk-pixbuf/gdk-pixbuf-scale.c: Fix includes. * gdk-pixbuf/gdk-pixbuf-scale.c (gdk_pixbuf_scale): Added some preconditions. Maybe we should also check for the colorspace, bits per pixel, and such. (gdk_pixbuf_composite): Likewise. (gdk_pixbuf_composite_color): Likewise. (gdk_pixbuf_scale_simple): Likewise, and fail gracefully if we cannot allocate the new pixbuf. (gdk_pixbuf_composite_color_simple): Likewise. * gdk-pixbuf/gnome-canvas-pixbuf.c (gnome_canvas_pixbuf_render): Use art_rgb_rgba_affine() or art_rgb_affine() since we no longer have an ArtPixBuf. * gdk-pixbuf/io-bmp.c: Fix includes. * gdk-pixbuf/pixops/pixops.c (pixops_scale_nearest): Fixed cast in an lvalue. * TODO: Populated. * configure.in: Removed checks for libart. * gdk-pixbuf/Makefile.am: Removed references to libart. (noinst_HEADERS): Added gdk-pixbuf-private.h. * gdk-pixbuf/Makefile.am (libgdk_pixbuf_la_LDFLAGS): Incremented the version number of the libtool library to indicate that this definitely is not compatible with the old usage. I know you love me. I know you do. * configure.in: Bumped version number to 0.7.0. * README: Updated. * gdk-pixbuf-config.in (--libs): We no longer require libart. * DEPENDS.libgdk_pixbuf: We no longer depend on libart. * gdk-pixbuf.spec.in: Updated, but I don't guarantee anything.
* Arjan van de Ven <arjan@fenrus.demon.nl>Arjan van de Ven2000-03-061-30/+78
| | | | | | | | Fixed to pointer-bugs and a mis-interpretation of the Microsoft documentation. Now it can load .BMP files that are not generated by The Gimp as well. a=federico
* 0.6.0 - FedericoGDK_PIXBUF_0_6_0Federico Mena Quintero2000-02-221-18/+19
|
* Change the order of the update func to make it more compatible with theJonathan Blandford2000-01-051-5/+11
| | | | | | | | | | | | | | | | | | 2000-01-05 Jonathan Blandford <jrb@redhat.com> * gdk-pixbuf/gdk-pixbuf-io.h: Change the order of the update func to make it more compatible with the rest of GTK. Added animation framework for progressive loading. * gdk-pixbuf/io-bmp.c (image_begin_load): Modified to handle new system. * gdk-pixbuf/io-ico.c (image_begin_load): ditto * gdk-pixbuf/io-png.c (image_begin_load): ditto * gdk-pixbuf/io-ras.c (image_begin_load): ditto * gdk-pixbuf/io-jpeg.c (image_begin_load): ditto * gdk-pixbuf/io-pnm.c (image_begin_load): ditto * gdk-pixbuf/io-tiff.c (image_begin_load): ditto * gdk-pixbuf/io-gif.c (image_begin_load): ditto
* Added missing "include <string.h>" to: gdk-pixbuf/io-ras.cArjan van de Ven1999-12-071-0/+1
| | | | | | | | | | 1999-12-05 Arjan van de Ven <arjan@fenrus.demon.nl> Added missing "include <string.h>" to: * gdk-pixbuf/io-ras.c * gdk-pixbuf/io-bmp.c * gdk-pixbuf/io-ico.c
* Major cleanup, added support for 32 bpp and 4 bpp (uncompressed) images,Arjan van de Ven1999-12-041-190/+270
| | | | | | | | | | | | | | | | 1999-12-04 Arjan van de Ven <arjan@fenrus.demon.nl> * gdk-pixbuf/io-bmp.c: Major cleanup, added support for 32 bpp and 4 bpp (uncompressed) images, fixed 1bpp. * gdk-pixbuf/io-ras.c: Minor cleanup, ran through lclint * gdk-pixbuf/io-ico.c: Minor cleanup, fixed 1bpp icons, ran through lclint. * gdk-pixbuf/gdk-pixbuf-io.c: Added detection of .CUR files (Windows Cursor files). These are identical to .ICO files, except for the signature and 2 extra fields for the hotspot.
* #include <config.h>, and fix includes.Federico Mena Quintero1999-12-021-6/+3
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | 1999-12-02 Federico Mena Quintero <federico@redhat.com> * src/testpixbuf.c: #include <config.h>, and fix includes. * src/testpixbuf-drawable.c: #include <config.h>, and fix includes. * src/io-xpm.c: Fix includes. * src/io-tiff.c: Fix includes. * src/io-ras.c: Fix includes, and do not include more stuff than needed. * src/io-pnm.c: Fix inlcudes, and do not include more stuff than needed. * src/io-png.c: Fix includes. * src/io-ico.c: Fix includes, and do not include more stuff than needed. * src/io-gif.c: Fix includes, and do not include more stuff than needed. * src/io-bmp.c: Fix includes, and do not include more stuff than needed. * src/gnome-canvas-pixbuf.c: Fix includes. * src/gdk-pixbuf.c: Fix includes. * src/gdk-pixbuf-util.c: Fix includes. * src/gdk-pixbuf-render.c: Fix includes. * src/gdk-pixbuf-io.h: Fix includes. * src/gdk-pixbuf-drawable.c: Fix includes. * src/gdk-pixbuf-drawable.h: Use angle brackets for the gdk-pixbuf include files. * src/gdk-pixbuf-data.c: Fix includes. * src/gdk-pixbuf-loader.c: #include <config.h> * src/gdk-pixbuf-loader.h: Use angle brackets for the gdk-pixbuf include files. * src/Makefile.am: Commented out the gdk-pixbuf-drawable stuff, since it is not finished.