mirror of
https://github.com/microtherion/VocalEasel.git
synced 2024-12-22 11:14:00 +00:00
Add document size options
This commit is contained in:
parent
83438255fd
commit
30815a6acc
4040
English.lproj/VLDocument.nib/designable.nib
generated
4040
English.lproj/VLDocument.nib/designable.nib
generated
File diff suppressed because it is too large
Load Diff
BIN
English.lproj/VLDocument.nib/keyedobjects.nib
generated
BIN
English.lproj/VLDocument.nib/keyedobjects.nib
generated
Binary file not shown.
|
@ -72,9 +72,11 @@ vlExceptions = #(append
|
|||
|
||||
\score {
|
||||
<<
|
||||
\override Score.ChordName #'font-family = #'Didot
|
||||
\override Score.ChordName #'font-size = #<{CHORDSIZE}>
|
||||
\override Score.LyricText #'font-family = #'Baskerville
|
||||
\override Score.LyricText #'font-size = #<{LYRICSIZE}>
|
||||
\context ChordNames \chords {
|
||||
\override ChordName #'font-family = #'BitstreamVeraSansMono
|
||||
\override ChordName #'font-size = #6
|
||||
\set chordNameExceptions = #vlExceptions
|
||||
\set chordNameSeparator = ""
|
||||
\set chordRootNamer = #note-name->markup
|
||||
|
|
|
@ -35,6 +35,9 @@ enum {
|
|||
NSString * songArranger;
|
||||
NSString * songGroove;
|
||||
NSNumber * songTempo;
|
||||
float chordSize;
|
||||
float lyricSize;
|
||||
float staffSize;
|
||||
int playElements;
|
||||
NSString * tmpPath;
|
||||
NSFileWrapper * vcsWrapper;
|
||||
|
|
|
@ -76,7 +76,10 @@
|
|||
songComposer = @"";
|
||||
songArranger = @"";
|
||||
songGroove = @"Swing";
|
||||
songTempo = [[NSNumber numberWithInt:120] retain];
|
||||
songTempo = [[NSNumber alloc] initWithInt:120];
|
||||
chordSize = 6.0f;
|
||||
lyricSize = 0.0f;
|
||||
staffSize = 20.0f;
|
||||
playElements = kVLPlayAccompaniment|kVLPlayMelody|kVLPlayCountIn;
|
||||
sheetWin = nil;
|
||||
pdfWin = nil;
|
||||
|
@ -258,6 +261,24 @@
|
|||
[self didChangeSong];
|
||||
}
|
||||
|
||||
- (void) setChordSize:(float)size
|
||||
{
|
||||
[[[self undoManager] prepareWithInvocationTarget:self] setChordSize:chordSize];
|
||||
chordSize = size;
|
||||
}
|
||||
|
||||
- (void) setLyricSize:(float)size
|
||||
{
|
||||
[[[self undoManager] prepareWithInvocationTarget:self] setLyricSize:lyricSize];
|
||||
lyricSize = size;
|
||||
}
|
||||
|
||||
- (void) setStaffSize:(float)size
|
||||
{
|
||||
[[[self undoManager] prepareWithInvocationTarget:self] setStaffSize:staffSize];
|
||||
staffSize = size;
|
||||
}
|
||||
|
||||
- (int) repeatVolta
|
||||
{
|
||||
return repeatVolta;
|
||||
|
|
|
@ -126,6 +126,12 @@
|
|||
[ly substituteMacro:@"FORMATTING" withValue:@"ragged-last-bottom = ##f"];
|
||||
[ly substituteMacro:@"VLVERSION" withValue:
|
||||
[bndl objectForInfoDictionaryKey:@"CFBundleVersion"]];
|
||||
[ly substituteMacro:@"CHORDSIZE" withValue:
|
||||
[NSString stringWithFormat:@"%.1f", chordSize]];
|
||||
[ly substituteMacro:@"LYRICSIZE" withValue:
|
||||
[NSString stringWithFormat:@"%.1f", lyricSize]];
|
||||
[ly substituteMacro:@"STAFFSIZE" withValue:
|
||||
[NSString stringWithFormat:@"%.1f", staffSize]];
|
||||
[ly substituteMacro:@"CHORDS" withValue:
|
||||
[NSString stringWithUTF8String:writer.Chords().c_str()]];
|
||||
[ly substituteMacro:@"NOTES" withValue:
|
||||
|
|
|
@ -1061,6 +1061,10 @@ static int8_t sSharpAcc[] = {
|
|||
|
||||
- (IBAction)editDisplayOptions:(id)sender
|
||||
{
|
||||
NSUndoManager * undoMgr = [[self document] undoManager];
|
||||
[undoMgr setGroupsByEvent:NO];
|
||||
[undoMgr beginUndoGrouping];
|
||||
|
||||
VLSheetWindow * wc = [[self window] windowController];
|
||||
[wc setValue:[NSNumber numberWithInt:fNumTopLedgers]
|
||||
forKey:@"editNumTopLedgers"];
|
||||
|
@ -1078,6 +1082,11 @@ static int8_t sSharpAcc[] = {
|
|||
- (void)didEndDisplaySheet:(NSWindow *)sheet returnCode:(int)returnCode
|
||||
contextInfo:(void *)ctx
|
||||
{
|
||||
NSUndoManager * undoMgr = [[self document] undoManager];
|
||||
[undoMgr setActionName:@"Display Options"];
|
||||
[undoMgr endUndoGrouping];
|
||||
[undoMgr setGroupsByEvent:YES];
|
||||
|
||||
switch (returnCode) {
|
||||
case NSAlertFirstButtonReturn: {
|
||||
VLSheetWindow * wc = [[self window] windowController];
|
||||
|
@ -1088,6 +1097,7 @@ static int8_t sSharpAcc[] = {
|
|||
[self setNeedsDisplay:YES];
|
||||
} break;
|
||||
default:
|
||||
[undoMgr undo];
|
||||
break;
|
||||
}
|
||||
[sheet orderOut:self];
|
||||
|
|
Loading…
Reference in New Issue
Block a user