The more I look at the source code for vcl, the more I am beginning to
dislike it.... And I'm looking at some of the other XML-based UI languages
available and none of them really seem adequate to describe any kind of a
major UI overhaul that would keep LibreOffice up to date with other office
suites....

So here's just a general idea I've had on XML layouts for quite a while -
let me know what you think!

Essentially, there would be three basic types of UI elements: layouts,
widgets, and references.  Layouts determine how whatever is inside them
'flows'.  Widgets are the actual parts that are interactive or informative
and may be defined by other xml files.  Finally, references just include
other defined pieces of the XML code.  Any programmatic interaction is done
by accepting clicks, etc. from the widgets.
So a sample of an OK dialog might be:

<layout:vertical id="promptdialog" title="Prompt For OK" flow="fill">

<layout:vertical id="textcontainer" flow="top left">

<widget:text id="promptvalue">Click OK here!</widget:text>

</layout:vertical>

<layout:horizontal flow="right">

<widget:button value="OK" id="okbutton" />
<widget:button value="Cancel" id="cancelbutton" />

</layout:horizontal>

<layout:vertical>

and in the compiled code, one might see:
Dialog promptdialog = new Dialog("promptdialog.xml");
((ButtonWidget) promptdialog.getById("okbutton")).onClick() = new
function(){
/** Handle clicks here **/
};

and that would basically be it.  Any thoughts?

Yours Truly,
Scott R. Pledger


On Fri, Apr 29, 2011 at 10:11, Christoph Noack <christ...@dogmatux.com>wrote:

> Hi Kohei, hi Scott!
>
> Kohei, thanks for the helpful information here ... great that you're
> listening here (especially since I know your workload...)!
>
> Am Freitag, den 29.04.2011, 10:25 -0400 schrieb Kohei Yoshida:
> > On Thu, 2011-04-28 at 23:15 -0600, Scott Pledger wrote:
> > > Is there any chance of implementing any kind of an XML-based UI
> template?
> > >  Something similar to XUL may be a good place to start...
> >
> > We don't have any concrete vision of what the VCL replacement should
> > look like, but making UI definition files XML-based is surely a sane
> > approach.  In fact, when we attempted to replace it at one point, we did
> > use an XML-based UI definition format.  Some of these files are still
> > around in the code base though we are on their way out.
> >
> > So, yeah, XML-based UI definition format is very likely.
>
> As far as I know, there have been several attempts to solve this issue.
> For example, at the OOoCon 2010 I attended a presentation related to XML
> based UI declaration ...
>
> http://www.ooocon.org/index.php/ooocon/2010/paper/view/199
> (see also the presentation download)
>
> Sun/Oracle also thought about that ... during my visit in Hamburg early
> 2010, we discussed how e.g. toolpanes might ideally behave - some
> improvements about what we have today. Here, "ideally" mainly refers to
> its technical behavior to detach/attach them anywhere. In this
> discussion, XML based UI stuff was mentioned as well. Here is the blog
> post - no technical relevance, but maybe interesting:
>
> http://uxopenofficeorg.blogspot.com/2010/01/ux-meeting-in-hamburg-day-two.html
>
> Cheers,
> Christoph
>
> PS: You may have noticed that my availability is a bit bad at the
> moment ... so sorry for not commenting the other threads at the moment
> "in time".
>
>
> --
> Unsubscribe instructions: E-mail to design+h...@libreoffice.org
> Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
> List archive: http://listarchives.libreoffice.org/www/design/
> All messages sent to this list will be publicly archived and cannot be
> deleted
>

-- 
Unsubscribe instructions: E-mail to design+h...@libreoffice.org
Posting guidelines + more: http://wiki.documentfoundation.org/Netiquette
List archive: http://listarchives.libreoffice.org/www/design/
All messages sent to this list will be publicly archived and cannot be deleted

Reply via email to