Directive[g1,g2,…]
represents a single graphics directive composed of the directives g1, g2, ….
Directive
Directive[g1,g2,…]
represents a single graphics directive composed of the directives g1, g2, ….
Details
- Any directives supported by Graphics or Graphics3D can appear inside Directive.
- Directive[{g1,g2,…}] is equivalent to Directive[g1,g2,…].
Examples
open all close allBasic Examples (4)
Give composite directives for primitives in a graphic:
Graphics[{Directive[Red, Thick], Circle[], Directive[Blue, Opacity[0.5]], Rectangle[{0, -1}, {2, 1}]}]Give a composite directive for a single curve or surface in a plot:
Plot[Sin[x], {x, 0, 10}, PlotStyle -> Directive[Orange, Thick, Dashed]]Plot3D[Sin[x + y ^ 2], {x, -3, 3}, {y, -2, 2}, PlotStyle -> Directive[Orange, Specularity[White, 10]], Mesh -> None]Give a composite directive for each curve in a plot:
Plot[{Sin[x], Cos[x]}, {x, 0, 10}, PlotStyle -> {Directive[Red, Dashed], Directive[Blue, Thick]}]Plot[2Sin[x], {x, 0, 10}, Frame -> True, FrameLabel -> {x, 2Sin[x]}, LabelStyle -> Directive[Medium, Italic]]Related Guides
History
Text
Wolfram Research (2007), Directive, Wolfram Language function, https://reference.wolfram.com/language/ref/Directive.html.
CMS
Wolfram Language. 2007. "Directive." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/Directive.html.
APA
Wolfram Language. (2007). Directive. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/Directive.html
BibTeX
@misc{reference.wolfram_2026_directive, author="Wolfram Research", title="{Directive}", year="2007", howpublished="\url{https://reference.wolfram.com/language/ref/Directive.html}", note=[Accessed: 13-June-2026]}
BibLaTeX
@online{reference.wolfram_2026_directive, organization={Wolfram Research}, title={Directive}, year={2007}, url={https://reference.wolfram.com/language/ref/Directive.html}, note=[Accessed: 13-June-2026]}