Commit Graph
37 Commits
Author SHA1 Message Date
shweetandClaude Opus 5.5 ce3b544392 Autosave edited spritesheets beside their files
With document autosave, spritesheets with unsaved pixel edits are written
to a hidden .<name>.png.autosave beside their PNG (only when changed since
their last autosave; a spritesheet edit alone also triggers the document
autosave). Restoring a document's autosave brings them back as unsaved
edits without touching the PNGs. The copies are removed when the
spritesheet is saved or reloaded, or the document's autosave is discarded.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 21:28:02 -04:00
shweetandClaude Opus 5.5 d08f59d7ba Stage 8a: panels as plain functions; content selection on the uid Selection
- New panel kit (imgui/window/panel.*): list/card drawing with multi-select,
  rename, arrow keys, drag hooks and tooltips; a list panel helper for the
  context menu, shortcuts and footer; panels build their Actions inline.
- Layers, nulls, events, sounds, spritesheets, regions, shaders and
  animations are plain functions over a small persistent state struct.
- Content items are selected by uid in the shared Selection (one kind per
  content type, plus a focus per kind); regions are those of the focused
  spritesheet. Selection survives undo, paste and removal like the timeline's.
- Combo labels are computed when drawn (Document::choices_get).
- Deletes the Window callback framework, WINDOW_FLAGS, Storage and the
  per-window selection snapshot fields.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 17:47:21 -04:00
shweetandClaude Opus 5.5 0b6f67d9bd Stage 7: typed model; Element tree is internal to model/xml.cpp
- src/model: typed Model (Info, Content, nested TrackGroup/AnimationGroup,
  copy-on-write shared animations, Extras/XmlNode passthrough for unknown XML,
  layout vectors so saves stay byte-identical).
- src/edit, Document, Selection, Snapshots, every window, the timeline, wizards
  and popups now read and edit model::Model; no UI code touches Element.
- anm2/ is reduced to the XML reader/writer/normalizer behind model/xml.cpp;
  dead Element operations (merge, regions, item_add, rect, frame helpers,
  element_get/unused, deserialize) are deleted.
