Christian Junk | 3 Jan 2005 16:40
Picon

Re: XBEL xslt stylesheet

Am Freitag, 31. Dezember 2004 01:31 schrieb Narve Saetre:
> There seem to be an invalid URL (another web page gone dead) on the XBEL
>
> page:
>  >Joris Graaumans (joris <at> cs.uu.nl) has developed a couple of XSLT
>
> stylesheets for XBEL <http://www.cs.uu.nl/%7Ejoris/stuff.html>.

Yes, this URL is no longer valid, but Joris sent me his XSLT stylesheets a 
month ago. If you like, I can upload them to 'secure' webspace. I'm able to 
provide webspace for other stylesheets, too. So if you're interested, we can 
collect good styles and offer them under a unique url?

> In my hunt for a better XBEL stylesheet I discovered a superior one
> (nice, recursive, graphic, icons, fast, cross-browser):
>
> http://cgi29.plala.or.jp/mozzarel/xbel/
>
> so I suggest the web master changes the URL to this one (and hope that
> one stays for a while).

Thanks for the link. It's a really good stylesheet!

> [..]

Regards,
Christian
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig
(Continue reading)

Andy Meyer | 3 Jan 2005 19:29
Favicon

xml.dom.minidom.toprettyxml whitespace question

Hello all,

I have a question about the xml.dom.minidom.toprettyxml method's 
insertion of whitespace into text elements, e.g. 
'<foo><bar>Hello!</bar></foo>' getting transformed by toprettyxml to:

<foo>
    <bar>
         Hello!
    </bar>
</foo>

with the addition of tabs and newlines around 'Hello!', instead of:

<foo>
    <bar>Hello!</bar>
</foo>

Since a SAX-style parser would read the second example as identical to 
the raw XML, to me the second way is more correct than the first, but 
I'm new to XML and handling whitespace seems to be an unresolved issue. 
Is this behavior by design?

Andy Meyer
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig

Rich Salz | 3 Jan 2005 20:02

Re: xml.dom.minidom.toprettyxml whitespace question

> I'm new to XML and handling whitespace seems to be an unresolved issue.

You might want to look up the "xml:space" attribute, and "whitespace 
normalization" (e.g., XPath 1.0)

> Is this behavior by design?

Yes. Note that the name is "toprettyxml" not just "dump" or "print" -- 
it's designed to make the output pretty, not to make the output be 
exactly like the input.

	/r$

--

-- 
Rich Salz, Chief Security Architect
DataPower Technology                           http://www.datapower.com
XS40 XML Security Gateway   http://www.datapower.com/products/xs40.html
XML Security Overview  http://www.datapower.com/xmldev/xmlsecurity.html
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig

Walter Dörwald | 3 Jan 2005 23:26
Picon

XIST 2.8 has been released

XIST 2.8 has been released!

What is it?
===========

XIST is an extensible HTML/XML generator written in Python. XIST is
also a DOM parser (built on top of SAX2) with a very simple and
Pythonesque tree API. Every XML element type corresponds to a Python
class, and these Python classes provide a conversion method to transform
the XML tree (e.g. into HTML). XIST can be considered "object oriented XSL".

What's new in version 2.8?
==========================

   * XIST requires Python 2.4 now.
   * ll.xist.ns.specials.x has been renamed to
     ll.xist.ns.specials.ignore.
     ll.xist.utils.findAttr has been renamed to ll.xist.utils.findattr.
   * ll.xist.xfind.item no longer handles slices.
   * XFind has been enhanced to support item and slice operators, i.e.
     if foo is an XFind operator, foo[0] is an operator that will
     produce the first node from foo (if there is one). Negative values
     and slices are supported too.
   * Operators can be chained via division: html.a/html.b is an operator
     that can be passed around and applied to a node.
   * XIST requires the new core module and makes use of the new
     "cooperative displayhook" functionality defined there: If you
     install the displayhook you can tweak or replace
     ll.xist.presenters.hookpresenter to change the output.

(Continue reading)

Malcolm Tredinnick | 4 Jan 2005 04:23
Picon
Favicon

Re: xml.dom.minidom.toprettyxml whitespace question

On Mon, 2005-01-03 at 13:29 -0500, Andy Meyer wrote:
> Hello all,
> 
> I have a question about the xml.dom.minidom.toprettyxml method's 
> insertion of whitespace into text elements, e.g. 
> '<foo><bar>Hello!</bar></foo>' getting transformed by toprettyxml to:
> 
> <foo>
>     <bar>
>          Hello!
>     </bar>
> </foo>
> 
> with the addition of tabs and newlines around 'Hello!', instead of:
> 
> <foo>
>     <bar>Hello!</bar>
> </foo>
> 
> Since a SAX-style parser would read the second example as identical to 
> the raw XML, to me the second way is more correct than the first, but 
> I'm new to XML and handling whitespace seems to be an unresolved issue. 
> Is this behavior by design?

Rich has already answered your question, but I thought I would just
point out that, in fact, the second example would not generally produce
the same SAX events as the raw XML. For the raw XML, you would see
(using a bad summary of SAX events):

        - start "foo" element
(Continue reading)

SourceForge.net | 6 Jan 2005 03:27
Picon
Favicon

