forked from bitcoinafterlife/bal-electrum-plugin
docs(qt.py): Add detailed interval documentation for HeirsLockTimeEdit class behavior
This commit is contained in:
15
qt.py
15
qt.py
@@ -1281,10 +1281,22 @@ class _LockTimeEditor:
|
||||
|
||||
Features:
|
||||
- Supports both raw locktime values and human-readable date formats
|
||||
- Emits valueEdited signal when the locktime value changes
|
||||
- Emits valueEdited signal when the locktime value is edited
|
||||
- Provides threshold-based validation for locktime values
|
||||
- Integrates with heir distribution workflows
|
||||
|
||||
Behavior:
|
||||
The class handles three types of locktime values:
|
||||
1. **Timestamps**: Raw integer values representing Unix timestamps
|
||||
2. **Day intervals**: Values ending with 'd' (e.g., '3d' = 3 days from now)
|
||||
3. **Year intervals**: Values ending with 'y' (e.g., '2y' = 2 years from now)
|
||||
|
||||
Only these formats are valid:
|
||||
- Examples: '1609459200', '3d', '2y'
|
||||
- Invalid: 'invalid', '5m', '10x'
|
||||
|
||||
The widget automatically converts day/year intervals to appropriate timestamps.
|
||||
|
||||
Attributes:
|
||||
valueEdited (pyqtSignal): Signal emitted when the locktime value is edited
|
||||
locktime_threshold (int): Minimum threshold value for locktime (default: 50000000)
|
||||
@@ -1294,7 +1306,6 @@ class _LockTimeEditor:
|
||||
default_index (int): Default index for the combo box (default: 1)
|
||||
"""
|
||||
|
||||
>>>>>>> origin/doc
|
||||
class HeirsLockTimeEdit(QWidget, _LockTimeEditor):
|
||||
valueEdited = pyqtSignal()
|
||||
locktime_threshold = 50000000
|
||||
|
||||
Reference in New Issue
Block a user