[icedtea-web] RFC: fix whitespace in parsing text

Omair Majid omajid at redhat.com
Wed Dec 8 12:34:15 PST 2010


The attached patch makes netx's Parser convert sequences of whitespace 
characters into a single space.

This means that all other places (GUI, command line) see consistent 
titles, descriptions and vendors. As it is, some GUI elements like 
JLabels will simply skip over new line characters while other places may 
show them. This make the strings sanitized for display and consistent.

2010-12-08  Omair Majid  <omajid at redhat.com>

     * netx/net/sourceforge/jnlp/Parser.java
     (getInformationDesc): Fix whitespace in title, vendor and
     description elements.
     (getRelatedContent): Fix whitespace in title and description
     (getSpanText(Node)): Delegate to ...
     (getSpanText(Node,boolean)): New method. Return the text in an
     element, optionally fixing whitespace.

Thoughts? Comments?

-------------- next part --------------
A non-text attachment was scrubbed...
Name: remove-new-lines-in-content-01.patch
Type: text/x-patch
Size: 3299 bytes
Desc: not available
Url : http://mail.openjdk.java.net/pipermail/distro-pkg-dev/attachments/20101208/29188b99/remove-new-lines-in-content-01.patch 

More information about the distro-pkg-dev mailing list