YihangZhu / LaTeX-in-Google-Spreadsheet

A simple add-on for converting a Google spreadsheet table to a LaTeX table or a LaTeX table to a Google Spreadsheet table.
31 stars 1 forks source link

underscore in celltext was no auto-escaped #2

Closed LennardSchwarz closed 4 years ago

LennardSchwarz commented 4 years ago

The exact text in the cell was: "Event Name (eg. group_name - event)"

This resulted in a compilation error in Latex and I had to escape the underscore manually. Would be amazing if special characters could get escaped automatically!

YihangZhu commented 4 years ago

The exact text in the cell was: "Event Name (eg. group_name - event)"

This resulted in a compilation error in Latex and I had to escape the underscore manually. Would be amazing if special characters could get escaped automatically!

Hi, thank you for the suggestion. There are pros and cons by setting them automatically. As I wrote in the readme: "Special LaTeX chars only "%"s are replaced with "\%". The rest special LaTeX chars remain intact, given that they may not be plain text. For example, $x$ may be a mathematical notation." But I will try to find a way to improve it.

By the way, by using "replace all" you can easily do the changes manually.

LennardSchwarz commented 4 years ago

Thanks for clarifying! I did not readme carefully enough apparently.

Have a nice day! On 17. Jun 2020, 21:25 +0100, Yi-Hang Zhu notifications@github.com, wrote:

The exact text in the cell was: "Event Name (eg. group_name - event)" This resulted in a compilation error in Latex and I had to escape the underscore manually. Would be amazing if special characters could get escaped automatically! Hi, thank you for the suggestion. There are pros and cons by setting them automatically. As I wrote in the readme: "Special LaTeX chars only "%"s are replaced with "%". The rest special LaTeX chars remain intact, given that they may not be plain text. For example, $x$ may be a mathematical notation." But I will try to find a way to improve it. By the way, by using "replace all" you can easily do the changes manually. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.

YihangZhu commented 4 years ago

The exact text in the cell was: "Event Name (eg. group_name - event)"

This resulted in a compilation error in Latex and I had to escape the underscore manually. Would be amazing if special characters could get escaped automatically!

Hi LennardSchwarz I have adopted your comment in the addon.

LennardSchwarz commented 4 years ago

This is awesome! I’ll check it out, thanks for telling me.

Viele Grüße, Lennard Schwarz On 25. Jul 2020, 08:25 +0100, Yi-Hang Zhu notifications@github.com, wrote:

The exact text in the cell was: "Event Name (eg. group_name - event)" This resulted in a compilation error in Latex and I had to escape the underscore manually. Would be amazing if special characters could get escaped automatically! Hi LennardSchwarz I have adopted your comment in the addon. — You are receiving this because you authored the thread. Reply to this email directly, view it on GitHub, or unsubscribe.