Re: XPM image creation
| From: | Joel De Gan | Date: | Fri, 02 Jul 2004 21:05:43 +0000 |
| Subject: | Re: XPM image creation | ||
| References: | 1 2 3 | Groups: | php.gtk.general |
| Request: | Send a blank email to php-gtk-general+get-4694@lists.php.net to get a copy of this message | ||
I just relized this might be a bit confusing still
in your example "2" is that it takes two letters to identify a code.
1 would be a-z,0-9 and others..
hope that is a little more clear..
-joel
On Fri, 2 Jul 2004 15:05:27 -0400, Joel De Gan <joeldg@gmail.com> wrote:
> Hey,
> The fourth number is the color code length.
> i.e. how many letter-combinations make up a pixel in the image.
> This generally depends on the number of colors that are present in an image.
> Spaces count here.
> They usually will start out like "{letter}{space}{tab}#{color}", and
> later you will start seeing other letters in that second spot.
> if they are 16 color they look like
> "{letter}{tab}#{color}",
> When "None" is specified instead of #{color}, that is a transparent pixel.
> Keep the images in RGB mode when you are exporting them to XPM. I
> usually try to keep them in 256 colors as above that it will require
> some parsing to fix certain characters.
> -joel
>
>
>
> On Sat, 3 Jul 2004 02:42:16 +1000, Tom Rogers <trogers@kwikin.com> wrote:
> > dmo> Does anyone have a link to a resource or tutorial about XPM image
> > dmo> creation. I've been going through Joel De Gan's code
> > dmo> ( message title: [PHP-GTK] introduction etc.. php-gtk tutorials ) from
> > dmo> yesterday, but there still seems to be basic stuff that I'm missing, like
> > dmo> the meaning of the 4th number in the first line of the xpm array, i.e.,
> >
> > dmo> xpm_array = array(
> > dmo> "120 /* width */ 100 /* height */ 256 /* number of colors
> > dmo> */ 2 /* what is this for */",
> > dmo> " c None",
> > dmo> ". c #020202",
> > dmo> "+ c #224A22",
> > dmo> "@ c #428642",
> > dmo> "# c #76BA76",
> > dmo> .....
> > dmo> ....
> > dmo> ...
> > dmo> ..
> > dmo> .
> >
> > dmo> ");
> >
> > dmo> And what application is actually producing the image? php_win.exe ?
> > dmo> (obviously, I'm on windows).
> >
> > dmo> I've googled around a bit, but haven't had much luck with good info.
> >
> > dmo> Thanks Much,
> >
> > dmo> dave
> >
> > The 2 is the number of characters/pixel so you can get to 256
> > colours (I think a space acts as a null)
> >
> > --
> > regards,
> > Tom
> >
> >
> >
> > --
> > PHP-GTK General Mailing List (http://gtk.php.net/)
> > To unsubscribe, visit: http://www.php.net/unsub.php
> >
> >
>