+ /* Before drawing anything, position each staff based on the size
+ * of each (including ledger lines) */
+ staff_y_pos = 0;
+ for (i = 0; i < score->num_staves; i++) {
+ score_staff_t *staff = score->staves[i];
+ staff_y_pos += staff->upper_ledger_lines * score->space_height;
+ staff->y_pos = staff_y_pos;
+ staff_y_pos += (score->staff_height +
+ staff->lower_ledger_lines * score->space_height +
+ score->staff_height);
+ }
+