Skip to content

Commit 3ff9df5

Browse files
Merge branch 'master' into stable
2 parents 43361ef + bd7300f commit 3ff9df5

23 files changed

+209
-66
lines changed

CHANGELOG.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -5,12 +5,23 @@
55
These changes have not been released to the Visual Studio marketplace, but (if checked) are available in preview within the [CI build](http://vsixgallery.com/extension/4c82e17d-927e-42d2-8460-b473ac7df316/).
66

77
- [ ] Features
8+
89
- [ ] Fixes
910

1011
## Previous Releases
1112

1213
These are the changes to each version that has been released to the Visual Studio marketplace.
1314

15+
## 10.6
16+
17+
**2018-12-09**
18+
19+
- [x] Features
20+
- [x] [#582](https://github.com/codecadwallader/codemaid/pull/582) - Digging: New option to show item types (e.g. method return or property type) - thanks [GammaWolf](https://github.com/GammaWolf)!
21+
- [x] [#593](https://github.com/codecadwallader/codemaid/pull/593) - Switching: Add .cshtml -> .cshtml.cs to defaults - thanks [derekmckinnon](https://github.com/derekmckinnon)!
22+
- [x] [#594](https://github.com/codecadwallader/codemaid/pull/594) - Cleaning: New option to add blank lines before/after single-line fields - thanks [jasonjtyler](https://github.com/jasonjtyler)!
23+
- [x] [#604](https://github.com/codecadwallader/codemaid/pull/604) - Turn on VS2019 support - thanks [digovc](https://github.com/digovc)!
24+
1425
## 10.5
1526

1627
**2018-06-09**

CONTRIBUTING.md

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22

33
Looking to contribute something? **Here's how you can help.**
44

5-
Please read http://www.codemaid.net/contribute/ for setup and a quick code overview
5+
Please read http://www.codemaid.net/contribute/ for setup and a quick code overview.
66

77
Following these guidelines helps to communicate that you respect the time of
88
the developers managing and developing this open source project. In return,
@@ -17,7 +17,7 @@ The issue tracker is the preferred channel for [bug reports](#bug-reports),
1717
[submitting pull requests](#pull-requests), but please respect the
1818
following restrictions:
1919

20-
* Please **do not** use the issue tracker for personal support requests. Stack
20+
* Please **do not** use the issue tracker for personal support requests. Stack
2121
Overflow is a better place to get help.
2222

2323
* Please **do not** derail or troll issues. Keep the discussion on topic and
@@ -42,7 +42,7 @@ Guidelines for bug reports:
4242

4343
3. **Isolate the problem** — ideally create an
4444
[SSCCE](http://www.sscce.org/) and a live example.
45-
Uploading the project on cloud storage (OneDrive, DropBox, et el.)
45+
Uploading the project on cloud storage (OneDrive, DropBox, et al.)
4646
or creating a sample GitHub repository is also helpful.
4747

4848

CodeMaid.UnitTests/Formatting/XmlFormattingTests.cs

Lines changed: 31 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -52,6 +52,7 @@ public void XmlFormattingTests_AddSpaceToTagContentWithSelfClosingTag()
5252

5353
Settings.Default.Formatting_CommentXmlSplitSummaryTagToMultipleLines = false;
5454
Settings.Default.Formatting_CommentXmlSpaceTags = true;
55+
Settings.Default.Formatting_CommentXmlSpaceSingleTags = false;
5556

5657
CommentFormatHelper.AssertEqualAfterFormat(input, expected);
5758
}
@@ -68,13 +69,14 @@ public void XmlFormattingTests_AddSpaceToTagContentWithSelfClosingTagMultiline()
6869

6970
Settings.Default.Formatting_CommentXmlSplitSummaryTagToMultipleLines = true;
7071
Settings.Default.Formatting_CommentXmlSpaceTags = true;
72+
Settings.Default.Formatting_CommentXmlSpaceSingleTags = false;
7173

7274
CommentFormatHelper.AssertEqualAfterFormat(input, expected);
7375
}
7476

7577
[TestMethod]
7678
[TestCategory("Formatting UnitTests")]
77-
public void XmlFormattingTests_AddSpaceToTagContentShouldLeaveNoTrailingWhitespace()
79+
public void XmlFormattingTests_AddSpaceToTagContentShouldLeaveNoTrailingWhitespace1()
7880
{
7981
var input = "<summary>Lorem ipsum dolor sit amet, consectetur adipiscing elit.</summary>";
8082
var expected =
@@ -90,6 +92,29 @@ public void XmlFormattingTests_AddSpaceToTagContentShouldLeaveNoTrailingWhitespa
9092
CommentFormatHelper.AssertEqualAfterFormat(input, expected);
9193
}
9294

95+
[TestMethod]
96+
[TestCategory("Formatting UnitTests")]
97+
[Ignore] // This is temporarily ignored until a better fix for #564 is found.
98+
public void XmlFormattingTests_AddSpaceToTagContentShouldLeaveNoTrailingWhitespace2()
99+
{
100+
var input =
101+
"<remarks>" + Environment.NewLine +
102+
"Lorem ipsum dolor sit amet, consectetur adipiscing elit." + Environment.NewLine +
103+
"</remarks>";
104+
105+
var expected =
106+
"<remarks>" + Environment.NewLine +
107+
" Lorem ipsum dolor sit amet, consectetur" + Environment.NewLine +
108+
" adipiscing elit." + Environment.NewLine +
109+
"</remarks>";
110+
111+
Settings.Default.Formatting_CommentWrapColumn = 50;
112+
Settings.Default.Formatting_CommentXmlValueIndent = 4;
113+
Settings.Default.Formatting_CommentXmlSpaceTags = true;
114+
115+
CommentFormatHelper.AssertEqualAfterFormat(input, expected);
116+
}
117+
93118
[TestMethod]
94119
[TestCategory("Formatting UnitTests")]
95120
public void XmlFormattingTests_AllRootLevelTagsOnNewLine()
@@ -185,6 +210,7 @@ public void XmlFormattingTests_DoesIndentAfterLiteralContent()
185210

186211
Settings.Default.Formatting_CommentXmlValueIndent = 4;
187212
Settings.Default.Formatting_CommentXmlKeepTagsTogether = true;
213+
Settings.Default.Formatting_CommentXmlSpaceSingleTags = false;
188214

189215
// First pass.
190216
var result = CommentFormatHelper.AssertEqualAfterFormat(input, expected);
@@ -264,6 +290,7 @@ public void XmlFormattingTests_DoNotAutoExpandTags()
264290
var input = "<summary/>";
265291

266292
Settings.Default.Formatting_CommentXmlSplitSummaryTagToMultipleLines = false;
293+
Settings.Default.Formatting_CommentXmlSpaceSingleTags = false;
267294

268295
CommentFormatHelper.AssertEqualAfterFormat(input);
269296
}
@@ -350,6 +377,8 @@ public void XmlFormattingTests_InterpunctionNoSpacing()
350377
{
351378
var input = "<test>Line with <interpunction/>.</test>";
352379

380+
Settings.Default.Formatting_CommentXmlSpaceSingleTags = false;
381+
353382
CommentFormatHelper.AssertEqualAfterFormat(input);
354383
}
355384

@@ -405,6 +434,7 @@ public void XmlFormattingTests_RemoveSpaceFromInsideTags()
405434
var expected = "<summary><see/></summary>";
406435

407436
Settings.Default.Formatting_CommentXmlSplitSummaryTagToMultipleLines = false;
437+
Settings.Default.Formatting_CommentXmlSpaceSingleTags = false;
408438

409439
CommentFormatHelper.AssertEqualAfterFormat(input, expected);
410440
}

CodeMaid/Integration/Images/about.png

189 Bytes
Loading

CodeMaid/Integration/Images/about.xcf

-93 KB
Binary file not shown.

CodeMaid/Logic/Cleaning/InsertBlankLinePaddingLogic.cs

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,9 @@ internal bool ShouldBePrecededByBlankLine(BaseCodeItem codeItem)
7777
return Settings.Default.Cleaning_InsertBlankLinePaddingBeforeEvents;
7878

7979
case KindCodeItem.Field:
80-
return codeItem.IsMultiLine && Settings.Default.Cleaning_InsertBlankLinePaddingBeforeFieldsMultiLine;
80+
return codeItem.IsMultiLine
81+
? Settings.Default.Cleaning_InsertBlankLinePaddingBeforeFieldsMultiLine
82+
: Settings.Default.Cleaning_InsertBlankLinePaddingBeforeFieldsSingleLine;
8183

8284
case KindCodeItem.Interface:
8385
return Settings.Default.Cleaning_InsertBlankLinePaddingBeforeInterfaces;
@@ -138,7 +140,9 @@ internal bool ShouldBeFollowedByBlankLine(BaseCodeItem codeItem)
138140
return Settings.Default.Cleaning_InsertBlankLinePaddingAfterEvents;
139141

140142
case KindCodeItem.Field:
141-
return codeItem.IsMultiLine && Settings.Default.Cleaning_InsertBlankLinePaddingAfterFieldsMultiLine;
143+
return codeItem.IsMultiLine
144+
? Settings.Default.Cleaning_InsertBlankLinePaddingAfterFieldsMultiLine
145+
: Settings.Default.Cleaning_InsertBlankLinePaddingAfterFieldsSingleLine;
142146

143147
case KindCodeItem.Interface:
144148
return Settings.Default.Cleaning_InsertBlankLinePaddingAfterInterfaces;

CodeMaid/Properties/Resources.Designer.cs

Lines changed: 9 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

CodeMaid/Properties/Resources.en-US.resx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -771,6 +771,9 @@
771771
<data name="ShowItemMetadata" xml:space="preserve">
772772
<value>Show item metadata</value>
773773
</data>
774+
<data name="ShowItemTypes" xml:space="preserve">
775+
<value>Show item types</value>
776+
</data>
774777
<data name="ShowMethodParameters" xml:space="preserve">
775778
<value>Show method parameters</value>
776779
</data>

CodeMaid/Properties/Resources.resx

Lines changed: 8 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -20,13 +20,13 @@
2020
<data name="Name1"><value>this is my long string</value><comment>this is a comment</comment></data>
2121
<data name="Color1" type="System.Drawing.Color, System.Drawing">Blue</data>
2222
<data name="Bitmap1" mimetype="application/x-microsoft.net.object.binary.base64">
23-
<value>[base64 mime encoded serialized .NET Framework object]</value>
24-
</data>
23+
<value>[base64 mime encoded serialized .NET Framework object]</value>
24+
</data>
2525
<data name="Icon1" type="System.Drawing.Icon, System.Drawing" mimetype="application/x-microsoft.net.object.bytearray.base64">
26-
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
26+
<value>[base64 mime encoded string representing a byte array form of the .NET Framework object]</value>
2727
<comment>This is a comment</comment>
28-
</data>
29-
28+
</data>
29+
3030
There are any number of "resheader" rows that contain simple
3131
name/value pairs.
3232
@@ -771,6 +771,9 @@
771771
<data name="ShowItemMetadata" xml:space="preserve">
772772
<value>Show item metadata</value>
773773
</data>
774+
<data name="ShowItemTypes" xml:space="preserve">
775+
<value>Show item types</value>
776+
</data>
774777
<data name="ShowMethodParameters" xml:space="preserve">
775778
<value>Show method parameters</value>
776779
</data>

CodeMaid/Properties/Resources.zh-Hans.resx

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -771,6 +771,9 @@
771771
<data name="ShowItemMetadata" xml:space="preserve">
772772
<value>显示项目元数据</value>
773773
</data>
774+
<data name="ShowItemTypes" xml:space="preserve">
775+
<value>显示项目类型</value>
776+
</data>
774777
<data name="ShowMethodParameters" xml:space="preserve">
775778
<value>显示方法参数</value>
776779
</data>

0 commit comments

Comments
 (0)