Am Donnerstag, 1. Dezember 2016 um 12:58:34, schrieb Kornel Benko <kor...@lyx.org> > Am Donnerstag, 1. Dezember 2016 um 12:03:02, schrieb Enrico Forestieri > <for...@lyx.org> > > On Thu, Dec 01, 2016 at 11:47:19AM +0100, Kornel Benko wrote: > > > Am Donnerstag, 1. Dezember 2016 um 01:01:44, schrieb Enrico Forestieri > > > <for...@lyx.org> > > > > > > > > Or we can add the braces on output, as done in the attached patch (also > > > > including the previous one). The braces will be added anytime a macro > > > > has optional arguments (not only when it is nested), but, given that > > > > this > > > > avoids a latex error, I think it is acceptable. > > > > > > > > The test case now displays and compiles fine for me. > > > > > > > > > > Confirmed, works very nice. Please commit. > > > > I found a small glitch with the previous patch. As the braces are always > > added and lyx removes only the ones appearing in a macro argument, if you > > copy/paste a macro with optional arguments you always get the outer braces, > > which tend to accumulate. Instead, the attached patch only adds the braces > > if the macro is actually in the argument of a math macro, thus avoiding > > this issue. Please, also test this one. > > > > First test looks good. Started export test suite ... this can take a while. > I have to go now, so feel free to commit. >
Please commit. Looks good. There are export tests failing, but the reason is with unicode symbols because of iconv. For example: -- Executing /BUILD/BUILDMint17/BuildLyxGitQt5.7main-gcc6.2/bin/lyx2.3 -userdir "/BUILD/BUILDMint17/BuildLyxGitQt5.7main-gcc6.2/Testing/.lyx" -E pdf2 latex/unicodesymbols/001-4-latin_defaultF.pdf2 "/BUILD/BUILDMint17/BuildLyxGitQt5.7main-gcc6.2/autotests/out-home/AbC_rYB0zt/latex/unicodesymbols/001-4-latin_pdf2_defaultF_cp437.lyx" Error 22 returned from iconv_open(out_cd_): Invalid argument Caught iconv exception: iconv problem in iconv_codecvt_facet initialization Error: Iconv software exception Detected Here 'iconv -l' shows the coding 'CP437', but not 'cp437'. And, if I use this encoding, the test pass. Kornel
Description: This is a digitally signed message part.