zum Beispiel:

Open in Online-Editor
\textbf{....} und {\textbf ...}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Danke.

gefragt 03 Feb '15, 10:47

cis's gravatar image

cis
9.5k95460491
Akzeptiert-Rate: 29%

bearbeitet 03 Feb '15, 10:47


Es gibt immer Unterschiede. Welche genau es gibt und ob sie sichtbare Auswirkungen oder überhaupt Auswirkungen haben, hängt aber von der Art des \Befehl ab:

Wenn \Befehl ein Argument hat (so wie das von Dir verwendete \textbf, dann ist im ersten Fall alles zwischen { und } das Argument und im zweiten Fall nur das erste Token nach dem Befehl:

Open in Online-Editor
Code, hier editierbar zum Übersetzen:
\documentclass{article}
\begin{document}
\textbf{Hallo} vs {\textbf Hallo}
\end{document}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

alt text

Je nachdem, wie der Befehl mit Argument definiert worden ist, kann der zweite Fall sogar einen Fehler verursachen:

Open in Online-Editor
Code, hier editierbar zum Übersetzen:
\documentclass{article}
\def\test#{\textbf}
\begin{document}
\test{Hallo} vs {\test Hallo}
\end{document}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

liefert

Open in Online-Editor
Code, hier editierbar zum Übersetzen:
! Use of \test doesn't match its definition.
l.7 \test{Hallo} vs {\test H
allo}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Bei einem Befehl ohne Argument hängt es davon ab, was er macht: bei einem Schriftschalter ist der Unterschied deutlich:

Open in Online-Editor
Code, hier editierbar zum Übersetzen:
\documentclass{article}
\begin{document}
Test {\bfseries Hallo} Test \par
Test \bfseries{Hallo} Test
\end{document}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

alt text

Einmal ist der Befehl in einer Gruppe {...} und seine Wirkung darauf beschränkt, das andere Mal ist er außerhalb der Gruppe und es gibt keine Beschränkung. In einem solchen Fall könnte die Wirkung von \Befehl aber auch global sein, dann gäbe es keinen Unterschied:

Open in Online-Editor
Code, hier editierbar zum Übersetzen:
\documentclass{article}
\def\test#1{\def\testI{#1}}
\def\Test#1{\gdef\testII{#1}}
\begin{document}
\test{foo}\show\testI
{\test bar}\show\testI
\Test{foo}\show\testII
{\Test bar}\show\testII
\end{document}
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Im log steht:

Open in Online-Editor
Code, hier editierbar zum Übersetzen:
> \testI=macro:
->foo.
l.8 \test{foo}\show\testI
> \testI=macro:
->foo.
l.9 {\test bar}\show\testI
> \testII=macro:
->foo.
l.11 \Test{foo}\show\testII
> \testII=macro:
->b.
l.12 {\Test bar}\show\testII
הההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההההה
XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

Nicht zuletzt kann \Befehl aber auch etwas wie \textasciicircum sein. Dann wird das Symbol (der Ersetzungstext) in beiden Fällen einfach ausgegeben.

Quintessenz des ganzen: das hängt ganz von der Definition von \Befehl ab und lässt sich pauschal schlecht beantworten.

Permanenter link

beantwortet 03 Feb '15, 16:29

cgnieder's gravatar image

cgnieder
22.1k253463
Akzeptiert-Rate: 60%

Deine Antwort
[Vorschau ausblenden]

Folgen dieser Frage

Per E-Mail:

Wenn sie sich anmelden, kommen Sie für alle Updates hier in Frage

Per RSS:

Antworten

Antworten und Kommentare

Frage-Themen:

×52

gestellte Frage: 03 Feb '15, 10:47

Frage wurde gesehen: 7,480 Mal

zuletzt geändert: 03 Feb '15, 16:29

Willkommen, erstes Mal hier? Schau mal unter FAQ!

×