This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
while (true) | |
{ | |
// Get data from the send buffer | |
var result = await reader.ReadAsync().ConfigureAwait(false); | |
if (result.IsCanceled) | |
{ | |
break; | |
} | |
// Write to the socket |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Extracted from the Lua Scintilla lexer and SciTE .properties file | |
var alphaChars = "abcdefghijklmnopqrstuvwxyzABCDEFGHIJKLMNOPQRSTUVWXYZ"; | |
var numericChars = "0123456789"; | |
var accentedChars = "ŠšŒœŸÿÀàÁáÂâÃãÄäÅ寿ÇçÈèÉéÊêËëÌìÍíÎîÏïÐðÑñÒòÓóÔôÕõÖØøÙùÚúÛûÜüÝýÞþßö"; | |
// Configuring the default style with properties | |
// we have common to every lexer style saves time. | |
scintilla.StyleResetDefault(); | |
scintilla.Styles[Style.Default].Font = "Consolas"; |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// The component is required using the 'component!' plugin we created. This will load | |
// 'page1.html' and 'page1.js' and return 'page1.js' to us. | |
define(['knockout', 'component!page1'], function (ko, Page1) { | |
'use strict'; | |
function App() { | |
var args = { name: 'Jacob' }; | |
// Example of using the component binding with the automatically registered component |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// For an explanation of this code visit: | |
// https://github.com/jacobslusser/ScintillaNET/wiki/Automatic-Syntax-Highlighting | |
// Configuring the default style with properties | |
// we have common to every lexer style saves time. | |
scintilla.StyleResetDefault(); | |
scintilla.Styles[Style.Default].Font = "Consolas"; | |
scintilla.Styles[Style.Default].Size = 10; | |
scintilla.StyleClearAll(); |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Reset the styles | |
scintilla.StyleResetDefault(); | |
scintilla.Styles[Style.Default].Font = "Consolas"; | |
scintilla.Styles[Style.Default].Size = 10; | |
scintilla.StyleClearAll(); // i.e. Apply to all | |
// Set the lexer | |
scintilla.Lexer = Lexer.Python; | |
// Known lexer properties: |