Puppy Linux Discussion Forum Forum Index Puppy Linux Discussion Forum
Puppy HOME page : puppylinux.com
"THE" alternative forum : puppylinux.info
 
 FAQFAQ   SearchSearch   MemberlistMemberlist   UsergroupsUsergroups   RegisterRegister 
 ProfileProfile   Log in to check your private messagesLog in to check your private messages   Log inLog in 

The time now is Thu 17 Apr 2014, 00:20
All times are UTC - 4
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
Pikona - Puppy Icon Assembler NEW and TINY! - v.0.4e
Post new topic   Reply to topic View previous topic :: View next topic
Page 1 of 4 [55 Posts]   Goto page: 1, 2, 3, 4 Next
Author Message
vovchik


Joined: 23 Oct 2006
Posts: 1285
Location: Ukraine

PostPosted: Thu 19 Nov 2009, 18:34    Post subject:  Pikona - Puppy Icon Assembler NEW and TINY! - v.0.4e
Subject description: No dependencies on IM :)
 

Dear Puppians,

Picona was created because I got tired of running my bash scripts that would call ImageMagick to merge images when making icons.

I decided to give BaCon a try for this purpose, and Pikona is the result.

Pikona used to require Image Magick. I finally revised it and removed all the IM calls, replacing them with my own routines. As a result, you don't have to install anything else, except extra images. The actual pikona binary (stripped and UPX'd) is just short of 29k - not 6+ MB for ImageMagick! Pikona now is able to read images from any directory and lots of graphic file types are supported (i.e.. png, gif, jpg, ico, icns, wmf, svg, xpm). The seemingly large pet file size is because there are some basic images in the bgd, onj and ovl directories. I have also made additional image packs for background, object and overlay images and highly recommend that you install them to see what Pikona can really do. Also, fileselection has been dramatically improved.

Pikona basically takes a background image, superimposes an object and covers that with a semi-transparent button.

The directories /bgd, /obj and /ovl (in /usr/pikona4) contain the source images (you can, of course, add your own). The composite image is stored (after saving), in the HOME$/pikona directory. There is a rudimentary help window.

I used BaCon (build 25) and the HUG (0.73) library for most of the GUI graphics and to straight calls to gdk_pixbuf and libssl for processing - the latter is needed for calculating the MD5 hashes of image thumbnails. The source is containd in the pikona4/data/src dir.

I know there are bugs, and there is much room for improvement. Please post suggestions or modified code.

Have fun creating your own icon sets in minutes, not days or hours.

With kind regards,
vovchik

PS. I compiled in Lucid - so Pikona4 should work in most recent puppies.
pikona4-obj-various.pet
Description 
pet

 Download 
Filename  pikona4-obj-various.pet 
Filesize  285.26 KB 
Downloaded  373 Time(s) 
pikona4-obj-grey.pet
Description 
pet

 Download 
Filename  pikona4-obj-grey.pet 
Filesize  239.57 KB 
Downloaded  340 Time(s) 
pikona4-obj-black.pet
Description 
pet

 Download 
Filename  pikona4-obj-black.pet 
Filesize  265.99 KB 
Downloaded  335 Time(s) 
pikona4-bgd-square2.pet
Description 
pet

 Download 
Filename  pikona4-bgd-square2.pet 
Filesize  640.35 KB 
Downloaded  369 Time(s) 
pikona4-bgd-square1.pet
Description 
pet

 Download 
Filename  pikona4-bgd-square1.pet 
Filesize  761.95 KB 
Downloaded  347 Time(s) 
pikona4-bgd-square1.pet
Description 
pet

 Download 
Filename  pikona4-bgd-square1.pet 
Filesize  761.95 KB 
Downloaded  336 Time(s) 
pikona4-bgd-round2.pet
Description 
pet

 Download 
Filename  pikona4-bgd-round2.pet 
Filesize  849.72 KB 
Downloaded  358 Time(s) 
pikona4-bgd-round1.pet
Description 
pet

 Download 
Filename  pikona4-bgd-round1.pet 
Filesize  748.88 KB 
Downloaded  356 Time(s) 
pikona4-base.pet
Description  You need this - everything else is optional!!!!!
pet

 Download 
Filename  pikona4-base.pet 
Filesize  621.59 KB 
Downloaded  375 Time(s) 
pikona4e.png
 Description   
 Filesize   96.49 KB
 Viewed   1147 Time(s)

pikona4e.png


Last edited by vovchik on Fri 09 Mar 2012, 10:45; edited 1 time in total
Back to top
View user's profile Send private message 
vovchik


Joined: 23 Oct 2006
Posts: 1285
Location: Ukraine

PostPosted: Fri 20 Nov 2009, 10:22    Post subject:  

Dear Puppians,

I tested Pikona with ImageMagick v. 6.3.3 and everything works. With any of the 6.5.x versions, however, I either get a reduced bitdepth - which kills transparency, amongst other things, or it coughs and does not produce an image during one of the 6 launches of IM executables. I will try to find out what systax changes were introduced between the versions for the convert, montage and coalesce binaries. If you know this offhand, please post this info, as this will save me time. I do want Pikona to run as universally as possible and could do a version check and modify the IM binary launch strings.

With kind regards,
vovchik
Back to top
View user's profile Send private message 
dejan555


Joined: 30 Nov 2008
Posts: 2588
Location: Montenegro

PostPosted: Fri 20 Nov 2009, 10:32    Post subject:  

Oh goodie, seems interesting, gonna test it later today, don't remember now which image magick version i have.
So lemme see. I can make backgrounds, overlays and pics to go inbetween, cool. I just place images in appropriate folders to show up in drop down list?

_________________


Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Fri 20 Nov 2009, 10:33    Post subject:  

vovchik

I havent tried your app yet but it looks
great! I wanted to let you know soon I just read this Very Happy

and also congratulations for doing it in BaCon !!

I'll be testing

I know imagemagic is very powerful
but if you need a just a light command line image resizer /non editor ... I use
aaphoto


with a simple script I wrote here for
conveting to 16 and 48 size *.png
for package building

I hope I can include that in your code Very Happy

a big thanks


Code:

#!/usr/bin/env bash

#Joe Arose aka..big_bass
#drag and drop make 48x48 images for packages
#to the pixmaps folder
#place the icon inside it
#remove the _new.png  name
#only a  *.png will get placed in the folder
#other formats will get made though such as *.jpg
#they just won't get placed in the package ready folder


# check if tools are available
if [ "`which aaphoto`" = "" ] > /dev/null 2>/dev/null
then
 echo "Please check if aaphoto is installed ."
 sleep 10 #some time to read
 exit -1
fi

#what if no file is selected?
if [$1 = ]; then
                  echo "no files given"
                  sleep 5
              exit 0
 
               fi
           
DIRNOW=`dirname "$1"`

#command line image converter  -s is silent ,resize48  is for 48 pixels
#read for options  #rox -s /usr/doc/aaphoto_sources-v0.30/README

aaphoto -s --resize48 "$1"

#strip off the .png
#make the strings I need
IMAGENAME=`basename  "$1" .png`
DIRNOW=`dirname "$1"`

#for testing only to check output
#echo $IMAGENAME"_new.png" >/root/image.txt
#echo $DIRNOW >>/root/image.txt


#here I need to rename the generated *_new file  back to the original name
#to make things easy the correct folder is made for you  also

#what if not a *.png file is selected?
#dont build the folders
if echo `basename "$1" ` | grep -q '.png$'; then
                  mkdir -p $DIRNOW/usr/share/pixmaps/   
              fi
                                                                   
mv $DIRNOW/$IMAGENAME"_new.png" $DIRNOW/usr/share/pixmaps/           
mv $DIRNOW/usr/share/pixmaps/$IMAGENAME"_new.png" $DIRNOW/usr/share/pixmaps/$IMAGENAME".png"     



updated now I tried it WOW
you got a great little app here Cool Cool Cool

imagemagick-6.4.3.10 I compiled it from source as a *.tgz
http://puppy2.org/slaxer/imagemagick-6.4.3.10-i486-2-slxr.tgz
Joe

_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though

Last edited by big_bass on Fri 20 Nov 2009, 13:13; edited 1 time in total
Back to top
View user's profile Send private message 
dejan555


