Skip to content

Commit

Permalink
dvispc: Support upTeX new encoding for combining characters
Browse files Browse the repository at this point in the history
git-svn-id: svn://tug.org/texlive/trunk/Build/source@71093 c570f23f-e606-0410-a88d-b1316a301751
  • Loading branch information
t-tk committed Apr 27, 2024
1 parent 06355f4 commit f2c9992
Show file tree
Hide file tree
Showing 5 changed files with 44 additions and 22 deletions.
2 changes: 1 addition & 1 deletion texk/dviout-util/COPYING
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@

Copyright (c) 1998-2011 Toshio OSHIMA, Yoshiki OTOBE, Kazunori ASAYAMA.
Copyright (c) 2017-2018 Hironobu YAMASHITA
Copyright (c) 2018-2022 Japanese TeX Development Community
Copyright (c) 2018-2024 Japanese TeX Development Community

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
Expand Down
8 changes: 8 additions & 0 deletions texk/dviout-util/ChangeLog
Original file line number Diff line number Diff line change
@@ -1,3 +1,11 @@
2024-04-27 TANAKA Takuji <ttk@t-lab.opal.ne.jp>

* dvispc.c: Support upTeX new encoding
for combining characters.
* configure.ac: Version 20240427.
* COPYING: Copyright year.
https://github.com/texjporg/tex-jp-build/issues/46

2023-09-17 Hironobu Yamashita <h.y.acetaminophen@gmail.com>

* chkdvifont.c: Check JFM with over 256 glue/kern.
Expand Down
22 changes: 11 additions & 11 deletions texk/dviout-util/configure
Original file line number Diff line number Diff line change
@@ -1,6 +1,6 @@
#! /bin/sh
# Guess values for system-dependent variables and create Makefiles.
# Generated by GNU Autoconf 2.72 for dviout-util (TeX Live) 20230917.
# Generated by GNU Autoconf 2.72 for dviout-util (TeX Live) 20240427.
#
# Report bugs to <tex-k@tug.org>.
#
Expand Down Expand Up @@ -614,8 +614,8 @@ MAKEFLAGS=
# Identity of this package.
PACKAGE_NAME='dviout-util (TeX Live)'
PACKAGE_TARNAME='dviout-util--tex-live-'
PACKAGE_VERSION='20230917'
PACKAGE_STRING='dviout-util (TeX Live) 20230917'
PACKAGE_VERSION='20240427'
PACKAGE_STRING='dviout-util (TeX Live) 20240427'
PACKAGE_BUGREPORT='tex-k@tug.org'
PACKAGE_URL=''

Expand Down Expand Up @@ -1365,7 +1365,7 @@ if test "$ac_init_help" = "long"; then
# Omit some internal or obsolete options to make the list less imposing.
# This message is too long to be a string in the A/UX 3.1 sh.
cat <<_ACEOF
'configure' configures dviout-util (TeX Live) 20230917 to adapt to many kinds of systems.
'configure' configures dviout-util (TeX Live) 20240427 to adapt to many kinds of systems.

Usage: $0 [OPTION]... [VAR=VALUE]...

Expand Down Expand Up @@ -1437,7 +1437,7 @@ fi

if test -n "$ac_init_help"; then
case $ac_init_help in
short | recursive ) echo "Configuration of dviout-util (TeX Live) 20230917:";;
short | recursive ) echo "Configuration of dviout-util (TeX Live) 20240427:";;
esac
cat <<\_ACEOF

Expand Down Expand Up @@ -1559,7 +1559,7 @@ fi
test -n "$ac_init_help" && exit $ac_status
if $ac_init_version; then
cat <<\_ACEOF
dviout-util (TeX Live) configure 20230917
dviout-util (TeX Live) configure 20240427
generated by GNU Autoconf 2.72

Copyright (C) 2023 Free Software Foundation, Inc.
Expand Down Expand Up @@ -2101,7 +2101,7 @@ cat >config.log <<_ACEOF
This file contains any messages produced by compilers while
running configure, to aid debugging if configure makes a mistake.

It was created by dviout-util (TeX Live) $as_me 20230917, which was
It was created by dviout-util (TeX Live) $as_me 20240427, which was
generated by GNU Autoconf 2.72. Invocation command line was

$ $0$ac_configure_args_raw
Expand Down Expand Up @@ -8662,7 +8662,7 @@ fi

# Define the identity of the package.
PACKAGE='dviout-util--tex-live-'
VERSION='20230917'
VERSION='20240427'


printf "%s\n" "#define PACKAGE \"$PACKAGE\"" >>confdefs.h
Expand Down Expand Up @@ -15011,7 +15011,7 @@ Usage: $0 [OPTIONS]
Report bugs to <bug-libtool@gnu.org>."

lt_cl_version="\
dviout-util (TeX Live) config.lt 20230917
dviout-util (TeX Live) config.lt 20240427
configured by $0, generated by GNU Autoconf 2.72.

Copyright (C) 2011 Free Software Foundation, Inc.
Expand Down Expand Up @@ -16652,7 +16652,7 @@ cat >>$CONFIG_STATUS <<\_ACEOF || ac_write_fail=1
# report actual input values of CONFIG_FILES etc. instead of their
# values after options handling.
ac_log="
This file was extended by dviout-util (TeX Live) $as_me 20230917, which was
This file was extended by dviout-util (TeX Live) $as_me 20240427, which was
generated by GNU Autoconf 2.72. Invocation command line was

CONFIG_FILES = $CONFIG_FILES
Expand Down Expand Up @@ -16720,7 +16720,7 @@ ac_cs_config_escaped=`printf "%s\n" "$ac_cs_config" | sed "s/^ //; s/'/'\\\\\\\\
cat >>$CONFIG_STATUS <<_ACEOF || ac_write_fail=1
ac_cs_config='$ac_cs_config_escaped'
ac_cs_version="\\
dviout-util (TeX Live) config.status 20230917
dviout-util (TeX Live) config.status 20240427
configured by $0, generated by GNU Autoconf 2.72,
with options \\"\$ac_cs_config\\"

Expand Down
4 changes: 2 additions & 2 deletions texk/dviout-util/configure.ac
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
dnl Process this file with autoconf to produce a configure script.
dnl
dnl Copyright 2018-2023 Japanese TeX Development Community <issue@texjp.org>
dnl Copyright 2018-2024 Japanese TeX Development Community <issue@texjp.org>
dnl
dnl This file is free software; the copyright holder
dnl gives unlimited permission to copy and/or distribute it,
dnl with or without modifications, as long as this notice is preserved.
dnl
AC_INIT([dviout-util (TeX Live)], [20230917], [tex-k@tug.org])
AC_INIT([dviout-util (TeX Live)], [20240427], [tex-k@tug.org])
AC_PREREQ([2.65])
AC_CONFIG_SRCDIR([dvispc.c])
AC_CONFIG_AUX_DIR([../../build-aux])
Expand Down
30 changes: 22 additions & 8 deletions texk/dviout-util/dvispc.c
Original file line number Diff line number Diff line change
Expand Up @@ -1906,8 +1906,8 @@ uint work(FILE *dvi)
uint csum;
#ifdef PTEXENC
int imb;
long wch;
char mbstr[4];
long wch, wcp;
char mbstr[9];
#else
int h_code, l_code;
#endif
Expand Down Expand Up @@ -1963,12 +1963,26 @@ uint work(FILE *dvi)
// internal-euc/sjis: fromDVI cannot convert ASCII range
if (is_internalUPTEX() || (isjis(code>>8) && isjis(code&0xff))) {
wch = fromDVI(code);
if (is_internalUPTEX()) wch = UCStoUTF8(wch);
imb = 0; memset(mbstr, '\0', 4);
if (BYTE1(wch) != 0) mbstr[imb++]=BYTE1(wch);
if (BYTE2(wch) != 0) mbstr[imb++]=BYTE2(wch);
if (BYTE3(wch) != 0) mbstr[imb++]=BYTE3(wch);
/* always */ mbstr[imb++]=BYTE4(wch);
imb = 0; memset(mbstr, '\0', 9);
if (is_internalUPTEX()) {
int j, len;
len = UVS_get_codepoint_length(wch);
for (j=1; j<=len; j++) {
wcp = UVS_get_codepoint_in_sequence(wch,j);
if (wcp>0) {
wcp = UCStoUTF8(wcp);
if (BYTE1(wcp) != 0) mbstr[imb++]=BYTE1(wcp);
if (BYTE2(wcp) != 0) mbstr[imb++]=BYTE2(wcp);
if (BYTE3(wcp) != 0) mbstr[imb++]=BYTE3(wcp);
/* always */ mbstr[imb++]=BYTE4(wcp);
}
}
} else {
if (BYTE1(wch) != 0) mbstr[imb++]=BYTE1(wch);
if (BYTE2(wch) != 0) mbstr[imb++]=BYTE2(wch);
if (BYTE3(wch) != 0) mbstr[imb++]=BYTE3(wch);
/* always */ mbstr[imb++]=BYTE4(wch);
}
fprintf(fp_out,
(f_dtl&DTL_CHAR2)?" %u \"":" 0x%x \"", code);
fputs2(mbstr, fp_out);
Expand Down

0 comments on commit f2c9992

Please sign in to comment.