InDesign的自动化放置斜体文字在一个新的段落 [英] Automating InDesign to place italicized text in a new paragraph

查看:988
本文介绍了InDesign的自动化放置斜体文字在一个新的段落的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我做一本书的报价。得到了在几千条。
他们都apear是这样的:

I'm making a book about quotes. Got in the thousands of them. They all apear like this:

耐心是一棵树的根是苦的,但它的果实非常甜。
  的波斯谚语

Patience is a tree whose root is bitter, but its fruit very sweet. Persian proverb

和我想使它们看起来像这样

And I would like to make them appear like this

耐心是一棵树的根是苦的,但它的果实非常甜。
  结果的波斯谚语

Patience is a tree whose root is bitter, but its fruit very sweet.
Persian proverb

所以我基本上需要的程序要明白,当文本与常规结尾,则有一个空格,然后还有的斜体的空间需要转换成一段输入(^ P)。不知道确切的话吧......

So I basically need the program to understand that when the text ends with regular, then have a space and then there is italic the space needs to be converted into a paragraph enter (^p). Don't know the exact word for it...

在事情AppleScript的是AP preciated!

Something in Applescript would be appreciated!

BTW:我使用的是做出来的许多句子,以及报价。

BTW: I use quotes that are made out of many sentences as well.

推荐答案

从你所说的,这听起来像你可以用查找/更改做到这一点。没有AppleScript的需要。

From what you've said, it sounds like you can do this with Find/Change. No AppleScript needed.

这为我工作,在InDesign CS6。

This worked for me, in InDesign CS6.

做一个GREP比赛意味着查找内容是<一个href=\"http://help.adobe.com/en_US/indesign/cs/using/WSFB3603CC-8D84-48d8-9F77-F3E0644CB0B6a.html#WS1952D538-1335-4b1d-BA5E-FA5A176FDC9Fa\"相对=nofollow>常规EX pression 。我们使用 + $ 我们的前pression。让我们打破前pression下来:

Doing a GREP match means that "Find what" is a regular expression. We're using .+$ for our expression. Let's break that expression down:


  • + 将匹配一个或多个字符的序列

  • $ A段落的结尾相匹配。

  • 的查找格式将只匹配的文本是斜体。 (希望你使用的字符样式的归因;如果是这样,用自己的风格来代替)

  • 全部放在一起,我们发现这一切在段落的结尾是斜体。如果有在段落的末尾没有斜体,我们将不匹配任何东西。

  • .+ will match a sequence of one or more characters
  • $ matches the end of a paragraph.
  • The find format will only match text that's in italics. (Hopefully you used character styles for the attributions; if so, use your style instead.)
  • Putting it all together, we're finding everything that's in italics at the end of a paragraph. If there are no italics at the end of a paragraph, we won't match anything.

有关更改为你想 \\ R $ 1,0


  • \\ r 创建一个新段落

  • $ 1,0 是在匹配的文本查找内容。

  • 所以,你将与你相匹配的斜体文本之前一个新的段落结束。

  • \r creates a new paragraph
  • $0 is the text you matched in "Find what."
  • So you'll end up with a new paragraph before the italicized text you matched.

在你全部更改,您将有新的段落您的斜体文字。但是,一些这些段落可以用空格字符开始(如果空间是斜体,以及由previous匹配查找内容)。你可以清理一下另一个GREP比赛。

After you do "Change All" you'll have your italic text in new paragraphs. But some of those paragraphs may start with a space character (if the space was in italics, and matched by the previous "Find What"). You can clean that up with another GREP match.


  • 找到什么: ^ (尖,然后空间)。插入符的一个段落的开头匹配。所以,我们发现所有的空格在段落的开头。

  • 更改为:的。

  • 这将删除是在段落开头的所有空格。

  • Find What: ^ (caret, then space). The caret matches the start of a paragraph. So we're finding all spaces at the start of a paragraph.
  • Change to: empty.
  • This will remove all spaces that are at the start of a paragraph.

这篇关于InDesign的自动化放置斜体文字在一个新的段落的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