Ticket #3245 (closed defect: fixed)

Opened 5 years ago

Last modified 5 years ago

mcview goto line is 0-based

Reported by: egmont Owned by: andrew_b
Priority: minor Milestone: 4.8.13
Component: mcview Version: master
Keywords: Cc:
Blocked By: Blocking:
Branch state: merged Votes for changeset: committed-master

Description

In mcview press F5 to go to a line. Type "1" (to go to the first line). You end up in the second line.

Apparently mcview assumes lines are numbered from 0. The common practice is to count line numbers from 1, even mcedit does so. So line 1 should be the topmost line, line 2 the second, etc. (line 0 would be nice to accept and treat as 1.)

On a related note, the F5 dialog says "Line number (decimal)". I'd personally remove that "decimal", I haven't seen anyone ever referring to line numbers in octal or hex, moreover, it's not there in mcedit's "Go to line" feature either.

Attachments

mc-3245-no-decimal-label.patch (17.2 KB) - added by egmont 5 years ago.
Remove label, update .po files too
mc-3245-line-number-off-by-one.patch (516 bytes) - added by egmont 5 years ago.
Make line numbers 1-based

Change History

Changed 5 years ago by egmont

Remove label, update .po files too

Changed 5 years ago by egmont

Make line numbers 1-based

comment:1 Changed 5 years ago by egmont

Fix attached. (.po files updated to avoid fuzzy translations and translator work)

comment:2 Changed 5 years ago by andrew_b

  • Owner set to andrew_b
  • Status changed from new to accepted
  • Branch state changed from no branch to on review
  • Milestone changed from Future Releases to 4.8.13

Branch: 3245_viwer_goto_line
Initial changeset:ecc4f84788eff00ec57af6fbaa3f6d349a848856

comment:3 Changed 5 years ago by andrew_b

  • Votes for changeset set to andrew_b
  • Branch state changed from on review to approved

comment:4 Changed 5 years ago by andrew_b

  • Status changed from accepted to testing
  • Votes for changeset changed from andrew_b to committed-master
  • Resolution set to fixed
  • Branch state changed from approved to merged

Merged to master: [3949e5597531dfff02b8fc98d807df43fe51a798].

git log --pretty=oneline 409d4b4..3949e55

comment:5 Changed 5 years ago by andrew_b

  • Status changed from testing to closed
Note: See TracTickets for help on using tickets.