MCPcopy Create free account
hub / github.com/KDE/kdevelop / modeForMimetype

Method modeForMimetype

kdevplatform/interfaces/isourceformatter.cpp:139–148  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

137}
138
139QString SourceFormatterStyle::modeForMimetype(const QMimeType& mime) const
140{
141 const auto mimeTypes = this->mimeTypes();
142 for (const auto& item : mimeTypes) {
143 if (mime.inherits(item.mimeType)) {
144 return item.highlightMode;
145 }
146 }
147 return QString();
148}
149
150void SourceFormatterStyle::copyDataFrom(const SourceFormatterStyle& other)
151{

Callers 2

updatePreviewMethod · 0.80
initPreviewMethod · 0.80

Calls 2

mimeTypesMethod · 0.95
QStringClass · 0.70

Tested by

no test coverage detected