docstr: Build new CPAL table using list of palettes.
  
  Optionally build CPAL v1 table using paletteTypes, paletteLabels and
  paletteEntryLabels.
  
  Cf. `fontTools.colorLib.builder.buildCPAL`.
code: def setupCPAL(
      self,
      palettes,
      paletteTypes=None,
      paletteLabels=None,
      paletteEntryLabels=None,
  ):
      """Build new CPAL table using list of palettes.
  
      Optionally build CPAL v1 table using paletteTypes, paletteLabels and
      paletteEntryLabels.
  
      Cf. `fontTools.colorLib.builder.buildCPAL`.
      """
      from fontTools.colorLib.builder import buildCPAL
  
      self.font["CPAL"] = buildCPAL(
          palettes,
          paletteTypes=paletteTypes,
          paletteLabels=paletteLabels,
          paletteEntryLabels=paletteEntryLabels,
          nameTable=self.font.get("name"),
      )
  
imports: from .ttLib import TTFont, newTable
  from .ttLib.tables._c_m_a_p import cmap_classes
  from .ttLib.tables._g_l_y_f import flagCubic
  from .ttLib.tables.O_S_2f_2 import Panose
  from .misc.timeTools import timestampNow
  import struct
  from collections import OrderedDict
label_desc: Use image node_id 31 for calling the FontBuilder obj's underlying member method code with example usage: obj.setupCPAL(palettes, paletteTypes, paletteLabels, paletteEntryLabels) without return types