reidwooten99 / connectbot

Automatically exported from code.google.com/p/connectbot
Apache License 2.0
0 stars 0 forks source link

Backspace key does not work with Swype keyboard (HTC Hero Sprint) #320

Closed GoogleCodeExporter closed 8 years ago

GoogleCodeExporter commented 8 years ago
What steps will reproduce the problem?
1. Requires Swype keyboard (get beta access at http://www.swypeinc.com/)
2. Open an ssh session
3. Type anything and then try to backspace

What is the expected output? What do you see instead?
Should erase last character. Does nothing instead. Backspace key in Swype  is 
working fine in every other app I've used on my phone so far.

What version of the product are you using (you can see this by using Menu
-> About in the Host List)?
1.6.2 (r480 2010.02.12)

What type of system are you trying to connect to?
Ubuntu 9.10 SSH Server

If you are able to connect, what is the output of "echo $TERM", "uname -a",
and any other relevant information on the host?
echo $TERM output: xterm
uname -a output:  2.6.31-22-generic #60-Ubuntu SMP Thu May 27 00:22:23 UTC 2010 
i686 GNU/Linux

Please provide any additional information below.
All other keys work fine and even the swype functionality works as it should. 
It's just the backspace key not working.

Original issue reported on code.google.com by pdrago...@gmail.com on 30 Jun 2010 at 7:48

GoogleCodeExporter commented 8 years ago
Same here with samsung galaxy S

Original comment by alexande...@gmail.com on 8 Jul 2010 at 2:06

GoogleCodeExporter commented 8 years ago
I also have this problem. HTC ADR6300 (Incredible). I believe it to be a 
problem with Swype upstream as it also happens in Terminal Emulator. I'm not 
sure if you will be able to find a workaround for it, but I will also file a 
bug report with swype.

Thanks,
Execute_Method

Original comment by execute....@gmail.com on 8 Jul 2010 at 4:27

GoogleCodeExporter commented 8 years ago
Having this issue too. Hope it's fixed soon enough as it is very hard to use a 
shell without backspace! :)

Original comment by zeromus...@gmail.com on 9 Jul 2010 at 1:00

GoogleCodeExporter commented 8 years ago
A tedious work around- move left with ball and use "ctrl-d" (ball-d) to delete 
the char vs backspacing it.

Original comment by gavin.co...@gmail.com on 11 Jul 2010 at 3:42

GoogleCodeExporter commented 8 years ago
Same problem on N1 2.2/Froyo with Swype 1.56. The backspace key doesn't appear 
to generate any key in Connectbot.

An easier workaround is 'ball-h' to get a ctrl-h with is a backspace.

Original comment by aaron.ro...@gmail.com on 11 Jul 2010 at 3:10

GoogleCodeExporter commented 8 years ago
Did you file your bug with Swype? Has there been any response yet? This is 
annoying :/

Original comment by steinb...@gmail.com on 15 Jul 2010 at 11:50

GoogleCodeExporter commented 8 years ago
...especially on devices like the Galaxy S -- which does not have a trackball.

Original comment by steinb...@gmail.com on 15 Jul 2010 at 11:51

GoogleCodeExporter commented 8 years ago
I sent an email to the Swype developers and have not recieved a reply. Maybe 
it's time to start using another KB :(

Original comment by execute....@gmail.com on 15 Jul 2010 at 11:55

GoogleCodeExporter commented 8 years ago
Apparently there is an issue in the Swype bug tracker, currently marked as 
'under review': 
http://swype.uservoice.com/forums/55960-swype-for-android-beta/suggestions/81677
5-backspace-does-not-work-in-terminal?ref=title

Original comment by steinb...@gmail.com on 15 Jul 2010 at 2:04

GoogleCodeExporter commented 8 years ago
I was playing with the keyboard trying to figure out if I could get an esc key, 
and one of the tips mentioned that keys didn't behave the same in password 
fields.  Perhaps the initial password entry screen is causing the issues?

I've downloaded the full keyboard which has all of the keys, but planning ahead 
to do the swap of keyboards is really annoying.  Perhaps a quick fix would be 
to allow you to change keyboards inside the app?  I've only been using android 
for 2 days, so I don't know a lot about the abilities/limitations.

On my old phone, there was a menu item to bring up special characters (esc, 
ctrl, alt, tab), arrows, and function keys.  When these options were enabled, a 
transparent button for the keys was added to the top of the window.  This could 
be another option.

Original comment by john.thi...@gmail.com on 30 Jul 2010 at 7:29

GoogleCodeExporter commented 8 years ago
The gory details:

The password field is a TextView that has an Editable associated with it.

The TerminalView is not a TextView and simply accepts raw key input instead of 
presenting an Editable.

