Frederik Handberg's avatar
Frederik Handberg
npub1nj0c...2gqz
23 🇩🇰 Studying for a degree in Software Engineering while building fun projects and working freelance as a News Photographer 📷 I share my software projects, photos and videos from my work as a news photographer, and progress updates as I learn to sew garments. Basically, I just write about my hobbies. frederikhandberg.com
The chat app I am building using JavaFX and RMI is coming together nicely. Remember, it’s just a portfolio project, so I am not spending much time on the visual design. Functionality is the most important part of this project. I have now implemented a context menu that appears when the user right clicks on one of their messages. The context menu has two options: ‘Edit’ and ‘Delete’. image If the user clicks the “Edit” button, it brings up a new window where the user can edit their message. The textbox is quite small. It should expand in height depending on the amount of lines. I might change this at some point… image Lastly, there is a delete button. When clicked, it shows a confirmation window. image
Walled gardens are a stupid, but efficient way to lock in users. They are stupid because it’s a disgusting method of keeping users, but they’re efficient because they make it hard for users to escape. Nostr ensures that walled gardens can’t exist. If a client turns evil or goes dark, just switch to a different one. #Nostr is freedom.
Made quite a bit of progress for the chat application in terms of direct messaging and the UI. The user can now search for another user and click their username to create a chat between them. They can then begin to send messages to each other. There is a problem that happens when clicking the enter button on the keyboard for sending a message. For some reason, it is sending the same message twice. Not sure why. When clicking the "Send" button in the UI, it only sends the message once as expected. Since this is just a portfolio project, I am not sure how much time I want to spend fixing small bugs like the issue described above. Next step will be to get group chats working. Will add a button with a plus (+) icon, which will bring up a new window where the user can type a group name and then click "Create" button. This should then create the group and the creator can begin inviting users to the group. #dev #Java #JavaFX image View quoted note →
The police have cordoned off an area in downtown Horsens. #press #police
Making some progress on the chat application that I’m building using JavaFX and RMI. The alignment of some of the UI elements are a bit scuffed, but working on fixing it. I also need to add a button to create a group chat and figure out how I want to allow users to search and discover other users. I might just make it so that the search input can search for current conversations, but also search for all users in the system. Then the user just clicks on a user in the search list to start a conversation with them. In terms of group chats, I need to implement a list displaying all users in the group and their respective roles. In this list, the creator and admins should be allowed to remove members from the group and change their roles (ADMIN or MEMBER). Additionally, I should add an invite button. The idea is that only the creator and admins are allowed to invite users to the group. Something I forgot when I worked on authentication to create an account, was to always capitalize the first letter in first and last name before inserting the values into the database – but that’s an easy fix… And, I need to actually create the tables. Currently, only the `users` table has been implemented. #dev #Java #RMI image
Working on a JavaFX application as a portfolio project. It’s an instant messaging app. User authentication is now finished. Next step will probably be to implement a SceneManager class to centralize all the logic for switching windows. I will be using RMI to handle connections between clients, so I’ll need a class to create a registry on a port (`RMIServer`) and then another class that finds the registry and connects via the port (`RMIClient`). I don’t believe RMI is used often nowadays. Probably due to it being Java exclusive, so it’s pretty limited compared to using Sockets, since that works no matter which programming language. #dev #Java
Video captured yesterday from the structure fire on Præstemarksvej in Horsens 8700 #press
Fire in riding arena at Præstemarksvej in Horsens 8700. #press
The voice-to-text feature on ChatGPT is crazy good. It’s really impressive.
I want to get better at being bored. A lot of people have this thing where the second they feel bored, they grab their phone and scroll through social media. I’m definitely guilty of this too, and I really want to stop with this habit. It’s okay to be bored and it’s probably healthy as well, especially in terms of having a good attention span. Luckily, my attention span is not bad. I don’t have an issue with being focused for hours, but I do think my attention span could still be improved. Also, boredom seems to really improve creativity. I guess it’s because when we are bored, our mind gets a chance to just drift away and think without constant noise.