مكتبة TikZ غير موجودة
! Package tikz Error: I did not find the library 'XXX'.
ماذا يعني هذا الخطأ
مكتبة TikZ المشار إليها بـ \usetikzlibrary{} غير موجودة أو مكتوبة بشكل خاطئ. وظائف TikZ مقسّمة إلى مكتبات يجب تحميلها صراحةً.
الأسباب الشائعة
- خطأ إملائي في اسم المكتبة
- استخدام مكتبة من إصدار أحدث من TikZ غير متوفر في التثبيت الحالي
- مكتبة تتطلب حزمة منفصلة (مثل pgfplots) تُحمَّل بشكل مستقل
كيفية الإصلاح
راجع دليل TikZ/PGF لمعرفة اسم المكتبة الصحيح. من المكتبات الشائعة: arrows.meta وdecorations.pathmorphing وcalc وpositioning وshapes وfit وexternal. وتتطلب رسوم pgfplots البيانية \usepackage{pgfplots} بشكل منفصل.
أمثلة على الشيفرة
\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{arrow} % Wrong: should be 'arrows' or 'arrows.meta'
\begin{document}
\begin{tikzpicture}
% ...
\end{tikzpicture}
\end{document}\documentclass{article}
\usepackage{tikz}
\usetikzlibrary{arrows.meta,positioning}
\begin{document}
\begin{tikzpicture}
\node (a) {A};
\node[right of=a] (b) {B};
\draw[-{Stealth}] (a) -- (b);
\end{tikzpicture}
\end{document}أخطاء ذات صلة
ملف غير موجود
! LaTeX Error: File 'XXX' not found.
امتداد رسومات غير معروف
! LaTeX Error: Unknown graphics extension: .XXX.
محرف يونيكود غير مدعوم (pdfLaTeX)
! Package inputenc Error: Unicode char U+XXXX not set up for use with LaTeX.
تعذر تحديد حجم الرسم (لا يوجد BoundingBox)
! LaTeX Error: Cannot determine size of graphic (no BoundingBox).
جرّب الحل مباشرة
الصق شيفرة LaTeX في الـ playground وجمّعها فورًا.