Joined: 30 Nov 2008
Posts: 2588
Location: Montenegro

PostPosted: Fri 20 Nov 2009, 12:52    Post subject:  

I tried it. I love it Smile
A question: is overlay image resized some % cause i made background and overlay same dimensions, and when it put em togheter overlay is bit scaled so I can see edges of background below overlay?

_________________


Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
vovchik


Joined: 23 Oct 2006
Posts: 1285
Location: Ukraine

PostPosted: Fri 20 Nov 2009, 13:36    Post subject:  

Dear dejan555,

I am glad it works for you. Originally - and in my incomplete glade version - I used a spinbox for the scaling, so it was more sensitive. Try setting it at 90 or 100. The default is set at 70. In my bash version, I also used an x,y displacement factor, which allowed control of object positioning. I would introduce it again, but it would destroy the current symmetry of the gui design. I suppose I could cut the dropdown scale list in half and then have two thin displacement dropdowns - for x and y distance from 0,0 (origin). I'll give it some thought.

I think you see now how easy it is to create a complete icon set without too much effort.

With kind regards,
vovchik

PS. Joe (big_bass): aaphoto is possible - look at the cmdx$ statements in the source. What I would really like to do is to eliminate all dependencies and do all the manipulation of images in memory. That would make Pikona self-contained, and it would run on all Puppies out of the box. But first I have to study the png format. BaCon allows for binary loads to memvars, which is nice and a prerequisite for what I have in mind.
Back to top
View user's profile Send private message 
amigo

Joined: 02 Apr 2007
Posts: 2166

PostPosted: Fri 20 Nov 2009, 13:51    Post subject:  

vovchik, I think you'll have to study the docs for ImageMagick about the syntax changes. There have been major changes in the way you use ImageMagick. It can now be used in such a way that the options act like a script -I mean you can carry out a whole series of operations on an image without having to run the program several times. This means that the *order* in which options are passed has become more critical.

Here's a link which might be useful:
http://www.packtpub.com/page/ImageMagick_Tricks_Table_of_Contents
Back to top
View user's profile Send private message 
dejan555


Joined: 30 Nov 2008
Posts: 2588
Location: Montenegro

PostPosted: Fri 20 Nov 2009, 13:56    Post subject:  

Yeah thanks for reply vovchik, but I'm talking about scaling "overlay", not "object", or is it set to 70 by default for both? I don't think so.

And yes, it IS very good for making iconsets, all you need is to make multiple objects then put em together between bg and overlay Very Happy

_________________


Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
dejan555


Joined: 30 Nov 2008
Posts: 2588
Location: Montenegro

PostPosted: Fri 20 Nov 2009, 14:01    Post subject:  

I really like the current design and functionality, I wouldn't change anything, just wondered about overlay, but maybe it was my bad.
_________________


Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
vovchik


Joined: 23 Oct 2006
Posts: 1285
Location: Ukraine

PostPosted: Fri 20 Nov 2009, 14:06    Post subject:  

Dear dejan555,

You are right. I only scale the object. If the bgd and ovl are not lined up in terms of x-y, check the images. I normally found that bdg images should have a margin of some 10 pixels or more on all sides and the ovl slightly less. I may be wrong about the numbers, since I can't recall. There is some trimming that goes on before the "end result", with expansion back to 128x128 on a transparent background for purposes of centring. I'll try to look into this.

With kind regards,
vovchik
Back to top
View user's profile Send private message 
vovchik


Joined: 23 Oct 2006
Posts: 1285
Location: Ukraine

PostPosted: Fri 20 Nov 2009, 15:03    Post subject:  

Dear Joe,

Thanks very much for your compile of ImageMagick. With it, Pikona works very nicely under Puppy 4.x, and we should recommend your version to all users who wish to run Pikona. After examing the tgz, I made it into a pet using tgz2pet and it installed fine. My previous version on a laptop was a very recent one and it caused some difficulties. I will have to take amigo's suggestion to heart and read up on the changes to IM syntax (6.5.x) one of these days, however, so that users don't run into problems and we are not tied to a particular IM version. There is some advantage to universality, as reflected in Peter's choice to use bash as the converter/compiler of BaCon. That was brilliant. Along the same lines, for Pikona it would be ideal to to do all the image manipulation natively, as mentioned above, but that will take some serious investigation of the png format (unless I co-opt gdk_pixbuf to do the thinking for me).

