Adding multiple items to substitutions

I’m a potential new user and I’m wondering about the substitutions feature, something I use a lot in other word processors. I notice the interface only allows you to add one item at a time, in rather mouse oriented menus. Is there a way to import a list of substitution items from another programme (if it’s formatted in a specific way, e.g. comma or tab separated items or something like that)?
Or does Scrivener store all substitutions in a plain text file that could be edited with Notepad, so one could import them that way?
And if so, is there a maximum number of items the list could contain?

If not, I guess that would be my feature request if I were user – but since I’m not fully that yet, I’m not going to put it in there just yet.

Once you’ve entered them, it’s easy to select all (or just some) and just drag them over to another project (the lists are project-specific). The manual talks about this under “20.2.2 Custom Auto-completion”, page 514. (Mac version)

Yes, but…

I’ll preface it with DON’T DO IT. I’M NOT RESPONSIBLE IF YOU BREAK ANYTHING! That being said:

The list is stored in the ... .scrivx file, located inside each project’s package / folder. It’s basically XML. There’s a section

<AutoCompleteList>
        <Completion Scope="-1">Jane Doe</Completion>
        <Completion Scope="-1">John Doe</Completion>
        <Completion Scope="-1">Whatever</Completion>
</AutoCompleteList>

and the possible “scope” values are

-1 General Text
-2 All (Text & Scripts)
 0 Script (Scene Heading)
 1 Script (Scene Action)
 2 Script (Character & Dialogue)
 3 Script (Dialogue (Cont.))

So a very careful person could in theory, if this Scrivener project isn’t open, easily… you know. In and out. But that’s no official advice. Don’t do it. I’m just a fellow user.

2 Likes

Make a copy of your project. File > Save As and then experiment. If blows up no issue

1 Like

One more thing I forgot to mention. Filling this list in the XML file by hand would be nonsensical, so assuming you have a text file containing all of your words, one per line, e.g.:

item 1
item 2
item 3

Any decent text editor (I guess that excludes Notepad) should allow for RegEx search

^(.*)$

and replace

<Completion Scope="-1">$1</Completion>

and give you a nice list that you can sandwich between the <AutoCompleteList> </AutoCompleteList> tags mentioned above.

1 Like