diff --git a/.github/workflows/deploy-pages.yml b/.github/workflows/deploy-pages.yml index a570248..e8790d4 100644 --- a/.github/workflows/deploy-pages.yml +++ b/.github/workflows/deploy-pages.yml @@ -7,6 +7,7 @@ on: paths: - 'docs/**' - 'web/**' + - 'tools/sourcey-api/**' - 'README.md' - '.github/workflows/deploy-pages.yml' push: @@ -15,6 +16,7 @@ on: paths: - 'docs/**' - 'web/**' + - 'tools/sourcey-api/**' - 'README.md' - '.github/workflows/deploy-pages.yml' workflow_dispatch: @@ -28,7 +30,7 @@ jobs: steps: - uses: actions/checkout@v4 with: - # Full history + tags so the docs generator can resolve a release line + # Full history + tags so the Sourcey generator can resolve a release line # via `git describe` (default shallow checkouts have neither). fetch-depth: 0 fetch-tags: true @@ -38,20 +40,20 @@ jobs: with: node-version: '22' cache: npm - cache-dependency-path: docs/package-lock.json + cache-dependency-path: tools/sourcey-api/package-lock.json - - name: Install documentation dependencies - run: npm ci --prefix docs + - name: Install Sourcey documentation dependencies + run: npm ci --prefix tools/sourcey-api - - name: Build and verify Sourcey reference - run: npm run check --prefix docs + - name: Build and verify Sourcey native reference + run: npm run check --prefix tools/sourcey-api - name: Assemble GitHub Pages site run: | mkdir -p _site cp -r web/* _site/ mkdir -p _site/api - cp -r docs/dist/* _site/api/ + cp -r tools/sourcey-api/dist/* _site/api/ touch _site/.nojekyll - name: Deploy to gh-pages diff --git a/.github/workflows/publish-micropython-lib.yml b/.github/workflows/publish-micropython-lib.yml index 3e8e2fe..0ad90a2 100644 --- a/.github/workflows/publish-micropython-lib.yml +++ b/.github/workflows/publish-micropython-lib.yml @@ -1,5 +1,5 @@ -# Publish pure-Python graphics to micropython-lib, MIP index, and TestPyPI (pydisplay-graphics). -# Native graphics-cmod wheels are published by publish-testpypi.yml on the same tag. +# Publish pure-Python pygraphics to micropython-lib, MIP index, and TestPyPI (pygraphics). +# Native pygraphics-cmod wheels are published by publish-testpypi.yml on the same tag. # # Release trigger: push tag vX.Y.Z (see scripts/publish_release_tag.sh). # @@ -20,11 +20,11 @@ on: type: string required: false sync_sources: - description: Sync graphics into micropython-lib + description: Sync pygraphics into micropython-lib type: boolean default: true upload_testpypi: - description: Upload pydisplay-graphics wheels to TestPyPI + description: Upload pygraphics wheels to TestPyPI type: boolean default: false publish_mip_index: @@ -47,7 +47,7 @@ concurrency: jobs: publish: runs-on: ubuntu-latest - if: github.repository == 'PyDevices/graphics' + if: github.repository == 'PyDevices/pygraphics' steps: - uses: actions/checkout@v4 with: @@ -81,7 +81,7 @@ jobs: VERSION="$(normalize "$TAG")" fi echo "version=$VERSION" >> "$GITHUB_OUTPUT" - echo "Publishing pydisplay-graphics / MIP release $VERSION" + echo "Publishing pygraphics / MIP release $VERSION" - name: Verify publish secrets env: @@ -99,8 +99,8 @@ jobs: fi fi if [[ ${#missing[@]} -gt 0 ]]; then - echo "::error::GitHub did not supply secrets to PyDevices/graphics: ${missing[*]}" - echo "Org Settings → Secrets → Actions → each secret → Repository access → include graphics." + echo "::error::GitHub did not supply secrets to PyDevices/pygraphics: ${missing[*]}" + echo "Org Settings → Secrets → Actions → each secret → Repository access → include pygraphics." exit 1 fi @@ -126,7 +126,7 @@ jobs: git -C micropython-lib remote set-url origin \ "https://x-access-token:${{ secrets.MICROPYTHON_LIB_DEPLOY_TOKEN }}@github.com/PyDevices/micropython-lib.git" - - name: Sync graphics into micropython-lib + - name: Sync pygraphics into micropython-lib if: github.event_name == 'push' || inputs.sync_sources == true env: MICROPYTHON_LIB_DIR: ${{ github.workspace }}/micropython-lib @@ -136,7 +136,7 @@ jobs: VERSION="${{ steps.version.outputs.version }}" MSG="${{ inputs.commit_message }}" if [[ -z "$MSG" ]]; then - MSG="graphics: Release v${VERSION} (${GITHUB_SHA::7})." + MSG="pygraphics: Release v${VERSION} (${GITHUB_SHA::7})." fi EXTRA=(--commit-message "$MSG" --push) if [[ "${{ github.event_name }}" != "push" && "${{ inputs.upload_testpypi }}" != "true" ]]; then @@ -149,7 +149,7 @@ jobs: if: github.event_name == 'push' || inputs.publish_mip_index == true env: MICROPYTHON_LIB_DIR: ${{ github.workspace }}/micropython-lib - GRAPHICS_DIR: ${{ github.workspace }} + PYGRAPHICS_DIR: ${{ github.workspace }} MICROPYTHON_DIR: /tmp/micropython MIP_INDEX_OUTPUT: /tmp/mip-index run: | diff --git a/.github/workflows/publish-testpypi.yml b/.github/workflows/publish-testpypi.yml index 16ca72b..fbc799d 100644 --- a/.github/workflows/publish-testpypi.yml +++ b/.github/workflows/publish-testpypi.yml @@ -1,4 +1,4 @@ -# Build graphics-cmod wheels (Linux + Windows + Android) with cibuildwheel and upload to TestPyPI. +# Build pygraphics-cmod wheels (Linux + Windows + Android) with cibuildwheel and upload to TestPyPI. # # Release trigger: push an annotated semver tag vX.Y.Z (see scripts/publish_release_tag.sh), # or workflow_dispatch. @@ -7,7 +7,7 @@ # TESTPYPI_API_TOKEN — TestPyPI API token (same as PyDevices/pydisplay) # # Install from TestPyPI (wheels are platform-specific): -# pip install -i https://test.pypi.org/simple/ graphics-cmod +# pip install -i https://test.pypi.org/simple/ pygraphics-cmod name: Publish TestPyPI @@ -28,7 +28,7 @@ permissions: jobs: prepare: runs-on: ubuntu-latest - if: github.repository == 'PyDevices/graphics' + if: github.repository == 'PyDevices/pygraphics' outputs: version: ${{ steps.version.outputs.version }} steps: @@ -66,12 +66,12 @@ jobs: fi echo "version=$VERSION" >> "$GITHUB_OUTPUT" - echo "Publishing graphics-cmod release $VERSION" + echo "Publishing pygraphics-cmod release $VERSION" build-wheels: needs: prepare runs-on: ${{ matrix.os }} - if: github.repository == 'PyDevices/graphics' + if: github.repository == 'PyDevices/pygraphics' strategy: fail-fast: false matrix: @@ -96,7 +96,7 @@ jobs: build-android-wheels: needs: prepare runs-on: ubuntu-latest - if: github.repository == 'PyDevices/graphics' + if: github.repository == 'PyDevices/pygraphics' steps: - uses: actions/checkout@v4 with: @@ -127,7 +127,7 @@ jobs: publish: needs: [prepare, build-wheels, build-android-wheels] runs-on: ubuntu-latest - if: github.repository == 'PyDevices/graphics' + if: github.repository == 'PyDevices/pygraphics' steps: - uses: actions/download-artifact@v4 with: diff --git a/.gitignore b/.gitignore index e7932a6..d9561f8 100644 --- a/.gitignore +++ b/.gitignore @@ -21,5 +21,6 @@ wheelhouse/ wheels/ # Local packaging stamp written by build/publish helpers (see AGENTS.md) VERSION -docs/node_modules/ -docs/dist/ +tools/sourcey-api/node_modules/ +tools/sourcey-api/dist/ +site/ diff --git a/AGENTS.md b/AGENTS.md index 7415847..1568bc0 100644 --- a/AGENTS.md +++ b/AGENTS.md @@ -1,16 +1,16 @@ -# AGENTS.md — graphics +# AGENTS.md — pygraphics -Native and pure-Python **graphics** (`import graphics`) for MicroPython, -CircuitPython, and CPython. Prefer `graphics-cmod` on desktop/Android when -available; otherwise `pydisplay-graphics` / MIP `graphics`. +Native and pure-Python **pygraphics** (`import pygraphics`) for MicroPython, +CircuitPython, and CPython. Prefer `pygraphics-cmod` on desktop/Android when +available; otherwise `pygraphics` / MIP `pygraphics`. ## Layout - Root: `micropython.mk`, `micropython.cmake`, `circuitpython.mk`, `setup.py`, patch scripts — build glue stays here for `USER_C_MODULES` discovery - `src/` — `.c` sources and shared headers (`gfx_*.h`, `font_8x*.h`, - `graphics_qstrdefs.h`) -- `lib/graphics/` — pure-Python package (same public API as the cmod) + `pygraphics_qstrdefs.h`) +- `lib/pygraphics/` — pure-Python package (same public API as the cmod) - `tests/` — native smoke and parity scripts - `tools/` — developer benchmarks / helpers (not maintainer publish scripts) - No `.c` / `.h` at repo root @@ -23,20 +23,20 @@ python3 -m venv .venv echo 0.0.0 > VERSION .venv/bin/pip install -e . .venv/bin/python tests/test_area.py -.venv/bin/python tests/test_graphics.py +.venv/bin/python tests/test_pygraphics.py # pure Python -PYTHONPATH=lib .venv/bin/python -c "import graphics; assert graphics.implementation() == 'graphics_python'" +PYTHONPATH=lib .venv/bin/python -c "import pygraphics; assert pygraphics.implementation() == 'pygraphics_python'" ``` ## Publishing One tag `vX.Y.Z` publishes: -1. **graphics-cmod** — `publish-testpypi.yml` (cibuildwheel) -2. **pydisplay-graphics** + MIP — `publish-micropython-lib.yml` (micropython-lib + TestPyPI + gh-pages) +1. **pygraphics-cmod** — `publish-testpypi.yml` (cibuildwheel) +2. **pygraphics** + MIP — `publish-micropython-lib.yml` (micropython-lib + TestPyPI + gh-pages) -See `docs/PUBLISHING.md`. Next shared version continues the `graphics-cmod` line +See `docs/PUBLISHING.md`. Next shared version continues the `pygraphics-cmod` line (`v0.0.9` → `v0.0.10`). ## After C changes @@ -45,4 +45,4 @@ Refresh pydisplay’s committed runtimes with `../build_pydisplay_runtimes.sh` from the cmods workspace root when the usermod is linked into those interpreters. Font C headers: `python3 scripts/sync_fonts.py` (source of truth is -`lib/graphics/_font_8x*.py`). +`lib/pygraphics/_font_8x*.py`). diff --git a/README.md b/README.md index 458f786..cca4bdc 100644 --- a/README.md +++ b/README.md @@ -1,12 +1,12 @@ # graphics Native and pure-Python **graphics** for MicroPython, CircuitPython, and CPython. -Import as `graphics`. +Import as `pygraphics`. | Product | Pip / MIP | Role | |---------|-----------|------| -| **graphics-cmod** | TestPyPI `graphics-cmod` | All-C extension (prefer on desktop/Android when available) | -| **pydisplay-graphics** | TestPyPI `pydisplay-graphics`, MIP `graphics` | Pure-Python package (same public API) | +| **pygraphics-cmod** | TestPyPI `pygraphics-cmod` | All-C extension (prefer on desktop/Android when available) | +| **pygraphics** | TestPyPI `pygraphics`, MIP `pygraphics` | Pure-Python package (same public API) | One release tag `vX.Y.Z` publishes both products at that version. @@ -18,7 +18,7 @@ One release tag `vX.Y.Z` publishes both products at that version. pip install \ -i https://test.pypi.org/simple/ \ --extra-index-url https://pypi.org/simple/ \ - graphics-cmod + pygraphics-cmod ``` ### Pure Python (TestPyPI) @@ -27,26 +27,26 @@ pip install \ pip install \ -i https://test.pypi.org/simple/ \ --extra-index-url https://pypi.org/simple/ \ - pydisplay-graphics + pygraphics ``` ### MicroPython (MIP) ```python import mip -mip.install("graphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") +mip.install("pygraphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") ``` ### Quick start ```python -import graphics -from graphics import FrameBuffer, RGB565 +import pygraphics +from pygraphics import FrameBuffer, RGB565 fb = FrameBuffer(bytearray(160 * 128 * 2), 160, 128, RGB565) fb.fill(0) fb.fill_rect(10, 10, 40, 40, 0xF800) -print(graphics.implementation()) # native_cmod or graphics_python +print(pygraphics.implementation()) # native_cmod or pygraphics_python ``` ## What you get @@ -58,9 +58,9 @@ print(graphics.implementation()) # native_cmod or graphics_python ## Links -- [Source-linked API reference](https://pydevices.github.io/graphics/api/) -- [Source](https://github.com/PyDevices/graphics) -- [Issues](https://github.com/PyDevices/graphics/issues) +- [Source-linked API reference](https://pydevices.github.io/pygraphics/api/) +- [Source](https://github.com/PyDevices/pygraphics) +- [Issues](https://github.com/PyDevices/pygraphics/issues) - Related: [pydisplay](https://github.com/PyDevices/pydisplay) ## License @@ -77,7 +77,7 @@ MIT (framebuf algorithms derived from MicroPython `extmod/modframebuf.c`, Damien graphics/ micropython.mk / micropython.cmake / circuitpython.mk / setup.py src/ # C sources + headers (gfx_*.h, font_8x*.h, qstrs) - lib/graphics/ # pure-Python package (import graphics) + lib/pygraphics/ # pure-Python package (import pygraphics) tests/ # native smoke / parity tests tools/ # developer benchmarks / helpers docs/ scripts/ web/ @@ -89,14 +89,14 @@ graphics/ python3 -m venv .venv .venv/bin/pip install -e . .venv/bin/python tests/test_area.py -.venv/bin/python tests/test_graphics.py +.venv/bin/python tests/test_pygraphics.py .venv/bin/python tests/test_subclass.py ``` ### Pure Python (no extension) ```bash -PYTHONPATH=lib python3 -c "import graphics; print(graphics.implementation())" +PYTHONPATH=lib python3 -c "import pygraphics; print(pygraphics.implementation())" ``` ### MicroPython @@ -121,6 +121,6 @@ cd ../../.. ### pydisplay integration -When this cmod is installed or linked, `graphics.framebuf_backend()` reports -`native` and `graphics.implementation()` reports `native_cmod`. Otherwise the -pure-Python package reports `graphics_python`. +When this cmod is installed or linked, `pygraphics.framebuf_backend()` reports +`native` and `pygraphics.implementation()` reports `native_cmod`. Otherwise the +pure-Python package reports `pygraphics_python`. diff --git a/apply_cp_unix_graphics_patches.sh b/apply_cp_unix_pygraphics_patches.sh similarity index 62% rename from apply_cp_unix_graphics_patches.sh rename to apply_cp_unix_pygraphics_patches.sh index 6c3213c..db81cf8 100755 --- a/apply_cp_unix_graphics_patches.sh +++ b/apply_cp_unix_pygraphics_patches.sh @@ -2,18 +2,18 @@ # Apply CircuitPython graphics integration (unix/coverage by default). set -euo pipefail -GRAPHICS_MOD_DIR=$(cd "$(dirname "$0")" && pwd) -WORKSPACE_DIR="${WORKSPACE_DIR:-$(cd "$GRAPHICS_MOD_DIR/.." && pwd)}" +PYGRAPHICS_MOD_DIR=$(cd "$(dirname "$0")" && pwd) +WORKSPACE_DIR="${WORKSPACE_DIR:-$(cd "$PYGRAPHICS_MOD_DIR/.." && pwd)}" CP_DIR="${CP_DIR:-$WORKSPACE_DIR/circuitpython}" PORT="${PORT:-unix}" VARIANT="${VARIANT:-coverage}" -SPIKE_DIR="$GRAPHICS_MOD_DIR/src/circuitpython_spike" +SPIKE_DIR="$PYGRAPHICS_MOD_DIR/src/circuitpython_spike" [[ -d "$CP_DIR/.git" ]] || { echo "CircuitPython not found: $CP_DIR" >&2; exit 1; } insert_after_line() { local file="$1" needle="$2" block="$3" - if grep -qF "$needle" "$file" && ! grep -qF "graphics-cmod" "$file" 2>/dev/null; then + if grep -qF "$needle" "$file" && ! grep -qF "pygraphics-cmod" "$file" 2>/dev/null; then : fi if grep -qF "$(printf '%s' "$block" | head -1)" "$file" 2>/dev/null; then @@ -39,7 +39,7 @@ PY insert_raw_after_line() { local file="$1" needle="$2" raw="$3" - if grep -qF "shared-bindings/graphics/__init__.c" "$file" 2>/dev/null || grep -qF $'\tgraphics/__init__.c \\' "$file" 2>/dev/null; then + if grep -qF "shared-bindings/pygraphics/__init__.c" "$file" 2>/dev/null || grep -qF $'\tgraphics/__init__.c \\' "$file" 2>/dev/null; then return 0 fi python3 - "$file" "$needle" "$raw" <<'PY' @@ -74,56 +74,56 @@ MPCONFIG_MK="$CP_DIR/py/circuitpy_mpconfig.mk" DEFNS_MK="$CP_DIR/py/circuitpy_defns.mk" # Drop obsolete graphics_native spike stubs. -rm -rf "$CP_DIR/shared-bindings/graphics_native" "$CP_DIR/shared-module/graphics_native" +rm -rf "$CP_DIR/shared-bindings/pygraphics_native" "$CP_DIR/shared-module/pygraphics_native" copy_spike -if ! grep -q "graphics-cmod" "$VARIANT_MK" 2>/dev/null; then +if ! grep -q "pygraphics-cmod" "$VARIANT_MK" 2>/dev/null; then if grep -q "graphics_native-cmod" "$VARIANT_MK" 2>/dev/null; then sed -i '/# >>> graphics_native-cmod begin/,/# >>> graphics_native-cmod end/d' "$VARIANT_MK" fi cat >> "$VARIANT_MK" <>> graphics-cmod begin -CIRCUITPY_GRAPHICS = 1 -CFLAGS += -DCIRCUITPY_GRAPHICS=1 -GRAPHICS_MOD_DIR := \$(abspath ../../../graphics) -include \$(GRAPHICS_MOD_DIR)/circuitpython.mk -# >>> graphics-cmod end +# >>> pygraphics-cmod begin +CIRCUITPY_PYGRAPHICS = 1 +CFLAGS += -DCIRCUITPY_PYGRAPHICS=1 +PYGRAPHICS_MOD_DIR := \$(abspath ../../../pygraphics) +include \$(PYGRAPHICS_MOD_DIR)/circuitpython.mk +# >>> pygraphics-cmod end EOF -elif ! grep -q "CIRCUITPY_GRAPHICS = 1" "$VARIANT_MK" 2>/dev/null; then - sed -i '/# >>> graphics-cmod begin/a CIRCUITPY_GRAPHICS = 1\nCFLAGS += -DCIRCUITPY_GRAPHICS=1' "$VARIANT_MK" +elif ! grep -q "CIRCUITPY_PYGRAPHICS = 1" "$VARIANT_MK" 2>/dev/null; then + sed -i '/# >>> pygraphics-cmod begin/a CIRCUITPY_PYGRAPHICS = 1\nCFLAGS += -DCIRCUITPY_PYGRAPHICS=1' "$VARIANT_MK" fi -insert_raw_after_line "$VARIANT_MK" $'shared-bindings/lvgl/__init__.c \\' $'\tshared-bindings/graphics/__init__.c \\' -insert_raw_after_line "$VARIANT_MK" $'shared-module/lvgl/__init__.c \\' $'\tshared-module/graphics/__init__.c \\' +insert_raw_after_line "$VARIANT_MK" $'shared-bindings/lvgl/__init__.c \\' $'\tshared-bindings/pygraphics/__init__.c \\' +insert_raw_after_line "$VARIANT_MK" $'shared-module/lvgl/__init__.c \\' $'\tshared-module/pygraphics/__init__.c \\' -if ! grep -q "graphics-cmod" "$PORT_MK" 2>/dev/null; then +if ! grep -q "pygraphics-cmod" "$PORT_MK" 2>/dev/null; then if grep -q "graphics_native-cmod" "$PORT_MK" 2>/dev/null; then sed -i '/# >>> graphics_native-cmod begin/,/# >>> graphics_native-cmod end/d' "$PORT_MK" fi cat >> "$PORT_MK" <<'EOF' -# >>> graphics-cmod begin -ifneq ($(wildcard $(abspath ../../../graphics/circuitpython.mk)),) -GRAPHICS_MOD_DIR ?= $(abspath ../../../graphics) -include $(GRAPHICS_MOD_DIR)/circuitpython.mk +# >>> pygraphics-cmod begin +ifneq ($(wildcard $(abspath ../../../pygraphics/circuitpython.mk)),) +PYGRAPHICS_MOD_DIR ?= $(abspath ../../../pygraphics) +include $(PYGRAPHICS_MOD_DIR)/circuitpython.mk endif -# >>> graphics-cmod end +# >>> pygraphics-cmod end EOF fi -if ! grep -q "CIRCUITPY_GRAPHICS ?=" "$MPCONFIG_MK" 2>/dev/null; then +if ! grep -q "CIRCUITPY_PYGRAPHICS ?=" "$MPCONFIG_MK" 2>/dev/null; then insert_after_line "$MPCONFIG_MK" "CFLAGS += -DCIRCUITPY_LOCALE=\$(CIRCUITPY_LOCALE)" $' -# >>> graphics-cmod begin -CIRCUITPY_GRAPHICS ?= 0 -CFLAGS += -DCIRCUITPY_GRAPHICS=$(CIRCUITPY_GRAPHICS) -# >>> graphics-cmod end +# >>> pygraphics-cmod begin +CIRCUITPY_PYGRAPHICS ?= 0 +CFLAGS += -DCIRCUITPY_PYGRAPHICS=$(CIRCUITPY_PYGRAPHICS) +# >>> pygraphics-cmod end ' fi -if ! grep -q "CIRCUITPY_GRAPHICS),1)" "$DEFNS_MK" 2>/dev/null; then +if ! grep -q "CIRCUITPY_PYGRAPHICS),1)" "$DEFNS_MK" 2>/dev/null; then python3 - "$DEFNS_MK" <<'PY' import sys from pathlib import Path @@ -131,14 +131,14 @@ from pathlib import Path path = Path(sys.argv[1]) text = path.read_text() block = """ -# >>> graphics-cmod begin -ifeq ($(CIRCUITPY_GRAPHICS),1) -SRC_PATTERNS += graphics/% +# >>> pygraphics-cmod begin +ifeq ($(CIRCUITPY_PYGRAPHICS),1) +SRC_PATTERNS += pygraphics/% endif -# >>> graphics-cmod end +# >>> pygraphics-cmod end """ needle = "ifeq ($(CIRCUITPY_MATH),1)" -if "CIRCUITPY_GRAPHICS),1)" in text: +if "CIRCUITPY_PYGRAPHICS),1)" in text: sys.exit(0) if needle not in text: raise SystemExit(f"needle not found in {path}") diff --git a/circuitpython.mk b/circuitpython.mk index 8c84dc0..4af34a8 100644 --- a/circuitpython.mk +++ b/circuitpython.mk @@ -1,21 +1,21 @@ -# CircuitPython build glue for graphics (unix coverage). -GRAPHICS_MOD_DIR ?= $(patsubst %/,%,$(dir $(lastword $(MAKEFILE_LIST)))) +# CircuitPython build glue for pygraphics (unix coverage). +PYGRAPHICS_MOD_DIR ?= $(patsubst %/,%,$(dir $(lastword $(MAKEFILE_LIST)))) -CFLAGS += -I$(GRAPHICS_MOD_DIR)/src -DCIRCUITPY_GRAPHICS=1 -QSTR_DEFS += $(GRAPHICS_MOD_DIR)/src/graphics_qstrdefs.h +CFLAGS += -I$(PYGRAPHICS_MOD_DIR)/src -DCIRCUITPY_PYGRAPHICS=1 +QSTR_DEFS += $(PYGRAPHICS_MOD_DIR)/src/pygraphics_qstrdefs.h GRAPHICS_SOURCES := \ - $(GRAPHICS_MOD_DIR)/src/gfx_module_mp.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_bindings_mp.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_canvas_mp.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_framebuffer.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_shapes.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_draw.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_font.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_bmp565.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_files.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_capabilities.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_area_mp.c + $(PYGRAPHICS_MOD_DIR)/src/gfx_module_mp.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_bindings_mp.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_canvas_mp.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_framebuffer.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_shapes.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_draw.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_font.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_bmp565.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_files.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_capabilities.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_area_mp.c GRAPHICS_SUPPRESS_CFLAGS := -Wno-unused-function -Wno-sign-compare $(foreach _gfx,$(GRAPHICS_SOURCES),$(eval $(BUILD)/$(_gfx:.c=.o): CFLAGS += $(GRAPHICS_SUPPRESS_CFLAGS))) diff --git a/docs/PUBLISHING.md b/docs/PUBLISHING.md index 13edcf2..ff01fdb 100644 --- a/docs/PUBLISHING.md +++ b/docs/PUBLISHING.md @@ -4,8 +4,8 @@ One annotated tag `vX.Y.Z` publishes **both** products at that version: | Product | Channel | Workflow | |---------|---------|----------| -| **graphics-cmod** | TestPyPI (platform wheels) | `publish-testpypi.yml` | -| **pydisplay-graphics** | TestPyPI (pure Python) + micropython-lib / MIP | `publish-micropython-lib.yml` | +| **pygraphics-cmod** | TestPyPI (platform wheels) | `publish-testpypi.yml` | +| **pygraphics** | TestPyPI (pure Python) + micropython-lib / MIP | `publish-micropython-lib.yml` | ## Pipeline @@ -14,11 +14,11 @@ graphics (commit on main) ./scripts/publish_release_tag.sh --push # next patch after highest v* │ ├─► publish-testpypi.yml - │ cibuildwheel → Linux + Windows + Android → graphics-cmod + │ cibuildwheel → Linux + Windows + Android → pygraphics-cmod │ └─► publish-micropython-lib.yml sync → micropython/graphics/ - hatch + twine → pydisplay-graphics + hatch + twine → pygraphics rebuild mip/PyDevices → gh-pages remove legacy micropython/pydisplay/graphics/ ``` @@ -26,7 +26,7 @@ graphics (commit on main) ## Version numbers Shared tag for **both** products. After reclaiming the historical -`pydisplay-graphics` TestPyPI line (last `0.0.24` from pydisplay), the next +`pygraphics` TestPyPI line (last `0.0.24` from pydisplay), the next release is **`v0.0.25`** (not `v0.0.11`). Later tags continue from the highest `v*` tag: @@ -40,7 +40,7 @@ release is **`v0.0.25`** (not `v0.0.11`). Later tags continue from the highest | Secret | Purpose | |--------|---------| -| `TESTPYPI_API_TOKEN` | TestPyPI upload (cmod + pydisplay-graphics) | +| `TESTPYPI_API_TOKEN` | TestPyPI upload (cmod + pygraphics) | | `MICROPYTHON_LIB_DEPLOY_TOKEN` | PAT with `contents:write` on PyDevices/micropython-lib | Grant both secrets to the **graphics** repository (org secret repository access). @@ -49,14 +49,14 @@ Grant both secrets to the **graphics** repository (org secret repository access) ```bash # native -pip install -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ graphics-cmod +pip install -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ pygraphics-cmod # pure Python -pip install -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ pydisplay-graphics +pip install -i https://test.pypi.org/simple/ --extra-index-url https://pypi.org/simple/ pygraphics ``` ```python -mip.install("graphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") +mip.install("pygraphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") ``` ## Local cmod wheel smoke @@ -65,5 +65,5 @@ mip.install("graphics", index="https://PyDevices.github.io/micropython-lib/mip/P echo "0.0.0.dev" > VERSION python3 -m venv .venv .venv/bin/pip install -e . -.venv/bin/python tests/test_graphics.py +.venv/bin/python tests/test_pygraphics.py ``` diff --git a/docs/README.md b/docs/README.md index 9512b27..f555e76 100644 --- a/docs/README.md +++ b/docs/README.md @@ -1,7 +1,7 @@ # API reference site This directory contains the reproducible Sourcey reference for the native -`graphics` module. The generator reads the CPython binding tables and public C +`pygraphics` module. The generator reads the CPython binding tables and public C headers at the checked-out commit, then emits source-linked Markdown for the Python and native integration surfaces. @@ -17,4 +17,4 @@ canonical URLs, and integration with the existing Pages deployment. Generated HTML remains untracked build output. The existing Pages workflow preserves the project homepage and publishes the -Sourcey build below `/graphics/api/` after a merge to `main`. +Sourcey build below `/pygraphics/api/` after a merge to `main`. diff --git a/lib/graphics/README.md b/lib/graphics/README.md deleted file mode 100644 index 689464c..0000000 --- a/lib/graphics/README.md +++ /dev/null @@ -1,52 +0,0 @@ -# pydisplay-graphics - -Pure-Python `graphics` package — `FrameBuffer`, `Draw`, fonts, shapes, and image -loaders. Import as `graphics`. - -> **Pip name:** `pydisplay-graphics` · **Import:** `import graphics` - -On desktop/Android when a native wheel is available, prefer -[`graphics-cmod`](https://test.pypi.org/project/graphics-cmod/) (same import -name, C implementation). Both products are published from this repo and share -the same release tag / version. - -## Install - -### CPython (TestPyPI) - -```bash -pip install \ - -i https://test.pypi.org/simple/ \ - --extra-index-url https://pypi.org/simple/ \ - pydisplay-graphics -``` - -### MicroPython (MIP) - -```python -import mip -mip.install("graphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") -``` - -## Quick start - -```python -import graphics - -fb = graphics.FrameBuffer( - bytearray(160 * 128 * 2), 160, 128, graphics.RGB565 -) -fb.fill(0) -fb.fill_rect(10, 10, 40, 40, 0xF800) -print(graphics.implementation()) # graphics_python -``` - -## Links - -- [API reference (native)](https://pydevices.github.io/graphics/api/) -- [Source](https://github.com/PyDevices/graphics) -- Related: [graphics-cmod](https://test.pypi.org/project/graphics-cmod/), [pydisplay](https://github.com/PyDevices/pydisplay) - -## License - -MIT — see [LICENSE](https://github.com/PyDevices/graphics/blob/main/LICENSE). diff --git a/lib/pygraphics/README.md b/lib/pygraphics/README.md new file mode 100644 index 0000000..d47a8b7 --- /dev/null +++ b/lib/pygraphics/README.md @@ -0,0 +1,52 @@ +# pygraphics + +Pure-Python `pygraphics` package — `FrameBuffer`, `Draw`, fonts, shapes, and image +loaders. Import as `pygraphics`. + +> **Pip name:** `pygraphics` · **Import:** `import pygraphics` + +On desktop/Android when a native wheel is available, prefer +[`pygraphics-cmod`](https://test.pypi.org/project/pygraphics-cmod/) (same import +name, C implementation). Both products are published from this repo and share +the same release tag / version. + +## Install + +### CPython (TestPyPI) + +```bash +pip install \ + -i https://test.pypi.org/simple/ \ + --extra-index-url https://pypi.org/simple/ \ + pygraphics +``` + +### MicroPython (MIP) + +```python +import mip +mip.install("pygraphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") +``` + +## Quick start + +```python +import pygraphics + +fb = pygraphics.FrameBuffer( + bytearray(160 * 128 * 2), 160, 128, pygraphics.RGB565 +) +fb.fill(0) +fb.fill_rect(10, 10, 40, 40, 0xF800) +print(pygraphics.implementation()) # pygraphics_python +``` + +## Links + +- [API reference (native)](https://pydevices.github.io/pygraphics/api/) +- [Source](https://github.com/PyDevices/pygraphics) +- Related: [pygraphics-cmod](https://test.pypi.org/project/pygraphics-cmod/), [pydisplay](https://github.com/PyDevices/pydisplay) + +## License + +MIT — see [LICENSE](https://github.com/PyDevices/pygraphics/blob/main/LICENSE). diff --git a/lib/graphics/__init__.py b/lib/pygraphics/__init__.py similarity index 84% rename from lib/graphics/__init__.py rename to lib/pygraphics/__init__.py index 7de1c44..4155a8e 100644 --- a/lib/graphics/__init__.py +++ b/lib/pygraphics/__init__.py @@ -1,5 +1,5 @@ """ -graphics — cross-platform 2D drawing for *Python. +pygraphics — cross-platform 2D drawing for *Python. Extends MicroPython's ``framebuf`` with shape helpers, fonts, image loaders, and ``Area`` bounding boxes for partial updates. On CPython and CircuitPython the @@ -7,12 +7,12 @@ Quick start:: - import graphics + import pygraphics - fb = graphics.FrameBuffer(bytearray(16 * 16 * 2), 16, 16, graphics.RGB565) + fb = pygraphics.FrameBuffer(bytearray(16 * 16 * 2), 16, 16, pygraphics.RGB565) fb.fill(0) area = fb.fill_rect(1, 1, 6, 6, 0xFFFF) - graphics.text8(fb, "Hi", 0, 0, 0xFFFF) + pygraphics.text8(fb, "Hi", 0, 0, 0xFFFF) """ from ._area import Area @@ -62,8 +62,8 @@ def implementation(): - """Return ``graphics_python`` (this package) vs ``native_cmod`` for the C module.""" - return "graphics_python" + """Return ``pygraphics_python`` (this package) vs ``native_cmod`` for the C module.""" + return "pygraphics_python" __all__ = [ diff --git a/lib/graphics/_area.py b/lib/pygraphics/_area.py similarity index 99% rename from lib/graphics/_area.py rename to lib/pygraphics/_area.py index e5a4ecd..f440bed 100644 --- a/lib/graphics/_area.py +++ b/lib/pygraphics/_area.py @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: MIT """ -`graphics._area` +`pygraphics._area` ==================================================== Area class for defining rectangular areas. """ diff --git a/lib/graphics/_blit_hooks.py b/lib/pygraphics/_blit_hooks.py similarity index 100% rename from lib/graphics/_blit_hooks.py rename to lib/pygraphics/_blit_hooks.py diff --git a/lib/graphics/_bmp565.py b/lib/pygraphics/_bmp565.py similarity index 100% rename from lib/graphics/_bmp565.py rename to lib/pygraphics/_bmp565.py diff --git a/lib/graphics/_clip.py b/lib/pygraphics/_clip.py similarity index 100% rename from lib/graphics/_clip.py rename to lib/pygraphics/_clip.py diff --git a/lib/graphics/_draw.py b/lib/pygraphics/_draw.py similarity index 98% rename from lib/graphics/_draw.py rename to lib/pygraphics/_draw.py index fc3ac9e..39989fc 100644 --- a/lib/graphics/_draw.py +++ b/lib/pygraphics/_draw.py @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: MIT """ -`graphics._draw` +`pygraphics._draw` ==================================================== Graphics Draw class """ @@ -16,7 +16,7 @@ class Draw: """ Draw shapes on a canvas (display, FrameBuffer, or compatible object). - Each method delegates to ``graphics._shapes`` and returns an ``Area`` bounding box. + Each method delegates to ``pygraphics._shapes`` and returns an ``Area`` bounding box. Args: canvas: Object with framebuf-compatible drawing methods. diff --git a/lib/graphics/_files.py b/lib/pygraphics/_files.py similarity index 100% rename from lib/graphics/_files.py rename to lib/pygraphics/_files.py diff --git a/lib/graphics/_font.py b/lib/pygraphics/_font.py similarity index 99% rename from lib/graphics/_font.py rename to lib/pygraphics/_font.py index 937165a..f4d4a35 100644 --- a/lib/graphics/_font.py +++ b/lib/pygraphics/_font.py @@ -3,7 +3,7 @@ # SPDX-License-Identifier: MIT """ -`graphics._font` +`pygraphics._font` ==================================================== A module to draw text to a canvas using fonts from diff --git a/lib/graphics/_font_8x14.py b/lib/pygraphics/_font_8x14.py similarity index 100% rename from lib/graphics/_font_8x14.py rename to lib/pygraphics/_font_8x14.py diff --git a/lib/graphics/_font_8x16.py b/lib/pygraphics/_font_8x16.py similarity index 100% rename from lib/graphics/_font_8x16.py rename to lib/pygraphics/_font_8x16.py diff --git a/lib/graphics/_font_8x8.py b/lib/pygraphics/_font_8x8.py similarity index 100% rename from lib/graphics/_font_8x8.py rename to lib/pygraphics/_font_8x8.py diff --git a/lib/graphics/_framebuf_plus.py b/lib/pygraphics/_framebuf_plus.py similarity index 99% rename from lib/graphics/_framebuf_plus.py rename to lib/pygraphics/_framebuf_plus.py index 7db6627..5d457bb 100644 --- a/lib/graphics/_framebuf_plus.py +++ b/lib/pygraphics/_framebuf_plus.py @@ -593,7 +593,7 @@ def save(self, filename=None): def export(self, filename): """Export this framebuffer as an importable ``.py`` bitmap module. - See :func:`graphics._files.export_framebuffer`. Ships ``BITMAP`` as a + See :func:`pygraphics._files.export_framebuffer`. Ships ``BITMAP`` as a ``bytearray`` for zero-copy :meth:`from_bitmap` on MicroPython. """ return _files.export_framebuffer(self, filename) diff --git a/lib/graphics/_shapes.py b/lib/pygraphics/_shapes.py similarity index 99% rename from lib/graphics/_shapes.py rename to lib/pygraphics/_shapes.py index a068803..18b1aeb 100644 --- a/lib/graphics/_shapes.py +++ b/lib/pygraphics/_shapes.py @@ -2,7 +2,7 @@ # # SPDX-License-Identifier: MIT """ -`graphics._shapes` +`pygraphics._shapes` ==================================================== Graphics primitives for drawing on a canvas. diff --git a/lib/graphics/framebuf.py b/lib/pygraphics/framebuf.py similarity index 99% rename from lib/graphics/framebuf.py rename to lib/pygraphics/framebuf.py index 3821187..7c364fc 100644 --- a/lib/graphics/framebuf.py +++ b/lib/pygraphics/framebuf.py @@ -14,10 +14,10 @@ for every drawing method; only ``pixel()`` without a color argument returns a value). - No pydisplay extensions (no ``RGB888``, no ``Area`` return values, no - ``arc``/``circle``/``blit_rect``/etc.) and no imports from ``graphics``. + ``arc``/``circle``/``blit_rect``/etc.) and no imports from ``pygraphics``. For the pydisplay-flavored subclass that adds ``Area`` bounding boxes, -``RGB888``, extra shapes, and file I/O, see ``graphics.FrameBuffer`` +``RGB888``, extra shapes, and file I/O, see ``pygraphics.FrameBuffer`` (``graphics/_framebuf_plus.py``), which subclasses this module. """ diff --git a/lib/pyproject.toml b/lib/pyproject.toml index a06d6b8..64b46aa 100644 --- a/lib/pyproject.toml +++ b/lib/pyproject.toml @@ -3,17 +3,17 @@ requires = ["hatchling"] build-backend = "hatchling.build" [project] -name = "pydisplay-graphics" +name = "pygraphics" version = "0.0.25" description = "Pure-Python graphics (FrameBuffer, Draw, fonts); import as graphics" -readme = "graphics/README.md" +readme = "pygraphics/README.md" license = "MIT" requires-python = ">=3.8" authors = [{ name = "Brad Barnett", email = "contact@pydevices.com" }] -urls = { Homepage = "https://github.com/PyDevices/graphics", Issues = "https://github.com/PyDevices/graphics/issues" } +urls = { Homepage = "https://github.com/PyDevices/pygraphics", Issues = "https://github.com/PyDevices/pygraphics/issues" } [tool.hatch.build.targets.wheel] -packages = ["graphics"] +packages = ["pygraphics"] [tool.hatch.build.targets.sdist] include = ["graphics"] diff --git a/micropython.cmake b/micropython.cmake index eb641a8..399dff4 100644 --- a/micropython.cmake +++ b/micropython.cmake @@ -1,34 +1,34 @@ -# MicroPython CMake glue for graphics (ESP32, RP2, …). +# MicroPython CMake glue for pygraphics (ESP32, RP2, …). # # Make-based ports use micropython.mk in this directory. CMake-based ports # (esp32, rp2, …) discover this file via USER_C_MODULES / an aggregator # micropython.cmake that includes sibling modules. # # Point USER_C_MODULES at this repo (or this file) directly, e.g.: -# idf.py build -DUSER_C_MODULES= +# idf.py build -DUSER_C_MODULES= # Or a semicolon-separated list with other modules (no aggregator required): -# -DUSER_C_MODULES=";" +# -DUSER_C_MODULES=";" -set(GRAPHICS_MOD_DIR ${CMAKE_CURRENT_LIST_DIR}) +set(PYGRAPHICS_MOD_DIR ${CMAKE_CURRENT_LIST_DIR}) -add_library(graphics INTERFACE) +add_library(pygraphics INTERFACE) -target_sources(graphics INTERFACE - ${GRAPHICS_MOD_DIR}/src/gfx_module_mp.c - ${GRAPHICS_MOD_DIR}/src/gfx_bindings_mp.c - ${GRAPHICS_MOD_DIR}/src/gfx_canvas_mp.c - ${GRAPHICS_MOD_DIR}/src/gfx_framebuffer.c - ${GRAPHICS_MOD_DIR}/src/gfx_shapes.c - ${GRAPHICS_MOD_DIR}/src/gfx_draw.c - ${GRAPHICS_MOD_DIR}/src/gfx_font.c - ${GRAPHICS_MOD_DIR}/src/gfx_bmp565.c - ${GRAPHICS_MOD_DIR}/src/gfx_files.c - ${GRAPHICS_MOD_DIR}/src/gfx_capabilities.c - ${GRAPHICS_MOD_DIR}/src/gfx_area_mp.c +target_sources(pygraphics INTERFACE + ${PYGRAPHICS_MOD_DIR}/src/gfx_module_mp.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_bindings_mp.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_canvas_mp.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_framebuffer.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_shapes.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_draw.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_font.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_bmp565.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_files.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_capabilities.c + ${PYGRAPHICS_MOD_DIR}/src/gfx_area_mp.c ) -target_include_directories(graphics INTERFACE ${GRAPHICS_MOD_DIR}/src) -target_compile_options(graphics INTERFACE +target_include_directories(pygraphics INTERFACE ${PYGRAPHICS_MOD_DIR}/src) +target_compile_options(pygraphics INTERFACE -Wno-unused-function -Wno-sign-compare -Wno-unused-const-variable @@ -36,7 +36,7 @@ target_compile_options(graphics INTERFACE # libm: required on some desktop ports; ESP-IDF already links libm into the app. if(NOT ESP_PLATFORM) - target_link_libraries(graphics INTERFACE m) + target_link_libraries(pygraphics INTERFACE m) endif() -target_link_libraries(usermod INTERFACE graphics) +target_link_libraries(usermod INTERFACE pygraphics) diff --git a/micropython.mk b/micropython.mk index 869fe86..d13f04d 100644 --- a/micropython.mk +++ b/micropython.mk @@ -1,11 +1,11 @@ -# MicroPython user C module glue for graphics. +# MicroPython user C module glue for pygraphics. # # Discovered via USER_C_MODULES pointing at the workspace directory that # contains this repo (its parent), e.g. `make USER_C_MODULES=../../..`. -GRAPHICS_MOD_DIR := $(USERMOD_DIR) +PYGRAPHICS_MOD_DIR := $(USERMOD_DIR) -CFLAGS_USERMOD += -I$(GRAPHICS_MOD_DIR)/src -Wno-unused-function -Wno-sign-compare -Wno-unused-const-variable +CFLAGS_USERMOD += -I$(PYGRAPHICS_MOD_DIR)/src -Wno-unused-function -Wno-sign-compare -Wno-unused-const-variable # math: cosf/sinf etc. # - mimxrt/samd: bare `ld` — absolute libm.a in LDFLAGS # - stm32: CROSS_COMPILE is set *after* py.mk, so $(CC) here is the host @@ -20,14 +20,14 @@ LDFLAGS_USERMOD += -lm endif SRC_USERMOD_C += \ - $(GRAPHICS_MOD_DIR)/src/gfx_module_mp.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_bindings_mp.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_canvas_mp.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_framebuffer.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_shapes.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_draw.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_font.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_bmp565.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_files.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_capabilities.c \ - $(GRAPHICS_MOD_DIR)/src/gfx_area_mp.c + $(PYGRAPHICS_MOD_DIR)/src/gfx_module_mp.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_bindings_mp.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_canvas_mp.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_framebuffer.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_shapes.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_draw.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_font.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_bmp565.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_files.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_capabilities.c \ + $(PYGRAPHICS_MOD_DIR)/src/gfx_area_mp.c diff --git a/pyproject.toml b/pyproject.toml index 6325f9c..78fdcc4 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -3,13 +3,13 @@ requires = ["setuptools>=61"] build-backend = "setuptools.build_meta" [project] -name = "graphics-cmod" +name = "pygraphics-cmod" dynamic = ["version"] description = "Native graphics cmod for CPython (FrameBuffer, Area); import as graphics" readme = "README.md" license = "MIT" requires-python = ">=3.10" -urls = { Homepage = "https://github.com/PyDevices/graphics", Issues = "https://github.com/PyDevices/graphics/issues" } +urls = { Homepage = "https://github.com/PyDevices/pygraphics", Issues = "https://github.com/PyDevices/pygraphics/issues" } [tool.setuptools] packages = [] @@ -21,7 +21,7 @@ version = { file = "VERSION" } [tool.cibuildwheel] build = "cp310-* cp311-* cp312-* cp313-* cp314-*" skip = "*musllinux* *-macosx_* *-win32" -test-command = "python -c \"import graphics; from graphics import FrameBuffer, RGB565, framebuf_backend; assert framebuf_backend() == 'native'\"" +test-command = "python -c \"import pygraphics; from pygraphics import FrameBuffer, RGB565, framebuf_backend; assert framebuf_backend() == 'native'\"" [tool.cibuildwheel.linux] archs = ["x86_64"] @@ -33,7 +33,7 @@ archs = ["AMD64"] [tool.cibuildwheel.android] archs = ["arm64_v8a", "x86_64"] environment = { ANDROID_API_LEVEL = "21" } -test-command = "python -c \"import graphics; assert graphics.framebuf_backend() == 'native'\"" +test-command = "python -c \"import pygraphics; assert pygraphics.framebuf_backend() == 'native'\"" test-skip = "*" [[tool.cibuildwheel.overrides]] diff --git a/scripts/publish_make_pyproject.py b/scripts/publish_make_pyproject.py index cb93ecd..eccae70 100755 --- a/scripts/publish_make_pyproject.py +++ b/scripts/publish_make_pyproject.py @@ -46,9 +46,9 @@ DEFAULT_AUTHOR = "micropython-lib " DEFAULT_LICENSE = "MIT" -HOME_PAGE = "https://github.com/PyDevices/graphics" -DOCS_PAGE = "https://pydevices.github.io/graphics" -ISSUES_PAGE = "https://github.com/PyDevices/graphics/issues" +HOME_PAGE = "https://github.com/PyDevices/pygraphics" +DOCS_PAGE = "https://pydevices.github.io/pygraphics" +ISSUES_PAGE = "https://github.com/PyDevices/pygraphics/issues" TESTPYPI = "https://test.pypi.org/simple/" diff --git a/scripts/publish_micropython_lib.sh b/scripts/publish_micropython_lib.sh index 7c4456f..39481f6 100755 --- a/scripts/publish_micropython_lib.sh +++ b/scripts/publish_micropython_lib.sh @@ -1,8 +1,8 @@ #!/usr/bin/env bash -# Sync graphics into PyDevices/micropython-lib, build TestPyPI wheels, push MIP index. +# Sync pygraphics into PyDevices/micropython-lib, build TestPyPI wheels, push MIP index. # # CI: MICROPYTHON_LIB_DIR=../micropython-lib ./scripts/publish_micropython_lib.sh --push -# MIP: mip.install("graphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") +# MIP: mip.install("pygraphics", index="https://PyDevices.github.io/micropython-lib/mip/PyDevices") set -euo pipefail @@ -16,7 +16,7 @@ usage() { cat <<'EOF' Usage: ./scripts/publish_micropython_lib.sh [OPTION] -Copy graphics lib/ into micropython-lib, optionally upload TestPyPI wheels, +Copy pygraphics lib/ into micropython-lib, optionally upload TestPyPI wheels, then commit (and optionally push) on the PyDevices branch. Options: @@ -83,15 +83,15 @@ resolve_version() { VERSION="$(resolve_version)" || exit 1 echo "Release version: $VERSION" -DESCRIPTION_PREFIX="graphics" +DESCRIPTION_PREFIX="pygraphics" AUTHOR="Brad Barnett " LICENSE="MIT" -BASENAME=graphics -PYPI_NAME=pydisplay-graphics +BASENAME=pygraphics +PYPI_NAME=pygraphics DEST_REPO="${MICROPYTHON_LIB_DIR:-$SOURCE_REPO/../micropython-lib}" DEST_REPO="$(cd "$DEST_REPO" 2>/dev/null && pwd || echo "$DEST_REPO")" export MICROPYTHON_LIB_DIR="$DEST_REPO" -SOURCE_DIR=$SOURCE_REPO/lib/graphics +SOURCE_DIR=$SOURCE_REPO/lib/pygraphics DEST_DIR=$DEST_REPO/micropython/$BASENAME PYPI_DIR=$SOURCE_REPO/wheels README_FULL_PATH=$SOURCE_REPO/README.md @@ -152,7 +152,7 @@ rsync -a --delete "${RSYNC_EXCLUDES[@]}" "$SOURCE_DIR/" "$DEST_DIR/$BASENAME/" cat < "$DEST_DIR/manifest.py" metadata( - description="Pure-Python graphics for MicroPython/CircuitPython/CPython (FrameBuffer, Draw, fonts); import as graphics", + description="Pure-Python pygraphics for MicroPython/CircuitPython/CPython (FrameBuffer, Draw, fonts); import as pygraphics", version="$VERSION", author="$AUTHOR", license="$LICENSE", @@ -163,6 +163,7 @@ EOF # Retire the legacy pydisplay/graphics tree after extraction. LEGACY_DIR="$DEST_REPO/micropython/pydisplay/graphics" +LEGACY_DIR2="$DEST_REPO/micropython/graphics" if [[ -d "$LEGACY_DIR" ]]; then rm -rf "$LEGACY_DIR" fi diff --git a/scripts/publish_mip_ghpages.sh b/scripts/publish_mip_ghpages.sh index a63ca0b..ae0a740 100755 --- a/scripts/publish_mip_ghpages.sh +++ b/scripts/publish_mip_ghpages.sh @@ -17,7 +17,7 @@ set -euo pipefail ROOT="$(cd "$(dirname "${BASH_SOURCE[0]}")/.." && pwd)" -GRAPHICS_DIR="${GRAPHICS_DIR:-$ROOT}" +PYGRAPHICS_DIR="${PYGRAPHICS_DIR:-$ROOT}" LIB_DIR="${MICROPYTHON_LIB_DIR:?set MICROPYTHON_LIB_DIR}" MPY_DIR="${MICROPYTHON_DIR:-/tmp/micropython}" INDEX_OUT="${MIP_INDEX_OUTPUT:-/tmp/mip-index}" @@ -37,7 +37,7 @@ rm -rf "$INDEX_OUT" mkdir -p "$INDEX_OUT" echo "Compiling MIP index from $LIB_DIR -> $INDEX_OUT" -python3 "$GRAPHICS_DIR/scripts/build.py" \ +python3 "$PYGRAPHICS_DIR/scripts/build.py" \ --lib-dir "$LIB_DIR" \ --micropython "$MPY_DIR" \ --mpy-cross "$MPY_CROSS" \ @@ -74,7 +74,7 @@ git diff --staged --quiet && { echo "No MIP index changes to publish" exit 0 } -git commit -m "graphics: Update mip/$MIP_SUBDIR from PyDevices/graphics ${SHA}." +git commit -m "pygraphics: Update mip/$MIP_SUBDIR from PyDevices/pygraphics ${SHA}." if [[ "$NEW_BRANCH" -eq 0 ]]; then git pull --rebase origin gh-pages diff --git a/scripts/sync_fonts.py b/scripts/sync_fonts.py index 890e35b..ee376c9 100644 --- a/scripts/sync_fonts.py +++ b/scripts/sync_fonts.py @@ -1,6 +1,6 @@ #!/usr/bin/env python3 # SPDX-License-Identifier: MIT -"""Generate C font headers from ``lib/graphics/_font_8x*.py`` romfont data. +"""Generate C font headers from ``lib/pygraphics/_font_8x*.py`` romfont data. Canonical font bytes live in the pure-Python package; this script writes ``font_8x8.h``, ``font_8x14.h``, and ``font_8x16.h`` under ``src/``. @@ -18,9 +18,9 @@ import re import sys -_GRAPHICS_DIR = Path(__file__).resolve().parents[1] -_INCLUDE_DIR = _GRAPHICS_DIR / "src" -_LIB_GRAPHICS = _GRAPHICS_DIR / "lib" / "graphics" +_PYGRAPHICS_DIR = Path(__file__).resolve().parents[1] +_INCLUDE_DIR = _PYGRAPHICS_DIR / "src" +_LIB_GRAPHICS = _PYGRAPHICS_DIR / "lib" / "pygraphics" def _load_font_bytes(py_path: Path) -> bytes: @@ -53,7 +53,7 @@ def _render_header(name: str, array_name: str, data: bytes, height: int) -> str: #define {guard} #include -/* romfont from lib/graphics/_font_{name.lower()}.py ({height}px, 256 glyphs) */ +/* romfont from lib/pygraphics/_font_{name.lower()}.py ({height}px, 256 glyphs) */ static const uint8_t {array_name}[] = {{ {_format_c_array(data)} }}; diff --git a/setup.py b/setup.py index a861cce..04118dd 100644 --- a/setup.py +++ b/setup.py @@ -1,5 +1,5 @@ # SPDX-License-Identifier: MIT -"""Build native graphics C extension.""" +"""Build native pygraphics C extension.""" import os import sys @@ -30,12 +30,12 @@ ] setup( - name="graphics-cmod", + name="pygraphics-cmod", packages=[], py_modules=[], ext_modules=[ Extension( - "graphics", + "pygraphics", sources=GFX_SOURCES, include_dirs=[os.path.join(ROOT, "src")], extra_compile_args=extra_compile_args, diff --git a/src/circuitpython_spike/copy_manifest.txt b/src/circuitpython_spike/copy_manifest.txt index 5f87814..d30548f 100644 --- a/src/circuitpython_spike/copy_manifest.txt +++ b/src/circuitpython_spike/copy_manifest.txt @@ -1,4 +1,4 @@ -shared-bindings/graphics __init__.c -shared-bindings/graphics __init__.h -shared-module/graphics __init__.c -shared-module/graphics __init__.h +shared-bindings/pygraphics __init__.c +shared-bindings/pygraphics __init__.h +shared-module/pygraphics __init__.c +shared-module/pygraphics __init__.h diff --git a/src/circuitpython_spike/shared-bindings/graphics/__init__.c b/src/circuitpython_spike/shared-bindings/graphics/__init__.c deleted file mode 100644 index ae29e1a..0000000 --- a/src/circuitpython_spike/shared-bindings/graphics/__init__.c +++ /dev/null @@ -1,8 +0,0 @@ -// CircuitPython shared-bindings registration for graphics. -#include "shared-bindings/graphics/__init__.h" -#include "py/obj.h" -#include "py/runtime.h" - -extern const mp_obj_module_t mp_module_graphics; - -MP_REGISTER_MODULE(MP_QSTR_graphics, mp_module_graphics); diff --git a/src/circuitpython_spike/shared-bindings/pygraphics/__init__.c b/src/circuitpython_spike/shared-bindings/pygraphics/__init__.c new file mode 100644 index 0000000..b082425 --- /dev/null +++ b/src/circuitpython_spike/shared-bindings/pygraphics/__init__.c @@ -0,0 +1,8 @@ +// CircuitPython shared-bindings registration for pygraphics. +#include "shared-bindings/pygraphics/__init__.h" +#include "py/obj.h" +#include "py/runtime.h" + +extern const mp_obj_module_t mp_module_pygraphics; + +MP_REGISTER_MODULE(MP_QSTR_pygraphics, mp_module_pygraphics); diff --git a/src/circuitpython_spike/shared-bindings/graphics/__init__.h b/src/circuitpython_spike/shared-bindings/pygraphics/__init__.h similarity index 52% rename from src/circuitpython_spike/shared-bindings/graphics/__init__.h rename to src/circuitpython_spike/shared-bindings/pygraphics/__init__.h index f8e3dd7..76320ff 100644 --- a/src/circuitpython_spike/shared-bindings/graphics/__init__.h +++ b/src/circuitpython_spike/shared-bindings/pygraphics/__init__.h @@ -1,9 +1,9 @@ -// CircuitPython shared-bindings header for graphics. +// CircuitPython shared-bindings header for pygraphics. #ifndef SHARED_BINDINGS_GRAPHICS___INIT___H #define SHARED_BINDINGS_GRAPHICS___INIT___H #include "py/obj.h" -extern const mp_obj_module_t mp_module_graphics; +extern const mp_obj_module_t mp_module_pygraphics; #endif diff --git a/src/circuitpython_spike/shared-module/graphics/__init__.c b/src/circuitpython_spike/shared-module/graphics/__init__.c deleted file mode 100644 index a39a5b3..0000000 --- a/src/circuitpython_spike/shared-module/graphics/__init__.c +++ /dev/null @@ -1,3 +0,0 @@ -// CircuitPython shared-module stub for graphics. -// Module object is defined in gfx_bindings_mp.c (graphics cmod). -#include "shared-module/graphics/__init__.h" diff --git a/src/circuitpython_spike/shared-module/pygraphics/__init__.c b/src/circuitpython_spike/shared-module/pygraphics/__init__.c new file mode 100644 index 0000000..c68c876 --- /dev/null +++ b/src/circuitpython_spike/shared-module/pygraphics/__init__.c @@ -0,0 +1,3 @@ +// CircuitPython shared-module stub for pygraphics. +// Module object is defined in gfx_bindings_mp.c (graphics cmod). +#include "shared-module/pygraphics/__init__.h" diff --git a/src/circuitpython_spike/shared-module/graphics/__init__.h b/src/circuitpython_spike/shared-module/pygraphics/__init__.h similarity index 63% rename from src/circuitpython_spike/shared-module/graphics/__init__.h rename to src/circuitpython_spike/shared-module/pygraphics/__init__.h index 3d6b857..a99b095 100644 --- a/src/circuitpython_spike/shared-module/graphics/__init__.h +++ b/src/circuitpython_spike/shared-module/pygraphics/__init__.h @@ -1,4 +1,4 @@ -// CircuitPython shared-module header for graphics. +// CircuitPython shared-module header for pygraphics. #ifndef SHARED_MODULE_GRAPHICS___INIT___H #define SHARED_MODULE_GRAPHICS___INIT___H diff --git a/src/font_8x14.h b/src/font_8x14.h index 7e64ed2..7d24878 100644 --- a/src/font_8x14.h +++ b/src/font_8x14.h @@ -2,7 +2,7 @@ #define FONT_8X14_H #include -/* romfont from pydisplay src/lib/graphics/_font_8x14.py (14px, 256 glyphs) */ +/* romfont from pydisplay src/lib/pygraphics/_font_8x14.py (14px, 256 glyphs) */ static const uint8_t font_8x14[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x81, 0xa5, 0x81, 0x81, 0xbd, 0x99, 0x81, 0x7e, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0xff, diff --git a/src/font_8x16.h b/src/font_8x16.h index d0fc9c2..6705fa6 100644 --- a/src/font_8x16.h +++ b/src/font_8x16.h @@ -2,7 +2,7 @@ #define FONT_8X16_H #include -/* romfont from pydisplay src/lib/graphics/_font_8x16.py (16px, 256 glyphs) */ +/* romfont from pydisplay src/lib/pygraphics/_font_8x16.py (16px, 256 glyphs) */ static const uint8_t font_8x16[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x81, 0xa5, 0x81, 0x81, 0xbd, 0x99, 0x81, 0x81, 0x7e, 0x00, 0x00, 0x00, 0x00, diff --git a/src/font_8x8.h b/src/font_8x8.h index 6675337..e93fb0b 100644 --- a/src/font_8x8.h +++ b/src/font_8x8.h @@ -2,7 +2,7 @@ #define FONT_8X8_H #include -/* romfont from pydisplay src/lib/graphics/_font_8x8.py (8px, 256 glyphs) */ +/* romfont from pydisplay src/lib/pygraphics/_font_8x8.py (8px, 256 glyphs) */ static const uint8_t font_8x8[] = { 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x00, 0x7e, 0x81, 0xa5, 0x81, 0xbd, 0x99, 0x81, 0x7e, 0x7e, 0xff, 0xdb, 0xff, 0xc3, 0xe7, 0xff, 0x7e, 0x6c, 0xfe, 0xfe, 0xfe, 0x7c, 0x38, 0x10, 0x00, diff --git a/src/gfx_bindings_mp.c b/src/gfx_bindings_mp.c index b634f5e..f55fb4c 100644 --- a/src/gfx_bindings_mp.c +++ b/src/gfx_bindings_mp.c @@ -503,7 +503,7 @@ static mp_obj_t draw_text16(size_t n_args, const mp_obj_t *args, mp_map_t *kw_ar } static MP_DEFINE_CONST_FUN_OBJ_KW(draw_text16_obj, 4, draw_text16); -/* ClipContext: with draw.clip(x,y,w,h) / draw.clip(Area) — matches graphics._clip */ +/* ClipContext: with draw.clip(x,y,w,h) / draw.clip(Area) — matches pygraphics._clip */ typedef struct _mp_obj_clip_ctx_t { mp_obj_base_t base; mp_obj_t draw_obj; @@ -582,7 +582,7 @@ static mp_obj_t draw_clip(size_t n_args, const mp_obj_t *args) { } static MP_DEFINE_CONST_FUN_OBJ_VAR_BETWEEN(draw_clip_obj, 2, 5, draw_clip); -/* ClippedCanvas: proxy that restricts drawing to a clip Area — matches graphics._clip */ +/* ClippedCanvas: proxy that restricts drawing to a clip Area — matches pygraphics._clip */ typedef struct _mp_obj_clipped_canvas_t { mp_obj_base_t base; mp_obj_t canvas_obj; @@ -1714,7 +1714,7 @@ static mp_obj_t mod_text_height(size_t n_args, const mp_obj_t *args, mp_map_t *k { MP_QSTR_, MP_ARG_REQUIRED | MP_ARG_INT, {.u_int = 0} }, { MP_QSTR_, MP_ARG_REQUIRED | MP_ARG_INT, {.u_int = 0} }, { MP_QSTR_c, MP_ARG_INT, {.u_int = 1} }, - /* Positional scale/inverted/font_data match Python graphics.textN */ + /* Positional scale/inverted/font_data match Python pygraphics.textN */ { MP_QSTR_scale, MP_ARG_INT, {.u_int = 1} }, { MP_QSTR_inverted, MP_ARG_BOOL, {.u_bool = false} }, { MP_QSTR_font_data, MP_ARG_OBJ, {.u_obj = mp_const_none} }, @@ -1765,7 +1765,7 @@ static mp_obj_t mod_text(size_t n_args, const mp_obj_t *args, mp_map_t *kw_args) { MP_QSTR_, MP_ARG_REQUIRED | MP_ARG_INT, {.u_int = 0} }, { MP_QSTR_, MP_ARG_REQUIRED | MP_ARG_INT, {.u_int = 0} }, { MP_QSTR_c, MP_ARG_INT, {.u_int = 1} }, - /* Positional optional args match Python graphics.text */ + /* Positional optional args match Python pygraphics.text */ { MP_QSTR_scale, MP_ARG_INT, {.u_int = 1} }, { MP_QSTR_inverted, MP_ARG_BOOL, {.u_bool = false} }, { MP_QSTR_font_data, MP_ARG_OBJ, {.u_obj = mp_const_none} }, @@ -1853,7 +1853,7 @@ static mp_obj_t mod_capabilities(void) { MP_DEFINE_CONST_FUN_OBJ_0(mod_capabilities_obj, mod_capabilities); static const mp_rom_map_elem_t graphics_module_globals_table[] = { - { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_graphics) }, + { MP_ROM_QSTR(MP_QSTR___name__), MP_ROM_QSTR(MP_QSTR_pygraphics) }, { MP_ROM_QSTR(MP_QSTR_FrameBuffer), MP_ROM_PTR(&mp_type_framebuf) }, { MP_ROM_QSTR(MP_QSTR_Area), MP_ROM_PTR(&mp_type_area) }, { MP_ROM_QSTR(MP_QSTR_Draw), MP_ROM_PTR(&mp_type_draw) }, @@ -1905,11 +1905,11 @@ static const mp_rom_map_elem_t graphics_module_globals_table[] = { MP_DEFINE_CONST_DICT(graphics_module_globals, graphics_module_globals_table); -const mp_obj_module_t mp_module_graphics = { +const mp_obj_module_t mp_module_pygraphics = { .base = { &mp_type_module }, .globals = (mp_obj_dict_t *)&graphics_module_globals, }; #if !CIRCUITPY -MP_REGISTER_MODULE(MP_QSTR_graphics, mp_module_graphics); +MP_REGISTER_MODULE(MP_QSTR_pygraphics, mp_module_pygraphics); #endif diff --git a/src/gfx_module_cpy.c b/src/gfx_module_cpy.c index f6de0a2..4b352fe 100644 --- a/src/gfx_module_cpy.c +++ b/src/gfx_module_cpy.c @@ -3,7 +3,7 @@ * * Full-parity binding surface matching the MicroPython/CircuitPython bindings * (gfx_module_mp.c / gfx_bindings_mp.c) and the pure-Python reference under - * pydisplay src/lib/graphics. All shape/text/blit primitives share the same C + * pydisplay src/lib/pygraphics. All shape/text/blit primitives share the same C * core (gfx_shapes/gfx_font/gfx_files/gfx_bmp565) as the MP bindings. * * SPDX-License-Identifier: MIT @@ -392,7 +392,7 @@ static PyNumberMethods area_as_number = { static PyTypeObject GfxAreaType = { PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "graphics.Area", + .tp_name = "pygraphics.Area", .tp_basicsize = sizeof(GfxAreaObject), .tp_dealloc = (destructor)area_dealloc, .tp_repr = (reprfunc)area_repr, @@ -1109,7 +1109,7 @@ static PyMethodDef framebuffer_methods[] = { static PyTypeObject GfxFrameBufferType = { PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "graphics.FrameBuffer", + .tp_name = "pygraphics.FrameBuffer", .tp_basicsize = sizeof(GfxFrameBufferObject), .tp_dealloc = (destructor)framebuffer_dealloc, .tp_flags = Py_TPFLAGS_DEFAULT | Py_TPFLAGS_BASETYPE, @@ -2082,7 +2082,7 @@ static PyMethodDef draw_methods[] = { static PyTypeObject GfxDrawType = { PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "graphics.Draw", + .tp_name = "pygraphics.Draw", .tp_basicsize = sizeof(GfxDrawObject), .tp_dealloc = (destructor)draw_dealloc, .tp_flags = Py_TPFLAGS_DEFAULT, @@ -2144,7 +2144,7 @@ static PyMethodDef clipctx_methods[] = { static PyTypeObject GfxClipCtxType = { PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "graphics.ClipContext", + .tp_name = "pygraphics.ClipContext", .tp_basicsize = sizeof(GfxClipCtxObject), .tp_dealloc = (destructor)clipctx_dealloc, .tp_flags = Py_TPFLAGS_DEFAULT, @@ -2152,7 +2152,7 @@ static PyTypeObject GfxClipCtxType = { .tp_new = clipctx_new, }; -/* ClippedCanvas — matches graphics._clip.ClippedCanvas */ +/* ClippedCanvas — matches pygraphics._clip.ClippedCanvas */ typedef struct { PyObject_HEAD PyObject *canvas_obj; @@ -2411,7 +2411,7 @@ static PyMethodDef clipped_canvas_methods[] = { static PyTypeObject GfxClippedCanvasType = { PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "graphics.ClippedCanvas", + .tp_name = "pygraphics.ClippedCanvas", .tp_basicsize = sizeof(GfxClippedCanvasObject), .tp_dealloc = (destructor)clipped_canvas_dealloc, .tp_flags = Py_TPFLAGS_DEFAULT, @@ -2640,7 +2640,7 @@ static PyMethodDef font_methods[] = { static PyTypeObject GfxFontType = { PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "graphics.Font", + .tp_name = "pygraphics.Font", .tp_basicsize = sizeof(GfxFontObject), .tp_dealloc = (destructor)font_dealloc, .tp_flags = Py_TPFLAGS_DEFAULT, @@ -2931,7 +2931,7 @@ static PyMappingMethods bmp565_as_mapping = { static PyTypeObject GfxBmp565Type = { PyVarObject_HEAD_INIT(NULL, 0) - .tp_name = "graphics.BMP565", + .tp_name = "pygraphics.BMP565", .tp_basicsize = sizeof(GfxBmp565Object), .tp_dealloc = (destructor)bmp565_dealloc, .tp_flags = Py_TPFLAGS_DEFAULT, @@ -2982,13 +2982,13 @@ static PyMethodDef module_methods[] = { static struct PyModuleDef graphics_module = { PyModuleDef_HEAD_INIT, - .m_name = "graphics", + .m_name = "pygraphics", .m_doc = "Native graphics module for CPython", .m_size = -1, .m_methods = module_methods, }; -PyMODINIT_FUNC PyInit_graphics(void) { +PyMODINIT_FUNC PyInit_pygraphics(void) { PyObject *m = PyModule_Create(&graphics_module); if (!m) { return NULL; diff --git a/src/graphics_qstrdefs.h b/src/pygraphics_qstrdefs.h similarity index 98% rename from src/graphics_qstrdefs.h rename to src/pygraphics_qstrdefs.h index d519b8f..0bb1a9e 100644 --- a/src/graphics_qstrdefs.h +++ b/src/pygraphics_qstrdefs.h @@ -1,4 +1,4 @@ -Q(graphics) +Q(pygraphics) Q(Area) Q(FrameBuffer) Q(Draw) diff --git a/tests/_env.py b/tests/_env.py index 95f6271..0424e10 100644 --- a/tests/_env.py +++ b/tests/_env.py @@ -1,7 +1,7 @@ # SPDX-FileCopyrightText: 2026 Brad Barnett # # SPDX-License-Identifier: MIT -"""Put ``lib/`` on ``sys.path`` so ``import graphics`` works in-repo.""" +"""Put ``lib/`` on ``sys.path`` so ``import pygraphics`` works in-repo.""" import os import sys diff --git a/tests/test_area.py b/tests/test_area.py index e309442..aeb71b5 100644 --- a/tests/test_area.py +++ b/tests/test_area.py @@ -8,7 +8,7 @@ if _p.endswith("/graphics") and "repos" in _p: sys.path.remove(_p) -from graphics import Area +from pygraphics import Area assert Area((5, 6, 7, 8)) == Area(5, 6, 7, 8) a = Area(0, 0, 10, 10) diff --git a/tests/test_blit_hooks.py b/tests/test_blit_hooks.py index c515e55..608b544 100644 --- a/tests/test_blit_hooks.py +++ b/tests/test_blit_hooks.py @@ -8,8 +8,8 @@ import _env # noqa: F401 from _support import make_fb -from graphics import Area, Draw, blit, blit_rect -from graphics._blit_hooks import ( +from pygraphics import Area, Draw, blit, blit_rect +from pygraphics._blit_hooks import ( blit_rect_dispatch, canvas_accepts_blit_rect, canvas_accepts_blit_transparent, @@ -88,7 +88,7 @@ def test_try_fast_framebuffer_blit_clips(self): self.assertEqual(dst.pixel(5, 5), 0) def test_blit_transparent_uses_display_hook(self): - from graphics import blit_transparent + from pygraphics import blit_transparent canvas = _BlitTransparentCanvas(8, 8) buf = bytearray(2 * 2 * 2) diff --git a/tests/test_clip.py b/tests/test_clip.py index ec7db10..75b91da 100644 --- a/tests/test_clip.py +++ b/tests/test_clip.py @@ -8,8 +8,8 @@ import _env # noqa: F401 from _support import make_fb -from graphics import Area -from graphics._clip import ClippedCanvas, crop_rgb565_buffer, intersect_rect +from pygraphics import Area +from pygraphics._clip import ClippedCanvas, crop_rgb565_buffer, intersect_rect class TestClipHelpers(unittest.TestCase): diff --git a/tests/test_draw.py b/tests/test_draw.py index be9a526..9bab8e5 100644 --- a/tests/test_draw.py +++ b/tests/test_draw.py @@ -1,10 +1,10 @@ # SPDX-FileCopyrightText: 2026 Brad Barnett # # SPDX-License-Identifier: MIT -"""Tests for the ``graphics.Draw`` convenience wrapper. +"""Tests for the ``pygraphics.Draw`` convenience wrapper. -``Draw`` binds a canvas once and forwards each call to ``graphics._shapes`` / -``graphics._font``, returning the ``Area`` bounding box. +``Draw`` binds a canvas once and forwards each call to ``pygraphics._shapes`` / +``pygraphics._font``, returning the ``Area`` bounding box. """ import unittest @@ -12,7 +12,7 @@ import _env # noqa: F401 from _support import count_set, make_fb -from graphics import Area, Draw +from pygraphics import Area, Draw _WHITE = 0xFFFF diff --git a/tests/test_files.py b/tests/test_files.py index aa311e5..b4db141 100644 --- a/tests/test_files.py +++ b/tests/test_files.py @@ -1,7 +1,7 @@ # SPDX-FileCopyrightText: 2026 Brad Barnett # # SPDX-License-Identifier: MIT -"""Tests for ``graphics`` image file I/O (save / from_file and the converters). +"""Tests for ``pygraphics`` image file I/O (save / from_file and the converters). Covers the formats whose pure-Python read/write paths round-trip cleanly on CPython: PBM (MONO_HLSB), PGM (grayscale), and BMP (RGB565). @@ -14,7 +14,7 @@ import _env # noqa: F401 -from graphics import ( +from pygraphics import ( BMP565, GS2_HMSB, GS4_HMSB, @@ -169,7 +169,7 @@ def test_pbm_bad_magic_raises(self): class TestBmp565(_TmpDirTest): def _write_minimal_bmp(self, path, width, height, pixels): - from graphics._bmp565 import write_bmp565_file + from pygraphics._bmp565 import write_bmp565_file with open(path, "wb") as f: write_bmp565_file(f, pixels, width, height) diff --git a/tests/test_font.py b/tests/test_font.py index 9eae935..81c5d8c 100644 --- a/tests/test_font.py +++ b/tests/test_font.py @@ -1,14 +1,14 @@ # SPDX-FileCopyrightText: 2026 Brad Barnett # # SPDX-License-Identifier: MIT -"""Tests for ``graphics`` text rendering (``Font`` and the ``text*`` helpers).""" +"""Tests for ``pygraphics`` text rendering (``Font`` and the ``text*`` helpers).""" import unittest import _env # noqa: F401 from _support import count_set, make_fb -from graphics import Area, Font, text, text8, text14, text16 +from pygraphics import Area, Font, text, text8, text14, text16 class TestFontObject(unittest.TestCase): diff --git a/tests/test_framebuf_plus.py b/tests/test_framebuf_plus.py index 72d8297..ba69f3f 100644 --- a/tests/test_framebuf_plus.py +++ b/tests/test_framebuf_plus.py @@ -1,10 +1,10 @@ # SPDX-FileCopyrightText: 2026 Brad Barnett # # SPDX-License-Identifier: MIT -"""Tests for ``graphics.FrameBuffer`` (the ``_framebuf_plus`` wrapper). +"""Tests for ``pygraphics.FrameBuffer`` (the ``_framebuf_plus`` wrapper). This is the ``FrameBuffer`` exported from the package. Unlike the bare -``framebuf`` base class, every drawing method returns an :class:`graphics.Area` +``framebuf`` base class, every drawing method returns an :class:`pygraphics.Area` bounding box and the buffer/format/color_depth are exposed as properties. """ @@ -13,8 +13,8 @@ import _env # noqa: F401 from _support import make_fb -import graphics -from graphics import ( +import pygraphics +from pygraphics import ( GS2_HMSB, GS4_HMSB, GS8, diff --git a/tests/test_parity.py b/tests/test_parity.py index 3c64915..f06323d 100644 --- a/tests/test_parity.py +++ b/tests/test_parity.py @@ -2,7 +2,7 @@ # SPDX-License-Identifier: MIT """Verify graphics cmod exports match pydisplay __all__.""" -import graphics +import pygraphics ALL = [ "BMP565", @@ -51,19 +51,19 @@ "vline", ] -missing = [name for name in ALL if not hasattr(graphics, name)] +missing = [name for name in ALL if not hasattr(pygraphics, name)] if missing: raise SystemExit("missing exports: " + ", ".join(missing)) -assert graphics.framebuf_backend() == "native", graphics.capabilities() -assert graphics.implementation() == "native_cmod", graphics.capabilities() +assert pygraphics.framebuf_backend() == "native", pygraphics.capabilities() +assert pygraphics.implementation() == "native_cmod", pygraphics.capabilities() buf = bytearray(32 * 32 * 2) -fb = graphics.FrameBuffer(buf, 32, 32, graphics.RGB565) +fb = pygraphics.FrameBuffer(buf, 32, 32, pygraphics.RGB565) assert fb.buffer is buf or bytes(fb.buffer) == bytes(buf) fb.fill(0) -graphics.fill_rect(fb, 1, 1, 4, 4, 0xF800) -graphics.text8(fb, "Hi", 0, 0, 0xFFFF) -d = graphics.Draw(fb) +pygraphics.fill_rect(fb, 1, 1, 4, 4, 0xF800) +pygraphics.text8(fb, "Hi", 0, 0, 0xFFFF) +d = pygraphics.Draw(fb) d.fill_rect(0, 0, 2, 2, 1) print("test_parity: ok") diff --git a/tests/test_parity_kwargs.py b/tests/test_parity_kwargs.py index 5684b1e..2afc280 100644 --- a/tests/test_parity_kwargs.py +++ b/tests/test_parity_kwargs.py @@ -1,10 +1,10 @@ # SPDX-License-Identifier: MIT -"""Parity probe: kwargs + missing methods vs pydisplay lib/graphics contract.""" +"""Parity probe: kwargs + missing methods vs pydisplay lib/pygraphics contract.""" try: - import graphics + import pygraphics except ImportError as e: - print("FAIL: import graphics:", e) + print("FAIL: import pygraphics:", e) raise SystemExit(1) results = {} @@ -20,8 +20,8 @@ def check(name, fn): print("FAIL:", name, e) -impl = graphics.implementation() -backend = graphics.framebuf_backend() +impl = pygraphics.implementation() +backend = pygraphics.framebuf_backend() print("implementation:", impl) print("framebuf_backend:", backend) assert impl == "native_cmod", impl @@ -29,15 +29,15 @@ def check(name, fn): W, H = 64, 64 buf = bytearray(W * H * 2) -fb = graphics.FrameBuffer(buf, W, H, graphics.RGB565) +fb = pygraphics.FrameBuffer(buf, W, H, pygraphics.RGB565) fb.fill(0) def t_text_module(): - graphics.text8(fb, "A", 0, 0, c=0xFFFF, scale=2, inverted=False) - graphics.text14(fb, "B", 0, 16, c=0xFFFF, scale=1) - graphics.text16(fb, "C", 0, 32, scale=1, inverted=False) - graphics.text(fb, "D", 0, 48, c=1, height=8, scale=1) + pygraphics.text8(fb, "A", 0, 0, c=0xFFFF, scale=2, inverted=False) + pygraphics.text14(fb, "B", 0, 16, c=0xFFFF, scale=1) + pygraphics.text16(fb, "C", 0, 32, scale=1, inverted=False) + pygraphics.text(fb, "D", 0, 48, c=1, height=8, scale=1) def t_text_fb(): @@ -49,7 +49,7 @@ def t_text_fb(): def t_text_draw(): - d = graphics.Draw(fb) + d = pygraphics.Draw(fb) assert hasattr(d, "text8") and hasattr(d, "text14") and hasattr(d, "text16") d.text8("I", 16, 0, c=0xFFFF, scale=1) d.text14("J", 16, 16, scale=1) @@ -58,27 +58,27 @@ def t_text_draw(): def t_fill_kwargs(): - graphics.rect(fb, 0, 0, 10, 10, 0xF800, f=True) - graphics.round_rect(fb, 12, 0, 10, 10, 2, 0x07E0, f=True) - graphics.ellipse(fb, 30, 5, 4, 3, 0x001F, f=True) - graphics.triangle(fb, 40, 0, 50, 0, 45, 8, 0xFFFF, f=True) + pygraphics.rect(fb, 0, 0, 10, 10, 0xF800, f=True) + pygraphics.round_rect(fb, 12, 0, 10, 10, 2, 0x07E0, f=True) + pygraphics.ellipse(fb, 30, 5, 4, 3, 0x001F, f=True) + pygraphics.triangle(fb, 40, 0, 50, 0, 45, 8, 0xFFFF, f=True) fb.rect(0, 12, 8, 8, 0xF800, f=True) fb.round_rect(10, 12, 8, 8, 2, 0x07E0, f=True) fb.circle(24, 16, 4, 0x001F, f=True) - d = graphics.Draw(fb) + d = pygraphics.Draw(fb) d.rect(30, 12, 8, 8, 0xF800, f=True) d.circle(44, 16, 3, 0x07E0, f=True) def t_gradient_polygon_blit(): - graphics.gradient_rect(fb, 0, 24, 20, 8, 0xF800, c2=0x001F, vertical=True) + pygraphics.gradient_rect(fb, 0, 24, 20, 8, 0xF800, c2=0x001F, vertical=True) fb.gradient_rect(22, 24, 20, 8, 0x07E0, c2=0xF800, vertical=False) pts = [(0, 0), (6, 0), (3, 6)] - graphics.polygon(fb, pts, 50, 24, 0xFFFF, angle=0.5) + pygraphics.polygon(fb, pts, 50, 24, 0xFFFF, angle=0.5) fb.polygon(pts, 50, 36, 0xFFFF, angle=0.0, center_x=0, center_y=0) - src = graphics.FrameBuffer(bytearray(4 * 4 * 2), 4, 4, graphics.RGB565) + src = pygraphics.FrameBuffer(bytearray(4 * 4 * 2), 4, 4, pygraphics.RGB565) src.fill(0xF800) - graphics.blit(fb, src, 0, 40, key=-1) + pygraphics.blit(fb, src, 0, 40, key=-1) fb.blit(src, 8, 40, key=0) @@ -103,7 +103,7 @@ def t_missing_fb_methods(): def t_missing_draw_methods(): - d = graphics.Draw(fb) + d = pygraphics.Draw(fb) for name in ( "text8", "text16", @@ -122,21 +122,21 @@ def t_missing_draw_methods(): d.ellipse(20, 10, 4, 3, 0xF800, f=True) d.gradient_rect(30, 8, 10, 6, 0xF800, c2=0x001F, vertical=True) d.triangle(0, 0, 5, 0, 2, 5, 0x07E0, f=True) - src = graphics.FrameBuffer(bytearray(2 * 2 * 2), 2, 2, graphics.RGB565) + src = pygraphics.FrameBuffer(bytearray(2 * 2 * 2), 2, 2, pygraphics.RGB565) src.fill(1) d.blit(src, 50, 50, key=-1) def t_font_kwargs(): - font = graphics.Font(height=8) + font = pygraphics.Font(height=8) font.text(fb, "Z", 0, 56, 0xFFFF, scale=1, inverted=False) def t_area_return(): a = fb.fill_rect(0, 0, 2, 2, 0) - assert isinstance(a, graphics.Area), type(a) - a2 = graphics.text8(fb, "x", 0, 0, 1) - assert isinstance(a2, graphics.Area), type(a2) + assert isinstance(a, pygraphics.Area), type(a) + a2 = pygraphics.text8(fb, "x", 0, 0, 1) + assert isinstance(a2, pygraphics.Area), type(a2) check("text_module", t_text_module) diff --git a/tests/test_graphics.py b/tests/test_pygraphics.py similarity index 91% rename from tests/test_graphics.py rename to tests/test_pygraphics.py index 9a5ce26..33540c7 100644 --- a/tests/test_graphics.py +++ b/tests/test_pygraphics.py @@ -8,8 +8,8 @@ import array -import graphics -from graphics import Area, FrameBuffer, RGB565, capabilities, framebuf_backend +import pygraphics +from pygraphics import Area, FrameBuffer, RGB565, capabilities, framebuf_backend print("backend:", framebuf_backend()) assert framebuf_backend() == "native", capabilities() diff --git a/tests/test_shapes.py b/tests/test_shapes.py index 3eb9464..6c9039e 100644 --- a/tests/test_shapes.py +++ b/tests/test_shapes.py @@ -1,11 +1,11 @@ # SPDX-FileCopyrightText: 2026 Brad Barnett # # SPDX-License-Identifier: MIT -"""Tests for the module-level drawing primitives in ``graphics._shapes``. +"""Tests for the module-level drawing primitives in ``pygraphics._shapes``. These are the functions re-exported from the package top level (``hline``, ``rect``, ``circle`` ...). They take the canvas as the first argument and -return an :class:`graphics.Area` bounding box. +return an :class:`pygraphics.Area` bounding box. """ from array import array @@ -14,7 +14,7 @@ import _env # noqa: F401 from _support import count_set, make_fb -from graphics import ( +from pygraphics import ( Area, arc, blit, diff --git a/tests/test_subclass.py b/tests/test_subclass.py index 7209736..f91c9e9 100644 --- a/tests/test_subclass.py +++ b/tests/test_subclass.py @@ -8,8 +8,8 @@ if _p.endswith("/graphics") and "repos" in _p: sys.path.remove(_p) -import graphics -from graphics import FrameBuffer, RGB565, Area +import pygraphics +from pygraphics import FrameBuffer, RGB565, Area class SubBuffer(FrameBuffer): diff --git a/tools/benchmark_framebuf.py b/tools/benchmark_framebuf.py index ce0953b..fa687fc 100644 --- a/tools/benchmark_framebuf.py +++ b/tools/benchmark_framebuf.py @@ -9,9 +9,9 @@ import time -from graphics import RGB565, framebuf_backend -from graphics._framebuf import FrameBuffer as NativeFB -from graphics._framebuf_pure import FrameBuffer as PureFB +from pygraphics import RGB565, framebuf_backend +from pygraphics._framebuf import FrameBuffer as NativeFB +from pygraphics._framebuf_pure import FrameBuffer as PureFB W, H = 128, 128 ITERS = 200 diff --git a/docs/favicon.svg b/tools/sourcey-api/favicon.svg similarity index 100% rename from docs/favicon.svg rename to tools/sourcey-api/favicon.svg diff --git a/docs/generated/area-clipping.md b/tools/sourcey-api/generated/area-clipping.md similarity index 58% rename from docs/generated/area-clipping.md rename to tools/sourcey-api/generated/area-clipping.md index 6f3b129..42024e1 100644 --- a/docs/generated/area-clipping.md +++ b/tools/sourcey-api/generated/area-clipping.md @@ -3,13 +3,13 @@ title: Area and clipping description: Rectangle geometry, scoped clip contexts, and clipped canvas operations. --- -Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). +Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). Rectangle geometry, scoped clip contexts, and clipped canvas operations. Every entry below is generated from a public binding table or header declaration and links to its immutable source line. -## `graphics.Area` +## `pygraphics.Area` ```python class Area(x=0, y=0, w=0, h=0) @@ -17,9 +17,9 @@ class Area(x=0, y=0, w=0, h=0) Immutable rectangle geometry used for bounds, clipping, and draw results. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L395) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L395) -## `graphics.Area.contains` +## `pygraphics.Area.contains` ```python Area.contains(point_or_x, y=None) @@ -27,9 +27,9 @@ Area.contains(point_or_x, y=None) Test whether the area contains a point. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L377) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L377) -## `graphics.Area.contains_area` +## `pygraphics.Area.contains_area` ```python Area.contains_area(other) @@ -37,9 +37,9 @@ Area.contains_area(other) Test whether another Area is fully contained. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L378) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L378) -## `graphics.Area.intersects` +## `pygraphics.Area.intersects` ```python Area.intersects(other) @@ -47,9 +47,9 @@ Area.intersects(other) Test whether two areas overlap. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L379) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L379) -## `graphics.Area.touches_or_intersects` +## `pygraphics.Area.touches_or_intersects` ```python Area.touches_or_intersects(other) @@ -57,9 +57,9 @@ Area.touches_or_intersects(other) Test whether two areas overlap or share an edge. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L380) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L380) -## `graphics.Area.shift` +## `pygraphics.Area.shift` ```python Area.shift(dx=0, dy=0) @@ -67,9 +67,9 @@ Area.shift(dx=0, dy=0) Return a copy translated by the requested offset. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L381) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L381) -## `graphics.Area.clip` +## `pygraphics.Area.clip` ```python Area.clip(other) @@ -77,9 +77,9 @@ Area.clip(other) Return the intersection with another Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L382) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L382) -## `graphics.Area.offset` +## `pygraphics.Area.offset` ```python Area.offset(left, top=None, right=None, bottom=None) @@ -87,9 +87,9 @@ Area.offset(left, top=None, right=None, bottom=None) Return an Area expanded independently on each edge. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L383) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L383) -## `graphics.Area.inset` +## `pygraphics.Area.inset` ```python Area.inset(left, top=None, right=None, bottom=None) @@ -97,9 +97,9 @@ Area.inset(left, top=None, right=None, bottom=None) Return an Area reduced independently on each edge. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L384) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L384) -## `graphics.Area.x` +## `pygraphics.Area.x` ```python Area.x @@ -107,9 +107,9 @@ Area.x Left coordinate. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L229) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L229) -## `graphics.Area.y` +## `pygraphics.Area.y` ```python Area.y @@ -117,9 +117,9 @@ Area.y Top coordinate. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L230) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L230) -## `graphics.Area.w` +## `pygraphics.Area.w` ```python Area.w @@ -127,9 +127,9 @@ Area.w Width in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L231) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L231) -## `graphics.Area.h` +## `pygraphics.Area.h` ```python Area.h @@ -137,9 +137,9 @@ Area.h Height in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L232) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L232) -## `graphics.ClipContext` +## `pygraphics.ClipContext` ```python class ClipContext(draw, area) @@ -147,9 +147,9 @@ class ClipContext(draw, area) Context manager returned by Draw.clip() for scoped clipping. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2147) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2147) -## `graphics.ClipContext.__enter__` +## `pygraphics.ClipContext.__enter__` ```python ClipContext.__enter__() @@ -157,9 +157,9 @@ ClipContext.__enter__() Push the requested clipping area and return the effective clip. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2140) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2140) -## `graphics.ClipContext.__exit__` +## `pygraphics.ClipContext.__exit__` ```python ClipContext.__exit__(exc_type, exc_value, traceback) @@ -167,9 +167,9 @@ ClipContext.__exit__(exc_type, exc_value, traceback) Pop the clipping area when leaving the context. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2141) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2141) -## `graphics.ClippedCanvas` +## `pygraphics.ClippedCanvas` ```python class ClippedCanvas(canvas, clip) @@ -177,9 +177,9 @@ class ClippedCanvas(canvas, clip) Canvas proxy that intersects writes with a fixed Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2414) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2414) -## `graphics.ClippedCanvas.pixel` +## `pygraphics.ClippedCanvas.pixel` ```python ClippedCanvas.pixel(x, y, color=None) @@ -187,9 +187,9 @@ ClippedCanvas.pixel(x, y, color=None) Read or write one pixel, depending on whether a color is supplied. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2402) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2402) -## `graphics.ClippedCanvas.fill` +## `pygraphics.ClippedCanvas.fill` ```python ClippedCanvas.fill(color) @@ -197,9 +197,9 @@ ClippedCanvas.fill(color) Fill the target canvas with one color and return the affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2403) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2403) -## `graphics.ClippedCanvas.fill_rect` +## `pygraphics.ClippedCanvas.fill_rect` ```python ClippedCanvas.fill_rect(x, y, width, height, color) @@ -207,9 +207,9 @@ ClippedCanvas.fill_rect(x, y, width, height, color) Fill a rectangular region and return the clipped affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2404) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2404) -## `graphics.ClippedCanvas.hline` +## `pygraphics.ClippedCanvas.hline` ```python ClippedCanvas.hline(x, y, width, color) @@ -217,9 +217,9 @@ ClippedCanvas.hline(x, y, width, color) Draw a horizontal line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2405) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2405) -## `graphics.ClippedCanvas.vline` +## `pygraphics.ClippedCanvas.vline` ```python ClippedCanvas.vline(x, y, height, color) @@ -227,9 +227,9 @@ ClippedCanvas.vline(x, y, height, color) Draw a vertical line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2406) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2406) -## `graphics.ClippedCanvas.blit_rect` +## `pygraphics.ClippedCanvas.blit_rect` ```python ClippedCanvas.blit_rect(buffer, x, y, width, height) @@ -237,9 +237,9 @@ ClippedCanvas.blit_rect(buffer, x, y, width, height) Copy a packed RGB565 rectangle onto the target. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2407) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2407) -## `graphics.ClippedCanvas.blit_transparent` +## `pygraphics.ClippedCanvas.blit_transparent` ```python ClippedCanvas.blit_transparent(buffer, x, y, width, height, key) @@ -247,9 +247,9 @@ ClippedCanvas.blit_transparent(buffer, x, y, width, height, key) Copy a packed RGB565 rectangle while skipping the transparent key. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2408) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2408) -## `graphics.ClippedCanvas.width` +## `pygraphics.ClippedCanvas.width` ```python ClippedCanvas.width @@ -257,9 +257,9 @@ ClippedCanvas.width Width in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2223) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2223) -## `graphics.ClippedCanvas.height` +## `pygraphics.ClippedCanvas.height` ```python ClippedCanvas.height @@ -267,4 +267,4 @@ ClippedCanvas.height Height in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2224) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2224) diff --git a/docs/generated/drawing.md b/tools/sourcey-api/generated/drawing.md similarity index 53% rename from docs/generated/drawing.md rename to tools/sourcey-api/generated/drawing.md index 0034cd2..9468aac 100644 --- a/docs/generated/drawing.md +++ b/tools/sourcey-api/generated/drawing.md @@ -3,13 +3,13 @@ title: Drawing operations description: Object-oriented and module-level shape, text, polygon, and blit operations. --- -Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). +Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). Object-oriented and module-level shape, text, polygon, and blit operations. Every entry below is generated from a public binding table or header declaration and links to its immutable source line. -## `graphics.Draw` +## `pygraphics.Draw` ```python class Draw(canvas) @@ -17,9 +17,9 @@ class Draw(canvas) Drawing facade that adds a bounded clip stack to any compatible canvas. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2085) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2085) -## `graphics.Draw.fill` +## `pygraphics.Draw.fill` ```python Draw.fill(color) @@ -27,9 +27,9 @@ Draw.fill(color) Fill the target canvas with one color and return the affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2057) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2057) -## `graphics.Draw.fill_rect` +## `pygraphics.Draw.fill_rect` ```python Draw.fill_rect(x, y, width, height, color) @@ -37,9 +37,9 @@ Draw.fill_rect(x, y, width, height, color) Fill a rectangular region and return the clipped affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2058) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2058) -## `graphics.Draw.pixel` +## `pygraphics.Draw.pixel` ```python Draw.pixel(x, y, color=None) @@ -47,9 +47,9 @@ Draw.pixel(x, y, color=None) Read or write one pixel, depending on whether a color is supplied. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2059) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2059) -## `graphics.Draw.hline` +## `pygraphics.Draw.hline` ```python Draw.hline(x, y, width, color) @@ -57,9 +57,9 @@ Draw.hline(x, y, width, color) Draw a horizontal line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2060) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2060) -## `graphics.Draw.vline` +## `pygraphics.Draw.vline` ```python Draw.vline(x, y, height, color) @@ -67,9 +67,9 @@ Draw.vline(x, y, height, color) Draw a vertical line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2061) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2061) -## `graphics.Draw.line` +## `pygraphics.Draw.line` ```python Draw.line(x1, y1, x2, y2, color) @@ -77,9 +77,9 @@ Draw.line(x1, y1, x2, y2, color) Draw a line between two points. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2062) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2062) -## `graphics.Draw.rect` +## `pygraphics.Draw.rect` ```python Draw.rect(x, y, width, height, color, fill=False) @@ -87,9 +87,9 @@ Draw.rect(x, y, width, height, color, fill=False) Draw an outlined or filled rectangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2063) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2063) -## `graphics.Draw.round_rect` +## `pygraphics.Draw.round_rect` ```python Draw.round_rect(x, y, width, height, radius, color, fill=False) @@ -97,9 +97,9 @@ Draw.round_rect(x, y, width, height, radius, color, fill=False) Draw an outlined or filled rounded rectangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2064) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2064) -## `graphics.Draw.circle` +## `pygraphics.Draw.circle` ```python Draw.circle(x, y, radius, color, fill=False) @@ -107,9 +107,9 @@ Draw.circle(x, y, radius, color, fill=False) Draw an outlined or filled circle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2065) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2065) -## `graphics.Draw.ellipse` +## `pygraphics.Draw.ellipse` ```python Draw.ellipse(x, y, x_radius, y_radius, color, fill=False, mask=0x0F) @@ -117,9 +117,9 @@ Draw.ellipse(x, y, x_radius, y_radius, color, fill=False, mask=0x0F) Draw selected quadrants of an outlined or filled ellipse. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2066) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2066) -## `graphics.Draw.arc` +## `pygraphics.Draw.arc` ```python Draw.arc(x, y, radius, start_angle, end_angle, color) @@ -127,9 +127,9 @@ Draw.arc(x, y, radius, start_angle, end_angle, color) Draw a circular arc between two angles. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2067) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2067) -## `graphics.Draw.triangle` +## `pygraphics.Draw.triangle` ```python Draw.triangle(x0, y0, x1, y1, x2, y2, color, fill=False) @@ -137,9 +137,9 @@ Draw.triangle(x0, y0, x1, y1, x2, y2, color, fill=False) Draw an outlined or filled triangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2068) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2068) -## `graphics.Draw.gradient_rect` +## `pygraphics.Draw.gradient_rect` ```python Draw.gradient_rect(x, y, width, height, color1, color2=None, vertical=True) @@ -147,9 +147,9 @@ Draw.gradient_rect(x, y, width, height, color1, color2=None, vertical=True) Fill a rectangle with a horizontal or vertical color gradient. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2069) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2069) -## `graphics.Draw.poly` +## `pygraphics.Draw.poly` ```python Draw.poly(x, y, coordinates, color, fill=False) @@ -157,9 +157,9 @@ Draw.poly(x, y, coordinates, color, fill=False) Draw a polygon from a packed coordinate buffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2070) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2070) -## `graphics.Draw.polygon` +## `pygraphics.Draw.polygon` ```python Draw.polygon(points, x, y, color, angle=0, center_x=0, center_y=0) @@ -167,9 +167,9 @@ Draw.polygon(points, x, y, color, angle=0, center_x=0, center_y=0) Draw a translated and optionally rotated sequence of points. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2071) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2071) -## `graphics.Draw.blit` +## `pygraphics.Draw.blit` ```python Draw.blit(source, x, y, key=-1, palette=None) @@ -177,9 +177,9 @@ Draw.blit(source, x, y, key=-1, palette=None) Copy another framebuffer onto the target with optional keying and palette lookup. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2072) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2072) -## `graphics.Draw.blit_rect` +## `pygraphics.Draw.blit_rect` ```python Draw.blit_rect(buffer, x, y, width, height) @@ -187,9 +187,9 @@ Draw.blit_rect(buffer, x, y, width, height) Copy a packed RGB565 rectangle onto the target. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2073) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2073) -## `graphics.Draw.blit_transparent` +## `pygraphics.Draw.blit_transparent` ```python Draw.blit_transparent(buffer, x, y, width, height, key) @@ -197,9 +197,9 @@ Draw.blit_transparent(buffer, x, y, width, height, key) Copy a packed RGB565 rectangle while skipping the transparent key. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2074) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2074) -## `graphics.Draw.text` +## `pygraphics.Draw.text` ```python Draw.text(text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8) @@ -207,9 +207,9 @@ Draw.text(text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8 Render bitmap text with selectable height, scale, and inversion. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2075) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2075) -## `graphics.Draw.text8` +## `pygraphics.Draw.text8` ```python Draw.text8(text, x, y, color=1, scale=1, inverted=False, font_data=None) @@ -217,9 +217,9 @@ Draw.text8(text, x, y, color=1, scale=1, inverted=False, font_data=None) Render text with the built-in 8-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2076) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2076) -## `graphics.Draw.text14` +## `pygraphics.Draw.text14` ```python Draw.text14(text, x, y, color=1, scale=1, inverted=False, font_data=None) @@ -227,9 +227,9 @@ Draw.text14(text, x, y, color=1, scale=1, inverted=False, font_data=None) Render text with the built-in 14-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2077) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2077) -## `graphics.Draw.text16` +## `pygraphics.Draw.text16` ```python Draw.text16(text, x, y, color=1, scale=1, inverted=False, font_data=None) @@ -237,9 +237,9 @@ Draw.text16(text, x, y, color=1, scale=1, inverted=False, font_data=None) Render text with the built-in 16-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2078) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2078) -## `graphics.Draw.clip` +## `pygraphics.Draw.clip` ```python Draw.clip(area_or_x, y=None, width=None, height=None) @@ -247,224 +247,224 @@ Draw.clip(area_or_x, y=None, width=None, height=None) Return the intersection with another Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2079) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2079) -## `graphics.fill` +## `pygraphics.fill` ```python -graphics.fill(canvas, color) +pygraphics.fill(canvas, color) ``` Fill the target canvas with one color and return the affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2953) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2953) -## `graphics.fill_rect` +## `pygraphics.fill_rect` ```python -graphics.fill_rect(canvas, x, y, width, height, color) +pygraphics.fill_rect(canvas, x, y, width, height, color) ``` Fill a rectangular region and return the clipped affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2954) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2954) -## `graphics.pixel` +## `pygraphics.pixel` ```python -graphics.pixel(canvas, x, y, color=None) +pygraphics.pixel(canvas, x, y, color=None) ``` Read or write one pixel, depending on whether a color is supplied. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2955) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2955) -## `graphics.hline` +## `pygraphics.hline` ```python -graphics.hline(canvas, x, y, width, color) +pygraphics.hline(canvas, x, y, width, color) ``` Draw a horizontal line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2956) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2956) -## `graphics.vline` +## `pygraphics.vline` ```python -graphics.vline(canvas, x, y, height, color) +pygraphics.vline(canvas, x, y, height, color) ``` Draw a vertical line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2957) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2957) -## `graphics.line` +## `pygraphics.line` ```python -graphics.line(canvas, x1, y1, x2, y2, color) +pygraphics.line(canvas, x1, y1, x2, y2, color) ``` Draw a line between two points. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2958) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2958) -## `graphics.rect` +## `pygraphics.rect` ```python -graphics.rect(canvas, x, y, width, height, color, fill=False) +pygraphics.rect(canvas, x, y, width, height, color, fill=False) ``` Draw an outlined or filled rectangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2959) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2959) -## `graphics.round_rect` +## `pygraphics.round_rect` ```python -graphics.round_rect(canvas, x, y, width, height, radius, color, fill=False) +pygraphics.round_rect(canvas, x, y, width, height, radius, color, fill=False) ``` Draw an outlined or filled rounded rectangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2960) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2960) -## `graphics.circle` +## `pygraphics.circle` ```python -graphics.circle(canvas, x, y, radius, color, fill=False) +pygraphics.circle(canvas, x, y, radius, color, fill=False) ``` Draw an outlined or filled circle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2961) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2961) -## `graphics.ellipse` +## `pygraphics.ellipse` ```python -graphics.ellipse(canvas, x, y, x_radius, y_radius, color, fill=False, mask=0x0F) +pygraphics.ellipse(canvas, x, y, x_radius, y_radius, color, fill=False, mask=0x0F) ``` Draw selected quadrants of an outlined or filled ellipse. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2962) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2962) -## `graphics.arc` +## `pygraphics.arc` ```python -graphics.arc(canvas, x, y, radius, start_angle, end_angle, color) +pygraphics.arc(canvas, x, y, radius, start_angle, end_angle, color) ``` Draw a circular arc between two angles. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2963) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2963) -## `graphics.triangle` +## `pygraphics.triangle` ```python -graphics.triangle(canvas, x0, y0, x1, y1, x2, y2, color, fill=False) +pygraphics.triangle(canvas, x0, y0, x1, y1, x2, y2, color, fill=False) ``` Draw an outlined or filled triangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2964) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2964) -## `graphics.gradient_rect` +## `pygraphics.gradient_rect` ```python -graphics.gradient_rect(canvas, x, y, width, height, color1, color2=None, vertical=True) +pygraphics.gradient_rect(canvas, x, y, width, height, color1, color2=None, vertical=True) ``` Fill a rectangle with a horizontal or vertical color gradient. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2965) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2965) -## `graphics.poly` +## `pygraphics.poly` ```python -graphics.poly(canvas, x, y, coordinates, color, fill=False) +pygraphics.poly(canvas, x, y, coordinates, color, fill=False) ``` Draw a polygon from a packed coordinate buffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2966) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2966) -## `graphics.blit` +## `pygraphics.blit` ```python -graphics.blit(canvas, source, x, y, key=-1, palette=None) +pygraphics.blit(canvas, source, x, y, key=-1, palette=None) ``` Copy another framebuffer onto the target with optional keying and palette lookup. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2967) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2967) -## `graphics.blit_rect` +## `pygraphics.blit_rect` ```python -graphics.blit_rect(canvas, buffer, x, y, width, height) +pygraphics.blit_rect(canvas, buffer, x, y, width, height) ``` Copy a packed RGB565 rectangle onto the target. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2968) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2968) -## `graphics.blit_transparent` +## `pygraphics.blit_transparent` ```python -graphics.blit_transparent(canvas, buffer, x, y, width, height, key) +pygraphics.blit_transparent(canvas, buffer, x, y, width, height, key) ``` Copy a packed RGB565 rectangle while skipping the transparent key. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2969) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2969) -## `graphics.polygon` +## `pygraphics.polygon` ```python -graphics.polygon(canvas, points, x, y, color, angle=0, center_x=0, center_y=0) +pygraphics.polygon(canvas, points, x, y, color, angle=0, center_x=0, center_y=0) ``` Draw a translated and optionally rotated sequence of points. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2970) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2970) -## `graphics.text` +## `pygraphics.text` ```python -graphics.text(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8) +pygraphics.text(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8) ``` Render bitmap text with selectable height, scale, and inversion. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2976) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2976) -## `graphics.text8` +## `pygraphics.text8` ```python -graphics.text8(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None) +pygraphics.text8(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None) ``` Render text with the built-in 8-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2977) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2977) -## `graphics.text14` +## `pygraphics.text14` ```python -graphics.text14(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None) +pygraphics.text14(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None) ``` Render text with the built-in 14-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2978) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2978) -## `graphics.text16` +## `pygraphics.text16` ```python -graphics.text16(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None) +pygraphics.text16(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None) ``` Render text with the built-in 16-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2979) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2979) diff --git a/docs/generated/fonts-images.md b/tools/sourcey-api/generated/fonts-images.md similarity index 56% rename from docs/generated/fonts-images.md rename to tools/sourcey-api/generated/fonts-images.md index 07683fa..6201ae1 100644 --- a/docs/generated/fonts-images.md +++ b/tools/sourcey-api/generated/fonts-images.md @@ -3,13 +3,13 @@ title: Fonts and images description: Bitmap font rendering, RGB565 bitmap access, and image conversion helpers. --- -Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). +Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). Bitmap font rendering, RGB565 bitmap access, and image conversion helpers. Every entry below is generated from a public binding table or header declaration and links to its immutable source line. -## `graphics.Font` +## `pygraphics.Font` ```python class Font(font_data=None, height=0, cached=True) @@ -17,9 +17,9 @@ class Font(font_data=None, height=0, cached=True) Bitmap font loader and renderer for built-in, file, or buffer-backed glyph data. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2643) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2643) -## `graphics.Font.text` +## `pygraphics.Font.text` ```python Font.text(canvas, text, x, y, color, scale=1, inverted=False) @@ -27,9 +27,9 @@ Font.text(canvas, text, x, y, color, scale=1, inverted=False) Render bitmap text with selectable height, scale, and inversion. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2633) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2633) -## `graphics.Font.draw_char` +## `pygraphics.Font.draw_char` ```python Font.draw_char(char, x, y, canvas, color, scale=1, inverted=False) @@ -37,9 +37,9 @@ Font.draw_char(char, x, y, canvas, color, scale=1, inverted=False) Render one glyph through this Font onto a canvas. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2634) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2634) -## `graphics.Font.text_width` +## `pygraphics.Font.text_width` ```python Font.text_width(text, scale=1) @@ -47,9 +47,9 @@ Font.text_width(text, scale=1) Measure rendered text width at the selected scale. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2635) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2635) -## `graphics.Font.deinit` +## `pygraphics.Font.deinit` ```python Font.deinit() @@ -57,9 +57,9 @@ Font.deinit() Release resources owned by the object. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2636) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2636) -## `graphics.Font.export` +## `pygraphics.Font.export` ```python Font.export(filename) @@ -67,9 +67,9 @@ Font.export(filename) Write cached font bytes to a file. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2637) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2637) -## `graphics.Font.width` +## `pygraphics.Font.width` ```python Font.width @@ -77,9 +77,9 @@ Font.width Width in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2626) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2626) -## `graphics.Font.height` +## `pygraphics.Font.height` ```python Font.height @@ -87,9 +87,9 @@ Font.height Height in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2627) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2627) -## `graphics.Font.font_name` +## `pygraphics.Font.font_name` ```python Font.font_name @@ -97,9 +97,9 @@ Font.font_name Font source name or the in-memory/default identifier. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2628) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2628) -## `graphics.BMP565` +## `pygraphics.BMP565` ```python class BMP565(filename=None, source=None, streamed=False, mirrored=False, width=None, height=None) @@ -107,9 +107,9 @@ class BMP565(filename=None, source=None, streamed=False, mirrored=False, width=N RGB565 bitmap reader supporting buffered and streamed access. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2934) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2934) -## `graphics.BMP565.save` +## `pygraphics.BMP565.save` ```python BMP565.save(filename=None) @@ -117,9 +117,9 @@ BMP565.save(filename=None) Write the current image or bitmap to a versioned output path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2923) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2923) -## `graphics.BMP565.deinit` +## `pygraphics.BMP565.deinit` ```python BMP565.deinit() @@ -127,9 +127,9 @@ BMP565.deinit() Release resources owned by the object. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2924) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2924) -## `graphics.BMP565.width` +## `pygraphics.BMP565.width` ```python BMP565.width @@ -137,9 +137,9 @@ BMP565.width Width in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2914) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2914) -## `graphics.BMP565.height` +## `pygraphics.BMP565.height` ```python BMP565.height @@ -147,9 +147,9 @@ BMP565.height Height in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2915) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2915) -## `graphics.BMP565.buffer` +## `pygraphics.BMP565.buffer` ```python BMP565.buffer @@ -157,9 +157,9 @@ BMP565.buffer Backing pixel buffer when the object owns or exposes one. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2916) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2916) -## `graphics.BMP565.bpp` +## `pygraphics.BMP565.bpp` ```python BMP565.bpp @@ -167,9 +167,9 @@ BMP565.bpp Bitmap color depth in bits per pixel. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2917) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2917) -## `graphics.BMP565.BPP` +## `pygraphics.BMP565.BPP` ```python BMP565.BPP @@ -177,54 +177,54 @@ BMP565.BPP Bitmap storage width in bytes per pixel. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2918) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2918) -## `graphics.load_image` +## `pygraphics.load_image` ```python -graphics.load_image(path) +pygraphics.load_image(path) ``` Load a supported image file as a FrameBuffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2971) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2971) -## `graphics.save_image` +## `pygraphics.save_image` ```python -graphics.save_image(framebuffer, path='screenshot') +pygraphics.save_image(framebuffer, path='screenshot') ``` Save a FrameBuffer to a versioned image path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2972) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2972) -## `graphics.bmp_to_framebuffer` +## `pygraphics.bmp_to_framebuffer` ```python -graphics.bmp_to_framebuffer(path) +pygraphics.bmp_to_framebuffer(path) ``` Decode a BMP file into a FrameBuffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2973) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2973) -## `graphics.pbm_to_framebuffer` +## `pygraphics.pbm_to_framebuffer` ```python -graphics.pbm_to_framebuffer(path) +pygraphics.pbm_to_framebuffer(path) ``` Decode a PBM file into a FrameBuffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2974) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2974) -## `graphics.pgm_to_framebuffer` +## `pygraphics.pgm_to_framebuffer` ```python -graphics.pgm_to_framebuffer(path) +pygraphics.pgm_to_framebuffer(path) ``` Decode a PGM file into a FrameBuffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2975) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2975) diff --git a/docs/generated/framebuffer.md b/tools/sourcey-api/generated/framebuffer.md similarity index 61% rename from docs/generated/framebuffer.md rename to tools/sourcey-api/generated/framebuffer.md index e1eb8c5..cc59fac 100644 --- a/docs/generated/framebuffer.md +++ b/tools/sourcey-api/generated/framebuffer.md @@ -3,13 +3,13 @@ title: FrameBuffer description: Native framebuffer construction, drawing, text, blitting, scrolling, and file output. --- -Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). +Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). Native framebuffer construction, drawing, text, blitting, scrolling, and file output. Every entry below is generated from a public binding table or header declaration and links to its immutable source line. -## `graphics.FrameBuffer` +## `pygraphics.FrameBuffer` ```python class FrameBuffer(buffer, width, height, format, stride=None) @@ -17,9 +17,9 @@ class FrameBuffer(buffer, width, height, format, stride=None) A framebuf-compatible native drawing surface backed by a writable buffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1112) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1112) -## `graphics.FrameBuffer.from_file` +## `pygraphics.FrameBuffer.from_file` ```python FrameBuffer.from_file(path) @@ -27,9 +27,9 @@ FrameBuffer.from_file(path) Load a supported image file into a new FrameBuffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1082) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1082) -## `graphics.FrameBuffer.fill` +## `pygraphics.FrameBuffer.fill` ```python FrameBuffer.fill(color) @@ -37,9 +37,9 @@ FrameBuffer.fill(color) Fill the target canvas with one color and return the affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1083) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1083) -## `graphics.FrameBuffer.fill_rect` +## `pygraphics.FrameBuffer.fill_rect` ```python FrameBuffer.fill_rect(x, y, width, height, color) @@ -47,9 +47,9 @@ FrameBuffer.fill_rect(x, y, width, height, color) Fill a rectangular region and return the clipped affected Area. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1084) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1084) -## `graphics.FrameBuffer.pixel` +## `pygraphics.FrameBuffer.pixel` ```python FrameBuffer.pixel(x, y, color=None) @@ -57,9 +57,9 @@ FrameBuffer.pixel(x, y, color=None) Read or write one pixel, depending on whether a color is supplied. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1085) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1085) -## `graphics.FrameBuffer.hline` +## `pygraphics.FrameBuffer.hline` ```python FrameBuffer.hline(x, y, width, color) @@ -67,9 +67,9 @@ FrameBuffer.hline(x, y, width, color) Draw a horizontal line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1086) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1086) -## `graphics.FrameBuffer.vline` +## `pygraphics.FrameBuffer.vline` ```python FrameBuffer.vline(x, y, height, color) @@ -77,9 +77,9 @@ FrameBuffer.vline(x, y, height, color) Draw a vertical line. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1087) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1087) -## `graphics.FrameBuffer.rect` +## `pygraphics.FrameBuffer.rect` ```python FrameBuffer.rect(x, y, width, height, color, fill=False) @@ -87,9 +87,9 @@ FrameBuffer.rect(x, y, width, height, color, fill=False) Draw an outlined or filled rectangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1088) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1088) -## `graphics.FrameBuffer.round_rect` +## `pygraphics.FrameBuffer.round_rect` ```python FrameBuffer.round_rect(x, y, width, height, radius, color, fill=False) @@ -97,9 +97,9 @@ FrameBuffer.round_rect(x, y, width, height, radius, color, fill=False) Draw an outlined or filled rounded rectangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1089) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1089) -## `graphics.FrameBuffer.circle` +## `pygraphics.FrameBuffer.circle` ```python FrameBuffer.circle(x, y, radius, color, fill=False) @@ -107,9 +107,9 @@ FrameBuffer.circle(x, y, radius, color, fill=False) Draw an outlined or filled circle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1090) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1090) -## `graphics.FrameBuffer.line` +## `pygraphics.FrameBuffer.line` ```python FrameBuffer.line(x1, y1, x2, y2, color) @@ -117,9 +117,9 @@ FrameBuffer.line(x1, y1, x2, y2, color) Draw a line between two points. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1091) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1091) -## `graphics.FrameBuffer.ellipse` +## `pygraphics.FrameBuffer.ellipse` ```python FrameBuffer.ellipse(x, y, x_radius, y_radius, color, fill=False, mask=0x0F) @@ -127,9 +127,9 @@ FrameBuffer.ellipse(x, y, x_radius, y_radius, color, fill=False, mask=0x0F) Draw selected quadrants of an outlined or filled ellipse. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1092) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1092) -## `graphics.FrameBuffer.poly` +## `pygraphics.FrameBuffer.poly` ```python FrameBuffer.poly(x, y, coordinates, color, fill=False) @@ -137,9 +137,9 @@ FrameBuffer.poly(x, y, coordinates, color, fill=False) Draw a polygon from a packed coordinate buffer. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1093) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1093) -## `graphics.FrameBuffer.arc` +## `pygraphics.FrameBuffer.arc` ```python FrameBuffer.arc(x, y, radius, start_angle, end_angle, color) @@ -147,9 +147,9 @@ FrameBuffer.arc(x, y, radius, start_angle, end_angle, color) Draw a circular arc between two angles. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1094) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1094) -## `graphics.FrameBuffer.triangle` +## `pygraphics.FrameBuffer.triangle` ```python FrameBuffer.triangle(x0, y0, x1, y1, x2, y2, color, fill=False) @@ -157,9 +157,9 @@ FrameBuffer.triangle(x0, y0, x1, y1, x2, y2, color, fill=False) Draw an outlined or filled triangle. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1095) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1095) -## `graphics.FrameBuffer.gradient_rect` +## `pygraphics.FrameBuffer.gradient_rect` ```python FrameBuffer.gradient_rect(x, y, width, height, color1, color2=None, vertical=True) @@ -167,9 +167,9 @@ FrameBuffer.gradient_rect(x, y, width, height, color1, color2=None, vertical=Tru Fill a rectangle with a horizontal or vertical color gradient. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1096) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1096) -## `graphics.FrameBuffer.polygon` +## `pygraphics.FrameBuffer.polygon` ```python FrameBuffer.polygon(points, x, y, color, angle=0, center_x=0, center_y=0) @@ -177,9 +177,9 @@ FrameBuffer.polygon(points, x, y, color, angle=0, center_x=0, center_y=0) Draw a translated and optionally rotated sequence of points. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1097) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1097) -## `graphics.FrameBuffer.blit` +## `pygraphics.FrameBuffer.blit` ```python FrameBuffer.blit(source, x, y, key=-1, palette=None) @@ -187,9 +187,9 @@ FrameBuffer.blit(source, x, y, key=-1, palette=None) Copy another framebuffer onto the target with optional keying and palette lookup. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1098) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1098) -## `graphics.FrameBuffer.blit_rect` +## `pygraphics.FrameBuffer.blit_rect` ```python FrameBuffer.blit_rect(buffer, x, y, width, height) @@ -197,9 +197,9 @@ FrameBuffer.blit_rect(buffer, x, y, width, height) Copy a packed RGB565 rectangle onto the target. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1099) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1099) -## `graphics.FrameBuffer.blit_transparent` +## `pygraphics.FrameBuffer.blit_transparent` ```python FrameBuffer.blit_transparent(buffer, x, y, width, height, key) @@ -207,9 +207,9 @@ FrameBuffer.blit_transparent(buffer, x, y, width, height, key) Copy a packed RGB565 rectangle while skipping the transparent key. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1100) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1100) -## `graphics.FrameBuffer.text` +## `pygraphics.FrameBuffer.text` ```python FrameBuffer.text(text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8) @@ -217,9 +217,9 @@ FrameBuffer.text(text, x, y, color=1, scale=1, inverted=False, font_data=None, h Render bitmap text with selectable height, scale, and inversion. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1101) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1101) -## `graphics.FrameBuffer.text8` +## `pygraphics.FrameBuffer.text8` ```python FrameBuffer.text8(text, x, y, color=1, scale=1, inverted=False, font_data=None) @@ -227,9 +227,9 @@ FrameBuffer.text8(text, x, y, color=1, scale=1, inverted=False, font_data=None) Render text with the built-in 8-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1102) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1102) -## `graphics.FrameBuffer.text14` +## `pygraphics.FrameBuffer.text14` ```python FrameBuffer.text14(text, x, y, color=1, scale=1, inverted=False, font_data=None) @@ -237,9 +237,9 @@ FrameBuffer.text14(text, x, y, color=1, scale=1, inverted=False, font_data=None) Render text with the built-in 14-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1103) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1103) -## `graphics.FrameBuffer.text16` +## `pygraphics.FrameBuffer.text16` ```python FrameBuffer.text16(text, x, y, color=1, scale=1, inverted=False, font_data=None) @@ -247,9 +247,9 @@ FrameBuffer.text16(text, x, y, color=1, scale=1, inverted=False, font_data=None) Render text with the built-in 16-pixel-high font path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1104) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1104) -## `graphics.FrameBuffer.scroll` +## `pygraphics.FrameBuffer.scroll` ```python FrameBuffer.scroll(x_step, y_step) @@ -257,9 +257,9 @@ FrameBuffer.scroll(x_step, y_step) Move framebuffer contents by the requested x and y offsets. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1105) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1105) -## `graphics.FrameBuffer.save` +## `pygraphics.FrameBuffer.save` ```python FrameBuffer.save(path='screenshot') @@ -267,9 +267,9 @@ FrameBuffer.save(path='screenshot') Write the current image or bitmap to a versioned output path. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1106) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1106) -## `graphics.FrameBuffer.width` +## `pygraphics.FrameBuffer.width` ```python FrameBuffer.width @@ -277,9 +277,9 @@ FrameBuffer.width Width in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1073) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1073) -## `graphics.FrameBuffer.height` +## `pygraphics.FrameBuffer.height` ```python FrameBuffer.height @@ -287,9 +287,9 @@ FrameBuffer.height Height in pixels. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1074) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1074) -## `graphics.FrameBuffer.buffer` +## `pygraphics.FrameBuffer.buffer` ```python FrameBuffer.buffer @@ -297,9 +297,9 @@ FrameBuffer.buffer Backing pixel buffer when the object owns or exposes one. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1075) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1075) -## `graphics.FrameBuffer.format` +## `pygraphics.FrameBuffer.format` ```python FrameBuffer.format @@ -307,9 +307,9 @@ FrameBuffer.format Framebuffer pixel-format identifier. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1076) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1076) -## `graphics.FrameBuffer.color_depth` +## `pygraphics.FrameBuffer.color_depth` ```python FrameBuffer.color_depth @@ -317,4 +317,4 @@ FrameBuffer.color_depth Bits per pixel for the framebuffer format. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1077) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1077) diff --git a/docs/generated/introduction.md b/tools/sourcey-api/generated/introduction.md similarity index 51% rename from docs/generated/introduction.md rename to tools/sourcey-api/generated/introduction.md index 37b5b65..c67a31f 100644 --- a/docs/generated/introduction.md +++ b/tools/sourcey-api/generated/introduction.md @@ -1,14 +1,14 @@ --- title: graphics API reference -description: Source-linked Python and native C reference for the PyDevices graphics module. +description: Source-linked Python and native C reference for the PyDevices pygraphics module. --- -`graphics` is the all-C drawing module shared by CPython, MicroPython, and CircuitPython builds in the PyDevices stack. +`pygraphics` is the all-C drawing module shared by CPython, MicroPython, and CircuitPython builds in the PyDevices stack. ## Quick start ```python -from graphics import Area, FrameBuffer, RGB565 +from pygraphics import Area, FrameBuffer, RGB565 buffer = bytearray(160 * 128 * 2) canvas = FrameBuffer(buffer, 160, 128, RGB565) @@ -19,7 +19,7 @@ assert changed == Area(10, 10, 40, 24) ## Reference snapshot - Release line: **v0.0.25** -- Source commit: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd) +- Source commit: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd) - License: **MIT** - Adapter: **CPython binding tables plus public C headers** - Python API entries indexed: **136** @@ -31,10 +31,10 @@ The generated pages expose the user-facing Python names and the lower-level C en ## Browse the reference -- [Area and clipping](https://pydevices.github.io/graphics/api/generated/area-clipping.html) — 26 entries -- [FrameBuffer](https://pydevices.github.io/graphics/api/generated/framebuffer.html) — 31 entries -- [Drawing operations](https://pydevices.github.io/graphics/api/generated/drawing.html) — 46 entries -- [Fonts and images](https://pydevices.github.io/graphics/api/generated/fonts-images.html) — 22 entries -- [Runtime and pixel formats](https://pydevices.github.io/graphics/api/generated/module-formats.html) — 11 entries -- [Native drawing and framebuffer API](https://pydevices.github.io/graphics/api/generated/native-drawing.html) — 34 entries -- [Native fonts, images, and runtime API](https://pydevices.github.io/graphics/api/generated/native-assets-runtime.html) — 27 entries +- [Area and clipping](https://pydevices.github.io/pygraphics/api/generated/area-clipping.html) — 26 entries +- [FrameBuffer](https://pydevices.github.io/pygraphics/api/generated/framebuffer.html) — 31 entries +- [Drawing operations](https://pydevices.github.io/pygraphics/api/generated/drawing.html) — 46 entries +- [Fonts and images](https://pydevices.github.io/pygraphics/api/generated/fonts-images.html) — 22 entries +- [Runtime and pixel formats](https://pydevices.github.io/pygraphics/api/generated/module-formats.html) — 11 entries +- [Native drawing and framebuffer API](https://pydevices.github.io/pygraphics/api/generated/native-drawing.html) — 34 entries +- [Native fonts, images, and runtime API](https://pydevices.github.io/pygraphics/api/generated/native-assets-runtime.html) — 27 entries diff --git a/docs/generated/manifest.json b/tools/sourcey-api/generated/manifest.json similarity index 72% rename from docs/generated/manifest.json rename to tools/sourcey-api/generated/manifest.json index a374390..0a4f64a 100644 --- a/docs/generated/manifest.json +++ b/tools/sourcey-api/generated/manifest.json @@ -68,7 +68,7 @@ ], "python_symbol_count": 136, "release": "v0.0.25", - "repository": "https://github.com/PyDevices/graphics", + "repository": "https://github.com/PyDevices/pygraphics", "repository_native_source_file_count": 31, "schema": "pydevices-graphics-sourcey-reference.v1", "source_file_count": 7, @@ -88,9 +88,9 @@ "line": 395, "name": "Area", "path": "src/gfx_module_cpy.c", - "qualified_name": "graphics.Area", + "qualified_name": "pygraphics.Area", "signature": "class Area(x=0, y=0, w=0, h=0)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L395", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L395", "summary": "Immutable rectangle geometry used for bounds, clipping, and draw results." }, { @@ -101,7 +101,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.contains", "signature": "Area.contains(point_or_x, y=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L377", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L377", "summary": "Test whether the area contains a point." }, { @@ -112,7 +112,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.contains_area", "signature": "Area.contains_area(other)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L378", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L378", "summary": "Test whether another Area is fully contained." }, { @@ -123,7 +123,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.intersects", "signature": "Area.intersects(other)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L379", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L379", "summary": "Test whether two areas overlap." }, { @@ -134,7 +134,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.touches_or_intersects", "signature": "Area.touches_or_intersects(other)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L380", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L380", "summary": "Test whether two areas overlap or share an edge." }, { @@ -145,7 +145,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.shift", "signature": "Area.shift(dx=0, dy=0)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L381", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L381", "summary": "Return a copy translated by the requested offset." }, { @@ -156,7 +156,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.clip", "signature": "Area.clip(other)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L382", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L382", "summary": "Return the intersection with another Area." }, { @@ -167,7 +167,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.offset", "signature": "Area.offset(left, top=None, right=None, bottom=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L383", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L383", "summary": "Return an Area expanded independently on each edge." }, { @@ -178,7 +178,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.inset", "signature": "Area.inset(left, top=None, right=None, bottom=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L384", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L384", "summary": "Return an Area reduced independently on each edge." }, { @@ -189,7 +189,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.x", "signature": "Area.x", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L229", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L229", "summary": "Left coordinate." }, { @@ -200,7 +200,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.y", "signature": "Area.y", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L230", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L230", "summary": "Top coordinate." }, { @@ -211,7 +211,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.w", "signature": "Area.w", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L231", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L231", "summary": "Width in pixels." }, { @@ -222,7 +222,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Area.h", "signature": "Area.h", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L232", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L232", "summary": "Height in pixels." }, { @@ -232,7 +232,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClipContext", "signature": "class ClipContext(draw, area)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2147", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2147", "summary": "Context manager returned by Draw.clip() for scoped clipping." }, { @@ -243,7 +243,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClipContext.__enter__", "signature": "ClipContext.__enter__()", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2140", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2140", "summary": "Push the requested clipping area and return the effective clip." }, { @@ -254,7 +254,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClipContext.__exit__", "signature": "ClipContext.__exit__(exc_type, exc_value, traceback)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2141", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2141", "summary": "Pop the clipping area when leaving the context." }, { @@ -264,7 +264,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas", "signature": "class ClippedCanvas(canvas, clip)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2414", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2414", "summary": "Canvas proxy that intersects writes with a fixed Area." }, { @@ -275,7 +275,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.pixel", "signature": "ClippedCanvas.pixel(x, y, color=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2402", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2402", "summary": "Read or write one pixel, depending on whether a color is supplied." }, { @@ -286,7 +286,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.fill", "signature": "ClippedCanvas.fill(color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2403", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2403", "summary": "Fill the target canvas with one color and return the affected Area." }, { @@ -297,7 +297,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.fill_rect", "signature": "ClippedCanvas.fill_rect(x, y, width, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2404", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2404", "summary": "Fill a rectangular region and return the clipped affected Area." }, { @@ -308,7 +308,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.hline", "signature": "ClippedCanvas.hline(x, y, width, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2405", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2405", "summary": "Draw a horizontal line." }, { @@ -319,7 +319,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.vline", "signature": "ClippedCanvas.vline(x, y, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2406", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2406", "summary": "Draw a vertical line." }, { @@ -330,7 +330,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.blit_rect", "signature": "ClippedCanvas.blit_rect(buffer, x, y, width, height)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2407", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2407", "summary": "Copy a packed RGB565 rectangle onto the target." }, { @@ -341,7 +341,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.blit_transparent", "signature": "ClippedCanvas.blit_transparent(buffer, x, y, width, height, key)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2408", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2408", "summary": "Copy a packed RGB565 rectangle while skipping the transparent key." }, { @@ -352,7 +352,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.width", "signature": "ClippedCanvas.width", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2223", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2223", "summary": "Width in pixels." }, { @@ -363,7 +363,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ClippedCanvas.height", "signature": "ClippedCanvas.height", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2224", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2224", "summary": "Height in pixels." }, { @@ -373,7 +373,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer", "signature": "class FrameBuffer(buffer, width, height, format, stride=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1112", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1112", "summary": "A framebuf-compatible native drawing surface backed by a writable buffer." }, { @@ -384,7 +384,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.from_file", "signature": "FrameBuffer.from_file(path)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1082", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1082", "summary": "Load a supported image file into a new FrameBuffer." }, { @@ -395,7 +395,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.fill", "signature": "FrameBuffer.fill(color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1083", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1083", "summary": "Fill the target canvas with one color and return the affected Area." }, { @@ -406,7 +406,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.fill_rect", "signature": "FrameBuffer.fill_rect(x, y, width, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1084", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1084", "summary": "Fill a rectangular region and return the clipped affected Area." }, { @@ -417,7 +417,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.pixel", "signature": "FrameBuffer.pixel(x, y, color=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1085", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1085", "summary": "Read or write one pixel, depending on whether a color is supplied." }, { @@ -428,7 +428,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.hline", "signature": "FrameBuffer.hline(x, y, width, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1086", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1086", "summary": "Draw a horizontal line." }, { @@ -439,7 +439,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.vline", "signature": "FrameBuffer.vline(x, y, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1087", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1087", "summary": "Draw a vertical line." }, { @@ -450,7 +450,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.rect", "signature": "FrameBuffer.rect(x, y, width, height, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1088", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1088", "summary": "Draw an outlined or filled rectangle." }, { @@ -461,7 +461,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.round_rect", "signature": "FrameBuffer.round_rect(x, y, width, height, radius, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1089", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1089", "summary": "Draw an outlined or filled rounded rectangle." }, { @@ -472,7 +472,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.circle", "signature": "FrameBuffer.circle(x, y, radius, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1090", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1090", "summary": "Draw an outlined or filled circle." }, { @@ -483,7 +483,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.line", "signature": "FrameBuffer.line(x1, y1, x2, y2, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1091", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1091", "summary": "Draw a line between two points." }, { @@ -494,7 +494,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.ellipse", "signature": "FrameBuffer.ellipse(x, y, x_radius, y_radius, color, fill=False, mask=0x0F)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1092", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1092", "summary": "Draw selected quadrants of an outlined or filled ellipse." }, { @@ -505,7 +505,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.poly", "signature": "FrameBuffer.poly(x, y, coordinates, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1093", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1093", "summary": "Draw a polygon from a packed coordinate buffer." }, { @@ -516,7 +516,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.arc", "signature": "FrameBuffer.arc(x, y, radius, start_angle, end_angle, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1094", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1094", "summary": "Draw a circular arc between two angles." }, { @@ -527,7 +527,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.triangle", "signature": "FrameBuffer.triangle(x0, y0, x1, y1, x2, y2, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1095", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1095", "summary": "Draw an outlined or filled triangle." }, { @@ -538,7 +538,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.gradient_rect", "signature": "FrameBuffer.gradient_rect(x, y, width, height, color1, color2=None, vertical=True)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1096", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1096", "summary": "Fill a rectangle with a horizontal or vertical color gradient." }, { @@ -549,7 +549,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.polygon", "signature": "FrameBuffer.polygon(points, x, y, color, angle=0, center_x=0, center_y=0)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1097", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1097", "summary": "Draw a translated and optionally rotated sequence of points." }, { @@ -560,7 +560,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.blit", "signature": "FrameBuffer.blit(source, x, y, key=-1, palette=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1098", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1098", "summary": "Copy another framebuffer onto the target with optional keying and palette lookup." }, { @@ -571,7 +571,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.blit_rect", "signature": "FrameBuffer.blit_rect(buffer, x, y, width, height)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1099", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1099", "summary": "Copy a packed RGB565 rectangle onto the target." }, { @@ -582,7 +582,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.blit_transparent", "signature": "FrameBuffer.blit_transparent(buffer, x, y, width, height, key)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1100", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1100", "summary": "Copy a packed RGB565 rectangle while skipping the transparent key." }, { @@ -593,7 +593,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.text", "signature": "FrameBuffer.text(text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1101", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1101", "summary": "Render bitmap text with selectable height, scale, and inversion." }, { @@ -604,7 +604,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.text8", "signature": "FrameBuffer.text8(text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1102", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1102", "summary": "Render text with the built-in 8-pixel-high font path." }, { @@ -615,7 +615,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.text14", "signature": "FrameBuffer.text14(text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1103", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1103", "summary": "Render text with the built-in 14-pixel-high font path." }, { @@ -626,7 +626,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.text16", "signature": "FrameBuffer.text16(text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1104", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1104", "summary": "Render text with the built-in 16-pixel-high font path." }, { @@ -637,7 +637,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.scroll", "signature": "FrameBuffer.scroll(x_step, y_step)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1105", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1105", "summary": "Move framebuffer contents by the requested x and y offsets." }, { @@ -648,7 +648,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.save", "signature": "FrameBuffer.save(path='screenshot')", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1106", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1106", "summary": "Write the current image or bitmap to a versioned output path." }, { @@ -659,7 +659,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.width", "signature": "FrameBuffer.width", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1073", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1073", "summary": "Width in pixels." }, { @@ -670,7 +670,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.height", "signature": "FrameBuffer.height", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1074", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1074", "summary": "Height in pixels." }, { @@ -681,7 +681,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.buffer", "signature": "FrameBuffer.buffer", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1075", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1075", "summary": "Backing pixel buffer when the object owns or exposes one." }, { @@ -692,7 +692,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.format", "signature": "FrameBuffer.format", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1076", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1076", "summary": "Framebuffer pixel-format identifier." }, { @@ -703,7 +703,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.FrameBuffer.color_depth", "signature": "FrameBuffer.color_depth", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1077", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L1077", "summary": "Bits per pixel for the framebuffer format." }, { @@ -711,9 +711,9 @@ "line": 2085, "name": "Draw", "path": "src/gfx_module_cpy.c", - "qualified_name": "graphics.Draw", + "qualified_name": "pygraphics.Draw", "signature": "class Draw(canvas)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2085", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2085", "summary": "Drawing facade that adds a bounded clip stack to any compatible canvas." }, { @@ -724,7 +724,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.fill", "signature": "Draw.fill(color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2057", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2057", "summary": "Fill the target canvas with one color and return the affected Area." }, { @@ -735,7 +735,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.fill_rect", "signature": "Draw.fill_rect(x, y, width, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2058", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2058", "summary": "Fill a rectangular region and return the clipped affected Area." }, { @@ -746,7 +746,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.pixel", "signature": "Draw.pixel(x, y, color=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2059", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2059", "summary": "Read or write one pixel, depending on whether a color is supplied." }, { @@ -757,7 +757,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.hline", "signature": "Draw.hline(x, y, width, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2060", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2060", "summary": "Draw a horizontal line." }, { @@ -768,7 +768,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.vline", "signature": "Draw.vline(x, y, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2061", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2061", "summary": "Draw a vertical line." }, { @@ -779,7 +779,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.line", "signature": "Draw.line(x1, y1, x2, y2, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2062", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2062", "summary": "Draw a line between two points." }, { @@ -790,7 +790,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.rect", "signature": "Draw.rect(x, y, width, height, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2063", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2063", "summary": "Draw an outlined or filled rectangle." }, { @@ -801,7 +801,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.round_rect", "signature": "Draw.round_rect(x, y, width, height, radius, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2064", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2064", "summary": "Draw an outlined or filled rounded rectangle." }, { @@ -812,7 +812,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.circle", "signature": "Draw.circle(x, y, radius, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2065", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2065", "summary": "Draw an outlined or filled circle." }, { @@ -823,7 +823,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.ellipse", "signature": "Draw.ellipse(x, y, x_radius, y_radius, color, fill=False, mask=0x0F)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2066", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2066", "summary": "Draw selected quadrants of an outlined or filled ellipse." }, { @@ -834,7 +834,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.arc", "signature": "Draw.arc(x, y, radius, start_angle, end_angle, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2067", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2067", "summary": "Draw a circular arc between two angles." }, { @@ -845,7 +845,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.triangle", "signature": "Draw.triangle(x0, y0, x1, y1, x2, y2, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2068", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2068", "summary": "Draw an outlined or filled triangle." }, { @@ -856,7 +856,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.gradient_rect", "signature": "Draw.gradient_rect(x, y, width, height, color1, color2=None, vertical=True)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2069", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2069", "summary": "Fill a rectangle with a horizontal or vertical color gradient." }, { @@ -867,7 +867,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.poly", "signature": "Draw.poly(x, y, coordinates, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2070", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2070", "summary": "Draw a polygon from a packed coordinate buffer." }, { @@ -878,7 +878,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.polygon", "signature": "Draw.polygon(points, x, y, color, angle=0, center_x=0, center_y=0)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2071", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2071", "summary": "Draw a translated and optionally rotated sequence of points." }, { @@ -889,7 +889,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.blit", "signature": "Draw.blit(source, x, y, key=-1, palette=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2072", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2072", "summary": "Copy another framebuffer onto the target with optional keying and palette lookup." }, { @@ -900,7 +900,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.blit_rect", "signature": "Draw.blit_rect(buffer, x, y, width, height)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2073", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2073", "summary": "Copy a packed RGB565 rectangle onto the target." }, { @@ -911,7 +911,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.blit_transparent", "signature": "Draw.blit_transparent(buffer, x, y, width, height, key)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2074", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2074", "summary": "Copy a packed RGB565 rectangle while skipping the transparent key." }, { @@ -922,7 +922,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.text", "signature": "Draw.text(text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2075", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2075", "summary": "Render bitmap text with selectable height, scale, and inversion." }, { @@ -933,7 +933,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.text8", "signature": "Draw.text8(text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2076", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2076", "summary": "Render text with the built-in 8-pixel-high font path." }, { @@ -944,7 +944,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.text14", "signature": "Draw.text14(text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2077", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2077", "summary": "Render text with the built-in 14-pixel-high font path." }, { @@ -955,7 +955,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.text16", "signature": "Draw.text16(text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2078", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2078", "summary": "Render text with the built-in 16-pixel-high font path." }, { @@ -966,7 +966,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Draw.clip", "signature": "Draw.clip(area_or_x, y=None, width=None, height=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2079", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2079", "summary": "Return the intersection with another Area." }, { @@ -977,7 +977,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.fill", "signature": "graphics.fill(canvas, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2953", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2953", "summary": "Fill the target canvas with one color and return the affected Area." }, { @@ -988,7 +988,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.fill_rect", "signature": "graphics.fill_rect(canvas, x, y, width, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2954", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2954", "summary": "Fill a rectangular region and return the clipped affected Area." }, { @@ -999,7 +999,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.pixel", "signature": "graphics.pixel(canvas, x, y, color=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2955", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2955", "summary": "Read or write one pixel, depending on whether a color is supplied." }, { @@ -1010,7 +1010,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.hline", "signature": "graphics.hline(canvas, x, y, width, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2956", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2956", "summary": "Draw a horizontal line." }, { @@ -1021,7 +1021,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.vline", "signature": "graphics.vline(canvas, x, y, height, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2957", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2957", "summary": "Draw a vertical line." }, { @@ -1032,7 +1032,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.line", "signature": "graphics.line(canvas, x1, y1, x2, y2, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2958", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2958", "summary": "Draw a line between two points." }, { @@ -1043,7 +1043,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.rect", "signature": "graphics.rect(canvas, x, y, width, height, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2959", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2959", "summary": "Draw an outlined or filled rectangle." }, { @@ -1054,7 +1054,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.round_rect", "signature": "graphics.round_rect(canvas, x, y, width, height, radius, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2960", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2960", "summary": "Draw an outlined or filled rounded rectangle." }, { @@ -1065,7 +1065,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.circle", "signature": "graphics.circle(canvas, x, y, radius, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2961", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2961", "summary": "Draw an outlined or filled circle." }, { @@ -1076,7 +1076,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.ellipse", "signature": "graphics.ellipse(canvas, x, y, x_radius, y_radius, color, fill=False, mask=0x0F)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2962", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2962", "summary": "Draw selected quadrants of an outlined or filled ellipse." }, { @@ -1087,7 +1087,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.arc", "signature": "graphics.arc(canvas, x, y, radius, start_angle, end_angle, color)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2963", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2963", "summary": "Draw a circular arc between two angles." }, { @@ -1098,7 +1098,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.triangle", "signature": "graphics.triangle(canvas, x0, y0, x1, y1, x2, y2, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2964", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2964", "summary": "Draw an outlined or filled triangle." }, { @@ -1109,7 +1109,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.gradient_rect", "signature": "graphics.gradient_rect(canvas, x, y, width, height, color1, color2=None, vertical=True)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2965", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2965", "summary": "Fill a rectangle with a horizontal or vertical color gradient." }, { @@ -1120,7 +1120,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.poly", "signature": "graphics.poly(canvas, x, y, coordinates, color, fill=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2966", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2966", "summary": "Draw a polygon from a packed coordinate buffer." }, { @@ -1131,7 +1131,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.blit", "signature": "graphics.blit(canvas, source, x, y, key=-1, palette=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2967", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2967", "summary": "Copy another framebuffer onto the target with optional keying and palette lookup." }, { @@ -1142,7 +1142,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.blit_rect", "signature": "graphics.blit_rect(canvas, buffer, x, y, width, height)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2968", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2968", "summary": "Copy a packed RGB565 rectangle onto the target." }, { @@ -1153,7 +1153,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.blit_transparent", "signature": "graphics.blit_transparent(canvas, buffer, x, y, width, height, key)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2969", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2969", "summary": "Copy a packed RGB565 rectangle while skipping the transparent key." }, { @@ -1164,7 +1164,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.polygon", "signature": "graphics.polygon(canvas, points, x, y, color, angle=0, center_x=0, center_y=0)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2970", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2970", "summary": "Draw a translated and optionally rotated sequence of points." }, { @@ -1175,7 +1175,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.text", "signature": "graphics.text(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None, height=8)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2976", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2976", "summary": "Render bitmap text with selectable height, scale, and inversion." }, { @@ -1186,7 +1186,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.text8", "signature": "graphics.text8(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2977", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2977", "summary": "Render text with the built-in 8-pixel-high font path." }, { @@ -1197,7 +1197,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.text14", "signature": "graphics.text14(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2978", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2978", "summary": "Render text with the built-in 14-pixel-high font path." }, { @@ -1208,7 +1208,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.text16", "signature": "graphics.text16(canvas, text, x, y, color=1, scale=1, inverted=False, font_data=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2979", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2979", "summary": "Render text with the built-in 16-pixel-high font path." }, { @@ -1216,9 +1216,9 @@ "line": 2643, "name": "Font", "path": "src/gfx_module_cpy.c", - "qualified_name": "graphics.Font", + "qualified_name": "pygraphics.Font", "signature": "class Font(font_data=None, height=0, cached=True)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2643", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2643", "summary": "Bitmap font loader and renderer for built-in, file, or buffer-backed glyph data." }, { @@ -1229,7 +1229,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.text", "signature": "Font.text(canvas, text, x, y, color, scale=1, inverted=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2633", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2633", "summary": "Render bitmap text with selectable height, scale, and inversion." }, { @@ -1240,7 +1240,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.draw_char", "signature": "Font.draw_char(char, x, y, canvas, color, scale=1, inverted=False)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2634", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2634", "summary": "Render one glyph through this Font onto a canvas." }, { @@ -1251,7 +1251,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.text_width", "signature": "Font.text_width(text, scale=1)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2635", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2635", "summary": "Measure rendered text width at the selected scale." }, { @@ -1262,7 +1262,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.deinit", "signature": "Font.deinit()", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2636", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2636", "summary": "Release resources owned by the object." }, { @@ -1273,7 +1273,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.export", "signature": "Font.export(filename)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2637", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2637", "summary": "Write cached font bytes to a file." }, { @@ -1284,7 +1284,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.width", "signature": "Font.width", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2626", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2626", "summary": "Width in pixels." }, { @@ -1295,7 +1295,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.height", "signature": "Font.height", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2627", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2627", "summary": "Height in pixels." }, { @@ -1306,7 +1306,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.Font.font_name", "signature": "Font.font_name", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2628", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2628", "summary": "Font source name or the in-memory/default identifier." }, { @@ -1316,7 +1316,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565", "signature": "class BMP565(filename=None, source=None, streamed=False, mirrored=False, width=None, height=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2934", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2934", "summary": "RGB565 bitmap reader supporting buffered and streamed access." }, { @@ -1327,7 +1327,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565.save", "signature": "BMP565.save(filename=None)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2923", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2923", "summary": "Write the current image or bitmap to a versioned output path." }, { @@ -1338,7 +1338,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565.deinit", "signature": "BMP565.deinit()", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2924", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2924", "summary": "Release resources owned by the object." }, { @@ -1349,7 +1349,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565.width", "signature": "BMP565.width", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2914", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2914", "summary": "Width in pixels." }, { @@ -1360,7 +1360,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565.height", "signature": "BMP565.height", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2915", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2915", "summary": "Height in pixels." }, { @@ -1371,7 +1371,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565.buffer", "signature": "BMP565.buffer", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2916", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2916", "summary": "Backing pixel buffer when the object owns or exposes one." }, { @@ -1382,7 +1382,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565.bpp", "signature": "BMP565.bpp", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2917", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2917", "summary": "Bitmap color depth in bits per pixel." }, { @@ -1393,7 +1393,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.BMP565.BPP", "signature": "BMP565.BPP", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2918", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2918", "summary": "Bitmap storage width in bytes per pixel." }, { @@ -1404,7 +1404,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.load_image", "signature": "graphics.load_image(path)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2971", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2971", "summary": "Load a supported image file as a FrameBuffer." }, { @@ -1415,7 +1415,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.save_image", "signature": "graphics.save_image(framebuffer, path='screenshot')", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2972", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2972", "summary": "Save a FrameBuffer to a versioned image path." }, { @@ -1426,7 +1426,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.bmp_to_framebuffer", "signature": "graphics.bmp_to_framebuffer(path)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2973", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2973", "summary": "Decode a BMP file into a FrameBuffer." }, { @@ -1437,7 +1437,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.pbm_to_framebuffer", "signature": "graphics.pbm_to_framebuffer(path)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2974", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2974", "summary": "Decode a PBM file into a FrameBuffer." }, { @@ -1448,7 +1448,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.pgm_to_framebuffer", "signature": "graphics.pgm_to_framebuffer(path)", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2975", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2975", "summary": "Decode a PGM file into a FrameBuffer." }, { @@ -1457,9 +1457,9 @@ "line": 2950, "name": "framebuf_backend", "path": "src/gfx_module_cpy.c", - "qualified_name": "graphics.framebuf_backend", - "signature": "graphics.framebuf_backend()", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2950", + "qualified_name": "pygraphics.framebuf_backend", + "signature": "pygraphics.framebuf_backend()", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2950", "summary": "Return the active framebuffer backend identifier." }, { @@ -1469,8 +1469,8 @@ "name": "implementation", "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.implementation", - "signature": "graphics.implementation()", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2951", + "signature": "pygraphics.implementation()", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2951", "summary": "Return the implementation identifier for this graphics module." }, { @@ -1481,7 +1481,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.capabilities", "signature": "graphics.capabilities()", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2952", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2952", "summary": "Return structured runtime feature and pixel-format capabilities." }, { @@ -1492,7 +1492,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.MONO_VLSB", "signature": "graphics.MONO_VLSB", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3027", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3027", "summary": "Monochrome vertical least-significant-bit layout." }, { @@ -1503,7 +1503,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.MONO_HLSB", "signature": "graphics.MONO_HLSB", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3028", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3028", "summary": "Monochrome horizontal least-significant-bit layout." }, { @@ -1514,7 +1514,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.MONO_HMSB", "signature": "graphics.MONO_HMSB", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3029", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3029", "summary": "Monochrome horizontal most-significant-bit layout." }, { @@ -1525,7 +1525,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.RGB565", "signature": "graphics.RGB565", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3030", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3030", "summary": "16-bit RGB565 pixel layout." }, { @@ -1536,7 +1536,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.GS2_HMSB", "signature": "graphics.GS2_HMSB", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3031", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3031", "summary": "2-bit grayscale horizontal most-significant-bit layout." }, { @@ -1547,7 +1547,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.GS4_HMSB", "signature": "graphics.GS4_HMSB", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3032", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3032", "summary": "4-bit grayscale horizontal most-significant-bit layout." }, { @@ -1558,7 +1558,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.GS8", "signature": "graphics.GS8", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3033", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3033", "summary": "8-bit grayscale layout." }, { @@ -1569,7 +1569,7 @@ "path": "src/gfx_module_cpy.c", "qualified_name": "graphics.RGB888", "signature": "graphics.RGB888", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3034", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3034", "summary": "24-bit RGB888 pixel layout." }, { @@ -1579,7 +1579,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_validate_buffer", "signature": "int gfx_fb_validate_buffer(size_t buf_len, int width, int height, int format, int stride);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L21", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L21", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1589,7 +1589,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_color_depth", "signature": "int gfx_fb_color_depth(int format);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L22", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L22", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1599,7 +1599,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_setpixel", "signature": "void gfx_fb_setpixel(const gfx_fb_t *fb, unsigned int x, unsigned int y, uint32_t col);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L24", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L24", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1609,7 +1609,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_getpixel", "signature": "uint32_t gfx_fb_getpixel(const gfx_fb_t *fb, unsigned int x, unsigned int y);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L25", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L25", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1619,7 +1619,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_setpixel_checked", "signature": "void gfx_fb_setpixel_checked(const gfx_fb_t *fb, int x, int y, int col, int mask);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L26", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L26", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1629,7 +1629,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_fill_rect_raw", "signature": "void gfx_fb_fill_rect_raw(const gfx_fb_t *fb, int x, int y, int w, int h, uint32_t col);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L27", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L27", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1639,7 +1639,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_fill_rect", "signature": "gfx_area_t gfx_fb_fill_rect(const gfx_fb_t *fb, int x, int y, int w, int h, uint32_t col);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L28", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L28", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1649,7 +1649,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_fill", "signature": "gfx_area_t gfx_fb_fill(const gfx_fb_t *fb, uint32_t col);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L29", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L29", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1659,7 +1659,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_canvas_init", "signature": "void gfx_fb_canvas_init(gfx_canvas_t *canvas, const gfx_fb_t *fb);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L31", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L31", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1669,7 +1669,7 @@ "path": "src/gfx_framebuffer.h", "qualified_name": "gfx_fb_scroll", "signature": "void gfx_fb_scroll(gfx_fb_t *fb, int xstep, int ystep);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L32", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L32", "summary": "Native fb entry point declared for firmware and extension integration." }, { @@ -1679,7 +1679,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_clipped_canvas_init", "signature": "void gfx_clipped_canvas_init(gfx_clipped_canvas_t *cc, const gfx_canvas_t *parent, const gfx_area_t *clip);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L20", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L20", "summary": "Native clipped entry point declared for firmware and extension integration." }, { @@ -1689,7 +1689,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_pixel", "signature": "gfx_area_t gfx_shapes_pixel(const gfx_canvas_t *canvas, int x, int y, int c);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L22", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L22", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1699,7 +1699,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_hline", "signature": "gfx_area_t gfx_shapes_hline(const gfx_canvas_t *canvas, int x, int y, int w, int c);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L23", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L23", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1709,7 +1709,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_vline", "signature": "gfx_area_t gfx_shapes_vline(const gfx_canvas_t *canvas, int x, int y, int h, int c);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L24", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L24", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1719,7 +1719,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_fill_rect", "signature": "gfx_area_t gfx_shapes_fill_rect(const gfx_canvas_t *canvas, int x, int y, int w, int h, int c);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L25", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L25", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1729,7 +1729,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_rect", "signature": "gfx_area_t gfx_shapes_rect(const gfx_canvas_t *canvas, int x, int y, int w, int h, int c, int fill);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L26", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L26", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1739,7 +1739,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_line", "signature": "gfx_area_t gfx_shapes_line(const gfx_canvas_t *canvas, int x1, int y1, int x2, int y2, int c);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L27", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L27", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1749,7 +1749,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_ellipse", "signature": "gfx_area_t gfx_shapes_ellipse(const gfx_canvas_t *canvas, int cx, int cy, int xradius, int yradius, int col, int fill, int mask_part);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L28", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L28", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1759,7 +1759,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_fill", "signature": "gfx_area_t gfx_shapes_fill(const gfx_canvas_t *canvas, int c);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L29", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L29", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1769,7 +1769,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_poly_int_from_buffer", "signature": "int gfx_shapes_poly_int_from_buffer(const void *buf, size_t len, size_t itemsize, const char *fmt, size_t index, int *out);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L31", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L31", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1779,7 +1779,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_poly", "signature": "gfx_area_t gfx_shapes_poly(const gfx_canvas_t *canvas, int x, int y, const void *coords, size_t coords_len, size_t itemsize, const char *fmt, int col, int fill);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L32", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L32", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1789,7 +1789,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_blit", "signature": "gfx_area_t gfx_shapes_blit(const gfx_canvas_t *canvas, const gfx_fb_t *source, int x, int y, int key, const gfx_fb_t *palette);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L33", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L33", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1799,7 +1799,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_circle", "signature": "gfx_area_t gfx_shapes_circle(const gfx_canvas_t *canvas, int x0, int y0, int r, int c, int fill);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L34", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L34", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1809,7 +1809,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_round_rect", "signature": "gfx_area_t gfx_shapes_round_rect(const gfx_canvas_t *canvas, int x0, int y0, int w, int h, int r, int c, int fill);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L35", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L35", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1819,7 +1819,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_triangle", "signature": "gfx_area_t gfx_shapes_triangle(const gfx_canvas_t *canvas, int x0, int y0, int x1, int y1, int x2, int y2, int c, int fill);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L36", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L36", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1829,7 +1829,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_arc", "signature": "gfx_area_t gfx_shapes_arc(const gfx_canvas_t *canvas, int x, int y, int r, float a0, float a1, int c);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L37", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L37", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1839,7 +1839,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_gradient_rect", "signature": "gfx_area_t gfx_shapes_gradient_rect(const gfx_canvas_t *canvas, int x, int y, int w, int h, int c1, int c2, int vertical);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L38", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L38", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1849,7 +1849,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_blit_rect", "signature": "gfx_area_t gfx_shapes_blit_rect(const gfx_canvas_t *canvas, const void *buf, int x, int y, int w, int h, int bpp);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L39", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L39", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1859,7 +1859,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_blit_transparent", "signature": "gfx_area_t gfx_shapes_blit_transparent(const gfx_canvas_t *canvas, const void *buf, int x, int y, int w, int h, int key, int bpp);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L40", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L40", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1869,7 +1869,7 @@ "path": "src/gfx_shapes.h", "qualified_name": "gfx_shapes_polygon", "signature": "gfx_area_t gfx_shapes_polygon(const gfx_canvas_t *canvas, const int *points, size_t n_points, int x, int y, int color, float angle, int center_x, int center_y);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L41", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L41", "summary": "Native shapes entry point declared for firmware and extension integration." }, { @@ -1879,7 +1879,7 @@ "path": "src/gfx_draw.h", "qualified_name": "gfx_draw_init", "signature": "void gfx_draw_init(gfx_draw_t *draw, const gfx_canvas_t *canvas);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L21", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L21", "summary": "Native draw entry point declared for firmware and extension integration." }, { @@ -1889,7 +1889,7 @@ "path": "src/gfx_draw.h", "qualified_name": "gfx_draw_effective_clip", "signature": "gfx_area_t gfx_draw_effective_clip(const gfx_draw_t *draw);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L23", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L23", "summary": "Native draw entry point declared for firmware and extension integration." }, { @@ -1899,7 +1899,7 @@ "path": "src/gfx_draw.h", "qualified_name": "gfx_draw_push_clip", "signature": "void gfx_draw_push_clip(gfx_draw_t *draw, const gfx_area_t *clip);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L24", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L24", "summary": "Native draw entry point declared for firmware and extension integration." }, { @@ -1909,7 +1909,7 @@ "path": "src/gfx_draw.h", "qualified_name": "gfx_draw_pop_clip", "signature": "void gfx_draw_pop_clip(gfx_draw_t *draw);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L25", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L25", "summary": "Native draw entry point declared for firmware and extension integration." }, { @@ -1919,7 +1919,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_init_default", "signature": "void gfx_font_init_default(gfx_font_t *font, int height);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L22", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L22", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1929,7 +1929,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_init_from_data", "signature": "void gfx_font_init_from_data(gfx_font_t *font, const uint8_t *data, size_t len, int height);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L23", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L23", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1939,7 +1939,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_deinit", "signature": "void gfx_font_deinit(gfx_font_t *font);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L24", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L24", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1949,7 +1949,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_export", "signature": "int gfx_font_export(const gfx_font_t *font, const char *filename);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L26", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L26", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1959,7 +1959,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_text", "signature": "gfx_area_t gfx_font_text(const gfx_canvas_t *canvas, const gfx_font_t *font, const char *str, int x0, int y0, int col, int scale, int inverted);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L29", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L29", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1969,7 +1969,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_draw_char", "signature": "gfx_area_t gfx_font_draw_char(const gfx_canvas_t *canvas, const gfx_font_t *font, unsigned char ch, int x, int y, int color, int scale, int inverted);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L30", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L30", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1979,7 +1979,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_text_width", "signature": "int gfx_font_text_width(const gfx_font_t *font, const char *str, int scale);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L31", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L31", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1989,7 +1989,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_text8", "signature": "gfx_area_t gfx_font_text8(const gfx_canvas_t *canvas, const char *str, int x0, int y0, int col);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L32", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L32", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -1999,7 +1999,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_text14", "signature": "gfx_area_t gfx_font_text14(const gfx_canvas_t *canvas, const char *str, int x0, int y0, int col);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L33", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L33", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -2009,7 +2009,7 @@ "path": "src/gfx_font.h", "qualified_name": "gfx_font_text16", "signature": "gfx_area_t gfx_font_text16(const gfx_canvas_t *canvas, const char *str, int x0, int y0, int col);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L34", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L34", "summary": "Native font entry point declared for firmware and extension integration." }, { @@ -2019,7 +2019,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_read_header_from_file", "signature": "int gfx_bmp565_read_header_from_file(const char *path, int *width, int *height, unsigned int *data_offset);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L27", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L27", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2029,7 +2029,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_open_stream", "signature": "int gfx_bmp565_open_stream(const char *path, gfx_bmp565_t *out);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L28", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L28", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2039,7 +2039,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_load_from_file", "signature": "int gfx_bmp565_load_from_file(const char *path, gfx_bmp565_t *out);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L29", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L29", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2049,7 +2049,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_init_from_buffer", "signature": "int gfx_bmp565_init_from_buffer(gfx_bmp565_t *out, const uint8_t *buf, size_t len, int width, int height);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L30", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L30", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2059,7 +2059,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_deinit", "signature": "void gfx_bmp565_deinit(gfx_bmp565_t *bmp);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L31", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L31", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2069,7 +2069,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_save", "signature": "int gfx_bmp565_save(const gfx_bmp565_t *bmp, const char *path);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L32", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L32", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2079,7 +2079,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_save_versioned", "signature": "int gfx_bmp565_save_versioned(const gfx_bmp565_t *bmp, const char *path, char *out_path, size_t out_path_len);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L33", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L33", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2089,7 +2089,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_read_bytes", "signature": "int gfx_bmp565_read_bytes(const gfx_bmp565_t *bmp, int start, int stop, uint8_t *out, size_t out_cap, size_t *out_len);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L34", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L34", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2099,7 +2099,7 @@ "path": "src/gfx_bmp565.h", "qualified_name": "gfx_bmp565_read_region", "signature": "int gfx_bmp565_read_region(const gfx_bmp565_t *bmp, int x0, int x1, int y0, int y1, uint8_t *out, size_t out_cap, size_t *out_len);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L35", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L35", "summary": "Native bmp565 entry point declared for firmware and extension integration." }, { @@ -2109,7 +2109,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_image_probe", "signature": "int gfx_image_probe(const uint8_t *data, size_t len, gfx_image_info_t *info);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L43", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L43", "summary": "Native image entry point declared for firmware and extension integration." }, { @@ -2119,7 +2119,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_image_decode", "signature": "int gfx_image_decode(const uint8_t *data, size_t len, const gfx_image_info_t *info, uint8_t *dst, size_t dst_len);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L47", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L47", "summary": "Native image entry point declared for firmware and extension integration." }, { @@ -2129,7 +2129,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_image_fb_free", "signature": "void gfx_image_fb_free(gfx_image_fb_t *img);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L64", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L64", "summary": "Native image entry point declared for firmware and extension integration." }, { @@ -2139,7 +2139,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_files_load_image", "signature": "int gfx_files_load_image(const char *path, gfx_image_fb_t *out);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L65", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L65", "summary": "Native files entry point declared for firmware and extension integration." }, { @@ -2149,7 +2149,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_files_save_image", "signature": "int gfx_files_save_image(const gfx_fb_t *fb, const char *path, char *out_path, size_t out_path_len);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L66", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L66", "summary": "Native files entry point declared for firmware and extension integration." }, { @@ -2159,7 +2159,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_files_pbm_to_framebuffer", "signature": "int gfx_files_pbm_to_framebuffer(const char *path, gfx_image_fb_t *out);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L67", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L67", "summary": "Native files entry point declared for firmware and extension integration." }, { @@ -2169,7 +2169,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_files_pgm_to_framebuffer", "signature": "int gfx_files_pgm_to_framebuffer(const char *path, gfx_image_fb_t *out);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L68", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L68", "summary": "Native files entry point declared for firmware and extension integration." }, { @@ -2179,7 +2179,7 @@ "path": "src/gfx_files.h", "qualified_name": "gfx_files_bmp_to_framebuffer", "signature": "int gfx_files_bmp_to_framebuffer(const char *path, gfx_image_fb_t *out);", - "source_url": "https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L69", + "source_url": "https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L69", "summary": "Native files entry point declared for firmware and extension integration." } ] diff --git a/docs/generated/module-formats.md b/tools/sourcey-api/generated/module-formats.md similarity index 51% rename from docs/generated/module-formats.md rename to tools/sourcey-api/generated/module-formats.md index dc2f0b8..cefcfb8 100644 --- a/docs/generated/module-formats.md +++ b/tools/sourcey-api/generated/module-formats.md @@ -3,118 +3,118 @@ title: Runtime and pixel formats description: Runtime capability probes and the exported framebuffer format constants. --- -Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). +Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). Runtime capability probes and the exported framebuffer format constants. Every entry below is generated from a public binding table or header declaration and links to its immutable source line. -## `graphics.framebuf_backend` +## `pygraphics.framebuf_backend` ```python -graphics.framebuf_backend() +pygraphics.framebuf_backend() ``` Return the active framebuffer backend identifier. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2950) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2950) -## `graphics.implementation` +## `pygraphics.implementation` ```python -graphics.implementation() +pygraphics.implementation() ``` -Return the implementation identifier for this graphics module. +Return the implementation identifier for this pygraphics module. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2951) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2951) -## `graphics.capabilities` +## `pygraphics.capabilities` ```python -graphics.capabilities() +pygraphics.capabilities() ``` Return structured runtime feature and pixel-format capabilities. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2952) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L2952) -## `graphics.MONO_VLSB` +## `pygraphics.MONO_VLSB` ```python -graphics.MONO_VLSB +pygraphics.MONO_VLSB ``` Monochrome vertical least-significant-bit layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3027) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3027) -## `graphics.MONO_HLSB` +## `pygraphics.MONO_HLSB` ```python -graphics.MONO_HLSB +pygraphics.MONO_HLSB ``` Monochrome horizontal least-significant-bit layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3028) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3028) -## `graphics.MONO_HMSB` +## `pygraphics.MONO_HMSB` ```python -graphics.MONO_HMSB +pygraphics.MONO_HMSB ``` Monochrome horizontal most-significant-bit layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3029) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3029) -## `graphics.RGB565` +## `pygraphics.RGB565` ```python -graphics.RGB565 +pygraphics.RGB565 ``` 16-bit RGB565 pixel layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3030) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3030) -## `graphics.GS2_HMSB` +## `pygraphics.GS2_HMSB` ```python -graphics.GS2_HMSB +pygraphics.GS2_HMSB ``` 2-bit grayscale horizontal most-significant-bit layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3031) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3031) -## `graphics.GS4_HMSB` +## `pygraphics.GS4_HMSB` ```python -graphics.GS4_HMSB +pygraphics.GS4_HMSB ``` 4-bit grayscale horizontal most-significant-bit layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3032) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3032) -## `graphics.GS8` +## `pygraphics.GS8` ```python -graphics.GS8 +pygraphics.GS8 ``` 8-bit grayscale layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3033) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3033) -## `graphics.RGB888` +## `pygraphics.RGB888` ```python -graphics.RGB888 +pygraphics.RGB888 ``` 24-bit RGB888 pixel layout. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3034) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_module_cpy.c#L3034) diff --git a/docs/generated/native-assets-runtime.md b/tools/sourcey-api/generated/native-assets-runtime.md similarity index 77% rename from docs/generated/native-assets-runtime.md rename to tools/sourcey-api/generated/native-assets-runtime.md index 9a19824..dbe65a9 100644 --- a/docs/generated/native-assets-runtime.md +++ b/tools/sourcey-api/generated/native-assets-runtime.md @@ -3,7 +3,7 @@ title: Native fonts, images, and runtime API description: Public C declarations for fonts, BMP565 data, image conversion, and capability reporting. --- -Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). +Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). Public C declarations for fonts, BMP565 data, image conversion, and capability reporting. @@ -17,7 +17,7 @@ void gfx_font_init_default(gfx_font_t *font, int height); Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L22) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L22) ## `gfx_font_init_from_data` @@ -27,7 +27,7 @@ void gfx_font_init_from_data(gfx_font_t *font, const uint8_t *data, size_t len, Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L23) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L23) ## `gfx_font_deinit` @@ -37,7 +37,7 @@ void gfx_font_deinit(gfx_font_t *font); Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L24) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L24) ## `gfx_font_export` @@ -47,7 +47,7 @@ int gfx_font_export(const gfx_font_t *font, const char *filename); Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L26) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L26) ## `gfx_font_text` @@ -57,7 +57,7 @@ gfx_area_t gfx_font_text(const gfx_canvas_t *canvas, const gfx_font_t *font, con Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L29) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L29) ## `gfx_font_draw_char` @@ -67,7 +67,7 @@ gfx_area_t gfx_font_draw_char(const gfx_canvas_t *canvas, const gfx_font_t *font Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L30) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L30) ## `gfx_font_text_width` @@ -77,7 +77,7 @@ int gfx_font_text_width(const gfx_font_t *font, const char *str, int scale); Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L31) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L31) ## `gfx_font_text8` @@ -87,7 +87,7 @@ gfx_area_t gfx_font_text8(const gfx_canvas_t *canvas, const char *str, int x0, i Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L32) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L32) ## `gfx_font_text14` @@ -97,7 +97,7 @@ gfx_area_t gfx_font_text14(const gfx_canvas_t *canvas, const char *str, int x0, Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L33) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L33) ## `gfx_font_text16` @@ -107,7 +107,7 @@ gfx_area_t gfx_font_text16(const gfx_canvas_t *canvas, const char *str, int x0, Native font entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L34) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_font.h#L34) ## `gfx_bmp565_read_header_from_file` @@ -117,7 +117,7 @@ int gfx_bmp565_read_header_from_file(const char *path, int *width, int *height, Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L27) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L27) ## `gfx_bmp565_open_stream` @@ -127,7 +127,7 @@ int gfx_bmp565_open_stream(const char *path, gfx_bmp565_t *out); Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L28) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L28) ## `gfx_bmp565_load_from_file` @@ -137,7 +137,7 @@ int gfx_bmp565_load_from_file(const char *path, gfx_bmp565_t *out); Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L29) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L29) ## `gfx_bmp565_init_from_buffer` @@ -147,7 +147,7 @@ int gfx_bmp565_init_from_buffer(gfx_bmp565_t *out, const uint8_t *buf, size_t le Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L30) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L30) ## `gfx_bmp565_deinit` @@ -157,7 +157,7 @@ void gfx_bmp565_deinit(gfx_bmp565_t *bmp); Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L31) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L31) ## `gfx_bmp565_save` @@ -167,7 +167,7 @@ int gfx_bmp565_save(const gfx_bmp565_t *bmp, const char *path); Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L32) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L32) ## `gfx_bmp565_save_versioned` @@ -177,7 +177,7 @@ int gfx_bmp565_save_versioned(const gfx_bmp565_t *bmp, const char *path, char *o Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L33) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L33) ## `gfx_bmp565_read_bytes` @@ -187,7 +187,7 @@ int gfx_bmp565_read_bytes(const gfx_bmp565_t *bmp, int start, int stop, uint8_t Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L34) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L34) ## `gfx_bmp565_read_region` @@ -197,7 +197,7 @@ int gfx_bmp565_read_region(const gfx_bmp565_t *bmp, int x0, int x1, int y0, int Native bmp565 entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L35) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_bmp565.h#L35) ## `gfx_image_probe` @@ -207,7 +207,7 @@ int gfx_image_probe(const uint8_t *data, size_t len, gfx_image_info_t *info); Native image entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L43) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L43) ## `gfx_image_decode` @@ -217,7 +217,7 @@ int gfx_image_decode(const uint8_t *data, size_t len, const gfx_image_info_t *in Native image entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L47) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L47) ## `gfx_image_fb_free` @@ -227,7 +227,7 @@ void gfx_image_fb_free(gfx_image_fb_t *img); Native image entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L64) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L64) ## `gfx_files_load_image` @@ -237,7 +237,7 @@ int gfx_files_load_image(const char *path, gfx_image_fb_t *out); Native files entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L65) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L65) ## `gfx_files_save_image` @@ -247,7 +247,7 @@ int gfx_files_save_image(const gfx_fb_t *fb, const char *path, char *out_path, s Native files entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L66) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L66) ## `gfx_files_pbm_to_framebuffer` @@ -257,7 +257,7 @@ int gfx_files_pbm_to_framebuffer(const char *path, gfx_image_fb_t *out); Native files entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L67) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L67) ## `gfx_files_pgm_to_framebuffer` @@ -267,7 +267,7 @@ int gfx_files_pgm_to_framebuffer(const char *path, gfx_image_fb_t *out); Native files entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L68) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L68) ## `gfx_files_bmp_to_framebuffer` @@ -277,4 +277,4 @@ int gfx_files_bmp_to_framebuffer(const char *path, gfx_image_fb_t *out); Native files entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L69) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_files.h#L69) diff --git a/docs/generated/native-drawing.md b/tools/sourcey-api/generated/native-drawing.md similarity index 76% rename from docs/generated/native-drawing.md rename to tools/sourcey-api/generated/native-drawing.md index 57b3ebf..340569b 100644 --- a/docs/generated/native-drawing.md +++ b/tools/sourcey-api/generated/native-drawing.md @@ -3,7 +3,7 @@ title: Native drawing and framebuffer API description: Public C declarations for geometry, framebuffer operations, shapes, and clipping. --- -Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/graphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). +Source snapshot: [`a02baf40d594bb77afae9676b5c803232bc188cd`](https://github.com/PyDevices/pygraphics/tree/a02baf40d594bb77afae9676b5c803232bc188cd). Public C declarations for geometry, framebuffer operations, shapes, and clipping. @@ -17,7 +17,7 @@ int gfx_fb_validate_buffer(size_t buf_len, int width, int height, int format, in Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L21) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L21) ## `gfx_fb_color_depth` @@ -27,7 +27,7 @@ int gfx_fb_color_depth(int format); Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L22) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L22) ## `gfx_fb_setpixel` @@ -37,7 +37,7 @@ void gfx_fb_setpixel(const gfx_fb_t *fb, unsigned int x, unsigned int y, uint32_ Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L24) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L24) ## `gfx_fb_getpixel` @@ -47,7 +47,7 @@ uint32_t gfx_fb_getpixel(const gfx_fb_t *fb, unsigned int x, unsigned int y); Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L25) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L25) ## `gfx_fb_setpixel_checked` @@ -57,7 +57,7 @@ void gfx_fb_setpixel_checked(const gfx_fb_t *fb, int x, int y, int col, int mask Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L26) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L26) ## `gfx_fb_fill_rect_raw` @@ -67,7 +67,7 @@ void gfx_fb_fill_rect_raw(const gfx_fb_t *fb, int x, int y, int w, int h, uint32 Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L27) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L27) ## `gfx_fb_fill_rect` @@ -77,7 +77,7 @@ gfx_area_t gfx_fb_fill_rect(const gfx_fb_t *fb, int x, int y, int w, int h, uint Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L28) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L28) ## `gfx_fb_fill` @@ -87,7 +87,7 @@ gfx_area_t gfx_fb_fill(const gfx_fb_t *fb, uint32_t col); Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L29) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L29) ## `gfx_fb_canvas_init` @@ -97,7 +97,7 @@ void gfx_fb_canvas_init(gfx_canvas_t *canvas, const gfx_fb_t *fb); Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L31) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L31) ## `gfx_fb_scroll` @@ -107,7 +107,7 @@ void gfx_fb_scroll(gfx_fb_t *fb, int xstep, int ystep); Native fb entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L32) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_framebuffer.h#L32) ## `gfx_clipped_canvas_init` @@ -117,7 +117,7 @@ void gfx_clipped_canvas_init(gfx_clipped_canvas_t *cc, const gfx_canvas_t *paren Native clipped entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L20) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L20) ## `gfx_shapes_pixel` @@ -127,7 +127,7 @@ gfx_area_t gfx_shapes_pixel(const gfx_canvas_t *canvas, int x, int y, int c); Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L22) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L22) ## `gfx_shapes_hline` @@ -137,7 +137,7 @@ gfx_area_t gfx_shapes_hline(const gfx_canvas_t *canvas, int x, int y, int w, int Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L23) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L23) ## `gfx_shapes_vline` @@ -147,7 +147,7 @@ gfx_area_t gfx_shapes_vline(const gfx_canvas_t *canvas, int x, int y, int h, int Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L24) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L24) ## `gfx_shapes_fill_rect` @@ -157,7 +157,7 @@ gfx_area_t gfx_shapes_fill_rect(const gfx_canvas_t *canvas, int x, int y, int w, Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L25) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L25) ## `gfx_shapes_rect` @@ -167,7 +167,7 @@ gfx_area_t gfx_shapes_rect(const gfx_canvas_t *canvas, int x, int y, int w, int Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L26) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L26) ## `gfx_shapes_line` @@ -177,7 +177,7 @@ gfx_area_t gfx_shapes_line(const gfx_canvas_t *canvas, int x1, int y1, int x2, i Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L27) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L27) ## `gfx_shapes_ellipse` @@ -187,7 +187,7 @@ gfx_area_t gfx_shapes_ellipse(const gfx_canvas_t *canvas, int cx, int cy, int xr Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L28) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L28) ## `gfx_shapes_fill` @@ -197,7 +197,7 @@ gfx_area_t gfx_shapes_fill(const gfx_canvas_t *canvas, int c); Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L29) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L29) ## `gfx_shapes_poly_int_from_buffer` @@ -207,7 +207,7 @@ int gfx_shapes_poly_int_from_buffer(const void *buf, size_t len, size_t itemsize Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L31) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L31) ## `gfx_shapes_poly` @@ -217,7 +217,7 @@ gfx_area_t gfx_shapes_poly(const gfx_canvas_t *canvas, int x, int y, const void Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L32) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L32) ## `gfx_shapes_blit` @@ -227,7 +227,7 @@ gfx_area_t gfx_shapes_blit(const gfx_canvas_t *canvas, const gfx_fb_t *source, i Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L33) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L33) ## `gfx_shapes_circle` @@ -237,7 +237,7 @@ gfx_area_t gfx_shapes_circle(const gfx_canvas_t *canvas, int x0, int y0, int r, Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L34) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L34) ## `gfx_shapes_round_rect` @@ -247,7 +247,7 @@ gfx_area_t gfx_shapes_round_rect(const gfx_canvas_t *canvas, int x0, int y0, int Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L35) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L35) ## `gfx_shapes_triangle` @@ -257,7 +257,7 @@ gfx_area_t gfx_shapes_triangle(const gfx_canvas_t *canvas, int x0, int y0, int x Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L36) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L36) ## `gfx_shapes_arc` @@ -267,7 +267,7 @@ gfx_area_t gfx_shapes_arc(const gfx_canvas_t *canvas, int x, int y, int r, float Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L37) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L37) ## `gfx_shapes_gradient_rect` @@ -277,7 +277,7 @@ gfx_area_t gfx_shapes_gradient_rect(const gfx_canvas_t *canvas, int x, int y, in Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L38) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L38) ## `gfx_shapes_blit_rect` @@ -287,7 +287,7 @@ gfx_area_t gfx_shapes_blit_rect(const gfx_canvas_t *canvas, const void *buf, int Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L39) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L39) ## `gfx_shapes_blit_transparent` @@ -297,7 +297,7 @@ gfx_area_t gfx_shapes_blit_transparent(const gfx_canvas_t *canvas, const void *b Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L40) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L40) ## `gfx_shapes_polygon` @@ -307,7 +307,7 @@ gfx_area_t gfx_shapes_polygon(const gfx_canvas_t *canvas, const int *points, siz Native shapes entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L41) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_shapes.h#L41) ## `gfx_draw_init` @@ -317,7 +317,7 @@ void gfx_draw_init(gfx_draw_t *draw, const gfx_canvas_t *canvas); Native draw entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L21) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L21) ## `gfx_draw_effective_clip` @@ -327,7 +327,7 @@ gfx_area_t gfx_draw_effective_clip(const gfx_draw_t *draw); Native draw entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L23) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L23) ## `gfx_draw_push_clip` @@ -337,7 +337,7 @@ void gfx_draw_push_clip(gfx_draw_t *draw, const gfx_area_t *clip); Native draw entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L24) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L24) ## `gfx_draw_pop_clip` @@ -347,4 +347,4 @@ void gfx_draw_pop_clip(gfx_draw_t *draw); Native draw entry point declared for firmware and extension integration. -[View the pinned source declaration](https://github.com/PyDevices/graphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L25) +[View the pinned source declaration](https://github.com/PyDevices/pygraphics/blob/a02baf40d594bb77afae9676b5c803232bc188cd/src/gfx_draw.h#L25) diff --git a/docs/package-lock.json b/tools/sourcey-api/package-lock.json similarity index 99% rename from docs/package-lock.json rename to tools/sourcey-api/package-lock.json index 8ec61e9..9e7ea23 100644 --- a/docs/package-lock.json +++ b/tools/sourcey-api/package-lock.json @@ -1,10 +1,10 @@ { - "name": "graphics-cmod-sourcey-docs", + "name": "pygraphics-cmod-sourcey-docs", "lockfileVersion": 3, "requires": true, "packages": { "": { - "name": "graphics-cmod-sourcey-docs", + "name": "pygraphics-cmod-sourcey-docs", "devDependencies": { "sourcey": "3.6.5" } diff --git a/docs/package.json b/tools/sourcey-api/package.json similarity index 87% rename from docs/package.json rename to tools/sourcey-api/package.json index 6982a14..2f2be6f 100644 --- a/docs/package.json +++ b/tools/sourcey-api/package.json @@ -1,5 +1,5 @@ { - "name": "graphics-cmod-sourcey-docs", + "name": "pygraphics-cmod-sourcey-docs", "private": true, "scripts": { "generate": "python3 scripts/generate_reference.py", diff --git a/docs/scripts/generate_reference.py b/tools/sourcey-api/scripts/generate_reference.py similarity index 96% rename from docs/scripts/generate_reference.py rename to tools/sourcey-api/scripts/generate_reference.py index 2925397..33612e8 100644 --- a/docs/scripts/generate_reference.py +++ b/tools/sourcey-api/scripts/generate_reference.py @@ -1,5 +1,5 @@ #!/usr/bin/env python3 -"""Generate a source-linked reference from graphics' public C bindings.""" +"""Generate a source-linked reference from pygraphics' public C bindings.""" from __future__ import annotations @@ -11,11 +11,11 @@ from typing import Dict, Iterable, List, Sequence, Tuple -REPO_ROOT = Path(__file__).resolve().parents[2] -DOCS_ROOT = REPO_ROOT / "docs" -OUTPUT_ROOT = DOCS_ROOT / "generated" -REPOSITORY_URL = "https://github.com/PyDevices/graphics" -PROJECT_DOCS_URL = "https://pydevices.github.io/graphics/api" +SOURCEY_ROOT = Path(__file__).resolve().parents[1] +REPO_ROOT = SOURCEY_ROOT.parents[1] +OUTPUT_ROOT = SOURCEY_ROOT / "generated" +REPOSITORY_URL = "https://github.com/PyDevices/pygraphics" +PROJECT_DOCS_URL = "https://pydevices.github.io/pygraphics/api" SOURCEY_VERSION = "3.6.5" CPYTHON_BINDING = "src/gfx_module_cpy.c" @@ -349,7 +349,7 @@ def property_entries(table: str, commit: str) -> List[Dict[str, object]]: def type_line(name: str) -> int: lines = (REPO_ROOT / CPYTHON_BINDING).read_text(encoding="utf-8").splitlines() - needle = f'.tp_name = "graphics.{name}"' + needle = f'.tp_name = "pygraphics.{name}"' return next(index for index, line in enumerate(lines, start=1) if needle in line) @@ -372,7 +372,7 @@ def module_signature(name: str) -> str: args = f"canvas, {COMMON_DRAW_SIGNATURES[name]}" else: args = "*args, **kwargs" - return f"graphics.{name}({args})" + return f"pygraphics.{name}({args})" def class_records(name: str, commit: str) -> List[Dict[str, object]]: @@ -381,7 +381,7 @@ def class_records(name: str, commit: str) -> List[Dict[str, object]]: records: List[Dict[str, object]] = [ { "name": name, - "qualified_name": f"graphics.{name}", + "qualified_name": f"pygraphics.{name}", "kind": "class", "signature": str(spec["signature"]), "summary": str(spec["summary"]), @@ -395,7 +395,7 @@ def class_records(name: str, commit: str) -> List[Dict[str, object]]: records.append( { **item, - "qualified_name": f"graphics.{name}.{method_name}", + "qualified_name": f"pygraphics.{name}.{method_name}", "kind": "method", "signature": python_signature(name, method_name), "summary": DESCRIPTIONS.get( @@ -411,7 +411,7 @@ def class_records(name: str, commit: str) -> List[Dict[str, object]]: records.append( { **item, - "qualified_name": f"graphics.{name}.{property_name}", + "qualified_name": f"pygraphics.{name}.{property_name}", "kind": "property", "signature": f"{name}.{property_name}", "summary": PROPERTY_DESCRIPTIONS.get( @@ -429,7 +429,7 @@ def module_records(commit: str) -> List[Dict[str, object]]: records.append( { **item, - "qualified_name": f"graphics.{name}", + "qualified_name": f"pygraphics.{name}", "kind": "function", "signature": module_signature(name), "summary": DESCRIPTIONS.get( @@ -452,9 +452,9 @@ def constant_records(commit: str) -> List[Dict[str, object]]: records.append( { "name": name, - "qualified_name": f"graphics.{name}", + "qualified_name": f"pygraphics.{name}", "kind": "constant", - "signature": f"graphics.{name}", + "signature": f"pygraphics.{name}", "summary": CONSTANT_DESCRIPTIONS.get( name, "Native graphics module constant." ), @@ -662,12 +662,12 @@ def write_reference(commit: str, release: str) -> Dict[str, object]: "graphics API reference", "Source-linked Python and native C reference for the PyDevices graphics module.", ), - "`graphics` is the all-C drawing module shared by CPython, MicroPython, and CircuitPython builds in the PyDevices stack.", + "`pygraphics` is the all-C drawing module shared by CPython, MicroPython, and CircuitPython builds in the PyDevices stack.", "", "## Quick start", "", "```python", - "from graphics import Area, FrameBuffer, RGB565", + "from pygraphics import Area, FrameBuffer, RGB565", "", "buffer = bytearray(160 * 128 * 2)", "canvas = FrameBuffer(buffer, 160, 128, RGB565)", diff --git a/docs/scripts/verify-site.mjs b/tools/sourcey-api/scripts/verify-site.mjs similarity index 83% rename from docs/scripts/verify-site.mjs rename to tools/sourcey-api/scripts/verify-site.mjs index 67b2c58..fb3f55e 100644 --- a/docs/scripts/verify-site.mjs +++ b/tools/sourcey-api/scripts/verify-site.mjs @@ -2,15 +2,15 @@ import { existsSync, readFileSync, readdirSync, statSync } from "node:fs"; import { join, resolve } from "node:path"; import { fileURLToPath } from "node:url"; -const docsDir = resolve(fileURLToPath(new URL("..", import.meta.url))); -const repoDir = resolve(docsDir, ".."); -const generatedDir = join(docsDir, "generated"); -const distDir = join(docsDir, "dist"); +const sourceyDir = resolve(fileURLToPath(new URL("..", import.meta.url))); +const repoDir = resolve(sourceyDir, "../.."); +const generatedDir = join(sourceyDir, "generated"); +const distDir = join(sourceyDir, "dist"); const manifest = JSON.parse( readFileSync(join(generatedDir, "manifest.json"), "utf8"), ); -const expectedBaseUrl = "/graphics/api/"; -const expectedSiteUrl = "https://pydevices.github.io/graphics/api/"; +const expectedBaseUrl = "/pygraphics/api/"; +const expectedSiteUrl = "https://pydevices.github.io/pygraphics/api/"; function walk(directory) { return readdirSync(directory).flatMap((name) => { @@ -53,7 +53,7 @@ for (const required of [ } const expectedSourcePrefix = - `https://github.com/PyDevices/graphics/blob/${manifest.commit}/`; + `https://github.com/PyDevices/pygraphics/blob/${manifest.commit}/`; if ( manifest.symbols.some( (symbol) => @@ -81,10 +81,10 @@ if (existsSync(join(distDir, "search-index.json"))) { .map((entry) => `${entry.title ?? ""} ${entry.content ?? ""}`) .join("\n"); for (const expected of [ - "graphics.FrameBuffer", - "graphics.Area.contains", - "graphics.Draw.clip", - "graphics.Font.text_width", + "pygraphics.FrameBuffer", + "pygraphics.Area.contains", + "pygraphics.Draw.clip", + "pygraphics.Font.text_width", "gfx_shapes_fill_rect", ]) { if (!searchable.includes(expected)) { @@ -99,7 +99,7 @@ if (existsSync(distDir)) { if (!html.includes(manifest.commit)) { failures.push("site does not expose the immutable source commit"); } - if (!html.includes("graphics.FrameBuffer") || !html.includes("gfx_shapes_fill_rect")) { + if (!html.includes("pygraphics.FrameBuffer") || !html.includes("gfx_shapes_fill_rect")) { failures.push("site is missing representative Python or native C entries"); } const canonicalUrls = [ @@ -118,7 +118,7 @@ if (!homepage.includes('href="api/"')) { failures.push("project homepage does not link to the API reference"); } const readme = readFileSync(join(repoDir, "README.md"), "utf8"); -if (!readme.includes("https://pydevices.github.io/graphics/api/")) { +if (!readme.includes("https://pydevices.github.io/pygraphics/api/")) { failures.push("README does not link to the published API reference"); } const workflow = readFileSync( @@ -126,9 +126,9 @@ const workflow = readFileSync( "utf8", ); for (const required of [ - "npm ci --prefix docs", - "npm run check --prefix docs", - "cp -r docs/dist/* _site/api/", + "npm ci --prefix tools/sourcey-api", + "npm run check --prefix tools/sourcey-api", + "cp -r tools/sourcey-api/dist/* _site/api/", "fetch-depth: 0", "fetch-tags: true", ]) { diff --git a/docs/sourcey.config.ts b/tools/sourcey-api/sourcey.config.ts similarity index 84% rename from docs/sourcey.config.ts rename to tools/sourcey-api/sourcey.config.ts index ffeb256..577c9ab 100644 --- a/docs/sourcey.config.ts +++ b/tools/sourcey-api/sourcey.config.ts @@ -2,12 +2,12 @@ import { defineConfig, markdown } from "sourcey"; export default defineConfig({ name: "graphics", - repo: "https://github.com/PyDevices/graphics", + repo: "https://github.com/PyDevices/pygraphics", siteUrl: "https://pydevices.github.io", - baseUrl: "/graphics/api/", + baseUrl: "/pygraphics/api/", favicon: "./favicon.svg", editBranch: "main", - editBasePath: "docs", + editBasePath: "tools/sourcey-api", theme: { preset: "api-first", colors: { @@ -20,13 +20,13 @@ export default defineConfig({ links: [ { type: "github", - href: "https://github.com/PyDevices/graphics", + href: "https://github.com/PyDevices/pygraphics", }, ], primary: { type: "button", label: "Project home", - href: "https://pydevices.github.io/graphics/", + href: "https://pydevices.github.io/pygraphics/", }, }, navigation: { diff --git a/web/index.html b/web/index.html index cb416e6..8d86fb0 100644 --- a/web/index.html +++ b/web/index.html @@ -5,7 +5,7 @@ graphics — PyDevices - + @@ -24,7 +24,7 @@ pydisplay cmods API reference - Source + Source