forked from AuroraMiddleware/gtk
Iain sent me a xpm that didn't load. It used "g" instead of "c" in it's
Iain sent me a xpm that didn't load. It used "g" instead of "c" in it's color table. I thought that was borked until I saw Imlib, xv, and Gimp load it up w/o problem... So, fixed that (less than one line fix). HOWEVER, if this is correct, then the gdk XPM loader in gtk+ also has the same problem. Owen, got an opinion on this? Mark
This commit is contained in:
parent
97f2c2b7bb
commit
d0f73034cf
@ -1,3 +1,8 @@
|
|||||||
|
2000-02-14 Mark Crichton <crichton@gimp.org>
|
||||||
|
|
||||||
|
* gdk-pixbuf/io-xpm.c (xpm_extract_color): Added check for "g" color type.
|
||||||
|
Imlib/libXpm handle this, but we didn't.
|
||||||
|
|
||||||
2000-02-14 Darin Adler <darin@eazel.com>
|
2000-02-14 Darin Adler <darin@eazel.com>
|
||||||
|
|
||||||
* gdk-pixbuf/testpixbuf.c: Remove now-unnecessary cast.
|
* gdk-pixbuf/testpixbuf.c: Remove now-unnecessary cast.
|
||||||
|
@ -195,7 +195,7 @@ xpm_extract_color (const gchar *buffer)
|
|||||||
|
|
||||||
counter = 0;
|
counter = 0;
|
||||||
while (ptr == NULL) {
|
while (ptr == NULL) {
|
||||||
if (buffer[counter] == 'c') {
|
if ((buffer[counter] == 'c') || (buffer[counter] == 'g')) {
|
||||||
ch = buffer[counter + 1];
|
ch = buffer[counter + 1];
|
||||||
if (ch == 0x20 || ch == 0x09)
|
if (ch == 0x20 || ch == 0x09)
|
||||||
ptr = &buffer[counter + 1];
|
ptr = &buffer[counter + 1];
|
||||||
|
Loading…
Reference in New Issue
Block a user