Editorial Workflows

Fountain Characters

public workflow

Install Workflow...

This workflow contains at least one Python script. Only use it if you trust the person who shared this with you, and if you know exactly what it does.

I understand, install the workflow!

This is a workflow for Editorial, a Markdown and plain text editor for iOS. To download it, you need to view this page on a device that has the app installed.

Description: Displays a list of Fountain character names. Selecting from list inserts the character name.

Shared by: http://www.macdrifter.com/2013/09/fountain-characters-with-editorial-sprinkling-in-python.html

Comments: Comment Feed (RSS)

There are no comments yet.

+ Add Comment

Workflow Preview
Document Text ?
Folded Text
  • Include
  • Replace with:
Run Python Script ?
Source Code
#coding: utf-8
import workflow
import re


document_in = workflow.get_input()

charac_pattern = r'(?<=\n)([ \t]*[^<>a-z\s\/\n][^<>a-z:!\n]*[^<>a-z\(!\?:,\n\.][ \t]?)\n{1}(?!\n)'

reg_obj = re.compile(charac_pattern)
matches = re.findall(reg_obj, document_in)
match_string = '\n'.join(matches)


action_out = match_string

workflow.set_output(action_out)
Remove Duplicate Lines ?
Sort Lines ?
Sort Order
  • Ascending (A → Z)
  • Descending (Z → A)
Select from List ?
Title
List (Lines)
Input
Multiple Selection
OFF
Show in Popover
ON
Replace Selected Text ?
Replacement Text
Input