简体   繁体   English

计算器应用包括键盘输入 java swing

[英]Calculator application including keyboard input in java swing

I have a calculator application in java swing, which is working properly with mouse click input.我在 java swing 中有一个计算器应用程序,它可以通过鼠标单击输入正常工作。 Now I want it to read input using keyboard button stroke.现在我希望它使用键盘按钮笔划来读取输入。 I had heard about the glass pane in java tutorial, but i need to know any other simple method to meet the requirement.我在 java 教程中听说过玻璃板,但我需要知道任何其他简单的方法来满足要求。

KeyPadPanel is an example that usesAction and Key Bindings for numeric entry. KeyPadPanel是一个使用ActionKey Bindings进行数字输入的示例。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM