summaryrefslogtreecommitdiffhomepage
path: root/src/config.h
AgeCommit message (Collapse)Author
2026-06-27refactor: split single-file main.c into modular .h/.c pairsAdam Malczewski
Decompose the 778-line src/main.c into 7 focused modules with separate headers for code isolation and parallel agent development: types.h shared types: PlayerState, SilenceRegion, UILayout, constants player.{h,c} audio playback: load, play, pause, seek, update, format_time study.{h,c} study mode: silence detection, portion navigation, auto-pause ui.{h,c} rendering + input: fonts, colors, drawing, keyboard/mouse config.{h,c} UI layout persistence (moved UILayout to types.h) layout_editor.{h,c} layout editor tab (unchanged) main.c thin composition root (main loop, tabs, platform glue) Module boundaries follow the dispatch-project style: - .h files are contracts (self-contained, #pragma once, forward-declare) - .c files are private (static helpers, no cross-module .c includes) - All shared state passed by pointer (PlayerState*/UIState*) - font_data.h (xxd-generated array definition) included in exactly one .c Updated documentation (AGENTS.md, ORCHESTRATOR.md, GLOSSARY.md, README.md, tasks.md) and bin/ scripts (dispatch-style conventions, added bin/build-web). Build: make clean && make -j$(nproc) exits 0 with zero warnings.
2026-06-08ui: add X-axis positioning to all layout elementscyberdeckAdam Malczewski
- UILayout gains titleX, statusX, helpX, smartPlayX, secNavX - All elements freely draggable in both X and Y in Layout editor - draw_text_centered() now takes centerX parameter - section nav positions relative to secNavX
2026-06-08ui: make smart play button and section nav configurableAdam Malczewski
- UILayout gains smartPlayY and secNavY fields - Smart play HOLD button now uses layout.smartPlayY - Section nav prev/next buttons use layout.secNavY - Both are draggable in Layout editor tab - config_load/config_save handle new fields
2026-06-08ui: add tab bar, layout editor with drag-to-repositionAdam Malczewski
- GuiTabBar from raygui v5.0 for Player/Layout tab switching - Layout tab: 5 draggable element placeholders (Title, Bar, Status, Play button, Help) — press+hold+drag to reposition - Auto-save config file on tab switch from Layout back to Player - config_save() added to config module - raygui include path added to Makefile, warnings suppressed via #pragma for third-party header
2026-06-08config: add key-value config file for UI layout positionsAdam Malczewski
- src/config.h: UILayout struct + config_load() declaration - src/config.c: key=value parser with defaults fallback - src/main.c: replace hardcoded layout constants with config-driven UILayout - Config file loaded from next to binary (study-player.cfg) - Missing config file falls back to hardcoded defaults