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
{{ message }}
Repository navigation
io.ascii.Latex and AASTex: Make reading more flexible #1525
Used as Readers io.ascii.Latex and AASTex are not as flexible as they could be. They were originally designed as writers that allow data to round-trip.
While there is no need to implement all features LaTeX offers (e.g. '\multiline' and '\mulitcolumn' don't make sense - in that case it's ambiguous what to put in a cell anyway), it would be easy to make them a little more flexible on read-in to make it more likely to read LaTeX tables found in articles e.g. on astro-ph.
I'll implement that eventually (This issue is here so I don't forget), but feel free to make a PR for this if you are faster.
Here are some ideas:
leading space before e.g. a \begin{table} should not prohibit the Reader to find the table start line (hint: edit regex in find_latex)
Line breaks are common between '\tablehead' and '\colhead' in AASTex tables. (slightly harder to implement, because this needs a real paser to count { and }.
Reading only allows lines with % (comment lilnes) in the first row or full lines with a & b \\ %comment (handeled around lines 128 or so), but crashes with % comment because it then tries to process an empty line.
Activity
hamogu commentedon Jun 23, 2014
Reading only allows lines with
%(comment lilnes) in the first row or full lines witha & b \\ %comment(handeled around lines 128 or so), but crashes with% commentbecause it then tries to process an empty line.nstarman commentedon Jun 4, 2023
@hamogu if you're still thinking about this 😆 I opened #14853 to track a problem with round-tripping units