/// <summary> /// Return all the markers from a scintilla document /// </summary> /// <param name="sci"></param> /// <returns></returns> private List<int> GetMarkers( ScintillaNet.ScintillaControl sci ) { List<int> markerLines = new List<int>(); int line = 0; int maxLine = 0; while (true) { if ((sci.MarkerNext(line, sci.GetMarginMaskN(0)) == -1) || (line > sci.LineCount)) break; line = sci.MarkerNext(line, sci.GetMarginMaskN(0)); markerLines.Add(line); maxLine = Math.Max(maxLine, line); line++; } return markerLines; }