Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/mono/monodevelop.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Text/TextFormatter.cs')
-rw-r--r--main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Text/TextFormatter.cs10
1 files changed, 9 insertions, 1 deletions
diff --git a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Text/TextFormatter.cs b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Text/TextFormatter.cs
index 4d6efb199a..aee449009a 100644
--- a/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Text/TextFormatter.cs
+++ b/main/src/core/MonoDevelop.Core/MonoDevelop.Projects.Text/TextFormatter.cs
@@ -113,6 +113,10 @@ namespace MonoDevelop.Projects.Text
}
}
}
+
+ public bool KeepLines {
+ get; set;
+ }
public bool TabsAsSpaces {
get { return tabsAsSpaces; }
@@ -304,8 +308,12 @@ namespace MonoDevelop.Projects.Text
void AppendCurrentWord (char separatorChar)
{
- if (currentWord.Length == 0)
+ if (currentWord.Length == 0) {
+ if (KeepLines && lineStart && separatorChar == '\n') {
+ AppendChar (separatorChar, true);
+ }
return;
+ }
if (Wrap == WrappingType.Word || Wrap == WrappingType.WordChar) {
if (curCol + currentWord.Length > MaxColumns) {
// If the last char was a word separator, remove it