Thanks again and kind regards,
vovchik

I am glad you like Pikona. We can now make Puppy very pretty very fast. Smile

With kind regards,
vovchik

PS. dejan555: Are you alredy working ont a nice, new icon set?
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Fri 20 Nov 2009, 16:08    Post subject:  

vovchik

some extra images for pikona unzip in the pikona folder
the folder is called obj when uncompressed
they will install in the correct place which is the obj folder
these are from my rox theme on slaxer pup

http://puppy2.org/slaxer/pikona-extra-images.tar.gz

thank you for this app
Joe

_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
dejan555


Joined: 30 Nov 2008
Posts: 2588
Location: Montenegro

PostPosted: Fri 20 Nov 2009, 16:24    Post subject:  

vovchik wrote:

PS. dejan555: Are you alredy working ont a nice, new icon set?


You betcha Wink

_________________


Back to top
View user's profile Send private message Visit poster's website MSN Messenger 
vovchik


Joined: 23 Oct 2006
Posts: 1285
Location: Ukraine

PostPosted: Mon 23 Nov 2009, 09:51    Post subject:
Subject description: Updated - now with spinbox and new images
 

Dear Puppians,

Peter was kind enough to make a few very lovely additions to the HUG library, including a spinbox and fileselect. I revised Pikona a bit to use the spinbox and will soon post another version that makes use of fileselect rather than combo boxes for choosing images.

If you have already installed the first version (v. 01 alpha), simply replace the old Pikona binary (and other files) with this one (v. 02 alpha) and replace the obj and ovl dirs with the new ones. There are quite a few more interesting background images now, and I included a blank128.png in some dirs for the sake of flexibility. Choose one of the metal backgrounds, set obj to blank128.png and ovl to clear-but.png and you will see what I mean. You can make new bgd images this way pretty easily.

If you have not installed Pikona yet, first install Joe's ImageMagick (see previous posts), then install the first version of Pikona and then overwrite the old stuff with the content of the attached archives. I could have made an all-in-one, easy-to-use archive, but there is a 1-MB limit for files on the forum. Sorry for the inconvenience.

Have fun....

With kind regards,
vovchik
pikona003.jpg
 Description   
 Filesize   36.12 KB
 Viewed   3045 Time(s)

pikona003.jpg

ovl.tar.gz
Description 
gz

 Download 
Filename  ovl.tar.gz 
Filesize  443.75 KB 
Downloaded  706 Time(s) 
bin.tar.gz
Description 
gz

 Download 
Filename  bin.tar.gz 
Filesize  36.81 KB 
Downloaded  692 Time(s) 
bgd.tar.gz
Description 
gz

 Download 
Filename  bgd.tar.gz 
Filesize  781.07 KB 
Downloaded  748 Time(s) 
Back to top
View user's profile Send private message 
big_bass

Joined: 13 Aug 2007
Posts: 1747

PostPosted: Mon 23 Nov 2009, 11:24    Post subject:  

Hey vovchik


new version test working fine!

Joe
blank128_puppylogo128_clear-blue_70.png
 Description   
 Filesize   23.74 KB
 Viewed   2799 Time(s)

blank128_puppylogo128_clear-blue_70.png


_________________
debian wheezy ,linux mint, slackware I use them all and they all have good points
Mint would be best for general users though
Back to top
View user's profile Send private message 
Display posts from previous:   Sort by:   
Page 1 of 4 [55 Posts]   Goto page: 1, 2, 3, 4 Next
Post new topic   Reply to topic View previous topic :: View next topic
 Forum index » Advanced Topics » Additional Software (PETs, n' stuff) » Desktop
Jump to:  

You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum
You cannot vote in polls in this forum
You cannot attach files in this forum
You can download files in this forum


Powered by phpBB © 2001, 2005 phpBB Group
[ Time: 0.0829s ][ Queries: 13 (0.0037s) ][ GZIP on ]