Better workaround (Re: Some before pseudo element breaks Amaya handling of UTF-8)
Dominique Meeùs <[email protected]> Fri, 28 Jan 2011 10:28:16 +0100
| Newsgroups | gmane.comp.web.amaya.general |
|---|---|
| Message-ID | <[email protected]> |
If the css is written outside the document, Amaya is still unable to display the pseudo-element correctly but does not destroy all others multi-byte characters any more. See example attached with external css, first Bluefish only, then safely edited with Amaya. (I’m not sure my “succession of the separated bytes” hereunder was the correct diagnostic. Looks more complicated than that. Anyway every single multi-byte character was replaced by some chain of funny characters.) Dominique Meeùs a écrit ce qui suit, le 28/01/11 05:16 : > Using Amaya 11.3.1 (Dec 9 2009) under Ubuntu 10.10. > Some before pseudo element breaks Amaya handling of UTF-8: multi-byte > characters are replaced in the code by the succession of the separated > bytes. > [et cetera] -- Amicalement, Dominique, [email protected], +32 473 61 31 75, http://www.d-meeus.be/ It’s partly true, too, but it isn’t /all/ true. People always think something’s /all/ true. (J. D. Salinger, 1958, /The Catcher in the Rye/ <http://studies.d-meeus.be/wikindx3/index.php?action=resourceView&id=649>, Penguin Books, Harmondsworth (Middlesex), 220 pages, ISBN:0-14-001248-6, p. 13.)
callnoteNBSP[1].css
(text/css, 64 B)
.callnote:before {content:" [";}
.callnote:after {content:"]";}
callnoteNBSP[1]extcss.html
(text/html, 1 KB)
<?xml version="1.0" encoding="utf-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Calling note [1]</title>
<meta http-equiv="content-type" content="text/html; charset=utf-8" />
<link rel="stylesheet" href="callnoteNBSP[1].css" type="text/css" />
</head>
<body>
<p>This is written in UTF-8 and declared as such. I do write accented charachters
explicitly as such, say, in French, « caractères accentués » for “accented
charachters”. I am not using numeric entities because I want my code to be readable.
Here I am calling a note by a digit one like this<a id="callnote1" class="callnote"
href="#note1">1</a>.</p>
<p>After some more text comes the note.</p>
<p id="note1"><a class="numnote" href="#callnote1">1</a>. In real life, I would put the
digit one calling this note in upper position, but let’s keep it simple here.</p>
</body>
</html>
callnoteNBSP[1]extcssAmaya.html
(text/html, 1.1 KB)
<?xml version="1.0" encoding="UTF-8"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN"
"http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
<html xmlns="http://www.w3.org/1999/xhtml" xml:lang="en" lang="en">
<head>
<title>Calling note [1]</title>
<meta http-equiv="content-type" content="text/html; charset=UTF-8" />
<link rel="stylesheet" href="callnoteNBSP[1].css" type="text/css" />
</head>
<body>
<p>This is written in UTF-8 and declared as such. I do write accented
charachters explicitly as such, say, in French, « caractères accentués »
for “accented charachters”. I am not using numeric entities because I want
my code to be readable. Here I am calling a note by a digit one like this<a
id="callnote1" class="callnote" href="#note1">1</a>.</p>
<p>After some more text comes the note.</p>
<p>In this version, I may edit in Amaya with more multi-bytes, even Russian :
« Политическая экономия ».</p>
<p id="note1"><a class="numnote" href="#callnote1">1</a>. In real life, I would
put the digit one calling this note in upper position, but let’s keep it
simple here.</p>
</body>
</html>