chiark / gitweb /
make AADEPTH configurable
[ypp-sc-tools.db-test.git] / pctb / dictionary-manager
index 365aecb01fb1184fc865faa979ae58bba551ff81..7091964c779a6eb6f09989a2ea44e275a5826fff 100755 (executable)
@@ -42,6 +42,9 @@
 #  if it wrote a byte to fd 4, it can take another question
 
 
+set aadepth 3
+
+
 #---------- library routines ----------
 
 proc manyset {list args} {
@@ -898,7 +901,7 @@ proc recursor {} {
 
 # $database($context 0x<bits> 0x<bits>...) = $hex
 
-set database_magic/char {# ypp-sc-tools pctb font v2}
+set database_magic/char "# ypp-sc-tools pctb font v3 depth=$aadepth"
     
 proc read_database_header/char {f} {
     global rows
@@ -1134,10 +1137,10 @@ proc chop_counted {var} {
 }
 
 proc approve_decompose_data {specdata} {
-    global data
+    global data aadepth
     set data $specdata
     
-    regsub-data {^ypp-sc-tools dictionary update v2\n} {}
+    regsub-data "^ypp-sc-tools dictionary update v3 depth=$aadepth\\n" {}
     uplevel 1 chop_counted pirate
     uplevel 1 chop_counted caller
     uplevel 1 chop_counted dict