Documentation ¶
Overview ¶
A quick (and dirty!) editor for SPLICE drum patterns.
Index ¶
Constants ¶
View Source
const ( CBlack termbox.Attribute = termbox.ColorBlack CWhite termbox.Attribute = termbox.ColorWhite CRed termbox.Attribute = termbox.ColorRed CBlue termbox.Attribute = termbox.ColorBlue CGreen termbox.Attribute = termbox.ColorGreen CMagenta termbox.Attribute = termbox.ColorMagenta CYellow termbox.Attribute = termbox.ColorYellow CDefault termbox.Attribute = termbox.ColorDefault ABold termbox.Attribute = termbox.AttrBold )
Variables ¶
View Source
var (
ScrW, ScrH int
ScrHW, ScrHH int
)
Functions ¶
func MessageBox ¶
func MessageBox(title, msg string, bg termbox.Attribute)
Open a popup Window with a message.
Types ¶
type Box ¶
type Box struct { X int Y int Width int Height int Foreground termbox.Attribute Background termbox.Attribute }
A simple Box.
type Label ¶
type Label struct { X int Y int Text string Foreground termbox.Attribute Background termbox.Attribute }
A simple text label.
type Led ¶
Led is used to indicate which step the editor is on.
type StepButton ¶
type StepButton struct { Box // contains filtered or unexported fields }
Represents a step in a Track.
func StepButtonNew ¶
func StepButtonNew(w *Window, x, y int, stepRef *bool) *StepButton
Create a new StepButton, with a reference to the step it is «assigned» to. The StepButton will also listen for mouse click events on the Window to handle toggling.
type Window ¶
type Window struct {
// contains filtered or unexported fields
}
A Window simply handles the termbox event loop.
func WindowNew ¶
Create a new Window. A popup Window differs in that it doesn't clear the whole screen before drawing.
Click to show internal directories.
Click to hide internal directories.