[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-core-devel
Subject:    kimgio_ico_write() is broken
From:       Claudiu Costin <claudiuc () work ! ro>
Date:       2001-06-28 15:48:36
[Download RAW message or body]

        Hello friends,

  A short story:
I need to generate MS ICO files 16x16-16colors
(aka favicons). Well I searched on the Net and 
found nothing for Linux. The ONLY free tool is
a java app at www.favicon.com. Even Adobe 
Photoshop, Corel Photopaint dont't know to 
work with such simple format. On Linux, 
the full featured ImageMagick don't handle 
writing.
  Sorry for long story :)

  So, well we have KDE with kimgio plugin based 
library. But it can read MS ICO files, 
but write BAD (tm) ones. I've made a simple
KDE program (sent to Coolo) and a Perl script
to extract info from ICO files (even an ASCII
rendering is posible) and found errors in writen ICO file.

  To be technical, here is a info dump from www.kde.org
favicon (which is a good icon):
____________________________________________
File info:
  reserved = 0
  type     = Icon
  count    = 2 icon(s)
 
Icon 1 entry:
  size     = 16x16 pixels - 255 color(s)
  hotspot  = (x=0 y=0)
  size     = 1384 bytes
  offset   = 38-th byte in file
 
Bitmap 1 header:
  header size      = 40 bytes
  bitmap width     = 16 pixels
  bitmap height    = 32 pixels
  planes           = 1
  bits per pixel   = 8 bits
  compression      = 0
  image size       = 0 bytes
  X pixels / meter = 0
  Y pixels / meter = 0
  colors used      = 0
  colors important = 0
____________________________________________

As you may observe "bitmap height=32" 
because are 2 bitmaps in ICO file. But 
KDE set bitmap height to 16!
Frankly, kimgio use DIB manipulation 
classes from Qt. So I think there is 
the bug.

  My question: could some one 
fix that and make an audit on this library.
It's a shame that under Linux is no 
favicon editor and an 
<put_your_format_here> to MS ICO converter.

 Being disapointed I started to write a Perl
XPM2ICO program. But this a workaround 
solution for 16x16-16 MS ICO.

kind regards,
-- 
Claudiu Costin
<claudiuc@work.ro>

[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic