Example #1
0
        private String GetLineContent(IVsTextLines lines, int lineNumber)
        {
            String str        = "";
            var    data       = new LINEDATA[1];
            var    markerData = new MARKERDATA[1];

            if (VSConstants.S_OK == lines.GetLineData(lineNumber, data, markerData))
            {
                str = Marshal.PtrToStringUni(data[0].pszText, data[0].iLength);

                // Clean up memory...needed?
                lines.ReleaseLineData(data);
                lines.ReleaseMarkerData(markerData);
            }
            return(str);
        }
Example #2
0
 public int ReleaseMarkerData(MARKERDATA[] pMarkerData)
 {
     return(_textBuffer.ReleaseMarkerData(pMarkerData));
 }
Example #3
0
        private String GetLineContent(IVsTextLines lines, int lineNumber)
        {
            String str = "";
            var data = new LINEDATA[1];
            var markerData = new MARKERDATA[1];
            if (VSConstants.S_OK == lines.GetLineData(lineNumber, data, markerData))
            {
                str = Marshal.PtrToStringUni(data[0].pszText, data[0].iLength);

                // Clean up memory...needed?
                lines.ReleaseLineData(data);
                lines.ReleaseMarkerData(markerData);
            }
            return str;
        }