Bug 472751 - Insert Mode overwrites instead of inserting
Summary: Insert Mode overwrites instead of inserting
Status: RESOLVED INTENTIONAL
Alias: None
Product: okteta
Classification: Applications
Component: general (show other bugs)
Version: 0.26.12
Platform: Neon Linux
: NOR normal
Target Milestone: ---
Assignee: Friedrich W. H. Kossebau
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2023-07-28 15:48 UTC by Greg Lepore
Modified: 2023-07-28 16:42 UTC (History)
0 users

See Also:
Latest Commit:
Version Fixed In:
Sentry Crash Report:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Greg Lepore 2023-07-28 15:48:50 UTC
SUMMARY
Using Edit->Insert to insert values into a file overwrites the existing data at that location instead of inserting the values and "pushing" the existing data over.

This behavior may be intentional, but it seems to be at odds with other programs that use the term "insert".

***

STEPS TO REPRODUCE
1. Open file
2. Select Edit->Insert and choose Pattern or Random Data
3. Click Insert

OBSERVED RESULT
Pattern or random data is put into the file over existing data

EXPECTED RESULT
Pattern or random data is put into file before existing data

SOFTWARE/OS VERSIONS
Operating System: KDE neon 5.27
KDE Plasma Version: 5.27.6
KDE Frameworks Version: 5.108.0
Qt Version: 5.15.10
Kernel Version: 5.19.0-46-generic (64-bit)
Graphics Platform: X11
Processors: 12 × AMD Ryzen 5 2600 Six-Core Processor
Memory: 31.3 GiB of RAM
Graphics Processor: NVIDIA GeForce GTX 1650 SUPER/PCIe/SSE2
Comment 1 Friedrich W. H. Kossebau 2023-07-28 16:01:01 UTC
> This behavior may be intentional, but it seems to be at odds with other programs that use the term "insert".

Curious., which other programs shaped your expectations here?
Comment 2 Friedrich W. H. Kossebau 2023-07-28 16:07:26 UTC
Also, "Insert Mode" expression in the bug report title might hint that the existing "Overwrite Mode" feature had not yet been noticed, and the editor was in Overwrite mode for you when you experienced the unexpected?
Comment 3 Greg Lepore 2023-07-28 16:15:54 UTC
Ahh, yes that's it! I missed the Overwrite checkbox in the Edit menu, and the INS/OVR button at the bottom of the screen. 

Is Overwrite by default the usual setting for editors?

No worries, I'll change it in my profile and my issue goes away. 

Thanks.
Comment 4 Friedrich W. H. Kossebau 2023-07-28 16:42:16 UTC
Okay :)

> Is Overwrite by default the usual setting for editors?

Might depend on the type of data that is edited :) Text? Images? Spreadsheets? Audio? Videos?

In case of a hex editor when editing existing files many of those are in formats where data is bound to be at fixed offsets. So inserting is not that typical there, people rather often only twist existing bytes without changing the overall data layout. So the default was set to be Overwrite mode (unless starting with an empty file). Sadly there is no one-default-fits-everyone here?