Skip to content
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

建议给关键词高亮添加优先级,以及正则表达式匹配好像有bug #3680

Open
WoChen5770 opened this issue Dec 3, 2024 · 3 comments

Comments

@WoChen5770
Copy link

WoChen5770 commented Dec 3, 2024

What feature you'd like to see or proposal(期望什么新功能/特性或者建议)

1.建议给关键词高亮添加优先级,比如下列正则表达式
IP地址与端口号:(\d+.){3}\d+(:\d+)?
数字:\b(\d+)(.\d+)?\b
2. 设置一个IP地址的正则表达式(\d+\.){3}\d+(:\d+)? 和一个文件大小 的正则表达式 \b\d+(\.\d+)?[KMGTP]i?B?\b ,会使终端出现一些不应该出现的字符0m(图一只有IP地址的正则表达式)
image
image

@zxdong262
Copy link
Member

两个正则不能交叉匹配,否则就会发生这种情况

@WoChen5770
Copy link
Author

两个正则不能交叉匹配,否则就会发生这种情况

建议添加优先级来处理正则,像tabby,Xterminal都是这样处理的

@zxdong262
Copy link
Member

感谢反馈,将在下个版本修复

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants