Skip to content

Commit 3ca9451

Browse files
author
VPKSoft
committed
* Fixed crash caused by missing encodings.
* Added Json prettify and Json to one line functions.
1 parent 398d277 commit 3ca9451

7 files changed

Lines changed: 196 additions & 40 deletions

File tree

PluginTemplate/PluginTemplate.csproj

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -58,6 +58,6 @@
5858
<None Include="Resources\tab_deli_localization.txt" />
5959
</ItemGroup>
6060
<ItemGroup>
61-
<PackageReference Include="ScriptNotepadPluginBase.SUO" Version="1.0.3" />
61+
<PackageReference Include="ScriptNotepadPluginBase.SUO" Version="1.0.5" />
6262
</ItemGroup>
6363
</Project>

ScriptNotepad/FormMain.Designer.cs

Lines changed: 29 additions & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

ScriptNotepad/FormMain.cs

Lines changed: 13 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3935,5 +3935,18 @@ private void MnuShowWrapSymbol_Click(object sender, EventArgs e)
39353935
: WrapVisualFlags.None);
39363936
}
39373937
#endregion
3938+
3939+
private void mnuJsonPrettify_Click(object sender, EventArgs e)
3940+
{
3941+
CurrentDocumentAction(document =>
3942+
{
3943+
if (document.Tag != null)
3944+
{
3945+
document.Scintilla.Text = sender.Equals(mnuJsonPrettify)
3946+
? document.Scintilla.Text.JsonPrettify()
3947+
: document.Scintilla.Text.JsonUglify();
3948+
}
3949+
});
3950+
}
39383951
}
39393952
}

0 commit comments

Comments
 (0)