Help | Site Map
Connecting Tech Pros Worldwide
 
 
LinkBack Thread Tools
  #1  
Old December 20th, 2006, 05:45 PM
=?ISO-8859-1?Q?J=FCrgen_Kahrs?=
Guest
 
Posts: n/a
Default Gtkdialg accepts XML data that is not well-formed

Hello,

I just tried to get the example script of the
Gtkdialog tool running:

http://linux.pte.hu/~pipas/gtkdialog/

This tool claims to use an XML description of
a GUI and run it. Indeed, the example works.
What puzzles me is the fact that the example
is not well-formed XML:

<vbox>
<frame Print fields>
<hbox>
....

I used xmlwf and xmllint and both didnt eat this.
Anyway, Gtkdialog eats it. How can this work ?
  #2  
Old December 20th, 2006, 10:15 PM
Manuel Collado
Guest
 
Posts: n/a
Default Re: Gtkdialg accepts XML data that is not well-formed

Jürgen Kahrs escribió:
Quote:
Hello,
>
I just tried to get the example script of the
Gtkdialog tool running:
>
http://linux.pte.hu/~pipas/gtkdialog/
>
This tool claims to use an XML description of
a GUI and run it. Indeed, the example works.
What puzzles me is the fact that the example
is not well-formed XML:
>
<vbox>
<frame Print fields>
<hbox>
...
>
I used xmlwf and xmllint and both didnt eat this.
Anyway, Gtkdialog eats it. How can this work ?
Well, quoting the Gtkdialog docs:

"The dialog description language is a simple XML like language capable
to denote any complex dialog box containing widgets and boxes. "

So it doesn't claim to be XML, but just XML-like. Probably read with a
simple ad-hoc parser (not an XML compliant one). The source tarball
contains files like "gtkdialog_lexer.c", "gtkdialog_parser.c", etc.

Regards.
--
Manuel Collado - http://lml.ls.fi.upm.es/~mcollado
  #3  
Old December 20th, 2006, 11:05 PM
=?ISO-8859-1?Q?J=FCrgen_Kahrs?=
Guest
 
Posts: n/a
Default Re: Gtkdialg accepts XML data that is not well-formed

Hello Manuel,
Quote:
Quote:
>I used xmlwf and xmllint and both didnt eat this.
>Anyway, Gtkdialog eats it. How can this work ?
>
Well, quoting the Gtkdialog docs:
>
"The dialog description language is a simple XML like language capable
to denote any complex dialog box containing widgets and boxes. "
Thanks for finding this out.
On their web page they introduce the first example
with the sentence.

The following shell script will load and execute a Glade XML file

So, I thought they really use XML files.
Quote:
So it doesn't claim to be XML, but just XML-like. Probably read with a
simple ad-hoc parser (not an XML compliant one). The source tarball
contains files like "gtkdialog_lexer.c", "gtkdialog_parser.c", etc.
XML-like sounds nice, but it becomes useless when
I cannot parse it with a proper XML parser.
It is incomprehensible to me why someone should
define an XML-like format. Only Microsoft and IBM
can make money by adopting a standard in this way.
  #4  
Old December 21st, 2006, 10:15 PM
Manuel Collado
Guest
 
Posts: n/a
Default Re: Gtkdialg accepts XML data that is not well-formed

Jürgen Kahrs escribió:
Quote:
Hello Manuel,
...
On their web page they introduce the first example
with the sentence.
>
The following shell script will load and execute a Glade XML file
>
So, I thought they really use XML files.
Well, it seems that Gtkdialog accepts two different input formats:

- True-XML glade files (option -g)
- XML-like Gtkdialog files (option -f)
Quote:
...
XML-like sounds nice, but it becomes useless when
I cannot parse it with a proper XML parser.
It is incomprehensible to me why someone should
define an XML-like format. Only Microsoft and IBM
can make money by adopting a standard in this way.
Yes, it is hurtful (or at least confusing) to invent new file formats and
pretend they are similar and almost-compatible with well stablished
standards, when in fact they aren't.

Regards.
--
Manuel Collado - http://lml.ls.fi.upm.es/~mcollado
 

Bookmarks

Thread Tools

Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is Off
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On

What is Bytes?

We are a network of experts and professionals in IT and software development that help one another with answers to tough questions and share insights. Get the best answers to your questions from over network members.
Post your question now . . .
It's fast and it's free

Popular Articles