Skip to content
GitLab
Projects
Groups
Snippets
/
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in
Toggle navigation
Menu
Open sidebar
Games
KMuddy
Commits
faa01e04
Commit
faa01e04
authored
May 11, 2019
by
Tomas Mecir
Browse files
fix clickable links
parent
d48436bb
Changes
1
Hide whitespace changes
Inline
Side-by-side
libs/ctextchunk.cpp
View file @
faa01e04
...
...
@@ -1314,7 +1314,8 @@ QString chunkLink::toHTML (QString &)
void
chunkLink
::
insertToDocument
(
QTextCursor
&
cursor
,
QTextCharFormat
&
format
)
{
QTextCharFormat
linkformat
=
format
;
linkformat
.
setAnchor
(
true
);
linkformat
.
setAnchorHref
(
_target
);
QString
href
=
QString
(
_iscommand
?
"command"
:
"link"
)
+
" "
+
(
_toprompt
?
"prompt"
:
"send"
)
+
" "
+
_target
;
linkformat
.
setAnchorHref
(
href
);
if
(
linkformat
.
foreground
().
color
()
==
_chunk
->
startAttr
().
fg
)
linkformat
.
setForeground
(
linkColor
);
cursor
.
insertText
(
_text
,
linkformat
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment