Skip to content

Commit 086361a

Browse files
committed
Updated Position types to work also on 64 bit according to https://www.scintilla.org/ScintillaDoc.html and https://en.cppreference.com/w/c/types/ptrdiff_t
1 parent 2efb1fc commit 086361a

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

Visual Studio Project Template C#/PluginInfrastructure/Scintilla_iface.cs

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -38,21 +38,21 @@ public struct ScNotificationHeader
3838
public struct ScNotification
3939
{
4040
public ScNotificationHeader Header;
41-
private int position; /* SCN_STYLENEEDED, SCN_DOUBLECLICK, SCN_MODIFIED, SCN_MARGINCLICK, SCN_NEEDSHOWN, SCN_DWELLSTART, SCN_DWELLEND, SCN_CALLTIPCLICK, SCN_HOTSPOTCLICK, SCN_HOTSPOTDOUBLECLICK, SCN_HOTSPOTRELEASECLICK, SCN_INDICATORCLICK, SCN_INDICATORRELEASE, SCN_USERLISTSELECTION, SCN_AUTOCSELECTION */
41+
private IntPtr position; /* SCN_STYLENEEDED, SCN_DOUBLECLICK, SCN_MODIFIED, SCN_MARGINCLICK, SCN_NEEDSHOWN, SCN_DWELLSTART, SCN_DWELLEND, SCN_CALLTIPCLICK, SCN_HOTSPOTCLICK, SCN_HOTSPOTDOUBLECLICK, SCN_HOTSPOTRELEASECLICK, SCN_INDICATORCLICK, SCN_INDICATORRELEASE, SCN_USERLISTSELECTION, SCN_AUTOCSELECTION */
4242
public int character; /* SCN_CHARADDED, SCN_KEY, SCN_AUTOCCOMPLETE, SCN_AUTOCSELECTION, SCN_USERLISTSELECTION */
4343
public int Mmodifiers; /* SCN_KEY, SCN_DOUBLECLICK, SCN_HOTSPOTCLICK, SCN_HOTSPOTDOUBLECLICK, SCN_HOTSPOTRELEASECLICK, SCN_INDICATORCLICK, SCN_INDICATORRELEASE */
4444
public int ModificationType; /* SCN_MODIFIED - modification types are name "SC_MOD_*" */
4545
public IntPtr TextPointer; /* SCN_MODIFIED, SCN_USERLISTSELECTION, SCN_AUTOCSELECTION, SCN_URIDROPPED */
46-
public int Length; /* SCN_MODIFIED */
47-
public int LinesAdded; /* SCN_MODIFIED */
46+
public IntPtr Length; /* SCN_MODIFIED */
47+
public IntPtr LinesAdded; /* SCN_MODIFIED */
4848
public int Message; /* SCN_MACRORECORD */
4949
public IntPtr wParam; /* SCN_MACRORECORD */
5050
public IntPtr lParam; /* SCN_MACRORECORD */
5151

5252
/// <summary>
5353
/// 0-based index
5454
/// </summary>
55-
public int LineNumber; /* SCN_MODIFIED */
55+
public IntPtr LineNumber; /* SCN_MODIFIED */
5656
public int FoldLevelNow; /* SCN_MODIFIED */
5757
public int FoldLevelPrev; /* SCN_MODIFIED */
5858
public int Margin; /* SCN_MARGINCLICK */
@@ -63,6 +63,7 @@ public struct ScNotification
6363
public int AnnotationLinesAdded; /* SC_MOD_CHANGEANNOTATION */
6464
public int Updated; /* SCN_UPDATEUI */
6565
public int ListCompletionMethod; /* SCN_AUTOCSELECTION, SCN_AUTOCCOMPLETED, SCN_USERLISTSELECTION */
66+
public int CharacterSource; /* SCN_CHARADDED */
6667

6768
/// <summary>
6869
/// SCN_STYLENEEDED, SCN_DOUBLECLICK, SCN_MODIFIED, SCN_MARGINCLICK, SCN_NEEDSHOWN, SCN_DWELLSTART, SCN_DWELLEND, SCN_CALLTIPCLICK, SCN_HOTSPOTCLICK, SCN_HOTSPOTDOUBLECLICK, SCN_HOTSPOTRELEASECLICK, SCN_INDICATORCLICK, SCN_INDICATORRELEASE, SCN_USERLISTSELECTION, SCN_AUTOCSELECTION
@@ -73,7 +74,7 @@ public struct ScNotification
7374
/// Character of the notification - eg keydown
7475
/// SCN_CHARADDED, SCN_KEY, SCN_AUTOCCOMPLETE, SCN_AUTOCSELECTION, SCN_USERLISTSELECTION
7576
/// </summary>
76-
public char Character { get { return (char) character; } }
77+
public char Character { get { return (char)character; } }
7778
}
7879

7980
[Flags]

0 commit comments

Comments
 (0)