如何在Find&替换MS Word
我有以下文本,我想匹配一条线,以便用蓝色格式化包含“ axy opyy”的整行,并用黄色的线包含“ nmj trui”
[3:57 p. m., 27/9/2021] Axy Opyy: A regular expression
[3:58 p. m., 27/9/2021] Nmj Trui: (shortened as regex or regexp;[1] sometimes
[4:19 p. m., 27/9/2021] Nmj Trui: referred to as rational expression[2][3])
[5:58 p. m., 27/9/2021] Nmj Trui: is a sequence of
[5:59 p. m., 27/9/2021] Axy Opyy: characters that specifies
[5:59 p. m., 27/9/2021] Nmj Trui: a search pattern
[0:13 p. m., 28/9/2021] Nmj Trui: in text.
我尝试了与通配符的不同组合选项,例如\ [?@[!^13]?@\] Axy Opyy:[!^13] {1,}
或(\ [?@2021 \]){1 } Axy Opyy:?@^13 ,但是在某些情况下,匹配多个行。每次匹配一行的正确正则是正确的言论?谢谢
更新
我当前的输出是此。我想向右移动一点点蓝色的线条。目前,左侧的空间仍在突出显示。有没有办法仅突出空间之后的文本?或插入子弹以使文本看起来像下面的图像一样对齐?
I have the following text, for which I´d like to match a single line in order to format with blue the whole lines that contains "Axy Opyy" and with yellow the lines that contains "Nmj Trui"
[3:57 p. m., 27/9/2021] Axy Opyy: A regular expression
[3:58 p. m., 27/9/2021] Nmj Trui: (shortened as regex or regexp;[1] sometimes
[4:19 p. m., 27/9/2021] Nmj Trui: referred to as rational expression[2][3])
[5:58 p. m., 27/9/2021] Nmj Trui: is a sequence of
[5:59 p. m., 27/9/2021] Axy Opyy: characters that specifies
[5:59 p. m., 27/9/2021] Nmj Trui: a search pattern
[0:13 p. m., 28/9/2021] Nmj Trui: in text.
I´ve tried different combinations with wildcard option, like \[?@[!^13]?@\] Axy Opyy:[!^13]{1,}
or (\[?@2021\]){1} Axy Opyy:?@^13
, but in several cases, matches more than one line. How would be the correct regex to match a single line each time? Thanks
UPDATE
My currently output is this. I´d like to shift to the right a little bit the lines that would be blue. Currently the space to the left is still highlighted. Is there a way to highlight only the text after the space?Or insert a bullet in order that the text look aligned like the image below?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(1)
例如,A 通配符查找/替换,在哪里:
您指定替换颜色。
For example, a wildcard Find/Replace, where:
and you specify the replacement colour.