> write(1, "+-\33[7b+\33[25G", 12) = 12

This tells your terminal to draw a "+", followed by a "-" which should
then be repeated seven more times (\33[7b), followed by a "+".  So, nano
(by way of ncurses) gives your terminal a correct sequence of codes to
draw the stuff that should be drawn.  But apparently your terminal
(Putty) does not understand the \33[nb code and ignores it, resulting in
a garbled display.

Please see https://stackoverflow.com/questions/46507473/ncurses-in-
urxvt-does-not-print-repeating-characters.  And https://invisible-
island.net/ncurses/ncurses.faq.html#xterm_generic (the paragraphs after
the table).

The problem is in Putty: it says it is an xterm (or xterm-compatible),
but it isn't.

Solution: set your TERM to what it should be: putty.  Look in
/usr/share/terminfo/p/ for other possibilities.

-- 
You received this bug notification because you are a member of Ubuntu
Touch seeded packages, which is subscribed to nano in Ubuntu.
https://bugs.launchpad.net/bugs/1858293

Title:
  Missing repeated characters

Status in nano package in Ubuntu:
  New

Bug description:
  Nano 2.9.3
   Ubuntu 18.04.3 LTS - Linux 4.14.157-171 armv7l
   ARMv7 Processor rev 3 (v7l)

   Ubuntu 18.04.3 LTS - Linux 4.9.196-63 aarch64
  Amlogic S922X rev a (4 A73 + 2 A53)

  This issue is repeatable on more than 6 each different machines of the above 
configurations.
  I am using ssh via Putty to log in via terminal screen.
  I am using nano defaults. I have not changed anything nor do I open with any 
arguments. I use nano <filename> and it's not associated with any extension. It 
behaves the same for all files, even no extension files.
  Nano is not changing the file, it's just not displaying correctly. The 
characters are there and they save properly, they're just not visible on the 
terminal screen.

  Using WinSCP presents no issues as I am using my local Windows text
  editor.

  If I use vi to view the file there are no problems.
  If I use cat to view the file there are no problems.
  If I use tail to view the file there are no problems

  I do not experience this issue on:
  Nano 2.5.3
  Ubuntu 16.04.6 LTS - Linux 4.14.5-92 armv7l
  ARMv7 Processor rev 3 (v7l)

  If I take any file that has repeat characters such as:
  ############
  -----------------
                  |||||||

  Nano 2.9.3 will not display all of the continuous repeat characters in
  the row. For example:

  Copy and paste ############ is displayed as:
  #           <-- But end of line is correct
  If I copy that line from the file in nano editor and paste it into another 
non nano editor I get:
  #
  as the paste result

  This is the same for all different repeated characters.
  If I keyboard type ############################## nano will display it until 
nano is closed and then the same file is reopened. Then it's same as above, one 
# but end of line is correct.

  Pasting:
  #       +--------+      +--------+      +--------+      +--------+
  #       |        |      |        |      |        |      |        |
  # >CLK->|        |>CLK->|        |>CLK->|        |>CLK->|        |>CLK->
  # >CS ->|        |>CS ->|        |>CS ->|        |>CS ->|        |>CS ->
  # >DIN->|        |>DIN->|        |>DIN->|        |>DIN->|        |>DIN->
  #       |        |      |        |      |        |      |        |
  #       +--------+      +--------+      +--------+      +--------+

  into nano results in displayed:
  # +-+      +-+      +-+      +-+
  # | |      | |      | |      | |
  # >CLK->| |>CLK->| |>CLK->| |>CLK->| |>CLK->
  # >CS ->| |>CS ->| |>CS ->| |>CS ->| |>CS ->
  # >DIN->| |>DIN->| |>DIN->| |>DIN->| |>DIN->
  # | |      | |      | |      | |
  # +-+      +-+      +-+      +-+
  while nano is still open.
  Close the file and view in cat, vi or tail and it is show properly..

  Pasting:
  #       +--------+      +--------+      +--------+      +--------+
  #       |        |      |        |      |        |      |        |
  # >CLK->|        |>CLK->|        |>CLK->|        |>CLK->|        |>CLK->
  # >CS ->|        |>CS ->|        |>CS ->|        |>CS ->|        |>CS ->
  # >DIN->|        |>DIN->|        |>DIN->|        |>DIN->|        |>DIN->
  #       |        |      |        |      |        |      |        |
  #       +--------+      +--------+      +--------+      +--------+

  using vi editor
  then save file and open file in nano results in:
  # +-+      +-+      +-+      +-+
  # | |      | |      | |      | |
  # >CLK->| |>CLK->| |>CLK->| |>CLK->| |>CLK->
  # >CS ->| |>CS ->| |>CS ->| |>CS ->| |>CS ->
  # >DIN->| |>DIN->| |>DIN->| |>DIN->| |>DIN->
  # | |      | |      | |      | |
  # +-+      +-+      +-+      +-+

To manage notifications about this bug go to:
https://bugs.launchpad.net/ubuntu/+source/nano/+bug/1858293/+subscriptions

-- 
Mailing list: https://launchpad.net/~touch-packages
Post to     : touch-packages@lists.launchpad.net
Unsubscribe : https://launchpad.net/~touch-packages
More help   : https://help.launchpad.net/ListHelp

Reply via email to