Qt
Internal/Contributor docs for the Qt SDK. <b>Note:</b> These are NOT official API docs; those are found <a href='https://doc.qt.io/'>here</a>.
Loading...
Searching...
No Matches
QMacMimeUnicodeText Class Reference
+ Inheritance diagram for QMacMimeUnicodeText:
+ Collaboration diagram for QMacMimeUnicodeText:

Public Member Functions

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< QByteArrayconvertFromMime (const QString &mime, const QVariant &data, const QString &uti) const override
 Returns data converted from MIME type mime to Mac UTI uti.
 
- Public Member Functions inherited from QUtiMimeConverter
 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 int count (const QMimeData *mimeData) const
 Returns the item count for the given mimeData.
 

Additional Inherited Members

- Public Types inherited from QUtiMimeConverter
enum class  HandlerScopeFlag : uint8_t {
  DnD = 0x01 , Clipboard = 0x02 , Qt_compatible = 0x04 , Qt3_compatible = 0x08 ,
  All = DnD|Clipboard , AllCompatible = All|Qt_compatible
}
 

Detailed Description

Definition at line 334 of file qutimimeconverter.mm.

Member Function Documentation

◆ convertFromMime()

QList< QByteArray > QMacMimeUnicodeText::convertFromMime ( const QString & mime,
const QVariant & data,
const QString & uti ) const
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 390 of file qutimimeconverter.mm.

References QString::append(), QStringConverterBase::Default, ret, QStringConverter::Utf16, and QStringConverterBase::WriteBom.

+ Here is the call graph for this function:

◆ convertToMime()

QVariant QMacMimeUnicodeText::convertToMime ( const QString & mime,
const QList< QByteArray > & data,
const QString & uti ) const
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 370 of file qutimimeconverter.mm.

References QByteArray::first(), QString::fromUtf8(), qPrintable, qWarning, ret, str, and QStringConverter::Utf16.

+ Here is the call graph for this function:

◆ mimeForUti()

QString QMacMimeUnicodeText::mimeForUti ( const QString & uti) const
overridevirtual

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 362 of file qutimimeconverter.mm.

◆ utiForMime()

QString QMacMimeUnicodeText::utiForMime ( const QString & mime) const
overridevirtual

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 345 of file qutimimeconverter.mm.

References i, QString::indexOf(), QString::left(), and mime.

+ Here is the call graph for this function:

The documentation for this class was generated from the following file: