]> git.lyx.org Git - lyx.git/log
lyx.git
46 hours agoDocument NeedCProtect -1 InsetLayout option 2.4.1-devel
Juergen Spitzmueller [Wed, 15 May 2024 11:58:28 +0000 (13:58 +0200)]
Document NeedCProtect -1 InsetLayout option

47 hours agoAmend a716fb96b53447
Juergen Spitzmueller [Tue, 14 May 2024 11:54:00 +0000 (13:54 +0200)]
Amend a716fb96b53447

(cherry picked from commit af59551b1b0c7d7e95c70ae4db156cba7ac0cefe)

47 hours agoNeedCProtect -1 also for InsetLayouts
Juergen Spitzmueller [Tue, 14 May 2024 11:37:29 +0000 (13:37 +0200)]
NeedCProtect -1 also for InsetLayouts

(cherry picked from commit a716fb96b534475759799b195a7edaeb049fbcf6)

47 hours agoDocument NeedCProtect -1
Juergen Spitzmueller [Mon, 13 May 2024 04:53:19 +0000 (06:53 +0200)]
Document NeedCProtect -1

(cherry picked from commit ea004cdb28e9b440347a9487d127e55765940c79)

47 hours agoAmend 207eaeee9071cb
Juergen Spitzmueller [Sun, 12 May 2024 06:52:09 +0000 (08:52 +0200)]
Amend 207eaeee9071cb

FragileFrame, as opposed to normal frame, supports cprotect (and needs
it in the usual circumstances)

(cherry picked from commit eeb3f9e719d15c4117a510e8a214d1c1b2c5a33c)
(cherry picked from commit 50cd148bd260222e30b6e429d135c45f8c2f1f14)

47 hours agoIntroduce NeedCProtect -1 layout option
Juergen Spitzmueller [Sun, 12 May 2024 05:52:16 +0000 (07:52 +0200)]
Introduce NeedCProtect -1 layout option

It turns out beamer frame does not allow \cprotect and errors if it is
used. Hence we need to prevent it in this context entirely.

(cherry picked from commit 207eaeee9071cb828a2ab7f4680f8ff92e379af8)
(cherry picked from commit f05fd787548e8b3082051b7d45bb4119f97a55dc)

5 days agoStatus
Richard Kimberly Heck [Sat, 11 May 2024 17:03:54 +0000 (13:03 -0400)]
Status

