atom / autocomplete-plus Goto Github PK
View Code? Open in Web Editor NEWView and insert possible completions in the editor while typing
License: MIT License
View and insert possible completions in the editor while typing
License: MIT License
I'd love to see this get file path autocompletion like neocomplete does: https://github.com/Shougo/neocomplete.vim
Great plugin!
Perhaps it's just me being use to the editor I came from before Atom but I would love to make autocomplete be 100% case sensitive. To me foo
is completely different from Foo
and when I type Fo
I don't want to be presented with foo
as an autocomplete option.
Would be really great if the provider API worked with both.
The worst thing that could happen is if the atom package implemented a different API. Then authors would have to either choose one, or support both. Neither of those is a great option.
I don't know how this is architected internally, and maybe its difficult to upstream as its currently written. But if that isn't the case, would be great.
Hi, I'm trying your plugin but it's clearly not working as expected, on my install. When I type something, after one or two chars, the autocomplete box pops up, and if I keep typing it doesn't go away. The only way to close it is either hit Esc
or select an autocomplete option with Up
and Down
and then hitting Enter
.
Here are my current settings.
Thanks for your work!
The tooltip with the suggestions shouldn't have an option selected by default.
Im using this with the "live completion" enabled, but because of the default selection I can't using in conjunction with emmet or even with my custom snippets. This happens because when I try to expand a snippet, most of the times there's a autocomplete suggestion that will expand instead.
Hello,
when having autocomplete plus installed and switching to the Korean 2 set input, the editor goes crazy. A single character will result in a line of Korean characters, keyboard navigation is no longer working and mouse interaction neither.
The only way to recover from this state is to cmd+w the tab, discard changes and open again, this time with US layout.
Tested on 2 Macbooks running OS X 10.9.2.
Atom version 0.85.9
Korean layout used is the normal 2 set one that ships with OS X.
Other editors like Sublime Text allow you to disable "Accepting" a suggestion on enter. For example, I get to the end of a line, and hit enter to return to the next line, but there was a suggestion that gets accepted instead.
In ST when you disable accept on enter, if there is a suggestion when you hit enter, it just returns to the next line. This would be my preferred behavior.
Steps to reproduce:
Uncaught TypeError: Cannot call method 'getBufferPosition' of undefined /Applications/Atom.app/Contents/Resources/app/src/editor.js:1246
It seems that it's trying to get the caret position for autocomplete on the file that was just saved and closed.
Other packages should be able to use the Autocomplete+ UI
Since we only generate the wordlist from time to time, it might contain suggestions for the wrong scope. Solution: Don't put scope words into the wordlist per default, just merge them with the wordlist every time we display suggestions.
When using d or manually selecting multiple instances of a symbol and autocompleting will append the entire autocompletion to the stubs of every selection but the last. For example:
<div cla>
...
<div cla>
...
<div cla>
selecting all of the 'cla' and typing 'clas', then tab completing to 'class' will result in
<div clasclass>
...
<div clasclass>
...
<div class>
It seems that once you've finished a "word", it gets removed from the list of candidates. But then what happens is if you hit "tab", what you've typed will get completely replaced with a very different word.
Here's an example in Java, with the words thread
and Thread
. When you start typing say the first few characters of thread
, the primary suggested match is thread
as expected, but when I type the last letter (d
), it suddenly changes to Thread
. Exact opposite thing happens when typing Thread.
Also in general, I think matching case should take higher priority for selecting the first match, or at least there should be an option. In this example, I think downloadThread
should be the main suggestion instead of DownloadTask
.
Otherwise the overlay won't detach until you trigger another autocompletion.
In ruby i am getting autocompletion on keywords like 'do'. The keyword is not in the suggestions list so you end up with something like 'double' instead
... it also fails locally too.
https://travis-ci.org/saschagehlich/autocomplete-plus/builds/23970446
Autocomplete > AutocompleteView > when auto-activation is enabled > it sets the width of the view to be wide enough to contain the longest completion without scrolling (+ 15 pixels):
TypeError: Cannot read property 'length' of undefined
Maybe add the option for it at least?
When editing a Markdown or Ruby, if I hit Return while the autocomplete box is open, it will enter a carriage return but not allow me to type anything else. I have to move to a new tab or Cmd-Tab out of the app and back in order to regain my control.
Window load time: 720ms /Applications/Atom.app/Contents/Resources/app/src/window-bootstrap.js:18
2
Uncaught TypeError: Cannot call method 'getBufferRange' of undefined /Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/history.js:99
23
Uncaught TypeError: Cannot call method 'getBufferRange' of undefined fuzzy-provider.coffee:95
Uncaught TypeError: Cannot call method 'getBufferRange' of undefined /Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/history.js:99
Uncaught TypeError: Cannot call method 'getBufferRange' of undefined /Applications/Atom.app/Contents/Resources/app/node_modules/atom-keymap/lib/keymap-manager.js:390
It would be really helpful if snippets could be part of the completion list. Currently you have to esc from the suggested completions and then tab complete the snippet.
That title is a bit of a mouthful. After completing redraw
in the scenario above, the dialog pops back up with Redraw
. Maybe the fix is case-insensitive matching or disable the dialog until the next keystroke after an autocomplete has been accepted.
class Redraw
redraw = -> console.log 'foo'
red # confirm this completion
If there are suggestions present when I save the file, the suggestions should be dismissed. Save implies I'm already done. Thoughts?
Nice work btw. I was used to this feature in Sublime Text.
I have so many issues using this, as I am used to autocomplete-confirm with the ENTER key, instead of tab. Would love a way to configure this in the settings pane. Could this be added?
Right now we're listening for the "contents-modified" on the editor. We should switch to a custom delay instead (default 0).
I just installed this fresh after uninstalling. Quit Atom and re-opened, just to make sure. Menu with autocomplete suggestions never comes up. Something I need to do that I'm not seeing in the Readme?
As propsed by @pjv, we should add some priority stuff to the suggestions:
Steps to reproduce:
Indentation lags by 15-20 seconds.
Attaching a few views of the console timeline.
How to reproduce:
open a folder with atom, with some files inside
open a file in the editor
hit cmd+k and an arrow to make a split panel
hit cmd+w to close the new panel
now whenever you hit cmd+s to save, you get the dev tools with the below error
Uncaught TypeError: Cannot call method 'getBufferPosition' of undefined
If I disable the plugin, save behaves normally and I don't get the dev tools.
Thoughts?
This way we would not have to rebuild the list on save and the autocompletion would always be up-to-date.
Having it live seems to bothersome when I'm writing comments. What about turning it off when I'm writing comments, or only turn it on after a slight delay?
For example: i got "foo" and "foo_bar" in my word list, after completing foo, foo_bar is suggested, it should not appear because i have already confirmed my choice.
e.g. constructor
e.g. three.js
has 38k LOC and autocompletion is pretty slow
When using my package 'git-plus' to save a commit message file, this gets thrown the first time core:save is triggered but saving will work the second time.
Stack trace:
Uncaught TypeError: Cannot read property 'length' of undefined
/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:154
module.exports.TextBuffer.lineLengthForRow
/Applications/Atom.app/Contents/Resources/app/node_modules/text-buffer/lib/text-buffer.js:154
module.exports.Editor.lineLengthForBufferRow
/Applications/Atom.app/Contents/Resources/app/src/editor.js:429
module.exports.FuzzyProvider.lastTypedWord
fuzzy-provider.coffee:104
module.exports.FuzzyProvider.addLastWordToList
fuzzy-provider.coffee:81
module.exports.FuzzyProvider.onChanged
fuzzy-provider.coffee:73
(anonymous function)
fuzzy-provider.coffee:1
The error only occurs when a new line isn't entered in the commit message.
It seems to me as if the newLine variable is true when it should be false because there is no \n
or ' '
This could be related to #13.
Steps to reproduce:
Atom Helper
process jumping to around 99% usage, while the down arrow is being pressed.Note when autosave is disabled cursor moves with less lag.
The arrows are quite far from the home-row ๐
Curently, runAutocompletion is an synchronous API, calling each Provider in order for suggestions. It might be more appropriate to make this an asynchronous, event-driven API. This presents obvious challenges for aggregation of suggestions, but should discourage any misbehaving providers from blocking unnecessarily.
Running this with Autosave on causes the file to get repeated "This file has changed on disk" warnings, requiring a reload of the file.
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.