From f39ecf357dcabe86d7841b9b1f0226ff23936bf5 Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Mon, 29 Apr 2013 23:28:32 +0000 Subject: exsheets (29apr13) git-svn-id: svn://tug.org/texlive/trunk@30166 c570f23f-e606-0410-a88d-b1316a301751 --- .../tex/latex/exsheets/exsheets_headings.def | 72 +++++++++++++--------- 1 file changed, 42 insertions(+), 30 deletions(-) (limited to 'Master/texmf-dist/tex/latex/exsheets/exsheets_headings.def') diff --git a/Master/texmf-dist/tex/latex/exsheets/exsheets_headings.def b/Master/texmf-dist/tex/latex/exsheets/exsheets_headings.def index c9f80403371..7c320340b2c 100644 --- a/Master/texmf-dist/tex/latex/exsheets/exsheets_headings.def +++ b/Master/texmf-dist/tex/latex/exsheets/exsheets_headings.def @@ -298,45 +298,57 @@ } \hcoffin_set:Nn \l__exsheets_heading_points_coffin { - \bool_if:nF { \fp_compare_p:n { #3 = 0 } && \fp_compare_p:n { #4 = 0 } } + \bool_if:NTF \l__exsheets_parse_points_bool { - \tl_use:N \l__exsheets_heading_points_format_tl - \group_begin: - \tl_use:N \l__exsheets_heading_title_format_tl \strut - \group_end: - \tl_use:N \l__exsheets_heading_points_pre_code_tl + \bool_if:nF { \fp_compare_p:n { #3 = 0 } && \fp_compare_p:n { #4 = 0 } } { - \fp_compare:nF { #3 = 0 } - { - \bool_if:nTF - { - \l__exsheets_points_separate_bonus_bool || - \fp_compare_p:n { #4 = 0 } - } - { \exsheets_print_points:n { #3 } } - { \exsheets_parse_points:n { #3 } } - } - \bool_if:nT { !\fp_compare_p:n { #3 = 0 } && !\fp_compare_p:n { #4 = 0 } } - { ~ } - \fp_compare:nF { #4 = 0 } + \tl_use:N \l__exsheets_heading_points_format_tl + \group_begin: + \tl_use:N \l__exsheets_heading_title_format_tl \strut + \group_end: + \tl_use:N \l__exsheets_heading_points_pre_code_tl { - \tl_use:N \l__exsheets_points_pre_bonus_marker_tl - \bool_if:nTF + \fp_compare:nF { #3 = 0 } { - \l__exsheets_points_separate_bonus_bool || - \fp_compare_p:n { #3 = 0 } + \bool_if:nTF + { + \l__exsheets_points_separate_bonus_bool || + \fp_compare_p:n { #4 = 0 } + } + { \exsheets_print_points:n { #3 } } + { \exsheets_parse_points:n { #3 } } } + \bool_if:nT { !\fp_compare_p:n { #3 = 0 } && !\fp_compare_p:n { #4 = 0 } } + { ~ } + \fp_compare:nF { #4 = 0 } { - \exsheets_print_bonus:n { #4 } - \tl_use:N \l__exsheets_points_post_bonus_marker_tl - } - { - \exsheets_parse_bonus:n { #4 } - \tl_use:N \l__exsheets_points_post_bonus_marker_tl - \exsheets_points_name:n { #3 + #4 } + \tl_use:N \l__exsheets_points_pre_bonus_marker_tl + \bool_if:nTF + { + \l__exsheets_points_separate_bonus_bool || + \fp_compare_p:n { #3 = 0 } + } + { + \exsheets_print_bonus:n { #4 } + \tl_use:N \l__exsheets_points_post_bonus_marker_tl + } + { + \exsheets_parse_bonus:n { #4 } + \tl_use:N \l__exsheets_points_post_bonus_marker_tl + \exsheets_points_name:n { #3 + #4 } + } } } + \tl_use:N \l__exsheets_heading_points_post_code_tl } + } + {% points/parse = false + \tl_use:N \l__exsheets_heading_points_format_tl + \group_begin: + \tl_use:N \l__exsheets_heading_title_format_tl \strut + \group_end: + \tl_use:N \l__exsheets_heading_points_pre_code_tl + { \exsheets_print_points:n { #3 } } \tl_use:N \l__exsheets_heading_points_post_code_tl } } -- cgit v1.2.3