def realizeSymbol(self, pp, grp, arp, symbol, annotation, onY2, clipPlotArea, clipDecoratedChart, drawMainSymbol, x, y, prevX, prevY, nextX, nextY):

        if (Double.NaN==(x))  or  (Double.NaN==(y)):
            # this point undefined (isNaN)
            return


        xPx = pp.xToPixel(x)
        yPx = pp.yToPixel(y, onY2)
        prevXPx = pp.xToPixel(prevX)
        prevYPx = pp.yToPixel(prevY, onY2)
        nextXPx = pp.xToPixel(nextX)
        nextYPx = pp.yToPixel(nextY, onY2)
        spacing = symbol.getFillSpacing()
        thickness = symbol.getFillThickness()
        canvas = grp.getCanvas()

        if 0 == spacing  and  None != canvas  and  thickness > 0:
            # if canvas rendered
            if None == self.horizontallyBanded:
                """
                * Continuous fill, canvas available, and not explicitly
                * horizontally or vertically banded. For example, BOX_*
                * symbol types are not explicitly oriented, but VBAR_*
                * (vertically) and HBAR_* (horizontally) are: use canvas
                * to draw a straight line between points.  <p>
                *
                * Code in this branch also gets executed by the LINE
                * symbol type.
                *
                """
                borderWidth = symbol.getBorderWidth()
                # negative (external) border widens line by 2*|borderWidth|
                if (borderWidth >= 0):
                    externalLineWidth = thickness
                else:
                    externalLineWidth = (thickness + 2*abs(borderWidth))
                if (borderWidth >= 0):
                    internalLineWidth = max(thickness-2*borderWidth,0)
                else:
                    internalLineWidth = thickness
                borderColor = symbol.getBorderColor()
                backgroundColor = symbol.getBackgroundColor()
                if (externalLineWidth > 0  and
                   ((GChartConsts.TRANSPARENT_BORDER_COLOR != borderColor  and
                   "transparent" != borderColor)  or
                   (GChartConsts.TRANSPARENT_BORDER_COLOR != backgroundColor  and
                   "transparent" != backgroundColor))):
                    if Double.NaN==(prevX)  or  Double.NaN==(prevY):
                        # first defined point after an undefined point ==> path
                        # (need to draw zero-thickness lines for possible line
                        # endings user may have defined by overriding beginPath)
                        canvas.beginPath()
                        canvas.moveTo(xPx - grp.x0, yPx - grp.y0)

                    if Double.NaN==(nextX)  or  Double.NaN==(nextY):
                        # last defined point before undefined point ==> draw accumulated path
                        if (GChartConsts.TRANSPARENT_BORDER_COLOR != borderColor  and
                           "transparent" != borderColor  and
                           externalLineWidth > 0):
                            canvas.setStrokeStyle(borderColor)
                            canvas.setLineWidth(externalLineWidth)
                            canvas.stroke()

                        if GChartConsts.TRANSPARENT_BORDER_COLOR != backgroundColor  and  "transparent" != backgroundColor  and  internalLineWidth > 0:
                            canvas.setLineWidth(internalLineWidth)
                            canvas.setStrokeStyle(backgroundColor)
                            canvas.stroke()


                    else:# not at end of chain ==> add one more segment to the path
                        # (need to draw doubled points for possibly "line join"
                        # user may have defined via overriding beginPath)
                        canvas.lineTo(nextXPx - grp.x0, nextYPx - grp.y0)

                # else lines are 0-width or transparent, so not rendered

            else:
                """
                * Explicitly oriented bandedness occurs only for vert or
                * horizontal bars. x,y coordinates are connected into
                * a path (as in a line chart), and then that path
                * is extended into a closed polygon by adding a
                * closing segment formed from an appropriate
                * section of an axis or baseline.
                *
                """

                """
                * Draw area interpolated between successive bars.
                *
                * Note that the "opposite" edge could be a point on an
                * x or y axis, or on the curve's baseline, depending
                * on the kind of bar chart involved: it's the edge
                * of the bar that is furthest from the x,y point.
                *
                """
                closeStrokeAndFill = False
                if False == self.horizontallyBanded:
                    if Double.NaN==(prevX)  or  Double.NaN==(prevY):
                        # 1st point, or 1st point after a break in the line
                        self.oppositeEdge = self.getEdgeOppositeVertically(
                                                pp, symbol, y, onY2)
                        canvas.beginPath()
                        canvas.moveTo(xPx - grp.x0, self.oppositeEdge - grp.y0)
                        canvas.lineTo(xPx - grp.x0, yPx - grp.y0)

                    if Double.NaN==(nextX)  or  Double.NaN==(nextY):
                        # last point, or last point before a break in the line
                        canvas.lineTo(xPx - grp.x0, self.oppositeEdge - grp.y0)
                        closeStrokeAndFill = True

                    else:
                        canvas.lineTo(nextXPx - grp.x0, nextYPx - grp.y0)


                else:

                    if Double.NaN==(prevX)  or  Double.NaN==(prevY):
                        # 1st point, or 1st point after a break in the line
                        self.oppositeEdge = self.getEdgeOppositeHorizontally(
                                            pp, symbol, x, onY2)
                        canvas.beginPath()
                        canvas.moveTo(self.oppositeEdge - grp.x0, yPx - grp.y0)
                        canvas.lineTo(xPx - grp.x0, yPx - grp.y0)

                    if Double.NaN==(nextX)  or  Double.NaN==(nextY):
                        # last point, or last point before a break in the line
                        canvas.lineTo(self.oppositeEdge - grp.x0, yPx - grp.y0)
                        closeStrokeAndFill = True

                    else:
                        canvas.lineTo(nextXPx - grp.x0, nextYPx - grp.y0)




                if closeStrokeAndFill:

                    canvas.closePath()
                    borderWidth = symbol.getBorderWidth()
                    # negative (external) border requires double-wide stroke
                    if (borderWidth >= 0):
                        lineWidth = borderWidth
                    else:
                        lineWidth = 2*abs(borderWidth)
                    borderColor = symbol.getBorderColor()
                    backgroundColor = symbol.getBackgroundColor()

                    """ XXX: Simply dropping the rendering as we do below does not
                    * exactly simulate the effect of transparent border/fill,
                    * specifically:
                    *
                    * <ol>
                    *   <li> Transparent internal border ==> the background
                    *          fill shines through the inner half of that border
                    *   <li> Transparent external border ==> Works OK
                    *   <li> Transparent fill w external border ==>
                    *           border extended internally to width
                    *   <li> Transparent fill w internal border ==> works OK
                    * </ol>
                    *
                    * GWTCanvas does not (?) provide a mechanism to "stroke
                    * transparent pixels", which is what I really needed. And
                    * emulating this, though possible via properly positioned
                    * inner/outter regions, etc. would have required a lot of effort
                    * to assure that sharply peaked angles, say, get rendered right.
                    *
                    """

                    # non-negative borders fill before stroking (thus
                    # stroke overwrites internal half of border)
                    if borderWidth is not 0  and  thickness > 0  and  GChartConsts.TRANSPARENT_BORDER_COLOR != backgroundColor  and  "transparent" != backgroundColor:
                        canvas.setFillStyle(backgroundColor)
                        canvas.fill()


                    # stroke whenever a border is present
                    if borderWidth != 0  and  GChartConsts.TRANSPARENT_BORDER_COLOR != borderColor  and  "transparent" != borderColor:
                        canvas.setStrokeStyle(borderColor)
                        canvas.setLineWidth(lineWidth)
                        canvas.stroke()


                    # negative borders fill AFTER stroking (thus zapping
                    # the internal half of the stroked border).
                    if borderWidth < 0  and  thickness > 0  and  GChartConsts.TRANSPARENT_BORDER_COLOR != backgroundColor  and  "transparent" != backgroundColor:
                        canvas.setFillStyle(backgroundColor)
                        canvas.fill()



         # if 0 == spacing  and  None != canvas  and  thickness > 0
        # next point defined
        # not a zero thickness connection
        elif (not Double.NaN==(nextX))  and  (not Double.NaN==(nextY))  and   thickness > 0  and    (x!=nextX  or  y!=nextY):
            # this/next point not overlayed
            if 0 == spacing:
                # 1px is as close as HTML-element
                spacing = 1;  # based filling can get to continuous

            d = self.distance(xPx,yPx,nextXPx,nextYPx)
            nChunks = int(round(d/spacing))
            if nChunks > 1:
                deltaX = nextXPx - xPx
                deltaY = nextYPx - yPx
                dXIsLonger = deltaX*deltaX > deltaY*deltaY
                if dXIsLonger:
                    deltaY /= deltaX; # from now on, dy is really dy/dx
                    deltaX /= nChunks;# from now on, dx is for 1 chunk

                else:
                    deltaX /= deltaY;  # from now on, dx is really dx/dy
                    deltaY /= nChunks; # from now on, dy is for 1 chunk

                # i==0 corresponds to the (to-be-drawn-last) symbol on (x,y).
                for i in range(1, nChunks):
                    # linearly interpolate forwards towards the next
                    # point; forward interpolation (usually) lets us
                    # place the "main" symbol for the original point on
                    # top of these interpolated symbols, in one pass.

                    # Rounding to the longer dimension first, then
                    # using that pixelated position to determine other
                    # dimension tends to keep points closer to being
                    # on the mathematically ideal line (at the cost of
                    # being less evenly spaced along that line). It's
                    # not too hard to see the improved alignment on
                    # GChartExample03, for example.
                    if dXIsLonger:
                        xi = round(xPx + deltaX * i)
                        yi = round(yPx + deltaY*(xi - xPx))

                    else:
                        # delta y is longer
                        yi = round(yPx + deltaY * i)
                        xi = round(xPx + deltaX*(yi - yPx))



                    # interpolated symbols set width & height to
                    # thickness, but are otherwise the same as main
                    # symbol at (x,y)
                    self.realizeOneImageOfSymbol(pp, grp, arp, symbol, None,
                                    onY2,
                                    clipPlotArea,
                                    clipDecoratedChart,
                                    xi, yi,
                                    prevXPx, prevYPx,
                                    nextXPx, nextYPx,
                                    thickness,
                                    thickness)


            # else points too close to require any "filler" elements

        # the "main" symbol (the one on the (x,y) point itself) is
        # rendered last to put it on top of interpolated images; this
        # is also where any annotation on the point gets rendered.
        if drawMainSymbol:
            self.realizeOneImageOfSymbol(pp, grp, arp, symbol, annotation,
                            onY2,
                            clipPlotArea,
                            clipDecoratedChart,
                            xPx, yPx,
                            prevXPx, prevYPx,
                            nextXPx, nextYPx,
                            symbol.getWidth(pp),
                            symbol.getHeight(pp,onY2))






 # end of class SymbolType
dataset/ETHPy150Open anandology/pyjamas/library/gwt/chart/SymbolType.py/SymbolType.realizeSymbol/operator `>=` -> `is not`