tikz dimension too large drawing a color wheel
edit: now from your answer (you should first edit your question and add missing in information), i can complete my answer:
\documentclass[10pt,a4paper]{article}
\usepackage[french]{babel}
\usepackage[T1]{fontenc}
\usepackage[dvipsnames]{xcolor}
\usepackage{tikz}
\usetikzlibrary{arrows, calc, decorations.text}
\begin{document}
\begin{tikzpicture}
\foreach \x/\t [count=\xx from 0] in {%
orange/orange, jaune/yellow, jaune-vert/LimeGreen, vert/green,
bleu-vert/SeaGreen, cyan/Cyan, bleu-rois/NavyBlue, bleu/blue, violet/Violet, magenta/magenta, rouge-rosé/RubineRed, rouge/red}
{
\pgfmathsetmacro{\angle}{30*\xx}
\path[decoration={text along path,
text={\x},
text align=center,
reverse path},
postaction={decorate},
]
\ifnum\xx<7
(\angle-15:4) arc (\angle-15:\angle+15:4);
\else
(\angle+15:4.2) arc (\angle+15:\angle-15:4.2);
\fi
\draw[double=\t, semithick,
double distance=5mm] (\angle-15:3.6) arc (\angle-15:\angle+15:3.6);
\draw[semithick] (\angle-15:3.35) -- (\angle-15:3.85);
\draw[->] (0,0) -- (\angle:3);
}
\end{tikzpicture}
\end{document}
Just for fun and inspired by the example and the answers an arrangement through a definition with parameters:
\ColorWeel(<coordinate>)[<radius>][<pseudo-sharpness>]{Color_Name/Graphicx_name, Color_name/Color1!value(0-100)!color2, ...}
RESULT:
MWE:
% By J. Leon V. Share as Beerware philosophy
\documentclass[border=20pt]{standalone}
\usepackage[utf8]{inputenc}
\usepackage[french]{babel}
\usepackage[T1]{fontenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{makeidx}
\usepackage{graphicx}
\usepackage{lmodern}
\usepackage{kpfonts}
\usepackage[dvipsnames]{xcolor}
\usepackage{tikz}
\usetikzlibrary{decorations.text, arrows.meta}
\usetikzlibrary{calc}
\begin{document}
\begin{tikzpicture}[
% Environment Cfg
>={Stealth[inset=0pt,length=10pt]}
]
%Variables: 1:Position 2:Radio 3:pseudo sharpsness 4: Name/Color array
\def\ColorWeel(#1)[#2][#3]#4{%
\begin{scope}[shift={(#1)}]
%Drawing features separations.
\foreach \elements [count=\n] in {#4}{}
\pgfmathparse{int(360/\n)}
\edef\Angle{\pgfmathresult}
\foreach \text/\color [count=\i from 0] in {#4}{
\draw[fill=\color,thick](\Angle*\i:#2)
arc (\Angle*\i:\Angle*\i+\Angle:#2)
-- (\Angle*\i+\Angle:#2-0.5cm) arc (\Angle*\i+\Angle:\Angle*\i:#2-0.5cm) -- cycle;
\pgfmathparse{int(\Angle*\i)}
\ifnum\pgfmathresult<180
\path[decoration={text along path,raise=-4pt,text={||\text},text align=center,reverse path},decorate]
(\Angle*\i:#2+0.5cm) arc (\Angle*\i:\Angle*\i+\Angle:#2+0.5cm);
\fi
\ifnum\pgfmathresult>179
\path[decoration={text along path,text={||\text},text align=center},decorate]
(\Angle*\i:#2+0.5cm) arc (\Angle*\i:\Angle*\i+\Angle:#2+0.5cm);
\fi
}
\clip (0,0) circle (#2-0.5cm);
\foreach \text/\color [count=\j from 0] in {#4}{
\foreach \k in {1,2,...,20}{
\path[fill=\color, opacity=#3](\Angle*\j+\Angle/2: #2-0.7cm) circle (\k*0.2);
}
\draw[thick, ->] (0,0) -- (\Angle*\j+\Angle/2: #2-1.2cm);
}
\end{scope}
}
\ColorWeel(0,0)[5cm][0.05]{
Orange/orange,
jaune/yellow,
jaune-vert/lime,
vert/green,
bleu-vert/SeaGreen,
cyan/Cyan,
bleu roi/NavyBlue,
bleu/blue,
violet/violet,
magenta/magenta,
rouge-ros{\'e}/RubineRed,
rouge/red}
\ColorWeel(11,0)[3.5cm][0.08]{
Blue/blue,
Red/red,
Yellow/yellow}
\ColorWeel(7,-10)[4cm][0.08]{
black/black,
white/white,
green-60-black/green!60!black,
blue-50-green/blue!50!green,
blue-50-red/blue!50!red}
\end{tikzpicture}
\end{document}
With the code from your answer, I wrote the entire code. I kept the structure of your code with 3 foreach loops that fits well here.
In each foreach loop, instead of incrementing two variables, it is also simple to count the number of colors and calculate the angles.
To make the code easy to read and understand, I spelled out the variable names (and in French): \couleur
for colour, \angle
, \n
for number.
I put the acute accent of the rouge-ros{é}
color between braces because otherwise I have an error at compilation and this even with the tikz babel library \usetikzlibrary{babel}
The inputenc package is now included in LaTeX, it is no longer necessary to load it, so I commented on it. %\usepackage[utf8]{inputenc}
to put the same margins with the geometry package, just write \usepackage[margin=2cm]{geometry}
\documentclass[10pt,a4paper]{article}
%\usepackage[utf8]{inputenc}
\usepackage[french]{babel}
\usepackage[T1]{fontenc}
\usepackage{amsmath}
\usepackage{amsfonts}
\usepackage{amssymb}
\usepackage{makeidx}
\usepackage{graphicx}
\usepackage{lmodern}
\usepackage{kpfonts}
\usepackage[margin=2cm]{geometry}
\usepackage[dvipsnames]{xcolor}
\usepackage{tikz}
\usetikzlibrary{calc}
\usetikzlibrary{arrows,decorations.text}
\usetikzlibrary{babel}
\begin{document}
\begin{tikzpicture}
%draw names
\foreach \couleur [count=\n from 0, evaluate= \n as \angle using \n*30-15] in {orange, jaune,jaune-vert ,vert,bleu-vert,cyan,bleu-roi}
{
\path[decoration={
text along path,
text={\couleur},
text align=center,
reverse path},
postaction={decorate}]
(\angle : 4.1) arc (\angle :\angle + 30 : 4.1);
}
%% draw names
\foreach \couleur [count=\n from 7,evaluate= \n as \angle using \n*30-15] in {bleu, violet, magenta, rouge-ros{é}, rouge}
{
\path[decoration={
text along path,
text={\couleur},
text align=center},
postaction={decorate}] (\angle:4.3) arc (\angle :\angle+30:4.3);
}
\foreach \couleur [count=\n from 0, evaluate= \n as \angle using \n*30-15] in {orange, yellow,LimeGreen,green, SeaGreen, Cyan, NavyBlue, blue, Violet, magenta, RubineRed, red}
{
\draw[double=\couleur,
semithick,
double distance=5mm] (\angle:3.6) arc (\angle:\angle+30:3.6);
\draw[->,thick] (0,0) -- (\angle-15:3);
}
\end{tikzpicture}
\end{document}