Returns a FoscTimeSignature.
Time signature.
| context | Gets context of time signature. |
| denominator | Gets denominator of time signature: |
| duration | Gets duration of time signature. |
| hasNonPowerOfTwoDenominator | Is true when time signature has non-power-of-two denominator. |
| hide | Is true when time signature should not appear in output (but should still determine effective time signature). |
| impliedProlation | Gets implied prolation of time signature. |
| numerator | Gets numerator of time signature. |
| pair | Gets numerator / denominator pair corresponding to time signature. |
| parameter | Is true. |
| partial | Gets duration of pick-up to time signature. |
| tweaks | Tweaks are not implemented on time signature. |
| add | !!!TODO: incomplete |
| copy | Copies time signature. |
| == | Is true when arg is a time signature with numerator and denominator equal to |
| format | Formats time signature. |
| >= | Is true when duration of time signature is greater than or equal to duration of arg. Otherwise false. |
| > | Is true when duration of time signature is greater than duration of arg. Otherwise false. |
| <= | Is true when duration of time signature is less than or equal to duration of arg. Otherwise false. |
| < | Is true when duration of time signature is less than duration of arg. Otherwise false. |
| [(abjad:](#(abjad:) | radd) |
| str | Gets string representation of time signature. |
| withPowerOfTwoDenominator | Makes new time signature equivalent to current time signature with power-of-two denominator. |
| inspect |
Example
a = FoscStaff(FoscLeafMaker().(#[60,62,64], [1/8]));
m = FoscTimeSignature(#[3,8]);
a[0].attach(m);
a.show;
!!!TODO: not yet working
Create a score-contexted time signature. Score-contexted time signatures format behind comments when no Abjad score container is found.
a = FoscStaff(FoscLeafMaker().(#[60,62,64], [1/8]));
m = FoscTimeSignature(#[3,8]);
a[0].attach(m, context: 'Score');
a.format;\new Staff {
\time 3/8
c'8
d'8
e'8
}a.show;
Score-contexted time signatures format normally when an Abjad score container is found.
a = FoscScore([a]);
a.show;
!!!TODO: tags not yet implemented
Time signatures can be tagged.
a = FoscStaff(FoscLeafMaker().(#[60,62,64], [1/8]));
m = FoscTimeSignature(#[3,8]);
a[0].attach(m, tag: "RED");
a.format;\new Staff {
\time 3/8
c'8
d'8
e'8
}Gets context of time signature.
Example
a = FoscTimeSignature(#[3,4]);
a.context.postln;StaffGets denominator of time signature:
Example
a = FoscTimeSignature(#[3,4]);
a.denominator.postln;4Gets duration of time signature.
Example
a = FoscTimeSignature(#[3,4]);
a.duration.postcs;FoscDuration(3, 4)Is true when time signature has non-power-of-two denominator.
Example
a = FoscTimeSignature(#[7,12]);
a.hasNonPowerOfTwoDenominator.postln;trueExample
a = FoscTimeSignature(#[3,4]);
a.hasNonPowerOfTwoDenominator.postln;falseIs true when time signature should not appear in output (but should still determine effective time signature).
Example
a = FoscStaff(FoscLeafMaker().(#[60,62,64,65], [1/4]));
m = FoscTimeSignature(#[4,4]);
a[0].attach(m);
m = FoscTimeSignature(#[2,4], hide: true);
a[2].attach(m);
a.format;\new Staff {
\time 4/4
c'4
d'4
e'4
f'4
}a.show;
!!!TODO: bug: result should be [[4,4],[4,4],[2,4],[2,4]]
FIXME: ERROR: Message byLeaf not understood.
iterate(a).byLeaf.do { |leaf|
FoscInspection(leaf).effectiveIndicator(FoscTimeSignature).pair.postln;
};Gets implied prolation of time signature.
Implied prolation of time signature with power-of-two denominator.
a = FoscTimeSignature(#[3,8]);
a.impliedProlation.postcs;FoscMultiplier(1, 1)Implied prolation of time signature with non-power-of-two denominator.
a = FoscTimeSignature(#[7,12]);
a.impliedProlation.postcs;FoscMultiplier(2, 3)Gets numerator of time signature.
Example
a = FoscTimeSignature(#[3,8]);
a.numerator.postln;3Gets numerator / denominator pair corresponding to time signature.
Example
a = FoscTimeSignature(#[3,8]);
a.pair.postln;[ 3, 8 ]Is true.
Example
a = FoscTimeSignature(#[3,8]);
a.parameter.postln;trueGets duration of pick-up to time signature.
Example
a = FoscTimeSignature(#[3,8]);
a.partial.postln;Tweaks are not implemented on time signature.
The LilyPond \time command refuses tweaks.
Override the LilyPond TimeSignature grob instead.
!!!TODO: incomplete
Adds time signature to timeSignature.
Returns new time signature.
Example
a = FoscTimeSignature([3, 4]);
b = FoscTimeSignature([7, 8]);
c = a + b;
c.pair.postln;[ 13, 8 ]Copies time signature.
Is true when arg is a time signature with numerator and denominator equal to this time signature. Also true when arg is a tuple with first and second elements equal to numerator and denominator of this time signature. Otherwise false.
Returns true or false.
Example
a = FoscTimeSignature([3, 4]);
b = FoscTimeSignature([3, 4]);
c = FoscTimeSignature([4, 4]);
d = FoscDuration([3, 4]);
(a == b).postln;true
(a == c).postln;false
(a == d).postln;falseFormats time signature.
Example
a = FoscTimeSignature([3, 8]);
a.format.postln;\time 3/8Is true when duration of time signature is greater than or equal to duration of arg. Otherwise false.
Returns true or false.
Example
a = FoscTimeSignature([3, 4]);
b = FoscTimeSignature([2, 4]);
(a >= b).postln;true
(b >= a).postln;falseIs true when duration of time signature is greater than duration of arg. Otherwise false.
Returns true or false.
Example
a = FoscTimeSignature([3, 4]);
b = FoscTimeSignature([2, 4]);
(a > b).postln;true
(b > a).postln;falseIs true when duration of time signature is less than or equal to duration of arg. Otherwise false.
Returns true or false.
Example
a = FoscTimeSignature([3, 4]);
b = FoscTimeSignature([2, 4]);
(a <= b).postln;false
(b <= a).postln;true
a <= 3; // FIXME: ERROR: Message 'duration' not understood.Is true when duration of time signature is less than duration of arg. Otherwise false.
Returns booelan.
Example
a = FoscTimeSignature([3, 4]);
b = FoscTimeSignature([2, 4]);
(a < b).postln;false
(b < a).postln;trueradd)
!!!TODO: see FoscFraction:performBinaryOpOnSimpleNumber
Gets string representation of time signature.
Example
a = FoscTimeSignature([3, 4]);
a.str;3/4Makes new time signature equivalent to current time signature with power-of-two denominator.
Returns new time signature.
Example
FoscTimeSignature([7, 16]).inspect;FoscTimeSignature.new