private static void CutSelectionOrLine() { var scintilla = new ScintillaGateway(PluginBase.GetCurrentScintilla()); if (scintilla.GetSelectionLength() != 0) { scintilla.Cut(); } else { scintilla.CopyAllowLine(); scintilla.LineDelete(); } }