![]() |
Qt 6.x
The Qt SDK
|
Public Member Functions | |
QMacMimeAny () | |
QString | utiForMime (const QString &mime) const override |
Returns the Mac UTI used for MIME type mime, or an empty string if this converter does not support converting from mime. | |
QString | mimeForUti (const QString &uti) const override |
Returns the MIME type used for Mac UTI uti, or an empty string if this converter does not support converting from uti. | |
QVariant | convertToMime (const QString &mime, const QList< QByteArray > &data, const QString &uti) const override |
Returns data converted from Mac UTI uti to MIME type mime. | |
QList< QByteArray > | convertFromMime (const QString &mime, const QVariant &data, const QString &uti) const override |
Returns data converted from MIME type mime to Mac UTI uti. | |
![]() | |
QUtiMimeConverter () | |
Constructs a new conversion object and adds it to the globally accessed list of available converters. | |
virtual | ~QUtiMimeConverter () |
Destroys a conversion object, removing it from the global list of available converters. | |
HandlerScope | scope () const |
bool | canConvert (const QString &mime, const QString &uti) const |
Returns true if the converter can convert (both ways) between mime and uti; otherwise returns false . | |
virtual QList< QByteArray > | convertFromMime (const QString &mime, const QVariant &data, const QString &uti) const =0 |
Returns data converted from MIME type mime to Mac UTI uti. | |
virtual QString | utiForMime (const QString &mime) const =0 |
Returns the Mac UTI used for MIME type mime, or an empty string if this converter does not support converting from mime. | |
virtual QString | mimeForUti (const QString &uti) const =0 |
Returns the MIME type used for Mac UTI uti, or an empty string if this converter does not support converting from uti. | |
virtual QVariant | convertToMime (const QString &mime, const QList< QByteArray > &data, const QString &uti) const =0 |
Returns data converted from Mac UTI uti to MIME type mime. | |
virtual int | count (const QMimeData *mimeData) const |
Returns the item count for the given mimeData. | |
Additional Inherited Members | |
![]() | |
enum class | HandlerScopeFlag : uint8_t { DnD = 0x01 , Clipboard = 0x02 , Qt_compatible = 0x04 , Qt3_compatible = 0x08 , All = DnD|Clipboard , AllCompatible = All|Qt_compatible } |
![]() | |
void | qRegisterDraggedTypes (const QStringList &types) |
Registers the given types as custom pasteboard types. | |
Definition at line 171 of file qutimimeconverter.mm.
|
inline |
Definition at line 173 of file qutimimeconverter.mm.
|
overridevirtual |
Returns data converted from MIME type mime to Mac UTI uti.
Note that Mac UTIs must all be self-terminating. The return value may contain trailing data.
All subclasses must reimplement this pure virtual function.
Implements QUtiMimeConverter.
Definition at line 213 of file qutimimeconverter.mm.
|
overridevirtual |
Returns data converted from Mac UTI uti to MIME type mime.
Note that Mac UTIs must all be self-terminating. The input data may contain trailing data.
All subclasses must reimplement this pure virtual function.
Implements QUtiMimeConverter.
Definition at line 200 of file qutimimeconverter.mm.
References QString::fromUtf8(), mime, qWarning, and ret.
Returns the MIME type used for Mac UTI uti, or an empty string if this converter does not support converting from uti.
All subclasses must reimplement this pure virtual function.
Implements QUtiMimeConverter.
Definition at line 192 of file qutimimeconverter.mm.
References QString::length(), QString::mid(), QString::replace(), QString::size(), and QString::startsWith().
Returns the Mac UTI used for MIME type mime, or an empty string if this converter does not support converting from mime.
All subclasses must reimplement this pure virtual function.
Implements QUtiMimeConverter.
Definition at line 183 of file qutimimeconverter.mm.