summaryrefslogtreecommitdiff
path: root/Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp
diff options
context:
space:
mode:
authorKarl Berry <karl@freefriends.org>2020-03-15 22:49:59 +0000
committerKarl Berry <karl@freefriends.org>2020-03-15 22:49:59 +0000
commit19d768ec00d8115ba1ff63de137a813662598155 (patch)
tree2c8d67339738161fa0ca38cf85f7e206fea57e65 /Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp
parent94d8a851454f2294254325942a0a96b90404147d (diff)
dvisvgm 2.9
git-svn-id: svn://tug.org/texlive/trunk@54335 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp')
-rw-r--r--Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp8
1 files changed, 4 insertions, 4 deletions
diff --git a/Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp b/Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp
index 97520c59534..e40ad8a3929 100644
--- a/Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp
+++ b/Build/source/texk/dvisvgm/dvisvgm-src/src/Font.cpp
@@ -2,7 +2,7 @@
** Font.cpp **
** **
** This file is part of dvisvgm -- a fast DVI to SVG converter **
-** Copyright (C) 2005-2019 Martin Gieseking <martin.gieseking@uos.de> **
+** Copyright (C) 2005-2020 Martin Gieseking <martin.gieseking@uos.de> **
** **
** This program is free software; you can redistribute it and/or **
** modify it under the terms of the GNU General Public License as **
@@ -425,10 +425,10 @@ int PhysicalFont::traceAllGlyphs (bool includeCached, GFGlyphTracer::Callback *c
* @param[out] bbox the computed bounding box
* @param[in] cb optional calback object forwarded to the tracer
* @return true if the box could be computed successfully */
-bool PhysicalFont::getExactGlyphBox(int c, BoundingBox& bbox, GFGlyphTracer::Callback* cb) const {
+bool PhysicalFont::getExactGlyphBox (int c, BoundingBox& bbox, GFGlyphTracer::Callback* cb) const {
Glyph glyph;
if (getGlyph(c, glyph, cb)) {
- glyph.computeBBox(bbox);
+ bbox = glyph.computeBBox();
double s = scaledSize()/unitsPerEm();
bbox.scale(s, s);
return true;
@@ -608,7 +608,7 @@ double NativeFont::charWidth (int c) const {
FontEngine::instance().setFont(*this);
int upem = FontEngine::instance().getUnitsPerEM();
double w = upem ? (scaledSize()*FontEngine::instance().getAdvance(c)/upem*_style.extend) : 0;
- w += fabs(_style.slant*charHeight(c));
+ w += abs(_style.slant*charHeight(c));
return w;
}