Kopher: a small (and probably the first) Gopher client for KaiOS - testers welcome

232 views
Skip to first unread message

Luxferre

unread,
Mar 25, 2023, 1:01:18 PM3/25/23
to comp.mobile.nokia.8110
Hi folks,

As you know, I have very little time to work on anything KaiOS-related, but when I got some, I decided to write a Gem... sorry, Gopher browser as a challenge to fit in this little amount of time.

Please check it out from this repo: https://git.sr.ht/~luxferre/Kopher - and make sure to read the README file.

It only works on KaiOS 2.5.x (and probably 1.0 but I didn't test it on 4044 yet) and is based upon the MozTCPSocket API, so requires the "privileged" level in the manifest. The UI is minimalistic, oldschool, opinionated and inspired by some really old WAP browsers. And the overall codebase is under 500 SLOC. Despite that, it supports history, dark/light theme switch, line wrapping toggle switch, up to 10 numbered bookmarks and customizable homepage. It also embeds two about: pages, one of them (about:kopher) is the default homepage (and an actual Gophermap) with useful links to get started in Gopherspace and another (about:help) is the quick help for controls.

Also, this is still v0.0.1, so lots of things might not work as expected. But this is why testers are more than welcome. My primary concerns are: dependency on Droid Sans Mono (I have absolutely no idea whether or not it's available on all 2.5.x devices, but I don't want to embed any standalone fonts in the app) and what to do with non-image binary types and how to correctly download them, or, rather, make KaiOS itself download them. So feel free to test out all the weird stuff and send your proposals here.

Have fun,
Luxferre

Farooq Karimi Zadeh

unread,
Mar 25, 2023, 3:23:15 PM3/25/23
to banana...@googlegroups.com

Nice work. Regarding downloading binaries, there is no way that KaiOS would download them itself. You have to download them yourself using the TCP API, save them in a blob and then save them in the storage.


May the Source be with you, Master Luxferre!

--
You received this message because you are subscribed to the Google Groups "comp.mobile.nokia.8110" group.
To unsubscribe from this group and stop receiving emails from it, send an email to bananahacker...@googlegroups.com.
To view this discussion on the web visit https://groups.google.com/d/msgid/bananahackers/f40e750d-3a50-42ca-8b8a-c4948827859fn%40googlegroups.com.

Luxferre

unread,
Mar 25, 2023, 6:07:46 PM3/25/23
to comp.mobile.nokia.8110
Thanks! By "downloading" I mean they are already stored in a blob by the client, just would like to reuse the existing file download mechanisms to transfer them from the blob onto the storage.

Farooq Karimi Zadeh

unread,
Mar 25, 2023, 6:12:52 PM3/25/23
to banana...@googlegroups.com

Yeah that's possible and the Storage APIs require Blob as far as I remember:


https://wiki.bananahackers.net/en/development/device-api/device-storage/create-new-file

Luxferre

unread,
Mar 26, 2023, 8:52:06 AM3/26/23
to comp.mobile.nokia.8110
Ok, I didn't want to use the Storage API but it looks like I had no choice, the default window.open() behavior was too weird for application/octet-stream type files.
The 0.0.2 version is now out, it handles the downloads to the root of the default storage (see all the changes in the README as well). Also, I tested the app on all KaiOS phones I have (even Doro 7060 and Alcatel 4044O) and confirmed it doesn't work on 1.0 (for now) but improved the look on the sKai (which still has some weird bugs displaying images with window.open(), by the way). This was reflected in the README as well.

Luxferre

unread,
Mar 26, 2023, 3:38:37 PM3/26/23
to comp.mobile.nokia.8110
Updated Kopher to version 0.0.3 with a critical fix that allows to not default an empty selector field to the description if the host and port field are actually present.

Luxferre

unread,
Apr 1, 2023, 8:22:40 AM4/1/23
to comp.mobile.nokia.8110
Kopher 0.0.4 is out:

- when viewing plaintext type documents and turning on the wrapping mode with the key 6, they are run through a special algorithm to remove hard line wraps and width-justified spaces if they have any of those, so they are much more comfortable to view on this 25-character screen;
- the 8-type entries are not processed but just displayed as the telnet:// URIs now.

Luxferre

unread,
Apr 3, 2023, 5:39:05 AM4/3/23
to comp.mobile.nokia.8110
Kopher 0.0.5 update:

- you can now share the current URL using standard KaiOS share activity by pressing * and Call key (if you choose Bluetooth, the URL is send as a vCard file);
- in the information lines of Gophermaps, basic ANSI terminal coloring/styling is now supported (still in testing phase).

Luxferre

unread,
Apr 3, 2023, 1:06:18 PM4/3/23
to comp.mobile.nokia.8110
Kopher 0.0.6 (phone restart recommended after update):

- some improvements with ANSI terminal styling;
- view activity handler for gopher:// URLs (doesn't work from browser anyway because the schemes there are hardcoded and not passed to the activities properly, but should work for any other apps that do create these activities).

Farooq Karimi Zadeh

unread,
Apr 4, 2023, 3:44:28 AM4/4/23
to banana...@googlegroups.com

I've heard these activities work in 8000 and 6300.

Farooq Karimi Zadeh

unread,
Apr 4, 2023, 4:24:47 AM4/4/23
to banana...@googlegroups.com

I meant in browser.

Reply all
Reply to author
Forward
0 new messages