Search:   Help

Navigation

Groups

LyX documentation

Edit

Shared groups

Links

LyX /

New in LyX 2.3

Categories: Development, LyX_2_3
<< | Page list | >>

About the new features in LyX 2.3.

What is new in LyX 2.3?

The LyX Team

March 2018

§1.  New features brought by the new file format

§1.1  Biblatex support

(:statusicon documented:)At long last, LyX 2.3 introduces native support for the state of the art bibliography package, Biblatex. This addresses one of the most frequent user requests.

Biblatex support is not comprehensive in the sense that each and every of the many features of the package is (already) natively supported via the GUI, but it is now possible to

  • select Biblatex alternatively to "Basic", "Jurabib", or "Natbib" in the Document Settings,
  • set bibliography (*.bbx) and citation (*cbx) style files (LyX will propose sensible defaults for author-year and numerical),
  • set arbitrary biblatex package options via a simple line edit widget,
  • set options to the \printbibliography command via a simple line edit widget in the Bib(la)TeX inset dialog.

The support furthermore includes the following features:

  • As for Natbib and Jurabib, LyX will offer a range of citation styles for Biblatex in the citation dialog/context menu and output the appropriate citation commands.
  • LyX also supports Biblatex's "qualified citation lists", i.e. multi-cite references with an optional pre- and postnote field for each individual item.
  • LyX is now aware of Biblatex's rather different bibliography handling and outputs the appropriate commands (\printbibliography and \addbibresource) at the appropriate places in the LaTeX output.
  • Support for multiple bibliographies (refsections), including cumulated output of these sections (Biblatex's \bibbysection command)
  • LyX now scans and detects the relevant files (package, style files)
  • By default, LyX automatically selects biber as processor (if installed) if Biblatex is used (and bibtex otherwise).
  • If bibtex or bibtex8 is selected as a bibliography processor (instead of biber), the relevant backend option is automatically set
  • Biblatex citation styles are also correctly exported to xhtml and plain text.

Simply put, you can now do (almost*) everything with Biblatex you could already do with Natbib or Jurabib in previous versions of LyX, and more (*with the exception of "Subdivided [aka "Sectioned"] Bibliographies", which are easily possible with Biblatex, but too different to be supported by the current "Subdivided Bibliography" check box. See the Biblatex manual for details).

We have put most energy into a design that enables portability between the diverse citation engines as much as possible, so it should be rather straightforward to switch an existing document from, say, Natbib to Biblatex and (to a limited degree, since the feature set is larger) back.

§1.2  Multiple bibliographies

LyX has supported subdivided bibliographies for a long time, drawing on the bibtopic package. LyX 2.3 introduces support for multiple bibliographies (per part, chapter, section, subsection or child document). This uses Biblatex's features, if Biblatex is used (see above). For classic BibTeX, either the bibtopic or the chapterbib package is used (depending on the setting). Since we draw on bibtopic, it is possible to combine multiple with subdivided bibliographies.

§1.3  Inverted branches

(:statusicon documented:)

LyX now supports "inverted" branch insets: Ones whose content will be output if the branch is not activated. This allows users more easily to define alternative text for two versions of a document.

§1.4  Quotation marks enhancements

The quotation marks inset has undergone a thorough revision. Several long-standing bugs have been fixed and some enhancements have been implemented, most notably

  • (:statusicon documented:)LyX now features "dynamic quotation marks". These automatically adapt to the global quotation mark style (and its changes).
  • (:statusicon documented:)So-called "plain" (i.e., non-typographical) quotation marks are now properly supported.
  • (:statusicon documented:)The following new quote styles have been added:
    • ‘british’ (“inner quotation”)
    • 「cjk」 (『inner quotation』)
    • 《cjkangle》 (〈inner quotation〉)
    • «french» (“inner quotation”)
    • «frenchin» («inner quotation») ["in" = Imprimerie Nationale]
    • «russian» („inner quotation“)
    • »swedishg» (’inner quotation’) ["g" = Guillemets]
  • (:statusicon documented:)The quotation mark style, level and side can be easily switched via context menu.
  • (:statusicon documented:)LyX now exports proper typographical quotation marks to XHTML and plain text.
  • The automatism to set opening or closing marks has been improved significantly.
  • The internal functions (lfuns) have been extended, so it is now easy to insert a specific quotation mark (e.g., German single opening) via lfun (quote-insert inner opening german in the example case) or change some characteristics (e.g. the style) of all existing quotation marks via the minibuffer (e.g., inset-forall Quotes inset-modify changetype g.. to change all quote insets to German style, while maintaining side and level); see the description of the inset-modify and quote-insert functions in Help > LyXFunctions).

