diff options
| -rw-r--r-- | include/Scintilla.h | 2 | ||||
| -rw-r--r-- | include/Scintilla.iface | 4 | ||||
| -rw-r--r-- | src/Editor.cxx | 8 | 
3 files changed, 14 insertions, 0 deletions
| diff --git a/include/Scintilla.h b/include/Scintilla.h index 7202712ad..19429a493 100644 --- a/include/Scintilla.h +++ b/include/Scintilla.h @@ -442,6 +442,8 @@ typedef sptr_t (*SciFnDirect)(sptr_t ptr, unsigned int iMessage, uptr_t wParam,  #define SCI_SETVISIBLEPOLICY 2394  #define SCI_DELLINELEFT 2395  #define SCI_DELLINERIGHT 2396 +#define SCI_SETXOFFSET 2397 +#define SCI_GETXOFFSET 2398  #define SCI_GRABFOCUS 2400  #define SCI_STARTRECORD 3001  #define SCI_STOPRECORD 3002 diff --git a/include/Scintilla.iface b/include/Scintilla.iface index 6c31eaa70..c77fe2b9e 100644 --- a/include/Scintilla.iface +++ b/include/Scintilla.iface @@ -1169,6 +1169,10 @@ fun void DelLineLeft=2395(,)  # Delete forwards from the current position to the end of the line  fun void DelLineRight=2396(,) +# Get and Set the xOffset (ie, horizonal scroll position) +set void SetXOffset=2397(int newOffset,) +get int GetXOffset=2398(,) +  # Set the focus to this Scintilla widget.  # GTK+ Specific  fun void GrabFocus=2400(,) diff --git a/src/Editor.cxx b/src/Editor.cxx index cbf3a951f..0730bc280 100644 --- a/src/Editor.cxx +++ b/src/Editor.cxx @@ -3700,6 +3700,14 @@ sptr_t Editor::WndProc(unsigned int iMessage, uptr_t wParam, sptr_t lParam) {  		HorizontalScrollTo(xOffset + wParam * vs.spaceWidth);  		return TRUE; +	case SCI_SETXOFFSET: +		xOffset = wParam; +		Redraw(); +		break; + +	case SCI_GETXOFFSET: +		return xOffset; +  	case SCI_SCROLLCARET:  		EnsureCaretVisible();  		break; | 
