\change_inserted -712698321 1723455730
EscapeChars
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455616
string
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455884
EscapeChars
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455884
string
+\change_unchanged
+
\end_layout
\end_inset
export if this parameter is 1,
as well as on screen.
Otherwise the document default font is used.
+\change_inserted -712698321 1723525171
+
+\end_layout
+
+\begin_layout Description
+
+\change_inserted -712698321 1723526674
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+
+\change_inserted -712698321 1723525171
+InsertCotext
+\end_layout
+
+\end_inset
+
+
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+
+\change_inserted -712698321 1723525183
+[
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+
+\change_inserted -712698321 1723525183
+0
+\end_layout
+
+\end_inset
+
+,
+\begin_inset space \thinspace{}
+\end_inset
+
+
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+
+\change_inserted -712698321 1723525183
+
+\emph on
+1
+\end_layout
+
+\end_inset
+
+]
+\end_layout
+
+\end_inset
+
+ If this is set to
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+
+\change_inserted -712698321 1723525171
+1
+\end_layout
+
+\end_inset
+
+,
+ a copy of the co-text (either selected text or the word preceding the cursor) is inserted as content on inset creation.
+\change_unchanged
+
\end_layout
\begin_layout Description
\change_inserted -712698321 1723455760
EscapeChars
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455760
string
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455760
%!@
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455760
!
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455760
@
+\change_unchanged
+
\end_layout
\end_inset
\change_inserted -712698321 1723455760
%
+\change_unchanged
+
\end_layout
\end_inset
\begin_inset Flex Code
status collapsed
+\begin_layout Plain Layout
+InsertCotext
+\end_layout
+
+\end_inset
+
+ [
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+
+\emph on
+0
+\end_layout
+
+\end_inset
+
+,
+\begin_inset space \thinspace{}
+\end_inset
+
+
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+1
+\end_layout
+
+\end_inset
+
+] Wenn dies auf
+\begin_inset Flex Code
+status collapsed
+
+\begin_layout Plain Layout
+1
+\end_layout
+
+\end_inset
+
+ gesetzt wird,
+ wird eine Kopie des umgebenden Texts (entweder der ausgewählte Text oder das Wort vor dem Cursor) bei der Erstellung als Inhalt eingefügt.
+\end_layout
+
+\begin_layout Description
+\begin_inset Flex Code
+status collapsed
+
\begin_layout Plain Layout
InToc
\end_layout
ForcePlain true
ContentAsLabel true
EscapeChars \"@|!
+ InsertCotext 1
End
InsetLayout IndexMacro:see
EscapeChars %!@|
EndArgument
EscapeChars %!@|
+ InsertCotext 1
End
InsetLayout Box
# New CiteEngine type "notes"
# Incremented to format 107, 12 August 2023 by spitz
-# New InsetLayout and Layout tags "EscapeChars"
+# New InsetLayout, Argument and Layout tags "EscapeChars"
+# New InsetLayout tag "InsertCotext"
# Do not forget to document format change in Customization
# Manual (section "Declaring a new text class").
bool gotsel = false;
bool move_layout = false;
- bool const copy_cotext = cmd.action() == LFUN_INDEX_INSERT
- || cmd.action() == LFUN_NOMENCL_INSERT;
+ bool const copy_cotext = inset->getLayout().insertCotext();
if (cur.selection()) {
if (copy_cotext)
copySelectionToTemp(cur);
// You should also run the development/tools/updatelayouts.py script,
// to update the format of all of our layout files.
//
-int const LAYOUT_FORMAT = 107; // spitz: EscapeChars
+int const LAYOUT_FORMAT = 107; // spitz: EscapeChars and InsertCotext
// Layout format for the current lyx file format. Controls which format is
IL_DOCBOOKRENDERASIMAGE,
IL_ESCAPE_CHARS,
IL_INHERITFONT,
+ IL_INSERTCOTEXT,
IL_INTOC,
IL_ISTOCCAPTION,
IL_LABELFONT,
{ "htmlstyle", IL_HTMLSTYLE },
{ "htmltag", IL_HTMLTAG },
{ "inheritfont", IL_INHERITFONT },
+ { "insertcotext", IL_INSERTCOTEXT },
{ "intoc", IL_INTOC },
{ "istoccaption", IL_ISTOCCAPTION },
{ "keepempty", IL_KEEPEMPTY },
case IL_INHERITFONT:
lex >> inheritfont_;
break;
+ case IL_INSERTCOTEXT:
+ lex >> insert_cotext_;
+ break;
case IL_INTOC:
lex >> intoc_;
break;
int allowedOccurrences() const { return allowed_occurrences_; }
///
bool allowedOccurrencesPerItem() const { return allowed_occurrences_per_item_; }
+ ///
+ bool insertCotext() const { return insert_cotext_; }
private:
///
void makeDefaultCSS() const;
int allowed_occurrences_ = -1;
///
bool allowed_occurrences_per_item_ = false;
+ ///
+ bool insert_cotext_ = false;
};
///