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

gEDA-cvs: branch: master updated (1.1.2.20070818-81-gde2f3d2)



The branch, master has been updated
       via  de2f3d240562202f305a0ba1a8d58f2ba78a3876 (commit)
       via  80a51f9d4faa5cbeb3222046bdf67f11b34114ef (commit)
      from  903db04d2174415fcc6ec6c0e7321d914a25b259 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.


=========
 Summary
=========

 utils/examples/tragesym/4099.src     |   14 +++++++++-----
 utils/examples/tragesym/template.ods |  Bin 18834 -> 24200 bytes
 utils/examples/tragesym/template.src |    4 ++--
 utils/scripts/tragesym               |   31 +++++++++++++++++++++----------
 4 files changed, 32 insertions(+), 17 deletions(-)


=================
 Commit Messages
=================

commit de2f3d240562202f305a0ba1a8d58f2ba78a3876
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Tue Oct 16 19:38:25 2007 +0200

    Misc corrections for tragesym spacer support
    
    remove spacers if the pinlabels are sorted
    don't add pinseq at spacers
    modified example to use the spacer support

:100644 100644 c35f837... 5c1913e... M	utils/examples/tragesym/4099.src
:100755 100755 4c27559... 6a592ca... M	utils/scripts/tragesym

commit 80a51f9d4faa5cbeb3222046bdf67f11b34114ef
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Tue Oct 16 18:58:43 2007 +0200

    Added spacer feature to tragesym
    
    A spacer line will put a gap between two pins.
    Patch written by Gilbert Forkel. Thanks

:100644 100644 f414b79... 3e2a99f... M	utils/examples/tragesym/template.ods
:100644 100644 4e507c3... 27c35bc... M	utils/examples/tragesym/template.src
:100755 100755 9becd83... 4c27559... M	utils/scripts/tragesym

=========
 Changes
=========

commit de2f3d240562202f305a0ba1a8d58f2ba78a3876
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Tue Oct 16 19:38:25 2007 +0200

    Misc corrections for tragesym spacer support
    
    remove spacers if the pinlabels are sorted
    don't add pinseq at spacers
    modified example to use the spacer support

diff --git a/utils/examples/tragesym/4099.src b/utils/examples/tragesym/4099.src
index c35f837..5c1913e 100644
--- a/utils/examples/tragesym/4099.src
+++ b/utils/examples/tragesym/4099.src
@@ -5,7 +5,7 @@
 [options]
 wordswap=yes
 rotate_labels=no
-sort_labels=yes
+sort_labels=no
 generate_pinseq=yes
 sym_width=1400
 pinwidthvertical=400
@@ -36,13 +36,16 @@ numslots=0
 #-----------------------------------------------------
 #pinnr	seq	type	style	posit.	net	label	
 #-----------------------------------------------------
-1		out	line	r		Q7
-2		in	line	l		Clear
-3		in	line	l		D
-4		in	dot	l		\_E\_
 5		in	line	l		A0
 6		in	line	l		A1
 7		in	line	l		A2
+			spacer	l
+3		in	line	l		D
+			spacer	l
+2		in	line	l		Clear
+			spacer	l
+			spacer	l
+4		in	dot	l		\_E\_
 8		pwr	none		VSS
 9		out	line	r		Q0
 10		out	line	r		Q1
@@ -51,4 +54,5 @@ numslots=0
 13		out	line	r		Q4
 14		out	line	r		Q5
 15		out	line	r		Q6
+1		out	line	r		Q7
 16		pwr	none		VDD
diff --git a/utils/scripts/tragesym b/utils/scripts/tragesym
index 4c27559..6a592ca 100755
--- a/utils/scripts/tragesym
+++ b/utils/scripts/tragesym
@@ -31,7 +31,7 @@
 import sys, string
 
 ##################### GLOBALS ############################################
