GithubHelp home page GithubHelp logo

Comments (11)

derekelkins avatar derekelkins commented on June 25, 2024

There is no variable that controls this currently, but I can add it. It should only take a few minutes. You can also just comment out the runtime agda-utf8.vim line in ftplugin/agda.vim.

from agda-vim.

derekelkins avatar derekelkins commented on June 25, 2024

Okay, I just pushed 5bbc866 which add the variable g:agdavim_includeutf8_mappings which if you set it to 0 in your vimrc should cause the agda-utf8.vim file not to be loaded.

from agda-vim.

HalosGhost avatar HalosGhost commented on June 25, 2024

I attempted to comment out that runtime line as you suggested but it does not seem to have changed anything. Is there a chance something else is causing it to be loaded?

from agda-vim.

derekelkins avatar derekelkins commented on June 25, 2024

Not really in this project unless your bundling mechanism just loads every file in the root of the bundle. The string "agda-utf8.vim" only occurs on that line in the whole project. You can grep your .vim folder to see if something else is loading a version, if, for example, you followed the directions on the Agda vim editing wiki page at some point in the past. You could also just remove the agda-utf8.vim file and that would unambiguously make it clear whether that is where the mappings are coming from.

from agda-vim.

HalosGhost avatar HalosGhost commented on June 25, 2024

This is what confuses me. I have also tried deleting that file wholesale and the \ unicode escape still happens. But, this only happens for me in agda files, no where else. Do you know if the native vim agda syntax provides something like that?

from agda-vim.

derekelkins avatar derekelkins commented on June 25, 2024

So, are you sure the \ is leading into unicode? E.g. does \N produce a blackboard N? If not, it's just that the commands in the Agda mode use LocalLeader by default and that is \ by default (in fact, the Unicode mappings also use LocalLeader), so it may just be waiting for a command, e.g. \t to get types. You can write let maplocalleader = ',' in your vimrc, say, to change that (it just needs to run before the mappings are made and comma is just an example.)

from agda-vim.

derekelkins avatar derekelkins commented on June 25, 2024

The "Typing Unicode Characters" section on this page, refers to the files and setup for the Unicode mappings. You can check for e.g. after/syntax/agda.vim or for unicode-keys to see if any of those being run.

from agda-vim.

HalosGhost avatar HalosGhost commented on June 25, 2024

Indeed, they do produce unicode characters, however, I just noticed something that may give the key to the problem. It seems if I start a new source file, this behavior does not happen in the new file. Does vim cache this kind of thing somewhere?

from agda-vim.

HalosGhost avatar HalosGhost commented on June 25, 2024

Ah hah! I figured it out. This was indeed not an issue with agda-vim (my apologies for the noise). It seems $HOME/.vim/view contains some cached information about files that have been opened with vim. Clearing the relevant files after having disabled the agda-utf8.vim runtime has solved this issue.

Thank you for the help!

from agda-vim.

derekelkins avatar derekelkins commented on June 25, 2024

I'd be surprised if it did that across vim sessions (i.e. closing and reopening vim entirely). Of course, it won't reload the mappings, which are buffer local, if the buffer remains open.

from agda-vim.

HalosGhost avatar HalosGhost commented on June 25, 2024

Actually, they did persist across closing and reopening vim entirely. I had to clear the relevant files from the view directory in order to get it to update. This may very well be due to some archaic setting I have in my rc that I had forgotten about.

from agda-vim.

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.