Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-28 Thread Russell Oliver
Thanks everyone for your input. First off, I too think it will get the most usage in the footprint editor, specifically when calculating the position and size of a pad from cryptic datasheet dimensions. I chose the schematic value entry dialog simply because its a small target. But even having

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-28 Thread Michael Geselbracht
Incidentally I have written a similar calculator last week and included it in Pcbnew. I used the lemon parser generator but exprtk might be a better choice. That way it should be easy to extend the calculator with support for variables without re-inventing the wheel. I wanted to mimick the

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-28 Thread hauptmech
or perhaps the python parser is already used in enough kicad builds that it should be used? On 28/08/17 19:56, Tomasz Wlostowski wrote: On 27.08.2017 22:28, Marco Ciampa wrote: +1 muparser is already present in many distros: apt-cache search muparser libmuparser-dev - fast mathematical

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-28 Thread Wayne Stambaugh
On 8/28/2017 3:55 AM, Tomasz Wlostowski wrote: > On 27.08.2017 17:03, Russell Oliver wrote: >> Hi all, >> >> Attached is a patch that allows for the use of a mathematical expression >> when editing the value field of components in Eeschema. >> >> If editing the value field and the entered string

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-28 Thread Tomasz Wlostowski
On 27.08.2017 22:28, Marco Ciampa wrote: > +1 muparser is already present in many distros: > > apt-cache search muparser > libmuparser-dev - fast mathematical expressions parse library (development) > libmuparser-doc - fast mathematical expressions parser library (documentation) > libmuparser2v5

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-28 Thread Tomasz Wlostowski
On 27.08.2017 17:03, Russell Oliver wrote: > Hi all, > > Attached is a patch that allows for the use of a mathematical expression > when editing the value field of components in Eeschema. > > If editing the value field and the entered string begins with an equals > sign "=" as you would when

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-27 Thread Marco Ciampa
On Sun, Aug 27, 2017 at 04:06:50PM -0400, David Novak wrote: > On 8/27/2017 11:03 AM, Russell Oliver wrote: > >Hi all, > > > >Attached is a patch that allows for the use of a mathematical expression > >when editing the value field of components in Eeschema. > > > >If editing the value field and

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-27 Thread David Novak
You might consider muparser. David On 8/27/2017 11:03 AM, Russell Oliver wrote: Hi all, Attached is a patch that allows for the use of a mathematical expression when editing the value field of components in Eeschema. If editing the value field and the entered string begins with an equals

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-27 Thread Greg Smith
Anyone know how to expose this to python? Maybe incorporate https://pypi.python.org/pypi/cexprtk/0.2.0 ? Greg S. > On Aug 27, 2017, at 10:03 AM, Russell Oliver wrote: > > ExprTk ___ Mailing list:

Re: [Kicad-developers] [RFC] Proof of concept of mathematical expression input for text fields.

2017-08-27 Thread Marcos Chaparro
I don't see myself using it in eeschema, but having this in the footprint editor or pcbnew would be awesome. Calculating the (x,y) of a pad often requires some simple math. Freecad has this kind of math parser, very useful. Marcos On Sun, Aug 27, 2017 at 12:03 PM, Russell Oliver