pockethub / PocketHub

PocketHub Android App
Apache License 2.0
9.39k stars 3.47k forks source link

Empty file should show zero line count #1249

Open arthur-star opened 4 years ago

arthur-star commented 4 years ago

Description

Empty file should show zero line count

Versions and device

Steps to Reproduce

  1. open an empty file -- for example

    https://github.com/arthur-star/Empty-demo/blob/master/zero-line

  2. the line count shows one, not zero

Actual behaviour

the line count shows one

Expected behaviour

the line count shows zero

Meisolsson commented 4 years ago

I will try to fix this at a later point. The reason why it shows one line is that we are using the same library for editing and displaying code so I guess that they "add" one line so that you would have something to type on. We do set it to read only, but yeah.

I have been looking at alternatives but haven't found any good ones.