@@ -605,14 +605,14 @@ function FlightLogGrapher(flightLog, graphConfig, canvas, craftCanvas, analyserC
605605
606606 //Draw an background for the line for a graph (at the origin and spanning the window)
607607 function drawAxisBackground ( plotHeight ) {
608- canvasContext . strokeStyle = "rgba(255,255,255,0.1)" ;
609- canvasContext . lineWidth = plotHeight ;
610-
611- canvasContext . beginPath ( ) ;
612- canvasContext . moveTo ( 0 , 0 ) ;
613- canvasContext . lineTo ( canvas . width , 0 ) ;
614-
615- canvasContext . stroke ( ) ;
608+ var axisGradient = canvasContext . createLinearGradient ( 0 , - plotHeight / 2 , 0 , plotHeight / 2 ) ;
609+ axisGradient . addColorStop ( 0.0 , 'rgba(255,255,255,0.1)' ) ;
610+ axisGradient . addColorStop ( 0.15 , 'rgba(0,0,0,0)' ) ;
611+ axisGradient . addColorStop ( 0.5 , 'rgba(0,0,0,0)' ) ;
612+ axisGradient . addColorStop ( 0.85 , 'rgba(0,0,0,0)' ) ;
613+ axisGradient . addColorStop ( 1.0 , 'rgba(255,255,255,0.1)' ) ;
614+ canvasContext . fillStyle = axisGradient ;
615+ canvasContext . fillRect ( 0 , - plotHeight / 2 , canvas . width , plotHeight ) ;
616616 }
617617
618618 //Draw a grid
0 commit comments