[ pyxml-Bugs-1096906 ] SAX2 wrecks marshal.generic

Bugs item #1096906, was opened at 2005-01-05 18:27
Message generated for change (Tracker Item Submitted) made by Item Submitter
You can respond by visiting: 
https://sourceforge.net/tracker/?func=detail&atid=106473&aid=1096906&group_id=6473

Category: SAX
Group: None
Status: Open
Resolution: None
Priority: 5
Submitted By: James S (laskovortex)
Assigned to: Nobody/Anonymous (nobody)
Summary: SAX2 wrecks marshal.generic

Initial Comment:
Using PyXML-0.8.4, mandrake linux 10.1 and python 2.3.4

Not sure what is happening, but

if this is the xml file (called "eraseme.prefs"):

<?xml version='1.0' encoding='UTF-8'?>
<marshal>
  <dictionary id='i2'>
    <string>color</string>
    <string>blue</string>
    <string>max</string>
    <int>3</int>
    <string>min</string>
    <int>0</int>
(Continue reading)

Narve Saetre | 6 Jan 2005 21:46
Picon

Re: XBEL xslt stylesheet


>Yes, this URL is no longer valid, but Joris sent me his XSLT stylesheets a 
>month ago. If you like, I can upload them to 'secure' webspace. I'm able to 
>provide webspace for other stylesheets, too. So if you're interested, we can 
>collect good styles and offer them under a unique url?
>  
>
Good idea -- having nice, working stylesheets available is always good 
if you have xml files and you want to display them quickly. Since your 
web site seems to be the main page for XBEL related work, it would be 
the natural place to host XBEL stylesheets. And of course, broken links 
are evil, so it is better to host the stylesheets yourself:)

--

-- 
Narve Sætre
Partner / Machina Networks as / +47 41915331

_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig

Nico Poppelier | 7 Jan 2005 19:32
Picon
Picon
Favicon

SAX2 support

Dear SIG members,

I have some XML tools written in Perl that I would like to rewrite in 
Python and make namespace-aware at the same time.
What I now have is based on xml.sax, but yesterday I noticed that some 
of the namespace features are not supported (yet).

The section on xml.sax.handler in the library reference says: " In 
addition to these classes, xml.sax.handler provides symbolic constants
for the feature and property names" and then gives a list of features 
and properties. The source for xml/sax/xmlreader.py, however, does not 
implement features and properites, and instead throws an exception when 
you call e.g. getFeature or setFeature.

When will features and properties of SAX2 be properly supported in 
xml.sax? Or should I forget about xml.sax and move to xml.dom, for 
example? The latter doesn't appeal to me, since I prefer minimal XML 
APIs and I find DOM too big and too cluttered.

Regards,

Nico Poppelier

P.S. Some years ago, I was editor of the W3C Math Working Group and did 
of lot of XML-related work, but with my present job XML is an activity 
for the occasional free weekend.
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig

(Continue reading)

Nathan Given | 7 Jan 2005 23:52

Trouble installing PyXML-0.8.4

Dear Python Representative,

I am having trouble installing PyXMO-0.8.4.

Here is some output from my console:

ebiz:/usr/local/include:! > python -V
Python 2.3.3
ebiz:/usr/local/include:! >

ebiz:/home/ng32/downloads/PyXML-0.8.4:! > python setup.py build
Traceback (most recent call last):
   File "setup.py", line 127, in ?
     config_h_vars = parse_config_h(open(config_h))
IOError: [Errno 2] No such file or directory: 
'/usr/local/include/python2.3/pyconfig.h'
ebiz:/home/ng32/downloads/PyXML-0.8.4:! >
ebiz:/home/ng32/downloads/PyXML-0.8.4:! > which python
/usr/local/bin/python
ebiz:/home/ng32/downloads/PyXML-0.8.4:! >

ebiz:/usr/local/include:! > ls -l | grep python
drwxr-xr-x   2 root       sys           2048 Jan  6 15:05 python/
drwxr-xr-x   2 swliddle   deg           2048 Sep  9  2002 python2.2/
ebiz:/usr/local/include:! >

I can't seem to figure it out... I guess it thinks python is in 
/usr/local/include/python2.3... but it doesn't appear like that 
directory exists.

(Continue reading)

Martin v. Löwis | 8 Jan 2005 00:49
Picon
Gravatar

Re: Trouble installing PyXML-0.8.4

Nathan Given wrote:
> ebiz:/usr/local/include:! > ls -l | grep python
> drwxr-xr-x   2 root       sys           2048 Jan  6 15:05 python/
> drwxr-xr-x   2 swliddle   deg           2048 Sep  9  2002 python2.2/
> ebiz:/usr/local/include:! >
> 
> I can't seem to figure it out... I guess it thinks python is in 
> /usr/local/include/python2.3... but it doesn't appear like that 
> directory exists.
> 
> Any ideas?

There is something wrong with your Python installation. The include
directory is supposed to be called /usr/local/include/python2.3,
not /usr/local/include/python. It might be that your sysadmin has
messed with the installation, renaming the directory. Please ask
her to undo this change.

Regards,
Martin
_______________________________________________
XML-SIG maillist  -  XML-SIG <at> python.org
http://mail.python.org/mailman/listinfo/xml-sig


Gmane