Layout prototypes: Just Watch, Mosaic, Teletext and Kids (design only, mock data)
pauljd/davidson-ci: Davidson CI / quality (push) Failing after 2m8s
pauljd/davidson-ci: Davidson CI / ai-review (push) Failing after 1m40s
release-gate / verify (push) Successful in 12m8s

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
This commit is contained in:
2026-11-11 22:27:17 +00:00
co-authored by Claude Opus 5.5
parent 63109a4804
commit 2460475a68
19 changed files with 289 additions and 0 deletions
+289
View File
@@ -0,0 +1,289 @@
"""More layout prototypes (Paul, 11 November 2026, chosen from seven ideas): Just Watch, Mosaic, Teletext and Kids.
Design only, like build-layouts.py: nothing here is in the app, Orbit Original stays as it is, and every programme, time and
line-up is MOCK DATA, labelled on each frame. Same 1920 x 1080 frames, same figcraft-cli conversion, same palette and logos.
- Just Watch: Orbit opens straight onto the last channel, full screen, like switching on a TV. One button brings up a short
menu over the picture; nothing else ever covers it.
- Mosaic: a wall of nine channels, each with its programme's artwork and title. Only the focused tile plays video, so the
server sees one stream, as now.
- Teletext: Orbit in OrbiFax's blocky page style, with three-digit page numbers and the four coloured buttons.
- Kids: big picture cards with a word each, rounded type, one way to move, and a clear way back.
Run: python3 design/layouts/build-layouts-2.py
"""
import importlib.util
from pathlib import Path
HERE = Path(__file__).resolve().parent
spec = importlib.util.spec_from_file_location("layouts1", HERE / "build-layouts.py")
L = importlib.util.module_from_spec(spec); spec.loader.exec_module(L)
Frame, LINEUP, uri, RES = L.Frame, L.LINEUP, L.uri, L.RES
NAVY, DEEP, PANEL, BLUE, GOLD, MUTED, WHITE, INK, MINT = L.NAVY, L.DEEP, L.PANEL, L.BLUE, L.GOLD, L.MUTED, L.WHITE, L.INK, L.MINT
BODY, COND, HEAD = L.BODY, L.COND, L.HEAD
MONO, ROUND = "DejaVu Sans Mono", "Comfortaa"
progress, left = L.progress, L.left
LOGO = dict(L.LOGO)
LOGO.update({k: uri(RES / f"{v}.webp", 480) for k, v in {
"junior": "orbit_junior_epg", "toonz": "toonz_epg", "wonder": "wonder_epg", "pixelz": "orbit_pixelz_epg",
"wild": "orbit_wild_epg", "kitchen": "orbit_kitchen_epg"}.items()})
# MOCK DATA: two more channels so the mosaic has nine.
WALL = LINEUP + [
(203, "Orbit Wild", "wild", "Night Hunters", "18:30", "19:30", .4, "Reef Life", "19:30"),
(205, "Orbit Kitchen", "kitchen", "Bake It Simple", "18:15", "19:00", .6, "Street Food Tour", "19:00"),
]
def art(f, x, y, w, h, hue, id="Artwork"):
"""A stand-in for the programme's own artwork from Emby: shapes in the channel's colour, never a real picture."""
f.g(id)
f.grad(f"art{x}{y}", hue, "#0A1B3D")
f.rect(x, y, w, h, f"url(#art{x}{y})", rx=10)
f.rect(x + w * .55, y + h * .18, w * .32, w * .32 * .9, WHITE, rx=w * .16, opacity=.12)
f.rect(x + w * .08, y + h * .62, w * .5, h * .12, WHITE, rx=6, opacity=.10)
f.end()
# ---------- Just Watch ----------
def jw_on():
f = Frame("justwatch-1-on", "Just Watch: Orbit opens on the channel", bg="#000000"); f.mock(y=24, x=1600)
f.picture(0, 0, 1920, 1080, "Switched on: the last channel, already playing")
f.g("Channel ident")
f.rect(1640, 900, 216, 116, "#000000", rx=12, opacity=.55)
f.img(1656, 914, 184, 88, LOGO["one"], "Channel logo")
f.end()
f.g("First few seconds only")
f.rect(64, 920, 760, 96, "#000000", rx=12, opacity=.6)
f.text(96, 968, "101 Coastal Kitchens", 40, WHITE, BODY, 700)
f.text(96, 1002, "OK for the menu · ▲▼ change channel", 26, MUTED, BODY, 500)
f.end()
f.text(1824, 120, "Nothing else on screen. The line fades after 4 s.", 26, MUTED, BODY, 400, "end", id="Design note")
f.save()
def jw_menu():
f = Frame("justwatch-2-menu", "Just Watch: OK brings up the menu over the picture", bg="#000000"); f.mock(y=24, x=1600)
f.picture(0, 0, 1920, 1080, "The picture keeps playing behind")
f.g("Menu")
f.grad("jwfade", "#00000000", NAVY)
f.rect(0, 560, 1920, 520, "url(#jwfade)")
f.text(96, 690, "101 Coastal Kitchens", 44, WHITE, BODY, 700)
f.text(96, 736, "18:30 to 19:00 · 18 minutes left · Next: The Quiz Hour", 30, INK)
f.rect(96, 756, 900, 10, BLUE, rx=5); f.rect(96, 756, 540, 10, GOLD, rx=5, id="Progress")
items = ["Channels", "TV Guide", "Catch Up", "Drive-In", "Settings"]
x = 96
for i, t in enumerate(items):
w = 300
focused = i == 0
f.rect(x, 820, w, 110, GOLD if focused else PANEL, rx=16, id=f"Item {t}")
if focused: f.ring(x, 820, w, 110, 16)
f.text(x + w / 2, 890, t, 38, NAVY if focused else WHITE, BODY, 700, "middle")
x += w + 28
f.end()
f.hints([("◀ ▶", "Choose"), ("OK", "Open"), ("Back", "Just the picture")], y=1040, size=24)
f.save()
def jw_channels():
f = Frame("justwatch-3-channels", "Just Watch: Channels, a strip along the bottom", bg="#000000"); f.mock(y=24, x=1600)
f.picture(0, 0, 1920, 1080, "Still playing: OK on a card switches to it")
f.g("Channel strip")
f.grad("jwfade2", "#00000000", NAVY)
f.rect(0, 620, 1920, 460, "url(#jwfade2)")
f.text(96, 700, "Channels", 40, WHITE, BODY, 700)
for i, row in enumerate(LINEUP[:5]):
num, name, logo, now, start, end, _, nxt, nt = row
x = 96 + i * 352; y = 730
focused = i == 1
f.rect(x, y, 328, 250, GOLD if focused else PANEL, rx=16, id=f"Card {num}")
if focused: f.ring(x, y, 328, 250, 16)
if focused: f.rect(x + 16, y + 16, 296, 92, NAVY, rx=10)
f.img(x + 24, y + 20, 280, 84, LOGO[logo], f"Logo {name}")
f.text(x + 24, y + 150, f"{num} {now}", 30 if len(now) < 16 else 26, NAVY if focused else WHITE, BODY, 700)
f.text(x + 24, y + 192, f"{left(end)} min left", 26, NAVY if focused else MUTED, BODY, 500)
f.rect(x + 24, y + 214, 280, 8, NAVY if focused else BLUE, rx=4, opacity=.35 if focused else 1)
f.rect(x + 24, y + 214, int(280 * progress(start, end)), 8, NAVY if focused else GOLD, rx=4)
f.end()
f.hints([("◀ ▶", "Channels"), ("OK", "Watch"), ("Back", "Just the picture")], y=1048, size=22)
f.save()
# ---------- Mosaic ----------
HUES = ["#2E6FD0", "#3E9E6E", "#C0563B", "#B28A2E", "#2E8EA0", "#7A3EA8", "#C03B7A", "#4E7A2E", "#C07A2E"]
def mosaic_wall():
f = Frame("mosaic-1-wall", "Mosaic: nine channels at a glance"); f.mock(y=24)
f.g("Masthead")
f.img(96, 40, 220, 56, LOGO["orbit"], "Orbit logo")
f.text(360, 84, "Mosaic", 44, WHITE, BODY, 600)
f.text(1650, 84, "18:42", 48, WHITE, COND, 500, "end")
f.end()
f.g("Wall")
w, h, gap = 560, 272, 20
for i, row in enumerate(WALL[:9]):
num, name, logo, now, start, end, _, nxt, nt = row
c, r = i % 3, i // 3
x, y = 96 + c * (w + gap), 118 + r * (h + gap)
focused = i == 4
if focused:
f.picture(x, y, w, h - 84, "Live: the only stream")
else:
art(f, x, y, w, h - 84, HUES[i], f"Artwork {num}")
f.rect(x, y + h - 84, w, 84, GOLD if focused else PANEL, id=f"Caption {num}")
if focused: f.ring(x, y, w, h, 10)
f.rect(x + 12, y + 12, 150, 56, "#000000", rx=8, opacity=.55)
f.img(x + 18, y + 14, 138, 52, LOGO[logo], f"Logo {name}")
f.text(x + 20, y + h - 36, f"{num} {now}", 32, NAVY if focused else WHITE, BODY, 700)
f.text(x + w - 20, y + h - 36, f"{left(end)}m", 28, NAVY if focused else MUTED, BODY, 500, "end")
f.end()
f.hints([("◀ ▶ ▲ ▼", "Move"), ("OK", "Watch full screen"), ("Back", "Home")], y=1062, size=22)
f.save()
def mosaic_states():
f = Frame("mosaic-2-states", "Mosaic: tile states and the server cost"); f.mock(y=24)
f.text(96, 110, "Mosaic tiles", 56, WHITE, BODY, 700)
f.text(96, 160, "Only the focused tile plays. The others show the programme's artwork, read once and kept on the box.", 30, MUTED)
states = [("Resting: artwork", False, False), ("Focused: live picture", True, False), ("Locked (After Dark, Kids)", False, True)]
for i, (label, focused, locked) in enumerate(states):
x = 96 + i * 600
f.text(x, 250, label, 32, GOLD, BODY, 600)
if focused: f.picture(x, 280, 540, 220, "Live")
else: art(f, x, 280, 540, 220, HUES[2 if not locked else 5], f"Artwork {label}")
if locked:
f.rect(x, 280, 540, 220, NAVY, rx=10, opacity=.8)
f.text(x + 270, 404, "PIN to watch", 34, WHITE, BODY, 700, "middle")
f.rect(x, 500, 540, 84, GOLD if focused else PANEL)
if focused: f.ring(x, 280, 540, 304, 10)
f.text(x + 20, 556, "305 The Long Night" if locked else "102 Garden Rescue", 30, NAVY if focused else WHITE, BODY, 700)
f.text(96, 700, "Server cost, as now: one stream at a time, and artwork already cached by the guide.", 32, WHITE, BODY, 600)
f.text(96, 750, "Moving across tiles waits 600 ms before the picture starts, so passing over a tile opens nothing.", 30, MUTED)
f.text(96, 800, "Motion: focus moves in 160 ms on Orbit's curve; with Reduce motion it simply jumps.", 30, MUTED)
f.save()
# ---------- Teletext ----------
TT = {"black": "#000000", "white": "#FFFFFF", "yellow": "#FFFF00", "cyan": "#00FFFF", "green": "#00FF00",
"red": "#FF0000", "magenta": "#FF00FF", "blue": "#0000FF"}
COL, ROW = 48, 40 # a 40 x 24 character page drawn on 1920 x 1080: 48 px columns, 40 px rows (plus margins)
def tt_text(f, col, row, s, colour="white", double=False):
size = 64 if double else 34
f.text(48 + col * COL * .9, 92 + row * ROW + (20 if double else 0), s, size, TT[colour], MONO, 700)
def tt_header(f, page, title, bar):
tt_text(f, 0, 0, f"P{page} ORBITFAX {page} Tue 10 Nov 18:42/31", "white")
f.rect(48, 118, 1824, 92, TT[bar])
tt_text(f, 1, 2, title, "white" if bar != "yellow" else "black", double=True)
def tt_fastext(f, items):
colours = ["red", "green", "yellow", "cyan"]
x = 48
for c, label in zip(colours, items):
tt_text(f, (x - 48) / (COL * .9), 23, label, c)
x += 460
def blocks(f, x, y, pattern, colour):
"""Teletext block graphics: each character cell split into 2 x 3 blocks."""
for r, line in enumerate(pattern):
for c, ch in enumerate(line):
if ch == "#": f.rect(x + c * 22, y + r * 14, 22, 14, TT[colour])
def tt_index():
f = Frame("teletext-1-index", "Teletext: Orbit as OrbiFax pages", bg="#000000"); f.mock(y=1030)
tt_header(f, 100, "ORBIT", "blue")
for i, c in enumerate(["red", "green", "yellow", "cyan", "magenta"]): # a band of block colours, as on old index pages
f.rect(1380 + i * 88, 140, 80, 48, TT[c])
entries = [("Now and Next", "101", "cyan"), ("TV Guide tonight", "110", "cyan"), ("Catch Up", "200", "cyan"),
("Drive-In bills", "300", "cyan"), ("Kids", "600", "green"), ("Settings", "800", "yellow"), ("Help", "888", "yellow")]
for i, (name, page, colour) in enumerate(entries):
tt_text(f, 2, 6 + i * 2, name, "white")
tt_text(f, 30, 6 + i * 2, page, colour)
tt_text(f, 2, 21, "Type three numbers to go to a page", "green")
tt_fastext(f, ["Now", "Guide", "Catch Up", "Index"])
f.save()
def tt_now():
f = Frame("teletext-2-now", "Teletext: Now and Next, page 101", bg="#000000"); f.mock(y=1030)
tt_header(f, 101, "NOW AND NEXT", "red")
for i, row in enumerate(LINEUP[:6]):
num, name, logo, now, start, end, _, nxt, nt = row
r = 6 + i * 2.5
focused = i == 1
if focused: f.rect(48, 92 + (r - 1) * ROW + 8, 1824, ROW * 2 + 8, TT["yellow"])
ink = "black" if focused else "white"
tt_text(f, 1, r, f"{num}", "black" if focused else "cyan")
tt_text(f, 6, r, f"{start} {now}"[:30], ink)
tt_text(f, 6, r + 1, f"{nt} {nxt}"[:30], "black" if focused else "green")
tt_text(f, 2, 21, "OK watches ▲▼ moves 101-104 subpages 1/2", "white")
tt_fastext(f, ["Index", "Guide", "Catch Up", "Next page"])
f.save()
# ---------- Kids ----------
KIDS = [(614, "Tots", "tots", "Sleepy Farm", "#F2994A"), (611, "Junior", "junior", "Puzzle Pals", "#56CCF2"),
(605, "ToonZ", "toonz", "Robot Squad", "#6FCF97"), (612, "Wonder", "wonder", "Sky Explorers", "#BB6BD9")]
def kids_home():
f = Frame("kids-1-home", "Kids: big picture cards"); f.mock(y=24)
f.g("Masthead")
f.text(96, 110, "What shall we watch?", 64, WHITE, ROUND, 700)
f.rect(1500, 54, 324, 76, PANEL, rx=38)
f.text(1662, 104, "Bedtime 19:30", 30, GOLD, ROUND, 700, "middle")
f.end()
f.g("Cards")
w, gap = 408, 32
for i, (num, name, logo, now, hue) in enumerate(KIDS):
x, y = 96 + i * (w + gap), 190
focused = i == 0
art(f, x, y, w, 420, hue, f"Picture {name}")
f.rect(x, y + 420, w, 220, GOLD if focused else PANEL, rx=0, id=f"Card {name}")
if focused: f.ring(x, y, w, 640, 24, 8)
f.rect(x + 24, y + 24, 200, 80, "#000000", rx=12, opacity=.5)
f.img(x + 32, y + 28, 184, 72, LOGO[logo], f"Logo {name}")
f.text(x + 32, y + 500, name, 56, NAVY if focused else WHITE, ROUND, 700)
f.text(x + 32, y + 560, now, 34, NAVY if focused else MUTED, ROUND, 700)
f.rect(x + 32, y + 590, w - 64, 14, NAVY if focused else BLUE, rx=7, opacity=.3 if focused else 1)
f.rect(x + 32, y + 590, (w - 64) * .4, 14, NAVY if focused else GOLD, rx=7)
f.end()
f.g("Remote")
f.rect(96, 900, 560, 100, PANEL, rx=50)
f.text(376, 964, "◀ ▶ pick · OK watch", 34, WHITE, ROUND, 700, "middle")
f.end()
f.text(1824, 964, "Only kids' channels. No guide grid, no settings.", 26, MUTED, BODY, 400, "end", id="Design note")
f.save()
def kids_watching():
f = Frame("kids-2-watching", "Kids: watching, with a big way back", bg="#000000"); f.mock(y=24, x=1600)
f.picture(0, 0, 1920, 1080, "Sleepy Farm, full screen")
f.g("Kids banner")
f.rect(64, 780, 1792, 236, NAVY, rx=40, opacity=.94)
f.img(104, 820, 240, 96, LOGO["tots"], "Channel logo")
f.text(380, 880, "Sleepy Farm", 60, WHITE, ROUND, 700)
f.text(380, 950, "Then: Bath Time Band", 38, MUTED, ROUND, 700)
f.rect(1340, 830, 460, 136, GOLD, rx=68, id="Back to channels")
f.ring(1340, 830, 460, 136, 68, 6)
f.text(1570, 914, "◀ Channels", 48, NAVY, ROUND, 700, "middle")
f.end()
f.text(1824, 740, "Wind Down still dims and quietens Tots in the evening.", 26, MUTED, BODY, 400, "end", id="Design note")
f.save()
if __name__ == "__main__":
for make in (jw_on, jw_menu, jw_channels, mosaic_wall, mosaic_states, tt_index, tt_now, kids_home, kids_watching):
make()
Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 123 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 162 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 178 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 115 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 207 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 215 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.
Binary file not shown.

After

Width:  |  Height:  |  Size: 167 KiB