<< | Page list | >>
About the new features in LyX 2.4.
What is new in LyX 2.4?
The LyX Team
Work on LyX 2.4 started in August 2017, in parallel to the final preparations of LyX 2.3.0 (which has been released in March 2018). Since then, the LyX development repository has seen more than 6400 commits with contributions by 34 persons, ranging from singular contributions to more than 1900 commits by the most active developer (state: February 2022).
Over this time, LyX has changed significantly all over the place. LyX 2.4.0 thus will bring many new features, user interface improvements, but also improvements under the hood that make LyX more stable, faster, pleasant, and more reliable.
Many (also long-standing) bugs have been fixed for this release (needless to say, the changes will also entail new bugs that are still to be detected).
We believe LyX 2.4.0 will bring significant, and some long-awaited, enhancements to many users. In what follows, we will introduce the new features we consider most important ourselves.
Unicode is now default everywhere
LyX has been using Unicode (utf8) internally for a long time now. Unicode has also been used with the "modern" TeX engines (XeTeX, LuaTeX) by default.
As of LyX 2.4, with LaTeX itself having switched to utf8 as default in 2018,
LyX now also uses utf8 encoding per default in classic (pdf)latex.
"Per default" certainly means that the traditional encodings are still available and can still be made selected automatically.
Note that this does not affect existing documents (which are left untouched). Note also that LyX also does not touch personal defaults and templates.
That is to say, if you still see traditional encoding preset for new documents, you can change that in Document→Settings...→Language
by selecting "Unicode (utf8) [default]" and hitting "Save as Documents Defaults" afterwards. Your personal templates need to be changed manually if desired.
Starting with LyX 2.4, all documents can be transformed into ePub 3. This feature is implemented on top of the DocBook 5 export, and has the same limitations (mostly, Beamer documents are not supported).
DocBook 5 support
LyX 2.4 introduces a rewritten support for DocBook, updated for DocBook 5. Most notably, all LyX documents can be output as DocBook, using a specific layout is no more required.
This feature is implemented to work properly with most books and articles; support for Beamer may appear at a later stage; output from posters is likely to be useless.
Previous versions of LyX generated XHTML 1 code, while LyX 2.4 will produce XHTML5 output with some semantic tags (
<section> for all documents). The resulting files are closer to validity than previously. They can still be parsed as XML.
This update required a major change: LyX no longer generates HTML entities (like
& nbsp ; for a nonbreaking space), only XML entities (
&# 0160 ;).
LyX now provides several table styles from which you can select when inserting a table. For instance you can now select, either locally in the Insert→Table dialog or globally in Document→Settings...→Text Layout, that newly inserted tables automatically use the "formal" (a.k.a. booktabs) style, a simple grid style, or no border lines at all. A style pre-selection can also be made in the layout file. You can even define new styles, which is as simple as
creating three LyX documents, each containing a table in your style (with one, two, and three rows, respectively).
Variable table column width
LyX now features a "variable" table column width that makes the column automatically expand to match the specified table width (this feature uses the tabularx package for single-page and the xltabular package for multi-page tables).
Less constraints in standard table columns
LyX now allows paragraph and line breaks as well as layout changes in non-fixed width table columns (incl. multicolumns and multirows). Internally, the column type "V" and the varwidth environment provided by the varwidth package are used for this purpose.
Trimming of formal table's midrules
Formal tables often use disconnected midrules to indicate grouping of columns (the booktabs package that is used for formal tables supports this by means of the (l) and (r) arguments to \cmidrule).
LyX now supports this as well:
New Templates/Examples dialog
- LyX 2.4 introduces a new dialog to access templates and example files (via File→New From Template... and File→Open Example..., respectively). This dialog lists those files in a transparent, structured way. It includes also examples and templates from the user directory (which have been hard to access with the native file dialog).
The example and template names are also more explanatory, and they are translated to the GUI language.
Furthermore, it is now easier to store new template files through the new menu item File→Save As Template..., which will guide you to the appropriate location in your user directory.
Redesigned (simple) Find & Replace dialog
- LyX 2.4 makes the find-replace dialog a dock widget, by default (though it can also be detached). This prevents that the dialog hides any text, let alone search results, while searching. As the two screenshots below show, the dialog can be minimized (to show just search) or expanded (to show replace and search options as well).
- New features of the simple search facility include "search as you type", "search/replace in selection only", and automatically wrap to start/end of document without asking. Furthermore, selected text is initally proposed as search term when opening the dialog.
- On Linux and Windows, Shift-F3 is now the shortcut for word-find-backwards (i.e., find previous), as on most other applications. (On OSX, this is still Command-G.)
- On OSX, the Command-E shortcut to store selections in the search buffer (for later re-use with Command-G) is now supported. A similar feature is available on Linux and Windows via Ctrl-F3.
Redesigned Text Properties dialog
- The Text Properties dialog, which has been very badly designed and thus subject to many bug reports and irritations, has been completely reworked and now looks and behaves more like users expect. Particularly the "toggling" behavior that irritated so many users has been dropped:
Most of this re-design has also been backported to LyX 2.3.2 (with improvements in LyX 2.3.3).
Furthermore, there is now an option to exclude text passages from spellchecking.
Redesigned Bib(la)TeX dialog
- The Bib(la)tex settings dialog has undergone a major redesign as well. It now displays available and selected bibliography databases in one place, and has gained some new functionality (such as general and [only with biblatex] per-file encoding selection, external editing of individual databases, inheritance of databases from the master document, and a filter for quick selection in large lists)
Redesigned Module Selection dialog
- The module selection in Document→Settings...→Modules now displays the available modules sorted by categories. This should make it easier to locate modules for specific tasks.
The information display has been improved.
Furthermore, there is now a filter for quick search of modules both by GUI name and module (file) name.
- Math equations numbers are now drawn outside of the inset, which makes them properly centered and easier to edit. In particular, an empty line can be added to accommodate long labels, similar to what LaTeX does when typesetting.
- Math operators like \sum are now bigger in display style.
- Superscripts and subscripts in text mode are now displayed correctly in a smaller size and the spurious spacing around them has been removed.
- Italic font at the cursor position is now indicated by a slanted caret.
- Selections are now tight around the actual text even in the presence of top labels or large vertical margins.
- Lines of text are now correctly broken on screen after insets (spaces, hyphenation points...) which allow line breaking.
- The algorithm that handles line breaking has been reworked to improve performance. This is in particular noticeable for documents that contain very large insets.
Better support for index entries
If you wanted to use more extended index features (such as subentries, sortkeys, "see" references, page ranges or pagination formatting), you needed to
resort to the rather esoteric makeindex syntax in LyX until now.
LyX 2.4 introduces native support for all these features via specific sub-insets and dialog settings:
This also comes with significant advancements of index generation in other formats than LaTeX (particularly XHTML and docbook).
Furthermore, existing index entries can now easily be re-used via the outliner context menu: right-click on an index entry to insert a copy of it at the
current cursor position. This way, you don't have to re-type recurrent index entries and you do not have to remember the exact wording. And we added a
convenience function to automatically index all occurrences of a given word (via the index inset context menu).
Flexible text fields
LyX since long had a rather crude Insert→Date function that inserted a static date formatted via the
strftime programm. Its usability was rather limited. To improve this, LyX 2.4 introduces the concept of "Fields" known from word processors. Most notably, it features different date and time formats which adapt to the context language. Besides these, some other information types such as file name, user name/email and version control information are available as well (next to types that are mostly relevant to developers and used in the LyX manuals, such as LaTeX package availability, LyX function shortcuts etc.; this latter information has been available for a long time, but its use was all but transparent).
It has been requested by many users to be able to globally specify an alignment for all float contents. This is now possible. The default alignment of floats contents can now be set in Document→Settings...→Float Settings and locally modified in the Float Settings dialog:
One powerful feature of LaTeX is its ability to manage counters. Mostly, this is handled automatically, but there are times one wants to modify counters directly. This has always been possible via ERT, but the new counter inset allows one to set a counter's value; to reset it (to zero); to add to the value (or subtract from it, since the value added can be negative); to save it; to restore the saved value; and to print the value. These effects can also be limited to LyX itself. And they will appear in HTML and DocBook output, as well as in LaTeX. You can find the new feature via Edit→Manage Counter Values.
External Editing of Insets
The 2.3.x series allowed the user of an external program (e.g., Notepad or Kate) to edit the document preamble and local layout. As of 2.4.0, this will also be possible for some insets, e.g., ERT and Listings. The new functionality can also be enabled for other insets, using the new EditExternal layout tag.
Improved detection of broken citations and cross references
Cross references to non-existing (deleted) labels, citations to non-existing bibliographic references or inclusion of non-existing files can now be detected more easily per different measures:
- They are now colored in the workarea
- There is a dedicated outliner entry "Broken References and Citations" that collects all broken refs and lets you navigate to them quickly
- You get an error message if you want to output the document (you can still view it, but you have been warned)
Line numbering in the output
It is possible to add line numbers in your typeset document via Document→Settings→Numbering & TOC→Line numbering. The lineno package is used in the background; its basic parameters can be passed through the accompanying Options widget.
Change tracking improvements
- Change bars (for change tracking) can now be set from Document→Settings...→Change Tracking. The changebars module has been removed.
- LyX now has a preference setting to toggle underlining of added text (in change tracking mode) in the workarea.
- LyX now has a preference setting to maintain markup on copy/paste.
- Deleted graphics and floats are now marked in the output.
- The addition and deletion of tabular columns and rows is now properly tracked.
- Many long-standing deficiencies in the change tracking output have been fixed.
Spell checking improvements
- LyX now supports per-document spell-checking dictionaries, i.e., words can be marked to be ignored by the spellchecker in the given document only (for a given language)
- Single words or text passages can be marked to be ignored (permanently) by the spell checker
Via Insert→List Preamble or Insert→Bibliography Preamble, you can now insert LaTeX code between the beginning of a list or bibliography environment and the first item. This is helpful if you want to redefine counters or lengths, something that was hitherto only possible via ugly hacks in LyX.
Bibliography- and citation-related improvements
- The bibliography databases can now have a different encoding than the LyX file (you can specify the divergent encoding in the BibTeX/BiblaTeX dialog). With Biblatex, it is even possible to mix bib files with divergent encoding (this requires Biblatex 3.12 at least).
- Citation inset now allows viewing the cited material (URL/PDF file) if a target link is provided or (optionally) if the file can be found on your disk. See User Guide, section "Opening cited documents from within LyX".
- With biblatex, it is now possible to refer to the same entry multiple times (with different pre- or postnotes)
- The use of author-year citations (natbib) with the bibliography environment (rather than BibTeX) is now much more straightforward.
Cancel background export
Since LyX 2.0, LyX has exported files in the background, allowing the user to continue working while the file is compiled. It has not been possible, however, to terminate such a process, except by killing it (or LyX) through the operating system. As of LyX 2.4, this is possible. When a file is exported, a new menu entry, "Cancel Background Process", appears on the Document menu: Selecting it will indeed cancel the export process. This can also be done by clicking on the 'spinner' that appears in the status bar when a file is being exported in the background.
Edit menu changes
The items on the Edit menu have been reordered, and many of the shortcuts have been changed so that they are more intuitive in the case of often used items. We understand that this may frustrate some users and apologize, while noting that menu shortcuts can always be customized by copying the
stdmenus.inc file to the
ui/ sub-directory of the user directory and editing it.
- The "Apply recent text properties" and "Paste" toolbar buttons now provide a history (and thus let you apply more than just the most recent thing).
The "Apply recent text properties" button furthermore provides an option to reset all font settings to the default value with one click:
- Both Custom Character Styles and Custom Insets can now be directly selected from the toolbar.
- The icons that imply a text direction are now inverted when text is typeset right-to-left.
Support for dark themes
LyX now works much better with dark themes. The math and IPA panel icons as well as the colors used in the work area automatically adapt to these themes now.
- The Memoir and KOMA layouts now support more paper sizes natively
- The KOMA layouts now support more font sizes natively
- Memoir now supports endnotes (pagenotes) natively.
- The support for linguistic glosses has been completely rewritten. LyX now uses the new and enhanced \digloss and \trigloss macros of covington rather than self-baked ones. The new macros are more stable and customizable. However, LyX now requires at least covington 2.3.
- The Linguistics module now supports Discourse Representation Structures.
- The Endnotes and Footnotes as Endnotes modules now natively support list of endnotes (via Insert→List/Contents/References→Endnotes). The header is now possibly translated to the current language.
- The Footnotes as Endnotes module now really outputs endnotes rather than redefining footnotes.
New supported LaTeX commands
- Support for the landscape environment of the [pdf]lscape packages has been added in form of the new Landscape module.
- The markup commands of the soul package (\caps, \hl, \so, \st, \ul) is now supported by the Hyphenatable Text Markup (Soul) module
- The Endnotes (Extended) and Footnotes as Endnotes (Extended) modules have been added. They support alternative ways to produce endnotes via the enotez package.
- \medspace and \thickspace (text mode spaces that accompany the respective math spaces) are now supported via the space inset. In recent LaTeX versions (as of 2020/10/01) these spaces (as well as all math spaces) are supported by the kernel, for earlier versions, amsmath is loaded.
- \nopagebreak which suppresses page breaks at the requested position has now its own inset which can be inserted via Insert→Formatting→No Page Break
- \DocumentMetadata, a new LaTeX kernel command (since 06/2022) which allows to specify PDF properties, is supported via Document→Settings...→PDF Properties
- The macros from the hepparticles and hepnames packages are now supported in math editor.
Better handling of special cases
- LyX now has basic support for the cprotect package. This means that "verbatim" input can be used now at places where a LaTeX error would have occurred previously, such as verbatim paragraphs in frame boxes, URLs with characters such as '#' or '%' in section headings or footnotes or comment insets in captions, which allows us to resolve some really old bug reports.
New preferences settings
- The new option Look and Feel→Display→Underline change tracking additions lets you disable the underlining of tracked insertions in the LyX workarea.
- The new option Editing→Control→Keep change tracking markup on copy and paste is for users who don't want tracked changes to be dissolved on copy and paste operations (i.e., inserted as new text with the deletions removed). If this is checked, the change-tracked text will be copied and pasted as is, independent if changes are currently tracked or not. This also applies to wrapping to/dissolving from insets.
New natively supported (LaTeX) fonts:
- Cantarell (the sans serif font used by the GNOME desktop)
- Extended Bitstream Charter (serif) fonts via the XCharter LaTeX package.
- Chivo (sans serif)
- Crimson Pro (serif), an extended redesign of Sebastian Kosch's (already supported) Crimson font by Jacques Le Bailly
- DejaVu Serif, Sans, and Mono (also Condensed)
- Fira Sans and Mono (in all available series)
- The Libertinus family of fonts (including Libertinus Math).
- Noto Serif, Sans, and Mono in all available series (Regular, Medium, Thin, Light, Extralight)
- IBM's Plex Serif, Sans, and Mono
- ParaType's PT Serif, Sans, and Mono ("Public Types of Russian Federation" that focus on Cyrillic but also contain Latin letters).
- Adobe's Source Code Pro, Source Sans Pro, and Source Serif Pro
General font enhancements:
- Support for babel with non-TeX fonts has been enhanced (LyX now supports babel's \babelfont font loading interface if babel >= 3.15 is available).
- It is now possible to enter additional options to font packages (or fontspec) via Document→Settings...→Fonts for selected fonts.
- It is now possible to select "Old style figures" for Sans Serif and Typewriter fonts (separately), if this feature is provided by the respective font.
- The switching of font properties for certain insets (esp. tables and insets with multiple paragraphs) has been improved as far as the LaTeX output is concerned. This allowed us to address some longstanding bugs in this area.
Languages and localization
New supported document languages
- Afrikaans (Polyglossia; Babel already supported)
- Azerbaijani (Babel only)
- Belarusian (Polyglossia; Babel already supported)
- Bengali (Polyglossia only)
- Bosnian (Polyglossia; Babel already supported)
- Church Slavonic (Polyglossia only)
- English (Canada) (Polyglossia; Babel already supported)
- French (Canada) (Polyglossia; Babel already supported)
- Georgian (Polyglossia; Babel already supported)
- Kurdish (Kurmanji) (Polyglossia; Babel already supported)
- Macedonian (Polyglossia; Babel already supported)
- Malayalam (Polyglossia only)
- Mongolian (Polyglossia; Babel already supported)
- Russian (Petrine orthography) (Polyglossia only)
- LyX now supports proper Hungarian quotation marks
- The default decimal separator (used in the tabular dialog for decimal separator alignment) is now language-sensitive.
General language improvements
- The support for some languages has been further improved (this particularly concerns right-to-left languages and languages with non-Latin script)
- LyX 2.4.0 includes new Russian translations of the UserGuide, Additional, EmbeddedObjects, Math, Beamer, ColoredBoxes, and XY-pic manuals.
- LyX now automatically adds the appropriate language and codepage option to the Xindy index processor command.
- Makeindex and xindy errors are now reported in LyX's error dialog.
- The xindex index processor is now supported as well. Xindex is a rather new tool that, like Xindy, supports unicode and sorting of multiple languages and scripts; as opposed to xindy, it is actively developed.
- Advanced find has undergone significant improvements, most notably performance-wise (speedup) and with regard to searching while respecting the formatting.
- The math auto correction feature has been improved: the substitution can depend on more than two characters, can be undone and does not need anymore to be enabled using the ! key.
- The merging of non-default/plain layouts with different layouts is allowed, for example, a numbered list directly below an itemized list by pressing backspace at the first position of the latter layout.
- The performance of compiling multi-part documents with only a subset of children included while maintaining counters and references has been improved.
User interface and user experience
- The dialogs adapt better to your OS/Desktop environment (e.g., order of OK/Apply/Cancel buttons).
- LyX now features a zoom slider.
- The text width in the workarea can now also be set in non-fullscreen mode.
- Document statistics (word and/or character count) can be shown in the status bar.
- Collapsible insets can now be edited externally. This is enabled by the EditExternal inset layout tag. By default, Chunks and ERT can be so edited.
- Clicking on an 'include' inset with the control key held down now opens the included file for editing, without having to go via the settings dialog.
- Opening the Library and User Directory is possible directly from the About dialog.
- Hyperlink inset now allows viewing entered URL via context menu.
- The possibility to switch between raw LaTeX input and formatted input in some dialog widgets has been extended to included listing's captions.
- Text insets can be split into two via the context menu.
- When using the document compare function, there is now an option to display the differences using a special "Document Compare" author.
- LyX now uses the parskip package to add vertical separation between paragraphs. This has the advantage that only paragraph separation is really affected, not separation in TOC and lists. For backwards compatibility reasons, old documents keep the previous settings, but we move them into the user preamble.
Under the hood
- LyX can be built against Qt6 toolkit via
--enable-qt6, though this is still considered experimental. Meanwhile Qt5 (the default) remain supported.
- LyX now uses "semantic linefeeds" for text in LyX files. This allows to have better diffs for documents stored in version-control systems.
New or changed LFUNs
The following functions have been added:
bibtex-database-list output a list of all bibtex files used in the current buffer. The function outputs absolute paths in the OS style and separated by the os-specific
path separator. This function is intended for bibliography managers.
branch-sync-all: Open/close all insets of selected branch (depending on its activation status).
buffer-reset-export advises LyX to remove the auxiliary files before doing the next export.
buffer-write-as-template is a convenience function to ease saving a document in the (personal) templates folder.
export-cancel is used to cancel background export processes.
font-nospellcheck marks the word under cursor or selection to the effect that the spellchecker ignores it.
ifrelatives is a helper function to check whether a buffer has a master or children.
index-tag-all adds a copy of the index entry under cursor to after all occurrences of the word that precedes the index inset.
inset-insert-copy inserts the inset's content (in ToC pane) at the position of the cursor.
inset-split is a new convenience function that splits an inset into two at the given
cursor position. This is only implemented for text insets currently.
lyxfiles-open opens the new examples or templates dialog.
master-buffer-forall executes an lfun in the master and all children of a document.
paragraph-select is a new convenience function to select the paragraph surrounding the actual cursor position.
search-string-set [arg] stores the <arg>, the currently selected text or the word under
cursor in the search cache that is used by
word-find[-backward|-forward] if no argument
is given to those.
spelling-add-local adds words for a given language to the document's local spelling dictionary.
spelling-remove-local removes words for a given language from the document's local spelling dictionary.
tabular-style-insert inserts a table in a specified style.
tab-group-previous: Activate another tab group in split view. The new functions bound to F6/S-F6 in CUA bindings.
The following functions have been changed:
citation-insert now returns a list of undefined citations if passed through the LyX Server.
file-insert: optional second parameter
ignorelang to make the insertion
ignore the inserted file's main language (and rather adapt it to the insertion
set-graphics-group was renamed to
info-insert buffer vcs-* was renamed to
info-insert vcs *
The following functions have been removed:
date-insert: this function has been superseded
Full Release notes
The full Release notes can be found in lib/RELEASE-NOTES file.
The following persons contributed to LyX 2.4.0 development (alphabetical order):
* Kornel Benko
* Lorenzo Bertini
* Henry Chern
* Eugene Chornyi
* Jean-Pierre Chrétien
* Sam Crawley
* Thibaut Cuvelier
* Yuval Deutscher
* Patrick De Visschere
* Alexander Dunlap
* Enrico Forestieri
* Gilbert Forkel
* Isaac Oscar Gariano
* Richard Kimberly Heck
* Christopher Hillenbrand
* Winfred Huang
* Joice Joseph
* Scott Kostyshak
* Joel A. Kulesza
* Jean-Marc Lasgouttes
* José Matos
* Günter Milde
* Guillaume Munch
* Phillip Netro
* Isaac Oscar
* Benjamin Piwowarski
* Daniel Ramöller
* Pavel anda
* Yuriy Skalko
* Jürgen Spitzmüller
* Uwe Stöhr
* Niko Strijbol
* Sergei Winitzki
* Stephan Witt
* Jürgen Womser-Schütz
If you are missing your name in this list, please add.