Hallo,

ich bin gerade damit beschäftigt die eigenes Paket zu erstellen für Sachen, die ich sehr häufig benutze.

Ich habe es jetzt hinbekommen, dass ich in meinem Paket ein neues Objekt per newcommand erstellen kann, dass dann gefunden wird, wenn ich das Paket einbinde.

Ich habe in mein Paket jetzt ein mit NewDocumentCommand erstelltes Objekt eingefügt. Das wird leider nicht gefunden, wenn ich das einbinde.

Kann man NewDocumentCommand nicht in einem Paket benutzen? Hat jemand eine Idee woran das sonst liegen kann?

Viele Grüße
Swizz

Code:
\NeedsTeXFormat{LaTeX2e} 
\ProvidesPackage{mein_paket} 
\RequirePackage{tikz,pgfmath,xparse}

\newcommand{\xxx}{{ saa}} 

\newcommand{\Simley}[1]{%
\begin{tikzpicture}[scale=0.5]
    \newcommand*{\SmileyRadius}{1.0}%
    \draw  (0,0) circle (\SmileyRadius);% outside circle
	\draw (-0.25cm,-1.2cm) -- (0.25cm,-1.2cm)--(0.25cm,-1.7cm)--(-0.25cm,-1.7cm)--cycle;
     node [yshift=-0.22*\SmileyRadius cm] {\tiny #1}% uncomment this to see the smile factor
\end{tikzpicture}%
}%

\NewDocumentCommand{\zm3}{ O{} O{} O{} O{} O{} O{} O{1} }{
\fontsize{\the\numexpr10*#7}{\the\numexpr5*#7}
	\begin{tikzpicture}[scale=#7]
		\draw[line width =0.5*#7mm] (0,0) -- (6,0) -- (6,1) -- (0,1)--cycle;
		\draw[line width =0.5*#7mm] (2,0)--(2,1);
		\draw[line width =0.5*#7mm] (4,0)--(4,1);
		\draw[line width =0.5*#7mm] (1,1) -- (5,1) -- (5,2) -- (1,2)--cycle;
		\draw[line width =0.5*#7mm] (3,1)--(3,2);
		\draw[line width =0.5*#7mm]  (2,2) -- (4,2) -- (4,3) -- (2,3)--cycle;
		\node at (1,0.5){#1};
		\node at (3,0.5){#2};	
		\node at (5,0.5){#3};
		\node at (2,1.5){#4};
		\node at (4,1.5){#5};
		\node at (3,2.5){#6};
	\end{tikzpicture}%

}
\endinput