Sometimes students using LaTeX ask me how to do the typesetting of documents in French or Spanish. I'm not able to help them because I never learned to speak or write French or Spanish.
Different languages have different typographic rules to typeset documents. For English documents one can read...
@JasperLoy I don't know and it is not so important. I was a little bit astonished to see the -5 reputation, because there was no information in faq or meta.tex. Meanwhile I found some infos in meta.stackexchange.com. And the downvote in my profile I can't click.
user19161
@Kurt Well, now and then users delete their accounts. Someone lost over 300 rep on another site because I deleted one of my accounts...
@FrankMittelbach: I really feel honoured to see the expl3 hummingbird flying so elegantly in the presentations and the website. :) There was no need to put my name in evidence in the slides, it was a humble contribution to the awesome LaTeX3 project, and I'm really glad to help with everything I can. :) Hopefully, Bruno and I might come up with something "new" and interesting for the testing machinery. :) And I have already a suggestion fora name of the testing framework. :P
@PauloCereda My English is not so good so I need a little bit time to understand. I think the German DIN is the most blasphemous document in German typography history. Typography and DIN can't really get come together but is often used for letters and some stupid rules how to typeset a thesis.
@PauloCereda But If you know not only ABNT (I think it could be helpful for Germans not knowing this) please feel free and add an answer. Perhaps in this case we leave "blasphemous"? :-)
user19161
@matthew I just looked up the verse and realized I knew it too.
@TorbjørnT. thanks for the help earlier. Can you ask him how to include citations using his template. I tried with \cite{label} but it did not work. may be u can take a look at the template he provided
@PauloCereda of course there is. The birds are great (even if the jury is still out on which in the end is going to fly ... both approaches are equally nice)
I'm having issues with switching between the fancy and plain page styles. I defined both styles in the preamble but once I have chosen the plain style I don't seem to be able to activate the fancy style at a later point. Below is a minimal working example. I would expect the first chapter to rend...
He uses biblatex, so you probably have to run biber , and not bibtex. Other than that, \cite should work just fine. I.e., the compilation sequence should be pdflatex document biber document pdflatex document
@GonzaloMedina Thanks for the heads-up about dupe accounts (from yesterday). I've done a merge: it seems the user in question keeps using 'throw-away' e-mail addresses to create accounts.
I want the the following table to be perfectly centered within the margin, with an approximately even spacing between each column.
\documentclass[a4paper,11pt]{article}
\usepackage{color,amsmath,amsfonts,amssymb}
\usepackage[english]{babel}
\usepackage{colortbl}
\usepackage{booktabs,...
@JosephWright Not at all. I only know that he wants to hack dcolumn to allow something like (Q....) there, where the correct solution would be to split that into more columns...
@Kurt I'm a bit reticent to include such incisive remark about ABNT. :) Just to extend my comment, ABNT stands for Brazilian National Standards Organization (the acronym is in Portuguese), and it is the normative body which is responsible for technical standards in Brazil. Sadly, everybody in academia has to follow the specs they "impose". IMHO it's a horrible document. I'll come up with some lines trying to be less ballistic while talking about ABNT. :)
@MarcoDaniel It would help other people read the TeX code and also help people post their TeX file, say in arXiv. I think this is helpful if you're colloborating for instance. :)
On the one hand, you'd like to type fast and on the other hand, you'd like other people to understand our TeX code. So, I guess an answer to the question would serve as a bridge in my humble opinion.
I am not sure the comment there is relevant.
Firstly, yes, it leads to questions of the same flavour (one question is the same as mine) but the answers are not helpful.
@KannappanSampath: well, I have a test script with some regular expressions that work for your MWE, but the script won't "resist" an attack of a more complex (real world) file. TeX is context sensitive, so it will be difficult to achieve something good that works for all cases. :(
You can't parse [X]HTML with regex. Because HTML can't be parsed by regex. Regex is not a tool that can be used to correctly parse HTML. As I have answered in HTML-and-regex questions here so many times before, the use of regex will not allow you to consume HTML. Regular expressions are a tool th...
import re
import sys
if len(sys.argv) != 3:
print('We need two arguments.')
sys.exit()
inputHandler = open(sys.argv[1], 'r')
mathDictionary = {}
commandDictionary = {}
print('Extracting commands...')
for line in inputHandler:
mathOperator = re.search('\\\\DeclareMathOperator{\\\\([A-Za-z]*)}{(.*)}', line)
if mathOperator:
mathDictionary[mathOperator.group(1)] = mathOperator.group(2)
newCommand = re.search('\\\\newcommand{\\\\([A-Za-z]*)}{(.*)}', line)
if newCommand:
My humble attempt works with \newcommand and \DeclareMathOperator, as long as the new command has no optional arguments, and both definitions end at the very same line. :)
@KannappanSampath I'm sorry, but this one was your fault. :) You had to tell me which one to replace. :) \DeclareMathOperator{\Enda}{Endb}, which value you want it to appear? :)
import re
import sys
if len(sys.argv) != 3:
print('We need two arguments.')
sys.exit()
inputHandler = open(sys.argv[1], 'r')
mathDictionary = {}
commandDictionary = {}
print('Extracting commands...')
for line in inputHandler:
mathOperator = re.search('\\\\DeclareMathOperator{\\\\([A-Za-z]*)}{(.*)}', line)
if mathOperator:
mathDictionary[mathOperator.group(1)] = mathOperator.group(2)
newCommand = re.search('\\\\newcommand{\\\\([A-Za-z]*)}{(.*)}', line)
if newCommand:
@PauloCereda I don't think mine will be very good- I'm struggling with \N in perl at the moment :) I'm looking forward to voting for your answer though :)
@Brent.Longborough Indeed. :) Regex always gives me headaches (not the mathematical model, thankfully), I'll try to "fix" the code as you suggest. I'm still a Python grasshopper. :)
@PauloCereda I think the Python re library implements full PCRE, including the non-greedy option. There are a number of interactive regex debuggers available - I use The Regex Coach