private void TemplateRemoveMenuItem_Click(object sender, EventArgs e)
 {
     if (sender is ToolStripMenuItem mi)
     {
         templManager.DeleteRule(mi.Text);
     }
 }