/// <summary> /// Tests if a key modifies the text in the edit box</summary> /// <param name="keyData">A key, such as from ProcessDialogKey</param> /// <returns>True iff the key modifies text</returns> public static bool IsEditKey(Keys keyData) { if (KeysUtil.IsPrintable(keyData)) { return(true); } // remove any modifiers and check for some non-printable editing keys keyData &= Keys.KeyCode; return (keyData == Keys.Back || keyData == Keys.Delete); }