Browse Source

Merge pull request #5500

crypto-universe (1):
      feat(chatfom): make magnet links clickable
reviewable/pr5504/r1
sudden6 7 years ago
parent
commit
49507d76d8
No known key found for this signature in database
GPG Key ID: 279509B499E032B9
  1. 1
      src/chatlog/textformatter.cpp

1
src/chatlog/textformatter.cpp

@ -90,6 +90,7 @@ static const QVector<QRegularExpression> URI_WORD_PATTERNS = { @@ -90,6 +90,7 @@ static const QVector<QRegularExpression> URI_WORD_PATTERNS = {
QRegularExpression(QStringLiteral(R"((?<=^|\s)\S*(tox:[a-zA-Z\d]{76}))")),
QRegularExpression(QStringLiteral(R"((?<=^|\s)\S*(mailto:\S+@\S+\.\S+))")),
QRegularExpression(QStringLiteral(R"((?<=^|\s)\S*(tox:\S+@\S+))")),
QRegularExpression(QStringLiteral(R"((?<=^|\s)\S*(magnet:[?]((xt(.\d)?=urn:)|(mt=)|(kt=)|(tr=)|(dn=)|(xl=)|(xs=)|(as=)|(x.))[\S| ]+))")),
};

Loading…
Cancel
Save