W3C home > Mailing lists > Public > www-html@w3.org > May 2000

RE: Give hint to browser about hyphenation: &php;

From: Dave J Woolley <DJW@bts.co.uk>
Date: Wed, 24 May 2000 15:07:57 +0100
Message-ID: <81E4A2BC03CED111845100104B62AFB5824684@stagecoach.bts.co.uk>
To: "'hattel@na.dk'" <hattel@na.dk>, www-html@w3.org
Cc: Michael Sundstrøm <Michael@na.dk>
> From:	Søren Hattel [SMTP:hattel@na.dk]
>  
> as programmer of dynamic content pages based on eg. databases I often
> encounter the problem of long words that break the design. The reason
> being that the browser cannot hyphenate words.
> 
	[DJW:]  A quick string search of the HTML 4.01 specification would
have
	found you this - the feature already exists.  (Actually, if a new
entity
	were needed, you would have to have it added to Unicode first!)

9.3.3 Hyphenation
In HTML, there are two types of hyphens: the plain hyphen and the soft
hyphen. The
plain hyphen should be interpreted by a user agent as just another
character. The
soft hyphen tells the user agent where a line break can occur.
Those browsers that interpret soft hyphens must observe the following
semantics:
If a line is broken at a soft hyphen, a hyphen character must be displayed
at the end
of the first line. If a line is not broken at a soft hyphen, the user agent
must not
display a hyphen character. For operations such as searching and sorting,
the soft
	hyphen should always be ignored.

In HTML, the plain hyphen is represented by the "-" character (&#45; or
&#x2D;).
The soft hyphen is represented by the character entity reference &shy;
(&#173; or
	&#xAD;)
Received on Wednesday, 24 May 2000 10:14:31 GMT

This archive was generated by hypermail 2.2.0+W3C-0.50 : Tuesday, 27 March 2012 18:15:43 GMT