Dear Georg, dear all, On 2015-11-05, Georg Baum wrote:
> I started to work on bug 9744 in order tor get better test results, as > discussed. Attached is a proof of concept for the automatic font selection. Thanks for your work and thanks for the patch. For the Document>Settings>Fonts GUI, I suggest * radiobuttons or drop-down list for the "fontspec" setting (auto, tex, non-tex) * two tabs for tex vs. non-tex fonts settings. This would make it obvious to the user that the settings can be specified and are kept independently. Currently, it is also not clear which font set is displayed/configured with the "automatic" setting. > However, while working on this, I realized that this will create a > combination of settings where we need to make an arbitrary choice: What > should happen if the fonts are set to automatic, and the user wants to view > the default output format? With the patch, the traditional route via TeX > fonts is chosen, but this is an arbitrary decision which I do not like. I can understand the hesitation. One reason for this "double automatic" is, that due to the current setup we have two competing "Default Output Formats" under Tools>Preferences>File Handling¹ With TeX fonts: With non-TeX fonts: With automatic selection of TeX vs. non-TeX fonts, there could be just one Default Output Format (and maybe a list of substitutes in case the document settings prevent the user preverence). ¹ why are they under "File Handling" and not "Output"????? > One motivation for the automatic setting was to get the tests right. The tests were a trigger for #9744, but the motivation behind it is stated in the description: The usual advise for users experiencing problems with 8-bit TeX is «use XeTeX» or «use LuaTeX». With the current LyX GUI, the most obvious user reaction would be to click the "view other formats" button and try XeTeX or LuaTeX. However, this will usually not solve, but worse the problem. The reason is, that the common advise "use XeTeX" usually implies also to select OpenType fonts with the "fontspec" package. With LyX, this requires checking Document>Settings>Fonts>Use non-TeX fonts. > The other motivation would be real use cases by users, and here I am > not sure: Do such uses cases exist? I am not aware of any. Without the > automatic setting, the user would have to chose betwen TeX and non-TeX > fonts, and the recommendation would be to use the default output format > for viewing. Then we would not have two competing automatic settings, > and I believe that it is quite unusual to switch frequently between TeX > engines (but please correct me if I am wrong). I tend to use the "View other formats" options a lot to try how a document looks in different output formats. I really like the possibility to test different formats without the need to change the document. For HTML or OpenOffice the font set is chosen according to "best practice" (or just not chosen at all). For XeTeX/LuaTeX, the "best practice" (use together with fontspec) is only available after an explicit change to the document, which has to be reverted to be able to export to 8-bit TeX again. > The test problem could easily be solved in the test machinery instead: When > exporting via XeTeX or LuaTeX, switch to non-TeX fonts, even if the document > has a different setting. Yes, this is possible. However, if a user wants to compare how our manuals look after export with LyX-HTML, PDF (ps2pdf), PDF (pdflatex), PDF (luatex), the comparison is unfair, because luatex is used with a non-recommended setting. > Unless someone presents a convincing use case for the automatic > setting, I would like to proceed this way, and only duplicate the font > settings, so that both the TeX and non-TeX settings could be stored in > parallel. The GUI would still look exactly like before, but you would > not loose the "other" font set if you toggle. This would in any case be a big advantage. It is also the pre-condition for "automatic" choice, if we decide to use this. Thanks, Günter