You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm using the hack with grid tables to align subfigures. It's working, but sometimes it's awkward. If I want place subfigures in the table with same column width, I have to manually add extra spaces for short columns. Moreover, when subcaption is long and/or three or more subfigures are placed in grid table, the source lines of table become very long. It would be handy if pandoc-crossref form this table itself.
I've implemented something like this in master. There are a couple caveats. You need to enable subfigGrid metadata option for this to work (boolean, default false)
Column widths will be taken from width attributes of corresponding images, e.g.
will produce a table with columns of 30%, 60% and 10% respectively.
Only first row of images is considered, other rows are completely ignored.
Anything except images is silently ignored. So any text, spaces, soft line breaks etc will silently disappear from output. That doesn't apply to caption paragraph, obviously.
All images will have width attribute automatically set to 100% in order to fill whole column.
Specifying width in anything but % will throw an error.
If width for some images in first row is not specified, those will span equally in the remaining space.
If width isn't specified for any image in first row, those will span equally on 99% of page width (due to Pandoc otherwise omitting width attribute for table)
Let me know if this is satisfactory, or if you run into issues.
I'm using the hack with grid tables to align subfigures. It's working, but sometimes it's awkward. If I want place subfigures in the table with same column width, I have to manually add extra spaces for short columns. Moreover, when subcaption is long and/or three or more subfigures are placed in grid table, the source lines of table become very long. It would be handy if pandoc-crossref form this table itself.
For example, the following
would be equal to (I'm adding two spaces to get same column width)
And if I wanted to place subfigures in the 3x2 table, I would write
Of course, this feature could be optional.
The text was updated successfully, but these errors were encountered: