Hi,
Noting the recent release of the excellent XML Widgets of M.Faassen and the discussion on wysiwyg I thought I better pre-annouce my upcoming VisualStudio for Zope in case other people are working on the same thing.
Currently, VisualStudio consists of 3 classes: Forms, Widgets and Behaviours. A Form is an XML document containing XHTML + Widgets.
Widgets are represented by: <box name="mybox1" x=1 y=5 width=10 height=50 behaviours="" theme="None"> contents </box>
within the form. They are rendered to HTML by calling a series of functions on a widget. A widget is another XML document in the aquisition path of the form:
<widget name="box" behaviours=".."> <constructor>javascript constructor function</constructor> <builder> <CSS></CSS> <- use browsers to edit these <DIV></DIV> </builder> <code language = ''>additional javascript/dhtml/python method code</code> <body>What to replace the widget reference with</body> </widget>
where each subelement is a PythonMethod called by passing the node within the form and the root node of the form. Hence, they can edit the copy of the form by obtaining information from other nodes within the widget.
Finally, each widget can have a number of behaviours. Behaviours are like mix-in classes for javascript/dhtml. Currently behaviours include:
draggable - makes a piece of html draggable on both NS & IE scrollable - cross-browser / themable iframes on NS & IE path-xxx - same properties as a gif animation but move html around in a preprogrammed path. resizable - add a resize button to it
Example: to make a cross-browser, themable MDI window: <window name="mywin" behaviours="path-circle path-square resizeable".. theme="MyTheme"> This is a window </window>
to show it: <a href="javascript:mywin.show()">Show it</a>
to hide it: <a href="javascript:mywin.hide()">Show it</a>
to change the theme: edit the Theme object (not started yet but is just a collection of images with some dhtml sugar to provide easy editing of them)
So, in summary, VisualStudio merges javascript and Zope backend scripts into the same namespace. This is done by merging XML and javascript on both the sever and client. Future plans include porting the GPL DuoPath to create a Visual Basic style development environment with visual and xml style editing working side by side.
Cheers,
Anthony Pfrunder
PS Check out Dan Steinman's DHTML tutorial: http://www.dansteinman.com/dynduo The code is GPL (_NOT_ the tutorial itself) is where I get the javascript from.
Anthony Pfrunder wrote:
Hi,
Noting the recent release of the excellent XML Widgets of M.Faassen and the discussion on wysiwyg I thought I better pre-annouce my upcoming VisualStudio for Zope in case other people are working on the same thing.
[snip description]
Hm, I'm not sure I get it exactly yet, though what I do understand sounds exciting. The idea is that you abstract Javascript + HTML in XML, so that you can design advanced web pages in an abstract way, right? Please explain some of the applications you have in mind for this?
My XMLWidgets are quite different in the sense that a widget is a Python class, and widgets are used to display individual XML nodes (of whatever type you desire), and to respond to any events that occur in them.
Perhaps we can merge some of the ideas of XMLWidgets and VisualStudio together, though.
Another, somewhat related, topic that I've been investigating (coding will start shortly) is the creation of 'Formulator'. This would be an easy way to construct HTML forms (with database backend) in Zope. Basically you'd put a lot of form elements (such as textareas, input boxes, etc) in a folder. Each form element would know how to display itself and how to validate its own contents, both client side (java script) and server side (always necessary, in Zope). Some XML Document or somesuch can then be used to layout the form elements into a form. SQL methods should be automatically generated if desired.
If we could get all this GUI type work (XMLWidgets, VisualStudio, Formulator) into somekind of unified framework that is Zopish, that would be very nice. I don't have any clear clues on how to do this, however. :)
Did anybody install and try XMLWidgets yet? Did it work at all? :)
Regards,
Martijn
Sounds like XMLWidgets and VisualStudio have some similar ideas. Both sound great!
I really like the idea of building simpler and smarter ways to construct pages, rather than hard coding all the HTML.
The idea of smart web page widgets has been floating around for a while. I'd love to see it really take off.
In addition, if there was a more high level way of describing a page, it might be feasible to get something like a wxWindows client via XML-RPC (!).
Perhaps we can merge some of the ideas of XMLWidgets and VisualStudio together, though.
If we could get all this GUI type work (XMLWidgets, VisualStudio, Formulator) into somekind of unified framework that is Zopish, that would be very nice. I don't have any clear clues on how to do this, however. :)
This sounds very exciting.
Did anybody install and try XMLWidgets yet? Did it work at all? :)
Yes, and no.
It seems that the XMLWidget python product clashes with the XMLWidget imported Product... 'The id XMLWidgets is invalid - it is already in use.'
XMLWidgets sound very cool. I'd love to get them working and take a closer look.
In fact they remind me of something I posted to the bobo list a long time ago.
http://www.egroups.com/group/bobo/129.html
Oh, and take a look at this post mentioning widgets by Jim,
http://www.egroups.com/group/bobo/421.html
Wow, early 1998 seems like ancient history ;-) You've come a long way, Zope!
-Amos
On Thu, 30 Sep 1999, Amos Latteier wrote:
[snip snip]
Arrrggghhh! Sorry, some of my bugfixes and "enhancements" to the XML Document must have slipped through. Just change all references to toHTML to toXML until I get a chance to fix it :(. ToHTML is a one line mod to the Nodes.py which returns <xxx> instead of <xxx/> as Netscape hates tags with <xx/> in it. The system still should work but not be "pretty".
My upcoming ehancements include an implementation of namespaces for XML Doc. For details on why this is useful please refer to: http://www.w3.org/TR/REC-xml-names/. Basically, they allow you to embed one XML application within another and also add CDATA's etc to nodes automagically. Also, I want to add a mergeNodes method to take two nodes which are idential and merge them.
Finally, a proposal to add a new method to the Zope superclass. New will return an "empty", new instance of the class that is passed to it:
<dtml-call "REQUEST.set(listofnodes, [NodeRef.new()])">
where NodeRef is an existing node perhapes obtained by getElementsByTagName(). It is annoying to move to Products because ZClasses don't support creation of new instances.
Cheers,
Anthony Pfrunder
At 13:15 30/09/99 , Anthony Pfrunder wrote:
On Thu, 30 Sep 1999, Amos Latteier wrote:
[snip snip]
Arrrggghhh! Sorry, some of my bugfixes and "enhancements" to the XML Document must have slipped through. Just change all references to toHTML to toXML until I get a chance to fix it :(. ToHTML is a one line mod to the Nodes.py which returns <xxx> instead of <xxx/> as Netscape hates tags with <xx/> in it. The system still should work but not be "pretty".
Change them to <xxx /> (with space). That should work better.
-- Martijn Pieters, Web Developer | Antraciet http://www.antraciet.nl | Tel: +31-35-7502100 Fax: +31-35-7502111 | mailto:mj@antraciet.nl http://www.antraciet.nl/~mj | PGP: http://wwwkeys.nl.pgp.net:11371/pks/lookup?op=get&search=0xA8A32149 ------------------------------------------
I downloaded it and couldn't make head or tail of it. The files wanted to be named VisualStudio_Core and Examples. I sniffed them a figured they were .zexp, so I imported VisualStudio just fine into my Control Panel. I tried to import Examples but it said it was truncated. I tried twice.
It seems to me that if the Examples contain required material (it says 'required') that mabey they should become classes in the Product itself, and start to develop a 'standard' widget set. Widget's just smell like classes to me. Granted I have no idea how your Product works at this point, but I want to try it!
Can you and Martijn give quick 10,000 ft overviews of your products? I'm going to d/l martijn's right now.
-Michel
Michel Pelletier wrote:
you and Martijn give quick 10,000 ft overviews of your products? I'm going to d/l martijn's right now.
I haven't understood (or successfully installed, though I got further than you; no problem with the examples file) Anthony's product yet, but I do know my system is quite different. I do give a 10,000 ft overview of my system on the Zope site, there's release info and such. :)
Basically, I use special classes (widgets) together with a map XML-nodetype -> Widget to translate an XML Document into a HTML page, which then can define events that when activated (user clicking a hyperlink) go back to the right widget methods.
This to make very dynamic XML documents (which can be edited or otherwise manipulated).
Regards,
Martijn
On Thu, 30 Sep 1999, Michel Pelletier wrote:
I downloaded it and couldn't make head or tail of it. The files wanted to be named VisualStudio_Core and Examples. I sniffed them a figured they were .zexp, so I imported VisualStudio just fine into my Control Panel. I tried to import Examples but it said it was truncated. I tried twice.
Hmm, I think it uploaded correctly - I'll download it again and try it.
It seems to me that if the Examples contain required material (it says 'required') that mabey they should become classes in the Product itself, and start to develop a 'standard' widget set. Widget's just smell like classes to me. Granted I have no idea how your Product works at this point, but I want to try it!
Ahh, that was a design decision! I _HATE_ having to make things via the Control Panel because you cannot tailor it. For example, say you have:
Zope + Marketing + Accounts
Zope contains company wide "widgets" while Marketing and Accounts each contain "widgets" applicable to their areas. In additional, people can have permissions to use and add widgets. A "widget" object is like a zclass and it is instanced within a form via: <widget parameters></widget>
Can you and Martijn give quick 10,000 ft overviews of your products? I'm going to d/l martijn's right now.
I've fixed it - it should work now!
10,000 ft overview? Think Visual Basic and Frontpage through the browser using cross-browser javascript. See my previous posts for more detail. VisualStudio is just a dump of an actively developed product.
PS: I'm getting a few emails that people cannot see VisualStudio under the "Products" page on zope.org. Anyone else have this problem?
-Michel
Zope-Dev maillist - Zope-Dev@zope.org http://www.zope.org/mailman/listinfo/zope-dev
(Related lists - please, no cross posts or HTML encoding!
To receive general Zope announcements, see: http://www.zope.org/mailman/listinfo/zope-announce
For non-developer, user-level issues, zope@zope.org, http://www.zope.org/mailman/listinfo/zope )
Cheers,
Anthony Pfrunder Computer Systems Engineering University of Queensland