2

Some of my pictures do no longer compile with version 4.00b of package tkz-euclide.

The announcement of the new version (2022-Jan-5) of tkz-euclide says:

Some new macros have appeared, others (secondary) have disappeared. The only important constraint to transfer the code from version 3 to 4 is to remove the unit "cm".

I probably have hundreds of occurences of "cm" in my files. What is the suggested way to handle this? To which unit should "cm" be converted to? Can I use "mm" instead? In the first go I took the "remove" literally and just eliminated it, but this changes the pictures.

Please also look at the following MWE:

\documentclass{standalone}
\usepackage{tkz-euclide}
\begin{document}
\begin{tikzpicture}
\tkzDefPoint(0,0){M1}
\tkzDefPoint(120:5){X}
\tkzDefPoint(120:3){M2}
\tkzDefPoint(45:4){P}
\tkzInterLC(P,M1)(M1,X)\tkzGetPoints{N1}{F1}
\tkzInterLC(P,M2)(M2,X)\tkzGetPoints{N2}{F2}
\tkzMarkAngle[arc=ll,size=.9cm](F2,X,F1)
\tkzMarkAngle[arc=ll,size=.9cm](N2,X,N1)
\end{tikzpicture}
\end{document}

Removing the two occurences of cm gives a different picture. I hope you can reproduce this -- inclusion of .pdfs is unfortunately not supported here.

1
  • just delete "cm". The unit as in TikZ is now by default the 'cm'. The most affected macros are those concerning circles with definitions, drawing or intersections. Another macro is tkzCalcLength, it is no longer necessary to put [cm]. Logically the code compiles but the distances are wrong. If you need I can send you the latest version. Commented Jan 7, 2022 at 19:10

1 Answer 1

1

An example with some cm. The code compiles but in your .log file you will see :

Missing character: There is no c ("63) in font nullfont!
Missing character: There is no m ("6D) in font nullfont!
Missing character: There is no c ("63) in font nullfont!
Missing character: There is no m ("6D) in font nullfont!
\documentclass{standalone}
\usepackage{tkz-euclide}
  
\tkzSetUpColors[background=white,text=teal]  
\tkzSetUpPoint[size=2,color=teal]
\tkzSetUpLine[thin,color=teal]
\tkzSetUpCompass[color=brown,ultra thin,/tkzcompass/delta=10]
\tikzset{label style/.append style={color=teal}}
 
\begin{document}
\begin{tikzpicture}

\begin{scope}[rotate=28]
  \tkzDefPoint(4,0){A} \tkzDefPoint(0,0){B}  \tkzDefPoint(1.5,4){C}
  \tkzDrawLines(B,A B,C)
  \tkzFillAngle[fill=teal!30,size=1](A,B,C)
  \tkzDefPointWith[linear normed,K=2](B,A) \tkzGetPoint{I}
  \tkzDefPointWith[linear normed,K=2](B,C) \tkzGetPoint{J}
  \tkzDrawArc(B,I)(J)
  \tkzCompass(I,J)
  \tkzDrawPoints(A,B,C,I,J) 
  \tkzLabelPoints(A,B,C,I,J)
\end{scope}

\begin{scope}
  \tkzDefPoint(5,0){B'}
  \tkzDefPoint(9,0){A'}
  \tkzDrawLine(B',A')
  \tkzDuplicateSegment(B,I)(B',A')  \tkzGetPoint{I'} 
  \tkzDrawArc[angles](B',I')(0,80)
  \tkzCalcLength[cm](I,J)  \tkzGetLength{dIJ}
  \tkzCalcLength[cm](B,I)  \tkzGetLength{dBI} 
  \tkzDrawArc[arc,R](I',\dIJ)(100,120)
  \tkzInterCC[R](B',\dBI cm)(I',\dIJ cm)\tkzGetPoints{J'}{K}  
  \tkzDrawLine[add = 0 and 1](B',J')
  \tkzFillAngle[fill=teal!30,size=1cm](A',B',J')
  \tkzDrawPoints(A',B',I',J')
  \tkzLabelPoints(A',B',I',J')
\end{scope}
\end{tikzpicture}
\end{document}

Now the code should be written like this:

\documentclass{standalone}
\usepackage{tkz-euclide}
  
\tkzSetUpColors[background=white,text=teal]  
\tkzSetUpPoint[size=2,color=teal]
\tkzSetUpLine[thin,color=teal]
\tkzSetUpCompass[color=brown,ultra thin,/tkzcompass/delta=10]
\tikzset{label style/.append style={color=teal}}
 
\begin{document}
\begin{tikzpicture}

\begin{scope}[rotate=28]
  \tkzDefPoint(4,0){A} \tkzDefPoint(0,0){B}  \tkzDefPoint(1.5,4){C}
  \tkzDrawLines(B,A B,C)
  \tkzFillAngle[fill=teal!30,size=1](A,B,C)
  \tkzDefPointWith[linear normed,K=2](B,A) \tkzGetPoint{I}
  \tkzDefPointWith[linear normed,K=2](B,C) \tkzGetPoint{J}
  \tkzDrawArc(B,I)(J)
  \tkzCompass(I,J)
  \tkzDrawPoints(A,B,C,I,J) 
  \tkzLabelPoints(A,B,C,I,J)
\end{scope}

\begin{scope}
  \tkzDefPoint(5,0){B'}
  \tkzDefPoint(9,0){A'}
  \tkzDrawLine(B',A')
  \tkzDuplicateSegment(B,I)(B',A')  \tkzGetPoint{I'} 
  \tkzDrawArc[angles](B',I')(0,80)
  \tkzCalcLength(I,J)  \tkzGetLength{dIJ}
  \tkzCalcLength(B,I)  \tkzGetLength{dBI} 
  \tkzDrawArc[arc,R](I',\dIJ)(100,120)
  \tkzInterCC[R](B',\dBI)(I',\dIJ)\tkzGetPoints{J'}{K}  
  \tkzDrawLine[add = 0 and 1](B',J')
  \tkzFillAngle[fill=teal!30,size=1](A',B',J')
  \tkzDrawPoints(A',B',I',J')
  \tkzLabelPoints(A',B',I',J')
\end{scope}
\end{tikzpicture}
\end{document}

enter image description here

With your MWE if you keep "cm" then you have an error :

! Package PGF Math Error: Unknown operator c' or cm' (in '.9cmcm-2.5\pgflinewidth ').

Without "cm"

\documentclass{standalone}
\usepackage{tkz-euclide}
\begin{document}
\begin{tikzpicture}
\tkzDefPoint(0,0){M1}
\tkzDefPoint(120:5){X}
\tkzDefPoint(120:3){M2}
\tkzDefPoint(45:4){P}
\tkzInterLC(P,M1)(M1,X)\tkzGetPoints{N1}{F1}
\tkzInterLC(P,M2)(M2,X)\tkzGetPoints{N2}{F2}
\tkzDrawPoints(M1,M2,X,P,N1,N2,F1,F2)
\tkzLabelPoints(M1,M2,X,P,N1,N2,F1,F2)
\tkzDrawSegments(P,M1 P,F2 X,F1 X,F2 N1,F1 X,N1 X,N2)
\tkzDrawCircles(M1,X M2,X)
\tkzMarkAngle[arc=ll,size=.9](F2,X,F1)
\tkzMarkAngle[arc=ll,size=.9](N2,X,N1)
\end{tikzpicture}
\end{document}

enter image description here

1
  • Please look at the MWE above.
    – Gerhard
    Commented Jan 8, 2022 at 13:12

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .