Improved Gopher entry support
This commit is contained in:
@@ -18,7 +18,7 @@ The following features are already (fully or partially) supported in BFG.
|
||||
* [Nex](https://nex.nightfall.city/nex/info/specification.txt) protocol (`nex://` URLs)
|
||||
* [Spartan](https://portal.mozz.us/spartan/spartan.mozz.us/specification.gmi) protocol (`spartan://` URLs) with single-line text query support
|
||||
* [Gemini](https://geminiprotocol.net/docs/) protocol (`gemini://` URLs) with single-line custom input support
|
||||
* Gophermap rendering (entry types 0, 1, 3, 5, 7, 8, 9, i, h)
|
||||
* Gophermap rendering (almost all known entry types)
|
||||
* Single-line search query support for Gopher type 7 resources
|
||||
* UTF-8 support for text content
|
||||
* Basic history support (back/forward actions)
|
||||
|
||||
@@ -589,7 +589,17 @@ proc render_handler_gopher {prevurl rooturl path body textw} {
|
||||
0 -
|
||||
1 -
|
||||
5 -
|
||||
9 { # plain text, gophermap, binary
|
||||
g -
|
||||
I -
|
||||
: -
|
||||
; -
|
||||
< -
|
||||
d -
|
||||
p -
|
||||
s -
|
||||
P -
|
||||
X -
|
||||
9 { # plain text, gophermap, binary, image, sound...
|
||||
linkinsert $textw $prevurl $rooturl "$tscheme://$rhost:$rport/$rtype$rsel" $rdesc "" preformatter
|
||||
}
|
||||
7 { # gophermap with input
|
||||
@@ -613,7 +623,7 @@ proc render_handler_gopher {prevurl rooturl path body textw} {
|
||||
default {}
|
||||
}
|
||||
}
|
||||
} elseif {($gophertype eq 5) || ($gophertype eq 9)} {
|
||||
} elseif {($gophertype ne 0) && ($gophertype ne 3)} {
|
||||
$textw insert end $body preformatter
|
||||
} else {
|
||||
$textw insert end [textsanitize $body] preformatter
|
||||
|
||||
Reference in New Issue
Block a user