Re: gnome-config problems



Miroslav Silovic wrote:
> 
> Jason Gilbert <jason@scott.net> writes:
> 
> > <panel>
> >    <param name=bgcolor value=grey>
> >    <menu name=main label="Main Menu">
> >      <li>
> >        <menu name="Programs">
> >          <li><program name=netscape label="Netscape"
> > exec="/opt/bin/netscape">
> >          <li><program name=gimp label="The Gimp" exec="/usr/bin/gimp">
> >        </menu>
> >      <li><a href=applet#logout> //you could allow references to other
> > config info
> >                                 //in the same file.
> >    </menu>
> >    <applet name=clock>
> >      <param name=whatever value=something>
> >    </applet>
> >    <applet name=menu>
> >      <param name=whatever value=somethingelse>
> >    </applet>
> >    <applet name=logout>
> >      <a href="panel.ghtml">Logout</a> //hyper link to external config
> > file for the
> >                                       // logout applet
> >    </applet>
> > </panel>
> >
> > Obviously, this is not a literal example;^), but just the jist.
> > It may not even be feasible.  Just a thought to run up the proverbial
> > flag pole.  I hope the spacing doesn't get all screwed.
> >
> > jason
> 
> Equivalent Scheme code:
> 
> '(panel
>   (param bgcolor grey)
>   (menu main "Main Menu"
>         (menu programs "Programs"
>               (program netscape "Netscape" "/opt/bin/netscape")
>               (program gimp "Gimp" "/usr/bin/gimp"))
>         (link (applet logout)))
>   (applet clock
>           (param whatever something))
>   (applet menu
>           (param whatever something))
>   (applet logout
>           (link "panel.guile" Logout)))
> 
> Beside being twice shorter,

The only reason it's shorter is b/c you don't have names for options.
See other post regarding this issue.  I would trade length for clarity
any day seeing as how I can't imagine a single config file growing
larger than any of the current config files.  Hopefully, a 20k config
file won't overrun your system;^)

> 5 times less redundant,

I guess the redundency is the clarity of the option names?

> trivial to parse,
> and easy to machine-generate, 

How many web browsers are out there now?
How many people are dynamically generating HTML on the fly w/ cgi?

> everything you need to deal with this
> type of config is guile, and guile is already a part of GNOME.

XmHTML

jason

-- 
Jason Gilbert | http://www.scott.net/~jason/ | http://www.mantissa.com/

"The total job will be in the software, and we'll be able to write big
fat programs. We can let them run somewhat inefficiently because there
will be so much horsepower that just sits there. The real focus won't
be who can cram it down in, or who can do it in machine language. It
will be on who can define the right user interface and properly
integrate the main packages." -- Bill Gates, PC Magazine 1982



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