§1.5  Updates to reference handling

(:statusicon documented:)

  • There is a new reference format, `label only', which prints just the LaTeX label. This allows for additional customization, should the user wish to put a custom command, not supported by LyX, into ERT.
  • The refstyle package allows for automatic capitalization and pluralization of formatted references. LyX now supports this feature. Note, however, that it only supports it insofar as refstyle itself does. So if you have a customized reference format (say, for corollaries), then you will need to define appropriate commands for caps and plurals. For example: \newref{cor}{name = corollary, names = corollaries, Name = Corollary, Names = Corollaries}. See the refstyle package documentation for more details, or have a look at the default refstyle.cfg.

§1.6  Improved LaTeX handling in dialogs

(:statusicon documented:)

Text that is added to the document via dialogs (e.g., "text after" in the citation dialog, "label" in the bibitem dialog, "name" in the hyperlink dialog, "index name" in the document dialog) is now properly prepared for the LaTeX output (special characters are transferred to LaTeX macros and necessary packages are loaded, special characters such as '&' are escaped). The affected dialogs furthermore provide a "literal" checkbox that allows the insertion of literal LaTeX code.

§1.7  Fonts

(:statusicon documented:)The LaTeX package microtype (for micro-typographic enhancements) is natively supported via the document preferences.

The following (LaTeX) fonts are now supported natively:

  • Crimson (via the cochineal and newtxmath packages, with fall back to the crimson package)
  • Noto (font family designed to cover all the scripts encoded in the Unicode standard.)

§1.8  New supported document languages

  • Amharic
  • Asturian
  • Bosnian
  • Friulian
  • Kannada
  • Khmer
  • Macedonian
  • Piedmontese
  • Romansh
  • Syriac
  • Urdu

§1.9  New supported LaTeX commands

  • (:statusicon documented:)Support for the command \xout that is provided by the LaTeX package ulem. This allows to cross out text via LyX's character dialog:
  • (:statusicon documented:)Support for the document class option fleqn and the length \mathindent. This allows to set that displayed formulas are indented instead of centered and to specify the indentation length:
  • (:statusicon documented:)Support for the length \baselineskip. It is now possible to select the unit "Line Distance %" as unit for all lengths in the dialogs. 100% Line Distance is the height between the baselines of two subsequent text lines.
  • (:statusicon documented:)Support for the document class options leqno and reqno. This allows place the formula number at the left or right side:
  • (:statusicon documented:)Support for the environment subequations via the new module subequations. This module provides the custom inset subequations in which one can input the equations:

§1.10  New template for Inkscape drawings

  • (:statusicon documented:)LyX has now the new external inset template Inkscape figure. This allows to include drawings created with the program Inkscape whose text is typeset by LaTeX. For information, see sec. 7.1 of LyX's EmbeddedObjects manual.

§2.  General improvements

§2.1  Handling of environments (e.g. beamer frames)

(:statusicon documented:)Particularly driven by the feedback we got about some shortcomings in the editing of beamer frames, the following improvements have been made:

  • Contents within particular environments (most notably beamer frames) are now automatically nested while the layout is set.
  • Follow-up paragraphs of a labeled paragraph group (belonging to one environment) are marked as nested. This indicates better what actually belongs to an environment.
  • Edit→Start New [Parent] Environment has been moved to the Insert menu and renamed to Insert→Separated <Environment Name> Below
  • A new function Insert→Separated <Environment Name> Above has been added which makes it easy to add a new beamer frame before the current one
  • Insert→Separated <Environment Name> Below now also works outside the nesting scope (e.g. in a non-nested Standard paragraph following a frame).

§2.2  Footnotes in tables

Footnotes in tables will now directly be output. It is no longer necessary to use TeX or preamble code to achieve this.

§2.3  Localization of nomenclature

Nomenclatures are now fully localized.

§2.4  New translations of the LyX user interface

  • Greek
  • Russian

§2.5  Improvements to on-screen display of math equations

The display of math has seen major changes. LyX now gives a good idea of the appearance of math equations in the typeset output, often matching the instant preview.

  • Several rules from the math typesetting algorithm described in Appendix G of the TeXbook have been implemented. Most importantly, the spacing between symbols is computed according to their class, including in complex situations involving math macros.
  • The display and selection of fonts has been improved. Text fonts are properly reset into a math font inside various insets as in the output; the font of math ERT has been fixed. The (absence of) kerning for \mathnormal, \mathscr, and \mathcal is more faithful to the output.
  • Spacing relies less on hardcoded pixel values and more on math units that depend on zoom and dpi. This should be good for HiDPI systems.
  • Font sizes and lengths in sub/superscripts are more accurate.
  • Math characters that behave like symbols in math (*, -, and :) are now displayed and spaced properly.
  • The display of fractions, binomials, and nice fractions has been fixed and improved.
  • The display of vertical and horizontal lines in math tables has been fixed.
  • (:statusicon documented:)AMS environments now display the correct horizontal alignment and a more accurate column spacing. Only the alignment options that are reflected in the output can now be selected.

The biggest change is the spacing algorithm. One typical example is that “-a” has no spacing, contrary to “a - b”. This reflects the difference TeX makes between unary and binary minus that will indeed appear in typeset output. Macros are handled properly; the spacing inside a macro will depend on the values of the arguments and the elements that are before and after the macro.

(:statusicon documented:) A consequence of these changes is that user macros that contain hand-crafted screen representations may have to be revised. Note that it is now possible to make use of the class macros: \mathrel, \mathbin, \mathop, \mathord, \mathopen, \mathclose, \mathinner, and \mathpunct. In particular \mathrel, \mathbin, \mathop, and \mathord are accessible from the “Styles & classes” toolbar.

§2.6  Automatic detection of file changes

(:statusicon undocumented:)

LyX detects external modifications to files in real-time and warns about it. It is also instantaneous for updating graphics when they change, and more battery-efficient.

§2.7  Citation & reference dialogs

Along the way of the new Biblatex implementation, we have polished, streamlined and extended the bibliography-related code at many places. This also allowed us, en passant, to fix some bugs and implement some long-standing desiderata (such as the display of upper-cased names and full author lists in the GUI and the text/xhtml output).

The citation dialog has been simplified. A more important focus is given to the filter box. Keyboard navigation has been enriched: it is now possible to select and edit citations quickly using only the filter, arrow keys, Enter, Backspace and Ctrl+Enter. Similar improvements have been made for the references dialog.

§2.8  Improvements to cursor movement and selection

  • (:statusicon undocumented:)A new movement and selection mode in math has been implemented: word movement and selection (Ctrl+[Shift+]Left/Right). In this mode, the cursor does not enter nested insets, and moves according to “words” composed of symbols within the same math class.
  • Selection starts in the middle of insets both in math and in text. This makes selection with the mouse considerably more convenient.
  • (:statusicon undocumented:)The deletion protection mechanism from math has been generalised to text. Trying to delete a big inset selects the inset first.
  • The horizontal position of the cursor is now remembered when moving up/down.
  • Shift+click now correctly works to perform a selection across insets.
  • Various bugs when clicking and releasing with or without selection have been fixed (Tabular, InsetMathSpace and more).

§2.9  Improvements to row breaking and alignment

  • Row breaking is improved for languages that do not rely on spaces, such as Chinese. This also improves the breaking of overlong words.
  • (:statusicon undocumented:)Justification: stretching no longer produces illegible lines, thanks to a cap of 1.5em to the stretching of spaces. The stretch is now proportional to the em, for instance one will see if a space is set in a smaller or bigger font size.

§2.10  Outliner and navigation menu

  • There are now a list of Theorems and Definitions from the various Theorems modules, and a list of Sweave and Knitr insets from the corresponding modules, and TODO notes from the todonotes module.
  • (:statusicon documented:)More generally, layouts can customize table of contents available in the UI using the “AddToToc” keyword.
  • The list of equations has been improved.
  • Although the outliner is still clumsy at times, full collapses have been fixed in several situations.

§2.11  Forward/Reverse search and error reporting

  • Reverse search is more precise and no longer fails for no reason (e.g. when triggering reverse search on empty areas).
  • Reverse search centers and updates the screen.
  • Reverse-search and error reporting now selects the complete line.
  • (:statusicon undocumented:)Error reporting and reverse search now work for the InPreamble layout option. This opens the door to correct error reporting inside preambles, provided one writes the preamble using the InPreamble inset from the InPreamble module.
  • Correct forward/reverse search and error reporting for Inset arguments and captions.

§2.12  Change tracking

  • The change tracking cues (strike if deleted, underline if added) now appear over insets, including collapsible insets, math insets, tables, graphics, and previews.
  • The change tracking toolbar is now shown automatically whenever there is a change in the document, not just when it is activated.
  • The review changes dialog has been improved.

§2.13  Code preview & highlighting

  • (:statusicon documented:)The “Source Pane” has been renamed into “Code Preview Pane” to better reflect its purpose.
  • (:statusicon undocumented:)Double clicking on the code preview pane triggers reverse-search.
  • Command names containing @ are now correctly highlighted in the preamble. This reflects that \makeatletter is in effect in the preamble and should not be added a second tme.
  • Colours are now compatible with dark themes.

§2.14  Shortcuts

  • LyX now prioritize the shortcuts from the work areas that start with Alt, over the menu accelerators. This partially fixes the behaviour under KDE which randomly changes the menu accelerators.
  • The shortcut preference pane has been improved with better feedback and error reporting.

§2.15  New or changed LFUNs

The following functions have been added:

  • buffer-external-modification-clear Clear the external modification flag on the current buffer
  • buffer-zoom Zooms the screen fonts to a given value or resets to the default zoom when no argument is given.
  • branch-invert Toggles inversion status of branch inset.
  • devel-mode-toggle Activate/deactivate the developer mode, which consists mainly in: (1) more information shown in the status bar and (2) help file opened in editable mode. This state used to be hardcoded at compile time.
  • font-crossout Cross out characters.
  • icon-size [size in px] Set the icon size in the toolbar
  • lyx-activate Activates the LyX window. Useful in combination with reverse search.
  • toolbar-movable Toggles movability of a given toolbar.

The following functions have been changed:

  • buffer-export If no or default argument is given, the function now exports to the default output format.
  • buffer-zoom-in, buffer-zoom-out The Zoom value set by these is now relative to the default zoom value set in preferences.
  • inset-modify This function now also applies to quote insets. It takes a three-character string as an argument, referring
    (1.) to the style (e = ``english'', s = swedish, g = ,,german``, p = ,,polish'', f = <<french>>, a = >>danish<<),
    (2.) to the side (l = left, r = right) and
    (3.) to the quotation level (s = single, d = double).
    So eld means "English left double quotation mark". A dot in the string means: take the current value. So inset-modify changetype e.. will only change the style to English, while letting side and level as is, inset-modify changetype f.s will change the style to French and the level to single, leaving the side value.
    This function is most useful when combined with inset-forall. E.g.,
    inset-forall Quotes inset-modify changetype f.. ⇒ change all quote insets to French style, maintaining current side and level
    inset-forall Quotes inset-modify changetype ..s ⇒ change all quote insets to single quotes, keeping style and level
    inset-forall Quotes inset-modify changetype g.s ⇒ change all quote insets to German single quotes, keeping left/right setting
  • paragraph-goto The function has now two further optional arguments that determine end positions. If specified, a selection is performed.
  • quote-insert The function now has a second and third optional argument to specify the side (left, right, auto) and quotation mark style (english, swedish, german, polish, french, danish).
  • specialchar-insert New option allowbreak that adds an invisible line break option,
  • word-delete-forward, word-delete-backward, char-delete-forward, char-delete-backward The pre-2.3 behavior of these functions is equivalent to the 2.3 behavior with the "force" option appended. The new default behavior (without "force") is to select big insets on the first call and delete them only on the second. This new behavior is consistent with how delete works in LyX's math editor.

§2.16  Layouts

  • New layout for the new Association for Computing Machinery (ACM) document class.
  • New layouts for the Japanese Article (BXJS) document classes.

§2.17  Module enhancements

  • Colors have been fixed for the TODO Notes module.
  • (:statusicon documented:) Passing final as document class option now disables the output of TODO notes.

§2.18  External templates reorganization

(:statusicon documented:)Up to LyX 2.2, all templates for formats that can be input to LyX via Insert→File→External Material were defined in one monolithic external_templates file, to the effect that you had to copy and change this whole file if you wanted to alter an existing template or add new ones. With LyX 2.3, the monolithic definition file has been dropped in favor of one file per template. These new template files use the filename suffix *.xtemplate and are now located in lib/xtemplates/. This change makes it much easier to add your own templates or modify existing ones.

Note: If you have modified the external_templates file, you will have to move the modifications to the respective *.xtemplate file manually.

§2.19  Image formats and conversion

  • The converters definition syntax (LYX_HOME/lyxrc*) now supports a new option, 'needauth', to prevent completely automated execution of the converter, unless LyX acquired explicit consent by the user. This is a new security feature, useful for converters that are capable of executing arbitrary code, such as R scripts (used with sweave/knitr), embedded within LyX documents. The user needs to explicitly grant per-document permission on the first need for using the converter on each document, unless he/she checks the "Don't ask again for this document" checkbox in the permission dialog. The new behavior can be fine-tuned from two new options in the preferences dialog (see their description below). These also allow for disabling 'needauth' converters altogether, if desired (default behavior).
  • LyX now supports insertion and automated conversion of Gnuplot scripts, recognized by their typical extension ".gp" or ".gnuplot". These can directly be inserted in a LyX document using the "Insert->Graphics..." dialog, then selecting the Gnuplot script. LyX automatically adds a proper "set terminal ..." and "set output ..." line to convert the file to the needed output format (e.g., .eps, .pdf), depending on whether the document is being previewed on screen or compiled as PDF or other formats. Terminal options cannot be fine-tuned at the moment, but that's a capability that may come soon, also according to the received feedback from users. In order to try this out, a minimal .gp file can be the following:
        set grid
        set xlabel "Sample"
        set ylabel "My Value"
        plot exp(-x) t 'Titles'
    
    

§2.20  New preferences settings

  • \default_platex_view_format
    Determine the default output format for Japanese documents that use the pLaTeX backend [default: "pdf3" == "PDF (dvipdfm)"]
  • \jbibtex_alternatives
    Alternative bibliography converters for Japanese.
  • \pygmentize_command
    holds the name of the driver command used by the Pygments python module.
  • \use_converter_needauth
    when enabled, user is asked before calling any external converter with the 'needauth' option
  • \use_converter_needauth_forbidden
    when enabled, use of external converters with the 'needauth' option is forbidden

§2.21  Miscellaneous

  • TeX Mode (ERT) and verbatim layouts are no longer hardcoded to latin1 encoding. The encoding is now inherited from the context. So it is now possible, for instance, to enter Cyrillic characters in ERT in Russian documents.
  • Remove question mark from dialogs in Windows.
  • Sorting strings based on the locale (e.g. É comes after E) has been improved.
  • The maximum number of remembered files has been increased.
  • The names of debug modes are shown in the message pane.
  • Allow swapping unmatched math delimiters.
  • (:statusicon documented:)Option to use the LaTeX package minted for the typesetting of code listings.
  • Allow enabling -shell-escape only for specific documents, rather than having to enable it globally in preferences.
  • LyX now provides a global default output format for Japanese documents (via pLaTeX)

§2.22  Under the hood

  • Tooltips can be made more informative across the while application thanks to automatic formatting with rich text, and automatic line breaking. Several tooltips now use rich text: bibliographical references, the symbols selection dialog, the module selection.
  • New file monitoring mechanism.

§2.23  Backported

2.24  Categories

Edit - History - Print - Recent Changes - All Recent Changes - Search
Page last modified on 2018-05-08 14:31 UTC