New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Option table-number-alignment=none #513
Comments
There's a fundamental difference for numbers: there's already |
I'm wondering if there's a (public) way of telling the code is 'inside' a |
I read the documentation of % -*- coding: utf-8 -*-
\documentclass{article}
\usepackage{tabularray}
\UseTblrLibrary{siunitx}
\setlength{\parindent}{0pt}
\begin{document}
\section{table-alignment-mode=format}
Tabular:
\begin{tabular}{
|S[table-column-width=4em,table-format=2.3,table-alignment=left]
|S[table-column-width=4em,table-format=2.3,table-alignment=center]
|S[table-column-width=4em,table-format=2.3,table-alignment=right]|
}
\hline
{A} & {B} & {C} \\
\hline
11 & 11 & 11 \\
\hline
2.111 & 2.222 & 2.333 \\
\hline
33.11 & 33.22 & 33.33 \\
\hline
\end{tabular}
\bigskip
Tabularray:
\begin{tblr}{
hlines, vlines, columns = {4em},
colspec={
Q[si={table-format=2.3,table-number-alignment=left},l]
Q[si={table-format=2.3,table-number-alignment=center},c]
Q[si={table-format=2.3,table-number-alignment=right},r]
}
}
{{{A}}} & {{{B}}} & {{{C}}} \\
11 & 11 & 11 \\
2.111 & 2.222 & 2.333 \\
33.11 & 33.22 & 33.33 \\
\end{tblr}
\section{table-alignment-mode=none}
Tabular:
\begin{tabular}{
|S[table-column-width=4em,table-alignment-mode=none,table-alignment=left]
|S[table-column-width=4em,table-alignment-mode=none,table-alignment=center]
|S[table-column-width=4em,table-alignment-mode=none,table-alignment=right]|
}
\hline
{A} & {B} & {C} \\
\hline
11 & 11 & 11 \\
\hline
2.111 & 2.222 & 2.333 \\
\hline
33.11 & 33.22 & 33.33 \\
\hline
\end{tabular}
\bigskip
Tabularray:
\begin{tblr}{
hlines, vlines, columns = {4em},
colspec={
Q[si={table-alignment-mode=none,table-number-alignment=left},l]
Q[si={table-alignment-mode=none,table-number-alignment=center},c]
Q[si={table-alignment-mode=none,table-number-alignment=right},r]
}
}
{{{A}}} & {{{B}}} & {{{C}}} \\
11 & 11 & 11 \\
2.111 & 2.222 & 2.333 \\
33.11 & 33.22 & 33.33 \\
\end{tblr}
\section{table-alignment-mode=marker}
Tabular:
\begin{tabular}{
|S[table-column-width=4em,table-alignment-mode=marker]
|S[table-column-width=4em,table-alignment-mode=marker]
|S[table-column-width=4em,table-alignment-mode=marker]|
}
\hline
{A} & {B} & {C} \\
\hline
11 & 11 & 11 \\
\hline
2.111 & 2.222 & 2.333 \\
\hline
33.11 & 33.22 & 33.33 \\
\hline
\end{tabular}
\bigskip
Tabularray:
\begin{tblr}{
hlines, vlines, columns = {4em},
colspec={
Q[si={table-alignment-mode=marker},c]
Q[si={table-alignment-mode=marker},c]
Q[si={table-alignment-mode=marker},c]
}
}
{{{A}}} & {{{B}}} & {{{C}}} \\
11 & 11 & 11 \\
2.111 & 2.222 & 2.333 \\
33.11 & 33.22 & 33.33 \\
\end{tblr}
\end{document} |
In issue #510, I only mentioned
table-text-alignment
, but in facttable-number-alignment=none
is also needed (and also fortable-alignment
). Sorry, I was not very familiar withsiunitx
package.The text was updated successfully, but these errors were encountered: