Cotton code
168 lines · 6.2 KB · JSONRaw
{  "views": [    {      "id": "script",      "label": "Script",      "visibility": "owner",      "is_default": false,      "read": {        "table": "story_scene",        "empty": {          "line": "empty_views.story.script",          "table": true        }      },      "sort": {        "column": "position",        "descending": false      },      "face": "script",      "current": {        "column": "story",        "by": "chosen_at"      }    },    {      "id": "scenes",      "label": "Scenes",      "visibility": "owner",      "is_default": true,      "read": {        "table": "story_scene",        "empty": {          "line": "empty_views.story.scenes",          "table": true        }      },      "sort": {        "column": "position",        "descending": false      },      "face": "cards",      "current": {        "column": "story",        "by": "chosen_at"      }    },    {      "id": "characters",      "label": "Characters",      "visibility": "owner",      "is_default": false,      "read": {        "table": "story_character",        "empty": {          "line": "empty_views.story.characters",          "table": true        }      },      "sort": {        "column": "lines",        "descending": true,        "tie": "name",        "tie_descending": false      },      "face": "cards",      "current": {        "column": "story",        "by": "chosen_at"      }    },    {      "id": "places",      "label": "Places",      "visibility": "owner",      "is_default": false,      "read": {        "table": "story_place",        "empty": {          "line": "empty_views.story.places",          "table": true        }      },      "sort": {        "column": "scenes",        "descending": true,        "tie": "name",        "tie_descending": false      },      "face": "cards",      "current": {        "column": "story",        "by": "chosen_at"      }    },    {      "id": "notes",      "label": "Notes",      "visibility": "owner",      "is_default": false,      "read": {        "table": "story_note",        "empty": {          "line": "empty_views.story.notes",          "table": true        }      },      "sort": {        "column": "title",        "descending": false      },      "face": "cards",      "current": {        "column": "story",        "by": "chosen_at"      }    },    {      "id": "stories",      "label": "Stories",      "visibility": "owner",      "is_default": false,      "read": {        "table": "story_story",        "empty": {          "line": "empty_views.story.stories",          "table": true        }      },      "sort": {        "column": "chosen_at",        "descending": true,        "tie": "made_at",        "tie_descending": true      },      "face": "cards"    }  ],  "id": "story",  "name": "Story",  "purpose": "Write a screenplay on your phone: just type, and it is laid out as a real script.",  "picture": {    "photo": "photo:02c6b77e42501920f5fb92ff270d46cd1349f63152b738f858d1573a87a49685"  },  "tables": [    "story_story",    "story_scene",    "story_character",    "story_place",    "story_note",    "story_line",    "story_answer",    "story_sequence",    "story_picture",    "story_thing",    "story_costume",    "story_use",    "story_draft",    "story_draft_scene",    "vault_key"  ],  "instructions": "Story is the owner's screenplays. A story (story_story) holds its scenes (story_scene, in order by position), characters (story_character), places (story_place) and notes (story_note), each linked by its story column. Scenes, Characters, Places, Notes and Script show the current story only: the one most lately chosen (chosen_at); choosing a story in Stories makes it current. How a scene body is written: it is plain text in Fountain, the plain-text screenplay format, WITHOUT the scene heading (the heading lives in the scene's heading column, like INT. KITCHEN - NIGHT). A line of action is just a sentence of what we see. A character's name alone on a line starts their speech, and the lines right under it are what they say; in English write the name in capitals (MEERA); in other scripts write it as the story's character is named. A short aside in brackets on its own line under the name, like (quietly), says how a line is said. A line in capitals ending in TO:, like CUT TO:, is a transition. Leave a blank line between one element and the next, never inside a speech. Never type scene numbers, page breaks, MORE or CONT'D: the script is laid out by Story. Words, pages, minutes and who speaks are worked out from the body, never written; a name that speaks and has no character yet becomes one, and a heading's place becomes a place. Use story_scene_write to write or rewrite a body or heading, story_scene_move to reorder, story_copy to copy a story for translating (its scenes keep their order and shape, ready to be rewritten line by line in the new language), story_fountain_write to read a whole story as Fountain and story_fdx_write as a Final Draft file. Every line of a scene is a story_line row with its own id that survives any rewrite: change one line with story_line_write or story_line_remove, split or merge scenes with story_scene_split and story_scene_merge, rename or merge a character or a place everywhere with story_rename and story_merge. A scene's day is its story day (1, 2, 3). Pictures of a place, a person, a person on a story day, a costume, a thing or a scene are story_picture rows: add one with story_picture_add. Things (story_thing: props, vehicles), costumes (story_costume, worn by a character, on a story day) and where each is used (story_use: a scene and a thing or costume) are written with create_record. A draft is the script frozen under a name: story_draft_mark, story_draft_read, story_draft_changes (what changed since, by identity) and story_draft_restore (only when the owner asks). Story never suggests: write only what the owner asks for. Lists and plain reads of these tables work as for any table. Everything in Story is invented by the owner; never put a real person's private details into a story unless the owner writes them.",  "automations": [],  "author": {    "device": "cotton",    "name": "Cotton"  },  "signature": null}