sschmidTU on develop
chore: update changelog for 1.7… (compare)
sschmidTU on develop
chore: fix changelog formatting… (compare)
sschmidTU on develop
cursor: add null check (sync wi… (compare)
sschmidTU on develop
chore: set osmd.Version to 1.7.… (compare)
sschmidTU on master
chore: update osmd.Version to 1… comment (what pedal EndNote mea… comment: Pedal.EndsStave, Begin… and 23 more (compare)
sschmidTU on develop
chore: bump version to 1.7.4-re… chore: update changelog for 1.7… Merge branch 'release/1.7.4' and 1 more (compare)
sschmidTU on 1.7.4
sschmidTU on develop
fix(Tremolo): Offset tremolo st… (compare)
sschmidTU on develop
fix(Articulation): support "har… (compare)
sschmidTU on glissando-and-slide
feat(Glissando): Add EngravingR… fix glissando error when start … (compare)
sschmidTU on develop
feat(Glissando): Add EngravingR… fix glissando error when start … (compare)
sschmidTU on develop
feat(Glissando): Implement glis… (compare)
@hallvors it's mainly historical, early on most properties were lowercase and private, and only some that should be public had getters and/or setters. But having getters and setters for everything in Typescript creates piles of boiler plate code, so we just made the properties public, and kept the lowercase in some cases for backwards compatibility.
cursor repetition support is already working in the audio player, will be integrated into osmd soon, see #379 (which you commented on), and #864
osmd.load()
without osmd.render()
, then the interpreted xml model is in osmd.sheet
.osmd.graphic.getClickedObject()
might help with this problem? If you calculate mouse coordinates relative to the SVG and pass an object with x and y to getClickedObject() you might get something to iterate to.. But I still don't know OSMD well enough, so maybe I'm barking up the wrong tree..
osmd.rules.DefaultColorCursor
in osmd 0.9.3
@phamconganh that is a weird MusicXML sample.
you can't easily remove these "words" expressions yet,
we can create an EngravingRule for that soon,
but you can try something like this after osmd.load()
:
removeUnknownExpressions() {
for (let i: number = 0; i < osmd.graphic.ParentMusicSheet.SourceMeasures.length; i++) {
const sourceMeasure: SourceMeasure = osmd.graphic.ParentMusicSheet.SourceMeasures[i];
for (let j: number = 0; j < sourceMeasure.StaffLinkedExpressions.length; j++) {
if (!this.graphicalMusicSheet.MeasureList[i] || !this.graphicalMusicSheet.MeasureList[i][j]) {
continue;
}
for (let k: number = 0; k < sourceMeasure.StaffLinkedExpressions[j].length; k++) {
sourceMeasure.StaffLinkedExpressions[j][k].unknownList = [];
}
}
}
}
but i haven't tested this. this is modified from MusicSheetCalculator.calculateMoodAndUnknownExpressions()
.
@rvilarl
In the sources there are some changes apply to vexflow (vexflowpatch). Would it make sense to include the sources of vexflow into osmd rather than vexflowpatch and decide what to update from vexflow or what to patch?
No, or I don't understand. Adding all vexflow classes that we don't patch is unnecessary, and would make it hard to see what we patched in vexflow.
In the sources there is only one reference to process.env: "public drawableBoundingBoxElement: string = process.env.DRAW_BOUNDING_BOX_ELEMENT;" would it make sense to replace that by an option in IOSMDOptions?
No, that is only used for continuous integration testing anyways, and i think it's currently mostly unused.
I made a prototype to support several cursors simustaneously with different colors and types. How would you suggest to approach the implementation of their configuration as additional parameters in the constructor of OpenSheetMusicDisplay(I did it this way): "constructor(container: string | HTMLElement, cursorColors: string[], cursorTypes: number[], options: IOSMDOptions = OSMDOptions.OSMDOptionsStandard())" or with additional IOSMDOptions?
It's great you made a prototype able to show multiple cursors!
However, i would avoid bloating the constructor, and i would simply add methods to add cursors. Maybe even locate these methods in the cursor class instead of OpenSheetMusicDisplay. Alternatively, cursorColors
and cursorTypes
could easily be integrated into IOSMDOptions.
process.env
usage, but since it isn't used for anything right now, it seems unimportant.
process.env.STATIC_FILES_SUBFOLDER
as well.