Version: 4.4.1 (KDE 4.4.1) (using 4.4.1 (KDE 4.4.1), 4.4.1-6.fc12 Fedora) Compiler: gcc OS: Linux (x86_64) release 2.6.32.10-92.fc12.x86_64 I started kwrite with the file to open as the parameter. Kwrite opened with the file loaded but I could not edit the file: can't insert characters or remove any. When I opened the file from the menu, it displays a dialog that says I'm opening a binary file and that saving it will result in a corrupt file. 1) This dialog should also appear when I open the file from the command line. 2) Is it normal I can't edit the file because it's binary? I don't think kwrite should prevent me from doing that?
Same thing happens in kate, but I assume this is to be expected.
(In reply to comment #0) > 2) Is it normal I can't edit the file because it's binary? I don't think kwrite > should prevent me from doing that? Yes it should, editing a binary file with a _plain text_ editor doesn't make the slightest sense. Kate is not a hex editor, you can use okteta for that.
The file I was trying to open was a text file with a few binary characters in it. Kwrite should tell me that it's binary and that I can only view the file. The open dialog warns me about the file being binary and says that it will get corrupted if I save it. But I can't change the file. So either the dialog should say that the file is read-only because it's binary, or keep the current message and allow me to shoot myself in the foot by changing it.
You can turn off read-only: tools -> read only mode. Maybe the wording on the warning can be better?
Yes, I think the wording could be changed to say that the file is currently opened read-only because it's binary and that you can turn it read-write in the tools menu. The warning should also appear when kwrite is started with the filename as a parameter and not only when the file is opened using the file-> open dialog. Maybe the title bar (or status bar) could say [read-only] when read-only mode is on like the way it also says [modified] when there are unsaved changes?
*** This bug has been marked as a duplicate of bug 154897 ***