Merge branch 'main' into parse_story_structure
This commit is contained in:
@@ -29,7 +29,6 @@ import json
|
||||
import logging
|
||||
import random
|
||||
|
||||
from collections.abc import ItemsView, Iterable
|
||||
from pathlib import Path
|
||||
from time import time
|
||||
from typing import TYPE_CHECKING
|
||||
@@ -44,7 +43,9 @@ from novelwriter.error import logException
|
||||
from novelwriter.text.comments import processComment
|
||||
from novelwriter.text.counting import standardCounter
|
||||
|
||||
if TYPE_CHECKING: # pragma: no cover
|
||||
if TYPE_CHECKING:
|
||||
from collections.abc import ItemsView, Iterable
|
||||
|
||||
from novelwriter.core.item import NWItem
|
||||
from novelwriter.core.project import NWProject
|
||||
|
||||
@@ -900,7 +901,7 @@ class IndexCache:
|
||||
which provides lookup capabilities and caching for shared data.
|
||||
"""
|
||||
|
||||
__slots__ = ("tags", "story")
|
||||
__slots__ = ("story", "tags")
|
||||
|
||||
def __init__(self, tagsIndex: TagsIndex) -> None:
|
||||
self.tags: TagsIndex = tagsIndex
|
||||
@@ -921,7 +922,7 @@ class ItemIndex:
|
||||
IndexHeading object for each heading of the text.
|
||||
"""
|
||||
|
||||
__slots__ = ("_project", "_cache", "_items")
|
||||
__slots__ = ("_cache", "_items", "_project")
|
||||
|
||||
def __init__(self, project: NWProject, tagsIndex: TagsIndex) -> None:
|
||||
self._project = project
|
||||
|
||||
Reference in New Issue
Block a user