Re: RTF in the canvas?



On 10 May 2001, Miguel de Icaza wrote:

> 
> >  If all complex features like tables and probably nested lists and even pics
> > are needed, I would suggest to use html as layout description language - it's
> > almost as rich as RTF, but humanly readable and may be already
> > partially supported by existing components like gtkhtml or gecko.
> 
> Well, what we need is a powerful canvas item.  See many projects could
> use something like this, and there is no point in having them
> implement their own if we can fullfill this need for them.
> 
> So we are looking at here at the engine that something like Achtung
> could use. 

  ολ, understood. I still think that html (or at least some xml-based format)
would be better than RTF.
  HTML does allow to specify exact properties for everything - here is a file
saved as .html from AbiWord with 3 words "GNOME" in different font size and
style:

----------------------------- 
<?xml version="1.0" encoding="KOI8-R"?>
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml/DTD/xhtml1-strict.dtd";>
<html xmlns="http://www.w3.org/1999/xhtml";>
<head>
<meta http-equiv="content-type" content="text/html; charset=KOI8-R" />
<title>/home/hvv/tmp/1.html</title>
<style type="text/css">
<!--
p
{
    margin-top: 0pt;
    margin-bottom: 0in;
}

p, ul, ol
{
    font-family: "Times New Roman"; font-size: 12pt;
}
-->
</style>
</head>
<body style="background-color: #ffffff;
    margin-top: 1in; margin-bottom: 1in; margin-left: 1in; margin-right: 1in">
<div>
<p><span style="font-weight: bold">GNOME</span><span 
style="font-weight: bold; color:#000000; font-family: Courier; 
font-size: 24.000000pt">GNOME</span><span style="font-style: italic;
color:#000000; font-family: Helvetic; font-size: 28.000000pt">GNOME</span></p>
</div>
</body>
</html>
----------------------

See <span style=> tags - they specify exact formatting properties. Internet
Explorer 5 displays this file as expected, Mozilla should also do that. Though
it's not very likely that anything but gecko will be able to display it
properly without further modifications.

 Best regards,
  -Vlad


_______________________________________________
gnome-hackers mailing list
gnome-hackers gnome org
http://mail.gnome.org/mailman/listinfo/gnome-hackers




[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]