summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMatthäus G. Chajdas <dev@anteru.net>2021-02-12 14:23:09 +0100
committerMatthäus G. Chajdas <dev@anteru.net>2021-02-12 14:23:09 +0100
commite496f91cc219ae66b1defdd2ee039828d7b3c443 (patch)
treeecbeaada928d2bc45eb1bdf29a4ce6b11fc250fd
parentc0f01ca4278672cdfe37056dca5b6e595002b725 (diff)
downloadpygments-git-fix/1698-lineos-wrapping.tar.gz
Document the line number styling changes.fix/1698-lineos-wrapping
-rw-r--r--CHANGES16
1 files changed, 16 insertions, 0 deletions
diff --git a/CHANGES b/CHANGES
index e62bc411..f695acab 100644
--- a/CHANGES
+++ b/CHANGES
@@ -32,6 +32,22 @@ Version 2.8.0
- Changed setuptools to use a declarative config through ``setup.cfg``.
Building Pygments now requires setuptools 39.2+.
- Added markdown to MarkdownLexer aliases (#1687)
+- Changed line number handling
+
+ * In ``<table>`` based output, the ``td.linenos`` element will have either a
+ ``normal`` or ``special`` class attached. Previously, only ``special`` line
+ numbers got a class. This prevents styles from getting applied twice -
+ once via ``<pre>``, once via ``<span class="special">``. This also means
+ that ``td.linenos pre`` is no longer styled, instead, use
+ ``td.linenos .normal`` and ``td.linenos .special``.
+ * In the "inline" style, the DOM element order was changed. The line number
+ is added first, then the line is wrapped is wrapped by the highlighter.
+ This fixes lines not being fully highlighted.
+ * The visual output for inline and non-inline line numbers & highlighting,
+ as well as class-based and inline styling is now consistent.
+ * Line number styles are set to ``background-color: transparent`` and
+ ``color: inherit`` by default. This works much better with dark styles
+ which don't have colors set for line numbers.
Version 2.7.4