Adding icon cache to kdelibs?

Rivo Laks rivolaks at hot.ee
Fri Jun 22 13:59:19 BST 2007


Ühel kenal päeval (reede 22 juuni 2007) kirjutas Lubos Lunak:
> On čt 21. června 2007, Rivo Laks wrote:
> > Ühel kenal päeval (neljapäev 21 juuni 2007) kirjutas Rex Dieter:
> > > Rivo, since an implementation of an icon cache already exists (gtk2),
> > > any interest in coordinating a common implementation?
> > >
> > > I ask selfishly, since I've been trying for ages to make icon handling
> > > "just work" for Fedora, but have been meeting with some resistance (ie,
> > > *every* icon-installing pkg currently must run/use
> > > gtk-update-icon-cache, which I think is utter silliness).  See also:
> > > http://fedoraproject.org/wiki/PackagingDrafts/ScriptletSnippets/iconcac
> > >he
> >
> > I don't think what I'm working on would be compatible with the GTK
> > implementation.
> > GTK implementation seems to be about putting all of icontheme's icons
> > into one file and then mmapping it so the icons would be shared between
> > apps (I might be wrong though since I'm not that familiar with gtk's
> > cache).
>
>  That is correct, AFAIK - the reasons for the gtk icon cache were that gtk
> for some reason wastes quite some memory and mmaping the icon data as
> shared memory helps. (BTW, your iconcache simply reading the data from
> QFile and not using mmap is final solution? If yes, it might make sense to
> measure its overhead.)

No, it's not final. I'll most likely use mmap. AFAIU the madvise() call you 
suggested requires mmap-ing as well.

Rivo




More information about the kde-core-devel mailing list