Category / Section
How to get or set the new line style of the text in the WinForms SyntaxEditor (EditControl)?
1 min read
New line style of text
You can get or set the new line style of the text in EditControl using the methods SetNewLineStyle and GetNewLineStyle. The SetNewLineStyle method can accept values from the NewLineStyle enumerator which has values like Windows, Mac, Unix and Control which correspond to the new line styles "\r\n", "\r", "\n\r" and "\n" respectively.
C#
this.editControl1.SetNewLineStyle(NewLineStyle.Mac);
VB
Me.editControl1.SetNewLineStyle(NewLineStyle.Mac)
C#
NewLineStyle newlinestyle=this.editControl1.GetNewLineStyle();
VB
Dim newlinestyle As NewLineStyle=Me.editControl1.GetNewLineStyle()
Reference link: https://help.syncfusion.com/windowsforms/syntax-editor/editing#new-line-styles