<p></p>
<p>The behaviour of Geany is self consistent, if you move the cursor after the newline it goes to the start of the next line.  That means you need to have a visual next line after the last line for it to go to.</p>
<p>Also, irrespective of what POSIX says there are situations where files must not have a terminating newline (inline includes for example) so there needs to be a way of indicating the presence or absence of the last newline.  But its impossible for a mere editor to know if its a file with a terminating newline, or a file with an empty unterminated last line, so it shows the presence of a newline by showing a next line place for the cursor to go.</p>
<p>This is the behaviour of other proper modeless visual editors/IDEs, Mint Text Edit (a Gedit clone IIRC) and Eclipse being the two I have at hand and a quick peruse of the vscode docs suggests its the same.</p>

<p style="font-size:small;-webkit-text-size-adjust:none;color:#666;">—<br />You are receiving this because you are subscribed to this thread.<br />Reply to this email directly, <a href="https://github.com/geany/geany/issues/2727#issuecomment-758292585">view it on GitHub</a>, or <a href="https://github.com/notifications/unsubscribe-auth/AAIOWJ5US4QLQZR4T47BXW3SZODT5ANCNFSM4V6CSWTQ">unsubscribe</a>.<img src="https://github.com/notifications/beacon/AAIOWJ6XD4L3EFJSFN64BPLSZODT5A5CNFSM4V6CSWT2YY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOFUZKA2I.gif" height="1" width="1" alt="" /></p>
<script type="application/ld+json">[
{
"@context": "http://schema.org",
"@type": "EmailMessage",
"potentialAction": {
"@type": "ViewAction",
"target": "https://github.com/geany/geany/issues/2727#issuecomment-758292585",
"url": "https://github.com/geany/geany/issues/2727#issuecomment-758292585",
"name": "View Issue"
},
"description": "View this Issue on GitHub",
"publisher": {
"@type": "Organization",
"name": "GitHub",
"url": "https://github.com"
}
}
]</script>