InDesign GREP:替换定义列表中单词的最后一个字母

发布于 2025-01-14 12:18:35 字数 502 浏览 8 评论 0原文

我正在尝试为 InDesign 编写一个广泛的查找/更改命令,该命令从定义的列表(列表很长,大约 500 个单词)中查找单词,并用其他字符替换最后一个字符。

假设我想要一些以“-e”结尾的单词来代替“-i”结尾(因此“table”变成“tabli”)。

如果我希望在每个以 -e 结尾的单词上进行此更改,这很容易做到:

find: e\>

change: i

但如果我只想要这个怎么办更改发生在特定的单词列表上,例如仅名词?上面的方法将把:

I see a table

更改为:

I sei a tabli

而我们想要的是:

I see a tabli

Short of为每个单词编写 500 个不同的查找/更改表达式,有没有办法将其仅应用于预定义列表中的单词?

I'm trying to write a broad find/change command for InDesign which looks for words from a defined list (the list is long, around 500 words) and replaces the final character with something else.

Let's say I want words some words ending "-e" to instead end "-i" (so "table" becomes "tabli").

This would be easy to do if I wanted this change to happen on every word ending -e:

find: e\>

change: i

but what if I only want this change to happen on a particular list of words, like only nouns? The method above would change:

I see a table

to:

I sei a tabli

when what we want would be:

I see a tabli

Short of writing 500 different find/change expressions for each word, is there a way to apply this to only words from a pre-defined list?

如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。

扫码二维码加入Web技术交流群

发布评论

需要 登录 才能够评论, 你可以免费 注册 一个本站的账号。
列表为空,暂无数据
我们使用 Cookies 和其他技术来定制您的体验包括您的登录状态等。通过阅读我们的 隐私政策 了解更多相关信息。 单击 接受 或继续使用网站,即表示您同意使用 Cookies 和您的相关数据。
原文