Icon Finder v1.4

Paint programs, vector editors, 3d modelers, animation editors, etc.
Message
Author
User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

Icon Finder v1.4

#1 Post by SFR »

Icons in Puppy are located in many, sometimes exotic, places.
This application helps to find them all and display at once.

Icon Finder will be useful, for instance:
- for users who want to easily find icons for new desktop shortcuts,
- for devs in searching for non gtk-stock icons for their apps,
(as a bonus I've included 'Gtk stock icons' viewer too, posted here by Smokey01)

Usage:

1. On the first run there's request to create a new list.
It may take even a few minutes - depends of your system specs and amount of icons.
2. When the list is already created, a window with icons will be displayed (see screenshot).
3. You can hover an icon to see its location and resolution.
4. You can click an icon to locate it via ROX-Filer.
5. If there were changes in your system and want to re-search icons, use 'Menu -> Create new list'.

More info:

Supported formats are: bmp gif ico jpg pcx png ppm pnm svg tga tif xpm
The app is not extensively tested, so I can't say if every variant of the above formats will be processed properly.

The minimum and maximum sizes of icons are set to 0x0-64x64, but it can be edited ('Menu -> Settings'), just remember to adjust the size of buttons too - it must be ~10px larger, to fit icons within...or use 'Scale images' option.

Requirements:

Gtkdialog >= 0.8.0, awk, cut, tr, grep, head, tail, file, exiv2 (or feh), xmessage, xrandr, Xdialog (all should be already included in most/all of modern Puppies)

Known issues:

Icon Finder examines files by extension and, depending on this info, tries to acquire their resolution.
If a file has altered extension (not corresponding to its real type), it won't be processed correctly and therefore not displayed.
BTW, I'm aware of a tool called "identify", but I didn't want to include any external tool that is not already in Puppy.

Files with spaces in filename are processed and displayed correctly, but in some Puppies won't be located via ROX-Filer (rox -s "$FILENAME").
This happens in Slacko-5.3.3, but not in Lupu-528; must be caused by different ROX versions...
EDIT: I've found the problem, it's /usr/local/bin/rox
If you're on Slacko 5.3.3 and the problem bothers you, open the above file and add double quotes, as shown below:

Code: Select all

exec /usr/local/apps/ROX-Filer/AppRun "${@#*file://}"
Slowness...
Even if the list is already created it takes a while to bring up the GUI (but hey, there is usually 1200+ icons to display!).
The same happens during window resizing, so it's not recommended.

If there's too many icons to display (~9000 in my tests) IconFinder/Gtkdialog just can't handle it and crashes...

In Lupu-528 (and its derivatives) when IconFinder is launched through right click menu entry and the displayed list of icons is too long (height counts) it may not work properly.
Workarounds:
- always run IconFinder through bottom left menu (Openbox) or shortcut on the pinboard, Wbar, etc.
- increase the number of columns (this will decrease the height)

_______________________

EDIT:
Uploaded new version with menu entry fix for Precise, see this post for details.
Uploaded version 1.1 with few fixes and additions, see this post for details.
Uploaded version 1.2, see this post for details.
Uploaded version 1.3, see this post for details.
Uploaded version 1.3.1, see this post for details.
Uploaded version 1.4, see this post for details.
_______________________

iconfinder_NLS-1.4.pet contains the following translations:
- Polish (me)
_______________________

Written on Slacko-5.3.3/5.5

Have fun &
Greetings!
Attachments
iconfinder_NLS-1.4.pet
Langpack for iconfinder-1.4 (so far only pl)
(2.37 KiB) Downloaded 944 times
iconfinder-1.4.pet
Icon Finder v1.4
(10.38 KiB) Downloaded 1005 times
iconfinder-1.3.1.pet
Icon Finder v1.3.1
(10.07 KiB) Downloaded 1119 times
iconfinder-1.3.pet
Icon Finder v1.3
(9.74 KiB) Downloaded 1222 times
screenshot.jpg
(67.19 KiB) Downloaded 2817 times
iconfinder-1.2.pet
Icon Finder v1.2
(9.37 KiB) Downloaded 1208 times
Last edited by SFR on Sat 29 Jun 2013, 15:34, edited 25 times in total.
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#2 Post by SFR »

Fixes in v1.0b1:

1. Redesigned GUI.
I had to resign of the drop down menu because there's a following problem with Gtkdialog-0.8.0.
It seems that if there are <menubar><menu><menuitem>... tags used in the GUI, then if one close such a window using 'X' and not through "Quit" option, the process remains active and previously allocated memory isn't freed (according to ps, htop and free commands).
...and the app is very resource hungry, so it is a problem.
If a GUI doesn't have menu everything's fine, so I used buttons instead...
BTW, I've tested the app with the latest Gtkdialog-0.8.2 and the problem didn't pop up there.

2. Changed the default max. icon res. from 48x48 to 64x64.

3. Tuned "Scale images" option.

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#3 Post by disciple »

Hi SFR,
I have added this to the list of programs using gtkdialog.
Do you have any other programs you can add?
Thanks.
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#4 Post by SFR »

Hey Disciple.

Yup, there's a few more; I've added them to your thread.

Thanks & Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

disciple
Posts: 6984
Joined: Sun 21 May 2006, 01:46
Location: Auckland, New Zealand

#5 Post by disciple »

Great, thanks. The text encryption one looks pretty cool :)
Do you know a good gtkdialog program? Please post a link here

