summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorwl <wl>2013-01-13 10:11:33 +0000
committerwl <wl>2013-01-13 10:11:33 +0000
commit4afaeb84f39261ce7d9211c15ed4e89f1bf95176 (patch)
tree582d79c4ee143bece5d916da747310ebe9cec9dd /src
parentdf5bd35647bafd44d7397132e94b35c4514e78dd (diff)
downloadgroff-4afaeb84f39261ce7d9211c15ed4e89f1bf95176.tar.gz
[eqn] Fix display of matrices in nroff output.
Problem reported by Andy Spencer <andy753421@gmail.com>. * src/preproc/eqn/pile.cpp (pile_box::compute_metrics): Fix rounding.
Diffstat (limited to 'src')
-rw-r--r--src/preproc/eqn/pile.cpp4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/preproc/eqn/pile.cpp b/src/preproc/eqn/pile.cpp
index 239e81b3..a511ce7e 100644
--- a/src/preproc/eqn/pile.cpp
+++ b/src/preproc/eqn/pile.cpp
@@ -1,5 +1,5 @@
// -*- C++ -*-
-/* Copyright (C) 1989, 1990, 1991, 1992, 2004, 2007, 2009
+/* Copyright (C) 1989-1992, 2004, 2007, 2009, 2013
Free Software Foundation, Inc.
Written by James Clark (jjc@jclark.com)
@@ -40,7 +40,7 @@ int pile_box::compute_metrics(int style)
printf(">?(\\n[" DEPTH_FORMAT "]+\\n[" HEIGHT_FORMAT "]+%dM)",
col.p[i-1]->uid, col.p[i]->uid, default_rule_thickness*5);
// round it so that it's a multiple of the vertical resolution
- printf("/\\n(.V+(\\n(.V/2)*\\n(.V\n");
+ printf("+(\\n(.V/2)/\\n(.V*\\n(.V\n");
printf(".nr " SUP_RAISE_FORMAT " \\n[" BASELINE_SEP_FORMAT "]*%d/2"
"+%dM\n",