How to do post-4.0 icon naming changes

David Faure faure at kde.org
Mon Jan 21 09:26:51 GMT 2008


On Sunday 20 January 2008, Hans Meine wrote:
> On Dienstag 15 Januar 2008, David Faure wrote:
> > > (c), if performed as pure renaming without further measures to be taken,
> > > will break icons that work fine in 4.0. Which is probably not a good idea
> > > in terms of backwards compatibility. Apart from that, benefits galore.
> > >
> > > My personal preference would be (c) with some smart mechanism that shows
> > > icons when they are requested but not in the icon dialog or among valid
> > > icons in the theme folder... that would need some smart-ass code
> > > solution, though. (Ideas on how to do that are highly appreciated!)
> >
> > It doesn't need to be "smart-ass" :), but a simple mapping file could be
> > read by KIconLoader in order to keep behavior compatibility indeed.
> > Just a file with
> > kde-4.0-icon-name kde-4.1-icon-name
> > kde-4.0-icon-name kde-4.1-icon-name
> > ...
> > and a QHash<QString,QString> in the code.
> 
> Note that this would only work if you update the code and all icon themes 
> along.

Solution: the mapping file should be part of the icon theme.

-- 
David Faure, faure at kde.org, sponsored by Trolltech to work on KDE,
Konqueror (http://www.konqueror.org), and KOffice (http://www.koffice.org).




More information about the kde-core-devel mailing list