static
| 47 | |
| 48 | // static |
| 49 | bool isPostscriptFile(const QString& fileName) |
| 50 | { |
| 51 | QFile theFile(fileName); |
| 52 | if (theFile.open(QIODevice::ReadOnly)) { |
| 53 | QByteArray ba = theFile.peek(4); |
| 54 | if (ba.startsWith("%!PS")) |
| 55 | return true; |
| 56 | } |
| 57 | return false; |
| 58 | } |
| 59 | |
| 60 | } // namespace Document |
| 61 | } // namespace Tw |