[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
branch master updated: @flushleft and @flushright for LaTeX
From: |
Gavin D. Smith |
Subject: |
branch master updated: @flushleft and @flushright for LaTeX |
Date: |
Tue, 16 Aug 2022 09:51:16 -0400 |
This is an automated email from the git hooks/post-receive script.
gavin pushed a commit to branch master
in repository texinfo.
The following commit(s) were added to refs/heads/master by this push:
new 3385218c17 @flushleft and @flushright for LaTeX
3385218c17 is described below
commit 3385218c17278df5cbcd281784e722f6a4b97398
Author: Gavin Smith <gavinsmith0123@gmail.com>
AuthorDate: Tue Aug 16 14:51:08 2022 +0100
@flushleft and @flushright for LaTeX
* tp/Texinfo/Convert/LaTeX.pm (%LaTeX_environment_commands):
Used nested flushleft/GNUTexinfoprefomatted environment for
@flushleft; likewise for @flushright.
---
ChangeLog | 8 +++++
tp/Texinfo/Convert/LaTeX.pm | 13 ++-----
.../res_parser/formatting_latex/formatting.tex | 40 ++++++++++++++++++++++
3 files changed, 50 insertions(+), 11 deletions(-)
diff --git a/ChangeLog b/ChangeLog
index 9eefcce323..94f59b9fb9 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,11 @@
+2022-08-16 Gavin Smith <gavinsmith0123@gmail.com>
+
+ @flushleft and @flushright for LaTeX
+
+ * tp/Texinfo/Convert/LaTeX.pm (%LaTeX_environment_commands):
+ Used nested flushleft/GNUTexinfoprefomatted environment for
+ @flushleft; likewise for @flushright.
+
2022-08-16 Gavin Smith <gavinsmith0123@gmail.com>
* tp/tests/README: Advise "make -k check", which runs
diff --git a/tp/Texinfo/Convert/LaTeX.pm b/tp/Texinfo/Convert/LaTeX.pm
index 1c18dd8422..31c7e0da0a 100644
--- a/tp/Texinfo/Convert/LaTeX.pm
+++ b/tp/Texinfo/Convert/LaTeX.pm
@@ -28,12 +28,6 @@
#\tableofcontents
#}
#
-# flushleft and flushright
-# the flushleft and flushright in Texinfo are not the same as in
-# LaTeX, as, in addition to come from a possibly different margin,
-# the text is not filled at all in Texinfo, each line is left as is.
-# LaTeX flushleft and flushright are filled but not aligned.
-#
# @group should also be added together with the non filled environments.
#
# There is something about form feeds to do. There is some processing of form
@@ -498,13 +492,10 @@ my @LaTeX_same_block_commands = (
my $small_font_size = 'footnotesize';
-# TODO flushleft and flushright
-# the flushleft and flushright in Texinfo are not the same as in
-# LaTeX, as, in addition to come from a possibly different margin,
-# the test is not filled at all, each line is left as is. LaTeX
-# flushleft and flushright are filled but not aligned.
my %LaTeX_environment_commands = (
'raggedright' => ['flushleft'],
+ 'flushleft' => ['flushleft', 'GNUTexinfopreformatted'],
+ 'flushright' => ['flushright', 'GNUTexinfopreformatted'],
'quotation' => ['quote'],
'smallquotation' => ['quote', $small_font_size],
'indentedblock' => ['quote'],
diff --git a/tp/tests/layout/res_parser/formatting_latex/formatting.tex
b/tp/tests/layout/res_parser/formatting_latex/formatting.tex
index 45f1e7b4ba..7fb4f1ae69 100644
--- a/tp/tests/layout/res_parser/formatting_latex/formatting.tex
+++ b/tp/tests/layout/res_parser/formatting_latex/formatting.tex
@@ -1510,11 +1510,19 @@ Value--table samp
c--artouche
\end{mdframed}
+\begin{flushleft}
+\begin{GNUTexinfopreformatted}
f--lushleft
more text
+\end{GNUTexinfopreformatted}
+\end{flushleft}
+\begin{flushright}
+\begin{GNUTexinfopreformatted}
f--lushright
more text
+\end{GNUTexinfopreformatted}
+\end{flushright}
\begin{center}
ce--ntered line
@@ -3197,11 +3205,19 @@ Value--table samp
c--artouche
\end{mdframed}
+\begin{flushleft}
+\begin{GNUTexinfopreformatted}
f--lushleft
more text
+\end{GNUTexinfopreformatted}
+\end{flushleft}
+\begin{flushright}
+\begin{GNUTexinfopreformatted}
f--lushright
more text
+\end{GNUTexinfopreformatted}
+\end{flushright}
\begin{center}
ce--ntered line
@@ -4905,11 +4921,19 @@ Value--table samp
c--artouche
\end{mdframed}
+\begin{flushleft}
+\begin{GNUTexinfopreformatted}
f--lushleft
more text
+\end{GNUTexinfopreformatted}
+\end{flushleft}
+\begin{flushright}
+\begin{GNUTexinfopreformatted}
f--lushright
more text
+\end{GNUTexinfopreformatted}
+\end{flushright}
\begin{center}
ce--ntered line
@@ -6591,11 +6615,19 @@ Value--table samp
c--artouche
\end{mdframed}
+\begin{flushleft}
+\begin{GNUTexinfopreformatted}
f--lushleft
more text
+\end{GNUTexinfopreformatted}
+\end{flushleft}
+\begin{flushright}
+\begin{GNUTexinfopreformatted}
f--lushright
more text
+\end{GNUTexinfopreformatted}
+\end{flushright}
\begin{center}
ce--ntered line
@@ -8924,20 +8956,28 @@ c{-}{-}artouche
\leftskip=2em\relax\ttfamily%
\end{GNUTexinfopreformatted}
+\begin{flushleft}
+\begin{GNUTexinfopreformatted}
\begin{GNUTexinfopreformatted}
\leftskip=2em\relax\ttfamily%
f{-}{-}lushleft
more text
\end{GNUTexinfopreformatted}
+\end{GNUTexinfopreformatted}
+\end{flushleft}
\begin{GNUTexinfopreformatted}
\leftskip=2em\relax\ttfamily%
\end{GNUTexinfopreformatted}
+\begin{flushright}
+\begin{GNUTexinfopreformatted}
\begin{GNUTexinfopreformatted}
\leftskip=2em\relax\ttfamily%
f{-}{-}lushright
more text
\end{GNUTexinfopreformatted}
+\end{GNUTexinfopreformatted}
+\end{flushright}
\begin{GNUTexinfopreformatted}
\leftskip=2em\relax\ttfamily%
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- branch master updated: @flushleft and @flushright for LaTeX,
Gavin D. Smith <=