docs: def scourCoordinates(data, options, force_whitespace=False, control_points=[], flags=[]):
      """
         Serializes coordinate data with some cleanups:
            - removes all trailing zeros after the decimal
            - integerize coordinates if possible
            - removes extraneous whitespace
            - adds spaces between values in a subcommand if required (or if force_whitespace is True)
      """
      if data is not None:
          newData = []
          c = 0
          previousCoord = ''
          for coord in data:
              is_control_point = c in control_points
              scouredCoord = scourUnitlessLength(coord,
                                                 renderer_workaround=options.renderer_workaround,
                                                 is_control_point=is_control_point)
              # don't output a space if this number starts with a dot (.) or minus sign (-); we only need a space if
              #   - this number starts with a digit
              #   - this number starts with a dot but the previous number had *no* dot or exponent
              #     i.e. '1.3 0.5' -> '1.3.5' or '1e3 0.5' -> '1e3.5' is fine but '123 0.5' -> '123.5' is obviously not
              #   - 'force_whitespace' is explicitly set to 'True'
              # we never need a space after flags (occuring in elliptical arcs), but librsvg struggles without it
              if (c > 0
                      and (force_whitespace
                           or scouredCoord[0].isdigit()
                           or (scouredCoord[0] == '.' and not ('.' in previousCoord or 'e' in previousCoord)))
                      and ((c-1 not in flags) or options.renderer_workaround)):
                  newData.append(' ')
  
              # add the scoured coordinate to the path string
              newData.append(scouredCoord)
              previousCoord = scouredCoord
              c += 1
  
          # What we need to do to work around GNOME bugs 548494, 563933 and 620565, is to make sure that a dot doesn't
          # immediately follow a command  (so 'h50' and 'h0.5' are allowed, but not 'h.5').
          # Then, we need to add a space character after any coordinates  having an 'e' (scientific notation),
          # so as to have the exponent separate from the next number.
          # TODO: Check whether this is still required (bugs all marked as fixed, might be time to phase it out)
          if options.renderer_workaround:
              if len(newData) > 0:
                  for i in range(1, len(newData)):
                      if newData[i][0] == '-' and 'e' in newData[i - 1]:
                          newData[i - 1] += ' '
                  return ''.join(newData)
          else:
              return ''.join(newData)
  
      return ''