Difference between revisions of "Development/Tutorials/Icons"

Jump to: navigation, search
Line 5: Line 5:
 
  open("/usr/lib64/libkemoticons.so.4", O_RDONLY) = 3
 
  open("/usr/lib64/libkemoticons.so.4", O_RDONLY) = 3
 
  #
 
  #
 +
You see, a KDE application (in this case ktimetracker) does not open icon files or even look for them. However, it spawns a process to look for these icons:
 +
 +
linux-qgla:~/repos/kdepim/ktimetracker # strace -ffe open ktimetracker 2>&1 | grep icon
 +
open("/usr/lib64/libkemoticons.so.4", O_RDONLY) = 3
 +
[pid  3457] open("/root/.icons/DMZ/cursors/left_ptr", O_RDONLY) = -1 ENOENT (No such file or directory)
 +
[pid  3457] open("/root/.icons/DMZ/index.theme", O_RDONLY) = -1 ENOENT (No such file or directory)
 +
[pid  3457] open("/usr/share/icons/DMZ/cursors/left_ptr", O_RDONLY) = 10
 +
[pid  3457] open("/var/tmp/kdecache-root/icon-cache.kcache", O_RDWR|O_CREAT|O_CLOEXEC, 0666) = 10
 +
[pid  3457] open("/var/tmp/kdecache-root/kpc/kde-icon-cache.data", O_RDONLY|O_CLOEXEC) = 10
 +
[pid  3457] open("/var/tmp/kdecache-root/kpc/kde-icon-cache.index", O_RDONLY|O_CLOEXEC) = 10
 +
[...]

Revision as of 21:04, 27 August 2011

Template:Stub

Maybe you have already searched for yourself how a KDE application finds its icons. You will not be successful like this:

# strace -e open ktimetracker 2>&1 | grep icon
open("/usr/lib64/libkemoticons.so.4", O_RDONLY) = 3
#

You see, a KDE application (in this case ktimetracker) does not open icon files or even look for them. However, it spawns a process to look for these icons:

linux-qgla:~/repos/kdepim/ktimetracker # strace -ffe open ktimetracker 2>&1 | grep icon
open("/usr/lib64/libkemoticons.so.4", O_RDONLY) = 3
[pid  3457] open("/root/.icons/DMZ/cursors/left_ptr", O_RDONLY) = -1 ENOENT (No such file or directory)
[pid  3457] open("/root/.icons/DMZ/index.theme", O_RDONLY) = -1 ENOENT (No such file or directory)
[pid  3457] open("/usr/share/icons/DMZ/cursors/left_ptr", O_RDONLY) = 10
[pid  3457] open("/var/tmp/kdecache-root/icon-cache.kcache", O_RDWR|O_CREAT|O_CLOEXEC, 0666) = 10
[pid  3457] open("/var/tmp/kdecache-root/kpc/kde-icon-cache.data", O_RDONLY|O_CLOEXEC) = 10
[pid  3457] open("/var/tmp/kdecache-root/kpc/kde-icon-cache.index", O_RDONLY|O_CLOEXEC) = 10
[...]

KDE® and the K Desktop Environment® logo are registered trademarks of KDE e.V.Legal