From 53f5cdeed1c99d21ba9fbbeb98c98a206d5a4de6 Mon Sep 17 00:00:00 2001 From: Konstantin Shaposhnikov Date: Tue, 8 Mar 2016 00:12:11 +0800 Subject: [PATCH] cmd/present: fix displaying line numbers for .code and .play Line numbers match line numbers from the included file, not the lines in the segment selected by the .code or .play START/STOP regexps. Fixes golang/go#5248 Change-Id: I374e7b665e98db5032446ae49e6fae00d9d2b975 Reviewed-on: https://go-review.googlesource.com/20311 Reviewed-by: Andrew Gerrand --- cmd/present/static/styles.css | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/cmd/present/static/styles.css b/cmd/present/static/styles.css index 688127f6..d877682b 100644 --- a/cmd/present/static/styles.css +++ b/cmd/present/static/styles.css @@ -372,6 +372,12 @@ pre { color: black; } +pre.numbers span:before { + content: attr(num); + margin-right: 1em; + display: inline-block; +} + code { font-size: 95%; font-family: 'Droid Sans Mono', 'Courier New', monospace;