💾 Archived View for auragem.letz.dev › techlog › 20240510.gmi captured on 2024-05-26 at 14:39:58. Gemini links have been rewritten to link to archived content
View Raw
More Information
⬅️ Previous capture (2024-05-10)
-=-=-=-=-=-=-
2024-05-10 Profectus Beta 1.1: Removed WebP Support
I have removed libwebp support at the request of a user. This is temporary until I can make webp fully optional and provide two different versions of profectus with and without webp. It is also good to provide this option because libwebp may not be preferred for users that care about security vulnerabilities (libwebp has had security problems in the past).
I have modified the docs to make it clearer what dependencies need to be installed to run profectus on Linux, and have provided the command to install them on Fedora and Debian/Ubuntu.
Lastly, I have changed the minimum required golang version to build profectus to 1.21.9, which should help with those who want to build golang but install go from their package managers.
You can download Profectus here:
Profectus Homepage
Precompiled Binaries
Differences Between Lagrange and Profectus
Because one of Profectus' goals was to be an alternative to Lagrange, it is only natural to assume that Profectus is meant to mimic Lagrange as much as possible.
However, while the overall style of Profectus is very similar to Lagrange, there are also some important differences that I view as general improvements over Lagrange. The goal is not to entirely mimic Lagrange, but to compete by making improvements.
Differences
- Input prompts in Profectus are attached to the page rather than the window. This means you can switch tabs without losing what you've typed in input prompts. In Lagrange, input prompts are a popup that is attached to the window, and you cannot switch tabs or have multiple inputs open at once, which makes copying and pasting text between tabs and inputs harder.
- Profectus has support for animated images, including apng, jxl, gif, and avif. Lagrange does not.
- Profectus supports the Scroll protocol, but does not support Gopher (yet). Lagrange supports Gopher, but does not support the Scroll protocol.
- Profectus provides more themes out of the box that mimic other browsers, like Firefox, Chrome, Kristall, Castor, and Lagrange. Theme files are implemented in fairly simple json files and it is very easy to create your own by copying one of them into a new json file. Profectus will auto-detect that theme, and you can switch to it with Alt+T.
- Profectus has more animations than Lagrange.
- Profectus will pipe videos into mpv, ffplay, or vlc by default if one of those programs are installed. Lagrange needs to be configured to do this in a file that can only be found by scouring the large Help documentation.
- I believe Profectus has a more powerful theming system, although one cannot use everything in the theming files quite yet. For example, you can place the tabs above the navigation/address bar in the theming system. You can also round buttons, textboxes, and panels in Profectus.
- The New tab page is quite different on Profectus.
- Profectus has more advanced document-rendering in that it does not try to convert everything to gemtext to be rendered but can easily implement different rendering for different document formats. An example of this is the CSV renderer in Profectus.
- Because Profectus is a Scroll browser with support for Gemini, and scrolltext is currently a superset of gemtext, many of the internal documentation can use list nesting and other features that cannot be used in gemtext.
- Smooth scrolling in Profectus doesn't glide as much. In Lagrange there is more (imo, too much) glide.
- The DPI and GUI scaling are handled differently in Profectus than in Lagrange.
Not Finished or Buggy in Profectus
- No text selection.
- Font rendering is far inferior - no fallback fonts means one cannot get emojis mixed with other text. Also, no fribidi yet.
- You cannot move the cursor in input text boxes yet, and there is no multiline textbox.
- Gemini subscriptions have not been implemented yet. Neither have bookmarks or a history page.
- Certificate management is not there yet.
- Profectus lacks a lot of settings and UI customization (particularly fonts and font sizes)
- TOFU has not been implemented yet.
- I have not put any work into trying to compile and run Profectus on mobile systems like Android or iOS.
- There's no AppImage, Snap, or other package files yet.
- Buggy mp3 playing.
- CSV document rendering can be very slow and might freeze the application on very long CSV documents. I am still looking into how to fix this.
Similarities
- Same fonts for UI and the document - Roboto and Iosevka.
- Font sizes are very similar by default.
- Heading colors for many of the themes were based on Lagrange's heading colors. Profectus does allow customization of heading colors in the theming system.
- General UI elements, like the outline sidebar and the topbar and tabbar.
- Profectus has a Lagrange theme that tries to exactly match much of the theming of Lagrange.
- They are both based on SDL and they are both tabbed Gemini browsers.
- They both support Nex and Spartan
- They both can stream music (wave, flac, ogg, and mp3). Profectus' mp3 playing can sometimes be buggy, however.
Why I Used Golang
Using Golang wasn't just for maintainability, it was also used both for code readability and so I could get something done very quickly. C lacks proper strings and a bunch of other things are missing from its standard library that it would have added months to the development of this project.
Rust is significantly different in that it requires basically learning the language from the ground-up again because of its very picky, but safe, borrow-checker. It would have added at least an additional month in learning the language and figuring out how to port my GUI code over to it.
C++ is awful and I will never use it for the rest of my life. I don't think I need to say why. It takes the worst of all languages and sticks them all together, and piles its own awful things right on top. The same can be said for Pythin, which is not compiled but interpreted, and its concurrency and threading support are lackluster.
Odin is a great language, and it is the most similar to Golang in syntax, but it is not garbage collected, and has a more powerful and easier to use foreign interface system and a more powerful allocator system than Golang. Unfortunately, Odin doesn't have a TLS library. Odin is what I originally wrote the GUI code in, but I ported it over to Golang because Odin lacked a TLS library. The port was quite simple because Odin and Golang are already quite similar to each other and have many things, particularly stirng manipulation, in their standard library. Porting the GUI code to Rust, C++, or C would have taken a long time and much hair-pulling. The hardest part about Golang is trying to interface with C libraries, and doing so in a way that is cross-platform. This makes it harder to bring in C libraries, but it also provides an incentive for me to not bring in too many dependencies too.
The idiosyncracies of Golang are quite annoying, and I'm frequently frustrated by the decisions the Golang developers make, but it's better than C for me. At least Golang is open source. However, I may move to a different language in the future, but it won't be until after the stable 1.0 release.