Commit0bf923d1Recorded15 Jan 2026Repositorysigil-studio
refactor(graphics): Move font and image to (sigil graphics *) namespace
Message
Rename modules to reflect their role as graphics subsystems: - (sigil font) -> (sigil graphics font) - (sigil image) -> (sigil graphics image)
This creates a cleaner module hierarchy where graphics-related functionality lives under the (sigil graphics) namespace.
Changes: - Move font.sgl and image.sgl to src/sigil/graphics/ - Update C module init functions and module names - Update all imports in tests and examples - Add docs/guides/graphics-audio.md documentation
Changed
examples/solitaire.sgl | 2 +-
package.sgl | 6 +++---
test/test-audio.sgl | 2 +-
test/test-font.sgl | 2 +-
test/test-image.sgl | 4 ++--
test/test-transforms.sgl | 2 +-
6 files changed, 9 insertions(+), 9 deletions(-)Diff
examples/solitaire.sglmodified
@@ -15,7 +15,7 @@
15
(sigil math) 16
(sigil app) 17
(sigil graphics)−18
(sigil font))+18
(sigil graphics font)) 19
20
;; ============================================================ 21
;; CONSTANTSpackage.sglmodified
@@ -6,9 +6,9 @@
6
;;; This is the same as the standard `sigil` CLI but with multimedia 7
;;; modules available: 8
;;; - (sigil app): Windowing, input handling, application lifecycle−9
;;; - (sigil graphics): 2D rendering, images, textures−10
;;; - (sigil image): CPU-side image loading−11
;;; - (sigil font): Font loading and text rendering+9
;;; - (sigil graphics): 2D rendering, textures+10
;;; - (sigil graphics image): CPU-side image loading+11
;;; - (sigil graphics font): Font loading and text rendering 12
;;; - (sigil audio): Sound effects and music streaming 13
14
(packagetest/test-audio.sglmodified
@@ -4,7 +4,7 @@
4
(sigil app) 5
(sigil graphics) 6
(sigil audio)−7
(sigil font))+7
(sigil graphics font)) 8
9
(define *font* #f) 10
(define *music-playing* #f)test/test-font.sglmodified
@@ -3,7 +3,7 @@
3
(import (sigil core) 4
(sigil app) 5
(sigil graphics)−6
(sigil font))+6
(sigil graphics font)) 7
8
(display "Loading font...\n") 9
test/test-image.sglmodified
@@ -1,9 +1,9 @@
1
;;; test-image.sgl - Test image loading 2
;;;−3
;;; This test verifies that (sigil image) can load images.+3
;;; This test verifies that (sigil graphics image) can load images. 4
5
(import (sigil core)−6
(sigil image))+6
(sigil graphics image)) 7
8
(display "Testing image loading...\n") 9
test/test-transforms.sglmodified
@@ -3,7 +3,7 @@
3
(import (sigil core) 4
(sigil app) 5
(sigil graphics)−6
(sigil font))+6
(sigil graphics font)) 7
8
(define (label text x y) 9
(set-color 0.7 0.7 0.7)