UI files, mass commit?

Allen Winter winter at kde.org
Thu Apr 16 22:44:11 BST 2009


On Thursday 16 April 2009 5:38:50 pm Christoph Feck wrote:
> Hi,
> 
> This is part of my "make KDE respect platform native layout" initiative :)
> 
> First, let me announce that kdelibs is now basically free of hard coded layout 
> values. If you find a dialog/ui/whatever in kdelibs that has odd layout, or 
> does not respect the values of the platform, please report. See my blog at 
> http://kdepepo.wordpress.com/ for a way to check.
> 
> Now I used a find/sed combo to remove all occurences of layoutfunction, 
> layoutdefaults, and pixmapfunction occurences in .ui files.
> 
> Basically, the diff removes things such as
> - <layoutdefault spacing="6" margin="11" />
> - <layoutfunction spacing="KDialog::spacingHint" 
> margin="KDialog::marginHint" />
> - <pixmapfunction></pixmapfunction>
> - <pixmapfunction>qPixmapFromMimeSource</pixmapfunction>
> 
> Regarding the layout values, these prevent layout classes to use the style's 
> layout values, for example, Oxygen has 4 pixels spacing, 6 pixels margin, and 
> removing those values from the .ui file makes the application respect those 
> values. On the other hand, removing these values disrespects the programmers 
> decision, and if these values had been chosen for a specific reason, that 
> could potentially be a problem.
> 
> Now my questions:
> 
> 1. If I would ever commit these removals, should this be done as a single 
> commit for the whole trunk/KDE tree, or as commits for individual modules, 
> applications, or even single files?
> 
My feeling is to do this on a module-by-module basis.

> 2. Regarding the pixmapfunction, I think this is obsolete with KDE4. Does 
> anyone know for sure? I see three references to things like
> - <pixmapfunction>SmallIcon</pixmapfunction>
> 
Don't know.

> 3. Objections?
> 
Nope.

I do wonder if Krazy should check for  layoutfunction, 
layoutdefaults, and pixmapfunction  in .ui files.. 
seems rather easy to check for these.

Do you want me to add this to the Krazy checker?


-- 
Allen Winter | allen at kdab.net | Software Engineer
KDAB (USA), LLC, a KDAB Group company
Tel. USA +1-866-777-KDAB(5322), Sweden (HQ) +46-563-540090
KDAB - Qt Experts - Platform-independent software solutions




More information about the kde-core-devel mailing list