![]() |
Qt 6.x
The Qt SDK
|
\inmodule QtWidgets More...
#include <qfileiconprovider.h>
Public Member Functions | |
QFileIconProvider () | |
Constructs a file icon provider. | |
~QFileIconProvider () | |
Destroys the file icon provider. | |
QIcon | icon (IconType type) const override |
\reimp | |
QIcon | icon (const QFileInfo &info) const override |
\reimp | |
![]() | |
QAbstractFileIconProvider () | |
Constructs a file icon provider. | |
virtual | ~QAbstractFileIconProvider () |
Destroys the file icon provider. | |
virtual QIcon | icon (IconType) const |
Returns an icon set for the given type, using the current icon theme. | |
virtual QIcon | icon (const QFileInfo &) const |
Returns an icon for the file described by info, using the current icon theme. | |
virtual QString | type (const QFileInfo &) const |
Returns the type of the file described by info. | |
virtual void | setOptions (Options) |
Sets options that affect the icon provider. | |
virtual Options | options () const |
Returns all the options that affect the icon provider. | |
Additional Inherited Members | |
![]() | |
enum | IconType { Computer , Desktop , Trashcan , Network , Drive , Folder , File } |
\value Computer The icon used for the computing device as a whole \value Desktop The icon for the special "Desktop" directory of the user \value Trashcan The icon for the user's "Trash" place in the desktop's file manager \value Network The icon for the “Network Servers” place in the desktop's file manager, and workgroups within the network \value Drive The icon used for disk drives \value Folder The standard folder icon used to represent directories on local filesystems \value File The icon used for generic text file types More... | |
enum | Option { DontUseCustomDirectoryIcons = 0x00000001 } |
\value DontUseCustomDirectoryIcons Always use the default directory icon. More... | |
![]() | |
QAbstractFileIconProvider (QAbstractFileIconProviderPrivate &dd) | |
![]() | |
QScopedPointer< QAbstractFileIconProviderPrivate > | d_ptr |
\inmodule QtWidgets
The QFileIconProvider class provides file icons for the QFileSystemModel class.
Definition at line 18 of file qfileiconprovider.h.
QFileIconProvider::QFileIconProvider | ( | ) |
Constructs a file icon provider.
Definition at line 100 of file qfileiconprovider.cpp.
|
default |
Destroys the file icon provider.
\reimp
Reimplemented from QAbstractFileIconProvider.
Definition at line 148 of file qfileiconprovider.cpp.
References QFileInfo::absoluteFilePath(), d, info, QFileInfo::isDir(), QFileInfo::isFile(), QIcon::isNull(), QFileSystemEntry::isRootPath(), QFileInfo::isSymLink(), QStyle::SP_DirHomeIcon, QStyle::SP_DirIcon, QStyle::SP_DirLinkIcon, QStyle::SP_DriveCDIcon, QStyle::SP_DriveFDIcon, QStyle::SP_DriveHDIcon, QStyle::SP_DriveNetIcon, QStyle::SP_FileIcon, and QStyle::SP_FileLinkIcon.
\reimp
Reimplemented from QAbstractFileIconProvider.
Definition at line 115 of file qfileiconprovider.cpp.
References QAbstractFileIconProvider::Computer, d, QAbstractFileIconProvider::Desktop, QAbstractFileIconProvider::Drive, QAbstractFileIconProvider::File, QAbstractFileIconProvider::Folder, QAbstractFileIconProvider::Network, QStyle::SP_ComputerIcon, QStyle::SP_DesktopIcon, QStyle::SP_DirIcon, QStyle::SP_DriveHDIcon, QStyle::SP_DriveNetIcon, QStyle::SP_FileIcon, QStyle::SP_TrashIcon, and QAbstractFileIconProvider::Trashcan.