Create inline C++ documentation system #92
Labels
No Label
Alpha Release Requirement
Bugfix
Demo Target
Documentation
Major Feature
Minor Feature
priority:tier1-active
priority:tier2-foundation
priority:tier3-future
Refactoring & Cleanup
system:animation
system:documentation
system:grid
system:input
system:performance
system:python-binding
system:rendering
system:ui-hierarchy
Tiny Feature
workflow:blocked
workflow:needs-benchmark
workflow:needs-documentation
No Milestone
No project
No Assignees
1 Participants
Notifications
Due Date
No due date set.
Dependencies
No dependencies set.
Reference: john/McRogueFace#92
Loading…
Reference in New Issue
No description provided.
Delete Branch "%!s(<nil>)"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Implement a macro system for documenting Python-exposed methods in C++ that automatically populates Python docstrings. This enables maintaining documentation in one place.
Affects: All Python-exposed objects (implementation infrastructure)
Implementation Complete ✅
The inline C++ documentation macro system is now fully implemented and operational.
What Was Delivered
Core Infrastructure:
src/McRFPy_Doc.hwith complete macro definitionstools/generate_dynamic_docs.pywith link transformation (HTML, Markdown, web, man page formats)Files Converted to Macro System:
src/PyVector.cpp- All 7 methods + 2 properties (magnitude, normalize, dot, distance_to, angle, copy, magnitude_squared, x, y)src/PyDrawable.cpp- 3 methods + 4 properties (get_bounds, move, resize, click, z_index, visible, opacity)src/UIBase.h- UIDRAWABLE_METHODS macro (affects all UI classes)src/UIBase.h- UIDRAWABLE_GETSETTERS macro (visible, opacity)src/UIFrame.cpp- click and z_index property overridessrc/UISprite.cpp- click and z_index property overridessrc/UICaption.cpp- click and z_index property overridessrc/UIGrid.cpp- click and z_index property overridesCode Removed:
tools/generate_complete_api_docs.py(959 lines)tools/generate_complete_markdown_docs.py(820 lines)tools/generate_api_docs.py(481 lines)tools/generate_api_docs_simple.py(118 lines)tools/generate_api_docs_html.py(1,601 lines)Documentation:
CLAUDE.mdwith macro usage guidelinesdocs/plans/2025-10-30-documentation-macro-system-design.mddocs/plans/2025-10-30-documentation-macro-system.mdVerification
✅ Vector class: 0 "..." placeholders (complete documentation)
✅ Drawable/Frame/Sprite/Caption/Grid: All inherited properties show enhanced docs
✅ Test suite: 16/16 property docstring tests pass
✅ Compilation: No errors or warnings
✅ Documentation generation: Successfully produces complete HTML and Markdown
Benefits Achieved
Follow-Up Work
Remaining classes to convert (tracked separately):
The infrastructure is complete and proven. Future conversions are straightforward applications of the established pattern.