<html>
<head>
<meta http-equiv="content-type" content="text/html; charset=UTF-8">
</head>
<body>
<p>Hi everybody!</p>
<p>Because of a programming error in the new cairo backend for
lilypond we occasionally generated insane hyperlink rect
definitions. One example is:<br>
</p>
<blockquote>
<p><font face="monospace">cairo_tag_begin (context,
CAIRO_TAG_LINK, attr.c_str ());<br>
cairo_tag_end (context, CAIRO_TAG_LINK);</font><br>
</p>
</blockquote>
<p>with attr set to <br>
</p>
<blockquote>
<p><font face="monospace">rect=[ inf -inf 0.000000 -0.000000 ]
uri='<a
href="textedit:/home/knut/sources/lilybuilt/cairotests/teil3.ly:136:10:10">textedit:///foo/bar.ly:136:10:10'</a></font></p>
</blockquote>
<p>Obviously using infinity and 0.0000 here is nonsense. But it is
interesting to note differences in cairo error detection between
builds for different platforms:<br>
</p>
<p>A build for linux x86-64 accepted attribute strings with "inf"
and "-inf" without problems and without ever generating a context
or surface error.</p>
<p>A mingw crossbuild tested on a Windows 10 system also never
produced a context or surface error immediately after
cairo_tag_begin() or cairo_tag_end(). But after
cairo_surface_finish() a context error 'invalid tag name,
attributes, or
<br>
nesting' was detected.</p>
<p> I really don't know if cairo should silently ignore such a
request to generate a link or if it should produce an error status
!= success. But at least I would have expected that such a
condition is handled identically on different platforms.<br>
</p>
<p>I used cairo git 6872490e77fb2d0cc7d7bb for both builds.</p>
<p>Knut<br>
</p>
<p><br>
</p>
</body>
</html>