Many IME authors don't test with anything but a TextView. This is simply a bug 
in the Swype IME due to insufficient testing. I have suggested the possible 
cause of this error on the above-linked Swype bug database.

Original comment by kr...@google.com on 4 Aug 2010 at 4:29

GoogleCodeExporter commented 8 years ago
Issue 327 has been merged into this issue.

Original comment by kenny@the-b.org on 4 Aug 2010 at 4:31

GoogleCodeExporter commented 8 years ago
Also having this issue on my Samsung Galaxy S when using Swype

Original comment by guy.knig...@gmail.com on 21 Aug 2010 at 9:04

GoogleCodeExporter commented 8 years ago
 Same issue with Samsung Captivate and swype.

Original comment by thom....@gmail.com on 28 Aug 2010 at 7:37

GoogleCodeExporter commented 8 years ago
I've got this issue on a samsung galaxy s with swype also.

Original comment by justin.l...@gmail.com on 31 Aug 2010 at 9:42

GoogleCodeExporter commented 8 years ago
I did some research on this. Swype uses InputConnector.deleteSurroundingText() 
to delete text instead of sending a KeyEvent with the key code 
KeyEvent.KEYCODE_DEL using InputConnector.sendKeyEvent().

So here's a patch for this. Might be quick and dirty but it works.

Original comment by julian.brost on 3 Sep 2010 at 11:48

Attachments:

GoogleCodeExporter commented 8 years ago
Android Terminal Emulator fixed this issue a few days ago...
http://github.com/jackpal/Android-Terminal-Emulator

It might be worth it to get with those guys and see if their solution could 
work here.
Well, unless Julian.B's solution works well enough.

Original comment by scott.re...@gmail.com on 7 Sep 2010 at 3:18

GoogleCodeExporter commented 8 years ago
@scott.reichel Let me quote the commit message [1]:

> Thanks to Julian Brost (who fixed the same bug in the connectbot project),
> and thanks to Todd Musall for spotting the bug fix in the connectbot
> tracker, and tried it out in Android Term.

They modified it to send as many DEL KeyEvents as specified in the leftLength 
argument of deleteSurroundingText(). But if you don't implement 
getTextBeforeCursor(), which is not always possible in a terminal, leftLength 
will always be 1 (if you tap backspace) or 0 (if you hold backspace). This is 
because Swype tries to delete whole words if you hold backspace pressed, which 
is not possible as getTextBeforeCursor() is not implemented so it wants to 
delete 0 characters. So no text will be deleted if you hold backspace (with the 
patch from Android Term).

My original versions sends a DEL KeyEvent unless Swype wants to delete 
characters right of the cursor. As Swype calls deleteSurroundingText(0, 0) 
multiple times if you hold backspace, this will sende multiple DEL KeyEvents 
(as I would expect it).

I've attached a new version of my patch which is able of sending multiple DEL 
KeyEvents if leftLength is greater than 1. Maybe that makes sense with some 
other IME, but it does not with Swype unless getTextBeforeCursor() is 
implemented. But implementing this could lead to some strange results as you 
can't always delete a character (or word in case of Swype) before the cursor.

[1] 
http://github.com/jackpal/Android-Terminal-Emulator/commit/d4122bbc6abc12eb0f22d
240370e75e89f88f295

Original comment by julian.brost on 7 Sep 2010 at 9:39

Attachments:

GoogleCodeExporter commented 8 years ago
Okay, I submitted that to the github repo. Thanks, Julian!

Original comment by kenny@the-b.org on 8 Sep 2010 at 3:40

GoogleCodeExporter commented 8 years ago
Just wanted to say that I got a notice from Swype that a new version was 
released recently. Downloaded it to my phone and the backspace key is now 
working perfectly. Thanks everyone! :)

Original comment by pdrago...@gmail.com on 13 Sep 2010 at 8:55

GoogleCodeExporter commented 8 years ago
Where did you get the new Swype Version? Galaxy S user here with no idea where 
to get a recent One...

Original comment by steinb...@gmail.com on 14 Sep 2010 at 12:27

GoogleCodeExporter commented 8 years ago
You should get an email from Swype to the email address you registered for the 
beta with. It contains a link for you to download a new installer. If your 
phone came with Swype pre-installed, you'll have to contact your manufacturer.

Original comment by pdrago...@gmail.com on 14 Sep 2010 at 1:33

GoogleCodeExporter commented 8 years ago
To make the backspace work in connectbot..use the steps as below:
1. edit the host (tap few seconds on the saved host)
2. select DEL Key
3. choose Backspace
4. done...now the backspace key will works...

Original comment by unreveab...@gmail.com on 10 Jun 2014 at 10:51