• 1 Post
  • 4 Comments
Joined 7 months ago
cake
Cake day: April 20th, 2024

help-circle
  • satyrn@lemmy.worldOPtoLinux@lemmy.mlJanus, a simple text editor
    link
    fedilink
    arrow-up
    6
    ·
    edit-2
    7 months ago

    The binary editing is there in case a file of yours gets corrupted or if you just want to see the insides of a given file in a human readable way. I used to use windows and one of the things that got me into programming was the realization that all files were simply data on the inside, something I explored using windows notepad. As for gedit, I was previously using leafpad and so the binary editing is meant to be a step up from leafpad’s inability to show data, not gedit’s capable escape sequence system.


  • Primarily, I wanted to make a simple notepad editor, not a hex editor. Binary editing is a feature, but not the main purpose. Many other text editors use escape characters to mimic the way that hex editors edit text, and while this is a very rational solution, I wanted a simple but elegant solution that would allow full control while not adding in a lot of overhead, and I came up with this one. Every character is still distinguishable for the most part, but the main purpose was always to display it as legible text rather than hexadecimal.


  • satyrn@lemmy.worldOPtoLinux@lemmy.mlJanus, a simple text editor
    link
    fedilink
    arrow-up
    10
    arrow-down
    1
    ·
    7 months ago

    This was mainly because I don’t know C++ but I do know C.

    Outside of that, I generally sway more towards gtk apps then qt apps and I use Budgie, so it fits in with my desktop better. Gtk also seems to be more widely used than Qt on linux. And Qt seems to delegate more of its functionality to standalone libraries, which means more dependency tracking which I am very opposed to, whereas Gtk packages one library that encompasses most of the libraries functionality (although I don’t know enough about qt to be sure if this is the case).


  • satyrn@lemmy.worldOPtoLinux@lemmy.mlJanus, a simple text editor
    link
    fedilink
    arrow-up
    14
    ·
    edit-2
    7 months ago

    The main thing is that gtk3 is a little more stable and available for now. Gtk deprecates tons of functions seemingly at random, and I don’t want to have to constantly re-code my project as they deprecate things. As for availability, Gtk3 is shipped everywhere as 3.24 rather than different distros having different versions, gtksourceview4 is shipped on older distributions then gtksourceview5 (meaning more compatibility), and if I ever wanted to port to other operating systems Gtk4 would be much harder than 3. Finally, before the starting Janus I was under the impression that no gtk4 apps could be themed, but I have since learned that that is not the case. Knowing what I do now, once they iron out more of the kinks I will definitely port to gtk4, but first I want to make sure everything works well.

    As for binary editing, I took a very different approach to other editors. Most either convert the binary data to a code page (very confusing and nearly impossible to edit) or use escape characters, which is not a bad solution by any means but looks increasingly worse with the entropy of the data. I eventually came up with this approach, which I think maintains the simplicity of a notepad editor while allowing the functionality I meant to include.