Classic Puppy quotes

ROOT FOREVER
GTK2 FOREVER

User avatar
RSH
Posts: 2397
Joined: Mon 05 Sep 2011, 14:21
Location: Germany

#6 Post by RSH »

Ok.

I wish this application would happen earlier - much earlier. I like this and so I have made an sfs from this one and do use it from sfs in LazY Puppy.

I like this that much, so i have made an icon for it.

Hope you like this.

RSH
Attachments
iconfinder.png
(3.08 KiB) Downloaded 2675 times
[b][url=http://lazy-puppy.weebly.com]LazY Puppy[/url][/b]
[b][url=http://rshs-dna.weebly.com]RSH's DNA[/url][/b]
[url=http://murga-linux.com/puppy/viewtopic.php?t=91422][b]SARA B.[/b][/url]

User avatar
RSH
Posts: 2397
Joined: Mon 05 Sep 2011, 14:21
Location: Germany

#7 Post by RSH »

SFR wrote:Fixes in v1.0b1:

1. Redesigned GUI.
I had to resign of the drop down menu because there's a following problem with Gtkdialog-0.8.0.
It seems that if there are <menubar><menu><menuitem>... tags used in the GUI, then if one close such a window using 'X' and not through "Quit" option, the process remains active and previously allocated memory isn't freed (according to ps, htop and free commands).
...and the app is very resource hungry, so it is a problem.
If a GUI doesn't have menu everything's fine, so I used buttons instead...
BTW, I've tested the app with the latest Gtkdialog-0.8.2 and the problem didn't pop up there.

2. Changed the default max. icon res. from 48x48 to 64x64.

3. Tuned "Scale images" option.

Greetings!
Hi, SFR.

If you want to use a menu in a gtkdialog gui and want to make sure the application does not remain active, insert the following code (the first line) to the script (</window> shows where to insert).

Code: Select all

<action signal="hide">exit:abort</action>
</window>" # End - Main GUI
Greetings,

RSH
[b][url=http://lazy-puppy.weebly.com]LazY Puppy[/url][/b]
[b][url=http://rshs-dna.weebly.com]RSH's DNA[/url][/b]
[url=http://murga-linux.com/puppy/viewtopic.php?t=91422][b]SARA B.[/b][/url]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#8 Post by SFR »

RSH wrote:I like this that much, so i have made an icon for it.

Hope you like this.
Sure I do like! Me personally can't draw a straight line, so I always appreciate such a help.
Your icon has been included.
RSH wrote:

Code: Select all

<action signal="hide">exit:abort</action>
It works, thanks a lot!
So, the menu is back. 8)

(NOTE: If you have installed the new version over the old one, you have to rescan icons to see the new GUI).

Thanks & Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
RSH
Posts: 2397
Joined: Mon 05 Sep 2011, 14:21
Location: Germany

#9 Post by RSH »

Redraw issue in iconfinder?

I have 4817 icons in LazY Puppy. At scroll-down redraw "crashes".
Image

Is it the iconfinder or is it gtkdialog?

Maybe this could be solved using gtkdialog object notebook (tabs)? One tab for icons smaller 48 pixel and another tab for icons equal and bigger than 48 pixel.
[b][url=http://lazy-puppy.weebly.com]LazY Puppy[/url][/b]
[b][url=http://rshs-dna.weebly.com]RSH's DNA[/url][/b]
[url=http://murga-linux.com/puppy/viewtopic.php?t=91422][b]SARA B.[/b][/url]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#10 Post by SFR »

Not sure...
I just loaded 6499 icons and have not such a problem (except initial slowness).
If there's a lot of icons to display, actions like resizing or maximizing can give an illusion of hanging up, but after longer pause things back to normal...

BTW, how much RAM do you have?
For those 6499 images IconFinder has stolen ~155M of mem.

EDIT:
Done a quick test with <notepad>.
Disaster - it's painfully slow during switching tabs (same behaviour as during resizing).
And the RAM consumption is the same, no difference.
It's not a way, unfortunately...
But thanks for a suggestion.

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
RSH
Posts: 2397
Joined: Mon 05 Sep 2011, 14:21
Location: Germany

#11 Post by RSH »

System Information wrote:Current Time: 23:17:15
System Uptime: 6 hr 54 min
Load Average: 0.12 0.17 0.17

Motherboard Vendor:
Product Name: 4CoreDual-SATA2.

Operating System: LazY Puppy 202
Desktop Panel: tint2 version 0.11-svn
Desktop Window Manager: Openbox 3.4.11
Desktop Start: xwin openbox

=== CENTRAL PROCESSOR ===

Pentium(R) Dual-Core CPU E5200 @ 2.50GHz
Socket Designation: CPUSocket
Manufacturer: Intel
Voltage: 1.2 V
External Clock: 200 MHz
Max Speed: 2400 MHz
Current Speed of Core 0: 2494 MHz, Core 1: 2494 MHz

=== COMPUTER MEMORY ===

Memory Module 1
Data Width: 64 bits
Size: 1024 MB
Form Factor: DIMM
Locator: DIMM0
Type: SDRAM
Type Detail: Synchronous
Speed: Unknown

Memory Module 2
Data Width: 64 bits
Size: 512 MB
Form Factor: DIMM
Locator: DIMM1
Type: SDRAM
Type Detail: Synchronous
Speed: Unknown
[b][url=http://lazy-puppy.weebly.com]LazY Puppy[/url][/b]
[b][url=http://rshs-dna.weebly.com]RSH's DNA[/url][/b]
[url=http://murga-linux.com/puppy/viewtopic.php?t=91422][b]SARA B.[/b][/url]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#12 Post by SFR »

=== COMPUTER MEMORY ===

Memory Module 1
Data Width: 64 bits
Size: 1024 MB
Form Factor: DIMM
Locator: DIMM0
Type: SDRAM
Type Detail: Synchronous
Speed: Unknown

Memory Module 2
Data Width: 64 bits
Size: 512 MB
Form Factor: DIMM
Locator: DIMM1
Type: SDRAM
Type Detail: Synchronous
Speed: Unknown
1.5GB of RAM, so it's not the cause. I've tested IconFinder with 1GB successfully.
To ensure, I launched the app in Lupu-528 (on which LazY is based) under Openbox, loaded about 9000* of images...and despite long waiting to load them all, still OK.
Sorry, just can't recreate it...

Perhaps there's a certain image, which interfere with Gtkdialog and makes it crashes..?
To eliminate or confirm this, you could, for instance, do such a thing:

1. Launch Iconfinder, let it crash.
2. Open /root/.icon_finder/list file.
There's a a code like:

Code: Select all

<window..>
...some other stuff...

# and lots of blocks of code like:

<hbox...>
<button........</button>
<button........</button>
<button........</button>
...
</hbox>

# and so on...

...other stuff again...
</window>
3. Make a backup of this file.
3a. Remove a half (approximately) of all these <hbox>...</hbox> blocks from the beginning of the file, run Iconfinder and see if it hangs.
3b. Recreate the original list from backup, but this time remove a half of blocks from the bottom and see again if it hangs.

Just make sure to remove full blocks of <hbox>....</hbox>

Maybe this will say something to us, because I'm out of ideas...


*) ~9000 it's near the limit, more produces gtk error, btw.

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#13 Post by SFR »

@RSH:
I just downloaded your latest LazY (great splash-screen, btw!)...and experienced this "crash" at last (5076 icons).

Here's what I've noticed, perhaps it gives you some clues:

When I launched IconFinder from the menu entry, it stopped displaying icons indeed, approximately at ~70% of scrollbar's lenght.
Additionaly, scrollbar was, let's say, "jumpy".

However when I launched IconFinder from terminal window (but only ROX-Term, because urxvt gives the same effect!), the problem just gone, everything worked fine, without "crashes" and scrollbar was moving smoothly.

Weird, isn't it? :shock:

HTH
Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#14 Post by SFR »

Update: version 1.0b3

I just noticed that the latest Barry's Precise (beta 7) has Bash v3.00 and IconFinder was written using Bash v4.1.0

But it was enough to change just one line and now it works in this Puppy, too.

NOTICE: if anyone tried to launch IconFinder on Precise before and have installed corrected version now, it's necessary to delete /root/.icon_finder directory or else app will not start.

Summarizing, IconFinder has been tested and works on the following Puppies, so far:
- Slacko-5.3.3
- Lupuplus-528.005-1
- LazYPuppy-2.0.2-Final (with problems, see the previous posts)
- Precise-5.3.95.1 (beta 7)

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
RSH
Posts: 2397
Joined: Mon 05 Sep 2011, 14:21
Location: Germany

#15 Post by RSH »

Hi, SFR.

The issue with iconfinder in LazY Puppy seems not to depend on the numbers of icons. I have reproduced this right now with a count of 3910 icons ---> free RAM is about 990 MB.

Everything works fine if using 12 columns instead of 8 columns!

LazY Puppy has installed gtkdialog4 (0.8.0) ---> which version of gtkdialog4 do you use?
SFR wrote:Weird, isn't it? :shock:
Yes, that's weird. :shock:
[b][url=http://lazy-puppy.weebly.com]LazY Puppy[/url][/b]
[b][url=http://rshs-dna.weebly.com]RSH's DNA[/url][/b]
[url=http://murga-linux.com/puppy/viewtopic.php?t=91422][b]SARA B.[/b][/url]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#16 Post by SFR »

Hey RSH
RSH wrote:LazY Puppy has installed gtkdialog4 (0.8.0) ---> which version of gtkdialog4 do you use?
The very same version.
RSH wrote:Everything works fine if using 12 columns instead of 8 columns!
Confirmed. It seems that the "bug" reveals itself when the list is too long (too height).

but then again...

When IconFinder is launched directly through:
- .desktop symlink (/usr/share/applications)
- .dekstop file (/usr/share/applications-desktop-files/applications)
- shortcut created on the pinboard
- "LazYPuppy" menu in the bottom left corner (!)
it runs without any problems again (5076 icons, 5 columns).

So, the problem pops up when IconFinder is launched via (right click menu entry OR urxvt) AND the list is too long (height).
BTW, it happens also in regular Lupu-528, so it's not LazY specific issue.

But it's still weird and beyond my understanding, so honestly I've no idea how to fix it. :?

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#17 Post by SFR »

v1.0 uploaded (see the first post).

Not much has changed really, just a few internal mods to handle errors and to display appropriate messages in such cases.
I just wanted to finish with those beta versions at last. :wink:

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
BarryK
Puppy Master
Posts: 9392
Joined: Mon 09 May 2005, 09:23
Location: Perth, Western Australia
Contact:

#18 Post by BarryK »

[url]https://bkhome.org/news/[/url]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#19 Post by SFR »

Thank you Barry, I must have overlooked this when I (briefly) tested the app in Precise.
I've done it like this:

Code: Select all

Categories=Graphics;Viewer
because in Slacko (and probably in other Pups too) if there's just "Viewer", the menu entry appears in "Utility" submenu only.

Thanks again!
____________

Also, there's a problem in Lupu (again) with checking if the app is already running (to prevent multiple instances), so I've removed this until I find more reliable way.

Looks like I was too hasty in ending betas, lol. :wink:

First post updated.

Greetings!
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

User avatar
SFR
Posts: 1800
Joined: Wed 26 Oct 2011, 21:52

#20 Post by SFR »

From Precise thread:
drblock2 wrote:[...]iconfinder had left my local machine and had started to download the addresses of all the jpg's on my server. This is why the program appeared to hang.

This unexpected behavior was caused by an unintended interaction with YASSM. iconfinder is configured to search /root among other directories and YASSM mounts the network shares in /root/YASSM - hence the entire network is included in the search rather than just a few local directories where icons are likely to be found.[...]
Whoa, that wasn't planned! :lol:
But it can be useful actually, because IconFinder is flexible enough to search for...wallpapers or photos, for instance.

Fixes & additions in version 1.1:
- from the above issue - added appropriate checkbox in settings; user can choose if any encountered mount point should be included or not (default = not).
- deleted '/etc' path in default settings - icons were never there anyway...
- ".desktop" file rectified again, this time to "Category=X-Graphic-Viewer;Graphics"; the menu entry will be only in Graphic submenu (no longer in Utility) and it's still compatible with Precise (in fact, from there I took the first part of that category name).
- "multiple instances prevention" fixed at last (hopefully).
- Added few checkboxes in settings to get control on filetypes of searched pictures.

First post updated.

Greetings!
Attachments
settings.png
screenshot
(31.38 KiB) Downloaded 972 times
[color=red][size=75][O]bdurate [R]ules [D]estroy [E]nthusiastic [R]ebels => [C]reative [H]umans [A]lways [O]pen [S]ource[/size][/color]
[b][color=green]Omnia mea mecum porto.[/color][/b]

Post Reply