Set Colors - Maple Help
For the best experience, we recommend viewing online help using Google Chrome or Microsoft Edge.

Online Help

All Products    Maple    MapleSim


Student

  

SetColors

  

set the colors of plot objects in the Student subpackages

 

Calling Sequence

Parameters

Description

Examples

Compatibility

Calling Sequence

SetColors(color1, color2, ...)

SetColors(colors)

Parameters

color1, color2, ...

-

(optional) valid colors

colors

-

(optional) a collection of colors, either the name of a ColorTools:-Palette or a container that can be converted to a list of colors.

Description

• 

The SetColors(color1, color2, ...) calling sequence sets the colors of the plot objects in the Student subpackages. SetColors affects plot objects displayed using visualization routines within the worksheet interface, as well as plot objects displayed in the interactive tutors. The given colors will replace the first colors in in the current list of colors, any further colors will remain unchanged.

• 

The SetColors( colors ) calling sequence sets the entire list of current colors. If colors is the name of a known ColorTools Palette, the colors of that palette will be used. Otherwise, convert/list will be called on colors and if the result is a list of colors, that will replace the current colors. If there are fewer than 10 colors in colors, the list will repeated so the current colors list contains at least 10 colors.

• 

If called with no arguments, a standard color selection Maplet application is displayed.

• 

In all cases, SetColors returns a list of the current colors.

• 

By default, the Student subpackages use the CVD color palette.

• 

In applicable tutors, a Colors button changes the colors being used for that instance of the tutor.

Examples

withStudent:

Change the colors using the SetColors Maplet application.

SetColors

A new palette can be selected by name, replacing all colors

SetColorsNiagara

#78000E,#000E78,#4A7800,#3E578A,#780072,#00786A,#604191,#004A78,#784C00,#91414A,#3E738A,#78003B,#00783F,#914186,#510078,#777800

(1)

Or a sequence of colors can be give. Here replace just the first three colors:

SetColorsBlack,Red,Blue

#000000,#FF0000,#0000FF,#3E578A,#780072,#00786A,#604191,#004A78,#784C00,#91414A,#3E738A,#78003B,#00783F,#914186,#510078,#777800

(2)

withStudentPrecalculus:

Display a plot with the new set of default colors.

RationalFunctionPlot3x2+2x1x+2

A new palette can be selected by name, replacing all colors

SetColorsSpring

#0074CC,#CC0074,#74CC00,#00CCBE,#5800CC,#4B7EA6,#C1CC00,#CC004E,#0041CC,#4BA673,#CC7E00,#BE00CC,#00CC33,#00A7CC,#9BA64B,#4BA6A6

(3)

RationalFunctionPlot3x2+2x1x+2

A list of colors will replace the whole list of current colors

LconvertColorTools:-GetPaletteNautical,list1..10

LRGB : Gray Blue,RGB : Red,RGB : Dark Gray,RGB : Olive,RGB : Light Blue,RGB : Gray,RGB : Gray Violet,RGB : Dark Green,RGB : Dark Blue,RGB : Pale Red

(4)

SetColorsL

#334D64,#A1040B,#333333,#4E6333,#789ABD,#666666,#4F4F71,#11A104,#0D04A1,#BD7E78

(5)

If a list of few colors is given, they will be repeated so there are at least ten

SetColorsRed,Blue,Green

#FF0000,#0000FF,#008000,#FF0000,#0000FF,#008000,#FF0000,#0000FF,#008000,#FF0000,#0000FF,#008000

(6)

Compatibility

• 

The colors parameter was introduced in Maple 2023.

• 

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

See Also

ColorTools

Student