Callback Naming Standardization #139
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#139
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?
Rename callback properties to consistent
on_*pattern across all event types.Context
Current API uses inconsistent naming:
drawable.click- callback propertymcrfpy.keypressScene()- function to set scene keyboard handlerAs we add more event types (enter, exit, move, cell events), we need consistent naming. This is a breaking change - do it now before the API stabilizes further.
Definition of Done
clickproperty toon_clickon all UIDrawableson_keyproperty to UIDrawables (optional per-widget keyboard handler)scene.on_keyor keepkeypressScene()but document deprecation pathNew Callback Pattern
Callback Validation
When a callback is assigned, McRogueFace should inspect the callable's signature:
inspect.signature()orcallable.__code__.co_argcountwarnings.warn()*args, **kwargssignatures as compatible with anythingMigration
This is a breaking change. Options:
Recommend option 1 given current project maturity level.
Dependencies
Related Issues