
我在 Lyx 中使用強調來指示計算演算法描述中的變數。
其中一些變數的名稱很長。當這些變數進入定義的頁邊距時,Lyx 不會嘗試用連字號連接這些變量,從而導致文字溢出。
此外,將它們包含在句子中似乎也會導致標準文字單字也被推到邊緣。
您可以在此螢幕截圖中看到這兩個問題;前兩行表示標準文字行所遵循的邊距的開始:
這是相關的 lyx 程式碼:
\emph default
are gathered into a set
\emph on
degreeOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
and the unmapped atoms of degree greater than one which are bonded to
\emph on
mapped
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
are gathered into a set
\emph on
unmappedDegreeGtOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
b
\end_layout
\end_inset
\emph default
.
The atoms in
\emph on
degreeOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
are decomposed into groups of atoms
\emph on
chemicalSimilarityGroups
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
which are a chemical match [
\begin_inset CommandInset ref
LatexCommand formatted
reference "Procedure:isChemicalMatch"
\end_inset
].
So too are the atoms in
\emph on
unmappedDegreeGtOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
decomposed into
\emph on
chemicalSimilarityGroups
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
b
\end_layout
\end_inset
\emph default
.
These chemically similar groups are then paired up where possible such
that a group
\emph on
chemicalSimilarityGroup
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
in
\emph on
chemicalSimilarityGroups
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
contains atoms which are a chemical match for a group
\emph on
chemicalSimilarityGroup
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
b
\end_layout
\end_inset
我知道我可以用來\hyphenation{wo-rd, w-ord}
手動指示此類單字允許的連字符。然而,我有很多這樣的變量,所以這種一對一的方法會太耗時。
我已經在尋找解決方案Lyx 連字符文檔,但無濟於事。
我是否可以在序言中添加一些內容,以指示 Lyx 以與標準文本單詞相同的方式對這些強調的單詞進行連字符,並防止它們破壞 Lyx 對行長度的計算,從而也防止標準文本溢出?
我想實現符合定義頁邊距的所有文字的連字符,而不是使用例如啟用對齊文字\raggedright
。
編輯:這是一個最小的 Lyx 檔案範例。 pdflatex 的圖像結果(編輯 -> 查看 [PDF (pdflatex)]) 隨後。
\lyxformat 413
\begin_document
\begin_header
\textclass article
\use_default_options true
\maintain_unincluded_children false
\language english
\language_package default
\inputencoding auto
\fontencoding global
\font_roman default
\font_sans default
\font_typewriter default
\font_default_family default
\use_non_tex_fonts false
\font_sc false
\font_osf false
\font_sf_scale 100
\font_tt_scale 100
\graphics default
\default_output_format default
\output_sync 0
\bibtex_command default
\index_command default
\paperfontsize default
\use_hyperref false
\papersize default
\use_geometry false
\use_amsmath 1
\use_esint 1
\use_mhchem 1
\use_mathdots 1
\cite_engine basic
\use_bibtopic false
\use_indices false
\paperorientation portrait
\suppress_date false
\use_refstyle 1
\index Index
\shortcut idx
\color #008000
\end_index
\secnumdepth 3
\tocdepth 3
\paragraph_separation indent
\paragraph_indentation default
\quotes_language english
\papercolumns 1
\papersides 1
\paperpagestyle default
\tracking_changes false
\output_changes false
\html_math_output 0
\html_css_as_file 0
\html_be_strict false
\end_header
\begin_body
\begin_layout Standard
Next, the procedure considers each anchor atom
\emph on
anchor
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
and its mapped counterpart
\emph on
mapped
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
.
The degree one atoms bonded to
\emph on
anchor
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
are gathered into a set
\emph on
degreeOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
and the unmapped atoms of degree greater than one which are bonded to
\emph on
mapped
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
are gathered into a set
\emph on
unmappedDegreeGtOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
b
\end_layout
\end_inset
\emph default
.
The atoms in
\emph on
degreeOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
are decomposed into groups of atoms
\emph on
chemicalSimilarityGroups
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
which are a chemical match.
So too are the atoms in
\emph on
unmappedDegreeGtOneNbors
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
decomposed into
\emph on
chemicalSimilarityGroups
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
b
\end_layout
\end_inset
\emph default
.
These chemically similar groups are then paired up where possible such
that a group
\emph on
chemicalSimilarityGroup
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
in
\emph on
chemicalSimilarityGroups
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
a
\end_layout
\end_inset
\emph default
contains atoms which are a chemical match for a group
\emph on
chemicalSimilarityGroup
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
b
\end_layout
\end_inset
\emph default
in
\emph on
chemicalSimilarityGroups
\begin_inset script subscript
\begin_layout Plain Layout
\emph on
b
\end_layout
\end_inset
\emph default
.
Each such pair is then considered in turn.
\end_layout
\end_body
\end_document
它在 Adobe Reader 中的外觀如下: