]> git.lyx.org Git - lyx.git/blobdiff - src/frontends/qt/GuiAbout.cpp
Allow compiling with Qt6
[lyx.git] / src / frontends / qt / GuiAbout.cpp
index b066106ad8e610188ca38e469854e2908745505b..d4173fae8b45e60d856c278431364aa2ec0c0a35 100644 (file)
@@ -59,7 +59,9 @@ static QString credits()
                        out << qt_("Please install correctly to estimate the great\namount of work other people have done for the LyX project.");
                } else {
                        QTextStream ts(&file);
+#if QT_VERSION < 0x060000
                        ts.setCodec("UTF-8");
+#endif
                        QString line;
                        do {
                                line = ts.readLine();
@@ -101,7 +103,9 @@ static QString release_notes()
                        out << qt_("Please install correctly to see what has changed\nfor this version of LyX.");
                } else {
                        QTextStream ts(&file);
+#if QT_VERSION < 0x060000
                        ts.setCodec("UTF-8");
+#endif
                        QString line;
                        bool incomment = false;
                        bool inlist = false;
@@ -123,8 +127,13 @@ static QString release_notes()
                                        continue;
 
                                // detect links to the tracker
+#if QT_VERSION < 0x060000
                                line.replace(QRegExp("(bug )(\\#)(\\d+)*"),
                                             "<a href=\"http://www.lyx.org/trac/ticket/\\3\">\\1\\3</a>");
+#else
+                               line.replace(QRegularExpression("(bug )(\\#)(\\d+)*"),
+                                            "<a href=\"http://www.lyx.org/trac/ticket/\\3\">\\1\\3</a>");
+#endif
 
                                // headings
                                if (line.startsWith("!!!")) {