Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Redesign file format #13

Open
spacekookie opened this issue Oct 22, 2018 · 0 comments
Open

Redesign file format #13

spacekookie opened this issue Oct 22, 2018 · 0 comments
Labels
help wanted Something that can easily be tackled by outside collaborators with mentorship I/O An issue related to the I/O backend improvement Improving on an existing feature tracking issue A collection of tasks, usually used for checlists

Comments

@spacekookie
Copy link
Contributor

This is a tracking issue about two aspects of the file format

  • Text encoding format (right now json, soon to be xml)
  • Folder structure for a novel and universe

Text encoding

  • Rust struct with simple serde Serialize/Deserialize attributes
  • Custom xml en-/decoder, working with some schema

Basic elements

  • <metadata> tags at the top of a document
    • Scene name
    • authors
    • creation/ modification date
    • <note> sections to display in info panel
  • <text> section contains the main body
    • <paragraph> sections around a paragraph.
    • Question: <sentence> sections around sentences?
    • <style foo> sections around style elements
      • bold
      • italics
      • underline
      • h1
      • h2
      • h3
    • <comment> sections around inline comments

File structure

The following outlines the way files could be arranged

my_novel/
├── meta
├── metadata.novel
├── script
│   ├── chapter_a
│   │   └── scene1.xml
│   ├── chapter_b
│   │   ├── scene1.xml
│   │   ├── scene2.xml
│   │   └── scene3.xml
│   ├── chapter_c
│   │   ├── scene1.xml
│   │   └── scene2.xml
│   └── chapter_d
│       ├── scene1.xml
│       ├── scene2.xml
│       └── scene3.xml
└── universe
    ├── characters
    │   ├── alice_bob.xml
    │   └── jane_smith.xml
    ├── metadata.universe
    ├── places
    │   ├── london_underground.xml
    │   └── paris_cafe.xml
    └── templates
        ├── character.xml
        ├── conversation.xml
        ├── family_tree.xml
        └── location.xml
@spacekookie spacekookie added improvement Improving on an existing feature help wanted Something that can easily be tackled by outside collaborators with mentorship tracking issue A collection of tasks, usually used for checlists I/O An issue related to the I/O backend labels Oct 22, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
help wanted Something that can easily be tackled by outside collaborators with mentorship I/O An issue related to the I/O backend improvement Improving on an existing feature tracking issue A collection of tasks, usually used for checlists
Projects
None yet
Development

No branches or pull requests

1 participant