|
Muvicado HD
|
A drawable element backed by NSBezierPath with color, text, and MIDI attributes. More...
#include <Pad.h>


Instance Methods | |
| (NSString *) | - text |
| (void) | - setText: |
| (Boolean) | - hasAction |
| (id) | - initWithRect: |
| (id) | - initWithPad: |
| (id) | - initWithBezierPath: |
| (void) | - formatSvgToFile:withIndentLevel: |
| (void) | - translateX:Y: |
| (BOOL) | - containsPoint: |
| (void) | - transformUsingAffineTransform: |
| (void) | - draw |
| (id) | - copyWithZone: [implementation] |
| (void) | - setFillColor: [implementation] |
| (void) | - setLineColor: [implementation] |
| (void) | - setTransparency: [implementation] |
| (id) | - init [implementation] |
| (void) | - dealloc [implementation] |
| (void) | - encodeWithCoder: [implementation] |
| (id) | - initWithCoder: [implementation] |
| (void) | - drawNubs: [implementation] |
Protected Attributes | |
| NSBezierPath * | path |
| ! Primary geometry of the pad. | |
| NSBezierPath * | tracePath |
| ! Optional secondary path (e.g., trace/preview). | |
| NSMutableArray * | elementBag |
| ! Optional container for child elements. | |
| NSString * | text |
| ! Label drawn at the pad's center. | |
| NSColor * | fillColor |
| ! Fill color. | |
| NSColor * | lineColor |
| ! Stroke color. | |
| int | layer |
| ! Layer index this pad belongs to (0 means all). | |
| int | targetLayer |
| ! Target layer used when the pad acts as an action. | |
| int | port |
| ! Reserved for MIDI port (if used). | |
| int | channel |
| ! MIDI channel (0–15). | |
| int | note |
| ! MIDI note number (0–127). | |
| int | velocity |
| ! Default MIDI velocity (0–127). | |
| int | actionID |
| ! Optional UI action identifier (PadActionID). | |
| CGFloat | lineWidth |
| ! Stroke width used when drawing the path. | |
| BOOL | hilight |
| ! Temporary highlight state for playback feedback. | |
| BOOL | selected |
Properties | |
| CGFloat | transparency |
| ! Convenience access to fill alpha component. | |
| NSColor * | altFillColor |
| ! Alternate fill color for highlight. | |
A drawable element backed by NSBezierPath with color, text, and MIDI attributes.
Concrete implementation of Pad behaviors.
Pads are the primary interactive shapes in the canvas. They support selection, drawing, hit-testing, affine transforms, and persistence. Pads can be exported to SVG path data and used to trigger MIDI notes when interacted with.
|
protected |
|
protected |
| - (BOOL) containsPoint: | (NSPoint) | p |
|
implementation |
|
implementation |
| - (void) draw |
|
implementation |
|
implementation |
| - (void) formatSvgToFile: | (FILE *) | outfile | |
| withIndentLevel: | (int) | level |
Serializes the pad as an SVG <path> element.
| outfile | Destination C FILE*. |
| level | Indentation level for pretty-printing. |
Writes an SVG <path> with style, d attribute, and id metadata. Converts NSBezierPath elements to SVG commands (M, L, C, Z).
Definition at line 264 of file Pad.m.


| - (Boolean) hasAction |
|
implementation |
| - (id) initWithBezierPath: | (NSBezierPath *) | bp |
|
implementation |
| - (id) initWithPad: | (Pad *) | pad |
| - (id) initWithRect: | (NSRect) | rect |
|
implementation |
|
implementation |
| - (void) setText: | (NSString *) | t |
|
implementation |
| - (NSString *) text |
Returns the pad's text label.

| - (void) transformUsingAffineTransform: | (NSAffineTransform *) | transform |
| - (void) translateX: | (CGFloat) | deltaX | |
| Y: | (CGFloat) | deltaY |
|
readwriteprotected |
! Optional UI action identifier (PadActionID).
|
readwriteretainprotected |
|
readwriteretainprotected |
|
readwriteprotected |
|
readwriteprotected |
|
readwriteretainprotected |
|
readwriteprotected |
|
readwriteretainprotected |
|
readwriteprotected |
|
readwriteprotected |
|
readwriteprotected |
|
readwriteretainprotected |
|
readwriteretainprotected |
|
readwriteprotected |
|
readatomicassign |
|
readwriteatomic |