• it/its

// the deer!
// plural deer therian ΞΈΞ”, trans demigirl
// stray pet with a keyboard
// i'm 20 & account is 18+!
name-color: #ebe41e
// yeah



cactus
@cactus

well i have good news and bad news.

the good news:

  • Swing still works the same way it always has
  • Kotlin serialization is almost as good to work with as serde
  • the Mastodon API documentation is way the hell better than Bluesky's
  • this right here is technically a non-webshit Mastodon client.

the bad news:

  • the Mastodon timeline defaults to including every reply sent by the people you follow, and only seeing replies to people you also follow is a Pleroma extension not supported (or at least not mentioned) by Mastodon itself. the idiomatic fediverse solution would be to just use that Pleroma-specific filter, include all the noise in the response from Mastodon, and tell users to move to an instance with better software, but that happens to suck
  • i have done some crimes with Kotlin delegates to get transparent persistence via the Java Preferences API. it is cool that i can, but it sucks that i did
  • the Swing default theme has a font size of 12px, which is indefensibly tiny, and it's surprisingly involved to fix that application-wide
  • BoxLayout and GridBagLayout are so clearly trying to be flexbox and CSS grid, but those hadn't been invented yet, so the APIs are all kinda worse. my kingdom for gap
  • at my day job i have adopted Conventional Commits to ensure that our commit history is easy to scan. i am compensating by putting absolute fucking nonsense in my commits here
    and i'm not joking
    82d5346 (HEAD -> canon) rest in piss, and not in the fun way
    bc27cc8 that technically works
    52a43d8 we do a medium amount of trolling
    83a0764 cock and ball torture
    028d1c3 gay sex
    
  • it's 2AM right now and i have a meeting at 8:30. oops !
  • links don't work in JLabels. you might not need a full HTML renderer for Mastodon posts, but you need links. as such i think it is time for this phase of this experiment to come to a close.

tune in over the weekend to see if i still care. if we're all very lucky, the thing i am trying to build might one day actually exist


cactus
@cactus

we are so fucking back. Java has rich text editing controls (it has two slightly different ones and the documentation doesn't explain why, but i'll take anything at this point) but you can just mark them as non-editable. you have to attach a HyperlinkListener to get working links but that's just

val postBody = JTextPane()
postBody.contentType = "text/html"
postBody.isEditable = false
postBody.text = post.htmlText
postBody.addHyperlinkListener {
    if (it.eventType == EventType.ACTIVATED) {
        Desktop.getDesktop().browse(it.url.toURI())
    }
}
syntax highlighting by codehost

You must log in to comment.

in reply to @cactus's post: