Skip to content

Commit

Permalink
Merge branch 'dev' into main
Browse files Browse the repository at this point in the history
  • Loading branch information
paulrosen committed Feb 25, 2022
2 parents 946eab4 + 3848245 commit 0d573f0
Show file tree
Hide file tree
Showing 11 changed files with 197 additions and 174 deletions.
10 changes: 10 additions & 0 deletions RELEASE.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,13 @@
# Version 6.0.1

## Bugs

* Make the printable example long enough to be on two pages.

* Fix paper size so that the bottom of a narrow staff is not cut off.

* Add a little padding to stems so they aren't cut off.

# Version 6.0.0

## Bugs
Expand Down
4 changes: 2 additions & 2 deletions dist/abcjs-basic-min.js

Large diffs are not rendered by default.

7 changes: 4 additions & 3 deletions dist/abcjs-basic.js
Original file line number Diff line number Diff line change
Expand Up @@ -19714,7 +19714,8 @@ AbstractEngraver.prototype.addNoteToAbcElement = function (abselem, elem, dot, s
abselem.addRight(new RelativeElement(null, dx, 0, p1, {
"type": "stem",
"pitch2": p2,
linewidth: width
linewidth: width,
bottom: p1 - 1
})); //var RelativeElement = function RelativeElement(c, dx, w, pitch, opt) {

min = Math.min(p1, p2);
Expand Down Expand Up @@ -24558,7 +24559,7 @@ module.exports = drawSeparator;

function setPaperSize(renderer, maxwidth, scale, responsive) {
var w = (maxwidth + renderer.padding.right) * scale;
var h = (renderer.y + renderer.padding.bottom) * scale;
var h = renderer.y * scale;
if (renderer.isPrint) h = Math.max(h, 1056); // 11in x 72pt/in x 1.33px/pt
// TODO-PER: We are letting the page get as long as it needs now, but eventually that should go to a second page.
// for accessibility
Expand Down Expand Up @@ -28186,7 +28187,7 @@ module.exports = unhighlight;
\********************/
/***/ (function(module) {

var version = '6.0.0';
var version = '6.0.1';
module.exports = version;

/***/ })
Expand Down
2 changes: 1 addition & 1 deletion dist/abcjs-basic.js.map

Large diffs are not rendered by default.

4 changes: 2 additions & 2 deletions dist/abcjs-plugin-min.js

Large diffs are not rendered by default.

12 changes: 12 additions & 0 deletions examples/printable.html
Original file line number Diff line number Diff line change
Expand Up @@ -75,6 +75,18 @@ <h1>PDF Maker</h1>
|:D2|EB{c}BA B2 EB|~B2 AB dBAG|FDAD BDAD|FDAD dAFD|
EBBA B2 EB|B2 AB defg|afe^c dBAF|DEFD E2:|
|:gf|eB B2 efge|eB B2 gedB|A2 FA DAFA|A2 FA defg|
eB B2 eBgB|eB B2 defg|afe^c dBAF|DEFD E2:|
|:D2|EB{c}BA B2 EB|~B2 AB dBAG|FDAD BDAD|FDAD dAFD|
EBBA B2 EB|B2 AB defg|afe^c dBAF|DEFD E2:|
|:gf|eB B2 efge|eB B2 gedB|A2 FA DAFA|A2 FA defg|
eB B2 eBgB|eB B2 defg|afe^c dBAF|DEFD E2:|
|:D2|EB{c}BA B2 EB|~B2 AB dBAG|FDAD BDAD|FDAD dAFD|
EBBA B2 EB|B2 AB defg|afe^c dBAF|DEFD E2:|
|:gf|eB B2 efge|eB B2 gedB|A2 FA DAFA|A2 FA defg|
eB B2 eBgB|eB B2 defg|afe^c dBAF|DEFD E2:|
|:D2|EB{c}BA B2 EB|~B2 AB dBAG|FDAD BDAD|FDAD dAFD|
EBBA B2 EB|B2 AB defg|afe^c dBAF|DEFD E2:|
|:gf|eB B2 efge|eB B2 gedB|A2 FA DAFA|A2 FA defg|
eB B2 eBgB|eB B2 defg|afe^c dBAF|DEFD E2:|
</textarea>

Expand Down
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
{
"name": "abcjs",
"version": "6.0.0",
"version": "6.0.1",
"description": "Renderer for abc music notation",
"main": "index.js",
"types": "types/index.d.ts",
Expand Down
2 changes: 1 addition & 1 deletion src/write/abc_abstract_engraver.js
Original file line number Diff line number Diff line change
Expand Up @@ -729,7 +729,7 @@ var ledgerLines = function(abselem, minPitch, maxPitch, isRest, symbolWidth, add
else
p1 += 1;
}
abselem.addRight(new RelativeElement(null, dx, 0, p1, {"type": "stem", "pitch2":p2, linewidth: width}));
abselem.addRight(new RelativeElement(null, dx, 0, p1, {"type": "stem", "pitch2":p2, linewidth: width, bottom: p1-1}));
//var RelativeElement = function RelativeElement(c, dx, w, pitch, opt) {
min = Math.min(p1, p2);
}
Expand Down
2 changes: 1 addition & 1 deletion src/write/draw/set-paper-size.js
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
function setPaperSize(renderer, maxwidth, scale, responsive) {
var w = (maxwidth+renderer.padding.right)*scale;
var h = (renderer.y+renderer.padding.bottom)*scale;
var h = (renderer.y)*scale;
if (renderer.isPrint)
h = Math.max(h, 1056); // 11in x 72pt/in x 1.33px/pt
// TODO-PER: We are letting the page get as long as it needs now, but eventually that should go to a second page.
Expand Down
Loading

0 comments on commit 0d573f0

Please sign in to comment.