From b90cd376c81615fec9d9c076b399c94951dc1f60 Mon Sep 17 00:00:00 2001 From: Johannes Maibaum Date: Mon, 14 Sep 2020 08:06:58 +0200 Subject: [PATCH 1/2] fix(packages): Remove extra space in \code in url Closes #1056 --- packages/url.lua | 1 - 1 file changed, 1 deletion(-) diff --git a/packages/url.lua b/packages/url.lua index 3bb7a6e8f..8ac044f81 100644 --- a/packages/url.lua +++ b/packages/url.lua @@ -44,7 +44,6 @@ SILE.registerCommand("code", function(_, content) SILE.settings.temporarily(function() SILE.call("verbatim:font") SILE.process(content) - SILE.typesetter:typeset(" ") end) end) From 08d719d0960e0929b900b45132ef6f03a69d96e9 Mon Sep 17 00:00:00 2001 From: Caleb Maclennan Date: Mon, 14 Sep 2020 12:22:48 +0300 Subject: [PATCH 2/2] refactor(packages): Simplify steps to accomplish the same thing --- packages/url.lua | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) diff --git a/packages/url.lua b/packages/url.lua index 8ac044f81..2a3df3975 100644 --- a/packages/url.lua +++ b/packages/url.lua @@ -40,11 +40,8 @@ SILE.registerCommand("url", function (options, content) SILE.call("code", {}, result) end) -SILE.registerCommand("code", function(_, content) - SILE.settings.temporarily(function() - SILE.call("verbatim:font") - SILE.process(content) - end) +SILE.registerCommand("code", function(options, content) + SILE.call("verbatim:font", options, content) end) return {