diff --git a/dist/schemascii-0.2.0-py3-none-any.whl b/dist/schemascii-0.2.0-py3-none-any.whl new file mode 100644 index 0000000..45213ed Binary files /dev/null and b/dist/schemascii-0.2.0-py3-none-any.whl differ diff --git a/dist/schemascii-0.2.0.tar.gz b/dist/schemascii-0.2.0.tar.gz new file mode 100644 index 0000000..31a5dc9 Binary files /dev/null and b/dist/schemascii-0.2.0.tar.gz differ diff --git a/format.md b/format.md index 177f2b9..3046a91 100644 --- a/format.md +++ b/format.md @@ -65,4 +65,6 @@ Examples: ## Inline configuration values +**New in 0.2.0!** + You can specify configuration values for rendering the components inline in the document by writing `!name=value!` in your document. See the help output of the Schemascii CLI for the different options (in the README) or look at the config options at the top of [`configs.py`](https://github.com/dragoncoder047/schemascii/blob/main/schemascii/configs.py). The most common options I use are `scale` and `padding`. diff --git a/pyproject.toml b/pyproject.toml index d6a07bc..5743437 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta" [project] name = "schemascii" -version = "0.1.3" +version = "0.2.0" description = "Render ASCII-art schematics to SVG" readme = "README.md" authors = [{ name = "dragoncoder047", email = "101021094+dragoncoder047@users.noreply.github.com" }] diff --git a/schemascii/__init__.py b/schemascii/__init__.py index 26e56e5..9206c36 100644 --- a/schemascii/__init__.py +++ b/schemascii/__init__.py @@ -8,7 +8,7 @@ from .utils import XML from .errors import * -__version__ = "0.1.3" +__version__ = "0.2.0" def render(filename: str, text: str = None, **options) -> str: @@ -19,7 +19,9 @@ def render(filename: str, text: str = None, **options) -> str: # get everything grid = Grid(filename, text) # Passed-in options override diagram inline options - options = apply_config_defaults(get_inline_configs(grid) | options) + options = apply_config_defaults(options + | get_inline_configs(grid) + | options.get("override_options", {})) components, bom_data = find_all(grid) terminals = {c: find_edge_marks(grid, c) for c in components} fixed_bom_data = {c: [b for b in bom_data if