-
Notifications
You must be signed in to change notification settings - Fork 104
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
Support & in matrices without catcode change #1081
base: master
Are you sure you want to change the base?
Commits on Dec 18, 2021
-
Fix "\matrix{a \\ b &[between origins] c};"
Column separation is handled by modifying the bounding box of cells. Adjust this to handle the case when [between origins] is specified in later rows, like \begin{tikzpicture} \matrix[column sep={5mm,between origins}, nodes=draw]{ \node{1}; & \node(2){2}; \\ \node{3}; & \node{4}; & \node(5){5}; \\ }; \draw (5) -- (2); \end{tikzpicture} Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 2407ff0 - Browse repository at this point
Copy the full SHA 2407ff0View commit details -
Break up \pgf@matrix@endcell for future changes.
Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 85f842a - Browse repository at this point
Copy the full SHA 85f842aView commit details -
pgfmatrix: Smuggle row and column separation out of all cells.
Upcoming changes require that \pgfmatrixendrow start with &, and column separation will need to be saved as well, as it will be processed later outside the cell group. These are to support constructs like (see bug pgf-tikz#503) \matrix[every odd row/.style={row sep=1cm}] {...}; Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 3418205 - Browse repository at this point
Copy the full SHA 3418205View commit details -
pgfmatrix: delay handling column separation.
This is a step towards supporting & in place of \pgfmatrixnextcell, as & is not able to immediately process any argument. Move code from \pgf@matrix@endcell to \pgfmatrixnextcell. Remove \pgf@matrix@process@nextcell@options, no longer used. Notable aspects of the move needing care: 1) The test \ifpgf@matrix@last@cell@in@row has been omitted, as no longer necessary, and no longer guaranteed to be correct. 2) The test \pgfmatrixcurrentcolumn < \pgf@matrix@numberofcolumns still yields the correct result, even though \pgf@matrix@numberofcolumns might have a different value. 3) \pgf@matrix@maxx might have a different value, but needs no change in code. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 70a400a - Browse repository at this point
Copy the full SHA 70a400aView commit details -
Remove \ifpgf@matrix@last@cell@in@row.
Last commit made it a noop code. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 11f8ab9 - Browse repository at this point
Copy the full SHA 11f8ab9View commit details -
Remove one \pgf@matrix@maxxN initialization, no longer needed.
Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for a7ab036 - Browse repository at this point
Copy the full SHA a7ab036View commit details -
pgfmatrix: remove unused \pgf@matrix@eom@found.
Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 739b4a5 - Browse repository at this point
Copy the full SHA 739b4a5View commit details -
Simplify detecting empty cell.
Detect it by the single token \pgf@matrix@endcell (brought in by & starting a new cell), which is easier to check than the two tokens \let\pgf@matrix@signal@cell@end. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 59fe51c - Browse repository at this point
Copy the full SHA 59fe51cView commit details -
pgfmatrix: Care for & when parsing optional arguments.
Think of "\pgfmatrixnextcell &" or "\pgfmatrixendrow &". The usual trick for this is surround looking ahead of next character by "\ifnum\iffalse{\fi0=`}\fi" and "\ifnum`{=0}\fi", but here we use variants. \pgfmatrixnextcell: As the look ahead does not occur in math mode, do it in a TeX group. This defends again & or \cr ending up in a (hidden) temporary control sequence for a long time. \pgfmatrixendrow: Look for an optional argument in the \noalign group, where the trick is not necessary. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 3c127e2 - Browse repository at this point
Copy the full SHA 3c127e2View commit details -
Remove a no longer needed global assignment.
Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for b4c3b7c - Browse repository at this point
Copy the full SHA b4c3b7cView commit details -
pgfmatrix: support & as cell separator, simplify last cell test.
There is no longer an ampersand "wrong catcode". In documentation promote & as cell separator, use it in all examples, and remove limitation due to catcode of ampersand. Still document \pgfmatrixnextcell, which is now simply &. The main technical idea is adding "\aftergroup\pgf@matrix@nextcell" to the \halign preamble. The macro \pgf@matrix@nextcell will be added after the cell group, i.e., right after "&" in user input, so TeX will see \pgf@matrix@nextcell as the first token of the next table cell. Now \pgf@matrix@nextcell does what \pgfmatricnextcell did before. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for ef27e67 - Browse repository at this point
Copy the full SHA ef27e67View commit details -
No longer make & active in TikZ matrices.
Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 9181d20 - Browse repository at this point
Copy the full SHA 9181d20View commit details -
pgfmatrix: Remove internal variable \pgf@matrix@paddingskip.
Use \pgf@matrix@maxxCOLUMN instead, which might have a different value but doesn't need extra global assignments. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for d660a5a - Browse repository at this point
Copy the full SHA d660a5aView commit details -
pgfmatrix: Simplify by removing \ifpgf@matrix@empty@cell.
Temporarily redefine \pgfmatrixendcode in empty cells, which is a much simpler way to omit end code. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for d4ebe22 - Browse repository at this point
Copy the full SHA d4ebe22View commit details -
Recombine \pgf@matrix@endcell.
Since one part is extremely short. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for ab2bedf - Browse repository at this point
Copy the full SHA ab2bedfView commit details -
\pgfmatrix: deduplicate halign header.
This is to simplify code without changing functionality. Move \pgfmatrix@init@row out of halign header to this end. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 2a365ea - Browse repository at this point
Copy the full SHA 2a365eaView commit details -
\pgfmatrix: slightly simplify adding row separation.
Make less dimension calculations, glue insertions, assignments for the same result. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for aea0349 - Browse repository at this point
Copy the full SHA aea0349View commit details -
\pgfmatrix: Optimize out \pgf@matrix@column@sep@N.
Simplify code to handle column separation in pgf matrices: change \pgf@picminx only once per matrix cell for this purpose. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for fbcaa39 - Browse repository at this point
Copy the full SHA fbcaa39View commit details -
matrices: Add some tests for & as cell separator.
Include tests for packages: tikz-cd, tikz-dependency, beamer (deliberately ignoring advice to not use & as cell separator). Omit dvisvgm result for beamer: it contains complicated dvips specials. Signed-off-by: Gábor Braun <gabor.braun@uni-duisburg-essen.de>
Configuration menu - View commit details
-
Copy full SHA for 10a77b1 - Browse repository at this point
Copy the full SHA 10a77b1View commit details