summaryrefslogtreecommitdiff
path: root/src/ui/linkinfo.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/ui/linkinfo.c')
-rw-r--r--src/ui/linkinfo.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/ui/linkinfo.c b/src/ui/linkinfo.c
index 72d76678..46aa6663 100644
--- a/src/ui/linkinfo.c
+++ b/src/ui/linkinfo.c
@@ -100,8 +100,12 @@ void infoText_LinkInfo(const iGmDocument *doc, iGmLinkId linkId, iString *text_o
100 appendRange_String(text_out, (iRangecc){ constBegin_String(url), comma }); 100 appendRange_String(text_out, (iRangecc){ constBegin_String(url), comma });
101 } 101 }
102 else if (scheme != gemini_GmLinkScheme) { 102 else if (scheme != gemini_GmLinkScheme) {
103 const size_t maxDispLen = 300;
103 appendCStr_String(text_out, scheme == file_GmLinkScheme ? "" : globe_Icon " "); 104 appendCStr_String(text_out, scheme == file_GmLinkScheme ? "" : globe_Icon " ");
104 appendCStrN_String(text_out, cstr_String(url), iMin(500, size_String(url))); 105 appendCStrN_String(text_out, cstr_String(url), iMin(maxDispLen, size_String(url)));
106 if (size_String(url) > maxDispLen) {
107 appendCStr_String(text_out, "...");
108 }
105 } 109 }
106 else { 110 else {
107 appendCStr_String(text_out, "\x1b[1m"); 111 appendCStr_String(text_out, "\x1b[1m");