-VERSION="0.0.11"
+VERSION="0.0.12"
 
 CHARHIGH=26
 preset_options = {"wordswap":"yes",
@@ -160,12 +160,12 @@ def readsrc(filename):
 
 def checkpins(pinlist):
     for pin in pinlist:
-    	if (pin[P_STYLE]=="spacer"):
-	    if (pin[P_POS] == ""):
-		print "There must be a position with a spacer.\n"
+    	if pin[P_STYLE] == "spacer":
+	    if pin[P_POS] == "":
+		print "Error: There must be a position with a spacer.\n"
 		sys.exit()
 	    if pin[P_POS] not in poslist:
-		print "Position is not allowed: \n", pin
+		print "Error: position is not allowed: \n", pin
 		sys.exit()
     	    continue
         if pin[P_STYLE] != "none":
@@ -350,7 +350,10 @@ def writesym(filename,options,attr,pins):
         if pin[P_STYLE] == "none": #
             continue
         if pin[P_STYLE]=="spacer":
-            if pin[P_POS] == "l": #left pin
+            if o_sort == "yes":
+                print "warning: spacers are not supported when sorting labels"
+                continue
+            elif pin[P_POS] == "l": #left pin
                 plefty=plefty - o_vdist  #where to draw the _next_ pin
             elif pin[P_POS] == "r": #right pin
                 prighty=prighty - o_vdist
@@ -358,7 +361,7 @@ def writesym(filename,options,attr,pins):
                 pbottomx=pbottomx + o_hdist
             elif pin[P_POS] == "t": # top pin
                 ptopx=ptopx + o_hdist
-            continue;
+            continue
 ### decide which pindirection to use
         ## TODO: put all constants into a dictionary         
         if pin[P_POS] == "l": #left pin
@@ -563,7 +566,7 @@ def mergeoptions(source_opt,pre_opt):
 def generate_pinseq(pins):
     seq=1
     for nr in xrange(len(pins)):
-        if pins[nr][P_STYLE] != "none":
+        if pins[nr][P_STYLE] not in ["none","spacer"]:
             pins[nr][P_SEQ] = "%i"%seq
             seq = seq + 1
     return pins

commit 80a51f9d4faa5cbeb3222046bdf67f11b34114ef
Author: Werner Hoch <werner.ho@xxxxxx>
Date:   Tue Oct 16 18:58:43 2007 +0200

    Added spacer feature to tragesym
    
    A spacer line will put a gap between two pins.
    Patch written by Gilbert Forkel. Thanks

diff --git a/utils/examples/tragesym/template.ods b/utils/examples/tragesym/template.ods
index f414b79..3e2a99f 100644
Binary files a/utils/examples/tragesym/template.ods and b/utils/examples/tragesym/template.ods differ
diff --git a/utils/examples/tragesym/template.src b/utils/examples/tragesym/template.src
index 4e507c3..27c35bc 100644
--- a/utils/examples/tragesym/template.src
+++ b/utils/examples/tragesym/template.src
@@ -48,8 +48,8 @@ numslots=0
 # pinnr is the physical number of the pin
 # seq is the pinseq= attribute, leave it blank if it doesn't matter
 # type can be (in, out, io, oc, oe, pas, tp, tri, clk, pwr)
-# style can be (line,dot,clk,dotclk,none). none if only want to add a net
-# posit. can be (l,r,t,b) or empty for nets
+# style can be (line,dot,clk,dotclk,spacer,none). none if only want to add a net
+# posit. can be (l,r,t,b) or empty for nets.
 # net specifies the name of the net. Vcc or GND for example.
 # label represents the pinlabel.
 #	negation lines can be added with "\_" example: \_enable\_ 
diff --git a/utils/scripts/tragesym b/utils/scripts/tragesym
index 9becd83..4c27559 100755
--- a/utils/scripts/tragesym
+++ b/utils/scripts/tragesym
@@ -49,7 +49,7 @@ single_attr_warning = ["device", "footprint", "author", "documentation",
                        "description", "numslots","dist-license", "use-license"]
 single_attr = ["slot"]
 multiple_attr = ["slotdef", "comment"]
-stylelist = ["line","dot","clk","dotclk","none"]
+stylelist = ["line","dot","clk","dotclk","spacer","none"]
 poslist = ["l","r","t","b",""]
 typelist = ["in","out","io","oc","oe","pas","tp","tri","clk","pwr"]
 P_NR, P_SEQ, P_TYPE, P_STYLE, P_POS, P_NET, P_LABEL = 0,1,2,3,4,5,6
@@ -304,7 +304,7 @@ def writesym(filename,options,attr,pins):
     calculated_top_symwidth=(numptop-1)*o_hdist+2*o_hdist
     calculated_bottom_symwidth=(numpbottom-1)*o_hdist+2*o_hdist
     
-    calcutated_symwidth = max(calculated_bottom_symwidth,
+    calculated_symwidth = max(calculated_bottom_symwidth,
                               calculated_top_symwidth)
 
     if (numptop + numpbottom > 0):
@@ -349,6 +349,16 @@ def writesym(filename,options,attr,pins):
     for pin in pins:
         if pin[P_STYLE] == "none": #
             continue
+        if pin[P_STYLE]=="spacer":
+            if pin[P_POS] == "l": #left pin
+                plefty=plefty - o_vdist  #where to draw the _next_ pin
+            elif pin[P_POS] == "r": #right pin
+                prighty=prighty - o_vdist
+            elif pin[P_POS] == "b": # bottom pin
+                pbottomx=pbottomx + o_hdist
+            elif pin[P_POS] == "t": # top pin
+                ptopx=ptopx + o_hdist
+            continue;
 ### decide which pindirection to use
         ## TODO: put all constants into a dictionary         
         if pin[P_POS] == "l": #left pin
@@ -406,8 +416,6 @@ def writesym(filename,options,attr,pins):
                 negl=(0,20,1,0)
                 swap=0
             ptopx=ptopx + o_hdist
-        if (pin[P_STYLE]=="spacer"):
-            continue
 ### draw the pin
         if (pin[P_STYLE]=="dot" or  #short pin and dot?
             pin[P_STYLE]=="dotclk"):




_______________________________________________
geda-cvs mailing list
geda-cvs@xxxxxxxxxxxxxx
http://www.seul.org/cgi-bin/mailman/listinfo/geda-cvs