TeX 3.0 (message 4 of 5) This is the second of three patch sets to bring TeX 2.993 files up to TeX version 3.0. It assumes you have applied the patches in message 2 (or already had those changes in your files). Give patch the "-p" flag to indicate how many components of pathnames should be ignored. Generally, "patch -p0" should be used. diff -rc1 ../old/mf/mf.web ./mf/mf.web *** ../old/mf/mf.web Mon Jan 22 10:05:16 1990 --- ./mf/mf.web Sun Mar 25 13:08:17 1990 *************** *** 20,21 **** --- 20,22 ---- % Version 1.9 improved skimping and was edited for style (December 1989). + % Version 2.0 fixed bug in addto; released with TeX version 3.0 (March 1990). % A few "harmless" optimizations have been made without changing versions. *************** *** 22,26 **** ! % A reward of $40.96 will be paid to the first finder of any remaining bug, ! % except bugs introduced in October 1989. ! % (This amount will double again in 1990.) --- 23,26 ---- ! % A reward of $81.92 will be paid to the first finder of any remaining bug, ! % except bugs introduced after August 1989. *************** *** 152,154 **** ! @d banner=='This is METAFONT, Version 1.9' {printed when \MF\ starts} --- 152,154 ---- ! @d banner=='This is METAFONT, Version 2.0' {printed when \MF\ starts} *************** *** 931,932 **** --- 931,936 ---- be given. The following code uses concepts that will be explained later. + (If the \PASCAL\ compiler does not support non-local |@!goto|, the + @^system dependencies@> + statement `|goto final_end|' should be replaced by something that + quietly terminates the program.) *************** *** 1701,1703 **** @ The |jump_out| procedure just cuts across all active procedure levels and ! goes to |end_of_MF|. This is the only nonlocal |@!goto| statement in the whole program. It is used when there is no recovery from a particular error. --- 1705,1707 ---- @ The |jump_out| procedure just cuts across all active procedure levels and ! goes to |end_of_MF|. This is the only nontrivial |@!goto| statement in the whole program. It is used when there is no recovery from a particular error. *************** *** 8629,8631 **** @!cur_pen:pointer; {an implicit input of |make_spec|, used in autorounding} ! @!cur_path_type:double_path_code..also_code; {likewise} @!max_allowed:scaled; {coordinates must be at most this big} --- 8633,8635 ---- @!cur_pen:pointer; {an implicit input of |make_spec|, used in autorounding} ! @!cur_path_type:double_path_code..contour_code; {likewise} @!max_allowed:scaled; {coordinates must be at most this big} *************** *** 13304,13305 **** --- 13308,13310 ---- @!in_open : 0..max_in_open; {the number of lines in the buffer, less one} + @!open_parens : 0..max_in_open; {the number of open text files} @!input_file : array[1..max_in_open] of alpha_file; *************** *** 13733,13735 **** begin input_ptr:=0; max_in_stack:=0; ! in_open:=0; max_buf_stack:=0; param_ptr:=0; max_param_stack:=0; --- 13738,13740 ---- begin input_ptr:=0; max_in_stack:=0; ! in_open:=0; open_parens:=0; max_buf_stack:=0; param_ptr:=0; max_param_stack:=0; *************** *** 14119,14122 **** if force_eof then ! begin print_char(")"); force_eof:=false; update_terminal; {show user that file has been read} end_file_reading; {resume previous level} --- 14124,14128 ---- if force_eof then ! begin print_char(")"); decr(open_parens); update_terminal; {show user that file has been read} + force_eof:=false; end_file_reading; {resume previous level} *************** *** 15899,15901 **** else if (term_offset>0)or(file_offset>0) then print_char(" "); ! print_char("("); print(name); update_terminal; if name=str_ptr-1 then {we can conserve string pool space now} --- 15905,15907 ---- else if (term_offset>0)or(file_offset>0) then print_char(" "); ! print_char("("); incr(open_parens); print(name); update_terminal; if name=str_ptr-1 then {we can conserve string pool space now} *************** *** 20250,20251 **** --- 20256,20258 ---- @!q:pointer; {beginning of second half of doubled path} + @!add_to_type:double_path_code..also_code; {modifier of \&{addto}} begin get_x_next; var_flag:=thing_to_add; scan_primary; *************** *** 20253,20257 **** @ ! else begin lhs:=cur_exp; cur_path_type:=cur_mod;@/ cur_type:=vacuous; get_x_next; scan_expression; ! if cur_path_type=also_code then @ else @; --- 20260,20264 ---- @ ! else begin lhs:=cur_exp; add_to_type:=cur_mod;@/ cur_type:=vacuous; get_x_next; scan_expression; ! if add_to_type=also_code then @ else @; *************** *** 20314,20316 **** if cur_edges=null then toss_knot_list(rhs) ! else begin lhs:=null; if left_type(rhs)=endpoint then --- 20321,20323 ---- if cur_edges=null then toss_knot_list(rhs) ! else begin lhs:=null; cur_path_type:=add_to_type; if left_type(rhs)=endpoint then *************** *** 22900,22901 **** --- 22907,22911 ---- if job_name=0 then open_log_file; + while open_parens>0 do + begin print(" )"); decr(open_parens); + end; while cond_ptr<>null do diff -rc1 ../old/mf/mfbook.tex ./mf/mfbook.tex *** ../old/mf/mfbook.tex Sun Jan 7 16:04:00 1990 --- ./mf/mfbook.tex Sun Mar 25 13:10:21 1990 *************** *** 106,108 **** \noindent ! {\sl \kern-1pt Fourth printing, revised, Umbruary 1990} \smallskip --- 106,108 ---- \noindent ! {\sl \kern-1pt Fifth printing, revised, March 1990} \smallskip *************** *** 123,125 **** \noindent ! DEFGHIJKLM--DO--943210 ^^{Knuth, Donald Ervin} --- 123,125 ---- \noindent ! EFGHIJKLM--AL--943210 ^^{Knuth, Donald Ervin} *************** *** 1962,1964 **** \vtop{\line{\indent \tt ! This\\is\\METAFONT,\\Version\\1.0\\(preloaded\\base=plain 85.11.8)} \leftline{\indent \tt **}}$$ --- 1962,1964 ---- \vtop{\line{\indent \tt ! This\\is\\METAFONT,\\Version\\2.0\\(preloaded\\base=plain 89.11.8)} \leftline{\indent \tt **}}$$ *************** *** 1965,1967 **** The `^|**|' is \MF's way of asking you for an input file name. ! % Incidentally, 85.11.8 was Hermann's 67th birthday. --- 1965,1967 ---- The `^|**|' is \MF's way of asking you for an input file name. ! % Incidentally, 89.11.8 was Hermann's 71st birthday. *************** *** 11085,11087 **** def wipescreen = % do this to initialize or reinitialize ! for i:=1 upto n_windows: display blankpicture on i; endfor n_windows := screen_bot := 0; screen_corner := origin enddef; --- 11085,11087 ---- def wipescreen = % do this to initialize or reinitialize ! for i:=1 upto n_windows: display blankpicture inwindow i; endfor n_windows := screen_bot := 0; screen_corner := origin enddef; *************** *** 13036,13038 **** @nonstopmode@, and @batchmode@ are the modes you get into by hitting ! `|S|', `|R|', or `|Q|, respectively, in response to error messages (cf.~Chapter~5). --- 13036,13038 ---- @nonstopmode@, and @batchmode@ are the modes you get into by hitting ! `|S|', `|R|', or `|Q|', respectively, in response to error messages (cf.~Chapter~5). *************** *** 14043,14045 **** |% And don't modify the file under any circumstances.| ! |string base_name, base_version; base_name="plain"; base_version="1.7";| \smallskip --- 14043,14045 ---- |% And don't modify the file under any circumstances.| ! |string base_name, base_version; base_name="plain"; base_version="2.0";| \smallskip *************** *** 14178,14181 **** \smallbreak ! |vardef |^|byte|| primary s =| ! | if string s: ASCII fi s enddef;| \smallbreak --- 14178,14180 ---- \smallbreak ! |vardef |^|byte|| primary s = if string s: ASCII fi s enddef;| \smallbreak *************** *** 14189,14192 **** |vardef |^|counterclockwise|| primary c =| ! | interim |^|autorounding||:=0;| ! | if |^|turningnumber|| c <= 0: reverse fi c enddef;| \smallbreak --- 14188,14192 ---- |vardef |^|counterclockwise|| primary c =| ! | if turningcheck>0:| ! | interim |^|autorounding||:=0;| ! | if |^|turningnumber|| c <= 0: reverse fi fi c enddef;| \smallbreak *************** *** 15050,15052 **** \begintt ! This is METAFONT, Version 1.0 (INIMF) 8 NOV 1985 10:09 **plain --- 15050,15052 ---- \begintt ! This is METAFONT, Version 2.0 (INIMF) 8 NOV 1989 10:09 **plain *************** *** 15053,15055 **** (plain.mf ! Preloading the plain base, version 1.0) *input local --- 15053,15055 ---- (plain.mf ! Preloading the plain base, version 2.0) *input local *************** *** 16455,16457 **** | ligtable "`": "`" =: oct"134"; % open quotes| ! | ligtable "'": "'" := oct"042", % close quotes| | "?" kern 2u#, "!" kern 2u#;| --- 16455,16457 ---- | ligtable "`": "`" =: oct"134"; % open quotes| ! | ligtable "'": "'" =: oct"042", % close quotes| | "?" kern 2u#, "!" kern 2u#;| *************** *** 20087,20091 **** \TeX\ Users Group - c/o American Mathematical Society P.O. Box 9506 ! Providence RI 02940-9506, USA. \author DONALD E. ^{KNUTH}, {\sl The \TeX book\/} (1985) % Appendix J --- 20087,20090 ---- \TeX\ Users Group P.O. Box 9506 ! Providence RI 02940\kern.05em-9506, USA. \author DONALD E. ^{KNUTH}, {\sl The \TeX book\/} (1985) % Appendix J diff -rc1 ../old/mf/trap.fot ./mf/trap.fot *** ../old/mf/trap.fot Wed Dec 20 13:12:52 1989 --- ./mf/trap.fot Sun Mar 25 13:10:25 1990 *************** *** 1,2 **** ! This is METAFONT, Version 1.9 (INIMF) ** &trap trap --- 1,2 ---- ! This is METAFONT, Version 2.0(INIMF) ** &trap trap *************** *** 38,40 **** Memory usage 1476&588 (104 still untouched) ! String usage 39&162 (822&7732 still untouched) {[repeat the loop]} --- 38,40 ---- Memory usage 1476&588 (104 still untouched) ! String usage 39&162 (821&7731 still untouched) {[repeat the loop]} *************** *** 46,47 **** --- 46,48 ---- {endgroup} + ) (end occurred when else on line 93 was incomplete) diff -rc1 ../old/mf/trap.log ./mf/trap.log *** ../old/mf/trap.log Wed Dec 20 13:12:28 1989 --- ./mf/trap.log Sun Mar 25 13:11:14 1990 *************** *** 1,2 **** ! This is METAFONT, Version 1.9 (preloaded base=trap 89.12.20) 20 DEC 1989 13:04 ** &trap trap --- 1,2 ---- ! This is METAFONT, Version 2.0 (preloaded base=trap 90.3.25) 25 MAR 1990 00:34 ** &trap trap *************** *** 1521,1523 **** l.73 ...es:=1; e[-1+-+ -1.00001] ! =nullpicture; Since I don't take square roots of negative numbers, --- 1521,1523 ---- l.73 ...es:=1; e[-1+-+ -1.00001] ! =nullpicture; addto e1 also[[ Since I don't take square roots of negative numbers, *************** *** 1528,1529 **** --- 1528,1531 ---- {addto} + {begingroup} + {addto} {(path)scaled(3)} *************** *** 1574,1575 **** --- 1576,1579 ---- {cull} + {nullpicture} + {endgroup} {show} *************** *** 1803,1805 **** Memory usage 1084&202 (749 still untouched) ! String usage 21&86 (867&11413 still untouched) {addto} --- 1807,1809 ---- Memory usage 1084&202 (749 still untouched) ! String usage 21&86 (866&11412 still untouched) {addto} *************** *** 4221,4223 **** Memory usage 1476&588 (104 still untouched) ! String usage 39&162 (822&7732 still untouched) {[repeat the loop]} --- 4225,4227 ---- Memory usage 1476&588 (104 still untouched) ! String usage 39&162 (821&7731 still untouched) {[repeat the loop]} *************** *** 4232,4233 **** --- 4236,4238 ---- {endgroup} + ) (end occurred when else on line 93 was incomplete) *************** *** 4236,4239 **** Here is how much of METAFONT's memory you used: ! 66 strings out of 888 ! 3753 string characters out of 11485 2897 words of memory out of 3001 --- 4241,4244 ---- Here is how much of METAFONT's memory you used: ! 66 strings out of 887 ! 3753 string characters out of 11484 2897 words of memory out of 3001 *************** *** 4240,4242 **** 289 symbolic tokens out of 2100 ! 8i,43n,14r,8p,168b stack positions out of 30i,100n,300r,150p,500b --- 4245,4247 ---- 289 symbolic tokens out of 2100 ! 8i,43n,14r,8p,167b stack positions out of 30i,100n,300r,150p,500b diff -rc1 ../old/mf/trap.mf ./mf/trap.mf *** ../old/mf/trap.mf Wed Dec 20 13:03:50 1989 --- ./mf/trap.mf Sun Mar 25 13:11:22 1990 *************** *** 72,76 **** point ypart(p~5 intersectiontimes p~5 shifted (.01,0))of p~5; ! [[interim tracingedges:=1; e[-1+-+ -1.00001]=nullpicture; addto e0 doublepath p~5 scaled 3 withpen q; e0=e1=e2; cull e1 dropping (0,.1); ! show e1 shifted(4089,-4095), e2 shifted(-4095,4092) shifted (-3,0), e2 shifted(4089,-4095)]];addto e1 also e2 shifted(-2,$); e1:=e1 shifted(-4,$); --- 72,76 ---- point ypart(p~5 intersectiontimes p~5 shifted (.01,0))of p~5; ! [[interim tracingedges:=1; e[-1+-+ -1.00001]=nullpicture; addto e1 also[[ addto e0 doublepath p~5 scaled 3 withpen q; e0=e1=e2; cull e1 dropping (0,.1); ! nullpicture]];show e1 shifted(4089,-4095), e2 shifted(-4095,4092)shifted (-3,0), e2 shifted(4089,-4095)]];addto e1 also e2 shifted(-2,$); e1:=e1 shifted(-4,$); diff -rc1 ../old/mf/trap.typ ./mf/trap.typ *** ../old/mf/trap.typ Wed Dec 20 13:11:58 1989 --- ./mf/trap.typ Sun Mar 25 13:11:28 1990 *************** *** 2,4 **** Options selected: Mnemonic output = true; pixel output = true. ! ' METAFONT output 1989.12.20:1304' --- 2,4 ---- Options selected: Mnemonic output = true; pixel output = true. ! ' METAFONT output 1990.03.25:0034' diff -rc1 ../old/mf/trapin.log ./mf/trapin.log *** ../old/mf/trapin.log Wed Dec 20 13:13:45 1989 --- ./mf/trapin.log Sun Mar 25 13:11:33 1990 *************** *** 1,2 **** ! This is METAFONT, Version 1.9 (INIMF) 20 DEC 1989 13:03 **\input trap --- 1,2 ---- ! This is METAFONT, Version 2.0 (INIMF) 25 MAR 1990 00:34 **\input trap *************** *** 149,151 **** Memory usage 291&37 (1922 still untouched) ! String usage 26&83 (896&11536 still untouched) ! OK. --- 149,151 ---- Memory usage 291&37 (1922 still untouched) ! String usage 26&83 (895&11534 still untouched) ! OK. *************** *** 173,178 **** {elseif} ! Beginning to dump on file trap.base ! (preloaded base=trap 89.12.20) ! 1112 strings of total length 20515 395 memory locations dumped; current usage is 317&67 --- 173,178 ---- {elseif} ! ) Beginning to dump on file trap.base ! (preloaded base=trap 90.3.25) ! 1113 strings of total length 20516 395 memory locations dumped; current usage is 317&67 diff -rc1 ../old/tex/tex.web ./tex/tex.web *** ../old/tex/tex.web Mon Jan 8 06:27:11 1990 --- ./tex/tex.web Sun Mar 25 13:14:46 1990 *************** *** 39,44 **** % Version 2.993 fixed a save_stack synchronization bug et alia (December 1989). ! % A reward of $163.84 will be paid to the first finder of any remaining bug, % not counting changes introduced after August 1989. - % (This amount will double again in 1990.) --- 39,44 ---- % Version 2.993 fixed a save_stack synchronization bug et alia (December 1989). + % Version 3.0 fixed unusual displays; was more \output robust (March 1990). ! % A reward of $327.68 will be paid to the first finder of any remaining bug, % not counting changes introduced after August 1989. *************** *** 185,187 **** ! @d banner=='This is TeX, Version 2.993' {printed when \TeX\ starts} --- 185,187 ---- ! @d banner=='This is TeX, Version 3.0' {printed when \TeX\ starts} *************** *** 433,435 **** @d hash_size=2100 {maximum number of control sequences; it should be at most ! about |(mem_max-mem_min)/10|, but 2100 is already quite generous} @d hash_prime=1777 {a prime number equal to about 85\pct! of |hash_size|} --- 433,435 ---- @d hash_size=2100 {maximum number of control sequences; it should be at most ! about |(mem_max-mem_min)/10|} @d hash_prime=1777 {a prime number equal to about 85\pct! of |hash_size|} *************** *** 1010,1011 **** --- 1010,1015 ---- be given. The following code uses concepts that will be explained later. + (If the \PASCAL\ compiler does not support non-local |@!goto|, the + @^system dependencies@> + statement `|goto final_end|' should be replaced by something that + quietly terminates the program.) *************** *** 1828,1830 **** @ The |jump_out| procedure just cuts across all active procedure levels and ! goes to |end_of_TEX|. This is the only nonlocal |@!goto| statement in the whole program. It is used when there is no recovery from a particular error. --- 1832,1834 ---- @ The |jump_out| procedure just cuts across all active procedure levels and ! goes to |end_of_TEX|. This is the only nontrivial |@!goto| statement in the whole program. It is used when there is no recovery from a particular error. *************** *** 6150,6153 **** each word contains a token and a link. Macro definitions, output-routine ! definitions, marks, and \.{\\write} texts are kept in \TeX's memory in the ! form of token lists, preceded by a node that has a reference count in its |token_ref_count| field. The token stored in location |p| is called --- 6154,6158 ---- each word contains a token and a link. Macro definitions, output-routine ! definitions, marks, \.{\\write} texts, and a few other things ! are remembered by \TeX\ in the form ! of token lists, usually preceded by a node with a reference count in its |token_ref_count| field. The token stored in location |p| is called *************** *** 6522,6523 **** --- 6527,6529 ---- @!in_open : 0..max_in_open; {the number of lines in the buffer, less one} + @!open_parens : 0..max_in_open; {the number of open text files} @!input_file : array[1..max_in_open] of alpha_file; *************** *** 7052,7054 **** begin input_ptr:=0; max_in_stack:=0; ! in_open:=0; max_buf_stack:=0; param_ptr:=0; max_param_stack:=0; --- 7058,7060 ---- begin input_ptr:=0; max_in_stack:=0; ! in_open:=0; open_parens:=0; max_buf_stack:=0; param_ptr:=0; max_param_stack:=0; *************** *** 7496,7498 **** if interaction>nonstop_mode then ! begin if (end_line_char<0)or(end_line_char>127) then incr(limit); if limit=start then {previous line was empty} --- 7502,7504 ---- if interaction>nonstop_mode then ! begin if end_line_char_inactive then incr(limit); if limit=start then {previous line was empty} *************** *** 7530,7533 **** if force_eof then ! begin print_char(")"); force_eof:=false; update_terminal; {show user that file has been read} end_file_reading; {resume previous level} --- 7536,7540 ---- if force_eof then ! begin print_char(")"); decr(open_parens); update_terminal; {show user that file has been read} + force_eof:=false; end_file_reading; {resume previous level} *************** *** 8038,8040 **** incr(align_state); long_state:=call; cur_tok:=par_token; ins_error; ! end --- 8045,8047 ---- incr(align_state); long_state:=call; cur_tok:=par_token; ins_error; ! end {a white lie; the \.{\\par} won't always trigger a runaway} *************** *** 9810,9815 **** different in examples like this: ! $$\vbox{\halign{\.{#}\hfil\cr ! {}\\def\\a\{\\c\}\cr ! {}\\def\\b\{\\d\}\cr {}\\def\\c\{\}\cr {}\\def\\d\{\}\cr}}$$ --- 9817,9822 ---- different in examples like this: ! $$\vbox{\halign{\.{#}\hfil&\qquad\.{#}\hfil\cr ! {}\\def\\a\{\\c\}& {}\\def\\c\{\}\cr + {}\\def\\b\{\\d\}& {}\\def\\d\{\}\cr}}$$ *************** *** 9818,9824 **** begin p:=link(cur_chr); q:=link(equiv(n)); {omit reference counts} ! while (p<>null)and(q<>null) do ! if info(p)<>info(q) then p:=null ! else begin p:=link(p); q:=link(q); ! end; ! b:=((p=null)and(q=null)); end --- 9825,9833 ---- begin p:=link(cur_chr); q:=link(equiv(n)); {omit reference counts} ! if p=q then b:=true ! else begin while (p<>null)and(q<>null) do ! if info(p)<>info(q) then p:=null ! else begin p:=link(p); q:=link(q); ! end; ! b:=((p=null)and(q=null)); ! end; end *************** *** 10333,10335 **** else if (term_offset>0)or(file_offset>0) then print_char(" "); ! print_char("("); print(name); update_terminal; state:=new_line; if name=str_ptr-1 then {we can conserve string pool space now} --- 10342,10345 ---- else if (term_offset>0)or(file_offset>0) then print_char(" "); ! print_char("("); incr(open_parens); print(name); update_terminal; ! state:=new_line; if name=str_ptr-1 then {we can conserve string pool space now} *************** *** 10347,10349 **** @= ! begin if not input_ln(cur_file,false) then do_nothing; firm_up_the_line; --- 10357,10359 ---- @= ! begin if input_ln(cur_file,false) then do_nothing; firm_up_the_line; *************** *** 14295,14296 **** --- 14305,14307 ---- by |cur_mu|. + @!@:non_script_}{\.{\\nonscript} primitive@> *************** *** 15756,15762 **** while q<>null do ! begin if type(q)=unset_node then ! @ ! else if type(q)=rule_node then ! @; s:=q; q:=link(q); --- 15767,15774 ---- while q<>null do ! begin if not is_char_node(q) then ! if type(q)=unset_node then ! @ ! else if type(q)=rule_node then ! @; s:=q; q:=link(q); *************** *** 16290,16292 **** @!d:integer; {demerits of test line} ! @!artificial_badness:boolean; {has |b| been forced to zero?} @!save_link:pointer; {temporarily holds value of |link(cur_p)|} --- 16302,16304 ---- @!d:integer; {demerits of test line} ! @!artificial_demerits:boolean; {has |d| been forced to zero?} @!save_link:pointer; {temporarily holds value of |link(cur_p)|} *************** *** 16326,16330 **** @= ! @!minimal_demerits:array[very_loose_fit..tight_fit] of scaled; {best total demerits known for current line class and position, given the fitness} ! @!minimum_demerits:scaled; {best total demerits known for current line class and position} --- 16338,16342 ---- @= ! @!minimal_demerits:array[very_loose_fit..tight_fit] of integer; {best total demerits known for current line class and position, given the fitness} ! @!minimum_demerits:integer; {best total demerits known for current line class and position} *************** *** 16371,16373 **** @; ! minimum_demerits:=minimum_demerits+abs(adj_demerits); for fit_class:=very_loose_fit to tight_fit do --- 16383,16387 ---- @; ! if abs(adj_demerits)>=awful_bad-minimum_demerits then ! minimum_demerits:=awful_bad-1 ! else minimum_demerits:=minimum_demerits+abs(adj_demerits); for fit_class:=very_loose_fit to tight_fit do *************** *** 16647,16649 **** @= ! begin @!stat artificial_badness:=false;@+tats@/ @^inner loop@> --- 16661,16663 ---- @= ! begin artificial_demerits:=false;@/ @^inner loop@> *************** *** 16714,16718 **** (prev_r=active) then ! begin b:=0; {set badness zero, this break is forced} ! @!stat artificial_badness:=true;@+tats ! end else if b>threshold then goto deactivate; --- 16728,16730 ---- (prev_r=active) then ! artificial_demerits:=true {set demerits zero, this break is forced} else if b>threshold then goto deactivate; *************** *** 16729,16731 **** @= ! @; @!stat if tracing_paragraphs>0 then --- 16741,16744 ---- @= ! if artificial_demerits then d:=0 ! else @; @!stat if tracing_paragraphs>0 then *************** *** 16758,16763 **** print(" b="); ! if artificial_badness then print_char("*")@+else print_int(b); @.*\relax@> ! print(" p="); print_int(pi); ! print(" d="); print_int(d); end --- 16771,16776 ---- print(" b="); ! if b>inf_bad then print_char("*")@+else print_int(b); @.*\relax@> ! print(" p="); print_int(pi); print(" d="); ! if artificial_demerits then print_char("*")@+else print_int(d); end *************** *** 16788,16790 **** @ @= ! d:=line_penalty+b; d:=d*d; if pi<>0 then --- 16801,16804 ---- @ @= ! begin d:=line_penalty+b; ! if abs(d)>=10000 then d:=100000000@+else d:=d*d; if pi<>0 then *************** *** 16795,16797 **** else d:=d+final_hyphen_demerits; ! if abs(fit_class-fitness(r))>1 then d:=d+adj_demerits --- 16809,16812 ---- else d:=d+final_hyphen_demerits; ! if abs(fit_class-fitness(r))>1 then d:=d+adj_demerits; ! end *************** *** 17442,17444 **** procedure hyphenate; ! label common_ending,done,found,found1,not_found,not_found+1,exit; var @@; --- 17457,17459 ---- procedure hyphenate; ! label common_ending,done,found,found1,found2,not_found,exit; var @@; *************** *** 17572,17574 **** q:=link(hb); link(hb):=null; r:=link(ha); link(ha):=null; bchar:=non_char; ! if type(hb)=ligature_node then if odd(subtype(hb)) then bchar:=font_bchar[hf]; --- 17587,17590 ---- q:=link(hb); link(hb):=null; r:=link(ha); link(ha):=null; bchar:=non_char; ! if not is_char_node(hb) then ! if type(hb)=ligature_node then if odd(subtype(hb)) then bchar:=font_bchar[hf]; *************** *** 17575,17587 **** if is_char_node(ha) then ! begin init_list:=ha; init_lig:=false; hu[0]:=qo(character(ha)); ! end else if type(ha)=ligature_node then ! begin init_list:=lig_ptr(ha); init_lig:=true; init_lft:=(subtype(ha)>1); ! hu[0]:=qo(character(lig_char(ha))); ! if init_list=null then if init_lft then ! begin hu[0]:=256; init_lig:=false; ! end; {in this case a ligature will be reconstructed from scratch} ! free_node(ha,small_node_size); ! end ! else goto not_found+1; {no punctuation found} s:=cur_p; {we have |cur_p<>ha| because |type(cur_p)=glue_node|} --- 17591,17609 ---- if is_char_node(ha) then ! if font(ha)<>hf then goto found2 ! else begin init_list:=ha; init_lig:=false; hu[0]:=qo(character(ha)); ! end else if type(ha)=ligature_node then ! if font(lig_char(ha))<>hf then goto found2 ! else begin init_list:=lig_ptr(ha); init_lig:=true; init_lft:=(subtype(ha)>1); ! hu[0]:=qo(character(lig_char(ha))); ! if init_list=null then if init_lft then ! begin hu[0]:=256; init_lig:=false; ! end; {in this case a ligature will be reconstructed from scratch} ! free_node(ha,small_node_size); ! end ! else begin {no punctuation found; look for left boundary} ! if not is_char_node(r) then if type(r)=ligature_node then ! if subtype(r)>1 then goto found2; ! j:=1; s:=ha; init_list:=null; goto common_ending; ! end; s:=cur_p; {we have |cur_p<>ha| because |type(cur_p)=glue_node|} *************** *** 17589,17595 **** j:=0; goto common_ending; ! not_found+1: j:=1; s:=ha; init_list:=null; ! if not is_char_node(r) then if type(r)=ligature_node then ! if subtype(r)>1 then ! begin j:=0; hu[0]:=256; init_lig:=false; ! end; common_ending: flush_node_list(r); --- 17611,17613 ---- j:=0; goto common_ending; ! found2: s:=ha; j:=0; hu[0]:=256; init_lig:=false; init_list:=null; common_ending: flush_node_list(r); *************** *** 19733,19736 **** if best_ins_ptr(r)=null then wait:=true ! else begin wait:=false; s:=ins_ptr(p); ! link(last_ins_ptr(r)):=s; s:=last_ins_ptr(r); if best_ins_ptr(r)=p then --- 19751,19753 ---- if best_ins_ptr(r)=null then wait:=true ! else begin wait:=false; s:=last_ins_ptr(r); link(s):=ins_ptr(p); if best_ins_ptr(r)=p then *************** *** 19751,19752 **** --- 19768,19770 ---- begin while link(s)<>broken_ptr(r) do s:=link(s); + link(s):=null; split_top_skip:=split_top_ptr(p); *************** *** 19758,19760 **** end; - link(s):=null; end; --- 19776,19777 ---- *************** *** 19815,19817 **** @= ! begin if loc<>null then @; end_token_list; {conserve stack space in case more outputs are triggered} --- 19832,19836 ---- @= ! begin if (loc<>null) or ! ((token_type<>output_text)and(token_type<>backed_up)) then ! @; end_token_list; {conserve stack space in case more outputs are triggered} *************** *** 19835,19837 **** @.Unbalanced output routine@> ! help2("Your sneaky output routine has fewer real {'s than }'s.")@/ ("I can't handle that very well; good luck."); error; --- 19854,19856 ---- @.Unbalanced output routine@> ! help2("Your sneaky output routine has problematic {'s and/or }'s.")@/ ("I can't handle that very well; good luck."); error; *************** *** 19839,19841 **** until loc=null; ! end --- 19858,19860 ---- until loc=null; ! end {loops forever if reading from a file, since |null=min_halfword<=0|} *************** *** 20366,20368 **** tail_append(new_penalty(-@'10000000000));@/ ! build_page; {append \.{\\hbox to \\hsize\{\}\\vss\\penalty-'10000000000}} end; --- 20385,20387 ---- tail_append(new_penalty(-@'10000000000));@/ ! build_page; {append \.{\\hbox to \\hsize\{\}\\vfill\\penalty-'10000000000}} end; *************** *** 20567,20572 **** ! @ It's very hard to get this error message; indeed, the case didn't arise ! until more than two years after it had been programmed. ! ! @= begin print_err("Extra "); print_cmd_chr(cur_cmd,cur_chr); --- 20586,20588 ---- ! @ @= begin print_err("Extra "); print_cmd_chr(cur_cmd,cur_chr); *************** *** 22186,22188 **** in a math formula. Two special cases are simplified here: Braces are effectively ! removed when they surround a single Ord character or, when they surround an accent that is the nucleus of an Ord atom. --- 22202,22204 ---- in a math formula. Two special cases are simplified here: Braces are effectively ! removed when they surround a single Ord without sub/superscripts, or when they surround an accent that is the nucleus of an Ord atom. *************** *** 22277,22279 **** if mode=-m then {end of equation number} ! begin cur_mlist:=p; cur_style:=text_style; mlist_penalties:=false; mlist_to_hlist; a:=hpack(link(temp_head),natural); --- 22293,22296 ---- if mode=-m then {end of equation number} ! begin @; ! cur_mlist:=p; cur_style:=text_style; mlist_penalties:=false; mlist_to_hlist; a:=hpack(link(temp_head),natural); *************** *** 22281,22283 **** if saved(0)=1 then l:=true; ! if danger then flush_math; m:=mode; p:=fin_mlist(null); --- 22298,22302 ---- if saved(0)=1 then l:=true; ! danger:=false; ! @; m:=mode; p:=fin_mlist(null); *************** *** 22286,22288 **** if m<0 then @ ! else begin @; @; --- 22305,22307 ---- if m<0 then @ ! else begin if a=null then @; @; *************** *** 22364,22366 **** mlist_to_hlist; p:=link(temp_head);@/ ! adjust_tail:=adjust_head; b:=hpack(p,natural); t:=adjust_tail; adjust_tail:=null;@/ --- 22383,22385 ---- mlist_to_hlist; p:=link(temp_head);@/ ! adjust_tail:=adjust_head; b:=hpack(p,natural); p:=list_ptr(b); t:=adjust_tail; adjust_tail:=null;@/ *************** *** 22424,22426 **** begin d:=half(z-w-e); ! if p<>null then if type(p)=glue_node then d:=0; end --- 22443,22445 ---- begin d:=half(z-w-e); ! if p<>null then if not is_char_node(p) then if type(p)=glue_node then d:=0; end *************** *** 22457,22462 **** end; ! shift_amount(b):=s+d; append_to_vlist(b); ! if t<>adjust_head then ! begin link(tail):=link(adjust_head); tail:=t; ! end --- 22476,22478 ---- end; ! shift_amount(b):=s+d; append_to_vlist(b) *************** *** 22467,22473 **** append_to_vlist(a); ! tail_append(new_penalty(post_display_penalty)); ! end ! else begin tail_append(new_penalty(post_display_penalty)); ! tail_append(new_param_glue(g2)); ! end --- 22483,22491 ---- append_to_vlist(a); ! g2:=0; ! end; ! if t<>adjust_head then {migrating material comes after equation number} ! begin link(tail):=link(adjust_head); tail:=t; ! end; ! tail_append(new_penalty(post_display_penalty)); ! if g2>0 then tail_append(new_param_glue(g2)) *************** *** 24220,24221 **** --- 24238,24242 ---- if job_name=0 then open_log_file; + while open_parens>0 do + begin print(" )"); decr(open_parens); + end; if cur_level>level_one then diff -rc1 ../old/tex/texbook.tex ./tex/texbook.tex *** ../old/tex/texbook.tex Fri Dec 8 20:19:41 1989 --- ./tex/texbook.tex Sun Mar 25 15:32:52 1990 *************** *** 5876,5878 **** infeasible breakpoint had to be chosen because there was no feasible ! alternative. --- 5876,5878 ---- infeasible breakpoint had to be chosen because there was no feasible ! way to keep total demerits small. *************** *** 8335,8340 **** \kern-.1em\TeX} Document Preparation System\/} (1983) ! % Note: the final manual has a slightly different wording on p43. ! % It's now called "LaTeX: A Document Preparation System" (1986) ! % But I decided to cite the original, partly because I have ! % no smallcaps sans-serif `A' to match the new LaTeX logo! --- 8335,8340 ---- \kern-.1em\TeX} Document Preparation System\/} (1983) ! % Note: the final manual has a slightly different wording on p43. ! % It's now called "LaTeX: A Document Preparation System" (1986) ! % But I decided to cite the original, partly because I have ! % no smallcaps sans-serif `A' to match the new LaTeX logo! *************** *** 10396,10398 **** formula produces a result exactly equivalent to ! `|\left(|\|\right)|', except that the ^{delimiters} are forced to be of the |\big| size regardless of the height and depth of the subformula. --- 10396,10399 ---- formula produces a result exactly equivalent to ! `|\left(|\|\right)|', when the \ doesn't end ! with Punct, except that the ^{delimiters} are forced to be of the |\big| size regardless of the height and depth of the subformula. *************** *** 17742,17745 **** token \cstok{par} into the input; after reading and expanding this \cstok{par} ! token, \TeX\ will see the \ again. \ (The current ! meaning of the control sequence ^|\par| will be used; \cstok{par} may no longer stand for \TeX's |\par| primitive.) --- 17743,17746 ---- token \cstok{par} into the input; after reading and expanding this \cstok{par} ! token, \TeX\ will see the \ token again. \ (The current ! meaning of the control sequence ^|\par| will be used; \cstok{par} might no longer stand for \TeX's |\par| primitive.) *************** *** 17930,17932 **** math list goes into the atomic field. If the math list turns out to be ! simply a single Ord atom without subscripts or superscripts, the enclosing braces are effectively removed. --- 17931,17934 ---- math list goes into the atomic field. If the math list turns out to be ! simply a single Ord atom without subscripts or superscripts, ! or an Acc whose nucleus is an Ord, the enclosing braces are effectively removed. *************** *** 18566,18568 **** |main memory size|\qquad(boxes, glue, breakpoints, token lists, ! characters, etc.)\cr |hash size|\qquad(control sequence names)\cr --- 18568,18570 ---- |main memory size|\qquad(boxes, glue, breakpoints, token lists, ! characters, etc.)\cr |hash size|\qquad(control sequence names)\cr *************** *** 18934,18936 **** | | ! ^|\vglue|| 1in % This makes an inch of blank space (1in=2.54cm).| ^|\centerline||{\bf A Bold, Centered Title}| --- 18936,18938 ---- | | ! ^|\topglue|| 1in % This makes an inch of blank space (1in=2.54cm).| ^|\centerline||{\bf A Bold, Centered Title}| *************** *** 18968,18970 **** {\parindent 20pt ! \vglue 1in % This makes an inch of blank space (1in=2.54cm). \centerline{\bf A Bold, Centered Title} --- 18970,18972 ---- {\parindent 20pt ! \topglue 1in % This makes an inch of blank space (1in=2.54cm). \centerline{\bf A Bold, Centered Title} *************** *** 19013,19015 **** |\medskip| or |\bigskip|; it uses |\llap| but not |\rlap|, |\item| ! but not |\itemitem|, |\vglue| but not |\hglue|. It does not illustrate |\raggedright| setting of paragraphs; it does not use --- 19015,19017 ---- |\medskip| or |\bigskip|; it uses |\llap| but not |\rlap|, |\item| ! but not |\itemitem|, |\topglue| but not |\hglue|. It does not illustrate |\raggedright| setting of paragraphs; it does not use *************** *** 19689,19696 **** There also are macros for potentially breakable vertical spaces: ! ^|\smallskip|, ^|\medskip|, and ^|\bigskip|. \beginlines ! |\def\enskip{\hskip.5em\relax}| ! |\def\quad{\hskip1em\relax} \def\qquad{\hskip2em\relax}| ! |\def\enspace{\kern.5em }| ! |\def\thinspace{\kern .16667em } \def\negthinspace{\kern-.16667em }| \smallbreak --- 19691,19697 ---- There also are macros for potentially breakable vertical spaces: ! ^|\smallskip|, ^|\medskip|, and ^|\bigskip|.^^|\topglue| \beginlines ! |\def\enskip{\hskip.5em\relax} \def\enspace{\kern.5em }| ! |\def\quad{\hskip1em\relax} \def\qquad{\hskip2em\relax}| ! |\def\thinspace{\kern .16667em } \def\negthinspace{\kern-.16667em }| \smallbreak *************** *** 19702,19703 **** --- 19703,19705 ---- | \nobreak\vskip\skip@ \prevdepth=\dimen@}| + |\def\topglue{\nointerlineskip \vglue-\topskip \vglue} % for top of page| \smallbreak *************** *** 24909,24911 **** in the width of box~$x$ if and only if limits are to be set or ! there is no subscript. Shift box~$x$ down by ${1\over2}\bigl(h(x)+d(x)\bigr) -a$, where $a=\sigma_{22}$, so that the operator character is centered --- 24911,24913 ---- in the width of box~$x$ if and only if limits are to be set or ! there is no subscript. Shift box~$x$ down by ${1\over2}\bigl(h(x)-d(x)\bigr) -a$, where $a=\sigma_{22}$, so that the operator character is centered *************** *** 27809,27810 **** --- 27811,27813 ---- |\top| ( $\top$ ), 435. + |\topglue|, @340, +352. |\topins|, 256, +363, @364. *************** *** 27940,27942 **** *|\vfuzz|, 274, @348. ! |\vglue|, 340, +352. vinculum, \see |\overline|. --- 27943,27945 ---- *|\vfuzz|, 274, @348. ! |\vglue|, +352, @408. vinculum, \see |\overline|.