Questions tagged [keyboard]

A text input device. Use this tag to ask programming questions related to typing, keyboard hiding and more.

What topics don't belong here?

If your question is about:

  • Making a (physical) keyboard: See electronics.SX. (Of course, if you want to implement/imitate a keyboard in software — e.g. an on-screen keyboard — then go right ahead and ask.)

  • Configuring your keyboard: See superuser.com, unix.SX, or another site that covers using computer systems — Stack Overflow is about programming them.

  • Interfacing with a device resembling a piano: This is not the tag you're looking for. Move along.

12648 questions
99
votes
23 answers

Really weird eclipse keyboard behavior/bug?

I am using Helios on Mac Snow Leopard. I don't know why but all of a sudden my arrow keys and delete button start not working only on Eclipse (so Eclipse ignores them) but the rest of the buttons works just fine. There is no exception/error thrown…
Aleyna
  • 1,857
  • 4
  • 20
  • 27
98
votes
9 answers

prevent mobile default keyboard when focusing an from showing

this is how i'm trying but the input stills 'launching' iphone's keyboard ps: i want to…
Toni Michel Caubet
  • 19,333
  • 56
  • 202
  • 378
94
votes
7 answers

Programmatically align a toolbar on top of the iPhone keyboard

In several cases I want to add a toolbar to the top of the iPhone keyboard (as in iPhone Safari when you're navigating form elements, for example). Currently I am specifying the toolbar's rectangle with constants but because other elements of the…
Rob Drimmie
  • 1,586
  • 1
  • 13
  • 16
90
votes
4 answers

How to detect when a TextField is selected in Flutter?

I have a Flutter TextField which gets covered by the soft keyboard when the field is selected. I need to scroll the field up and out of the way when the keyboard is displayed. This is a pretty common problem and a solution is presented in this…
user2785693
  • 935
  • 1
  • 8
  • 7
90
votes
15 answers

Handling key-press events (F1-F12) using JavaScript and jQuery, cross-browser

I want to handle F1-F12 keys using JavaScript and jQuery. I am not sure what pitfalls there are to avoid, and I am not currently able to test implementations in any other browsers than Internet Explorer 8, Google Chrome and Mozilla FireFox 3. Any…
cllpse
  • 21,396
  • 37
  • 131
  • 170
87
votes
14 answers

Is it possible to program Android to act as physical USB keyboard?

What I really want to know is whether it is a hardware problem, or a software problem. Could I plug my android phone into a computer via USB and have it act as a hardware keyboard. I do not want to install anything on the computer, I want android to…
Billy Moon
  • 57,113
  • 24
  • 136
  • 237
87
votes
6 answers

Android softkeyboard never shows up in emulator

I'm new to Android. I've spent two hours already for searching. Whatever i try softkeyboard is never shown for my EditText. I create it simply: EditText editText = (EditText)findViewById(R.id.editText); I tried: editText.requestFocus();//i tried…
Andrey Chernukha
  • 21,488
  • 17
  • 97
  • 161
87
votes
2 answers

How can I give keyboard focus to a DIV and attach keyboard event handlers to it?

I am building an application where I want to be able to click a rectangle represented by a DIV, and then use the keyboard to move that DIV by listing for keyboard events. Rather than using an event listener for those keyboard events at the document…
Paul Dixon
  • 295,876
  • 54
  • 310
  • 348
87
votes
7 answers

What is the height of iPhone's onscreen keyboard?

The height in portrait and the height in landscape measured in points.
Erik B
  • 40,889
  • 25
  • 119
  • 135
86
votes
1 answer

How to speed up the left and right arrow keys for editing text?

Is it just me, or do other people find that the left and right arrow keys on MacOS are unusually slow for editing text? Compared to my Windows machines, positioning the cursor with left/right arrow keys seems to take twice as long on the Mac. The…
Blue
  • 1,196
  • 1
  • 9
  • 7
85
votes
5 answers

Simulate Keypress With jQuery

Using jQuery, how can I simulate (trigger?) a KeyPress when a link is clicked? For example, when a user clicks the following link: Click Here Then, by clicking the link, it would be as if they pressed the…
Dodinas
  • 6,705
  • 22
  • 76
  • 108
83
votes
10 answers

can't get correct value of keyboard height in iOS8

I was using this code to determine what is the size of the keyboard : - (void)keyboardWillChange:(NSNotification *)notification { NSDictionary* keyboardInfo = [notification userInfo]; NSValue* keyboardFrameBegin = [keyboardInfo…
Eli Braginskiy
  • 2,867
  • 5
  • 31
  • 46
82
votes
22 answers

Weird keyboard locks in IntelliJ IDEA (delete & arrow keys, etc.)

While working in IntelliJ IDEA, the keyboard occasionally locks in a way that delete or < > ^ keys don't work properly anymore, in a way that delete doesn't do anything anymore, and the arrow keys scroll the entire source code / editor section. I…
Mathias Conradt
  • 28,420
  • 21
  • 138
  • 192
80
votes
11 answers

How can I add a keyboard shortcut to an existing JavaScript Function?

Here is my code: function pauseSound() { var pauseSound = document.getElementById("backgroundMusic"); pauseSound.pause(); } I would like to add a keyboard shortcut to this code, how can I do this so that the function can also be executed…
Chris
  • 841
  • 1
  • 8
  • 8
79
votes
16 answers

How do I dismiss the iOS keyboard?

I have a UITextfield that i'd like to dismiss the keyboard for. I can't seem to make the keyboard go away no matter what code i use.
Tyler McMaster
  • 1,407
  • 2
  • 14
  • 15