相关文章推荐
酷酷的金针菇  ·  日文顏色Color Names in ...·  6 月前    · 
文雅的山楂  ·  Anti-GFP (Green ...·  6 月前    · 
眉毛粗的风衣  ·  fluent(fluent的名词)-速石科技·  7 月前    · 
威武的苦咖啡  ·  1980 SUZUKI GSX250 | ...·  7 月前    · 
没有腹肌的鞭炮  ·  李克强:不能说中国已经出现通货紧缩_评论_政 ...·  1 年前    · 
小百科  ›  How to set leader key for vim mode and some keybindings using it? - Help - Obsidian Forum
vim
帅气的刺猬
2 年前
Things I have tried
  • Putting let mapleader = " " in my .obsidian.vimrc file but it doesn’t work
  • setting keybinding (in .obsidian.vimrc ) like this:
  • exmap openGraph obcommand graph:open
    nmap <leader>og openGraph
    

    but it won’t work without setting the leader key first.

    What I’m trying to do

    I’m trying to set leader key to space and set some keybindings with it.
    I googled and searched this forum a lot today and I can’t find a single example of setting the leader key. Can anybody help me with it? Thank you.

    I unmapped space in my .obsidian.vimrc with unmap <Space>. Now what? How to map space as leader or create key chord with it? I tried adding this to my .obsidian.vimrc:

    exmap openGraph obcommand graph:open
    nmap <leader>og openGraph
    nmap <Space>og openGraph
    

    But pressing <Space> o g in normal mode doesn’t display graph (it only creates new line as if I pressed only o). What am I missing? When I run manually :openGraph it works as it should.

    Thank you very much, it works now!

    It works when I use Space directly like this:
    nmap <Space>og :openGraph

    Do you know if it is actually possible to set space as leader key and use <leader> notation in my .obsidian.vimrc? Like this:
    nmap <leader>og :openGraph

    Kossak:

    Do you know if it is actually possible to set space as leader key and use <leader> notation

    Sorry I haven’t tried it.

     
    推荐文章
    酷酷的金针菇  ·  日文顏色Color Names in Japanese|免費日文教材東大前TODAIMAE ...
    6 月前
    文雅的山楂  ·  Anti-GFP (Green Fluorescent Protein) pAb(Polyclonal, Polyclonal ...
    6 月前
    眉毛粗的风衣  ·  fluent(fluent的名词)-速石科技
    7 月前
    威武的苦咖啡  ·  1980 SUZUKI GSX250 | Sat 5th &amp; Sun 6th April | Anglia Car Auctions
    7 月前
    没有腹肌的鞭炮  ·  李克强:不能说中国已经出现通货紧缩_评论_政策法规解读_政策_ ...
    1 年前
    今天看啥   ·   Py中国   ·   codingpro   ·   小百科   ·   link之家   ·   卧龙AI搜索
    删除内容请联系邮箱 2879853325@qq.com
    小百科 - 百科知识指南
    © 2024 ~ 沪ICP备11025650号