Commit Graph

639 Commits

Author SHA1 Message Date
Jean-Marc Lasgouttes
3f5b836aa9 Make some code that handle authors more readable
Create accssors authodmap() in BufferParams.

Use [] operator instead of find().

Hopefully this will avoid to confuse Coverity scan.
2024-09-10 15:32:49 +02:00
Scott Kostyshak
7fb059bce4 Whitespace 2024-09-10 14:23:37 +02:00
Jürgen Spitzmüller
498135ef38 Do not push options to \babelprovide which do not make sense there
Should fix a couple of tests
2024-09-10 13:58:33 +02:00
Juergen Spitzmueller
b1b8ded15d output babel options via \babelprovide in all cases needed 2024-08-26 07:20:58 +02:00
Juergen Spitzmueller
686b55e70d Amend fc605cf138
Use proper option if main and a secondary language have BabelProvide 2
2024-08-25 18:01:26 +02:00
Juergen Spitzmueller
17ca2ac89c Properly set the babel bidi option (#12862) 2024-08-25 15:21:56 +02:00
Juergen Spitzmueller
fc605cf138 Add proper support for BabelProvide 2
We need to instruct babel not to load an existing ldf in this case
2024-08-25 14:56:05 +02:00
Juergen Spitzmueller
66aa0d8699 Avoid empty option in babelCall 2024-08-25 13:23:57 +02:00
Juergen Spitzmueller
047dee5a3b Basic support for \babelprovide
This is the new(er) babel mechanism to load languages via babel *.ini
files.

Some languages (or varieties) are only supported this way, some work
better with unicode engines this way (for the latter case, we have
BabelProvide 2)
2024-08-25 09:46:29 +02:00
Juergen Spitzmueller
7e09f574ba Add BabelOpts to languages
This way, some settings that were hardcoded in BabelPreamble are
customizable in document settings
2024-08-24 14:30:37 +02:00
Juergen Spitzmueller
8ff3e467a1 Avoid duplicate option passing with babel 2024-08-24 05:54:54 +02:00
Juergen Spitzmueller
3c852439a6 Fix language options glitches 2024-08-23 16:46:30 +02:00
Juergen Spitzmueller
2889e98d01 Amend 7e49ae7b13 2024-08-23 16:06:50 +02:00
Juergen Spitzmueller
7e49ae7b13 Add support for language options (#8034)
File format change.

Note that this cannot be properly reverted to LyX 2.4, so any options
will simply vanish on reversion or roundtrip
2024-08-23 15:52:34 +02:00
Juergen Spitzmueller
0ca600b93b \use_nomentbl -> \nomencl_opts
This allows for support of more options

As the param is only a few hours old, no lyx2lyx handling is needed
2024-08-22 05:35:47 +02:00
Juergen Spitzmueller
13ee0bc8cd Add support for the nomentbl nomenclature option
file format change
2024-08-21 17:39:36 +02:00
Juergen Spitzmueller
5c3b788999 amend d4f58c96b5
avoid having to validate the whole buffer just for this information
2024-07-27 13:34:38 +02:00
Juergen Spitzmueller
ca4fc01847 Load geometry after graphics
Newer graphics driver overwrite some (output) page settings otherwise
See https://tex.stackexchange.com/a/384952/19291

Re-fixes #10970
2024-07-27 12:46:12 +02:00
Juergen Spitzmueller
d4f58c96b5 Add support for multiple indexes in Memoir
As with almost everything, this class bakes its own cake also with
multiple indexes. So we need to account for this to produce
compilable output.

Not very nice, but there you go!
2024-07-26 12:48:12 +02:00
Juergen Spitzmueller
55d60ee24f Rename function 2024-07-14 09:42:36 +02:00
Juergen Spitzmueller
25dd2e29b7 Fix non-biblatex style checks 2024-07-14 09:39:54 +02:00
Juergen Spitzmueller
08c0377f0c consider style-specifics for citation alias 2024-07-13 17:21:27 +02:00
Juergen Spitzmueller
6603c5362f Provide reversed style specifier for citation commands
This lets you exclude given variants for specific citation styles only
2024-07-13 17:20:29 +02:00
Juergen Spitzmueller
8941b05774 Add support for biblatex-chicago (#12240)
File format change
2024-07-09 15:18:06 +02:00
Udi-Fogiel
51453c61d6 avoid adding redundant preamble to double column hebrew documents (#12919) 2024-06-03 21:06:10 +03:00
Scott Kostyshak
2e227cceaf Whitespace 2024-06-02 22:52:18 -04:00
Juergen Spitzmueller
2a7ec054be Support half und full line parskip class options (#12946)
Currently only employed by the KOMA classes.

Layout format change.
2024-06-02 11:41:54 +02:00
Juergen Spitzmueller
d2db74f9ee Add support for glue length in parskip (#12867) 2024-06-01 13:47:39 +02:00
Jean-Marc Lasgouttes
2660df9b99 Move Lexer to support/ directory (and lyx::support namespace)
This requires quite a bit of trivial code shuffling.
2024-04-28 12:23:13 +02:00
Juergen Spitzmueller
07c99393be Consider PackageOptions with parskip 2023-10-30 12:54:29 +01:00
Juergen Spitzmueller
6c5dc39cd5 Amend 9de9ec1e88
When setting halfline parskip with parskip provided, we still need
to set this explicitly, as we don't know the current \parskip value.

Also improve code readability.
2023-10-30 12:17:14 +01:00
Juergen Spitzmueller
9de9ec1e88 Do not add empty \parskip definition (reported in #12946) 2023-10-30 09:22:14 +01:00
Juergen Spitzmueller
04bfbc0f7a Limit RTL hack to classic engines (#12919)
It breaks with LuaTeX, is definitely not needed with XeTeX, and it is
doubted whether it is needed at all (but this needs further testing).
2023-09-30 17:00:51 +02:00
Pavel Sanda
6141b437b1 pdfcolmk is an empty stub for many years now (bug #12920).
Patch from Udi.
2023-09-28 00:36:35 +02:00
Richard Kimberly Heck
2ad57dcb6b Preview formatted references in the work area.
Patch from Daniel Ramoeller <d.lyx@web.de>, fixed up by RKH.
2023-08-24 21:24:31 -04:00
Juergen Spitzmueller
315c2f132a Account for babel's bidi option (#12866)
bidi=bidi-{r,l} load the bidi package
2023-08-17 14:25:33 +02:00
Udi Fogiel
9f29fb33d1 prioretize-user-font-options 2023-08-11 11:13:24 +02:00
Pavel Sanda
9e8901f997 Adding hebrew quotation marks (bug #12849).
Patch from Udi Fogiel.
2023-08-06 16:50:07 +02:00
Pavel Sanda
32209c9845 Typo in metadata glyphs check.
So I belive, but someone please double check.
2023-04-13 21:55:57 +02:00
Juergen Spitzmueller
da1d6d03eb Amend 2987530434
This is more readable (and fixes a thinko)
2023-02-18 17:04:43 +01:00
Juergen Spitzmueller
2987530434 Address an edge case where we need to loaf fontspec also with babel 2023-02-18 16:12:49 +01:00
Juergen Spitzmueller
2e6ea5f613 Extend flexible version check to packages 2022-12-19 17:42:27 +01:00
Juergen Spitzmueller
029adfa28c Improve LaTeX version checking
Instead of having to add and individually test the versions to check
for, we store the current version and test on that with a specific
function isAvailableAtLeastFrom(package, year, month, day)

Currently only used for the LaTeX version, but could also be extended
for package versions.
2022-12-19 15:15:41 +01:00
Juergen Spitzmueller
41146030b6 Simplify output code 2022-12-19 11:09:50 +01:00
Juergen Spitzmueller
0c6d0a86b9 Remove unnecessary conversion 2022-12-19 10:55:28 +01:00
Juergen Spitzmueller
c2a324e242 Amend 9716e79624
If the main language does not require the inputenc package, but a
secondary language does, inputenc needs to be loaded as well
(without options)

Also simplify the code a bit.
2022-12-19 08:00:06 +01:00
Juergen Spitzmueller
9716e79624 inputenc only expects one option
File switches with documents are done via \inputencoding.
Other than with fontenc, these do not need to be laoded via options
beforehand.

Also, out current code loaded the additional languages' encoding last,
which might result in wrong encoding settings.
2022-12-17 15:14:47 +01:00
Richard Kimberly Heck
5db9e91f16 Fix bug #11781. Patch from Daniel. 2022-11-27 13:20:17 -05:00
Jean-Marc Lasgouttes
90ea508111 Fix pasting as LaTeX in documents with no modules
When there is no module, the old code would invoke tex2lyx with option
 -m
instead of
 -m ""
and an error would ensue.

This is because the QProcess command line parser used in Systemcall is
broken and does not recognize empty parameters as such. The solution
is to rewrite our parsecmd() parser to generate a list of parameters.
This is post-2.4.0 work.

The workaround used here is:

- set the list of modules to "," when it should be empty. In effect,
  this is a list of two empty modules.

- change tex2lyx to accept empty module names and ignore them; this is
  good in terms of robustness anyway.

Additionally, when there is no receiving buffer, set the defaults as
the BufferParams defaults instead of empty (this is cleaner, but
should not make a difference in practice).

In the long term, we should switch to use the QStringList-based API of
QProcess in Systemcall (see QTBUG-80640).
2022-11-06 13:20:02 +01:00
Jean-Marc Lasgouttes
fff28c5756 Always qualify calls to std::move()
This quashes a new warning in clang++ 15, when std::move() (the
one-parameter version) is used as simply move(). There is a strong
recommendation from WG21 to avoid that.

Details here: https://reviews.llvm.org/D119670

It might be that we should not use that many move()s. I am not
competent to decide on that.

I also used this occasion to get rid of a spacial casing for C++11
that does not seem necessary after all.
2022-10-21 14:11:36 +02:00