SUMMARY In some cases it is common to work on files where a large portion of them is empty (e.g. working on filesystem dumps). Scrolling across these sections always takes time and risks skipping over some data. Tools like od and hexdump automatically skip sections of consecutive zeros for exactly this reason (though they are CLI tools where this is even more important). Okteta should learn a view setting which collapses large zero regions (maybe with a configurable threshold). STEPS TO REPRODUCE 1. Create large, mostly empty file (e.g. `dd if=/dev/zero...`) 2. Hide some important data throughout the file at random offsets (e.g. using okteta) 3. Open the file in okteta and try to rediscover the exact places where the data is OBSERVED RESULT It is very hard to find exactly where the non-zero segments in the file are. EXPECTED RESULT There should be an easy way to skip zero segments or a tool to help discover non-zero fragments. Some tools also offer visual/color representations of the data for exactly these purposes (with the added benefit of easily spotting repeating structures)
Thanks for the feature proposal and describing the motivation for it. I can see how this would be useful and good to have provided by Okteta. The current implementation of Okteta's data display is rather simple. Supporting such dynamic layout or custom styling will need some bigger work, so for now this work-flow support can only be added to the long-term plans. For sure display variations like format/syntax highlighting or dynamic wrapping (e.g. to support plain text linebreaks or as here proposed, folding ranges on certain conditions, have been pipe dreams of the Okteta author since the very start, but so far dared to try getting that done and always found something else to do :) Only ever got to some initial design/code drafts of highlighting or "map" scrollbar. For your use-case having persistent bookmarks might also be interesting? (sadly also just some experimental code/design drafts for now and not around the corner).
For your workflow needs, would some navigation shortcut to go to the next non-null byte also be interesting? Currently Okteta, being plain-string/characters-centric initially, supports going to begin/end of next "word" (Ctrl+Left/Right). So that could be changed to instead see "words" as anything non-null. Or, possibly better for muscle memory/consistency, having another (but which?) dedicated shortcut for such cursor move operations? Would you have seen something like this somewhere?
(In reply to Friedrich W. H. Kossebau from comment #1) > For your use-case having persistent bookmarks might also be interesting? > (sadly also just some experimental code/design drafts for now and not around > the corner). Probably not, the reproduction instructions (put something in the file and later find it) was just an example where one can easily see and understand the problem. In reality I do not know where the data will be and it might be in a completely different place on the next start (or move, etc). (In reply to Friedrich W. H. Kossebau from comment #2) > For your workflow needs, would some navigation shortcut to go to the next > non-null byte also be interesting? Yes, that would remove 90% of the current frustration. Another thing which would make this better is a visual representation like here: https://github.com/FireyFly/pixd (e.g. as a tool in the sidebar, and clicking on a point would take you to that offset)
Git commit 54ef8aa595b73c1eea7c1467e9b5ff8710085774 by Friedrich W. H. Kossebau. Committed on 24/03/2025 at 15:06. Pushed by kossebau into branch '0.26'. Okteta gui: support navigation to non-zero bytes range boundaries * following the logic & behaviour with text words * using hard-coded Ctrl + Alt + Left/Right for now M +88 -0 gui/controller/keynavigator.cpp M +2 -0 gui/controller/keynavigator.hpp https://invent.kde.org/utilities/okteta/-/commit/54ef8aa595b73c1eea7c1467e9b5ff8710085774