ColorTools[Palette] - Maple Programming Help

Online Help

All Products    Maple    MapleSim


Home : Support : Online Help : Graphics : Packages : ColorTools : Palette Object Commands : ColorTools/Palette/numcolors

ColorTools[Palette]

  

numcolors

  

retrieve the number of defining colors in a Palette object

  

numelems

  

retrieve the current total number of colors in a Palette object

 

Calling Sequence

Parameters

numcolors

numelems

Examples

Compatibility

Calling Sequence

numcolors(P)

numelems(P)

Parameters

P

-

Palette object created with ColorTools:-Palette

numcolors

• 

The numcolors command returns the number of indexable colors in a Palette object when it was created before any automatic palette expansion.

numelems

• 

The numelems command returns the number of colors in a Palette object including any colors added during automatic palette expandsion.

Examples

PColorTools:-GetPalettespring

PPalette Spring:BlueRoseYellowGreenBlueGreenVioletCobaltYellowPurpleRedGreenBluePaleGreenOrangePurpleGreenSeaBluePaleYellowPaleBlueGreen

(1)

numcolorsP

16

(2)

numelemsP

16

(3)

PnumcolorsP+10

RGB : 0.8 0 0.606

(4)

numcolorsP

16

(5)

numelemsP

27

(6)

Compatibility

• 

The ColorTools[Palette][numcolors] and ColorTools[Palette][numelems] commands were introduced in Maple 16.

• 

For more information on Maple 16 changes, see Updates in Maple 16.

See Also

ColorTools[Palette]

numelems