首页
学习
活动
专区
圈层
工具
发布
社区首页 >问答首页 >如何在单击Ctrl时使urxvt打开链接

如何在单击Ctrl时使urxvt打开链接
EN

Unix & Linux用户
提问于 2021-04-24 11:28:07
回答 1查看 755关注 0票数 0

当前urxvt识别链接并给它们下划线。点击时,它会在firefox中打开它们。以下是我目前的.Xresources:

代码语言:javascript
复制
URxvt.perl-ext:           default,matcher
URxvt.url-launcher:       firefox
URxvt.matcher.button:     1
URxvt.matcher.pattern.1:  \\bwww\\.[\\w-]+\\.[\\w./?&@#-]*[\\w/-]

我希望urxvt在默认情况下不要在链接下划线。我希望它只在鼠标超过它们的时候划出它们的下划线。我还希望urxvt在单击它们时什么也不做,但是在用Ctrl键单击urxvt时打开它们。

EN

回答 1

Unix & Linux用户

发布于 2022-03-07 06:51:07

您可以在按钮号码前面插入C-(控制)、S-(Shift)或M-(Meta/Alt)。因此,您可以在例如~/.Xresources中使用以下一行

代码语言:javascript
复制
! Only execute `launcher` on matched String when using 'Control + Left-Mouse-Button'
URxvt.matcher.button:     C-1
! Only execute `launcher` on matched String when using 'Shift + Middle Mouse-Button'
! URxvt.matcher.button:     S-2
! Only execute `launcher` on matched String when using 'Meta(alt) + Middle Mouse-Button'
! URxvt.matcher.button:     M-2

我猜Shift/AltGr在代码中查看有效_按钮时也在工作,但我自己还没有尝试过。

我也回答不了这个问题。我猜你得稍微修改一下代码。

我只能推荐一些像URxvt.keysym.C-M-Delete: matcher:select这样的东西,只需跳过你的箭头键,然后选择你的对手。

票数 3
EN
页面原文内容由Unix & Linux提供。腾讯云小微IT领域专用引擎提供翻译支持
原文链接:

https://unix.stackexchange.com/questions/646514

复制
相关文章

相似问题

领券
问题归档专栏文章快讯文章归档关键词归档开发者手册归档开发者手册 Section 归档