Code Monkey home page Code Monkey logo

Comments (9)

Airblader avatar Airblader commented on July 16, 2024

I usually use Ctrl-J to validate something, and would like to have that feature in i3lock also.

I think this captures the problem perfectly: everybody would want something else. However, we don't want a generic binding configurability in i3lock because it would make it a whole lot more complex and therefore potentially unsafe.

IMHO you'd be best served by implementing this as a local patch.

from i3lock.

acrisci avatar acrisci commented on July 16, 2024

I don't use i3lock, but I could see why the user base would consider this feature valuable by giving i3lock a "terminal" feel. Ctrl-j will enter a password that you enter from a terminal, for instance.

As for this being a gateway to bindings in i3lock, I don't think that would be the case. However, it would be a gateway to supporting any of the emacs-based terminal commands (such as ctrl-h for backspace, ctrl-u for kill line) which might be complicated and is definitely would be an increase of scope for i3lock. I'm not sure if there is a library that already handles that kind of user input but there might be.

I don't feel strongly either way about this, however. i3lock would be very easy to fork and make your own project out of with more scope.

from i3lock.

bew avatar bew commented on July 16, 2024

everybody would want something else
Yes maybe, but here, C-j is not really a user-special-case..
In almost every terminal program, C-j is handled as Enter

As we don't need readline abilities (like moving the cursor, etc) but only key inputs then Enter, I don't think that multiple ways to type "Enter" is too much.

I'm I clear enough?

from i3lock.

acrisci avatar acrisci commented on July 16, 2024

Now that I think about it, I can't imagine this exploding into either bindings or readline. If you make ctrl-j work however, people will expect ctrl-h for backspace as well.

Maybe @Airblader is not aware that this is a widely used standard in interactive unix programs and text editors (maybe from before there was an enter key or something? I don't know.).

from i3lock.

He-Ro avatar He-Ro commented on July 16, 2024

Chiming in here. I think that, ctrl-u would also be expected to work, if crtl-j is supported. ctrl-u deletes the whole line before the cursor. Thus I think it should delete the whole passphrase that was entered until that point, because the cursor is always at the end.

from i3lock.

Airblader avatar Airblader commented on July 16, 2024

So Ctrl+J now already went to Ctrl+J, Ctrl+U, Ctrl+H in less than 24 hours. See my point?

from i3lock.

karulont avatar karulont commented on July 16, 2024

Ctrl+U is already in the code. I know that every feature adds unwanted complexity to i3lock. But I think in this case a few lines to add support for the Ctrl+J and Ctrl+H are not that complex. To me adding them now seems like a "bug" fix, because the three keys form a whole, and Ctrl+U is alone at the moment. One option would be to remove Ctrl+U, however that would break someones workflow. So I propose that these minor features should be added.

from i3lock.

stapelberg avatar stapelberg commented on July 16, 2024

Given that we already support the keypad return key as an alternative to return, I think adding ctrl+j would be okay — it should be just another case statement.

from i3lock.

bew avatar bew commented on July 16, 2024

You did it, thanks all!

from i3lock.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.