- Goldens, invariants, undo walk and the local corpus (1,251 files) match.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 16:53:17 -04:00
shweetandClaude Opus 5.5 2d0f70b1e5 Stage 6: Document::change() always refreshes derived data; ChangeType removed
change() now flushes drafts, re-syncs assets and shaders, rebuilds every label
list and the uid index, and commits. Document::ChangeType, the switch in
change(), the type parameter of edit_apply/edit_run/edit_push/assets_sync,
Window::changeType and every per-call change type (about 40 sites) are gone.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 15:59:44 -04:00
shweetandClaude Opus 5.5 ec72a30ce0 Canvas windows, settings and manager: share view code and list I/O
- CanvasView base holds checker pan sync, zoom step, grid panel, view buttons and view context menu
- frame_parent_model_get replaces five root/group transform compositions
- Canvas builds VAOs through one helper, unifies uniform setters and frees the texture VAO/VBO/EBO (leak fix)
- Settings load/save loop over component suffix tables; unused settings Type enum removed
- Manager shares one path-list load/save for recent and autosave files
- Anonymous namespaces removed per project style

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 13:50:13 -04:00
shweetandClaude Opus 5.5 d926fc6677 Split window.cpp per window and drive menus from one flag table
- WINDOW_FLAGS table builds every context menu, footer and shortcut set
- Shared list-row and card-row renderers replace per-window copies
- Layers/nulls/events share one properties popup; Manager keeps one item popup API
- Regions, spritesheets and sounds drop hand-built menus, footers and shortcut blocks
- Animation remove and cut share one erase path that also clears group ids
- Index-mapped multi-select fixes shift-range over non-contiguous ids
- Fix Remove Unused tooltip showing the Add shortcut and the missing break in item properties

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 13:27:34 -04:00
shweetandClaude Opus 5.5 3f31cedeed Slim Document: move data-model code out, unify edit plumbing
- Region generate/scan move to anm2/regions.cpp; both generators number from 1
- file_merge moves to anm2/merge.cpp and is table-driven
- MaxRects packer moves to util/pack
- Uniform config apply/trim/save move to resource/shader
- Snapshots push from their owned state; Document snapshot wrappers removed
- DocumentData base replaces the hand-written move constructor
- toast_log replaces 55 duplicated toast + English log pairs
- Apply repo .clang-format to touched files

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 13:08:00 -04:00
shweetandClaude Opus 5.5 a9f48bc3a0 De-bloat anm2 core: templates, tables, unified emitter
- Collapse const/non-const pairs into templates; Anm2::element_get uses deducing this
- Drive container/track/item mappings from ANM2_ELEMENT_TYPES, ANM2_ITEM_TYPES and TRACK_CONTAINERS
- One sink-based emitter feeds both XML writing and hashing
- frame_mix and frame_bake_split replace five copies of the bake/lerp loop
- item_add replaces layer_animation_add/null_animation_add
- Fix timeline split ignoring shear

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
2026-10-03 12:54:24 -04:00
shweet 0ea0afe1e3 pivot fix 2026-06-13 14:56:02 -04:00
shweet e8083d7817 Auto bake frames! new attributes! 2026-06-07 12:40:56 -04:00
shweet 8c421595c4 more tweaks 2026-05-22 11:13:39 -04:00
shweet 1bc5199e3b Holy vibecode Batman! 2026-05-21 21:00:57 -04:00
shweet 7db835e6d4 managed autosave deletion 2026-05-20 11:41:40 -04:00
shweet b345c27a87 autosave_restore moved out of welcome in case of loading from file 2026-05-11 17:29:52 -04:00
shweet d39a1dac3c miscellaneous sloppa fixes 2026-04-20 13:54:49 -04:00
shweet b60c4bc295 I N T E R P O L A T I O N 2026-04-14 14:28:14 -04:00
shweet 0b91382f0f changes + more windows bs 2026-03-29 20:13:24 -04:00
shweet c11b404392 let's actually stage those changes... 2026-03-09 23:09:37 -04:00
shweet 64d6a1d95a Mega Region Update. 2026-02-05 21:34:42 -05:00
shweet bd3fdbf930 saving fixes? 2026-01-11 01:20:21 -05:00
shweet b41b6df19e handling saving issues in certain contexts/new shortcuts 2026-01-05 04:16:51 -05:00
shweet 119bbc4081 Refactor + render animation tweaks + updated frame properties + bug fixes 2025-12-17 23:02:00 -05:00
shweet 31ac9707e7 preliminary utf-16 stuff 2025-12-13 21:54:29 -05:00
shweet c77701fe72 yeah these too 2025-12-13 01:21:57 -05:00
shweet 300e322b9d Sound drag/drop 2025-11-30 22:25:57 -05:00
shweet d414375d82 fix autosaving 2025-11-16 21:08:50 -05:00
shweet c57c32aca8 ...Anm2Ed 2.0 2025-11-13 22:06:09 -05:00
shweet 1b21080fe2 recent files issues 2025-11-11 23:11:27 -05:00
shweet a1f6bda59d ......................................................... 2025-11-11 22:37:38 -05:00
shweet 517a8262a6 few more windows issues 2025-11-11 19:00:00 -05:00
shweet d9a05947c0 more minor polish there and here 2025-11-11 16:07:02 -05:00
shweet 07096c487b fuck git and fuck vs code 2025-11-11 11:25:46 -05:00
shweet e2799b1e58 timeline refactor, bit broken rn 2025-11-09 10:35:21 -05:00
shweet 1e35910b0a Refactoring, FFmpeg updates 2025-11-03 00:16:05 -05:00
shweet 62cd94ca78 Big refactor, shuffling a lot of files around 2025-11-01 19:51:19 -04:00
shweet 729d5fb216 Autosave feature, spritesheet editor dashed lines, refactoring, fixes 2025-10-28 15:47:54 -04:00
shweet fe9366f9ef context menus, document refactoring, fixes 2025-10-26 00:10:44 -04:00