bugGNU nano - Bugs: bug #54978, <Backspace> sometimes fails...

 
 

You are not allowed to post comments on this tracker with your current authentication level.

bug #54978: <Backspace> sometimes fails to work in help viewer and/or file browser

Submitted by:  David Lawrence Ramsey <dolorous>
Submitted on:  Wed 07 Nov 2018 12:39:02 AM UTC  
 
Severity:  2 - Minor Status:  Fixed
Assigned to:  Benno Schulenberg <bens> Open/Closed:  Closed

( Jump to the original submission)

Wed 07 Nov 2018 07:39:29 PM UTC, comment #6: 

No problem.

You have a point on Backspace.  However, as for hypothetical problems' not being problems... in terms of design, they most certainly can be.  But this isn't the place to discuss that further.

David Lawrence Ramsey <dolorous>
Project Member
Wed 07 Nov 2018 07:31:49 PM UTC, comment #5: 

Thanks for confirming.

Fixed in git, commits 5f6f8a80 and 03d10941.

(The function of <Backspace> in viewer and browser is unlikely to change.  A hypothetical problem is no problem.)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Wed 07 Nov 2018 06:49:50 PM UTC, comment #4: 

Your patch makes Backspace work in the file browser in xterm, urxvt, and the Linux console, so everything works properly with those terminals.

It has no effect on the others, which are still broken (as you point out, because my Backspace key generates ^?).  Binding DEL_CODE in the help viewer and file browser should fix it, since I've done that locally when trying to figure this problem out, and it does solve the problem on the other terminals.

As for adding a "case DEL_CODE" in help.c and browser.c, that may be easier, but it will also add a potential problem if someone later changes the binding of Backspace in either the help viewer or file browser.

David Lawrence Ramsey <dolorous>
Project Member
Wed 07 Nov 2018 04:56:00 PM UTC, comment #3: 

Hmm.  Why your <Backspace> key generates ^? is a mystery to me, but the same is the case on FreeBSD and NetBSD (and maybe others), so to make this work there too, this additional line is needed:

  add_to_sclist(MHELP|MBROWSER, "Bsp", DEL_CODE, do_page_up, 0);

(I don't like to add such lines, but it can't be helped.  Or... the alternative is to add a "case DEL_CODE" in help.c and browser.c.  Hmmm... Maybe that is better: it doesn't burden the main shortcut checking code.)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Wed 07 Nov 2018 03:47:01 PM UTC, comment #2: 

Please try the attached patch.

(file #45379)

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Wed 07 Nov 2018 03:30:52 PM UTC, comment #1: 

For me, <Backspace> still always pages up in the help viewer, on xfce4-terminal, xterm, and urxvt.  It's just in the file browser that <Backspace> fails to scroll a page back.

Bug exists since version 2.9.2.  The offending commit is 8581e702.

Benno Schulenberg <bens>
Project AdministratorIn charge of this item.
Wed 07 Nov 2018 12:39:02 AM UTC, original submission:  

Currently, in git 7ee07af0, Backspace is supposed to act as PageUp in both the help viewer and the file browser.  However, this is not actually the case in all terminals.

In xterm, urxvt, and the Linux console, Backspace acts as PageUp in the help viewer, as it should.  In the file browser, nano displays "Unbound key" when Backspace is pressed.

In rxvt, xfce4-terminal, and KDE5's Konsole, nano displays "Unbound key: ^?" when Backspace is pressed in either the help viewer or the file browser.

David Lawrence Ramsey <dolorous>
Project Member

 

Depends on the following items: None found

Items that depend on this one: None found

 

Carbon-Copy List
  • -email is unavailable- added by bens (Posted a comment)
  • -email is unavailable- added by dolorous (Submitted the item)
  •  

    Do you think this task is very important?
    If so, you can add your encouragement to it.
    This task has 0 encouragements so far.

    Only logged-in users can vote.

     

     

     

    Follow 7 latest changes.

    Date Changed by Updated Field Previous Value => Replaced by
    2018-11-12 bens Open/ClosedOpen => Closed
    2018-11-07 bens StatusIn Progress => Fixed
    2018-11-07 bens Attached File- => Added 0001-bindings-Bsp-should-not-be-bound-to-do_backspace-in-.patch, #45379
        StatusNone => In Progress
    2018-11-07 bens Severity3 - Normal => 2 - Minor
        Assigned toNone => bens
        SummaryBackspace sometimes fails to work in help viewer and/or file browser => <Backspace> sometimes fails to work in help viewer and/or file browser

    Back to the top


    Powered by Savane 3.5