GithubHelp home page GithubHelp logo

Comments (11)

vifon avatar vifon commented on June 11, 2024

I could not reproduce it. Can you provide some more information?

Does calling perl:aAtt:undo in the last step instead of WORD-complete erase the characters too?

from autocomplete-all-the-things.

Lompik avatar Lompik commented on June 11, 2024
  • In Step 3, when hitting the the WORD-complete key I see highligh showing on comple1.
  • Calling perl:aTT:undo in Step 2 between <C-M-/> and Enter
  • Calling perl:aTT:undo in Step 3 before <C-M-/> erase the characters too

The only tweak i did in source file was to use $char_class_before = '\b'; instead of "\s" for the WORD-complete. Is it reproducible with that tweak ?

from autocomplete-all-the-things.

vifon avatar vifon commented on June 11, 2024

It seems $self->{last_word} is not resetting correctly. And it is done in the leave() function called from conditional_leave(). I still can't reproduce it, sadly. You could try to add a few warn statements to see what is being evaluated (and when) and what is not. Run urxvt from a terminal (even from another urxvt) and the output from warns should be there.

from autocomplete-all-the-things.

Lompik avatar Lompik commented on June 11, 2024

Thanks !

it seems like conditional_leave never enters the if confition as $event->{'state'} is always >2 (ie in the 16..25 range) . I'm not sure where that variable comes from though.

from autocomplete-all-the-things.

vifon avatar vifon commented on June 11, 2024

Maybe @seletskiy will be able to help, as he was the one that added this check. All I know about this variable is what he has described in this pull request: #9.

If you use urxvt pre-9.21, you may try using the older plugin version.

from autocomplete-all-the-things.

Lompik avatar Lompik commented on June 11, 2024

Alright so this the values for the event->{'state'} :

# state bitmask: Shift = 1, Ctrl = 4, Alt = 8

But for unknown reason, on my system $event->{'state'} has 16 by default. So I changed the if condition as so :

if (($event->{'state'} & 14) < 2 &&

And issue is solved. I'm not sure why i have this weird value though. I can create a pull request if you see fit.

My urxvt info :

rxvt-unicode (urxvt) v9.21 - released: 2014-12-31
options: perl,xft,styles,combining,blink,iso14755,unicode3,encodings=eu+vn+jp+jp-ext+kr+zh+zh-ext,fade,transparent,tint,XIM,frills,selectionscrolling,wheel,slipwheel,cursorBlink,pointerBlank,scrollbars=plain+rxvt+NeXT+xterm
URxvt.perl-ext-common:      readline,matcher,selection-to-clipboard,keyboard-select,clipboard,autocomplete-ALL-the-things

from autocomplete-all-the-things.

seletskiy avatar seletskiy commented on June 11, 2024

@Lompik: do you have secondary keyboard layout? If so, then state value can depends on what keyboard layout is now active.

from autocomplete-all-the-things.

Lompik avatar Lompik commented on June 11, 2024

@seletskiy I have a modified xmodmap, I disabled caps-lock and move Control to caps . But not sure what you mean by secondary keyboard layout. It's probably this issue affects only me.

from autocomplete-all-the-things.

seletskiy avatar seletskiy commented on June 11, 2024

@Lompik: according to /usr/include/X11/X.h mask 16 = 1 << 4 stands for Mod2. Mod2 is a NumLock by default, check NumLock state, then.

from autocomplete-all-the-things.

Lompik avatar Lompik commented on June 11, 2024

@seletskiy you're right. Disabling numlock gets me the Shift = 1, Ctrl = 4, Alt = 8 values as initially expected. Are you guys not using Numlock ?

from autocomplete-all-the-things.

vifon avatar vifon commented on June 11, 2024

Makes sense. Thanks a lot, guys. I'll fix it when I get back from work. I was going to rewrite that part anyway (there are issues with using ctrl/alt+something right after using the completion).

Are you guys not using Numlock?

Not really. I don't even have a numpad.

from autocomplete-all-the-things.

Related Issues (17)

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.