5 days agoConsider CT in dash mechanism (#13062)
Juergen Spitzmueller [Sat, 11 May 2024 11:07:32 +0000 (13:07 +0200)]
Consider CT in dash mechanism (#13062)

(cherry picked from commit fe4f0dbf0b37c413994bbfa780a833b1c041a433)

3 weeks agoSet buffer_ correctly when inseting a math macro over a selection
Jean-Marc Lasgouttes [Thu, 25 Apr 2024 12:28:10 +0000 (14:28 +0200)]
Set buffer_ correctly when inseting a math macro over a selection

The code that handles this special macro insertion (in
Cursor::mathMacroClose())) is very weird: it inserts the contents of
the macro _after_ the macro and later, since the macro is 'greedy', it
will eat this contents and put it in its first macro cell.

Does it make sense to you? It does not ake sense to me either. Anyway,
this is the point where one should make sure that the buffer is set.

Fixes ticket #12682.

(cherry picked from commit b45a957929a78cefc729a0fa984214eb83357d42)

3 weeks agoSanitize cursors after a buffer has been reloaded
Jean-Marc Lasgouttes [Tue, 16 Apr 2024 09:45:09 +0000 (11:45 +0200)]
Sanitize cursors after a buffer has been reloaded

When a buffer is reloaded, its content may remain the same, but the
memory allocation is new, so that the inset pointers in cursors are
now wrong. This requires to sanitize the cursors held by the buffer
views.

Before the biginset branch, some full metrics computation call that is
now removed probably did that as a side effect. Now we have to be more
precise.

To this effect, introduce WorkAreaManager::sanitizeCursors() and use
it in Buffer::reload().

(cherry picked from commit c1fd622c51752d790576600f5911813ff8dac3fa)

3 weeks agoDocument biginset branch
Jean-Marc Lasgouttes [Sun, 21 Apr 2024 20:26:41 +0000 (22:26 +0200)]
Document biginset branch

3 weeks agoStatus
Richard Kimberly Heck [Sun, 21 Apr 2024 19:56:00 +0000 (15:56 -0400)]
Status

3 weeks agoStatus update
Juergen Spitzmueller [Sun, 21 Apr 2024 07:34:35 +0000 (09:34 +0200)]
Status update

3 weeks agogbrief-2 loads babel internally. So don't load it ourselves.
Juergen Spitzmueller [Sat, 13 Apr 2024 05:32:30 +0000 (07:32 +0200)]
gbrief-2 loads babel internally. So don't load it ourselves.

This makes the class fully functional with non-TeX fonts (it uses
\babelfont for the purpose). Before, docs were compiling but the
output was wrong.

(cherry picked from commit c3c96a446b32ef77927b5e06436c2668d95dfd6d)

3 weeks agog-brief loads babel internally. So don't load it ourselves.
Juergen Spitzmueller [Tue, 16 Apr 2024 16:23:01 +0000 (18:23 +0200)]
g-brief loads babel internally. So don't load it ourselves.

This makes the class fully functional with non-TeX fonts (it uses
\babelfont for the purpose). Before, docs were compiling but the
output was wrong.

3 weeks agoCmake install: Forgotten to install tabletemplates.
Kornel Benko [Sat, 20 Apr 2024 17:33:25 +0000 (19:33 +0200)]
Cmake install: Forgotten to install tabletemplates.

(cherry picked from commit d05e295ddc22c65183a203e97240898a055d2d12)

4 weeks agoAlways repaint the gray area below main inset
Jean-Marc Lasgouttes [Tue, 16 Apr 2024 21:55:24 +0000 (23:55 +0200)]
Always repaint the gray area below main inset

Now that SingleParUpdate does not always lead to a full screen update
when the height of the paragraph changes (see new behavior of
updateMatrics(bool)), it is necessary to make sure that the grey area
below the main page is always repainted.

(cherry picked from commit 1a11abe4394272f521cd63993e426c136e0e9b6c)

4 weeks agoDo not compute metrics at each preview when loading file
Jean-Marc Lasgouttes [Thu, 21 Dec 2023 15:33:06 +0000 (16:33 +0100)]
Do not compute metrics at each preview when loading file

With the branch-test.lyx file from #12297, loading takes forever when
previews are activated. This is because each preview element causes a
full screen metrics recomputation.

This commit just skips these calls and only does one when all previews
have been obtained. As a result, computing the previews takes 1 second
instead of 25 seconds on branch-test.lyx.

Part of bug #12297.

(cherry picked from commit 244969330108a89f4be93d3b2eb9024bdb756204)

4 weeks agoImprove the code that limits scrolling at top/bottom
Jean-Marc Lasgouttes [Fri, 17 Nov 2023 17:30:37 +0000 (18:30 +0100)]
Improve the code that limits scrolling at top/bottom

The most visible part of this commit is the move of part of
BufferView::updateMetrics to a new TextMetrics::updateMetrics. This
new method makes sure that metrics are known for all visible paragraphs
(starting from anchor), and that the positions of the paragraphs have
been recorded.

This method is called up to 3 times in BufferView::updateMetrics:
* unconditionally, to update all visible metrics,
* then, if the bottom of the document is visible and too high, after
  updating the anchor ypos,
* and similarly if the top of the document is visible and too low.

This fixes for example the case where one jumps to Section 5.3 at the
end of Tutorial and 'scroll_below_document' is false.

Some now redundant code is removed from BufferView::scrollToCursor.

The anchor-setting code in BufferView::draw is not clearly useful, but
left here just in case. It generates a debug warning, though.

Part of bug #12297.

(cherry picked from commit f15d2ebf3819913114ab93d1ff7e140cb26b03d5)

4 weeks agoImplement quick scroll
Jean-Marc Lasgouttes [Mon, 24 Jul 2023 21:23:40 +0000 (23:23 +0200)]
Implement quick scroll

Replace flag parameter for updateMetrics() by a `force' boolean. When
it is false, the method keeps the metrics of paragraphs that are still
visible in WorkArea instead of computing everything afresh. All it has
to do is update their positions.

Add code to updateMetrics() to update the value of the anchor pit/ypos
(similar to the one in draw()).

Update processUpdateFlags() to use this when update flag is ForceDraw.

Modify scrollDocView() to just change the anchor paragraph position
when the scrolling operation would re-use some of the existing
paragraphs.

The time needed to update the metrics when scrolling with mouse in the
branch-test.lyx document is now divided by 20!

Part of bug #12297.

(cherry picked from commit 08010c6a5e425b3f2d0d625536e3a571c90a0482)

4 weeks agoIntroduce new helpers ParagraphMetrics::top/bottom
Jean-Marc Lasgouttes [Tue, 25 Jul 2023 14:31:13 +0000 (16:31 +0200)]
Introduce new helpers ParagraphMetrics::top/bottom

This avoids code with position/ascent/descent that is difficult to follow.

No change in function intended.

(cherry picked from commit 0b6105b9245350e428c73deee88af2cd7c0d4732)

4 weeks agoIn the no-draw phase, do not cache the positions of not visible insets
Jean-Marc Lasgouttes [Mon, 24 Jul 2023 15:53:16 +0000 (17:53 +0200)]
In the no-draw phase, do not cache the positions of not visible insets

This can make a big difference for a very large branch that contains
lots of equations.

This is complementary to the previous patch, since instead of reducing
the number of calls to updatePosCache, we make it faster.

In the same test of scrolling with mouse wheel through the
branch-test.lyx document, one finds a 23% improvement for
BufferView::updateMetrics().

Part of bug #12297.

(cherry picked from commit 7f85024f80601b15634fb5e771bba51435ad429f)

4 weeks agoRemove some redundant calls to updatePosCache
Jean-Marc Lasgouttes [Mon, 24 Jul 2023 13:35:16 +0000 (15:35 +0200)]
Remove some redundant calls to updatePosCache

The setting of insets positions was done twice in updateMetrics.
When one of the paragraph is a huge branch, this can be very expensive.

This leads to a 17% improvement on updateMetrics time on a scrolling test.

Part of bug #12297

(cherry picked from commit d19ade9a611d3ecf6840c5eb43291cb268ad6f4f)

4 weeks agoEnable Update::SinglePar in nested insets too
Jean-Marc Lasgouttes [Mon, 17 Jul 2023 12:43:29 +0000 (14:43 +0200)]
Enable Update::SinglePar in nested insets too

The idea of single par update is to try to re-break only the paragraph
containing the cursor (if this paragraph contains insets etc.,
re-breaking will recursively descend).

The existing single paragraph update mechanism was tailored to work
only at top level. Indeed changing a paragraph nested into an inset may
lead to larger changes.

This commit tries a rather naive approach that seems to work well: we
need a full redraw if either

1/ the height has changed
or
2/ the width has changed and it was equal to the text metrics width;
   the goal is to catch the case of a one-row inset that grows with
   its contents, but optimize the case of typing in a short paragraph
   part of a larger inset.

NOTE: if only the height has changed, then it should be
  possible to update all metrics at minimal cost. However,
  since this is risky, we do not try that right now.

Part of bug #12297.

(cherry picked from commit 9a96726bcd06d565c3027011fea954656aa46668)

4 weeks agoDefer construction of temporary cursor.
Richard Kimberly Heck [Tue, 16 Apr 2024 16:15:50 +0000 (12:15 -0400)]
Defer construction of temporary cursor.

We were doing this on every mouse movement. I.e., for every single
pixel the mouse traverses. It can be expensive if there are a lot
of math insets.

(cherry picked from commit 4e8aa89eb96cd73e6630deea6fd6b9d3039aab6c)

4 weeks agoDisable language package choice if the class preloads a package
Juergen Spitzmueller [Sat, 13 Apr 2024 08:07:18 +0000 (10:07 +0200)]
Disable language package choice if the class preloads a package

(cherry picked from commit 5477451e36cd9ff4e99aefea2627fbf63e028004)

4 weeks agoSet cursor font after pasting to PassThru inset (#12592)
Juergen Spitzmueller [Sat, 13 Apr 2024 09:36:10 +0000 (11:36 +0200)]
Set cursor font after pasting to PassThru inset (#12592)

(cherry picked from commit 09c72d7c8d3341ecc7ae2307b4355c592d9dcc1b)

4 weeks agoDocument 76dbb9dc4
Juergen Spitzmueller [Sat, 13 Apr 2024 05:16:21 +0000 (07:16 +0200)]
Document 76dbb9dc4

4 weeks agoFix wrong position of conversion windows of the input method #11723, #13054
Koji Yokota [Fri, 29 Mar 2024 13:09:36 +0000 (22:09 +0900)]
Fix wrong position of conversion windows of the input method #11723, #13054

5 weeks agoDocument 0d3d91c0551
Juergen Spitzmueller [Sat, 6 Apr 2024 07:58:31 +0000 (09:58 +0200)]
Document 0d3d91c0551

(cherry picked from commit 012c739668700d1e02109a3bee6d116bb45cf912)

5 weeks ago* status.24x
Pavel Sanda [Fri, 5 Apr 2024 21:15:53 +0000 (23:15 +0200)]
* status.24x

5 weeks agoImprove stats update times for buffer switches and toolbar toggles.
Pavel Sanda [Fri, 5 Apr 2024 20:59:07 +0000 (22:59 +0200)]
Improve stats update times for buffer switches and toolbar toggles.

5 weeks ago* status.24x
Pavel Sanda [Fri, 5 Apr 2024 17:45:09 +0000 (19:45 +0200)]
* status.24x

5 weeks agoAllow relative statistics values in statusbar.
Pavel Sanda [Fri, 5 Apr 2024 17:34:29 +0000 (19:34 +0200)]
Allow relative statistics values in statusbar.

https://www.mail-archive.com/lyx-devel@lists.lyx.org/msg221311.html

6 weeks agoUpdate sk.po
Kornel Benko [Wed, 3 Apr 2024 11:08:36 +0000 (13:08 +0200)]
Update sk.po

6 weeks agoAdd status file
Juergen Spitzmueller [Wed, 3 Apr 2024 07:35:12 +0000 (09:35 +0200)]
Add status file

6 weeks agode.po
Juergen Spitzmueller [Wed, 3 Apr 2024 07:19:14 +0000 (09:19 +0200)]
de.po

6 weeks agoDissolve some shortcut conflicts in the wake of f3a4602c4c1ec
Juergen Spitzmueller [Wed, 3 Apr 2024 06:28:00 +0000 (08:28 +0200)]
Dissolve some shortcut conflicts in the wake of f3a4602c4c1ec

(cherry picked from commit 728175f9acdd8b67249d5403d99319557201f80c)

6 weeks agoSmarter menu length calculation
Juergen Spitzmueller [Tue, 2 Apr 2024 12:41:54 +0000 (14:41 +0200)]
Smarter menu length calculation

It is possible I have missed some shortcut conflicts, so please report
if you find any.

(cherry picked from commit f3a4602c4c1eca9bc79e7ba0b58395b79eafe9db)

6 weeks agoUpdate German User Guide
Juergen Spitzmueller [Wed, 3 Apr 2024 05:40:56 +0000 (07:40 +0200)]
Update German User Guide

6 weeks agode/UserGuide: update
Juergen Spitzmueller [Tue, 2 Apr 2024 07:32:02 +0000 (09:32 +0200)]
de/UserGuide: update

6 weeks agoIgnore all build* directories
Richard Kimberly Heck [Wed, 3 Apr 2024 02:03:53 +0000 (22:03 -0400)]
Ignore all build* directories

6 weeks agoDocs for menu change
Richard Kimberly Heck [Wed, 3 Apr 2024 02:02:55 +0000 (22:02 -0400)]
Docs for menu change

6 weeks agoCmake build: Adapt for branch 2.4
Kornel Benko [Tue, 2 Apr 2024 08:46:20 +0000 (10:46 +0200)]
Cmake build: Adapt for branch 2.4

(cherry picked from commit b8b9e8ec1402341229aade4b4a975b54c3ef80c9)

6 weeks agocmake build with qt6 (macos) did not include "plugins"
P. De Visschere [Sun, 31 Dec 2023 14:30:12 +0000 (15:30 +0100)]
cmake build with qt6 (macos) did not include "plugins"

(cherry picked from commit 4d02fb7ad7a846bebfd8ba5fd37a5453482e768d)

6 weeks agoCmake build: Handle deprecated cmake versions
Kornel Benko [Sun, 31 Dec 2023 14:18:11 +0000 (15:18 +0100)]
Cmake build: Handle deprecated cmake versions

The warning says:
CMake Deprecation Warning at .../CMakeLists.txt:1 (cmake_minimum_required):
  Compatibility with CMake < 3.5 will be removed from a future version of
  CMake.

Spotted by Scott Kostyshak

(cherry picked from commit 8d79860ea76da4d9c0b87fce86526da15b686ab9)

6 weeks agoFindAdv: no paragraph indentation for more space in the search string
Daniel Ramoeller [Sun, 31 Dec 2023 13:36:01 +0000 (14:36 +0100)]
FindAdv: no paragraph indentation for more space in the search string

See #11555

(cherry picked from commit 638c04dd6aab3e16063a03183e25491f83780b68)

6 weeks agoFindAdv: Handle neg-spaces like normal space if searching without format
Kornel Benko [Sun, 31 Dec 2023 13:27:40 +0000 (14:27 +0100)]
FindAdv: Handle neg-spaces like normal space if searching without format

(cherry picked from commit 07cacef398d6d748e30d70fa6f06821e82ac4e4e)

6 weeks agoRename hasToString() to findUsesToString()
Kornel Benko [Sun, 31 Dec 2023 13:09:17 +0000 (14:09 +0100)]
Rename hasToString() to findUsesToString()

There are special cases where the toString() exist,
but still plaintext() is not to be used by find.

(cherry picked from commit 8de81e8dc1cf344a9a245868aaff2c31dd0c9ce4)

6 weeks agoUpdate sk.po
Kornel Benko [Tue, 2 Apr 2024 09:35:56 +0000 (11:35 +0200)]
Update sk.po

6 weeks agode.po
Juergen Spitzmueller [Tue, 2 Apr 2024 07:15:03 +0000 (09:15 +0200)]
de.po

6 weeks agoFix duplicate accelerator
Richard Kimberly Heck [Tue, 2 Apr 2024 01:54:44 +0000 (21:54 -0400)]
Fix duplicate accelerator

6 weeks agoAdd shortcut for plain single quote.
Richard Kimberly Heck [Mon, 1 Apr 2024 21:26:29 +0000 (17:26 -0400)]
Add shortcut for plain single quote.

6 weeks agoClarify quote-insert LFUN.
Richard Kimberly Heck [Mon, 1 Apr 2024 21:26:01 +0000 (17:26 -0400)]
Clarify quote-insert LFUN.

And add remark about multiple optional arguments.

6 weeks agoFix bug #13025.
Richard Kimberly Heck [Mon, 1 Apr 2024 21:25:40 +0000 (17:25 -0400)]
Fix bug #13025.

Add plain single quote to menu.

6 weeks agoMark 2.4.1 development branch
Richard Kimberly Heck [Mon, 1 Apr 2024 20:20:55 +0000 (16:20 -0400)]
Mark 2.4.1 development branch

6 weeks agoFix context menu of InsetMathRef
Juergen Spitzmueller [Mon, 1 Apr 2024 15:59:56 +0000 (17:59 +0200)]
Fix context menu of InsetMathRef

6 weeks agoFix backslash LaTeXifying in InsetCommand
Juergen Spitzmueller [Mon, 1 Apr 2024 08:57:27 +0000 (10:57 +0200)]
Fix backslash LaTeXifying in InsetCommand

\ was transformed very early to \textbackslash{}, but then the following
routines escaped braces in the string, so we wrongly ended up in
\textbackslash\{\} and "\{} in the output

6 weeks agoFactor out shared method
Juergen Spitzmueller [Sun, 31 Mar 2024 10:40:27 +0000 (12:40 +0200)]
Factor out shared method

Amends babb5b007bd

6 weeks ago Restore Chapter 11
jpc [Sat, 30 Mar 2024 16:38:18 +0000 (17:38 +0100)]
       Restore Chapter 11

6 weeks agoFix crash with quick search starting with mathed selection
Juergen Spitzmueller [Sat, 30 Mar 2024 09:14:34 +0000 (10:14 +0100)]
Fix crash with quick search starting with mathed selection

setCursorSelection does not work with math. Copy the method from
spellchecker.

6 weeks ago Further translations of the French Additional manual
jpc [Fri, 29 Mar 2024 17:58:25 +0000 (18:58 +0100)]
   Further translations of the French Additional manual

7 weeks ago Further translations of French Additional manual + typo and ref. to Hebrew...
jpc [Thu, 28 Mar 2024 18:09:38 +0000 (19:09 +0100)]
  Further translations of French Additional manual + typo and ref. to Hebrew Letter in sec 3.5 of Additional.lyx

7 weeks agoDo not enter page break in heading (#13040)
Juergen Spitzmueller [Thu, 28 Mar 2024 17:03:54 +0000 (18:03 +0100)]
Do not enter page break in heading (#13040)

Rather than that, put it before or after, or disallow,
depending on the position.

7 weeks ago Further translations of French Additional manual
jpc [Thu, 28 Mar 2024 09:13:22 +0000 (10:13 +0100)]
  Further translations of French Additional manual

7 weeks ago Further translation of French Additional manual + typo in English version
jpc [Wed, 27 Mar 2024 17:38:28 +0000 (18:38 +0100)]
   Further translation of French Additional manual + typo in English version

7 weeks agoTypo in doc
Jean-Marc Lasgouttes [Mon, 25 Mar 2024 21:32:17 +0000 (22:32 +0100)]
Typo in doc

Thanks to Peter J. Puchyr for noticing it.

7 weeks agoFix alignment of screen font preview in prefs (remaining part of #13046)
Juergen Spitzmueller [Sun, 24 Mar 2024 08:00:41 +0000 (09:00 +0100)]
Fix alignment of screen font preview in prefs (remaining part of #13046)

7 weeks agoCmake build wit qt(5|6)(macos) did not include "plugins"
Patrick de Visschere [Sat, 23 Mar 2024 10:25:27 +0000 (11:25 +0100)]
Cmake build wit qt(5|6)(macos) did not include "plugins"

This makes things much simpler.

But at least with the latest macos tools (Sonoma and XCode15) a bundle
refuses to run if it 's not signed properly.

Both issues are solved with the patch included and have now been tested
with Qt5.15 and Qt6.7.

For completeness: I've checked the font-emph shortcut issue and, as
reported in the ticket mentioned, ^CmdE works with Qt5.15 but not with
Qt6.7. However the sequence ^C E does work. I don't know whether this is
intended as a workaround for this issue or was already implemented.

7 weeks agoFix display of a math hull inset in a tight inset
Jean-Marc Lasgouttes [Fri, 14 Jul 2023 00:13:18 +0000 (02:13 +0200)]
Fix display of a math hull inset in a tight inset

This is a kind of hack. This allows InsetMathHull to state that it
needs some elbow room beyond its width, in order to fit the numbering
and/or the left margin (with left alignment), which are outside of the
inset itself.

To this end, InsetMathHull::metrics() sets a value in
MetricsInfo::extrawidth and this value is added later to the width of
the row that contains the inset (when this row is tight or shorter
than the max allowed width).

Fixes bug #12320.

7 weeks agoRevert "Fix display of a math hull inset in a tight inset"
Jean-Marc Lasgouttes [Fri, 22 Mar 2024 14:08:26 +0000 (15:08 +0100)]
Revert "Fix display of a math hull inset in a tight inset"

This commit will be replaed by a better solution.

Part of ticket #12320.

This reverts commit 4bbd4a45e7494363903801540102150886fa2c6b.

8 weeks agofix documentation of --enable-cxx-mode
Jean-Marc Lasgouttes [Thu, 21 Mar 2024 21:50:38 +0000 (22:50 +0100)]
fix documentation of --enable-cxx-mode

8 weeks ago* cs.po
Pavel Sanda [Thu, 21 Mar 2024 21:47:31 +0000 (22:47 +0100)]
* cs.po

8 weeks agotypo
Jean-Marc Lasgouttes [Thu, 21 Mar 2024 21:40:19 +0000 (22:40 +0100)]
typo

8 weeks agoAmend 16660d12.
Thibaut Cuvelier [Thu, 21 Mar 2024 20:32:45 +0000 (21:32 +0100)]
Amend 16660d12.

The previous commit introduced wrong behaviours for <>. The new code carefully escapes what needs to be escaped from LaTeX, using the now-standard XML tools (XMLStream).

8 weeks agoMathML in HTML: don't escape <> for a raw LaTeX output.
Thibaut Cuvelier [Wed, 20 Mar 2024 23:29:23 +0000 (00:29 +0100)]
MathML in HTML: don't escape <> for a raw LaTeX output.

In some cases (I only found numbered equations), the LaTeX output still has a bit of HTML. For numbered equations, using \tag{X} (as suggested in https://www.lyx.org/trac/ticket/13048) would require fiddling with the output. KaTeX doesn't support \label. This patch is probably the easiest and most reliable fix.

Fixes https://www.lyx.org/trac/ticket/13048.

8 weeks agoUsing the latest commit and building lyx with cmake on macos-sonoma with
Patrick de Visschere [Wed, 20 Mar 2024 10:44:22 +0000 (11:44 +0100)]
Using the latest commit and building lyx with cmake on macos-sonoma with
xcode fails with multiple error messages like this one:

----------
CMake Error in po/CMakeLists.txt:
       The custom command generating

     <build-directory>/po/LyX2.4.cat.pot

       is attached to multiple targets:

     translations
     update-gmo

  but none of these is a common dependency of the other(s).  This is not
  allowed by the Xcode "new build system".

8 weeks agoAdd $$OrigAbsName placeholder to external
Jürgen Spitzmüller [Wed, 20 Mar 2024 06:57:43 +0000 (07:57 +0100)]
Add $$OrigAbsName placeholder to external

This produces the absolute path to the original file.

Documentation will follow in die time (after documentation has been
unfrozen)

8 weeks agoTableUI - allow expading of TableAlignCO (part of #13046).
Pavel Sanda [Tue, 19 Mar 2024 18:23:22 +0000 (19:23 +0100)]
TableUI - allow expading of TableAlignCO (part of #13046).

2 months agoUse docstring for preview snippet all the way down
Juergen Spitzmueller [Sat, 16 Mar 2024 10:55:17 +0000 (11:55 +0100)]
Use docstring for preview snippet all the way down

No need to convert back and forth

2 months agoMerge branch 'master' of git.lyx.org:lyx
Juergen Spitzmueller [Sat, 16 Mar 2024 04:03:16 +0000 (05:03 +0100)]
Merge branch 'master' of git.lyx.org:lyx

2 months agoSimplify b3fe9cb7049da
Juergen Spitzmueller [Sat, 16 Mar 2024 04:01:53 +0000 (05:01 +0100)]
Simplify b3fe9cb7049da

2 months agoMerge branch 'master' of git.lyx.org:lyx
Juergen Spitzmueller [Sat, 16 Mar 2024 03:59:08 +0000 (04:59 +0100)]
Merge branch 'master' of git.lyx.org:lyx

2 months agoPrevent iconv exception in previews (#13042)
Juergen Spitzmueller [Sat, 16 Mar 2024 03:52:51 +0000 (04:52 +0100)]
Prevent iconv exception in previews (#13042)

The preview loader assumes all content is in the main document encoding.

As soon as content was not encodable, LyX crashed. We now check for that
and if non-encodable glyphs are found, we do not produce a preview snippet
and warn.

Ideally, the preview loader should be made aware of encoding changes, or
we should generally use utf8 for previews.

2 months agoAdd Idan Pazi to contributors list
Juergen Spitzmueller [Tue, 12 Mar 2024 11:53:34 +0000 (12:53 +0100)]
Add Idan Pazi to contributors list

2 months agoFix returned value of win32file.ReadFile
Idan Pazi [Fri, 16 Feb 2024 13:17:17 +0000 (15:17 +0200)]
Fix returned value of win32file.ReadFile

returns an PyOVERLAPPEDReadBuffer that needs to be converted to str.

2 months agoMathML: don't let the processor stretch operators when they are single characters...
Thibaut Cuvelier [Mon, 11 Mar 2024 01:00:47 +0000 (02:00 +0100)]
MathML: don't let the processor stretch operators when they are single characters for LyX.

The main goal is to match TeX' behaviour. If you want stretchy operators, use InsetMathDelim / \left & \right. This patch will change the output in many files, but making the rendering much closer to that of TeX (which users should expect, due to LyX' roots in TeX).

2 months agoMathML: stop stretching all delimiters.
Thibaut Cuvelier [Mon, 11 Mar 2024 00:40:16 +0000 (01:40 +0100)]
MathML: stop stretching all delimiters.

No form? Reference: https://w3c.github.io/mathml-core/#dfn-form. The MathML processor is smart enough to determine whether the delimiter is prefix or postfix.

No stretchy/symmetric/fence in all cases? Reference: https://w3c.github.io/mathml-core/#algorithm-for-determining-the-properties-of-an-embellished-operator and https://w3c.github.io/mathml-core/#operator-dictionary-human (example entry: U+0028). Delimiters have the right properties by default.

2 months agoMathML: don't output delimiters in InsetMathBinom and
Thibaut Cuvelier [Mon, 11 Mar 2024 00:30:48 +0000 (01:30 +0100)]
MathML: don't output delimiters in InsetMathBinom and
 InsetMathDelim if the delimiter is a space.

2 months agoExtract vert, langle, rangle in MathExtern like parentheses and brackets.
Thibaut Cuvelier [Mon, 11 Mar 2024 00:22:12 +0000 (01:22 +0100)]
Extract vert, langle, rangle in MathExtern like parentheses and brackets.

This patch is part of a series that aims at solving https://www.lyx.org/trac/ticket/12891. It is an excerpt of the patch that lynx published at https://www.lyx.org/trac/ticket/12270.

2 months agoImprove const correctness.
Thibaut Cuvelier [Mon, 11 Mar 2024 00:15:48 +0000 (01:15 +0100)]
Improve const correctness.

2 months agoMemorise whether delims are extracted from MathExtern.
Thibaut Cuvelier [Mon, 11 Mar 2024 00:07:25 +0000 (01:07 +0100)]
Memorise whether delims are extracted from MathExtern.

This patch is part of a series that aims at solving https://www.lyx.org/trac/ticket/12891. It should not change any output.

2 months agoReduce code duplication.
Thibaut Cuvelier [Sun, 10 Mar 2024 15:55:12 +0000 (16:55 +0100)]
Reduce code duplication.

2 months agoAmend 04beccca: Group some entries in invertedTests
Kornel Benko [Sun, 10 Mar 2024 13:11:27 +0000 (14:11 +0100)]
Amend 04beccca: Group some entries in invertedTests

2 months agoMathML: consider ordinary and alphabetical characters as identifiers instead of opera...
Thibaut Cuvelier [Sat, 9 Mar 2024 19:59:12 +0000 (20:59 +0100)]
MathML: consider ordinary and alphabetical characters as identifiers instead of operators.

The goal is to consider all Greek letters as identifiers instead of operators.

Solves: https://www.lyx.org/trac/ticket/12948.

2 months agoSimplify a loop with a for-each.
Thibaut Cuvelier [Sat, 9 Mar 2024 19:46:54 +0000 (20:46 +0100)]
Simplify a loop with a for-each.

These loops were brought by C++11. The next step could be using std::any_of.

2 months agoDocBook: add missing mapping for AASTeX 6.3.
Thibaut Cuvelier [Sat, 9 Mar 2024 14:09:45 +0000 (15:09 +0100)]
DocBook: add missing mapping for AASTeX 6.3.

The result is far from perfect, see the TODOs. The corresponding tests are still inverted.

2 months agode/Additional: small adaptations
Juergen Spitzmueller [Fri, 8 Mar 2024 08:06:26 +0000 (09:06 +0100)]
de/Additional: small adaptations

2 months agoAdditional: Minor fix
Juergen Spitzmueller [Fri, 8 Mar 2024 08:05:57 +0000 (09:05 +0100)]
Additional: Minor fix

2 months agoUppdate sk.po
Kornel Benko [Thu, 7 Mar 2024 10:53:44 +0000 (11:53 +0100)]
Uppdate sk.po