-
-
Notifications
You must be signed in to change notification settings - Fork 145
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
ad-tag-include shows up in non-asciidoc files' auto complete #632
Comments
Thanks for reporting this accurately will all necessary details. Yes, the fix you suggest should fix it. Do you want to provide a pull request? |
Looking at #450 (comment) this might have been intended? |
Hm, you're right. Thanks for doing the research. So it makes sense to keep it for all languages, as includes would work in all languages. Could this be better clarified to avoid surprises in the future? |
I don't think it's a good idea to use AsciiDoc includes in other languages.
While it would work, it really breaks the spirit of the separation and
blurs the lines of what AsciiDoc is. If someone wants to do it, that's
their choice, but the IDE shouldn't encourage it.
|
@mojavelinux - my last comment was not as precise as it could have been: it is about adding tags to source code files of other languages that will then be used as tags for includes in AsciiDoc. The following recoding shows how it works inpractice. The hot-key is Ctrl+Alt+T. It adds line comments (for example |
Finally found how to disable it( |
@ahus1 Thanks for clarifying and my apologies for the confusion. That makes perfect sense. |
@dblanovschi - I assume that this feature would be hard to discover for users it it would be opt-in. Having it as a live template to create an empty tagged snipped to be included and as a surround-with... is helpful for those who want to include source code snippets in their AsciiDoc documents. I'll update the description "Surround with Tag for include macro" to make it more descriptive. I recommend that you disable it as you described above if you think you'll not going to use it. |
Ok, thank you |
Updated description of live template. Update docs in dc7842c for Live Templates; also added entry to FAQ. |
Since a couple of days typing I'm not sure if that was a change in the plugin, something JB did or if I messed up a setting. |
Yeah it's super annoying (same as @markushaslinger). I don't think the tag include should be live template either, I'd rather have this as an intention action. For me it shows everywhere I type english text, e.g. in github PR review comment component : @ahus1 I would really revisit this ! E.g. IJ also has surround actions, and now they appear in their editor floating bar which might be a better fit. |
I did another search, and there is this usability issue in tracked for IntelliJ: https://youtrack.jetbrains.com/issue/IDEABKL-7114 They describe how to disable live templates to show up in the auto-completion by changing the registry entry I'm having another look if this can be suppressed somehow in a more standard way. |
@bric3 - the template still makes sense if you start with an include tag in a non-AsciiDoc file and then start typing the content between the start and end. Again, I'll have another look how this can be changed in addition to the registry option stated above. |
Yeah but I do like to have the other live template in the completion. |
Observed vs. expected behavior
ad-tag-include
shows up on auto complete everywhere, instead of only in asciidoc files.Steps to reproduce
Type
a
in any open editor that is not an asciidoc file(a rust file in this image)Environment
Plugin Version: 0.32.7
IntelliJ Details: CLion 2020.3.1
Build #CL-203.6682.181, built on December 30, 2020
Runtime version: 11.0.9.1+11-b1145.63 amd64
VM: OpenJDK 64-Bit Server VM by JetBrains s.r.o.
Linux 5.9.14-arch1-1
GC: ParNew, ConcurrentMarkSweep
Memory: 1987M
Cores: 4
Registry: run.processes.with.pty=TRUE, debugger.watches.in.variables=false, ide.tree.collapse.recursively=false, ide.balloon.shadow.size=0
Non-Bundled Plugins: GLSL, IdeaVIM, Key Promoter X, SmarterEditor, String Manipulation, com.alayouni.ansiHighlight, com.chrisrm.idea.MaterialThemeUI, com.fernandojimenez.obsidian.theme, com.intellij.copyright, com.intellij.ideolog, com.intellij.plugins.visualstudiokeymap, com.intellij.plugins.vscodekeymap, com.mallowigi, com.nasmlanguage, com.samdark.intellij-visual-studio-code-dark-plus, idea.goyacc, io.allandequeiroz.random.image.background, nb-mind-map-idea, net.seesharpsoft.intellij.plugins.file-preview, net.vektah.codeglance, org.editorconfig.editorconfigjetbrains, org.jetbrains.plugins.hocon, com.codestream.jetbrains-codestream, uk.co.ben-gibson.remote.repository.mapper, zielu.gittoolbox, com.almightyalpaca.intellij.plugins.discord, mobi.hsz.idea.gitignore, com.jetbrains.codeWithMe, name.kropp.intellij.makefile, Docker, org.toml.lang, tv.codely.codelytv-theme, org.exbin.deltahex.intellij, org.asciidoctor.intellij.asciidoc, org.rust.lang, com.github.ArtsiomCh.NestedBracketsColorer, com.mdrobnak.intellij-lalrpop, ru.adelf.idea.dotenv
Current Desktop: GNOME
Possible fix?
Change this line to
Or at least add an option to disable it?
The text was updated successfully, but these errors were encountered: