Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Enter key is filtered #30

Open
Bluebugs opened this issue Apr 30, 2023 · 7 comments
Open

Enter key is filtered #30

Bluebugs opened this issue Apr 30, 2023 · 7 comments

Comments

@Bluebugs
Copy link

Connecting via ssh to a Mikrotik router, the return key is not working. This is true with sshterm, but also when using ssh in fyneterm to connect to it.

It is working correctly when connecting to a linux host. And it is working correctly from other terminal when sshing to the router.

I guess something is somehow not interpreting the return key properly.

@andydotxyz
Copy link
Member

Enter or Return or both? (You mentioned both)

@Bluebugs
Copy link
Author

My keyboard doesn't make a difference between the two.

@andydotxyz
Copy link
Member

In fyne_demo advanced tab which keys are listed as being tapped?

@Bluebugs
Copy link
Author

Bluebugs commented May 1, 2023

In the case of the main return key, I get Return and in the case of the numpad I get KP_Enter. In both case, shell through ssh is not interpreting it.

@andydotxyz
Copy link
Member

Is there a set of steps where we can replicate this? SSH is working great in my tests.

@Bluebugs
Copy link
Author

Bluebugs commented May 1, 2023

I think I figured out the issue. We need to detect the CRLF mode of the terminal like terminology does: https://github.com/borisfaure/terminology/blob/master/src/bin/termptyesc.c#L381 and then based on that information emit \r\n when needed as done here: https://github.com/borisfaure/terminology/blob/master/src/bin/keyin.c#L136

@Bluebugs
Copy link
Author

I looked at it a bit more and it is the escape for private mode which is to simplistic and we are missing a lot there compared to terminology code. I will see if I can work on a patch, but it seems that there is a bit of information that need to be carried over that isn't yet (maybe, I haven't understood the code fully yet).

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants