Merge branch 'main' into multi_root

This commit is contained in:
Veronica Berglyd Olsen
2022-04-02 16:03:43 +02:00
47 changed files with 5994 additions and 2733 deletions
+4 -2
View File
@@ -4,9 +4,11 @@ on:
push:
branches:
- main
- patch
pull_request:
branches:
- main
- patch
jobs:
checkSyntax:
@@ -27,5 +29,5 @@ jobs:
flake8 tests --count --select=E9,F63,F7,F82 --show-source --statistics
- name: Coding Style Violations
run: |
flake8 novelwriter --count --max-line-length=99 --ignore E221,E226,E228,E241 --show-source --statistics
flake8 tests --count --max-line-length=99 --ignore E221,E226,E228,E241 --show-source --statistics
flake8 novelwriter --count --max-line-length=99 --ignore E133,E221,E226,E228,E241,W503 --show-source --statistics
flake8 tests --count --max-line-length=99 --ignore E133,E221,E226,E228,E241,W503 --show-source --statistics
+3 -1
View File
@@ -4,15 +4,17 @@ on:
push:
branches:
- main
- patch
pull_request:
branches:
- main
- patch
jobs:
testLinux:
strategy:
matrix:
python-version: ["3.6", "3.7", "3.8", "3.9", "3.10"]
python-version: ["3.7", "3.8", "3.9", "3.10"]
runs-on: ubuntu-latest
steps:
- name: Python Setup
+3 -1
View File
@@ -4,9 +4,11 @@ on:
push:
branches:
- main
- patch
pull_request:
branches:
- main
- patch
jobs:
testMac:
@@ -15,7 +17,7 @@ jobs:
- name: Python Setup
uses: actions/setup-python@v2
with:
python-version: 3.9
python-version: "3.10"
architecture: x64
- name: Install Packages
run: |
+3 -1
View File
@@ -4,9 +4,11 @@ on:
push:
branches:
- main
- patch
pull_request:
branches:
- main
- patch
jobs:
testWin:
@@ -15,7 +17,7 @@ jobs:
- name: Python Setup
uses: actions/setup-python@v2
with:
python-version: 3.9
python-version: "3.10"
architecture: x64
- name: Checkout Source
uses: actions/checkout@v2
+126 -1
View File
@@ -1,5 +1,130 @@
# novelWriter Changelog
## Version 1.6.2 [2022-03-20]
### Release Notes
This is a bugfix release that fixes a couple of minor issues. Projects containing one or more empty
documents would trigger a rebuild of the index each time the project was opened. This has now been
fixed. Another fix resolves an error message being written to the console logging output when a new
document was created. Both errors were harmless.
### Detailed Changelog
**Bugfixes**
* Fixed an issue where projects containing empty documents would trigger an index rebuild on open,
but the empty document would be skipped due to a check that skips empty documents. As a
consequence, the index would be rebuilt each time the project was opened. Empty documents are now
added to the index, resolving this issue. Issue #1020. PR #1022.
* Fixed an issue where the shasum calculation would be performed when a new document was created,
which would fail as the file did not yet exist. The error was handled, but an error message was
printed to the console log. The shasum is now no longer called if the file doesn't already exist.
Issue #1021. PR #1023.
----
## Version 1.6.1 [2022-03-16]
### Release Notes
This is a bugfix and patch release that fixes two recursion/loop issues. One would potentially
cause a crash if the window was resized rapidly, and one would cause a hang with certain search
parameters in the editor's search box. The Latin American Spanish translation has also been
updated.
### Detailed Changelog
**Installation**
* When using the new installer on Windows, the project file mime type icon path would not be
correctly configured in registry. The correct path is now used. PR #1006.
**Internationalisation**
* The Latin American Spanish translation has been updated with two missing translation strings.
PR #1017.
**Bugfixes**
* Fix a bug where rapidly resizing the main window could trigger the recursion detector in Python
if done on a slower system. The actual issue may be a race condition or similar, and the change
made at least makes it harder to trigger. PR #1007.
* With some document searches, it was possible to trigger an infinite loop in the function that
counts results. It seems to be caused by the QTextEdit widget's find function returning a
successful result status, but no actual result selection. The fix will now write a warning to the
log and exit in such cases. The number of results is also now capped at 1000. Issue #1015.
PR #1016.
----
## Version 1.6 [2022-02-20]
### Release Notes
This release does not introduce any major new features, but is instead a collection of minor
improvements and tweaks based on user requests. There are also a number of changes under the hood
to improve the structure and performance of novelWriter.
Some key improvements to the user interface are:
* The max text width setting in Preferences now also applies to the document viewer, and the
setting itself on the Preference dialog has been simplified a bit.
* When text is selected in the document editor, the number of words selected is displayed in the
editor's footer area.
* The search tool in the document editor now shows the number of results in the document.
* The Enter and Ctrl+O keyboard shortcuts should now work the same way in all tree views.
* It is now possible to set a blank section title format on the Build Novel Project tool and get
empty paragraphs in the output. Previously, a blank format would just remove the section break
entirely. This change allows the user to define hard and soft scene breaks using level three and
four headings. The scene and section titles can be hidden completely with two new switches added
to the user interface.
Other feature changes include:
* The project index is now automatically rebuilt in the event it is empty or incomplete when the
project is opened.
* The user can now add their own syntax and GUI theme files in the app folder in their user area on
the host operating system. Where the custom files must be added is described in the
documentation.
* A Windows installer is yet again provided for novelWriter. If you have novelWriter installed
using another method, make sure you uninstall it properly first as the two methods are not
compatible.
* Release versions for Ubuntu 21.04 have been dropped, and added for the upcoming Ubuntu 22.04.
* Most translations have been updated. A Dutch translation is in the works.
In addition to these changes, the documentation has been completely restructured and a new theme
added. The theme has a light and a dark mode.
_These Release Notes also include the changes from 1.6 Beta 1 and RC 1._
### Detailed Changelog
**User Interface**
* The default OS font is not always suitable for editing documents. The default editor font is now
Arial on Windows and Courier on macOS; if those fonts are available on the platform. Issue #988.
PR #990.
* Added some some random error messages from Discworld to the error dialog shown when novelWriter
crashes. They are visible on the dialog title bar if the title bar is visible on the platform.
This is just a fun addition made to note the #1000 addition to novelWriter. PR #1000.
**Installation**
* Dropped the Ubuntu 21.04 release as it is now deprecated, and added a release package for the
upcoming Ubuntu 22.04. PR #987.
**Internationalisation**
* The French, Norwegian and Portuguese (Brazil) translations have been updated. #992.
**Documentation**
* Some minor improvements have been made to the Introduction section of the documentations.
PR #991.
----
## Version 1.6 RC 1 [2022-02-06]
### Release Notes
@@ -97,7 +222,7 @@ final release.
* Custom GUI themes and syntax themes can now be loaded from the user's data path. The actual
storage path is determined by the OS. Part of Feature Request #892. PR #893.
* A number of text messages and labels on the GUI have been improved. Issue #923. PR #926.
* The switch in Preferences to disbale fixed width text in the editor has been removed. Instead,
* The switch in Preferences to disable fixed width text in the editor has been removed. Instead,
the user just sets the fixed with setting to 0 to disable it. The settings is now also applied to
the document viewer as well. Issue #924. PR #943.
* The Open Document export file produced from the build tool is now more LibreOffice and OpenOffice
+1
View File
@@ -16,6 +16,7 @@
* Portuguese: Bruno Meneguello (@bkmeneguello)
* Simplified Chinese: Qianzhi Long (@longqzh)
* Latin American Spanish: Tommy Marplatt (@tmarplatt)
* Dutch: Martijn van der Kleijn (@mvdkleijn)
## Libraries
+3 -3
View File
@@ -31,9 +31,9 @@ The full credits are listed in
## Implementation
The application is written in Python 3 (3.6+) using Qt5 and PyQt5 (5.3+). It is developed on Linux,
but should in principle work fine on other operating systems as well as long as dependencies are
met. It is regularly tested on Debian and Ubuntu Linux, Windows, and macOS.
The application is written with Python 3 (3.7+) using Qt5 and PyQt5 (5.3+). It is developed on
Linux, but should in principle work fine on other operating systems as well as long as dependencies
are met. It is regularly tested on Debian and Ubuntu Linux, Windows, and macOS.
## Installation
+1 -1
View File
@@ -55,7 +55,7 @@ html_theme_options = {
"light_logo": "novelwriter-light.png",
"dark_logo": "novelwriter-dark.png",
}
html_title = f"<div style='text-align: center'>Documentation<br>Version {release}</div>"
html_title = f"<div style='text-align: center'>Documentation Version {release}</div>"
# -- Options for HTMLHelp Output ---------------------------------------------
+1 -1
View File
@@ -115,7 +115,7 @@ Windows
-------
First, make sure you have Python installed on your system. If you don't, you can download it from
`python.org`_. Python 3.6 or higher is required, but it is recommended that you install the latest
`python.org`_. Python 3.7 or higher is required, but it is recommended that you install the latest
version.
Make sure you select the "Add Python to PATH" option during installation, otherwise the ``python``
+22 -3
View File
@@ -11,13 +11,32 @@ changes require minor actions from the user.
The key changes in the formats are listed below, as well as the user actions required where
applicable.
.. caution::
When you update a project from one format version to the next, the project can no longer be
opened by a version of novelWriter prior to the version where the new file format was
introduced. You will get a notification about any updates to your project file format and will
have the option to decline the upgrade.
.. _a_prjfmt_1_4:
Format 1.4 Changes
==================
This project format was introduced in novelWriter version 1.7.
This format changes the way project items (folders, documents and notes) are stored. It is a more
compact format that is simpler and faster to parse, and easier to extend. The conversion is done
automatically the first time a project is loaded. No user action is required.
.. _a_prjfmt_1_3:
Format 1.3 Changes
==================
This project format vas introduces in novelWriter version 1.5.
This project format was introduced in novelWriter version 1.5.
With this format, the number of document layouts was reduced from 8 to 2. The conversion of
document layouts is performed automatically when the project is opened.
@@ -55,7 +74,7 @@ should be used only a few places in any given project. These are as follows:
Format 1.2 Changes
==================
This project format was introduces in novelWriter version 0.10.
This project format was introduced in novelWriter version 0.10.
With this format, the way auto-replace entries were stored in the main project XML file changed.
Opening an old project automatically converts the storage format up to and including version 1.1.1.
@@ -69,7 +88,7 @@ auto-replace is not being used, can still be opened in novelWriter as of version
Format 1.1 Changes
==================
This project format was introduces in novelWriter version 0.7.
This project format was introduced in novelWriter version 0.7.
With this format, the ``content`` folder was introduced in the project storage. Previously, all
novelWriter documents were saved in a series of folders numbered from ``data_0`` to ``data_f``.
+531 -1212
View File
File diff suppressed because it is too large Load Diff
+4521
View File
File diff suppressed because it is too large Load Diff
+5 -5
View File
@@ -60,9 +60,9 @@ __license__ = "GPLv3"
__author__ = "Veronica Berglyd Olsen"
__maintainer__ = "Veronica Berglyd Olsen"
__email__ = "code@vkbo.net"
__version__ = "1.6-rc1"
__hexversion__ = "0x010600c1"
__date__ = "2022-02-06"
__version__ = "1.7-alpha0"
__hexversion__ = "0x010700a0"
__date__ = "2022-02-20"
__status__ = "Stable"
__domain__ = "novelwriter.io"
__url__ = "https://novelwriter.io"
@@ -209,9 +209,9 @@ def main(sysArgs=None):
# Check Packages and Versions
errorData = []
errorCode = 0
if sys.hexversion < 0x030600f0:
if sys.hexversion < 0x030700f0:
errorData.append(
"At least Python 3.6 is required, found %s" % CONFIG.verPyString
"At least Python 3.7 is required, found %s" % CONFIG.verPyString
)
errorCode |= 0x04
if CONFIG.verQtValue < 50300:
+47 -7
View File
@@ -2,16 +2,56 @@
<html>
<body>
<h2>Release Notes for 1.6 RC 1</h2>
<p><i>Released on 6 February 2022</i></p>
<h2>Release Notes for 1.6</h2>
<p><i>Released on 20 February 2022</i></p>
<p>This is a release candidate for the next release version, and is intended for testing purposes.
Please be careful when using this version on live writing projects, and make sure you take frequent
backups.</p>
<p>Please check the changelog for an overview of changes. The full release notes will be added to
the final release.</p>
<p>This release does not introduce any major new features, but is instead a collection of minor
improvements and tweaks based on user requests. There are also a number of changes under the hood
to improve the structure and performance of novelWriter.</p>
<p><u>Some key improvements to the user interface are:</u></p>
<p>&#10003; The max text width setting in Preferences now also applies to the document viewer, and
the setting itself on the Preference dialog has been simplified a bit.</p>
<p>&#10003; When text is selected in the document editor, the number of words selected is displayed
in the editor's footer area.</p>
<p>&#10003; The search tool in the document editor now shows the number of results in the
document.</p>
<p>&#10003; The Enter and Ctrl+O keyboard shortcuts should now work the same way in all tree
views.</p>
<p>&#10003; It is now possible to set a blank section title format on the Build Novel Project tool
and get empty paragraphs in the output. Previously, a blank format would just remove the section
break entirely. This change allows the user to define hard and soft scene breaks using level three
and four headings. The scene and section titles can be hidden completely with two new switches
added to the user interface.</p>
<p><u>Other feature changes include:</u></p>
<p>&#10003; The project index is now automatically rebuilt in the event it is empty or incomplete
when the project is opened.</p>
<p>&#10003; The user can now add their own syntax and GUI theme files in the app folder in their
user area on the host operating system. Where the custom files must be added is described in the
documentation.</p>
<p>&#10003; A Windows installer is yet again provided for novelWriter. If you have novelWriter
installed using another method, make sure you uninstall it properly first as the two methods are
not compatible.</p>
<p>&#10003; Release versions for Ubuntu 21.04 have been dropped, and added for the upcoming Ubuntu
22.04.</p>
<p>&#10003; Most translations have been updated. A Dutch translation is in the works.</p>
<p><i>See also the <a href="https://github.com/vkbo/novelWriter/releases">Releases</a> page.</i></p>
<h2>Patch Notes</h2>
<h3>Patch 1.6.1 &ndash; 16 March 2022</h3>
<p>This is a bugfix and patch release that fixes two recursion/loop issues. One would potentially
cause a crash if the window was resized rapidly, and one would cause a hang with certain search
parameters in the editor's search box. The Latin American Spanish translation has also been
updated.</p>
<h3>Patch 1.6.2 &ndash; 20 March 2022</h3>
<p>This is a bugfix release that fixes a couple of minor issues. Projects containing one or more
empty documents would trigger a rebuild of the index each time the project was opened. This has now
been fixed. Another fix resolves an error message being written to the console logging output when
a new document was created. Both errors were harmless.</p>
</body>
</html>
-13
View File
@@ -241,19 +241,6 @@ def formatTime(tS):
return "ERROR"
def parseTimeStamp(theStamp, default, allowNone=False):
"""Parses a text representation of a timestamp and converts it into
a float. Note that negative timestamps cause an OSError on Windows.
See https://bugs.python.org/issue29097
"""
if str(theStamp).lower() == "none" and allowNone:
return None
try:
return datetime.strptime(theStamp, nwConst.FMT_TSTAMP).timestamp()
except Exception:
return default
# =============================================================================================== #
# String Functions
# =============================================================================================== #
+2 -1
View File
@@ -89,9 +89,10 @@ class NWDoc():
theText = ""
self._docMeta = {}
self._prevHash = sha256sum(docPath)
self._prevHash = None
if os.path.isfile(docPath):
self._prevHash = sha256sum(docPath)
try:
with open(docPath, mode="r", encoding="utf-8") as inFile:
# Check the first <= 10 lines for metadata
+8 -8
View File
@@ -112,8 +112,7 @@ class NWIndex():
theDoc = NWDoc(self.theProject, tHandle)
theText = theDoc.readDocument()
if theText:
self.scanText(tHandle, theText)
self.scanText(tHandle, theText if theText is not None else "")
return True
@@ -217,18 +216,19 @@ class NWIndex():
if theItem.itemType != nwItemType.FILE:
logger.info("Not indexing non-file item '%s'", tHandle)
return False
# Run word counter for the whole text
cC, wC, pC = countWords(theText)
self._fileMeta[tHandle] = ["H0", cC, wC, pC]
# If the file's meta data is missing, or the file is out of the
# main project, we don't index the content
if theItem.itemLayout == nwItemLayout.NO_LAYOUT:
logger.info("Not indexing no-layout item '%s'", tHandle)
return False
if theItem.itemParent is None:
logger.info("Not indexing orphaned item '%s'", tHandle)
return False
# Run word counter for the whole text
cC, wC, pC = countWords(theText)
self._fileMeta[tHandle] = ["H0", cC, wC, pC]
# If the file is archived or in trash, we don't index the content
if self.theProject.projTree.isTrashRoot(theItem.itemParent):
logger.debug("Not indexing trash item '%s'", tHandle)
return False
+40 -23
View File
@@ -139,24 +139,32 @@ class NWItem():
def packXML(self, xParent):
"""Pack all the data in the class instance into an XML object.
"""
xPack = etree.SubElement(xParent, "item", attrib={
"handle": str(self._handle),
"order": str(self._order),
"parent": str(self._parent),
})
self._subPack(xPack, "name", text=str(self._name))
self._subPack(xPack, "type", text=str(self._type.name))
self._subPack(xPack, "class", text=str(self._class.name))
self._subPack(xPack, "status", text=str(self._status))
itemAttrib = {}
itemAttrib["handle"] = str(self._handle)
itemAttrib["parent"] = str(self._parent)
itemAttrib["order"] = str(self._order)
itemAttrib["type"] = str(self._type.name)
itemAttrib["class"] = str(self._class.name)
if self._type == nwItemType.FILE:
self._subPack(xPack, "exported", text=str(self._exported))
self._subPack(xPack, "layout", text=str(self._layout.name))
self._subPack(xPack, "charCount", text=str(self._charCount), none=False)
self._subPack(xPack, "wordCount", text=str(self._wordCount), none=False)
self._subPack(xPack, "paraCount", text=str(self._paraCount), none=False)
self._subPack(xPack, "cursorPos", text=str(self._cursorPos), none=False)
itemAttrib["layout"] = str(self._layout.name)
metaAttrib = {}
if self._type == nwItemType.FILE:
metaAttrib["charCount"] = str(self._charCount)
metaAttrib["wordCount"] = str(self._wordCount)
metaAttrib["paraCount"] = str(self._paraCount)
metaAttrib["cursorPos"] = str(self._cursorPos)
else:
self._subPack(xPack, "expanded", text=str(self._expanded))
metaAttrib["expanded"] = str(self._expanded)
nameAttrib = {}
nameAttrib["status"] = str(self._status)
if self._type == nwItemType.FILE:
nameAttrib["exported"] = str(self._exported)
xPack = etree.SubElement(xParent, "item", attrib=itemAttrib)
self._subPack(xPack, "meta", attrib=metaAttrib)
self._subPack(xPack, "name", text=str(self._name), attrib=nameAttrib)
return
@@ -175,19 +183,31 @@ class NWItem():
self.setParent(xItem.attrib.get("parent", None))
self.setOrder(xItem.attrib.get("order", 0))
self.setType(xItem.attrib.get("type", nwItemType.NO_TYPE))
self.setClass(xItem.attrib.get("class", nwItemClass.NO_CLASS))
self.setLayout(xItem.attrib.get("layout", nwItemLayout.NO_LAYOUT))
tmpStatus = ""
for xValue in xItem:
if xValue.tag == "name":
if xValue.tag == "meta":
self.setExpanded(xValue.attrib.get("expanded", False))
self.setCharCount(xValue.attrib.get("charCount", 0))
self.setWordCount(xValue.attrib.get("wordCount", 0))
self.setParaCount(xValue.attrib.get("paraCount", 0))
self.setCursorPos(xValue.attrib.get("cursorPos", 0))
elif xValue.tag == "name":
self.setName(xValue.text)
self.setStatus(xValue.attrib.get("status", None))
self.setExported(xValue.attrib.get("exported", True))
# Legacy Format (1.3 and earlier)
elif xValue.tag == "status":
self.setStatus(xValue.text)
elif xValue.tag == "type":
self.setType(xValue.text)
elif xValue.tag == "class":
self.setClass(xValue.text)
elif xValue.tag == "layout":
self.setLayout(xValue.text)
elif xValue.tag == "status":
tmpStatus = xValue.text
elif xValue.tag == "expanded":
self.setExpanded(xValue.text)
elif xValue.tag == "exported":
@@ -206,9 +226,6 @@ class NWItem():
# version of novelWriter that doesn't know the tag
logger.error("Unknown tag '%s'", xValue.tag)
# Guarantees that <status> is parsed after <class>
self.setStatus(tmpStatus)
return True
@staticmethod
+5 -2
View File
@@ -53,7 +53,7 @@ logger = logging.getLogger(__name__)
class NWProject():
FILE_VERSION = "1.3"
FILE_VERSION = "1.4"
def __init__(self, theParent):
@@ -474,8 +474,11 @@ class NWProject():
# 1.3 : Reduces the number of layouts to only two. One for novel
# documents and one for project notes. Introduced in
# version 1.5.
# 1.4 : Introduces a more compact format for storing items. All
# settings aside from name are now attributes. Introduced
# in version 1.7.
if fileVersion not in ("1.0", "1.1", "1.2", "1.3"):
if fileVersion not in ("1.0", "1.1", "1.2", "1.3", "1.4"):
self.theParent.makeAlert(self.tr(
"Unknown or unsupported novelWriter project file format. "
"The project cannot be opened by this version of novelWriter. "
+7 -2
View File
@@ -1,7 +1,7 @@
"""
novelWriter Text Tokenizer
============================
Splits a piece of novelWriter markdown text into its elements
Split novelWriter plain text into its elements
File History:
Created: 2019-05-05 [0.0.1]
@@ -27,6 +27,7 @@ import re
import logging
import novelwriter
from abc import ABC, abstractmethod
from operator import itemgetter
from functools import partial
@@ -40,7 +41,7 @@ from novelwriter.core.document import NWDoc
logger = logging.getLogger(__name__)
class Tokenizer():
class Tokenizer(ABC):
# In-Text Format
FMT_B_B = 1 # Begin bold
@@ -267,6 +268,10 @@ class Tokenizer():
# Class Methods
##
@abstractmethod
def doConvert(self):
raise NotImplementedError
def addRootHeading(self, theHandle):
"""Add a heading at the start of a new root folder.
"""
+1 -1
View File
@@ -330,7 +330,7 @@ class ToOdt(Tokenizer):
# Meta Data
xMeta = etree.SubElement(self._xMeta, _mkTag("meta", "creation-date"))
xMeta.text = datetime.now().strftime(r"%Y-%m-%dT%H:%M:%S")
xMeta.text = datetime.now().isoformat(sep="T", timespec="seconds")
xMeta = etree.SubElement(self._xMeta, _mkTag("meta", "generator"))
xMeta.text = f"novelWriter/{novelwriter.__version__}"
+1
View File
@@ -187,6 +187,7 @@ class GuiAbout(QDialog):
("Português", "Bruno Meneguello"),
("简体中文", "Qianzhi Long"),
("Español Latinoamericano", "Tommy Marplatt"),
("Nederlands", "Martijn van der Kleijn"),
])
)
+8
View File
@@ -24,6 +24,7 @@ along with this program. If not, see <https://www.gnu.org/licenses/>.
"""
import sys
import random
import logging
from PyQt5.QtCore import Qt
@@ -86,6 +87,13 @@ class NWErrorMessage(QDialog):
self.mainBox.addWidget(self.btnBox, 2, 0, 1, 2)
self.mainBox.setSpacing(16)
self.setWindowTitle([
"+++ Out of Cheese Error +++",
"+++ Divide by Cucumber Error +++",
"+++ Whoops! Here Comes The Cheese! +++",
"+++ Please Reinstall Universe and Reboot +++",
][random.randint(0, 3)])
self.setLayout(self.mainBox)
self.setMinimumWidth(500)
+11 -5
View File
@@ -1061,8 +1061,8 @@ class GuiDocEditor(QTextEdit):
"""If the text editor is resized, we must make sure the document
has its margins adjusted according to user preferences.
"""
QTextEdit.resizeEvent(self, theEvent)
self.updateDocMargins()
QTextEdit.resizeEvent(self, theEvent)
return
##
@@ -1436,10 +1436,16 @@ class GuiDocEditor(QTextEdit):
theCursor.setPosition(0)
self.setTextCursor(theCursor)
while self.find(searchFor, findOpt):
# Search up to a maximum of 1000, and make sure certain special
# searches like a regex search for .* turns into an infinite loop
while self.find(searchFor, findOpt) and len(resE) <= 1000:
theCursor = self.textCursor()
resS.append(theCursor.selectionStart())
resE.append(theCursor.selectionEnd())
if theCursor.hasSelection():
resS.append(theCursor.selectionStart())
resE.append(theCursor.selectionEnd())
else:
logger.warning("The search returned an empty result")
break
if hasSelection:
theCursor.setPosition(origA, QTextCursor.MoveAnchor)
@@ -2410,7 +2416,7 @@ class GuiDocEditSearch(QFrame):
"""Set the count values for the current search.
"""
currRes = "?" if currRes is None else currRes
resCount = "?" if resCount is None else resCount
resCount = "?" if resCount is None else "1000+" if resCount > 1000 else resCount
minWidth = self.theTheme.getTextWidth(f"{resCount}//{resCount}", self.boxFont)
self.resultLabel.setText(f"{currRes}/{resCount}")
self.resultLabel.setMinimumWidth(minWidth)
+3 -2
View File
@@ -471,10 +471,11 @@ class GuiDocViewer(QTextBrowser):
##
def resizeEvent(self, theEvent):
"""Make sure the document title is the same width as the window.
"""If the text editor is resized, we must make sure the document
has its margins adjusted according to user preferences.
"""
QTextBrowser.resizeEvent(self, theEvent)
self.updateDocMargins()
QTextBrowser.resizeEvent(self, theEvent)
return
def mouseReleaseEvent(self, theEvent):
+2 -6
View File
@@ -457,12 +457,8 @@ class GuiWritingStats(QDialog):
if len(inData) < 6:
continue
dStart = datetime.strptime(
"%s %s" % (inData[0], inData[1]), nwConst.FMT_TSTAMP
)
dEnd = datetime.strptime(
"%s %s" % (inData[2], inData[3]), nwConst.FMT_TSTAMP
)
dStart = datetime.fromisoformat(" ".join(inData[0:2]))
dEnd = datetime.fromisoformat(" ".join(inData[2:4]))
sIdle = 0
if len(inData) > 6:
+78 -238
View File
@@ -1,13 +1,13 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.6-rc1" hexVersion="0x010600c1" fileVersion="1.3" timeStamp="2022-02-06 23:05:58">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:55:50">
<project>
<name>Sample Project</name>
<title>Sample Project</title>
<author>Jane Smith</author>
<author>Jay Doh</author>
<saveCount>1297</saveCount>
<saveCount>1303</saveCount>
<autoCount>199</autoCount>
<editTime>64424</editTime>
<editTime>64457</editTime>
</project>
<settings>
<doBackup>False</doBackup>
@@ -49,265 +49,105 @@
</importance>
</settings>
<content count="25">
<item handle="7031beac91f75" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>Started</status>
<expanded>True</expanded>
<item handle="7031beac91f75" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="True"/>
<name status="Started">Novel</name>
</item>
<item handle="53b69b83cdafc" order="0" parent="7031beac91f75">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Started</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>93</charCount>
<wordCount>19</wordCount>
<paraCount>2</paraCount>
<cursorPos>2</cursorPos>
<item handle="53b69b83cdafc" parent="7031beac91f75" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="93" wordCount="19" paraCount="2" cursorPos="2"/>
<name status="Started" exported="True">Title Page</name>
</item>
<item handle="974e400180a99" order="1" parent="7031beac91f75">
<name>Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>186</charCount>
<wordCount>39</wordCount>
<paraCount>2</paraCount>
<cursorPos>212</cursorPos>
<item handle="974e400180a99" parent="7031beac91f75" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="186" wordCount="39" paraCount="2" cursorPos="212"/>
<name status="New" exported="True">Page</name>
</item>
<item handle="edca4be2fcaf8" order="2" parent="7031beac91f75">
<name>Part One</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>26</charCount>
<wordCount>6</wordCount>
<paraCount>1</paraCount>
<cursorPos>33</cursorPos>
<item handle="edca4be2fcaf8" parent="7031beac91f75" order="2" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="26" wordCount="6" paraCount="1" cursorPos="33"/>
<name status="New" exported="True">Part One</name>
</item>
<item handle="e7ded148d6e4a" order="3" parent="7031beac91f75">
<name>A Folder</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>1st Draft</status>
<expanded>True</expanded>
<item handle="e7ded148d6e4a" parent="7031beac91f75" order="3" type="FOLDER" class="NOVEL">
<meta expanded="True"/>
<name status="1st Draft">A Folder</name>
</item>
<item handle="6a2d6d5f4f401" order="0" parent="e7ded148d6e4a">
<name>Chapter One</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Notes</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>75</charCount>
<wordCount>14</wordCount>
<paraCount>1</paraCount>
<cursorPos>279</cursorPos>
<item handle="6a2d6d5f4f401" parent="e7ded148d6e4a" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="75" wordCount="14" paraCount="1" cursorPos="279"/>
<name status="Notes" exported="True">Chapter One</name>
</item>
<item handle="636b6aa9b697b" order="1" parent="e7ded148d6e4a">
<name>Making a Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>1st Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>2429</charCount>
<wordCount>432</wordCount>
<paraCount>14</paraCount>
<cursorPos>219</cursorPos>
<item handle="636b6aa9b697b" parent="e7ded148d6e4a" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="2429" wordCount="432" paraCount="14" cursorPos="219"/>
<name status="1st Draft" exported="True">Making a Scene</name>
</item>
<item handle="bc0cbd2a407f3" order="2" parent="e7ded148d6e4a">
<name>Another Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>1st Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>476</charCount>
<wordCount>93</wordCount>
<paraCount>3</paraCount>
<cursorPos>577</cursorPos>
<item handle="bc0cbd2a407f3" parent="e7ded148d6e4a" order="2" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="476" wordCount="93" paraCount="3" cursorPos="577"/>
<name status="1st Draft" exported="True">Another Scene</name>
</item>
<item handle="ba8a28a246524" order="3" parent="e7ded148d6e4a">
<name>Interlude</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>617</charCount>
<wordCount>101</wordCount>
<paraCount>3</paraCount>
<cursorPos>4</cursorPos>
<item handle="ba8a28a246524" parent="e7ded148d6e4a" order="3" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="617" wordCount="101" paraCount="3" cursorPos="4"/>
<name status="New" exported="True">Interlude</name>
</item>
<item handle="96b68994dfa3d" order="4" parent="e7ded148d6e4a">
<name>A Note on Structure</name>
<type>FILE</type>
<class>NOVEL</class>
<status>2nd Draft</status>
<exported>False</exported>
<layout>NOTE</layout>
<charCount>1692</charCount>
<wordCount>313</wordCount>
<paraCount>6</paraCount>
<cursorPos>1110</cursorPos>
<item handle="96b68994dfa3d" parent="e7ded148d6e4a" order="4" type="FILE" class="NOVEL" layout="NOTE">
<meta charCount="1692" wordCount="313" paraCount="6" cursorPos="1110"/>
<name status="2nd Draft" exported="False">A Note on Structure</name>
</item>
<item handle="88706ddc78b1b" order="5" parent="e7ded148d6e4a">
<name>Chapter Two</name>
<type>FILE</type>
<class>NOVEL</class>
<status>1st Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>139</charCount>
<wordCount>28</wordCount>
<paraCount>1</paraCount>
<cursorPos>343</cursorPos>
<item handle="88706ddc78b1b" parent="e7ded148d6e4a" order="5" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="139" wordCount="28" paraCount="1" cursorPos="343"/>
<name status="1st Draft" exported="True">Chapter Two</name>
</item>
<item handle="ae7339df26ded" order="6" parent="e7ded148d6e4a">
<name>We Found John!</name>
<type>FILE</type>
<class>NOVEL</class>
<status>1st Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>189</charCount>
<wordCount>37</wordCount>
<paraCount>1</paraCount>
<cursorPos>224</cursorPos>
<item handle="ae7339df26ded" parent="e7ded148d6e4a" order="6" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="189" wordCount="37" paraCount="1" cursorPos="224"/>
<name status="1st Draft" exported="True">We Found John!</name>
</item>
<item handle="f6622b4617424" order="1" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>None</status>
<expanded>True</expanded>
<item handle="f6622b4617424" parent="None" order="1" type="ROOT" class="CHARACTER">
<meta expanded="True"/>
<name status="None">Characters</name>
</item>
<item handle="f7e2d9f330615" order="0" parent="f6622b4617424">
<name>Main Characters</name>
<type>FOLDER</type>
<class>CHARACTER</class>
<status>None</status>
<expanded>True</expanded>
<item handle="f7e2d9f330615" parent="f6622b4617424" order="0" type="FOLDER" class="CHARACTER">
<meta expanded="True"/>
<name status="None">Main Characters</name>
</item>
<item handle="14298de4d9524" order="0" parent="f7e2d9f330615">
<name>John Smith</name>
<type>FILE</type>
<class>CHARACTER</class>
<status>Minor</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>49</charCount>
<wordCount>9</wordCount>
<paraCount>1</paraCount>
<cursorPos>24</cursorPos>
<item handle="14298de4d9524" parent="f7e2d9f330615" order="0" type="FILE" class="CHARACTER" layout="NOTE">
<meta charCount="49" wordCount="9" paraCount="1" cursorPos="24"/>
<name status="Minor" exported="True">John Smith</name>
</item>
<item handle="bb2c23b3c42cc" order="1" parent="f7e2d9f330615">
<name>Jane Smith</name>
<type>FILE</type>
<class>CHARACTER</class>
<status>Major</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>55</charCount>
<wordCount>9</wordCount>
<paraCount>1</paraCount>
<cursorPos>25</cursorPos>
<item handle="bb2c23b3c42cc" parent="f7e2d9f330615" order="1" type="FILE" class="CHARACTER" layout="NOTE">
<meta charCount="55" wordCount="9" paraCount="1" cursorPos="25"/>
<name status="Major" exported="True">Jane Smith</name>
</item>
<item handle="15c4492bd5107" order="2" parent="None">
<name>Locations</name>
<type>ROOT</type>
<class>WORLD</class>
<status>None</status>
<expanded>True</expanded>
<item handle="15c4492bd5107" parent="None" order="2" type="ROOT" class="WORLD">
<meta expanded="True"/>
<name status="None">Locations</name>
</item>
<item handle="b3e74dbc1f584" order="0" parent="15c4492bd5107">
<name>Earth</name>
<type>FILE</type>
<class>WORLD</class>
<status>Main</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>76</charCount>
<wordCount>15</wordCount>
<paraCount>1</paraCount>
<cursorPos>20</cursorPos>
<item handle="b3e74dbc1f584" parent="15c4492bd5107" order="0" type="FILE" class="WORLD" layout="NOTE">
<meta charCount="76" wordCount="15" paraCount="1" cursorPos="20"/>
<name status="Main" exported="True">Earth</name>
</item>
<item handle="f1471bef9f2ae" order="1" parent="15c4492bd5107">
<name>Space</name>
<type>FILE</type>
<class>WORLD</class>
<status>Minor</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>115</charCount>
<wordCount>24</wordCount>
<paraCount>1</paraCount>
<cursorPos>133</cursorPos>
<item handle="f1471bef9f2ae" parent="15c4492bd5107" order="1" type="FILE" class="WORLD" layout="NOTE">
<meta charCount="115" wordCount="24" paraCount="1" cursorPos="133"/>
<name status="Minor" exported="True">Space</name>
</item>
<item handle="5eaea4e8cdee8" order="2" parent="15c4492bd5107">
<name>Mars</name>
<type>FILE</type>
<class>WORLD</class>
<status>Major</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>28</charCount>
<wordCount>6</wordCount>
<paraCount>1</paraCount>
<cursorPos>45</cursorPos>
<item handle="5eaea4e8cdee8" parent="15c4492bd5107" order="2" type="FILE" class="WORLD" layout="NOTE">
<meta charCount="28" wordCount="6" paraCount="1" cursorPos="45"/>
<name status="Major" exported="True">Mars</name>
</item>
<item handle="6827118336ac1" order="3" parent="None">
<name>Archive</name>
<type>ROOT</type>
<class>ARCHIVE</class>
<status>New</status>
<expanded>True</expanded>
<item handle="6827118336ac1" parent="None" order="3" type="ROOT" class="ARCHIVE">
<meta expanded="True"/>
<name status="New">Archive</name>
</item>
<item handle="ae9bf3c3ea159" order="0" parent="6827118336ac1">
<name>Scenes</name>
<type>FOLDER</type>
<class>ARCHIVE</class>
<status>New</status>
<expanded>True</expanded>
<item handle="ae9bf3c3ea159" parent="6827118336ac1" order="0" type="FOLDER" class="ARCHIVE">
<meta expanded="True"/>
<name status="New">Scenes</name>
</item>
<item handle="8a5deb88c0e97" order="0" parent="ae9bf3c3ea159">
<name>Old File</name>
<type>FILE</type>
<class>NOVEL</class>
<status>1st Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>315</charCount>
<wordCount>55</wordCount>
<paraCount>1</paraCount>
<cursorPos>322</cursorPos>
<item handle="8a5deb88c0e97" parent="ae9bf3c3ea159" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="315" wordCount="55" paraCount="1" cursorPos="322"/>
<name status="1st Draft" exported="True">Old File</name>
</item>
<item handle="98acd8c76c93a" order="4" parent="None">
<name>Trash</name>
<type>TRASH</type>
<class>TRASH</class>
<status>None</status>
<expanded>True</expanded>
<item handle="98acd8c76c93a" parent="None" order="4" type="TRASH" class="TRASH">
<meta expanded="True"/>
<name status="None">Trash</name>
</item>
<item handle="b8136a5a774a0" order="0" parent="98acd8c76c93a">
<name>Delete Me!</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>30</charCount>
<wordCount>6</wordCount>
<paraCount>1</paraCount>
<cursorPos>36</cursorPos>
<item handle="b8136a5a774a0" parent="98acd8c76c93a" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="30" wordCount="6" paraCount="1" cursorPos="36"/>
<name status="New" exported="True">Delete Me!</name>
</item>
</content>
</novelWriterXML>
+2 -3
View File
@@ -11,7 +11,6 @@ license_file = LICENSE.md
license = GNU General Public License v3
classifiers =
Programming Language :: Python :: 3 :: Only
Programming Language :: Python :: 3.6
Programming Language :: Python :: 3.7
Programming Language :: Python :: 3.8
Programming Language :: Python :: 3.9
@@ -29,7 +28,7 @@ project_urls =
Source Code = https://github.com/vkbo/novelWriter
[options]
python_requires = >=3.6
python_requires = >=3.7
include_package_data = True
packages = find:
install_requires =
@@ -50,6 +49,6 @@ gui_scripts =
universal = 0
[flake8]
ignore = E221,E226,E228,E241
ignore = E133,E221,E226,E228,E241,W503
max-line-length = 99
exclude = docs/*
-1
View File
@@ -786,7 +786,6 @@ def makeForLaunchpad(doSign=False, isFirst=False, isSnapshot=False):
bldNum = "0"
distLoop = [
("18.04", "bionic"),
("20.04", "focal"),
("21.10", "impish"),
("22.04", "jammy"),
+3 -3
View File
@@ -2,14 +2,14 @@ Source: novelwriter
Maintainer: Veronica Berglyd Olsen <code@vkbo.net>
Section: text
Priority: optional
Build-Depends: dh-python, python3-setuptools, python3-all, debhelper (>= 9), python3 (>=3.6), python3-pyqt5 (>= 5.3), python3-lxml (>= 4.0), python3-enchant (>= 2.0)
Build-Depends: dh-python, python3-setuptools, python3-all, debhelper (>= 9), python3 (>=3.7), python3-pyqt5 (>= 5.3), python3-lxml (>= 4.0), python3-enchant (>= 2.0)
Standards-Version: 4.5.1
Homepage: https://novelwriter.io
X-Python3-Version: >= 3.6
X-Python3-Version: >= 3.7
Package: novelwriter
Architecture: all
Depends: ${misc:Depends}, ${python3:Depends}, python3 (>=3.6), python3-pyqt5 (>= 5.3), python3-lxml (>= 4.0), python3-enchant (>= 2.0)
Depends: ${misc:Depends}, ${python3:Depends}, python3 (>=3.7), python3-pyqt5 (>= 5.3), python3-lxml (>= 4.0), python3-enchant (>= 2.0)
Description: A markdown-like text editor for planning and writing novels
novelWriter is a plain text editor designed for writing novels assembled from
many smaller text documents. It uses a minimal formatting syntax inspired by
+3 -3
View File
@@ -10,9 +10,9 @@ synchronisation tools. All text is saved as plain text files with a meta data he
project structure is stored in a single project XML file, and other meta data is primarily saved as
JSON files.
The application is written in Python 3 (3.6+) using Qt5 and PyQt5 (5.3+). It is developed on Linux,
but should in principle work fine on other operating systems as well as long as dependencies are
met. It is regularly tested on Debian and Ubuntu Linux, Windows, and macOS.
The application is written with Python 3 (3.7+) using Qt5 and PyQt5 (5.3+). It is developed on
Linux, but should in principle work fine on other operating systems as well as long as dependencies
are met. It is regularly tested on Debian and Ubuntu Linux, Windows, and macOS.
novelWriter is developed and maintained by [Veronica Berglyd Olsen](https://github.com/vkbo).
+1 -1
View File
@@ -51,6 +51,6 @@ Filename: "{app}\pythonw.exe"; Parameters: "{#nwAppExeName}"; Description: "{cm
[Registry]
Root: HKA; Subkey: "Software\Classes\.nwx\OpenWithProgids"; ValueType: string; ValueName: "novelWriterProject.nwx"; ValueData: ""; Flags: uninsdeletevalue
Root: HKA; Subkey: "Software\Classes\novelWriterProject.nwx"; ValueType: string; ValueName: ""; ValueData: "novelWriter Project File"; Flags: uninsdeletekey
Root: HKA; Subkey: "Software\Classes\novelWriterProject.nwx\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\assets\icons\x-novelwriter-project.ico"
Root: HKA; Subkey: "Software\Classes\novelWriterProject.nwx\DefaultIcon"; ValueType: string; ValueName: ""; ValueData: "{app}\novelwriter\assets\icons\x-novelwriter-project.ico"
Root: HKA; Subkey: "Software\Classes\novelWriterProject.nwx\shell\open\command"; ValueType: string; ValueName: ""; ValueData: """{app}\pythonw.exe"" ""{app}\{#nwAppExeName}"" ""%1"""
Root: HKA; Subkey: "Software\Classes\Applications\{#nwAppExeName}\SupportedTypes"; ValueType: string; ValueName: ".nwx"; ValueData: ""; Flags: uninsdeletekey
+66 -204
View File
@@ -1,12 +1,12 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.3" timeStamp="2021-08-02 17:47:39">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 22:04:38">
<project>
<name>Lorem Ipsum</name>
<title>Lorem Ipsum</title>
<author>lipsum.com</author>
<saveCount>17</saveCount>
<saveCount>21</saveCount>
<autoCount>24</autoCount>
<editTime>1777</editTime>
<editTime>1847</editTime>
</project>
<settings>
<doBackup>False</doBackup>
@@ -44,227 +44,89 @@
</importance>
</settings>
<content count="21">
<item handle="b3643d0f92e32" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>True</expanded>
<item handle="b3643d0f92e32" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="True"/>
<name status="New">Novel</name>
</item>
<item handle="7a992350f3eb6" order="0" parent="b3643d0f92e32">
<name>Lorem Ipsum</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Finished</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>230</charCount>
<wordCount>40</wordCount>
<paraCount>3</paraCount>
<cursorPos>148</cursorPos>
<item handle="7a992350f3eb6" parent="b3643d0f92e32" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="230" wordCount="40" paraCount="3" cursorPos="148"/>
<name status="Finished" exported="True">Lorem Ipsum</name>
</item>
<item handle="8c58a65414c23" order="1" parent="b3643d0f92e32">
<name>Front Matter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Finished</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>1058</charCount>
<wordCount>176</wordCount>
<paraCount>2</paraCount>
<cursorPos>43</cursorPos>
<item handle="8c58a65414c23" parent="b3643d0f92e32" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="1058" wordCount="176" paraCount="2" cursorPos="43"/>
<name status="Finished" exported="True">Front Matter</name>
</item>
<item handle="88d59a277361b" order="2" parent="b3643d0f92e32">
<name>Prologue</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>584</charCount>
<wordCount>92</wordCount>
<paraCount>1</paraCount>
<cursorPos>4</cursorPos>
<item handle="88d59a277361b" parent="b3643d0f92e32" order="2" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="584" wordCount="92" paraCount="1" cursorPos="4"/>
<name status="Draft" exported="True">Prologue</name>
</item>
<item handle="db7e733775d4d" order="3" parent="b3643d0f92e32">
<name>Act One</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>35</charCount>
<wordCount>6</wordCount>
<paraCount>1</paraCount>
<cursorPos>42</cursorPos>
<item handle="db7e733775d4d" parent="b3643d0f92e32" order="3" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="35" wordCount="6" paraCount="1" cursorPos="42"/>
<name status="New" exported="True">Act One</name>
</item>
<item handle="45e6b01ca35c1" order="4" parent="b3643d0f92e32">
<name>Chapter One</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>Draft</status>
<expanded>True</expanded>
<item handle="45e6b01ca35c1" parent="b3643d0f92e32" order="4" type="FOLDER" class="NOVEL">
<meta expanded="True"/>
<name status="Draft">Chapter One</name>
</item>
<item handle="fb609cd8319dc" order="0" parent="45e6b01ca35c1">
<name>Chapter One</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>419</charCount>
<wordCount>67</wordCount>
<paraCount>1</paraCount>
<cursorPos>56</cursorPos>
<item handle="fb609cd8319dc" parent="45e6b01ca35c1" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="419" wordCount="67" paraCount="1" cursorPos="56"/>
<name status="Draft" exported="True">Chapter One</name>
</item>
<item handle="88243afbe5ed8" order="1" parent="45e6b01ca35c1">
<name>Scene One</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Finished</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>2758</charCount>
<wordCount>404</wordCount>
<paraCount>4</paraCount>
<cursorPos>1528</cursorPos>
<item handle="88243afbe5ed8" parent="45e6b01ca35c1" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="2758" wordCount="404" paraCount="4" cursorPos="1528"/>
<name status="Finished" exported="True">Scene One</name>
</item>
<item handle="f96ec11c6a3da" order="2" parent="45e6b01ca35c1">
<name>Scene Two</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Finished</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>4043</charCount>
<wordCount>600</wordCount>
<paraCount>6</paraCount>
<cursorPos>2335</cursorPos>
<item handle="f96ec11c6a3da" parent="45e6b01ca35c1" order="2" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="4043" wordCount="600" paraCount="6" cursorPos="2335"/>
<name status="Finished" exported="True">Scene Two</name>
</item>
<item handle="846352075de7d" order="5" parent="b3643d0f92e32">
<name>Interlude</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>False</exported>
<layout>DOCUMENT</layout>
<charCount>631</charCount>
<wordCount>109</wordCount>
<paraCount>3</paraCount>
<cursorPos>376</cursorPos>
<item handle="846352075de7d" parent="b3643d0f92e32" order="5" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="631" wordCount="109" paraCount="3" cursorPos="376"/>
<name status="New" exported="False">Interlude</name>
</item>
<item handle="6bd935d2490cd" order="6" parent="b3643d0f92e32">
<name>Chapter Two</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>Draft</status>
<expanded>True</expanded>
<item handle="6bd935d2490cd" parent="b3643d0f92e32" order="6" type="FOLDER" class="NOVEL">
<meta expanded="True"/>
<name status="Draft">Chapter Two</name>
</item>
<item handle="441420a886d82" order="0" parent="6bd935d2490cd">
<name>Chapter Two</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Draft</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>477</charCount>
<wordCount>70</wordCount>
<paraCount>1</paraCount>
<cursorPos>56</cursorPos>
<item handle="441420a886d82" parent="6bd935d2490cd" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="477" wordCount="70" paraCount="1" cursorPos="56"/>
<name status="Draft" exported="True">Chapter Two</name>
</item>
<item handle="eb103bc70c90c" order="1" parent="6bd935d2490cd">
<name>Scene Three</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Finished</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>3006</charCount>
<wordCount>439</wordCount>
<paraCount>4</paraCount>
<cursorPos>57</cursorPos>
<item handle="eb103bc70c90c" parent="6bd935d2490cd" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="3006" wordCount="439" paraCount="4" cursorPos="57"/>
<name status="Finished" exported="True">Scene Three</name>
</item>
<item handle="f8c0562e50f1b" order="2" parent="6bd935d2490cd">
<name>Scene Four</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Finished</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>3839</charCount>
<wordCount>563</wordCount>
<paraCount>6</paraCount>
<cursorPos>56</cursorPos>
<item handle="f8c0562e50f1b" parent="6bd935d2490cd" order="2" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="3839" wordCount="563" paraCount="6" cursorPos="56"/>
<name status="Finished" exported="True">Scene Four</name>
</item>
<item handle="47666c91c7ccf" order="3" parent="6bd935d2490cd">
<name>Scene Five</name>
<type>FILE</type>
<class>NOVEL</class>
<status>Finished</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>3644</charCount>
<wordCount>543</wordCount>
<paraCount>5</paraCount>
<cursorPos>351</cursorPos>
<item handle="47666c91c7ccf" parent="6bd935d2490cd" order="3" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="3644" wordCount="543" paraCount="5" cursorPos="351"/>
<name status="Finished" exported="True">Scene Five</name>
</item>
<item handle="67a8707f2f249" order="1" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>True</expanded>
<item handle="67a8707f2f249" parent="None" order="1" type="ROOT" class="CHARACTER">
<meta expanded="True"/>
<name status="New">Characters</name>
</item>
<item handle="4c4f28287af27" order="0" parent="67a8707f2f249">
<name>Mr. Nobody</name>
<type>FILE</type>
<class>CHARACTER</class>
<status>Major</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>1864</charCount>
<wordCount>284</wordCount>
<paraCount>3</paraCount>
<cursorPos>1883</cursorPos>
<item handle="4c4f28287af27" parent="67a8707f2f249" order="0" type="FILE" class="CHARACTER" layout="NOTE">
<meta charCount="1864" wordCount="284" paraCount="3" cursorPos="1883"/>
<name status="Major" exported="True">Mr. Nobody</name>
</item>
<item handle="6c6afb1247750" order="2" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>True</expanded>
<item handle="6c6afb1247750" parent="None" order="2" type="ROOT" class="PLOT">
<meta expanded="True"/>
<name status="New">Plot</name>
</item>
<item handle="2426c6f0ca922" order="0" parent="6c6afb1247750">
<name>Main</name>
<type>FILE</type>
<class>PLOT</class>
<status>Main</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>1369</charCount>
<wordCount>195</wordCount>
<paraCount>2</paraCount>
<cursorPos>1387</cursorPos>
<item handle="2426c6f0ca922" parent="6c6afb1247750" order="0" type="FILE" class="PLOT" layout="NOTE">
<meta charCount="1369" wordCount="195" paraCount="2" cursorPos="1387"/>
<name status="Main" exported="True">Main</name>
</item>
<item handle="60bdf227455cc" order="3" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>True</expanded>
<item handle="60bdf227455cc" parent="None" order="3" type="ROOT" class="WORLD">
<meta expanded="True"/>
<name status="New">World</name>
</item>
<item handle="04468803b92e1" order="0" parent="60bdf227455cc">
<name>Ancient Europe</name>
<type>FILE</type>
<class>WORLD</class>
<status>Minor</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>1770</charCount>
<wordCount>259</wordCount>
<paraCount>3</paraCount>
<cursorPos>1792</cursorPos>
<item handle="04468803b92e1" parent="60bdf227455cc" order="0" type="FILE" class="WORLD" layout="NOTE">
<meta charCount="1770" wordCount="259" paraCount="3" cursorPos="1792"/>
<name status="Minor" exported="True">Ancient Europe</name>
</item>
</content>
</novelWriterXML>
+27 -66
View File
@@ -1,13 +1,13 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.3" timeStamp="2021-08-02 17:47:26">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:21">
<project>
<name>Test Minimal</name>
<title>Minimal</title>
<author>Jane Doe</author>
<author>John Doh</author>
<saveCount>9</saveCount>
<saveCount>12</saveCount>
<autoCount>2</autoCount>
<editTime>113</editTime>
<editTime>129</editTime>
</project>
<settings>
<doBackup>True</doBackup>
@@ -42,76 +42,37 @@
</importance>
</settings>
<content count="8">
<item handle="a508bb932959c" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>True</expanded>
<item handle="a508bb932959c" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="True"/>
<name status="New">Novel</name>
</item>
<item handle="a35baf2e93843" order="0" parent="a508bb932959c">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>28</charCount>
<wordCount>6</wordCount>
<paraCount>1</paraCount>
<cursorPos>33</cursorPos>
<item handle="a35baf2e93843" parent="a508bb932959c" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="28" wordCount="6" paraCount="1" cursorPos="33"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="a6d311a93600a" order="1" parent="a508bb932959c">
<name>New Chapter</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>True</expanded>
<item handle="a6d311a93600a" parent="a508bb932959c" order="1" type="FOLDER" class="NOVEL">
<meta expanded="True"/>
<name status="New">New Chapter</name>
</item>
<item handle="f5ab3e30151e1" order="0" parent="a6d311a93600a">
<name>New Chapter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>11</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>16</cursorPos>
<item handle="f5ab3e30151e1" parent="a6d311a93600a" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="11" wordCount="2" paraCount="0" cursorPos="16"/>
<name status="New" exported="True">New Chapter</name>
</item>
<item handle="8c659a11cd429" order="1" parent="a6d311a93600a">
<name>New Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>9</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>15</cursorPos>
<item handle="8c659a11cd429" parent="a6d311a93600a" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="9" wordCount="2" paraCount="0" cursorPos="15"/>
<name status="New" exported="True">New Scene</name>
</item>
<item handle="7695ce551d265" order="1" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="7695ce551d265" parent="None" order="1" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="afb3043c7b2b3" order="2" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="afb3043c7b2b3" parent="None" order="2" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="9d5247ab588e0" order="3" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="9d5247ab588e0" parent="None" order="3" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">World</name>
</item>
</content>
</novelWriterXML>
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.2" timeStamp="2021-08-02 02:30:49">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:31">
<project>
<name>Test Custom</name>
<title>Test Novel</title>
@@ -42,231 +42,97 @@
</importance>
</settings>
<content count="23">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="False"/>
<name status="New">Novel</name>
</item>
<item handle="44cb730c42048" order="0" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="44cb730c42048" parent="None" order="0" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="71ee45a3c0db9" order="0" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="71ee45a3c0db9" parent="None" order="0" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="811786ad1ae74" order="0" parent="None">
<name>Locations</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="811786ad1ae74" parent="None" order="0" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">Locations</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="None">
<name>Timeline</name>
<type>ROOT</type>
<class>TIMELINE</class>
<status>New</status>
<expanded>False</expanded>
<item handle="25fc0e7096fc6" parent="None" order="0" type="ROOT" class="TIMELINE">
<meta expanded="False"/>
<name status="New">Timeline</name>
</item>
<item handle="31489056e0916" order="0" parent="None">
<name>Objects</name>
<type>ROOT</type>
<class>OBJECT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="31489056e0916" parent="None" order="0" type="ROOT" class="OBJECT">
<meta expanded="False"/>
<name status="New">Objects</name>
</item>
<item handle="98010bd9270f9" order="0" parent="None">
<name>Entities</name>
<type>ROOT</type>
<class>ENTITY</class>
<status>New</status>
<expanded>False</expanded>
<item handle="98010bd9270f9" parent="None" order="0" type="ROOT" class="ENTITY">
<meta expanded="False"/>
<name status="New">Entities</name>
</item>
<item handle="0e17daca5f3e1" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="0e17daca5f3e1" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="1a6562590ef19" order="0" parent="73475cb40a568">
<name>Chapter 1</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="1a6562590ef19" parent="73475cb40a568" order="0" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">Chapter 1</name>
</item>
<item handle="031b4af5197ec" order="0" parent="1a6562590ef19">
<name>Chapter 1</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="031b4af5197ec" parent="1a6562590ef19" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Chapter 1</name>
</item>
<item handle="41cfc0d1f2d12" order="0" parent="1a6562590ef19">
<name>Scene 1.1</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="41cfc0d1f2d12" parent="1a6562590ef19" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 1.1</name>
</item>
<item handle="2858dcd1057d3" order="0" parent="1a6562590ef19">
<name>Scene 1.2</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="2858dcd1057d3" parent="1a6562590ef19" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 1.2</name>
</item>
<item handle="2fca346db6561" order="0" parent="1a6562590ef19">
<name>Scene 1.3</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="2fca346db6561" parent="1a6562590ef19" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 1.3</name>
</item>
<item handle="02d20bbd7e394" order="0" parent="73475cb40a568">
<name>Chapter 2</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="02d20bbd7e394" parent="73475cb40a568" order="0" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">Chapter 2</name>
</item>
<item handle="7688b6ef52555" order="0" parent="02d20bbd7e394">
<name>Chapter 2</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="7688b6ef52555" parent="02d20bbd7e394" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Chapter 2</name>
</item>
<item handle="c837649cce43f" order="0" parent="02d20bbd7e394">
<name>Scene 2.1</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="c837649cce43f" parent="02d20bbd7e394" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 2.1</name>
</item>
<item handle="6208ef0f7750c" order="0" parent="02d20bbd7e394">
<name>Scene 2.2</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="6208ef0f7750c" parent="02d20bbd7e394" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 2.2</name>
</item>
<item handle="3e1e967e9b793" order="0" parent="02d20bbd7e394">
<name>Scene 2.3</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="3e1e967e9b793" parent="02d20bbd7e394" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 2.3</name>
</item>
<item handle="39fa9ec190eee" order="0" parent="73475cb40a568">
<name>Chapter 3</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="39fa9ec190eee" parent="73475cb40a568" order="0" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">Chapter 3</name>
</item>
<item handle="d029fa3a95e17" order="0" parent="39fa9ec190eee">
<name>Chapter 3</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="d029fa3a95e17" parent="39fa9ec190eee" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Chapter 3</name>
</item>
<item handle="81b8a03f97e87" order="0" parent="39fa9ec190eee">
<name>Scene 3.1</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="81b8a03f97e87" parent="39fa9ec190eee" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 3.1</name>
</item>
<item handle="da4ea2a5506f2" order="0" parent="39fa9ec190eee">
<name>Scene 3.2</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="da4ea2a5506f2" parent="39fa9ec190eee" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 3.2</name>
</item>
<item handle="a68b412c42825" order="0" parent="39fa9ec190eee">
<name>Scene 3.3</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="a68b412c42825" parent="39fa9ec190eee" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 3.3</name>
</item>
</content>
</novelWriterXML>
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.2" timeStamp="2021-08-02 02:29:34">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:31">
<project>
<name>Test Custom</name>
<title>Test Novel</title>
@@ -42,138 +42,61 @@
</importance>
</settings>
<content count="14">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="False"/>
<name status="New">Novel</name>
</item>
<item handle="44cb730c42048" order="0" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="44cb730c42048" parent="None" order="0" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="71ee45a3c0db9" order="0" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="71ee45a3c0db9" parent="None" order="0" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="811786ad1ae74" order="0" parent="None">
<name>Locations</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="811786ad1ae74" parent="None" order="0" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">Locations</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="None">
<name>Timeline</name>
<type>ROOT</type>
<class>TIMELINE</class>
<status>New</status>
<expanded>False</expanded>
<item handle="25fc0e7096fc6" parent="None" order="0" type="ROOT" class="TIMELINE">
<meta expanded="False"/>
<name status="New">Timeline</name>
</item>
<item handle="31489056e0916" order="0" parent="None">
<name>Objects</name>
<type>ROOT</type>
<class>OBJECT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="31489056e0916" parent="None" order="0" type="ROOT" class="OBJECT">
<meta expanded="False"/>
<name status="New">Objects</name>
</item>
<item handle="98010bd9270f9" order="0" parent="None">
<name>Entities</name>
<type>ROOT</type>
<class>ENTITY</class>
<status>New</status>
<expanded>False</expanded>
<item handle="98010bd9270f9" parent="None" order="0" type="ROOT" class="ENTITY">
<meta expanded="False"/>
<name status="New">Entities</name>
</item>
<item handle="0e17daca5f3e1" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="0e17daca5f3e1" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="1a6562590ef19" order="0" parent="73475cb40a568">
<name>Scene 1</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="1a6562590ef19" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 1</name>
</item>
<item handle="031b4af5197ec" order="0" parent="73475cb40a568">
<name>Scene 2</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="031b4af5197ec" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 2</name>
</item>
<item handle="41cfc0d1f2d12" order="0" parent="73475cb40a568">
<name>Scene 3</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="41cfc0d1f2d12" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 3</name>
</item>
<item handle="2858dcd1057d3" order="0" parent="73475cb40a568">
<name>Scene 4</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="2858dcd1057d3" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 4</name>
</item>
<item handle="2fca346db6561" order="0" parent="73475cb40a568">
<name>Scene 5</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="2fca346db6561" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 5</name>
</item>
<item handle="02d20bbd7e394" order="0" parent="73475cb40a568">
<name>Scene 6</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="02d20bbd7e394" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Scene 6</name>
</item>
</content>
</novelWriterXML>
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.2" timeStamp="2021-08-02 02:28:30">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:32">
<project>
<name>New Project</name>
<title></title>
@@ -40,100 +40,45 @@
</importance>
</settings>
<content count="10">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="False"/>
<name status="New">Novel</name>
</item>
<item handle="44cb730c42048" order="0" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="44cb730c42048" parent="None" order="0" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="71ee45a3c0db9" order="0" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="71ee45a3c0db9" parent="None" order="0" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="811786ad1ae74" order="0" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="811786ad1ae74" parent="None" order="0" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">World</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="25fc0e7096fc6" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="31489056e0916" order="0" parent="73475cb40a568">
<name>New Chapter</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="31489056e0916" parent="73475cb40a568" order="0" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">New Chapter</name>
</item>
<item handle="98010bd9270f9" order="0" parent="31489056e0916">
<name>New Chapter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="98010bd9270f9" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Chapter</name>
</item>
<item handle="0e17daca5f3e1" order="0" parent="31489056e0916">
<name>New Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="0e17daca5f3e1" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Scene</name>
</item>
<item handle="1a6562590ef19" order="0" parent="31489056e0916">
<name>Hello</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="1a6562590ef19" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Hello</name>
</item>
<item handle="031b4af5197ec" order="0" parent="71ee45a3c0db9">
<name>Jane</name>
<type>FILE</type>
<class>CHARACTER</class>
<status>New</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="031b4af5197ec" parent="71ee45a3c0db9" order="0" type="FILE" class="CHARACTER" layout="NOTE">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Jane</name>
</item>
</content>
</novelWriterXML>
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.2" timeStamp="2021-08-02 02:31:23">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:31">
<project>
<name>New Project</name>
<title></title>
@@ -40,76 +40,37 @@
</importance>
</settings>
<content count="8">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="False"/>
<name status="New">Novel</name>
</item>
<item handle="44cb730c42048" order="0" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="44cb730c42048" parent="None" order="0" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="71ee45a3c0db9" order="0" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="71ee45a3c0db9" parent="None" order="0" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="811786ad1ae74" order="0" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="811786ad1ae74" parent="None" order="0" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">World</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="25fc0e7096fc6" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="31489056e0916" order="0" parent="73475cb40a568">
<name>New Chapter</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="31489056e0916" parent="73475cb40a568" order="0" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">New Chapter</name>
</item>
<item handle="98010bd9270f9" order="0" parent="31489056e0916">
<name>New Chapter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="98010bd9270f9" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Chapter</name>
</item>
<item handle="0e17daca5f3e1" order="0" parent="31489056e0916">
<name>New Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="0e17daca5f3e1" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Scene</name>
</item>
</content>
</novelWriterXML>
+38 -117
View File
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.6-rc1" hexVersion="0x010600c1" fileVersion="1.3" timeStamp="2022-02-14 22:15:58">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:32">
<project>
<name>New Project</name>
<title></title>
@@ -39,133 +39,54 @@
<entry blue="0" green="200" red="50">Main</entry>
</importance>
</settings>
<content count="16">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<content count="12">
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="False"/>
<name status="New">Novel</name>
</item>
<item handle="44cb730c42048" order="0" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="44cb730c42048" parent="None" order="0" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="71ee45a3c0db9" order="0" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="71ee45a3c0db9" parent="None" order="0" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="811786ad1ae74" order="0" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="811786ad1ae74" parent="None" order="0" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">World</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="25fc0e7096fc6" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="31489056e0916" order="0" parent="73475cb40a568">
<name>New Chapter</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="31489056e0916" parent="73475cb40a568" order="0" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">New Chapter</name>
</item>
<item handle="98010bd9270f9" order="0" parent="31489056e0916">
<name>New Chapter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="98010bd9270f9" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Chapter</name>
</item>
<item handle="0e17daca5f3e1" order="0" parent="31489056e0916">
<name>New Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>0</charCount>
<wordCount>0</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="0e17daca5f3e1" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="0" wordCount="0" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Scene</name>
</item>
<item handle="1a6562590ef19" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="1a6562590ef19" parent="None" order="0" type="ROOT" class="TIMELINE">
<meta expanded="False"/>
<name status="New">Timeline</name>
</item>
<item handle="031b4af5197ec" order="0" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="031b4af5197ec" parent="None" order="0" type="ROOT" class="OBJECT">
<meta expanded="False"/>
<name status="New">Object</name>
</item>
<item handle="41cfc0d1f2d12" order="0" parent="None">
<name>Character</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="41cfc0d1f2d12" parent="None" order="0" type="ROOT" class="CUSTOM">
<meta expanded="False"/>
<name status="New">Custom1</name>
</item>
<item handle="2858dcd1057d3" order="0" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
</item>
<item handle="2fca346db6561" order="0" parent="None">
<name>Timeline</name>
<type>ROOT</type>
<class>TIMELINE</class>
<status>New</status>
<expanded>False</expanded>
</item>
<item handle="02d20bbd7e394" order="0" parent="None">
<name>Object</name>
<type>ROOT</type>
<class>OBJECT</class>
<status>New</status>
<expanded>False</expanded>
</item>
<item handle="7688b6ef52555" order="0" parent="None">
<name>Custom1</name>
<type>ROOT</type>
<class>CUSTOM</class>
<status>New</status>
<expanded>False</expanded>
</item>
<item handle="c837649cce43f" order="0" parent="None">
<name>Custom2</name>
<type>ROOT</type>
<class>CUSTOM</class>
<status>New</status>
<expanded>False</expanded>
<item handle="2858dcd1057d3" parent="None" order="0" type="ROOT" class="CUSTOM">
<meta expanded="False"/>
<name status="New">Custom2</name>
</item>
</content>
</novelWriterXML>
@@ -1,11 +1,11 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-beta2" hexVersion="0x010500b2" fileVersion="1.3" timeStamp="2021-08-31 00:03:45">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 22:05:03">
<project>
<name>New Project</name>
<title></title>
<saveCount>5</saveCount>
<autoCount>2</autoCount>
<editTime>4</editTime>
<editTime>3</editTime>
</project>
<settings>
<doBackup>True</doBackup>
@@ -40,119 +40,53 @@
</importance>
</settings>
<content count="12">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>True</expanded>
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="True"/>
<name status="New">Novel</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>11</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="25fc0e7096fc6" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="11" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="31489056e0916" order="1" parent="73475cb40a568">
<name>New Chapter</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>True</expanded>
<item handle="31489056e0916" parent="73475cb40a568" order="1" type="FOLDER" class="NOVEL">
<meta expanded="True"/>
<name status="New">New Chapter</name>
</item>
<item handle="98010bd9270f9" order="0" parent="31489056e0916">
<name>New Chapter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>11</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="98010bd9270f9" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="11" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Chapter</name>
</item>
<item handle="0e17daca5f3e1" order="1" parent="31489056e0916">
<name>New Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>612</charCount>
<wordCount>95</wordCount>
<paraCount>10</paraCount>
<cursorPos>768</cursorPos>
<item handle="0e17daca5f3e1" parent="31489056e0916" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="612" wordCount="95" paraCount="10" cursorPos="768"/>
<name status="New" exported="True">New Scene</name>
</item>
<item handle="44cb730c42048" order="1" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>True</expanded>
<item handle="44cb730c42048" parent="None" order="1" type="ROOT" class="PLOT">
<meta expanded="True"/>
<name status="New">Plot</name>
</item>
<item handle="031b4af5197ec" order="0" parent="44cb730c42048">
<name>New File</name>
<type>FILE</type>
<class>PLOT</class>
<status>New</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>48</charCount>
<wordCount>10</wordCount>
<paraCount>1</paraCount>
<cursorPos>69</cursorPos>
<item handle="031b4af5197ec" parent="44cb730c42048" order="0" type="FILE" class="PLOT" layout="NOTE">
<meta charCount="48" wordCount="10" paraCount="1" cursorPos="69"/>
<name status="New" exported="True">New File</name>
</item>
<item handle="71ee45a3c0db9" order="2" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>True</expanded>
<item handle="71ee45a3c0db9" parent="None" order="2" type="ROOT" class="CHARACTER">
<meta expanded="True"/>
<name status="New">Characters</name>
</item>
<item handle="1a6562590ef19" order="0" parent="71ee45a3c0db9">
<name>New File</name>
<type>FILE</type>
<class>CHARACTER</class>
<status>New</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>34</charCount>
<wordCount>8</wordCount>
<paraCount>1</paraCount>
<cursorPos>51</cursorPos>
<item handle="1a6562590ef19" parent="71ee45a3c0db9" order="0" type="FILE" class="CHARACTER" layout="NOTE">
<meta charCount="34" wordCount="8" paraCount="1" cursorPos="51"/>
<name status="New" exported="True">New File</name>
</item>
<item handle="811786ad1ae74" order="3" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>True</expanded>
<item handle="811786ad1ae74" parent="None" order="3" type="ROOT" class="WORLD">
<meta expanded="True"/>
<name status="New">World</name>
</item>
<item handle="41cfc0d1f2d12" order="0" parent="811786ad1ae74">
<name>New File</name>
<type>FILE</type>
<class>WORLD</class>
<status>New</status>
<exported>True</exported>
<layout>NOTE</layout>
<charCount>51</charCount>
<wordCount>9</wordCount>
<paraCount>1</paraCount>
<cursorPos>68</cursorPos>
<item handle="41cfc0d1f2d12" parent="811786ad1ae74" order="0" type="FILE" class="WORLD" layout="NOTE">
<meta charCount="51" wordCount="9" paraCount="1" cursorPos="68"/>
<name status="New" exported="True">New File</name>
</item>
<item handle="2fca346db6561" order="4" parent="None">
<name>Trash</name>
<type>TRASH</type>
<class>TRASH</class>
<status>None</status>
<expanded>True</expanded>
<item handle="2fca346db6561" parent="None" order="4" type="TRASH" class="TRASH">
<meta expanded="True"/>
<name status="None">Trash</name>
</item>
</content>
</novelWriterXML>
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.2" timeStamp="2021-08-02 02:49:51">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:41">
<project>
<name>New Project</name>
<title></title>
@@ -40,76 +40,37 @@
</importance>
</settings>
<content count="8">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="False"/>
<name status="New">Novel</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>11</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="25fc0e7096fc6" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="11" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="31489056e0916" order="1" parent="73475cb40a568">
<name>New Chapter</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="31489056e0916" parent="73475cb40a568" order="1" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">New Chapter</name>
</item>
<item handle="98010bd9270f9" order="0" parent="31489056e0916">
<name>New Chapter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>11</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="98010bd9270f9" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="11" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Chapter</name>
</item>
<item handle="0e17daca5f3e1" order="1" parent="31489056e0916">
<name>New Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>9</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="0e17daca5f3e1" parent="31489056e0916" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="9" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Scene</name>
</item>
<item handle="44cb730c42048" order="1" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="44cb730c42048" parent="None" order="1" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="71ee45a3c0db9" order="2" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="71ee45a3c0db9" parent="None" order="2" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="811786ad1ae74" order="3" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="811786ad1ae74" parent="None" order="3" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">World</name>
</item>
</content>
</novelWriterXML>
@@ -1,5 +1,5 @@
<?xml version='1.0' encoding='utf-8'?>
<novelWriterXML appVersion="1.5-alpha0" hexVersion="0x010500a0" fileVersion="1.2" timeStamp="2021-08-02 03:04:13">
<novelWriterXML appVersion="1.7-alpha0" hexVersion="0x010700a0" fileVersion="1.4" timeStamp="2022-02-17 21:57:36">
<project>
<name>Project Name</name>
<title>Project Title</title>
@@ -46,76 +46,37 @@
</importance>
</settings>
<content count="8">
<item handle="73475cb40a568" order="0" parent="None">
<name>Novel</name>
<type>ROOT</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="73475cb40a568" parent="None" order="0" type="ROOT" class="NOVEL">
<meta expanded="False"/>
<name status="New">Novel</name>
</item>
<item handle="25fc0e7096fc6" order="0" parent="73475cb40a568">
<name>Title Page</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>11</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="25fc0e7096fc6" parent="73475cb40a568" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="11" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">Title Page</name>
</item>
<item handle="31489056e0916" order="1" parent="73475cb40a568">
<name>New Chapter</name>
<type>FOLDER</type>
<class>NOVEL</class>
<status>New</status>
<expanded>False</expanded>
<item handle="31489056e0916" parent="73475cb40a568" order="1" type="FOLDER" class="NOVEL">
<meta expanded="False"/>
<name status="New">New Chapter</name>
</item>
<item handle="98010bd9270f9" order="0" parent="31489056e0916">
<name>New Chapter</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>11</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="98010bd9270f9" parent="31489056e0916" order="0" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="11" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Chapter</name>
</item>
<item handle="0e17daca5f3e1" order="1" parent="31489056e0916">
<name>New Scene</name>
<type>FILE</type>
<class>NOVEL</class>
<status>New</status>
<exported>True</exported>
<layout>DOCUMENT</layout>
<charCount>9</charCount>
<wordCount>2</wordCount>
<paraCount>0</paraCount>
<cursorPos>0</cursorPos>
<item handle="0e17daca5f3e1" parent="31489056e0916" order="1" type="FILE" class="NOVEL" layout="DOCUMENT">
<meta charCount="9" wordCount="2" paraCount="0" cursorPos="0"/>
<name status="New" exported="True">New Scene</name>
</item>
<item handle="44cb730c42048" order="1" parent="None">
<name>Plot</name>
<type>ROOT</type>
<class>PLOT</class>
<status>New</status>
<expanded>False</expanded>
<item handle="44cb730c42048" parent="None" order="1" type="ROOT" class="PLOT">
<meta expanded="False"/>
<name status="New">Plot</name>
</item>
<item handle="71ee45a3c0db9" order="2" parent="None">
<name>Characters</name>
<type>ROOT</type>
<class>CHARACTER</class>
<status>New</status>
<expanded>False</expanded>
<item handle="71ee45a3c0db9" parent="None" order="2" type="ROOT" class="CHARACTER">
<meta expanded="False"/>
<name status="New">Characters</name>
</item>
<item handle="811786ad1ae74" order="3" parent="None">
<name>World</name>
<type>ROOT</type>
<class>WORLD</class>
<status>New</status>
<expanded>False</expanded>
<item handle="811786ad1ae74" parent="None" order="3" type="ROOT" class="WORLD">
<meta expanded="False"/>
<name status="New">World</name>
</item>
</content>
</novelWriterXML>
+3 -20
View File
@@ -24,8 +24,6 @@ import os
import time
import pytest
from datetime import datetime
from mock import causeOSError
from tools import writeFile
@@ -33,9 +31,9 @@ from novelwriter.guimain import GuiMain
from novelwriter.common import (
checkString, checkInt, checkFloat, checkBool, checkHandle, isHandle,
isTitleTag, isItemClass, isItemType, isItemLayout, hexToInt, checkIntRange,
checkIntTuple, formatInt, formatTimeStamp, formatTime, parseTimeStamp,
splitVersionNumber, transferCase, fuzzyTime, numberToRoman, jsonEncode,
readTextFile, makeFileNameSafe, sha256sum, getGuiItem, NWConfigParser
checkIntTuple, formatInt, formatTimeStamp, formatTime, splitVersionNumber,
transferCase, fuzzyTime, numberToRoman, jsonEncode, readTextFile,
makeFileNameSafe, sha256sum, getGuiItem, NWConfigParser
)
@@ -272,21 +270,6 @@ def testBaseCommon_FormatTime():
# END Test testBaseCommon_FormatTime
@pytest.mark.base
def testBaseCommon_ParseTimeStamp():
"""Test the parseTimeStamp function.
"""
localEpoch = datetime(2000, 1, 1).timestamp()
assert parseTimeStamp(None, 0.0, allowNone=True) is None
assert parseTimeStamp("None", 0.0, allowNone=True) is None
assert parseTimeStamp("None", 0.0) == 0.0
assert parseTimeStamp("2000-01-01 00:00:00", 123.0) == localEpoch
assert parseTimeStamp("2000-13-01 00:00:00", 123.0) == 123.0
assert parseTimeStamp("2000-01-32 00:00:00", 123.0) == 123.0
# END Test testBaseCommon_ParseTimeStamp
@pytest.mark.base
def testBaseCommon_SplitVersionNumber():
"""Test the splitVersionNumber function.
+109 -27
View File
@@ -306,22 +306,6 @@ def testCoreItem_LayoutSetter(mockGUI):
theItem.setLayout("NOTE")
assert theItem.itemLayout == nwItemLayout.NOTE
# Deprecated Layouts
theItem.setLayout("TITLE")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("PAGE")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("BOOK")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("PARTITION")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("UNNUMBERED")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("CHAPTER")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("SCENE")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
# Alternatives
theItem.setLayout(nwItemLayout.NOTE)
assert theItem.itemLayout == nwItemLayout.NOTE
@@ -358,12 +342,9 @@ def testCoreItem_XMLPackUnpack(mockGUI, caplog):
xContent = etree.SubElement(nwXML, "content")
theItem.packXML(xContent)
assert etree.tostring(xContent, pretty_print=False, encoding="utf-8") == (
b"<content>"
b"<item handle=\"0123456789abc\" order=\"1\" parent=\"0123456789abc\">"
b"<name>A Name</name><type>FILE</type><class>NOVEL</class><status>New</status>"
b"<exported>False</exported><layout>NOTE</layout><charCount>7</charCount>"
b"<wordCount>5</wordCount><paraCount>3</paraCount><cursorPos>11</cursorPos></item>"
b"</content>"
b'<content><item handle="0123456789abc" parent="0123456789abc" order="1" type="FILE" '
b'class="NOVEL" layout="NOTE"><meta charCount="7" wordCount="5" paraCount="3" '
b'cursorPos="11"/><name status="New" exported="False">A Name</name></item></content>'
)
# Unpack
@@ -404,11 +385,8 @@ def testCoreItem_XMLPackUnpack(mockGUI, caplog):
xContent = etree.SubElement(nwXML, "content")
theItem.packXML(xContent)
assert etree.tostring(xContent, pretty_print=False, encoding="utf-8") == (
b"<content>"
b"<item handle=\"0123456789abc\" order=\"1\" parent=\"0123456789abc\">"
b"<name>A Name</name><type>FOLDER</type><class>NOVEL</class><status>New</status>"
b"<expanded>True</expanded></item>"
b"</content>"
b'<content><item handle="0123456789abc" parent="0123456789abc" order="1" type="FOLDER" '
b'class="NOVEL"><meta expanded="True"/><name status="New">A Name</name></item></content>'
)
# Unpack
@@ -462,3 +440,107 @@ def testCoreItem_XMLPackUnpack(mockGUI, caplog):
)
# END Test testCoreItem_XMLPackUnpack
@pytest.mark.core
def testCoreItem_ConvertFromFmt12(mockGUI):
"""Test the setter for all the nwItemLayout values for the NWItem
class using the class names that were present in file format 1.2.
"""
theProject = NWProject(mockGUI)
theItem = NWItem(theProject)
# Deprecated Layouts
theItem.setLayout("TITLE")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("PAGE")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("BOOK")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("PARTITION")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("UNNUMBERED")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("CHAPTER")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("SCENE")
assert theItem.itemLayout == nwItemLayout.DOCUMENT
theItem.setLayout("MUMBOJUMBO")
assert theItem.itemLayout == nwItemLayout.NO_LAYOUT
# END Test testCoreItem_ConvertFromFmt12
@pytest.mark.core
def testCoreItem_ConvertFromFmt13(mockGUI):
"""Test packing and unpacking XML objects for the NWItem class from
format version 1.3
"""
theProject = NWProject(mockGUI)
# Make Version 1.3 XML
nwXML = etree.Element("novelWriterXML")
xContent = etree.SubElement(nwXML, "content")
# Folder
xPack = etree.SubElement(xContent, "item", attrib={
"handle": "a000000000001",
"order": "1",
"parent": "b000000000001",
})
NWItem._subPack(xPack, "name", text="Folder")
NWItem._subPack(xPack, "type", text="FOLDER")
NWItem._subPack(xPack, "class", text="NOVEL")
NWItem._subPack(xPack, "status", text="New")
NWItem._subPack(xPack, "expanded", text="True")
# Unpack Folder
theItem = NWItem(theProject)
theItem.unpackXML(xContent[0])
assert theItem.itemHandle == "a000000000001"
assert theItem.itemParent == "b000000000001"
assert theItem.itemOrder == 1
assert theItem.isExpanded is True
assert theItem.isExported is True
assert theItem.charCount == 0
assert theItem.wordCount == 0
assert theItem.paraCount == 0
assert theItem.cursorPos == 0
assert theItem.itemClass == nwItemClass.NOVEL
assert theItem.itemType == nwItemType.FOLDER
assert theItem.itemLayout == nwItemLayout.NO_LAYOUT
# File
xPack = etree.SubElement(xContent, "item", attrib={
"handle": "c000000000001",
"order": "2",
"parent": "a000000000001",
})
NWItem._subPack(xPack, "name", text="Scene")
NWItem._subPack(xPack, "type", text="FILE")
NWItem._subPack(xPack, "class", text="NOVEL")
NWItem._subPack(xPack, "status", text="New")
NWItem._subPack(xPack, "exported", text="True")
NWItem._subPack(xPack, "layout", text="DOCUMENT")
NWItem._subPack(xPack, "charCount", text="600")
NWItem._subPack(xPack, "wordCount", text="100")
NWItem._subPack(xPack, "paraCount", text="6")
NWItem._subPack(xPack, "cursorPos", text="50")
# Unpack File
theItem = NWItem(theProject)
theItem.unpackXML(xContent[1])
assert theItem.itemHandle == "c000000000001"
assert theItem.itemParent == "a000000000001"
assert theItem.itemOrder == 2
assert theItem.isExpanded is False
assert theItem.isExported is True
assert theItem.charCount == 600
assert theItem.wordCount == 100
assert theItem.paraCount == 6
assert theItem.cursorPos == 50
assert theItem.itemClass == nwItemClass.NOVEL
assert theItem.itemType == nwItemType.FILE
assert theItem.itemLayout == nwItemLayout.DOCUMENT
# END Test testCoreItem_ConvertFromFmt13
+13 -8
View File
@@ -28,12 +28,17 @@ from novelwriter.core import NWProject, NWDoc
from novelwriter.core.tokenizer import Tokenizer
class BareTokenizer(Tokenizer):
def doConvert(self):
pass
@pytest.mark.core
def testCoreToken_Setters(mockGUI):
"""Test all the setters for the Tokenizer class.
"""
theProject = NWProject(mockGUI)
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
# Verify defaults
assert theToken._fmtTitle == "%title%"
@@ -135,7 +140,7 @@ def testCoreToken_TextOps(monkeypatch, nwMinimal, mockGUI):
theProject.projLang = "en"
theProject._loadProjectLocalisation()
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
theToken.setKeepMarkdown(True)
assert theProject.openProject(nwMinimal)
@@ -222,7 +227,7 @@ def testCoreToken_HeaderFormat(mockGUI):
"""Test the tokenization of header formats in the Tokenizer class.
"""
theProject = NWProject(mockGUI)
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
theToken.setKeepMarkdown(True)
# Title
@@ -426,7 +431,7 @@ def testCoreToken_MetaFormat(mockGUI):
"""Test the tokenization of meta formats in the Tokenizer class.
"""
theProject = NWProject(mockGUI)
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
theToken.setKeepMarkdown(True)
# Comment
@@ -495,7 +500,7 @@ def testCoreToken_MarginFormat(mockGUI):
"""Test the tokenization of margin formats in the Tokenizer class.
"""
theProject = NWProject(mockGUI)
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
theToken.setKeepMarkdown(True)
# Alignment and Indentation
@@ -550,7 +555,7 @@ def testCoreToken_TextFormat(mockGUI):
"""Test the tokenization of text formats in the Tokenizer class.
"""
theProject = NWProject(mockGUI)
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
theToken.setKeepMarkdown(True)
# Text
@@ -672,7 +677,7 @@ def testCoreToken_SpecialFormat(mockGUI):
"""Test the tokenization of special formats in the Tokenizer class.
"""
theProject = NWProject(mockGUI)
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
theToken._isNovel = True
@@ -877,7 +882,7 @@ def testCoreToken_ProcessHeaders(mockGUI):
theProject = NWProject(mockGUI)
theProject.projLang = "en"
theProject._loadProjectLocalisation()
theToken = Tokenizer(theProject)
theToken = BareTokenizer(theProject)
# Nothing
theToken._theText = "Some text ...\n"
+23 -30
View File
@@ -379,36 +379,29 @@ def testCoreTree_XMLPackUnpack(mockGUI, mockItems):
nwXML = etree.Element("novelWriterXML")
theTree.packXML(nwXML)
assert etree.tostring(nwXML, pretty_print=False, encoding="utf-8") == (
b"<novelWriterXML>"
b"<content count=\"8\">"
b"<item handle=\"a000000000001\" order=\"0\" parent=\"None\">"
b"<name>Novel</name><type>ROOT</type><class>NOVEL</class><status>None</status>"
b"<expanded>True</expanded></item>"
b"<item handle=\"b000000000001\" order=\"0\" parent=\"a000000000001\">"
b"<name>Act One</name><type>FOLDER</type><class>NOVEL</class><status>None</status>"
b"<expanded>True</expanded></item>"
b"<item handle=\"c000000000001\" order=\"0\" parent=\"b000000000001\">"
b"<name>Chapter One</name><type>FILE</type><class>NOVEL</class><status>None</status>"
b"<exported>True</exported><layout>DOCUMENT</layout><charCount>300</charCount>"
b"<wordCount>50</wordCount><paraCount>2</paraCount><cursorPos>0</cursorPos></item>"
b"<item handle=\"c000000000002\" order=\"0\" parent=\"b000000000001\">"
b"<name>Scene One</name><type>FILE</type><class>NOVEL</class><status>None</status>"
b"<exported>True</exported><layout>DOCUMENT</layout><charCount>3000</charCount>"
b"<wordCount>500</wordCount><paraCount>20</paraCount><cursorPos>0</cursorPos></item>"
b"<item handle=\"a000000000002\" order=\"0\" parent=\"None\">"
b"<name>Outtakes</name><type>ROOT</type><class>ARCHIVE</class><status>None</status>"
b"<expanded>False</expanded></item>"
b"<item handle=\"a000000000003\" order=\"0\" parent=\"None\">"
b"<name>Trash</name><type>TRASH</type><class>TRASH</class><status>None</status>"
b"<expanded>False</expanded></item>"
b"<item handle=\"a000000000004\" order=\"0\" parent=\"None\">"
b"<name>Characters</name><type>ROOT</type><class>CHARACTER</class><status>None</status>"
b"<expanded>True</expanded></item>"
b"<item handle=\"b000000000002\" order=\"0\" parent=\"a000000000002\">"
b"<name>Jane Doe</name><type>FILE</type><class>CHARACTER</class><status>None</status>"
b"<exported>True</exported><layout>NOTE</layout><charCount>2000</charCount>"
b"<wordCount>400</wordCount><paraCount>16</paraCount><cursorPos>0</cursorPos></item>"
b"</content></novelWriterXML>"
b'<novelWriterXML>'
b'<content count="8">'
b'<item handle="a000000000001" parent="None" order="0" type="ROOT" class="NOVEL">'
b'<meta expanded="True"/><name status="None">Novel</name></item>'
b'<item handle="b000000000001" parent="a000000000001" order="0" type="FOLDER" '
b'class="NOVEL"><meta expanded="True"/><name status="None">Act One</name></item>'
b'<item handle="c000000000001" parent="b000000000001" order="0" type="FILE" class="NOVEL" '
b'layout="DOCUMENT"><meta charCount="300" wordCount="50" paraCount="2" cursorPos="0"/>'
b'<name status="None" exported="True">Chapter One</name></item>'
b'<item handle="c000000000002" parent="b000000000001" order="0" type="FILE" class="NOVEL" '
b'layout="DOCUMENT"><meta charCount="3000" wordCount="500" paraCount="20" cursorPos="0"/>'
b'<name status="None" exported="True">Scene One</name></item>'
b'<item handle="a000000000002" parent="None" order="0" type="ROOT" class="ARCHIVE">'
b'<meta expanded="False"/><name status="None">Outtakes</name></item>'
b'<item handle="a000000000003" parent="None" order="0" type="TRASH" class="TRASH">'
b'<meta expanded="False"/><name status="None">Trash</name></item>'
b'<item handle="a000000000004" parent="None" order="0" type="ROOT" class="CHARACTER">'
b'<meta expanded="True"/><name status="None">Characters</name></item>'
b'<item handle="b000000000002" parent="a000000000002" order="0" type="FILE" '
b'class="CHARACTER" layout="NOTE"><meta charCount="2000" wordCount="400" paraCount="16" '
b'cursorPos="0"/><name status="None" exported="True">Jane Doe</name></item>'
b'</content>'
b'</novelWriterXML>'
)
theTree.clear()
+12 -5
View File
@@ -1286,13 +1286,13 @@ def testGuiEditor_Search(qtbot, monkeypatch, nwGUI, nwLipsum):
monkeypatch.setattr(GuiDocEditor, "hasFocus", lambda *a: True)
nwGUI.theProject.projTree.setSeed(42)
assert nwGUI.openProject(nwLipsum)
assert nwGUI.openDocument("4c4f28287af27")
assert nwGUI.openProject(nwLipsum) is True
assert nwGUI.openDocument("4c4f28287af27") is True
origText = nwGUI.docEditor.getText()
qtbot.wait(stepDelay)
# Select the Word "est"
assert nwGUI.docEditor.setCursorPosition(630)
nwGUI.docEditor.setCursorPosition(630)
nwGUI.docEditor._makeSelection(QTextCursor.WordUnderCursor)
theCursor = nwGUI.docEditor.textCursor()
assert theCursor.selectedText() == "est"
@@ -1331,7 +1331,7 @@ def testGuiEditor_Search(qtbot, monkeypatch, nwGUI, nwLipsum):
assert nwGUI.docEditor.docSearch.isVisible() is True
# Search for non-existing
assert nwGUI.docEditor.setCursorPosition(0)
nwGUI.docEditor.setCursorPosition(0)
assert nwGUI.docEditor.docSearch.setSearchText("abcdef")
qtbot.mouseClick(nwGUI.docEditor.docSearch.searchButton, Qt.LeftButton, delay=keyDelay)
assert nwGUI.docEditor.getCursorPosition() < 3 # No result
@@ -1342,11 +1342,18 @@ def testGuiEditor_Search(qtbot, monkeypatch, nwGUI, nwLipsum):
assert nwGUI.docEditor.docSearch.isRegEx is True
# Set invalid RegEx
assert nwGUI.docEditor.setCursorPosition(0)
nwGUI.docEditor.setCursorPosition(0)
assert nwGUI.docEditor.docSearch.setSearchText(r"\bSus[")
qtbot.mouseClick(nwGUI.docEditor.docSearch.searchButton, Qt.LeftButton, delay=keyDelay)
assert nwGUI.docEditor.getCursorPosition() < 3 # No result
# Set dangerous RegEx (issue #1015)
# If this doesn't get caught, the app will hang
nwGUI.docEditor.setCursorPosition(0)
assert nwGUI.docEditor.docSearch.setSearchText(r".*")
qtbot.mouseClick(nwGUI.docEditor.docSearch.searchButton, Qt.LeftButton, delay=keyDelay)
assert abs(nwGUI.docEditor.getCursorPosition() - 14) < 3
# Set valid RegEx
assert nwGUI.docEditor.docSearch.setSearchText(r"\bSus")
qtbot.mouseClick(nwGUI.docEditor.docSearch.searchButton, Qt.LeftButton, delay=keyDelay)