Skip to main content

A markdown-like document editor for writing novels

Project description

novelWriter

Build Status codecov Documentation Status

novelWriter is a markdown-like text editor designed for writing novels and larger projects of many smaller plain text documents.

novelWriter uses its own flavour of markdown that supports a meta data syntax for comments, synopsis and cross-referencing between files.

novelWriter is licensed under GPLv3, see the GNU General Public License website for more details, or consult the LICENSE file. The bundled Typicon-based icon themes are licensed under CC BY-SA 4.0.

Below is a short overview of the features of novelWriter. The full documentation is available at novelwriter.readthedocs.io.

Note

The application is under initial development, and not all planned features are included. The core functionality is, however, in place and has been used for a while by the author and collaborators.

New features are being added regularly, until the core toolset is complete. When all planned initial features are in place, a release 1.0 will be made. Until then, novelWriter is in a pre-release alpha state, and should be considered experimental. If you do use it for real projects, please run backups frequently to avoid data losses. There is a built in backup feature that can pack the entire project into a zip file on close. Please check the documentation for further details.

Markdown Flavour

novelWriter is not a full-feature Markdown editor. It allows for a minimal set of formatting needed for writing text documents for novels. These are currently limited to:

  • Headings level 1 to 4 using the # syntax only.
  • Bold, italic and underline text.
  • Hard line breaks using two or more spaces at the end of a line.

That is it. Features not supported in the editor are also not exported when using the export tool.

In addition, novelWriter adds the following, which is otherwise not supported by Markdown:

  • A line starting with % is treated as a comment and not rendered on exports unless requested. Comments do not count towards the word count.
  • A set of meta data keyword/value sets starting with the character @. This is used for tagging and inter-linking documents.
  • Non-breaking spaces are supported as long as your system is using at least Qt 5.9. For earlier version, non-breaking spaces are converted to normal spaces when saving the document. This is done by the Qt library.
  • Tabs may be rendered, depending on export format.

The core export format that should render properly all supported features is the HTML export. This format also forms the basis of conversion to Office type document formats with Pandoc. Note that Pandoc itself strips some formatting from the document during conversion, so the final result may be different than expected.

Implementation

The application is written in Python3 using Qt5 via PyQt5. It is developed on Linux, but it should in principle work fine on other operating systems as well as long as dependencies are met.

The application can be started from the source folder with the command:

./novelWriter.py

It also takes a few parameters for debugging and such, which can be listed with the switch --help.

There are no launcher icons yet. Consult your operating system documentation for how to make those. These will be added at some point, and I would appreciate any assistance from people working on Windows and MacOS as I don't use either of those operating systems.

Package Dependencies

It is recommended that novelWriter runs with Qt 5.9 or later, and Python 3.6 or later. Running with Qt as low as 5.2.1 and Python 3.4.3 has been tested, and worked in the past, but there are no guarantees that this will keep working as these are not a part of the test builds.

For the apt package manager on Debian systems, the following Python3 packages are needed:

  • python3-pyqt5 for the GUI
  • python3-pyqt5.qtsvg may need to be installed separately
  • python3-lxml for writing project files

These are optional, but recommended:

  • python3-enchant for better spell checking

Alternatively, the packages can be installed with pip by running

python3 -m pip install -r requirements.txt

in the application folder.

You can also do them one at a time, skipping the ones you don't need:

python3 -m pip install pyqt5
python3 -m pip install lxml
python3 -m pip install pyenchant

If no external spell checking tool is installed, novelWriter will use a basic spell checker based on standard Python package difflib. Currently, only English dictionaries are available for this spell checker, but more can be added to the nw/assets/dict folder. See the nw/assets/dict/README.md file in that folder for how to generate more dictionaries. Note that the difflib-based option is both slow and limited.

Note: On Windows, make sure Python3 is in your PATH if you want to launch novelWriter from command line. You can also right click the novelWriter.py file, create a shortcut, then right click again, select "Properties" and change the target to your python executable and novelWriter.py.

It should look something like this:

C:\...\AppData\Local\Programs\Python\Python38\python.exe novelWriter.py

Key Features

