[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: gEDA-dev: Proposal for a gschem Tools menu for list of scripts
Hi Dan McMahill, Peter Clifton and ALL,
Thank you very much for your inputs.
Please don't worry, we are not trying to re-invent
a new config format, we were using a descriptive
way of expressing what we plan to do. Al Davis
was merely using that to describe clearly the concept.
If you read Al Davis message:
>> It could use a scheme-like syntax and be just as clear.
and my previous my message:
>> (actual format can be in scheme code calling
>> a generic popup SCM)
Plan is to do it the usual gEDA way, and do it right:
scheme -- SCM -- GTK
If I am not mistaken, Al Davis is already working
on it. If not, you are more than welcome to give
it a try, and we will be more than grateful to you
for that.
Best Regards,
Paul Tan
-----Original Message-----
From: Dan McMahill <dan@mcmahill.net>
To: gEDA developer mailing list <geda-dev@moria.seul.org>
Sent: Sat, 24 Nov 2007 8:41 am
Subject: Re: gEDA-dev: Proposal for a gschem Tools menu for list of
scripts
Peter Clifton wrote:
> On Fri, 2007-11-23 at 15:30 -0500, Paul Tan wrote:
>> Hi Al Davis,
>>
>> I forgot to mention, if we only need the filename
>> as a parameter, the current menu already can
>> accomodate it, since there is already a scheme
>> function for it. It is the multiple parameters
>> which I am thinking about to accomocate.
>> Thanks again.
>
> PCB has a feature similar to this in its exporters. The exporter
defines
> a number of parameters and validation checks for them, which are
> prompted for in a UI.
>
> Auto generation of dialogs doesn't always lend its-self to well
> designed / structured GUI, but for many purposes, the utility
outweighs
> the need for a specifically designed dialog. (Like printer settings
> in .ppd file, for example). We could provide a function to do similar,
> and a guile binding for it to be used from menu items as needed.
>
> It should in theory be possible for scheme code "plugins" to make GUIs
> using guile-gtk if more complexity is needed, although I have never
> tried it.
>
> Dont re-invent more config file formats for now, use the existing
scheme
> code for adding menus, calling a scheme procedure to do your bidding.
> With appropriate helper functions, this won't necessitate lots of code
> duplication for each menu item.
take a look at the pcb.scm file in gschem/scheme/pcb.scm. You can
uncomment the loading of it in your gafrc/gschemrc. That adds a pcb
menu and shows how to do some callbacks that will for example launch
pcb
and perhaps gsch2pcb (can't recall offhand). To help support that, I
was working on a small set of core routines that you'd want to quickly
build support for pcb or whatever other simulator or layout backend you
might want to use. As part of this, I started down the path of
implementing something like the generic HID attribute editor that pcb
uses to build the export dialog boxes. I didn't quite finish.
As for guile-gtk, that is really a deadend right now, it is old and
unmaintained. I think there is something similar but pulls in a bunch
of gnome stuff. From my point of view I didn't really want just a
wrapper around low-level gtk calls anyway. I wanted to just support a
few basic things like:
- file select dialog box
- message dialog box
- attribute editor dialog (used for things like configuring a simulator
or something to do with a pcb project).
- confirmation dialog box
- write to the gschem log
With the exception of the attribute editor, I've implemented all of
these in the following guile functions: gschem-log, gschem-msg,
gschem-filesel, gschem-confirm
pcb.scm file demonstrates the use as well as adding a new menu to
gschem. pcb.scm also implements cross probing between schematic and
layout. In other words, you can select an instance in one tool and the
other tool will select the corresponding element.
Using scheme isn't too bad especially if you have an example to work
from. Dropping to a less capable file format probably doesn't buy much
and certainly loses capability.
-Dan
_______________________________________________
geda-dev mailing list
geda-dev@moria.seul.org
http://www.seul.org/cgi-bin/mailman/listinfo/geda-dev
________________________________________________________________________
Check Out the new free AIM(R) Mail -- Unlimited storage and
industry-leading spam and email virus protection.
_______________________________________________
geda-dev mailing list
geda-dev@moria.seul.org
http://www.seul.org/cgi-bin/mailman/listinfo/geda-dev