#23 Files opened read only switch to r/w


Under HPUX version of Nedit 5.11 when you open a file
for viewing with -read switch or via the menu options,
and some other entity modifies the file after you
select the reload option from the menu you are put into
read/write mode. I think that a reload of a document
should honor the read only status of the original
before a reload.


  • Alexander Mai

    Alexander Mai - 2001-04-09
    • priority: 5 --> 3
  • Alexander Mai

    Alexander Mai - 2001-04-09

    Logged In: YES

    This seems to hold for our development version
    on other operating systems as well.
    Is this by chance a feature (as opposed to a bug) ...?

  • Steve LoBasso

    Steve LoBasso - 2001-04-09

    Logged In: YES

    No, this is a bug. If you start an editing session read-only
    from the command line,
    it should stay that way, no matter what happens to the file.

  • Steve LoBasso

    Steve LoBasso - 2001-04-09

    Logged In: YES

    There seems to be another issue that is similar.
    Open a binary file. If the "Too much binary data.." dialog
    appears click "View".
    At this point the file is opened read only, If the file
    permissions are changed a few times, the file is unlocked.
    This is quite bad since the original data is not available.

    This brings up a couple of issues:
    Should a user be able to unlock a file that was opened "nc
    -read x.c" or "nedit -read x.c" from the Preferences->Read
    Only menu?
    If the user locks a file from the Preferences->Read Only
    menu and then chooses Revert to Saved, should it remain

    It seems we have several read-only concepts:
    1. User selected read only from preferences menu. Easily
    2. File permissions read only. Must be changed from shell.
    3. Using -read on command line.
    4. Too much binary data that comes about in null
    substitution code. Must not be unlocked.

    We are maintaining these concepts in only two booleans,
    which is why information is getting lost.

  • Scott Tringali

    Scott Tringali - 2001-05-15
    • assigned_to: nobody --> slobasso
  • Scott Tringali

    Scott Tringali - 2001-05-15

    Logged In: YES

    Steve, I saw some code regarding this in CVS. Is it fixed,
    or should we beat on a bit more?

  • Eddy De Greef

    Eddy De Greef - 2001-05-15

    Logged In: YES

    I have tested it to some extent, and I still
    think that it has been "over-fixed". Not allowing
    the user to override the -read flag from the menu
    is not acceptable IMHO.
    It is almost like not allowing the user to change the
    language mode after using the -lm command line argument.

    I use the -read option very often to prevent
    accidental modifications, but it also happens
    frequently that I decide to edit the file anyhow.

    Forcing the user to close the window, figure out
    where that file was located, and reopen it without
    the -read flag is very user-unfriendly.

  • Steve LoBasso

    Steve LoBasso - 2001-10-12

    Logged In: YES

    I have a patch for this. If there are no complaints, I'll
    commit it to the main line on 10-15

  • Eddy De Greef

    Eddy De Greef - 2002-02-11

    Logged In: YES

    The patch has been committed and was improved later on.
    I suppose this can be closed.

  • Eddy De Greef

    Eddy De Greef - 2002-02-11
    • status: open --> closed-fixed

Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks