1
0
mirror of git://projects.qi-hardware.com/fped.git synced 2024-09-30 17:24:47 +03:00
Commit Graph

243 Commits

Author SHA1 Message Date
Werner Almesberger
86c082f5a9 track bounding box also on a per-package basis and use this to scale Postscript
Until now, everything used the bounding box of the root frame which
contains all the packages, visible or not. We now also record what
ends up in which package, allowing inst_get_bbox to return the
bounding box of a specific package.

This is mainly useful for scaling Postscript output where only one
package is printed per sheet and there is not much point in reserving
space for any other packages that may be generated from the same
footprint definition.
2012-07-12 17:40:31 -03:00
Werner Almesberger
e2ce0eecf7 inst.c: zero-sized pads and holes now cause instantiation to fail
Before, they were silently ignored but still included in output.
This produced invalid Postscript (attempts to fit the pad name into
the zero-sized pad failed) and may also have produced artefacts
that could confuse KiCad.
2012-07-12 16:21:59 -03:00
Werner Almesberger
59b90b3054 reset reachable_pkg in the instantiation process and restore on inst_revert
Before, it was reset outside and not restored when instatiation failed.
This caused fped to segfault.
2012-05-28 23:58:05 -03:00
Werner Almesberger
5d76af2d7c make variable type changes also commit the value (name) being edited
This streamlines the workflow.
2012-05-28 12:15:15 -03:00
Werner Almesberger
f2d3986600 fix whitespace anomalies
/ \t/, / $/, and /\t$/
2012-05-28 03:11:15 -03:00
Werner Almesberger
4c3dea7111 support switching variables between assignment and key (WIP)
This is a little awkward: to change a variable used as key to an
assignment, one first had to change the name such that it doesn't
clash, hit Enter, and then edit the variable again to change its
type.

Variable type changes should pick up the edit in progress and allow
a type change to also imply acceptance of the variable.
2012-05-28 02:54:50 -03:00
Werner Almesberger
326a480b63 gui_frame.c: display a question mark before variables used as key 2012-05-28 02:53:01 -03:00
Werner Almesberger
101bd11c98 test/tsort: fix permission (wasn't excecutable) 2012-05-27 22:14:00 -03:00
Werner Almesberger
3488cf80ec introduce keyed tables (?var syntax; WIP)
This cannot be set/changed through the GUI yet.
2012-05-27 22:14:00 -03:00
Werner Almesberger
3c39600c1c add %iprint, to track variables during instantiation 2012-05-27 22:14:00 -03:00
Werner Almesberger
91154440a3 test/floor: add two real-life-like rounding problems (mil to mm) 2012-05-26 20:10:26 -03:00
Werner Almesberger
9a6c7d2742 add floor() function 2012-05-26 14:13:58 -03:00
Werner Almesberger
e0351bdf73 make active package track active variables (for the GUI)
If the package whose name is produced by the active variable values
is active and the variables change, then make the newly active
package the one whose name is produced by the changed variables.

This way, iterating through a table or a loop will automatically
switch to the right package, with the exception that, if the user
choses to explicitly select a different package (by clicking on
its name in the packages line), then that selection takes priority.

Explicit selection loses its priority when active package and active
variables coincide again. I.e., one can simply "catch" the active
package by activating the corresponding values.
2012-05-25 19:20:29 -03:00
Werner Almesberger
b06ed92557 inst.h (FOR_PKG_INSTS): protect against active_pkg == NULL
active_pkg can become NULL if the root frame contains a loop that
will never execute, i.e., loop x = 1, 0

This caused fped to segfault when FOR_PKG_INSTS was called from
FOR_ALL_INSTS in inst_draw.
2012-05-25 18:21:09 -03:00
Werner Almesberger
424b74e482 change use of curly braces with "if-else" to kernel style 2012-05-25 13:33:54 -03:00
Werner Almesberger
6623ae198f Makefile: generate dependencies also for YACC- and LEX-generated files
We need explicit rules to compile lex.yy.c and y.tab.c for the relaxed
CFLAGS. However, this means that the implicit rule was not used and
therefore no dependencies were generated.
2012-05-22 16:20:54 -03:00
Werner Almesberger
6547384793 fpd.l: make start_token "static" 2012-04-26 02:55:45 -03:00
Werner Almesberger
43928dbbf3 purge unused measurement instances
Instances of measurements referencing vectors not instantiated were
only partially initialized (because only inst_meas_hint was called
on them but never inst_meas) but still left in the list of instances.

They were thus displayed, producing confusing results.

We now trace a measurement instance's validity and remove all invalid
instances at the end of instantiate_meas.
2012-03-17 23:14:16 -03:00
Werner Almesberger
5130707371 postscript.c (ps_for_all_pkg): "pages" was never initialized 2012-03-17 23:05:05 -03:00
Werner Almesberger
e2749ea6c5 don't draw center cross in full-page Postscript 2012-01-18 16:10:22 -03:00
Werner Almesberger
cb34a28826 vector names can now be resolved at instantiation (partially implemented) 2011-10-25 17:03:21 -03:00
Werner Almesberger
c8f5d29178 obj.c: move vector to coord translation to separate function (for future extension) 2011-10-25 16:22:04 -03:00
Werner Almesberger
ea9b8f988e already "fped -T" dumped, not only "fped -T -T". test/Common didn't use -T -T. 2011-10-25 16:05:22 -03:00
Werner Almesberger
b8f1add539 fped/obj.c (generate_items): handle failure to expand package name gracefully
We just use "_" in this case. Before, "expand" returned NULL, which
inst_select_pkg interprets as the global package. This in turn caused
no further packages to be defined and thus active_pkg stayed NULL.
This finally led to a crash in inst_draw.
2011-09-14 20:37:54 -03:00
Werner Almesberger
6dfbb51af9 fped/gnuplot.c (gnuplot_arc): implemented drawing of arcs 2011-09-12 20:54:58 -03:00
Werner Almesberger
e5d8fd87c3 fped/: added gnuplot output for line/rect/circle with -g (experimental) 2011-09-04 20:35:34 -03:00
Werner Almesberger
6ca5c22ea4 fped.c: cleaned up batch mode selection; batch modes are now mutually exclusive 2011-09-04 17:22:10 -03:00
Werner Almesberger
f0c0ae779a changed GUI page location, checkout instructions, and e-mail address
- Makefile (UPLOAD), README, debian/control (Homepage, Description),
  fped.1: the GUI page is now on downloads.qi-hardware.com instead
  of people.openmoko.org
- debian/copyright, fped.1: changed e-mail from werner@openmoko.org
  to werner@almesberger.net
- README: changed repository from Openmoko SVN to Qi-Hardware git
2011-07-28 06:40:46 -03:00
Werner Almesberger
9465776449 xxx 2011-07-28 06:40:46 -03:00
Werner Almesberger
6cadac8977 Makefile: switched from SVN to git
- Makefile (CFLAGS): renamed cpp macro SVN_VERSION to VERSION
- Makefile (SVN_VERSION, SVN_STATUS): renamed to GIT_VERSION and
  GIT_STATUS and switched to corresponding git command
- Makefile (.PHONY, update): removed this little-used target
2011-07-28 06:40:34 -03:00
Xiangfu Liu
6396ca8499 update to r6006 2011-03-25 08:50:51 +08:00
Xiangfu Liu
acccaee4d6 update to r6005 2011-03-25 08:42:36 +08:00
Xiangfu Liu
a49bbd2fe6 debian package update to 5999 2011-03-25 08:42:36 +08:00
Xiangfu Liu
ceaa519ccb update to r5997
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
4a68274e67 update the homepage to help webpage
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
ced96bbb13 add ghostscript to Build-Depends
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
5ac0cb58d8 override dh_auto_clean, use make spotless instread
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
5fa6038c07 update to svn rev 5986
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
21f2ae2bb5 remove the Build-Depends ttf-liberation
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
a6d21bb4bb update take svn rev: 5983
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
069e82ffc4 use usual name for orig tarball top-level directory
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
17dc8ff45c update to svn rev 5982, enable dh_auto_test
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
b9a6369ca2 add debian/fped.manpages for install manpage
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
b17ed1a7df use the new version rules.
add the get-orig-source.sh file

Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:36 +08:00
Xiangfu Liu
e394af8c90 clean up the Build-Depends.
Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:35 +08:00
Xiangfu Liu
b6807a7c0d add debian package stuff
add ITP bug number to 'debian/changelog'

Signed-off-by: Xiangfu Liu <xiangfu@sharism.cc>
2011-03-25 08:42:35 +08:00
werner
78e4ba0d9c fped: mechanical holes had incorrect layers
- inst.c (inst_hole): set inst->u.hole.layers, not inst->u.pad.layers
- layer.c (mech_hole_layers): holes don't need solder paste



git-svn-id: http://svn.openmoko.org/trunk/eda/fped@6006 99fdad57-331a-0410-800a-d7fa5415bdb3
2011-03-24 23:42:47 +00:00
werner
335ddb6e1d fpd.y: dump() requires a dummy "one" argument here too, oops
git-svn-id: http://svn.openmoko.org/trunk/eda/fped@6005 99fdad57-331a-0410-800a-d7fa5415bdb3
2011-03-23 08:25:22 +00:00
werner
2de385e9c7 hack: set errno to ENOENT when -1 fails, so that the error isn't too ugly
The caller assumes that any error would be signaled via errno. A proper
solution would be to allow also for non-errno errors.



git-svn-id: http://svn.openmoko.org/trunk/eda/fped@6004 99fdad57-331a-0410-800a-d7fa5415bdb3
2011-03-23 08:07:31 +00:00
werner
f44accdad7 fped: added option -1 package to select a single package to output with -p/-P
git-svn-id: http://svn.openmoko.org/trunk/eda/fped@6003 99fdad57-331a-0410-800a-d7fa5415bdb3
2011-03-23 07:14:13 +00:00