Introduction
Introduction Statistics Contact Development Disclaimer Help
style.h - abc2ps - A powerful sheet setting tool using the simple abc notation
git clone git://vernunftzentrum.de/abc2ps.git
Log
Files
Refs
---
style.h (3162B)
---
1 /*
2 * This file is part of abc2ps,
3 * Copyright (C) 1996,1997,1998 Michael Methfessel
4 * See file abc2ps.c for details.
5 */
6
7 /* Global style parameters for the note spacing and Knuthian glue. */
8
9 /* Parameters here are used to set spaces around notes.
10 Names ending in p: prefered natural spacings
11 Names ending in x: expanded spacings
12 Units: everything is based on a staff which is 24 points high
13 (ie. 6 pt between two staff lines). */
14
15 /* name for this set of parameters */
16 #define STYLE "std"
17
18 /* ----- set_style_pars: set the parameters which control note spacing -…
19 void set_style_pars (strictness)
20 float strictness;
21 {
22 float y;
23
24 f0p=0.10; f0x=0.15;
25 f5p=0.60; f5x=0.7;
26 f1p=1.0; f1x=1.0;
27
28 lnnp=40; lnnx=90;
29 bnnp=1.0; bnnx=1.0;
30 fnnp=1.0; fnnx=1.0;
31
32 lbnp=30; lbnx=50;
33 bbnp=0.2; bbnx=0.2;
34 rbnp=0.12; rbnx=0.10;
35
36 lnbp=30; lnbx=55;
37 bnbp=0.9; bnbx=0.9;
38 rnbp=0.10; rnbx=0.1;
39
40 /* set parameters f0p,f1p according to strictness */
41 /* the y*y makes the scale a bit more intuitive .. */
42 y=1-strictness;
43 f0p=y*y*0.40;
44 f0x=y*y*0.60;
45 if (verbose>3)
46 printf ("Set style parameters, strictness %.2f (f0p=%.3f, f0x=%.3f)\…
47 strictness,f0p,f0x);
48
49 }
50
51
52 /* ----- Function of the spacing parameters ----- */
53
54 /* Parameters for the length-to-width mapping:
55 f0p, f5p, f1p are the return values for notes of zero duration,
56 half notes, and whole notes. A parabolic interpolation is
57 used for other note durations. The purpose is to allow a non-linear
58 relation between the note duration and the spacing on the paper.
59
60 Parameters for the note-note spacing:
61 (the internote spacing between two notes that follow
62 each other without a bar in between.)
63
64 - lnn is an overall multiplier, i.e. the final note width in points
65 is the return value of function nwid times lnn.
66 - bnn determines how strongly the first note enters into the spacing.
67 For bnn=1, the spacing is calculated using the first note.
68 For bnn=0, the spacing is the average for the two notes.
69 - fnn multiplies the spacing under a beam, to compress the notes a bi…
70
71 Parameters for the bar-note spacing:
72 (the spacing between a bar and note at the measure start.)
73
74 - lbn is the overall multiplier for the return values from nwid.
75 - rbn is the note duration which defines the default spacing.
76 - bbn determines how strongly the note duration enters into the spaci…
77 For bbn=1, the spacing is lbn times the return value of nwid.
78 For bbn=0, the spacing is lbn times the width of rbn times timesig.
79
80 Parameters for the note-bar spacing:
81 (the spacing between a note at the measure end and the bar.)
82
83 - lnb is the overall multiplier for the return values from nwid.
84 - rnb is the note duration which defines the default spacing.
85 - bnb determines how strongly the note duration enters into the spaci…
86 For bnb=1, the spacing is lnb times the return value of nwid.
87 For bnb=0, the spacing is lnb times the width of rbn times timesig.…
You are viewing proxied material from vernunftzentrum.de. The copyright of proxied material belongs to its original authors. Any comments or complaints in relation to proxied material should be directed to the original authors of the content concerned. Please see the disclaimer for more details.