vim:在正常模式下键入<Enter>时,标签栏窗口会打开

如何解决vim:在正常模式下键入<Enter>时,标签栏窗口会打开

在安装了标签栏插件的Vim中以普通模式键入时,标签栏窗口将自动打开。我想禁用此功能。我该怎么办?

解决方法

尝试:help标签栏以打开文档。听起来您的vimrc文件中可能有一个映射,内容类似于

nnoremap <silent> <CR> :TagbarToggle<CR>

nnoremap <silent> <CR> :TagbarOpen<CR>

如果找到并删除该映射,将不再打开标签栏

,

您对/WEB-INF/web.xml的映射实际上是Enter键打开标签栏的原因。如果您从vimrc中删除该地图,则Enter键将不再触发package com.android.usb; import androidx.appcompat.app.AppCompatActivity; import java.util.HashMap; import java.util.Iterator; import android.app.Activity; import android.app.PendingIntent; import android.content.BroadcastReceiver; import android.content.Context; import android.content.Intent; import android.content.IntentFilter; import android.hardware.usb.UsbDevice; import android.hardware.usb.UsbManager; import android.os.Bundle; import android.util.Log; import android.view.View; import android.view.View.OnClickListener; import android.widget.Button; import android.widget.TextView; import java.util.HashMap; import java.util.Iterator; public class MainActivity extends AppCompatActivity { private static final String ACTION_USB_PERMISSION = "com.android.usb.USB_PERMISSION"; Button btnCheck; TextView textInfo; UsbManager usbManager; @Override protected void onCreate(Bundle savedInstanceState) { super.onCreate(savedInstanceState); setContentView(R.layout.activity_main); btnCheck = (Button) findViewById(R.id.check); textInfo = (TextView) findViewById(R.id.info); btnCheck.setOnClickListener(new View.OnClickListener() { @Override public void onClick(View arg0) { textInfo.setText(""); checkInfo(); } }); } private void checkInfo() { UsbManager manager = (UsbManager) getSystemService(Context.USB_SERVICE); PendingIntent permissionIntent = PendingIntent.getBroadcast(this,new Intent(ACTION_USB_PERMISSION),0); IntentFilter filter = new IntentFilter(ACTION_USB_PERMISSION); registerReceiver(usbReceiver,filter); HashMap<String,UsbDevice> deviceList = manager.getDeviceList(); Iterator<UsbDevice> deviceIterator = deviceList.values().iterator(); String i = ""; while(deviceIterator.hasNext()) { UsbDevice device = deviceIterator.next(); usbManager.requestPermission(device,permissionIntent); i += "\n" + "DeviceID: " + device.getDeviceId() + "\n" + "DeviceName: " + device.getDeviceName() + "\n" + "DeviceClass: " + device.getDeviceClass() + " - " + "DeviceSubClass: " + device.getDeviceSubclass() + "\n" + "VendorID: " + device.getVendorId() + "\n" + "ProductID: " + device.getProductId() + "\n"; } textInfo.setText(i); } /*---------------------------------------------------------------------------------------------------*/ private final BroadcastReceiver usbReceiver = new BroadcastReceiver() { public void onReceive(Context context,Intent intent) { String action = intent.getAction(); if (ACTION_USB_PERMISSION.equals(action)) { synchronized (this) { UsbDevice device = (UsbDevice)intent.getParcelableExtra(UsbManager.EXTRA_DEVICE); /*-----------------------------------------------------------------------------------*/ if (intent.getBooleanExtra(UsbManager.EXTRA_PERMISSION_GRANTED,false)) { if(device != null) { //call method to set up device communication } } else { Log.d("ERROR","permission denied for device " + device); } } } } }; /*------------------------------------------------------*/ }

Mappings for <C-m> and <CR> (Enter) are synonymous in Vim:

下表显示了键盘上的某些键与等效的Ctrl键组合之间的映射:

Ctrl-I选项卡
Ctrl- [Esc
Ctrl-M Enter
Ctrl-H退格键

如果在地图的上表中使用Ctrl键组合之一,则该地图也将应用于相应的键。两个键产生相同的键扫描代码。例如,如果您为CTRL-I创建一个映射,则可以通过按Ctrl-I或Tab键来调用该映射。

这意味着当您设置<C-m>时,它与 还设置:TagbarToggle

您可能想选择一个新的密钥而不是M。 在操作系统级别更改nmap <C-m> :TagbarToggle<CR>发送的密钥 重新映射程序。

终端键绑定来自readline,readline是处理输入文本的程序 您的终端提示。 readline manual中包含键绑定的完整列表。

您可以通过在Vim中键入nmap <CR> :TagbarToggle<CR>或阅读帮助文档here来找到有关Vim密钥代码的更多信息。

版权声明:本文内容由互联网用户自发贡献,该文观点与技术仅代表作者本人。本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌侵权/违法违规的内容, 请发送邮件至 dio@foxmail.com 举报,一经查实,本站将立刻删除。

相关推荐


依赖报错 idea导入项目后依赖报错,解决方案:https://blog.csdn.net/weixin_42420249/article/details/81191861 依赖版本报错:更换其他版本 无法下载依赖可参考:https://blog.csdn.net/weixin_42628809/a
错误1:代码生成器依赖和mybatis依赖冲突 启动项目时报错如下 2021-12-03 13:33:33.927 ERROR 7228 [ main] o.s.b.d.LoggingFailureAnalysisReporter : *************************** APPL
错误1:gradle项目控制台输出为乱码 # 解决方案:https://blog.csdn.net/weixin_43501566/article/details/112482302 # 在gradle-wrapper.properties 添加以下内容 org.gradle.jvmargs=-Df
错误还原:在查询的过程中,传入的workType为0时,该条件不起作用 &lt;select id=&quot;xxx&quot;&gt; SELECT di.id, di.name, di.work_type, di.updated... &lt;where&gt; &lt;if test=&qu
报错如下,gcc版本太低 ^ server.c:5346:31: 错误:‘struct redisServer’没有名为‘server_cpulist’的成员 redisSetCpuAffinity(server.server_cpulist); ^ server.c: 在函数‘hasActiveC
解决方案1 1、改项目中.idea/workspace.xml配置文件,增加dynamic.classpath参数 2、搜索PropertiesComponent,添加如下 &lt;property name=&quot;dynamic.classpath&quot; value=&quot;tru
删除根组件app.vue中的默认代码后报错:Module Error (from ./node_modules/eslint-loader/index.js): 解决方案:关闭ESlint代码检测,在项目根目录创建vue.config.js,在文件中添加 module.exports = { lin
查看spark默认的python版本 [root@master day27]# pyspark /home/software/spark-2.3.4-bin-hadoop2.7/conf/spark-env.sh: line 2: /usr/local/hadoop/bin/hadoop: No s
使用本地python环境可以成功执行 import pandas as pd import matplotlib.pyplot as plt # 设置字体 plt.rcParams[&#39;font.sans-serif&#39;] = [&#39;SimHei&#39;] # 能正确显示负号 p
错误1:Request method ‘DELETE‘ not supported 错误还原:controller层有一个接口,访问该接口时报错:Request method ‘DELETE‘ not supported 错误原因:没有接收到前端传入的参数,修改为如下 参考 错误2:cannot r
错误1:启动docker镜像时报错:Error response from daemon: driver failed programming external connectivity on endpoint quirky_allen 解决方法:重启docker -&gt; systemctl r
错误1:private field ‘xxx‘ is never assigned 按Altʾnter快捷键,选择第2项 参考:https://blog.csdn.net/shi_hong_fei_hei/article/details/88814070 错误2:启动时报错,不能找到主启动类 #
报错如下,通过源不能下载,最后警告pip需升级版本 Requirement already satisfied: pip in c:\users\ychen\appdata\local\programs\python\python310\lib\site-packages (22.0.4) Coll
错误1:maven打包报错 错误还原:使用maven打包项目时报错如下 [ERROR] Failed to execute goal org.apache.maven.plugins:maven-resources-plugin:3.2.0:resources (default-resources)
错误1:服务调用时报错 服务消费者模块assess通过openFeign调用服务提供者模块hires 如下为服务提供者模块hires的控制层接口 @RestController @RequestMapping(&quot;/hires&quot;) public class FeignControl
错误1:运行项目后报如下错误 解决方案 报错2:Failed to execute goal org.apache.maven.plugins:maven-compiler-plugin:3.8.1:compile (default-compile) on project sb 解决方案:在pom.
参考 错误原因 过滤器或拦截器在生效时,redisTemplate还没有注入 解决方案:在注入容器时就生效 @Component //项目运行时就注入Spring容器 public class RedisBean { @Resource private RedisTemplate&lt;String
使用vite构建项目报错 C:\Users\ychen\work&gt;npm init @vitejs/app @vitejs/create-app is deprecated, use npm init vite instead C:\Users\ychen\AppData\Local\npm-