Re: [xep-support] hyphenation for url's

From: G. Ken Holman (
Date: Tue Jun 24 2003 - 04:22:20 PDT

  • Next message: Els van Trigt: "RE: [xep-support] No matching stylesheet error"

    At 2003-06-24 09:42 +0200, Jack Broeren wrote:
    >I can I tell xep to hyphenate a long string like the url
    >(e.g. http://www,
    >on the chars : or / (or .)

    I needed to do this for the long XPath addresses used in my UBL
    stylesheets, by preventing unwanted breaks and promoting breaks at the "/"

    I did this by a recursive loop through the string adding zero-width space
    ​ characters to the location either immediately before or
    immediately after the "/" characters (choose based on what you want to see
    at the line break).

    When the resulting string was short enough for my table column, the
    zero-width spaces cannot be seen. When the string was too long, the breaks
    were done at the embedded zero-width spaces.

    I hope this helps.

    .......................... Ken

    Upcoming hands-on courses: XSLT/XPath North America: Aug 12, 2003
    -                          XSL-FO     North America: Aug  4, 2003
    G. Ken Holman      
    Crane Softwrights Ltd.
    Box 266, Kars, Ontario CANADA K0A-2E0   +1(613)489-0999 (F:-0995)
    ISBN 0-13-065196-6                      Definitive XSLT and XPath
    ISBN 0-13-140374-5                              Definitive XSL-FO
    ISBN 1-894049-08-X  Practical Transformation Using XSLT and XPath
    ISBN 1-894049-11-X              Practical Formatting Using XSL-FO
    Member of the XML Guild of Practitioners:
    Male Breast Cancer Awareness
    (*) To unsubscribe, send a message with words 'unsubscribe xep-support'
    in the body of the message to from the address
    you are subscribed from.
    (*) By using the Service, you expressly agree to these Terms of Service

    This archive was generated by hypermail 2.1.5 : Tue Jun 24 2003 - 04:24:56 PDT