Discussion:
Automatic horizontal scrollbar
Mike Lischke
2013-07-02 14:24:09 UTC
Permalink
Hey Neil,

I have the vague feeling this has been discussed already, but I'm not sure about the current stand. Currently, when you paste text into Scintilla which is larger than the currently visible area the horizontal scrollbar appears. Not so when you set the text via code (e.g. when loading text from a file (using SCI_SETTEXT, sometimes SCI_APPENDTEXT).

How's that supposed to work now? Is it still so that in the second case the scrollbar is not updated? It's really annoying, so I need to find a way to solve this. But maybe I'm doing something wrong and the scrollbar would normally appear in both cases...

Mike
--
www.soft-gems.net
--
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.
Neil Hodgson
2013-07-03 00:21:16 UTC
Permalink
Post by Mike Lischke
Currently, when you paste text into Scintilla which is larger than the currently visible area the horizontal scrollbar appears. Not so when you set the text via code (e.g. when loading text from a file (using SCI_SETTEXT, sometimes SCI_APPENDTEXT).
Default behaviour is to show a horizontal scroll bar.

If you have reduced the scroll width to hide the scroll bar and turned scroll width tracking on then Scintilla should notice wider lines when painting them and then, on the next timer tick, show the scroll bar if needed. Lines that haven't been painted won't affect the scroll width.

Neil
--
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.
Mike Lischke
2013-07-03 15:41:29 UTC
Permalink
Post by Neil Hodgson
Post by Mike Lischke
Currently, when you paste text into Scintilla which is larger than the currently visible area the horizontal scrollbar appears. Not so when you set the text via code (e.g. when loading text from a file (using SCI_SETTEXT, sometimes SCI_APPENDTEXT).
Default behaviour is to show a horizontal scroll bar.
If you have reduced the scroll width to hide the scroll bar and turned scroll width tracking on then Scintilla should notice wider lines when painting them and then, on the next timer tick, show the scroll bar if needed. Lines that haven't been painted won't affect the scroll width.
Neil, that did the trick. I wasn't aware of that option. Thank you.

Mike
--
www.soft-gems.net
--
You received this message because you are subscribed to the Google Groups "scintilla-interest" group.
To unsubscribe from this group and stop receiving emails from it, send an email to scintilla-interest+***@googlegroups.com.
To post to this group, send email to scintilla-***@googlegroups.com.
Visit this group at http://groups.google.com/group/scintilla-interest.
For more options, visit https://groups.google.com/groups/opt_out.
Continue reading on narkive:
Loading...