Change "TextFont" to "Font". This fixes the following terminal
errors when opening the file:
LyX: Unknown InsetLayout tag [around line 247 of file
[layouts/jlreq-common.inc] current token: 'TextFont' context: '']
LyX: Unknown InsetLayout tag [around line 247 of file
[layouts/jlreq-common.inc] current token: 'Family' context: '']
LyX: Unknown InsetLayout tag [around line 248 of file
[layouts/jlreq-common.inc] current token: 'Typewriter' context: '']
LyX: Unknown InsetLayout tag [around line 249 of file
[layouts/jlreq-common.inc] current token: 'EndFont' context: '']
See the thread
2.4 Crash (was: Updated LaTeXConfig.lyx (bxjsclasses added))
on lyx-devel (26/01/2023).
The backtrace imply a problem like:
1/ metrics are computed for some info inset
2/ the info inset is regenerated (and thus the paragraph it held is now invalid)
3/ We draw the inset and because of the new (disabled by default)
bookmark display code, we access the id() of the invalid paragraph.
4/ boom!
To fix the issue, introduce a new boolean member that indicates when
the Row object of the metrics should not be used. In this case, the
draw() method returns early.
Typically there are two sources of spacing:
* the button has two pixels added to the left and to the right
* the frame around the text also has 2 pixels to the left and to the right
Note that this value of two pixels is given here for simplicity, but
these are parameterized by methods like textOffset or leftOffset.
What we want to remove is the space after the button and the space
before the frame. This is done in 3 places
In dimensionCollapsed(), the extra space is removed from the dimension
after its computation
In metrics(), the space avoided before the frame is removed from width.
In draw, the whome text inset is drawn with a negative offset.
Fixes#12335.
Remove acknowledgment theorem types
As we have learned, these shouldn't have been added from the get go.
Documents having it get a local layout definition.
This commit had had an additional not documented change: redraws
happen only when they are needed. This did not help fix the bug, but
looked smart on first sight. Alas, I find that these smart changes
added because "why not?" tend to come back to haunt me eventually.
In particular this case, the problem was that the code tested whether
the offset of anchor paragraph had changed, but not whether the
paragraph itself had changed. This means that, when switching from one
section to another with the outliner, the view was not updated.