Source code for jdxi_editor.ui.editors.pattern.models

from dataclasses import dataclass


@dataclass
[docs] class NoteButtonAttrs: """Note Button Attributes"""
[docs] NOTE = "note"
[docs] NOTE_DURATION = "note_duration"
[docs] NOTE_VELOCITY = "note_velocity"
@dataclass
[docs] class ButtonAttrs: """Button Attrs"""
[docs] DURATION = "duration"
[docs] CHECKED = "checked"
[docs] NOTE = "note"
[docs] VELOCITY = "velocity"
@dataclass
[docs] class ClipboardData:
[docs] SOURCE_BAR: str = "source_bar"
[docs] START_STEP: str = "start_step"
[docs] END_STEP: str = "end_step"
[docs] NOTES_DATA: str = "notes_data"
[docs] class SequencerStyle:
[docs] ROW_FONT_SIZE = 20
[docs] ROW_FONT_WEIGHT = "bold"
@staticmethod
[docs] def row_label(color: str) -> str: return ( f"font-size: {SequencerStyle.ROW_FONT_SIZE}px;" f"font-weight: {SequencerStyle.ROW_FONT_WEIGHT};" f"color: {color};" )