Code Monkey home page Code Monkey logo

soul's People

Contributors

drehscheibe avatar

Stargazers

 avatar  avatar  avatar

Watchers

 avatar  avatar  avatar

soul's Issues

Soul breaks page numbering

Using soul sometimes breaks page numbering. This happens in particular when the highlighted/underlined text contains a paragraph break and appears near a page break. The fix would be a one-line change.

This bug was brought up in this question on StackExchange, as well as in a few other questions that have since been closed as duplicates. The questions and the answers contain some sample documents demonstrating the problem. A solution is proposed in my answer to the question.

The problem lies in the fact that soul uses\count0, which also holds the page number, as a local scratch register. Using \count0 in this manner is only safe if it is guaranteed that no page breaks may be triggered within the scope where it is used. This is not always true in soul's case.

To solve the problem, the line

\countdef\SOUL@minus\z@

in soul.dtx would simply need to be replaced by (for instance)

\newcount\SOUL@minus

Replacing the \z@ by 8 would also resolve the issue, but could still lead to similar problems if an output routine is employed that uses this register. A few of the other registers used by soul should probably also be similarly reserved.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.