[Qt-creator] Customising file type icons shown in File system and Projects view

Ziller Eike Eike.Ziller at digia.com
Wed Jul 10 09:22:09 CEST 2013


coreplugin/fileiconprovider.cpp:

     // Get icon from OS.
    if (HostOsInfo::isWindowsHost() || HostOsInfo::isMacHost())
        return QFileIconProvider::icon(fileInfo);

    // File icons are unknown on linux systems.
    return (fileInfo.isDir()) ?
           QFileIconProvider::icon(fileInfo) :
           d->m_unknownFileIcon;


I suppose that code might not be aligned to reality anymore (it's certainly old code), so you could try what happens if you remove the special handling for !win && !mac

Br, Eike

On 09.07.2013, at 18:46, Peter Pearson <peter at thefoundry.co.uk> wrote:

> Hi,
> 
> Is there any way to customise what icons are shown for particular file 
> types in the File System and Project views?
> 
> They don't seem to take from the system settings (Gnome 2 in my case) or 
> the Qt Creator Environment MIME Types.
> 
> I'd basically like to see .txt and .py files with different icons than 
> the standard "it's just a generic file" icon, and have other extensions 
> match .cpp/.c icons.
> 
> Is this something that's exposed?
> 
> Thanks,
> Peter Pearson
> _______________________________________________
> Qt-creator mailing list
> Qt-creator at qt-project.org
> http://lists.qt-project.org/mailman/listinfo/qt-creator

-- 
Eike Ziller, Senior Software Engineer - Digia, Qt
 
Digia Germany GmbH, Rudower Chaussee 13, D-12489 Berlin
Geschäftsführer: Mika Pälsi, Juha Varelius, Anja Wasenius
Sitz der Gesellschaft: Berlin, Registergericht: Amtsgericht Charlottenburg, HRB 144331 B




More information about the Qt-creator mailing list