inset.
If the reference is "sec:mysec", then this will output just "mysec".
This is what is needed, e.g., to use refstyle's range commands, e.g.,
\secrangeref{mysec1}{mysec2}
You *cannot* use:
\secrangeref{sec:mysec1}{sec:mysec2}
even if those are the actual labels.
Eventually, I'd like to add native support for this, but I'm a bit
frightened of trying to make the reference dialog support multiple
selections.
This entails a change of getAbbrAuthor to getAuthorList (the default is
still abbreviated with respect to MaxCiteItems, but the list can be, at
explicit request, shortened or full notwithstanding MaxCiteItems.
Next to the cmd name, introduce optional latex names (that might differ
from the cmd name) and aliases (that are "obsoleted by" the cmd).
This enhances portability between the engines.
For biblatex, we need the file name as it was entered in the inset
(abs path, rel path, only file name) in order to resolve it properly
for the export (as in the BibTeX inset intself).
Therefore, we now store a pair<docstring, FileName>.
A FileNamePairList has been added to FileNameList for this purpose.
Fixes: #8831
This introduces
* a new inset member isPartOfTextSequence() that returns
whether the inset produces something visible at the current position
in the text flow
* an isOpenPunctuation() test that returns whether a character is in the
'Punctuation, Open' unicode class. This is used instead of just checking
for two (Western, ASCII) opening brackets
It also fixes the isChar() and isLetter() value of InsetSpecialChar,
since some types have not been assigned correctly.
* b `british' (``inner quotation'')
* w >>swedishg>> ('inner quotation') ["g" = Guillemets]
* f <<french>> (``inner quotation'')
* i <<frenchin>> (<<inner quotation>>) ["in" = Imprimerie Nationale]
* r <<russian>> (,,inner quotation``)
Rename "french" to "swiss"
Also rename "single/double" to "secondary/primary" ("inner/outer" in
the UI) and "left/right" to "opening/closing". Note that the inset
identifier string is left as is ("s/d" and "l/r")
The current char-based implementation gets increasingly unreadable,
especially if styles are added that do not follow the strict
single-double paradigm.
A dot in the <lang><side><times> string means: keep current value.
This expert feature allows to change arbitrary quote features in one step.
E.g.,
inset-forall Quotes inset-modify changetype f..
=> change all quote insets to French style, maintaining current side
and times setting
inset-forall Quotes inset-modify changetype ..s
=> change all quote insets to single quotes, keeping style and times
inset-forall Quotes inset-modify changetype g.s
=> change all quote insets to German single quotes, keeping left/right
setting
Any idea where to document this?
All typographic quotation marks are supported, if the proper
LaTeX macros (as opposed to ligatures) are used.
So no need for forcing straight quotes.
This is in line with what babel-hebrew suggests.
* Adjoining closing Single + double quote becomes double + single quote
(for English, Swedish and German, LaTeX export as ''').
* French double quotes are converted to << >> in the LaTeX file and to
double inverted question/interrogation marks in the output, if the font
encoding is set to [None] or OT1 but the global default is T1. (test
for lyxrc.fontenc instead of the document-specific fontenc setting in
InsetQuotes.cpp).
* Quote type ignored for LyXHTML: always "English" quotes used.
See #10451
This helper method is used to set the inset dimension cache at metrics
time. However this is already done by the metrics code itself
(MathRow::metrics, TextMetrics::redoParagraph), so that there is no
need to do this same work again in a different place.
Also, InsetPhantom::metrics is removed, since it does not do anything
interesting.
This commit comes with a mild risk attached (it might be that some of
these calls were useful after all!), but all of this is fixable.
This helper method is used to set the inset position cache at drawing
time. However this is already done by the drawing code itself
(MathRow::draw, RowPainter::paintInset), so that there is no need to
do this same work again in a different place.
Note that the inset positions are still set in InsetTabular::draw for
each cell.
This commit comes with a mild risk attached (it might be that some of
these calls were useful after all!), but all of this is fixable.
Up to now Inset::dimension was either a helper function to access
CoordCache, or... something else. This created problems to properly
use it.
In particular, the definition of InsetText::dimension created problems
for child classes. Removing this definition (actually renaming it to
dimensionHelper) allows to streamline the code.
Addressing #10481.
This patch adds the new 'needauth' option for converters launching
external programs that are capable of running arbitrary code on behalf
of the user. These converters won't be run unless the user gives explicit
authorization, which is asked on-demand when the converter is about to
be run (question is not asked if the file is cached and calling the
converter is not needed).
The user prompt has a 3rd button so that he/she's not prompted again
for (any converter over) the same document (identified through
buffer->absFileName()).
Two preference options are added:
lyxrc.use_converter_needauth_forbidden disables any converter with
the 'needauth' option, which is meant to force user to an explicit
action via the preferences pane, before being able to use advanced
converters that can potentially bring security threats;
lyxrc.use_converter_needauth enables prompting the user for 'needauth'
converters, or bypasses the check if not enabled, falling back to the
previous behavior.
So, the first option is for maximum security, the second is for
maximum usability.
In fact having an extra parameter "bool cond" is no longer useful because it can
now always be emulated with a ternary operator:
Changers dummy = cond ? do_change() : Changer();
texstring is a pair of a docstring and a corresponding TexRow. The row count in
the TexRow has to match the number of lines in the docstring.
otexstringstream is an output string stream that can be used to create
texstrings (i.e. it's an odocstringstream that records the TexRow information
and let us extract a texstring from it).
texstrings can be passed around and output to otexstream and otexrowstream,
which produces an accurate TexRow information by concatenating TexRows.
As noted in the log, this commit was a bit radical and needs some
adjustments (which was expected, actually).
Let InsetText do their own background drawing.
Fixes bug #10359.
Before, it could have been the case that
lyx -e pdf2 file.lyx
had exit code 0 even though file.lyx includes a file that exits with
error. If compiled in the GUI a warning was given, but from the
command line exit code it would seem there was no problem. The exit
code for this case is now non-zero and the word "Warning" is now
removed from the message because it should be treated as an error.
An exception is thrown from InsetInclude and is caught in
Buffer::makeLaTeXFile() and added to the error list.
The (similar) use case at #8840 is also fixed by this commit.
Now by default all insets paint their own background when needed. This
means that 63cf3297 and part of 9940acc5 can be reverted.
To avoid extra painting, background drawing is disabled for
InsetCommand and InsetCollapsable. These insets draw background as
part of their normal drawing activity.
This will avoid drawing artifacts with InsetNewpage, InsetVSpace and
probably some others.