reassign a new “character” to a key, so that it gets printed instead of the default letter for the key
问题 I'm in the process of developing a text editor that has a "macro system," where the user can reassign values to the keys on their keyboard -- so that when they press the letter a, it might print the letter "z" instead. (Really, it'll be used for math symbols, not other letters). Can anyone get me started on the Java code to reassign a value to a key within a JTextPane? If you need more details, let me know. Thank you! So far, this is what I have: public void keyPressed(KeyEvent evt) { /