#955 horiz scroll window, place caret at left, it disappears


When the text is scrolled completely to the left, and the caret is placed to the left of the first character, the caret blinks as expected.
When the text is scrolled to the right and the caret is placed to the left of the first visible character, the caret disappears.

Steps to reproduce
Edit a text file
click on the horizontal scroll bar to cause the text to scroll so that, say, column 10 is the first visible column at the left edge of the window
click on a row of text
use the left arrow key to move the caret closer and closer to the left edge
when the caret moves to the left of the left-most glyph, it disappears

23:16:10: Geany INFO : Geany 1.24 (git >= 0c5442b), en_US.UTF-8
23:16:10: Geany INFO : GTK 2.24.10, GLib 2.32.3
Linux houston 3.2.0-41-generic-pae #66-Ubuntu SMP Thu Apr 25 03:50:20 UTC 2013 i686 athlon i386 GNU/Linux


  • Lex Trotman

    Lex Trotman - 2013-05-14
    • status: open --> pending
  • Lex Trotman

    Lex Trotman - 2013-05-14

    This is not a bug, the caret is normally positioned between characters. That is between the glyph boundaries. This minimises the chance of the caret overlapping and covering or distorting part of the glyph. But if a glyph is positioned hard against the left edge of the visible screen, there is no space for the caret and it disappears, scroll your screen a pixel or two and it will re-appear.

    For the first character of the line the caret has to be moved to the right, into the glyph of the first character, as there is no space to the left of the glyph to put it. You can see this by comparing the distance of the caret and the following character when it is before say a P at the start of the line and a P elsewhere in the line. The alternative is to have to leave "caret space" before each line, using some pixels just in case the caret is located at the left.

    This functionality is provided by the editing component that Geany uses from the separate Scintilla project. (www.scintilla.org). You could try asking there for such a feature which would then become available in Geany as the version of Scintilla is updated.

  • Colomban Wendling

    @elexer IMO having caret disappearing from screen after a caret movement IS a bug. Normally the view should be scrolled horizontally for the caret to get back in the visible area, and it's what happens if you move the caret one character further.

    But indeed, it's an issue in Scintilla.

  • Lex Trotman

    Lex Trotman - 2013-05-14

    Yes, perhaps Scintilla should do the massive and seemingly random scroll jump it does on the next caret move one character earlier.


Log in to post a comment.

Get latest updates about Open Source Projects, Conferences and News.

Sign up for the SourceForge newsletter:

JavaScript is required for this form.

No, thanks