2021-04-06 23:10:57 +08:00
|
|
|
#ifndef UTILS_H
|
|
|
|
#define UTILS_H
|
|
|
|
|
|
|
|
class QByteArray;
|
|
|
|
class QString;
|
|
|
|
|
|
|
|
enum FileEncodingType {
|
|
|
|
etAuto,
|
|
|
|
etUTF8,
|
|
|
|
etAscii,
|
|
|
|
etAnsi,
|
|
|
|
etUTF8Bom
|
|
|
|
};
|
|
|
|
|
|
|
|
FileEncodingType GetFileEncodingType(const QByteArray& content);
|
|
|
|
|
2021-04-07 21:13:15 +08:00
|
|
|
bool isTextAllAscii(const QString& text);
|
2021-04-06 23:10:57 +08:00
|
|
|
|
|
|
|
#endif // UTILS_H
|