The text documents of novelWriter use a format similar to markdown, but with a few extensions and a few omissions. Project meta data is stored as XML.

Colour Themes

The editor has syntax highlighting for the features it supports, and includes a set of different syntax highlighting themes. The GUI also has an optional dark theme in addition to the default system theme.

Note that the dark theme may not render all elements of the GUI as dark colours if you are running an early version of Qt5. This is not due to a bug in novelWriter, but due to the fact that the the styling options in the Qt API in some versions were incomplete.

New themes can easily be added to the nw/assets/themes folder. Have a look in the existing folders for examples of how to define the colours.

Auto-Saving and Document Stats

Open documents and the project file itself is saved regularly on a timer – if they have been altered. The status of this is indicated by two indicators on the right hand side of the status bar. Unsaved changes are in yellow, and saved is indicated by green in the default theme. Latest word count for the document and project is shown next to these indicators in the status bar. The counts are updated regularly, but not as-you-type.

Easy Organising of Project Files

The structure of the project is shown on the left hand side of the main GUI. Project files are organised into root folders, indicating what class of file they are. The most important root folder is the Novel folder, which contains all of the files that makes up the finished novel. Each root folder can have subfolders. Folders have no impact on the project structure, they are purely tools for organising the files in whatever way the user needs.

The editor supports four levels of headings, which determines what level the following text belongs to. Headings of level one signify a book or partition title. Headings of level two signify the start of a new chapter. Headings of level three signify the start of a new scene. Headings of level four can be used internally in each scene to separate sections.

Each novel file can be assigned a layout format, which shows up as a flag next to the item in the project tree. These are mostly to help the user see what they contain, but they also have some impact on the format of the exported document. See the documentation for further details.

Project Notes

Supporting note files can be added for the story plot, characters, locations, story timeline, etc. These have their separate root folders. These are optional files.

Visualisation of Story Elements

The different notes can be assigned tags, which the novel files can refer back to using special meta keywords. This information can be used to display an outline of the story, showing where each scene connects to the plot, and which characters, etc. occur in them. In addition, the tags themselves are clickable in the document view pane, and control-clickable in the editor. They make it possible to quickly navigate between the documents while editing.

Contribution

If you want to contribute to novelWriter, please follow the coding convention laid out in the Style Guide. They broadly follow Python PEP8, but there are a few modifications.

Screenshot

novelWriter with default system theme: Screenshot 1

novelWriter with dark theme: Screenshot 2

Project details


Release history Release notifications | RSS feed

This version

0.6

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

novelWriter-0.6.tar.gz (1.3 MB view details)

Uploaded Source

Built Distribution

novelWriter-0.6-py3-none-any.whl (1.4 MB view details)

Uploaded Python 3

File details

Details for the file novelWriter-0.6.tar.gz.

File metadata

  • Download URL: novelWriter-0.6.tar.gz
  • Upload date:
  • Size: 1.3 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.3

File hashes

Hashes for novelWriter-0.6.tar.gz
Algorithm Hash digest
SHA256 8f5ceea9cb5859234702b5b85f511710afabe516ccd2944df44cb51983530e66
MD5 99464bca5952093ada41d8dd07fea781
BLAKE2b-256 f8185d2b6584baecef73ac4fb0b87105c056443d8b81344e5b409aac5a79f782

See more details on using hashes here.

Provenance

File details

Details for the file novelWriter-0.6-py3-none-any.whl.

File metadata

  • Download URL: novelWriter-0.6-py3-none-any.whl
  • Upload date:
  • Size: 1.4 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/3.1.1 pkginfo/1.4.2 requests/2.23.0 setuptools/46.1.3 requests-toolbelt/0.8.0 tqdm/4.43.0 CPython/3.8.3

File hashes

Hashes for novelWriter-0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 ab51f946770163c1adccc5c6eccf7b29483035e30f4e8b5d746482ba5e42c96b
MD5 22ebaf33890111c1a0ee91fef87bf7df
BLAKE2b-256 9b92a5f7dd2498f6ccb4ddd38084a32c840023140d5d94ec8d93819fc2d7f979

See more details on using hashes here.

Provenance

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page