commit/galaxy-central: jgoecks: Trackster: ensure that reads are drawn in squish and pack modes even when view area is large by setting a minimum width of 1px.
1 new changeset in galaxy-central: http://bitbucket.org/galaxy/galaxy-central/changeset/dd604de40ac4/ changeset: r5349:dd604de40ac4 user: jgoecks date: 2011-04-05 23:59:43 summary: Trackster: ensure that reads are drawn in squish and pack modes even when view area is large by setting a minimum width of 1px. affected #: 1 file (317 bytes) --- a/static/scripts/trackster.js Tue Apr 05 14:16:26 2011 -0400 +++ b/static/scripts/trackster.js Tue Apr 05 17:59:43 2011 -0400 @@ -1126,10 +1126,9 @@ /** * Tiles for TiledTracks. */ -var Tile = function(track, canvas, histo_max) { +var Tile = function(track, canvas) { this.track = track; this.canvas = canvas; - this.histo_max = histo_max; }; /** @@ -2192,7 +2191,7 @@ // Start dealing with row-by-row tracks - // If working with a mode where slotting is neccesary, update the incremental slotting + // If working with a mode where slotting is necessary, update the incremental slotting var slots, slots_required = 1; if ( mode === "no_detail" || mode === "Squish" || mode === "Pack" ) { slots_required = this.incremental_slots(w_scale, result.data, mode); @@ -3164,6 +3163,14 @@ var seq_start = feature_start + base_offset, s_start = Math.floor( Math.max(0, (seq_start - tile_low) * w_scale) ), s_end = Math.floor( Math.max(0, (seq_start + cig_len - tile_low) * w_scale) ); + + // Make sure that read is drawn even if it too small to be rendered officially; in this case, + // read is drawn at 1px. + // TODO: need to ensure that s_start, s_end are calcuated the same for both slotting + // and drawing. + if (s_start === s_end) { + s_end += 1; + } switch (cig_op) { case "H": // Hard clipping. Repository URL: https://bitbucket.org/galaxy/galaxy-central/ -- This is a commit notification from bitbucket.org. You are receiving this because you have the service enabled, addressing the recipient of this email.
participants (1)
-
Bitbucket