summaryrefslogtreecommitdiff
path: root/Build/source/texk/web2c/luatexdir/tex
diff options
context:
space:
mode:
authorAkira Kakuto <kakuto@fuk.kindai.ac.jp>2016-09-10 09:52:59 +0000
committerAkira Kakuto <kakuto@fuk.kindai.ac.jp>2016-09-10 09:52:59 +0000
commit7e17932009a54c6047241ce05f043b51cce32233 (patch)
tree7b6001c89a8bbf5dee032af1048892cf9ab20373 /Build/source/texk/web2c/luatexdir/tex
parent8072d653e5694112aadd35396317648fa019dc6e (diff)
luatexdir: sync with the upstream
git-svn-id: svn://tug.org/texlive/trunk@42031 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Build/source/texk/web2c/luatexdir/tex')
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/commands.w3
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/dumpdata.w2
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/equivalents.h22
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/errors.w1
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/linebreak.w2
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/mainbody.w2
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/mlist.w121
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/texfileio.w12
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/texmath.h4
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/texmath.w1
-rw-r--r--Build/source/texk/web2c/luatexdir/tex/texnodes.w45
11 files changed, 163 insertions, 52 deletions
diff --git a/Build/source/texk/web2c/luatexdir/tex/commands.w b/Build/source/texk/web2c/luatexdir/tex/commands.w
index 88211643533..e4a269d93d0 100644
--- a/Build/source/texk/web2c/luatexdir/tex/commands.w
+++ b/Build/source/texk/web2c/luatexdir/tex/commands.w
@@ -557,6 +557,8 @@ void initialize_commands(void)
primitive_luatex("Umathlimitbelowvgap", set_math_param_cmd, math_param_limit_below_vgap, 0);
primitive_luatex("Umathlimitbelowbgap", set_math_param_cmd, math_param_limit_below_bgap, 0);
primitive_luatex("Umathlimitbelowkern", set_math_param_cmd, math_param_limit_below_kern, 0);
+ primitive_luatex("Umathnolimitsubfactor", set_math_param_cmd, math_param_nolimit_sub_factor, 0); /* bonus */
+ primitive_luatex("Umathnolimitsupfactor", set_math_param_cmd, math_param_nolimit_sup_factor, 0); /* bonus */
primitive_luatex("Umathunderdelimitervgap", set_math_param_cmd, math_param_under_delimiter_vgap, 0);
primitive_luatex("Umathunderdelimiterbgap", set_math_param_cmd, math_param_under_delimiter_bgap, 0);
primitive_luatex("Umathoverdelimitervgap", set_math_param_cmd, math_param_over_delimiter_vgap, 0);
@@ -751,6 +753,7 @@ void initialize_etex_commands(void)
primitive_luatex("matheqnogapstep", assign_int_cmd, int_base + math_eqno_gap_step_code, int_base);
primitive_luatex("mathdisplayskipmode", assign_int_cmd, int_base + math_display_skip_mode_code, int_base);
primitive_luatex("mathscriptsmode", assign_int_cmd, int_base + math_scripts_mode_code, int_base);
+ primitive_luatex("mathnolimitsmode", assign_int_cmd, int_base + math_nolimits_mode_code, int_base);
primitive_luatex("synctex", assign_int_cmd, int_base + synctex_code, int_base);
primitive_etex("currentgrouplevel", last_item_cmd, current_group_level_code, 0);
diff --git a/Build/source/texk/web2c/luatexdir/tex/dumpdata.w b/Build/source/texk/web2c/luatexdir/tex/dumpdata.w
index ae769584381..85ff55f4e09 100644
--- a/Build/source/texk/web2c/luatexdir/tex/dumpdata.w
+++ b/Build/source/texk/web2c/luatexdir/tex/dumpdata.w
@@ -23,7 +23,7 @@
/* we start with 907: the sum of the values of the bytes of "don knuth" */
-#define FORMAT_ID (907+17)
+#define FORMAT_ID (907+18)
#if ((FORMAT_ID>=0) && (FORMAT_ID<=256))
#error Wrong value for FORMAT_ID.
#endif
diff --git a/Build/source/texk/web2c/luatexdir/tex/equivalents.h b/Build/source/texk/web2c/luatexdir/tex/equivalents.h
index 7f83dd3d6cc..b2bda5f605b 100644
--- a/Build/source/texk/web2c/luatexdir/tex/equivalents.h
+++ b/Build/source/texk/web2c/luatexdir/tex/equivalents.h
@@ -278,20 +278,21 @@ the |number_regs| \.{\\dimen} registers.
# define math_eqno_gap_step_code 87 /* factor/1000 used for distance between eq and eqno */
# define math_display_skip_mode_code 88
# define math_scripts_mode_code 89
-# define synctex_code 90 /* is synctex file generation enabled ? */
-# define shape_mode_code 91
-# define first_valid_language_code 92
-# define hyphenation_bounds_code 93
+# define math_nolimits_mode_code 90
+# define synctex_code 91 /* is synctex file generation enabled ? */
+# define shape_mode_code 92
+# define first_valid_language_code 93
+# define hyphenation_bounds_code 94
-# define math_option_code 94
+# define math_option_code 95
-# define mathoption_int_base (int_base+95) /* one reserve */
-# define mathoption_int_last (int_base+100)
+# define mathoption_int_base (int_base+96) /* one reserve */
+# define mathoption_int_last (int_base+104)
-# define backend_int_base (int_base+101)
-# define backend_int_last (int_base+125)
+# define backend_int_base (int_base+105)
+# define backend_int_last (int_base+129)
-# define tex_int_pars (126) /* total number of integer parameters */
+# define tex_int_pars (130) /* total number of integer parameters */
# define page_direction_code (tex_int_pars)
# define body_direction_code (tex_int_pars+1)
@@ -637,6 +638,7 @@ extern halfword last_cs_name;
#define disable_kern_par int_par(disable_kern_code)
#define disable_space_par int_par(disable_space_code)
#define scripts_mode_par int_par(math_scripts_mode_code)
+#define nolimits_mode_par int_par(math_nolimits_mode_code)
#define thin_mu_skip_par glue_par(thin_mu_skip_code)
#define med_mu_skip_par glue_par(med_mu_skip_code)
diff --git a/Build/source/texk/web2c/luatexdir/tex/errors.w b/Build/source/texk/web2c/luatexdir/tex/errors.w
index 4cad07c6f28..1af16ec58ef 100644
--- a/Build/source/texk/web2c/luatexdir/tex/errors.w
+++ b/Build/source/texk/web2c/luatexdir/tex/errors.w
@@ -219,6 +219,7 @@ void do_final_end(void)
{
update_terminal();
ready_already = 0;
+ lua_close(Luas); /* new per 0.99 */
if ((history != spotless) && (history != warning_issued))
uexit(1);
else
diff --git a/Build/source/texk/web2c/luatexdir/tex/linebreak.w b/Build/source/texk/web2c/luatexdir/tex/linebreak.w
index fb67eb2fcec..1c8a1e20f69 100644
--- a/Build/source/texk/web2c/luatexdir/tex/linebreak.w
+++ b/Build/source/texk/web2c/luatexdir/tex/linebreak.w
@@ -183,7 +183,7 @@ void line_break(boolean d, int line_break_context)
club_penalty_par,
club_penalties_par_ptr,
(d ? display_widow_penalties_par_ptr : widow_penalties_par_ptr),
- (d ? display_widow_penalty_code : widow_penalty_code),
+ (d ? display_widow_penalty_par : widow_penalty_par),
broken_penalty_par,
final_par_glue);
}
diff --git a/Build/source/texk/web2c/luatexdir/tex/mainbody.w b/Build/source/texk/web2c/luatexdir/tex/mainbody.w
index 0fb8bc4b484..faa6e1992da 100644
--- a/Build/source/texk/web2c/luatexdir/tex/mainbody.w
+++ b/Build/source/texk/web2c/luatexdir/tex/mainbody.w
@@ -449,7 +449,7 @@ void main_body(void)
initialize_math();
fixup_selector(log_opened_global);
check_texconfig_init();
- if ((iloc < ilimit) && (get_cat_code(cat_code_table_code, buffer[iloc]) != escape_cmd))
+ if ((iloc < ilimit) && (get_cat_code(cat_code_table_par, buffer[iloc]) != escape_cmd))
start_input(); /* \.{\\input} assumed */
/* DIR: Initialize |text_dir_ptr| */
text_dir_ptr = new_dir(0);
diff --git a/Build/source/texk/web2c/luatexdir/tex/mlist.w b/Build/source/texk/web2c/luatexdir/tex/mlist.w
index ace56be8627..753ce840cbc 100644
--- a/Build/source/texk/web2c/luatexdir/tex/mlist.w
+++ b/Build/source/texk/web2c/luatexdir/tex/mlist.w
@@ -53,6 +53,7 @@ already apply that shift.
@ @c
#define is_new_mathfont(A) ((font_math_params(A) >0) && (math_old_par == 0))
#define is_old_mathfont(A,B) ((font_math_params(A)==0) && (font_params(A)>=(B)))
+#define do_new_math(A) ((font_math_params(A) >0) && (font_oldmath(A) == 0) && (math_old_par == 0))
@
\def\LuaTeX{Lua\TeX}
@@ -94,7 +95,7 @@ already apply that shift.
} \
} while (0)
-#define font_MATH_par(a,b) \
+#define font_MATH_par(a,b) \
(font_math_params(a)>=b ? font_math_param(a,b) : undefined_math_parameter)
@ here are the math parameters that are font-dependant
@@ -197,7 +198,7 @@ static void math_param_error(const char *param, int style)
static scaled accent_base_height(int f)
{
scaled a;
- if (is_new_mathfont(f)) {
+ if (do_new_math(f)) {
a = font_MATH_par(f, AccentBaseHeight);
if (a == undefined_math_parameter)
a = x_height(f);
@@ -280,6 +281,7 @@ static scaled radical_rule(int var)
@c
#define get_math_param_or_error(a,b) do_get_math_param_or_error(a, math_param_##b, #b)
+#define get_math_param_or_zero(a,b) do_get_math_param_or_zero(a, math_param_##b, #b)
static scaled do_get_math_param_or_error(int var, int param, const char *name)
{
@@ -291,6 +293,15 @@ static scaled do_get_math_param_or_error(int var, int param, const char *name)
return a;
}
+static scaled do_get_math_param_or_zero(int var, int param, const char *name)
+{
+ scaled a = get_math_param(param, var);
+ if (a == undefined_math_parameter) {
+ a = 0;
+ }
+ return a;
+}
+
@ A variant on a suggestion on the list based on analysis by UV.
@c
@@ -365,6 +376,9 @@ static scaled get_delimiter_height(scaled max_d, scaled max_h, boolean axis) {
#define limit_below_bgap(a) get_math_param_or_error(a, limit_below_bgap)
#define limit_below_kern(a) get_math_param_or_error(a, limit_below_kern)
+#define nolimit_sub_factor(a) get_math_param_or_zero(a, nolimit_sub_factor)
+#define nolimit_sup_factor(a) get_math_param_or_zero(a, nolimit_sup_factor)
+
#define sub_shift_drop(a) get_math_param_or_error(a, sub_shift_drop)
#define sup_shift_drop(a) get_math_param_or_error(a, sup_shift_drop)
#define sub_shift_down(a) get_math_param_or_error(a, sub_shift_down)
@@ -563,6 +577,14 @@ void fixup_math_parameters(int fam_id, int size_id, int f, int lvl)
0, lvl);
DEFINE_DMATH_PARAMETERS(math_param_limit_below_kern, size_id,
0, lvl);
+ DEFINE_MATH_PARAMETERS(math_param_nolimit_sub_factor, size_id,
+ font_MATH_par(f, NoLimitSubFactor), lvl); /* bonus */
+ DEFINE_DMATH_PARAMETERS(math_param_nolimit_sub_factor, size_id,
+ font_MATH_par(f, NoLimitSubFactor), lvl); /* bonus */
+ DEFINE_MATH_PARAMETERS(math_param_nolimit_sup_factor, size_id,
+ font_MATH_par(f, NoLimitSupFactor), lvl); /* bonus */
+ DEFINE_DMATH_PARAMETERS(math_param_nolimit_sup_factor, size_id,
+ font_MATH_par(f, NoLimitSupFactor), lvl); /* bonus */
DEFINE_MATH_PARAMETERS(math_param_fraction_rule, size_id,
font_MATH_par(f, FractionRuleThickness), lvl);
@@ -819,6 +841,14 @@ void fixup_math_parameters(int fam_id, int size_id, int f, int lvl)
big_op_spacing5(size_id), lvl);
DEFINE_DMATH_PARAMETERS(math_param_limit_below_kern, size_id,
big_op_spacing5(size_id), lvl);
+ DEFINE_MATH_PARAMETERS(math_param_nolimit_sub_factor, size_id,
+ font_MATH_par(f, NoLimitSubFactor), lvl); /* bonus */
+ DEFINE_DMATH_PARAMETERS(math_param_nolimit_sub_factor, size_id,
+ font_MATH_par(f, NoLimitSubFactor), lvl); /* bonus */
+ DEFINE_MATH_PARAMETERS(math_param_nolimit_sup_factor, size_id,
+ font_MATH_par(f, NoLimitSupFactor), lvl); /* bonus */
+ DEFINE_DMATH_PARAMETERS(math_param_nolimit_sup_factor, size_id,
+ font_MATH_par(f, NoLimitSupFactor), lvl); /* bonus */
DEFINE_MATH_PARAMETERS(math_param_subsup_vgap, size_id,
4 * default_rule_thickness(size_id), lvl);
DEFINE_DMATH_PARAMETERS(math_param_subsup_vgap, size_id,
@@ -991,7 +1021,7 @@ static pointer char_box(internal_font_number f, int c, pointer bb)
{
pointer b, p; /* the new box and its character node */
b = new_null_box();
- if (is_new_mathfont(f))
+ if (do_new_math(f))
width(b) = char_width(f, c);
else
width(b) = char_width(f, c) + char_italic(f, c);
@@ -1404,7 +1434,7 @@ static pointer do_delimiter(pointer q, pointer d, int s, scaled v, boolean flat,
b = get_delim_box(d, ext, f, v, att, cur_style, vlist_node);
}
if (delta != NULL) {
- if (is_new_mathfont(f)) {
+ if (do_new_math(f)) {
*delta = char_vert_italic(f,x);
} else {
*delta = char_italic(f,x);
@@ -1414,12 +1444,12 @@ static pointer do_delimiter(pointer q, pointer d, int s, scaled v, boolean flat,
*stack = true ;
} else {
b = char_box(f, c, att);
- if (!is_new_mathfont(f)) {
+ if (!do_new_math(f)) {
/* italic gets added to width */
width(b) += char_italic(f, c);
}
if (delta != NULL) {
- *delta = char_italic(f,x);
+ *delta = char_italic(f, c); /* was historically (f, x) */
}
if (stack != NULL)
*stack = false ;
@@ -2113,7 +2143,7 @@ static boolean compute_accent_skew(pointer q, int flags, scaled *s)
boolean s_is_absolute = false; /* will be true if a top-accent is placed in |s| */
if (type(nucleus(q)) == math_char_node) {
fetch(nucleus(q));
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
/*
there is no bot_accent so let's assume similarity
@@ -2183,7 +2213,7 @@ static void do_make_math_accent(pointer q, internal_font_number f, int c, int fl
x = clean_box(nucleus(q), cramped_style(cur_style), cur_style);
w = width(x);
h = height(x);
- if (is_new_mathfont(cur_f) && !s_is_absolute) {
+ if (do_new_math(cur_f) && !s_is_absolute) {
s = half(w);
s_is_absolute = true;
}
@@ -2261,7 +2291,7 @@ static void do_make_math_accent(pointer q, internal_font_number f, int c, int fl
} else if ((vlink(q) != null) && (type(nucleus(q)) == math_char_node)) {
/* only pure math char nodes */
internal_font_number f = fam_fnt(math_fam(nucleus(q)),cur_size);
- if (is_new_mathfont(f)) {
+ if (do_new_math(f)) {
ic = char_italic(f,math_character(nucleus(q)));
}
}
@@ -2545,7 +2575,7 @@ static void make_fraction(pointer q, int cur_style)
put the fraction into a box with its delimiters, and make |new_hlist(q)|
point to it
*/
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
if (math_use_old_fraction_scaling_par) {
delta = fraction_del_size_old(cur_style);
} else {
@@ -2610,7 +2640,7 @@ static scaled make_op(pointer q, int cur_style)
small_fam(y) = math_fam(nucleus(q));
small_char(y) = math_character(nucleus(q));
x = do_delimiter(q, y, text_size, ok_size, false, cur_style, true, NULL, &delta);
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
/* we never added italic correction */
} else if ((subscr(q) != null) && (subtype(q) != op_noad_type_limits)) {
/* remove italic correction */
@@ -2628,7 +2658,7 @@ static scaled make_op(pointer q, int cur_style)
delta = char_italic(cur_f, cur_c);
x = clean_box(nucleus(q), cur_style, cur_style);
if (delta != null) {
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
/* we never added italic correction */
} else if ((subscr(q) != null) && (subtype(q) != op_noad_type_limits)) {
/* remove italic correction */
@@ -2642,7 +2672,7 @@ static scaled make_op(pointer q, int cur_style)
delta = char_italic(cur_f, cur_c);
x = clean_box(nucleus(q), cur_style, cur_style);
if (delta != 0) {
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
/* we never added italic correction */
} else if ((subscr(q) != null) && (subtype(q) != op_noad_type_limits)) {
/* remove italic correction */
@@ -2662,15 +2692,56 @@ static scaled make_op(pointer q, int cur_style)
/* we now handle op_nod_type_no_limits here too */
if (subtype(q) == op_noad_type_no_limits) {
- if (is_new_mathfont(cur_f)) {
- if (delta != 0) {
- delta = half(delta) ;
- }
+ if (do_new_math(cur_f)) {
+ /*
+ if (delta != 0) {
+ delta = half(delta) ;
+ }
+ */
p = check_nucleus_complexity(q, &dummy, cur_style);
if ((subscr(q) == null) && (supscr(q) == null)) {
assign_new_hlist(q, p);
} else {
- make_scripts(q, p, 0, cur_style, delta, -delta);
+ /*
+ make_scripts(q, p, 0, cur_style, delta, -delta);
+ */
+ int mode = nolimits_mode_par; /* wins */
+ /*
+ for easy configuration ... fonts are somewhat inconsistent and the
+ values for italic correction run from 30 to 60% of the width
+ */
+ switch (mode) {
+ case 0 :
+ /* as with limits */
+ make_scripts(q, p, 0, cur_style, half(delta), -half(delta));
+ break;
+ case 1 :
+ /* MathConstants driven */
+ make_scripts(q, p, 0, cur_style,
+ round_xn_over_d(delta, nolimit_sup_factor(cur_style), 1000),
+ -round_xn_over_d(delta, nolimit_sub_factor(cur_style), 1000));
+ case 2 :
+ /* no correction */
+ make_scripts(q, p, 0, cur_style, 0, 0);
+ break;
+ case 3 :
+ /* half bottom correction */
+ make_scripts(q, p, 0, cur_style, 0, -half(delta));
+ break;
+ case 4 :
+ /* full bottom correction */
+ make_scripts(q, p, 0, cur_style, 0, -delta);
+ break;
+ default :
+ /* half bottom and top correction */
+ if (mode > 15) {
+ /* for quickly testing values */
+ make_scripts(q, p, 0, cur_style, 0, -round_xn_over_d(delta, mode, 1000));
+ } else {
+ make_scripts(q, p, 0, cur_style, half(delta), -half(delta));
+ }
+ break;
+ }
}
delta = 0;
} else {
@@ -2691,7 +2762,7 @@ static scaled make_op(pointer q, int cur_style)
v = new_null_box();
reset_attributes(v, node_attr(q));
type(v) = vlist_node;
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
n = null;
if (! math_no_italic_compensation_par) {
n = nucleus(q);
@@ -2802,7 +2873,7 @@ static scaled make_op(pointer q, int cur_style)
supscr(q) = null;
}
assign_new_hlist(q, v);
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
delta = 0;
}
}
@@ -2844,7 +2915,7 @@ static void make_ord(pointer q)
fetch(nucleus(q));
a = cur_c;
/* add italic correction */
- if (is_new_mathfont(cur_f) && (char_italic(cur_f,math_character(nucleus(q))) != 0)) {
+ if (do_new_math(cur_f) && (char_italic(cur_f,math_character(nucleus(q))) != 0)) {
p = new_kern(char_italic(cur_f,math_character(nucleus(q))));
reset_attributes(p, node_attr(q));
couple_nodes(p,vlink(q));
@@ -3005,7 +3076,7 @@ static scaled find_math_kern(internal_font_number l_f, int l_c,
{
scaled corr_height_top = 0, corr_height_bot = 0;
scaled krn_l = 0, krn_r = 0, krn = 0;
- if ((!is_new_mathfont(l_f)) || (!is_new_mathfont(r_f)) || (!char_exists(l_f, l_c)) || (!char_exists(r_f, r_c)))
+ if ((!do_new_math(l_f)) || (!do_new_math(r_f)) || (!char_exists(l_f, l_c)) || (!char_exists(r_f, r_c)))
return MATH_KERN_NOT_FOUND;
if (cmd == sup_mark_cmd) {
@@ -3732,14 +3803,14 @@ static pointer check_nucleus_complexity(halfword q, scaled * delta, int cur_styl
fetch(nucleus(q));
if (char_exists(cur_f, cur_c)) {
/* we could look at neighbours */
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
*delta = 0 ; /* cf spec only the last one */
} else {
*delta = char_italic(cur_f, cur_c);
}
p = new_glyph(cur_f, cur_c);
reset_attributes(p, node_attr(nucleus(q)));
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
if (! math_no_char_italic_par) {
/* keep italic, but bad with two successive letters */
} else if (get_char_cat_code(cur_c) == 11) {
@@ -3759,7 +3830,7 @@ static pointer check_nucleus_complexity(halfword q, scaled * delta, int cur_styl
couple_nodes(p,x);
*delta = 0;
}
- if (is_new_mathfont(cur_f)) {
+ if (do_new_math(cur_f)) {
*delta = char_italic(cur_f, cur_c); /* must be more selective */
}
}
diff --git a/Build/source/texk/web2c/luatexdir/tex/texfileio.w b/Build/source/texk/web2c/luatexdir/tex/texfileio.w
index 8b21cd02e71..c222eef975b 100644
--- a/Build/source/texk/web2c/luatexdir/tex/texfileio.w
+++ b/Build/source/texk/web2c/luatexdir/tex/texfileio.w
@@ -107,13 +107,21 @@ static char *find_in_output_directory(const char *s)
@ find an \.{\\input} or \.{\\read} file. |n| differentiates between those case.
@c
+int kpse_available(const char *m) {
+ if (!kpse_init) {
+ fprintf(stdout,"missing kpse replacement callback '%s', quitting\n",m);
+ exit(1);
+ }
+ return 1 ;
+}
+
char *luatex_find_read_file(const char *s, int n, int callback_index)
{
char *ftemp = NULL;
int callback_id = callback_defined(callback_index);
if (callback_id > 0) {
(void) run_callback(callback_id, "dS->R", n, s, &ftemp);
- } else {
+ } else if (kpse_available("find_read_file")) {
/* use kpathsea here */
ftemp = find_in_output_directory(s);
if (!ftemp)
@@ -136,7 +144,7 @@ char *luatex_find_file(const char *s, int callback_index)
if (callback_id > 0) {
(void) run_callback(callback_id, "S->R", s, &ftemp);
- } else {
+ } else if (kpse_available("find_read_file")) {
/* use kpathsea here */
switch (callback_index) {
case find_enc_file_callback:
diff --git a/Build/source/texk/web2c/luatexdir/tex/texmath.h b/Build/source/texk/web2c/luatexdir/tex/texmath.h
index 93e85b46221..e5ad6798257 100644
--- a/Build/source/texk/web2c/luatexdir/tex/texmath.h
+++ b/Build/source/texk/web2c/luatexdir/tex/texmath.h
@@ -155,6 +155,8 @@ typedef enum {
math_param_limit_below_vgap,
math_param_limit_below_bgap,
math_param_limit_below_kern,
+ math_param_nolimit_sub_factor, /* bonus */
+ math_param_nolimit_sup_factor, /* bonus */
math_param_under_delimiter_vgap,
math_param_under_delimiter_bgap,
math_param_over_delimiter_vgap,
@@ -307,6 +309,8 @@ typedef enum {
SubscriptShiftDownWithSuperscript,
FractionDelimiterSize,
FractionDelimiterDisplayStyleSize,
+ NoLimitSubFactor,
+ NoLimitSupFactor,
MATH_param_last,
} MATH_param_codes;
diff --git a/Build/source/texk/web2c/luatexdir/tex/texmath.w b/Build/source/texk/web2c/luatexdir/tex/texmath.w
index 4d588079ce7..b378c662619 100644
--- a/Build/source/texk/web2c/luatexdir/tex/texmath.w
+++ b/Build/source/texk/web2c/luatexdir/tex/texmath.w
@@ -452,6 +452,7 @@ const char *math_param_names[] = {
"fractiondenomvgap", "fractiondenomdown", "fractiondelsize",
"limitabovevgap", "limitabovebgap", "limitabovekern",
"limitbelowvgap", "limitbelowbgap", "limitbelowkern",
+ "nolimitsubfactor", "nolimitsupfactor", /* bonus */
"underdelimitervgap", "underdelimiterbgap",
"overdelimitervgap", "overdelimiterbgap",
"subshiftdrop", "supshiftdrop", "subshiftdown",
diff --git a/Build/source/texk/web2c/luatexdir/tex/texnodes.w b/Build/source/texk/web2c/luatexdir/tex/texnodes.w
index 50fbe95190f..c242577404f 100644
--- a/Build/source/texk/web2c/luatexdir/tex/texnodes.w
+++ b/Build/source/texk/web2c/luatexdir/tex/texnodes.w
@@ -2827,9 +2827,21 @@ void show_node_wrapup_pdf(int p)
@ Recursive calls on |show_node_list| therefore use the following pattern:
@c
#define node_list_display(A) do { \
- append_char('.'); \
- show_node_list(A); \
- flush_char(); \
+ append_char('.'); \
+ show_node_list(A); \
+ flush_char(); \
+} while (0)
+
+#define node_list_display_x(A,B) do { \
+ if ((B) != null) { \
+ append_char('.'); \
+ append_char(A); \
+ append_char(' '); \
+ show_node_list(B); \
+ flush_char(); \
+ flush_char(); \
+ flush_char(); \
+ } \
} while (0)
/* prints a node list symbolically */
@@ -3145,17 +3157,26 @@ void show_node_list(int p)
/* Display discretionary |p|; */
/* The |post_break| list of a discretionary node is indicated by a prefixed
`\.{\char'174}' instead of the `\..' before the |pre_break| list. */
+ /* We're not compatible anyway so ...
+ tprint_esc("discretionary");
+ print_int(disc_penalty(p));
+ print_char('|');
+ if (vlink(no_break(p)) != null) {
+ tprint(" replacing ");
+ node_list_display(vlink(no_break(p)));
+ }
+ node_list_display(vlink(pre_break(p)));
+ append_char('|');
+ show_node_list(vlink(post_break(p)));
+ flush_char();
+ */
tprint_esc("discretionary");
+ tprint(" (penalty ");
print_int(disc_penalty(p));
- print_char('|');
- if (vlink(no_break(p)) != null) {
- tprint(" replacing ");
- node_list_display(vlink(no_break(p)));
- }
- node_list_display(vlink(pre_break(p))); /* recursive call */
- append_char('|');
- show_node_list(vlink(post_break(p)));
- flush_char(); /* recursive call */
+ print_char(')');
+ node_list_display_x('<',vlink(pre_break(p)));
+ node_list_display_x('>',vlink(post_break(p)));
+ node_list_display_x('=',vlink(no_break(p)));
break;
case mark_node:
/* Display mark |p|; */