LaTeX tab completions


#1

I have been working on a set of packages to handle different sets of entities for Unicode characters (or sequences).
I almost have the first of these, LaTeX_Entities ready (the others are Emoji_Entities, HTML_Entities, and Unicode_Entities. (I used simpler forms of these in my StringUtils.jl package).

One issue that came up is that there are a few entities in the Julia latex_symbols.jl file that have names that are not part of any standard, and I wondered if some of those should be deprecated and replaced, or simply have the standard names added. (Note: the code I wrote for LaTeX entity tables could be used also for Base, it produces a table that can be loaded very quickly, takes much less memory, and doesn’t require some of the patches the current tables have had, such as for \varepsilon).

The names that I wonder if should simply be replaced by the versions in the standards are the following:

    "pprime"      => "″",     # synonym of \dprime
    "ppprime"     => "‴",     # synonym of \trprime
    "pppprime"    => "⁗",     # synonym of \qprime
    "backpprime"  => "‶",     # synonym of \backdprime
    "backppprime" => "‷",     # synonym of \backtrprime
    "llbracket" => "⟦",       # synonym of \lBrack
    "rrbracket" => "⟧",       # synonym of \rBrack

(I think maybe the llbracket and rrbracket could just stay as Julia-specific synonyms, such as the ones cbrt and xor,
but the *prime ones seem more confusing than the standard names to me)


#2

I think the prime variants also make sense since they are quite similar to the various integrals \int, \iint, \iiint etc. Perhaps you could simply add both, the current and the standard ones, to make it directly compatible with LaTeX.


#3

OK, that’s easy enough to do!
Since I’m not a mathematician, I need feedback on this, thanks!


#4

What about the llbracket and rrbracket ones? Are those easier for people than the standard lBrack and rBrack?
Would people want both for those as well? (I’m fine either way, just want to know what the desires of the people who might actually use this)


#5

Considering how often I have to google to figure out how certain LaTeX abbreviations are named, I believe sticking to a certain pattern would makes sense. So, my opinion is yes, llbracket would be easier to remember. Then again, where do you draw the line… after all, one can add user-defined abbreviations as well (at least today).

There’s another point of view: In Mathematica, the double brackets have a meaning, they are used as ‘pretty printing’ of the indexing brackets, which would otherwise be written as [[i, j]]. Since there is not such a need currently in Julia, their importance is probably significantly lower.


#6

I’ve also added standard LaTeX completions that might be easier to remember for people, such as mathtt{0} as opposed to mttzero. (I added just the ones that had a single {} with [A-Za-z0-9] inside the curly braces, not things like
Elsevier{123f})


#7

Cool, and it’s still the same syntax in LaTeX and Julia, despite the brackets. Nice. I like it.