GenomeView.drawVerticalPositionLine doesn't honour parent argument #545

Closed
yeban opened this Issue Dec 10, 2014 · 2 comments

Comments

Projects
None yet
2 participants
@yeban
Contributor

yeban commented Dec 10, 2014

drawVerticalPositionLine simply passes parent argument to drawBasePairLabel function. And drawBasePairLabel instead seems to expect scaleDiv in args, and not parent.

This seems to work at L1308 -

-    this.drawBasePairLabel({ name: 'single', offset: 0, x: numX, parent: parent });
+    this.drawBasePairLabel({ name: 'single', offset: 0, x: numX, scaleDiv: parent });
@cmdcolin

This comment has been minimized.

Show comment
Hide comment
@cmdcolin

cmdcolin Dec 10, 2014

Contributor

There's one weird side effect of this change. Normally, when you hold down shift, the red line with the base pair marker is drawn at the top, but with this change, the red line is still drawn but the base pair marker is at the bottom of the screen

Reason:

this.drawVerticalPositionLine( this.outerTrackContainer, evt );
Contributor

cmdcolin commented Dec 10, 2014

There's one weird side effect of this change. Normally, when you hold down shift, the red line with the base pair marker is drawn at the top, but with this change, the red line is still drawn but the base pair marker is at the bottom of the screen

Reason:

this.drawVerticalPositionLine( this.outerTrackContainer, evt );
@yeban

This comment has been minimized.

Show comment
Hide comment
@yeban

yeban Dec 10, 2014

Contributor

I guess that's because height of outerTrackContainer is way too much and that affects this calculation.

What I really want is the ability to position base pair label lower than normal. I'm calling drawVerticalPositionLine when resizing exon to show a vertical marker, and the base pair label (while nifty) obstructs the resize view.

screen shot 2014-12-10 at 9 27 02 pm

With the above diff applied, and using edit track's div as the parent the result is agreeable.

screen shot 2014-12-10 at 9 25 12 pm

I disabled the shift behaviour long back in Afra, so didn't realise that would break.

this.drawVerticalPositionLine( this.outerTrackContainer, evt );

you could use a different parent container perhaps? this.scaleTrackDiv?

Contributor

yeban commented Dec 10, 2014

I guess that's because height of outerTrackContainer is way too much and that affects this calculation.

What I really want is the ability to position base pair label lower than normal. I'm calling drawVerticalPositionLine when resizing exon to show a vertical marker, and the base pair label (while nifty) obstructs the resize view.

screen shot 2014-12-10 at 9 27 02 pm

With the above diff applied, and using edit track's div as the parent the result is agreeable.

screen shot 2014-12-10 at 9 25 12 pm

I disabled the shift behaviour long back in Afra, so didn't realise that would break.

this.drawVerticalPositionLine( this.outerTrackContainer, evt );

you could use a different parent container perhaps? this.scaleTrackDiv?

@cmdcolin cmdcolin added this to the 1.11.6 milestone Jan 23, 2015

@cmdcolin cmdcolin closed this in f8d2851 Feb 6, 2015

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment