From 5ceb82d4e4b49f919caf156fa644360b6c66622a Mon Sep 17 00:00:00 2001 From: Juergen Spitzmueller Date: Sun, 24 May 2015 14:51:47 +0200 Subject: [PATCH] GuiAbout: Detect and provide links to trac Text in the form "bug #1234" is transformed to a link that points to the respective trac entry. --- src/frontends/qt4/GuiAbout.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/src/frontends/qt4/GuiAbout.cpp b/src/frontends/qt4/GuiAbout.cpp index 3c4e84fe8d..d2a69e9d7a 100644 --- a/src/frontends/qt4/GuiAbout.cpp +++ b/src/frontends/qt4/GuiAbout.cpp @@ -121,6 +121,11 @@ static QString release_notes() continue; } if (incomment) continue; + + // detect links to the tracker + line.replace(QRegExp("(bug )(\\#)(\\d+)*"), + "\\1\\3"); + // headings if (line.startsWith("!!!")) { if (inlist) { @@ -267,6 +272,7 @@ GuiAbout::GuiAbout(GuiView & lv) d->ui.versionLA->setText(version()); d->ui.buildinfoTB->setText(buildinfo()); d->ui.releasenotesTB->setHtml(release_notes()); + d->ui.releasenotesTB->setOpenExternalLinks(true); d->ui.creditsTB->setHtml(credits()); d->ui.tab->setUsesScrollButtons(false);