ashthespy / Atom-LaTeX

The only LaTeX package you need for typesetting with Atom.
https://atom.io/packages/atom-latex
MIT License
22 stars 9 forks source link

Autocomplete on atom+windows #269

Closed mmarras closed 3 years ago

mmarras commented 3 years ago

Hi, I am struggling to get autocomplete to work on windows (this doesn't imply that I have another non-win system on which it works).

Failure: Does not autocomplete Expected Behavior: typing \begin{document} should trigger to issue \end{document}. Reproduce: Make latex document type \begin{document}

win10, Atom : 1.54.0 Electron: 6.1.12 Chrome : 76.0.3809.146 Node : 12.4.0

Anything that I need to set-up before it it works, or should be out of the box?

ashthespy commented 3 years ago

Anything fishy turning up on your dev console? It should work OTB..

mmarras commented 3 years ago
C:\Users\#####\AppData\Local\atom\app-1.52.0\resources\app.asar\src\text-editor-element.js:357 [Deprecation] document.registerElement is deprecated and will be removed in M80, around February 2020. Please use window.customElements.define instead. See https://www.chromestatus.com/features/4642138092470272 and https://developers.google.com/web/updates/2019/07/web-components-time-to-upgrade for more details.
(anonymous) @ C:\Users\######\AppData\Local\atom\app-1.52.0\resources\app.asar\src\text-editor-element.js:357
<embedded>:11 No deserializer found for http://127.0.0.1:58072/viewer.html?file=preview.pdf
deserialize @ <embedded>:11
2C:\Users\######\.atom\packages\turtle-completer\lib\turtle-provider.coffee:19 Config change false for 
2<embedded>:14 TrustedTypes policy dompurify could not be created.
_createTrustedTypesPolicy @ <embedded>:14
manager.coffee:213 RootWatcher Init: 48.807861328125ms

Not to me, but no clue.

ashthespy commented 3 years ago

-- Do you have any conflicting Latex packages? -- Can you share a quick screen cap of what is happening? For reference, it should look something like this

mmarras commented 3 years ago

No other latex package in atom installed.

It is doing something at least when you manually close an itemize environment is throws in an \item. But please see a screen capture of the situation as requested.

ashthespy commented 3 years ago

You need to hit tab for autocomplete.. So \begin tab and then select what environment is required..

mmarras commented 3 years ago

Thanks for taking the time to work with me on this! Autocompletion works now.

But to be honest, I would have hoped it to be more robust: opening { breaks it. using the cursor with the keyboard-arrow in-between also breaks it, I move two cursors around then 😨. So really one needs to press tabs for right time and once in that mode, don't do something stupid. Btw. begin{document} is not in the list of autocompletions?

ashthespy commented 3 years ago

This isn't some thing the package can control directly, it's the the normal autocomplete API of most text editors.. Here we use the default Atom API.