Source code for semi_cr.assets
"""Asset path utilities."""
from pathlib import Path
# Assets directory is at the repo root, sibling to src/
_ASSETS_DIR = Path(__file__).parent.parent.parent / "assets"
[docs]
def get_asset_path(filename: str) -> Path:
"""Return the full path to an asset file."""
return _ASSETS_DIR / filename
[docs]
def get_font_path(filename: str = "Inconsolata-Medium.ttf") -> str:
"""Return the full path to a font file as a string."""
return str(get_asset_path(filename))
[docs]
def get_sample_gds_path() -> str:
"""Return the full path to the sample GDS file."""
return str(get_asset_path("343_vj_7p2.gds"))