Différences
Ci-dessous, les différences entre deux révisions de la page.
| Les deux révisions précédentesRévision précédente | |||
| generalites:erreurs:alignment_tab_changed_to_cr [2020/12/12 17:17] – Backquotes remplacés par des doubles apostrophes dbitouze | generalites:erreurs:alignment_tab_changed_to_cr [2021/01/10 16:22] (Version actuelle) – Suppression après fusion avec "generalites/erreurs/e/extra_alignment_tab_has_been_changed_to_cr". jejust | ||
|---|---|---|---|
| Ligne 1: | Ligne 1: | ||
| - | ====== Alignment tab changed to '' | ||
| - | |||
| - | |||
| - | This is an error you may encounter in LaTeX when a tabular | ||
| - | environment is being processed. | ||
| - | ''&'' | ||
| - | (or '' | ||
| - | |||
| - | <code latex> | ||
| - | ! Extra alignment tab has been changed to \cr | ||
| - | </ | ||
| - | could arise from a simple typo, such as: | ||
| - | |||
| - | <code latex> | ||
| - | \begin{tabular}{ll} | ||
| - | hello & there & jim \\ | ||
| - | goodbye & now | ||
| - | \end{tabular} | ||
| - | </ | ||
| - | where the second ''&'' | ||
| - | two-column '' | ||
| - | case, an extra '' | ||
| - | continue from the error in this case, '' | ||
| - | to a row of his own.) Another simple typo that can provoke the error | ||
| - | is: | ||
| - | |||
| - | <code latex> | ||
| - | \begin{tabular}{ll} | ||
| - | hello & there | ||
| - | goodbye & now | ||
| - | \end{tabular} | ||
| - | </ | ||
| - | where the '' | ||
| - | In this case, if you continue from the error, you will find that | ||
| - | LaTeX has made a table equivalent to: | ||
| - | |||
| - | <code latex> | ||
| - | \begin{tabular}{ll} | ||
| - | hello & there goodbye\\ | ||
| - | now | ||
| - | \end{tabular} | ||
| - | </ | ||
| - | (with the second line of the table having only one cell). | ||
| - | |||
| - | Rather more difficult to spot is the occurrence of the error when | ||
| - | you're using alignment instructions in a '' | ||
| - | |||
| - | <code latex> | ||
| - | \usepackage{array} | ||
| - | ... | ||
| - | \begin{tabular}{l> | ||
| - | here & we are again \\ | ||
| - | happy & as can be | ||
| - | \end{tabular} | ||
| - | </ | ||
| - | the problem here (as explained in | ||
| - | [[FAQ-tabcellalign|tabular cell alignment]]) is that the | ||
| - | '' | ||
| - | '' | ||
| - | '' | ||
| - | following ''&'' | ||
| - | ''&'' | ||
| - | |||
| - | Get rid of the error in the way described in | ||
| - | [[FAQ-tabcellalign|tabular cell alignment]] --- either use | ||
| - | '' | ||
| - | there. | ||
| - | |||
| - | The [[ctanpkg> | ||
| - | a matrix (the package provides many matrix environments), | ||
| - | fixed maximum number of columns in a matrix --- exceed that maximum, | ||
| - | and the error will appear. | ||
| - | the value is stored in counter '' | ||
| - | changed (in the same way as any counter): | ||
| - | |||
| - | <code latex> | ||
| - | \setcounter{MaxMatrixCols}{20} | ||
| - | </ | ||
| - | |||
| - | |||
| - | ----- | ||
| - | |||
| - | //Source:// [[faquk> | ||
| - | |||
| - | {{htmlmetatags> | ||
| - | metatag-og: | ||
| - | metatag-og: | ||
| - | }} | ||

