diff options
author | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2016-03-31 22:49:18 +0000 |
---|---|---|
committer | Akira Kakuto <kakuto@fuk.kindai.ac.jp> | 2016-03-31 22:49:18 +0000 |
commit | 4f0696d9aa8cf04c1e0106e830e28c45556588ce (patch) | |
tree | 50b4903b9c5e10d14e73bca7f2b1838f8a74b6d1 /Build/source/texk/web2c/luatexdir/tex/texnodes.h | |
parent | 657b5cfe19672cc27026ed2ab78b667062af6e68 (diff) |
web2c/luatexdir: sync with the upstream
git-svn-id: svn://tug.org/texlive/trunk@40200 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/luatexdir/tex/texnodes.h')
-rw-r--r-- | Build/source/texk/web2c/luatexdir/tex/texnodes.h | 83 |
1 files changed, 58 insertions, 25 deletions
diff --git a/Build/source/texk/web2c/luatexdir/tex/texnodes.h b/Build/source/texk/web2c/luatexdir/tex/texnodes.h index 1f1a4e82964..0da84945184 100644 --- a/Build/source/texk/web2c/luatexdir/tex/texnodes.h +++ b/Build/source/texk/web2c/luatexdir/tex/texnodes.h @@ -68,8 +68,6 @@ extern void undump_node_mem(void); # define rlink(a) vlink((a)+1) /* aka alink() */ # define tlink(a) vinfo((a)+1) /* overlaps with node_attr() */ -# define add_glue_ref(a) glue_ref_count(a)++ /* new reference to a glue spec */ - /* really special head node pointers that only need links */ # define temp_node_size 2 @@ -106,15 +104,6 @@ extern void update_attribute_cache(void); extern halfword copy_attribute_list(halfword n); extern halfword do_set_attribute(halfword p, int i, int val); -/* a glue spec */ -# define glue_spec_size 4 -# define stretch(a) vlink((a)+1) -/* width == a+2 */ -# define shrink(a) vinfo((a)+1) -# define stretch_order(a) type((a)+3) -# define shrink_order(a) subtype((a)+3) -# define glue_ref_count(a) vlink((a)+3) - # define width_offset 2 # define depth_offset 3 # define height_offset 4 @@ -138,11 +127,53 @@ typedef enum { # define penalty_node_size 3 # define penalty(a) vlink((a)+2) +/* # define glue_node_size 4 # define glue_ptr(a) vinfo((a)+2) # define leader_ptr(a) vlink((a)+2) # define synctex_tag_glue(a) vinfo((a)+3) # define synctex_line_glue(a) vlink((a)+3) +*/ + +# define glue_node_size 7 +# define glue_spec_size 5 +/* define width(a) vinfo((a)+2) */ +/* define leader_ptr(a) vlink((a)+2) */ +# define shrink(a) vinfo((a)+3) +# define stretch(a) vlink((a)+3) +# define stretch_order(a) vinfo((a)+4) +# define shrink_order(a) vlink((a)+4) +# define leader_ptr(a) vlink((a)+5) /* should be in vlink((a)+2) but fails */ +# define synctex_tag_glue(a) vinfo((a)+6) +# define synctex_line_glue(a) vlink((a)+6) + +#define glue_is_zero(p) \ + ((p == null) || (width(p) == 0 && stretch(p) == 0 && shrink(p) == 0)) + +#define reset_glue_to_zero(p) \ + if (p != null) { \ + width(p) = 0; \ + stretch(p) = 0; \ + shrink(p) = 0; \ + stretch_order(p) = 0; \ + shrink_order(p) = 0; \ + } + +#define copy_glue_values(p,q) \ + if (q == null) { \ + width(p) = 0; \ + stretch(p) = 0; \ + shrink(p) = 0; \ + stretch_order(p) = 0; \ + shrink_order(p) = 0; \ + } else { \ + width(p) = width(q); \ + stretch(p) = stretch(q); \ + shrink(p) = shrink(q); \ + stretch_order(p) = stretch_order(q); \ + shrink_order(p) = shrink_order(q); \ + } + /* disc nodes could eventually be smaller, because the indirect @@ -282,11 +313,17 @@ typedef enum { # define before 0 /* |subtype| for math node that introduces a formula */ # define after 1 /* |subtype| for math node that winds up a formula */ -# define math_node_size 4 -# define surround(a) vlink((a)+2) -/* also: glue_ptr(a) vinfo((a)+2) */ -# define synctex_tag_math(a) vinfo((a)+3) -# define synctex_line_math(a) vlink((a)+3) +# define math_node_size 7 +/* define width(a) vinfo((a)+2) */ +/* overlaps width */ +/* define shrink(a) vinfo((a)+3) */ +/* define stretch(a) vlink((a)+3) */ +/* define stretch_order(a) vinfo((a)+4) */ +/* define shrink_order(a) vlink((a)+4) */ +/* leader_ptr slot */ +# define surround(a) vinfo((a)+5) +# define synctex_tag_math(a) vinfo((a)+6) +# define synctex_line_math(a) vlink((a)+6) # define ins_node_size 6 # define float_cost(a) varmem[(a)+2].cint @@ -620,15 +657,13 @@ typedef enum { # define special_node_size 3 -# define dir_node_size 6 +# define dir_node_size 5 # define dir_dir(a) vinfo((a)+2) # define dir_level(a) vlink((a)+2) -# define dir_dvi_ptr(a) vinfo((a)+3) -# define dir_dvi_h(a) vlink((a)+3) /* obsolete */ -# define dir_refpos_h(a) vinfo((a)+4) -# define dir_refpos_v(a) vlink((a)+4) -# define dir_cur_h(a) vinfo((a)+5) -# define dir_cur_v(a) vlink((a)+5) +# define dir_refpos_h(a) vinfo((a)+3) +# define dir_refpos_v(a) vlink((a)+3) +# define dir_cur_h(a) vinfo((a)+4) +# define dir_cur_v(a) vlink((a)+4) # define write_node_size 3 # define close_node_size 3 @@ -910,10 +945,8 @@ typedef enum { # define is_running(A) ((A)==null_flag) /* tests for a running dimension */ extern halfword tail_of_list(halfword p); -extern void delete_glue_ref(halfword p); extern int var_used; -extern halfword temp_ptr; # define cache_disabled max_halfword |