1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 247 248 249 250 251 252 253 254 255 256 257 258 259 260 261 262 263 264 265 266 267 268 269 270 271 272 273 274 275 276 277 278 279 280 281 282 283 284 285 286 287 288 289 290 291 292 293 294 295 296 297 298 299 300 301 302 303 304 305 306 307 308 309 310 311 312 313 314 315 316 317 318 319 320 321 322 323 324 325 326 327 328 329 330 331 332 333 334 335 336 337 338 339 340 341 342 343 344 345 346 347 348 349 350 351 352 353 354 355 356 357 358 359 360 361 362 363 364 365 366 367 368 369 370 371 372 373 374 375 376 377 378 379 380 381 382 383 384 385 386 387 388 389 390 391 392 393 394 395 396 397 398 399 400 401 402 403 404 405 406 407 408 409 410 411 412 413 414 415 416 417 418 419 420 421 422 423 424 425 426 427 428 429 430 431 432 433 434 435 436 437 438 439 440 441 442 443 444 445 446 447 448 449 450 451 452 453 454 455 456 457 458 459 460 461 462 463 464 465 466 467 468 469 470 471 472 473 474 475 476 477 478 479 480 481 482 483 484 485 486 487 488 489 490 491 492 493 494 495 496 497 498 499 500 501 502 503 504 505 506 507 508 509 510 511 512 513 514 515 516 517 518 519 520 521 522 523 524 525 526 527 528 529 530 531 532 533 534 535 536 537 538 539 540 541 542 543 544 545 546 547 548 549 550 551 552 553 554 555 556 557 558 559 560 561 562 563 564 565 566 567 568 569 570 571 572 573 574 575 576 577 578 579 580 581 582 583 584 585 586 587 588 589 590 591 592 593 594 595 596 597 598 599 600 601 602 603 604 605 606 607 608 609 610 611 612 613 614 615 616 617 618 619 620 621 622 623 624 625 626 627 628 629 630 631 632 633 634 635 636 637 638 639 640 641 642 643 644 645 646 647 648 649 650 651 652 653 654 655 656 657 658 659 660 661 662 663 664 665 666 667 668 669 670 671 672 673 674 675 676 677 678 679 680 681 682 683 684 685 686 687 688 689 690 691 692 693 694 695 696 697 698 699 700 701 702 703 704 705 706 707 708 709 710 711 712 713 714 715 716 717 718 719 720 721 722 723 724 725 726 727 728 729 730 731 732 733 734 735 736 737 738 739 740 741 742 743 744 745 746 747 748 749 750 751 752 753 754 755 756 757 758 759 760 761 762 763 764 765 766 767 768 769 770 771 772 773 774 775 776 777 778 779 780 781 782 783 784 785 786 787 788 789 790 791 792 793 794 795 796 797 798 799 800 801 802 803 804 805 806 807 808 809 810 811 812 813 814 815 816 817 818 819 820 821 822 823 824 825 826 827 828 829 830 831 832 833 834 835 836 837 838 839 840 841 842 843 844 845 846 847 848 849 850 851 852 853 854 855 856 857 858 859 860 861 862 863 864 865 866 867 868 869 870 871 872 873 874 875 876 877 878 879 880 881 882 883 884 885 886 887 888 889 890 891 892 893 894 895 896 897 898 899 900 901 902 903 904 905 906 907 908 909 910 911 912 913 914 915 916 917 918 919 920 921 922 923 924 925 926 927 928 929 930 931 932 933 934 935 936 937 938 939 940 941 942 943 944 945 946 947 948 949 950 951 952 953 954 955 956 957 958 959 960 961 962 963 964 965 966 967 968 969 970 971 972 973 974 975 976 977 978 979 980 981 982 983 984 985 986 987 988 989 990 991 992 993 994 995 996 997 998 999 1000 1001 1002 1003 1004 1005 1006 1007 1008 1009 1010 1011 1012 1013 1014 1015 1016 1017 1018 1019 1020 1021 1022 1023 1024 1025 1026 1027 1028 1029 1030 1031 1032 1033 1034 1035 1036 1037 1038 1039 1040 1041 1042 1043 1044 1045 1046 1047 1048 1049 1050 1051 1052 1053 1054 1055 1056 1057 1058 1059 1060 1061 1062 1063 1064 1065 1066 1067 1068 1069 1070 1071 1072 1073 1074 1075 1076 1077 1078 1079 1080 1081 1082 1083 1084 1085 1086 1087 1088 1089 1090 1091 1092 1093 1094 1095 1096 1097 1098 1099 1100 1101 1102 1103 1104 1105 1106 1107 1108 1109 1110 1111 1112 1113 1114 1115 1116 1117 1118 1119 1120 1121 1122 1123 1124 1125 1126 1127 1128 1129 1130 1131 1132 1133 1134 1135 1136 1137 1138 1139 1140 1141 1142 1143 1144 1145 1146 1147 1148 1149 1150 1151 1152 1153 1154 1155 1156 1157 1158 1159 1160 1161 1162 1163 1164 1165 1166 1167 1168 1169 1170 1171 1172 1173 1174 1175 1176 1177 1178 1179 1180 1181 1182 1183 1184 1185 1186 1187 1188 1189 1190 1191 1192 1193 1194 1195 1196 1197 1198 1199 1200 1201 1202 1203 1204 1205 1206 1207 1208 1209 1210 1211 1212 1213 1214 1215 1216 1217 1218 1219 1220 1221 1222 1223 1224 1225 1226 1227 1228 1229 1230 1231 1232 1233 1234 1235 1236 1237 1238 1239 1240 1241 1242 1243 1244 1245 1246 1247 1248 1249 1250 1251 1252 1253 1254 1255 1256 1257 1258 1259 1260 1261 1262 1263 1264 1265 1266 1267 1268 1269 1270 1271 1272 1273 1274 1275 1276 1277 1278 1279 1280 1281 1282 1283 1284 1285 1286 1287 1288 1289 1290 1291 1292 1293 1294 1295 1296 1297 1298 1299 1300 1301 1302 1303 1304 1305 1306 1307 1308 1309 1310 1311 1312 1313 1314 1315 1316 1317 1318 1319 1320 1321 1322 1323 1324 1325 1326 1327 1328 1329 1330 1331 1332 1333 1334 1335 1336 1337 1338 1339 1340 1341 1342 1343 1344 1345 1346 1347 1348 1349 1350 1351 1352 1353 1354 1355 1356 1357 1358 1359 1360 1361 1362 1363 1364 1365 1366 1367 1368 1369 1370 1371 1372 1373 1374 1375 1376 1377 1378 1379 1380 1381 1382 1383 1384 1385 1386 1387 1388 1389 1390 1391 1392 1393 1394 1395 1396 1397 1398 1399 1400 1401 1402 1403 1404 1405 1406 1407 1408 1409 1410 1411 1412 1413 1414 1415 1416 1417 1418 1419 1420 1421 1422 1423 1424 1425 1426 1427 1428 1429 1430 1431 1432 1433 1434 1435 1436 1437 1438 1439 1440 1441 1442 1443 1444 1445 1446 1447 1448 1449 1450 1451 1452 1453 1454 1455 1456 1457 1458 1459 1460 1461 1462 1463 1464 1465 1466 1467 1468 1469 1470 1471 1472 1473 1474 1475 1476 1477 1478 1479 1480 1481 1482 1483 1484 1485 1486 1487 1488 1489 1490 1491 1492 1493 1494 1495 1496 1497 1498 1499 1500 1501 1502 1503 1504 1505 1506 1507 1508 1509 1510 1511 1512 1513 1514 1515 1516 1517 1518 1519 1520 1521 1522 1523 1524 1525 1526 1527 1528 1529 1530 1531 1532 1533 1534 1535 1536 1537 1538 1539 1540 1541 1542 1543 1544 1545 1546 1547 1548 1549 1550 1551 1552 1553 1554 1555 1556 1557 1558 1559 1560 1561 1562 1563 1564 1565 1566 1567 1568 1569 1570 1571 1572 1573 1574 1575 1576 1577 1578 1579 1580 1581 1582 1583 1584 1585 1586 1587 1588 1589 1590 1591 1592 1593 1594 1595 1596 1597 1598 1599 1600 1601 1602 1603 1604 1605 1606 1607 1608 1609 1610 1611 1612 1613 1614 1615 1616 1617 1618 1619 1620 1621 1622 1623 1624 1625 1626 1627 1628 1629 1630 1631 1632 1633 1634 1635 1636 1637 1638 1639 1640 1641 1642 1643 1644 1645 1646 1647 1648 1649 1650 1651 1652 1653 1654 1655 1656 1657 1658 1659 1660 1661 1662 1663 1664 1665 1666 1667 1668 1669 1670 1671 1672 1673 1674 1675 1676 1677 1678 1679 1680 1681 1682 1683 1684 1685 1686 1687 1688 1689 1690 1691 1692 1693 1694 1695 1696 1697 1698 1699 1700 1701 1702 1703 1704 1705 1706 1707 1708 1709 1710 1711 1712 1713 1714 1715 1716 1717 1718 1719 1720 1721 1722 1723 1724 1725 1726 1727 1728 1729 1730 1731 1732 1733 1734 1735 1736 1737 1738 1739 1740 1741 1742 1743 1744 1745 1746 1747 1748 1749 1750 1751 1752 1753 1754 1755 1756 1757 1758 1759 1760 1761 1762 1763 1764 1765 1766 1767 1768 1769 1770 1771 1772 1773 1774 1775 1776 1777 1778 1779 1780 1781 1782 1783 1784 1785 1786 1787 1788 1789 1790 1791 1792 1793 1794 1795 1796 1797 1798 1799 1800 1801 1802 1803 1804 1805 1806 1807 1808 1809 1810 1811 1812 1813 1814 1815 1816 1817 1818 1819 1820 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 1837 1838 1839 1840 1841 1842 1843 1844 1845 1846 1847 1848 1849 1850 1851 1852 1853 1854 1855 1856 1857 1858 1859 1860 1861 1862 1863 1864 1865 1866 1867 1868 1869 1870 1871 1872 1873 1874 1875 1876 1877 1878 1879 1880 1881 1882 1883 1884 1885 1886 1887 1888 1889 1890 1891 1892 1893 1894 1895 1896 1897 1898 1899 1900 1901 1902 1903 1904 1905 1906 1907 1908 1909 1910 1911 1912 1913 1914 1915 1916 1917 1918 1919 1920 1921 1922 1923 1924 1925 1926 1927 1928 1929 1930 1931 1932 1933 1934 1935 1936 1937 1938 1939 1940 1941 1942 1943 1944 1945 1946 1947 1948 1949 1950 1951 1952 1953 1954 1955 1956 1957 1958 1959 1960 1961 1962 1963 1964 1965 1966 1967 1968 1969 1970 1971 1972 1973 1974 1975 1976 1977 1978 1979 1980 1981 1982 1983 1984 1985 1986 1987 1988 1989 1990 1991 1992 1993 1994 1995 1996 1997 1998 1999 2000 2001 2002 2003 2004 2005 2006 2007 2008 2009 2010 2011 2012 2013 2014 2015 2016 2017 2018 2019 2020 2021 2022 2023 2024 2025 2026 2027 2028 2029 2030 2031 2032 2033 2034 2035 2036 2037 2038 2039 2040 2041 2042 2043 2044 2045 2046 2047 2048 2049 2050 2051 2052 2053 2054 2055 2056 2057 2058 2059 2060 2061 2062 2063 2064 2065 2066 2067 2068 2069 2070 2071 2072 2073 2074 2075 2076 2077 2078 2079 2080 2081 2082 2083 2084 2085 2086 2087 2088 2089 2090 2091 2092 2093 2094 2095 2096 2097 2098 2099 2100 2101 2102 2103 2104 2105 2106 2107 2108 2109 2110 2111 2112 2113 2114 2115 2116 2117 2118 2119 2120 2121 2122 2123 2124 2125 2126 2127 2128 2129 2130 2131 2132 2133 2134 2135 2136 2137 2138 2139 2140 2141 2142 2143 2144 2145 2146 2147 2148 2149 2150 2151 2152 2153 2154 2155 2156 2157 2158 2159 2160 2161 2162 2163 2164 2165 2166 2167 2168 2169 2170 2171 2172 2173 2174 2175 2176 2177 2178 2179 2180 2181 2182 2183 2184 2185 2186 2187 2188 2189 2190 2191 2192 2193 2194 2195 2196 2197 2198 2199 2200 2201 2202 2203 2204 2205 2206 2207 2208 2209 2210 2211 2212 2213 2214 2215 2216 2217 2218 2219 2220 2221 2222 2223 2224 2225 2226 2227 2228 2229 2230 2231 2232 2233 2234 2235 2236 2237 2238 2239 2240 2241 2242 2243 2244 2245 2246 2247 2248 2249 2250 2251 2252 2253 2254 2255 2256 2257 2258 2259 2260 2261 2262 2263 2264 2265 2266 2267 2268 2269 2270 2271 2272 2273 2274 2275 2276 2277 2278 2279 2280 2281 2282 2283 2284 2285 2286 2287 2288 2289 2290 2291 2292 2293 2294 2295 2296 2297 2298 2299 2300 2301 2302 2303 2304 2305 2306 2307 2308 2309 2310 2311 2312 2313 2314 2315 2316 2317 2318 2319 2320 2321 2322 2323 2324 2325 2326 2327 2328 2329 2330 2331 2332 2333 2334 2335 2336 2337 2338 2339 2340 2341 2342 2343 2344 2345 2346 2347 2348 2349 2350 2351 2352 2353 2354 2355 2356 2357 2358 2359 2360 2361 2362 2363 2364 2365 2366 2367 2368 2369 2370 2371 2372 2373 2374 2375 2376 2377 2378 2379 2380 2381 2382 2383 2384 2385 2386 2387 2388 2389 2390 2391 2392 2393 2394 2395 2396 2397 2398 2399 2400 2401 2402 2403 2404 2405 2406 2407 2408 2409 2410 2411 2412 2413 2414 2415 2416 2417 2418 2419 2420 2421 2422 2423 2424 2425 2426 2427 2428 2429 2430 2431 2432 2433 2434 2435 2436 2437 2438 2439 2440 2441 2442 2443 2444 2445 2446 2447 2448 2449 2450 2451 2452 2453 2454 2455 2456 2457 2458 2459 2460 2461 2462 2463 2464 2465 2466 2467 2468 2469 2470 2471 2472 2473 2474 2475 2476 2477 2478 2479 2480 2481 2482 2483 2484 2485 2486 2487 2488 2489 2490 2491 2492 2493 2494 2495 2496 2497 2498 2499 2500 2501 2502 2503 2504 2505 2506 2507 2508 2509 2510 2511 2512 2513 2514 2515 2516 2517 2518 2519 2520 2521 2522 2523 2524 2525 2526 2527 2528 2529 2530 2531 2532 2533 2534 2535 2536 2537 2538 2539 2540 2541 2542 2543 2544 2545 2546 2547 2548 2549 2550 2551 2552 2553 2554 2555 2556 2557 2558 2559 2560 2561 2562 2563 2564 2565 2566 2567 2568 2569 2570 2571 2572 2573 2574 2575 2576 2577 2578 2579 2580 2581 2582 2583 2584 2585 2586 2587 2588 2589 2590 2591 2592 2593 2594 2595 2596 2597 2598 2599 2600 2601 2602 2603 2604 2605 2606 2607 2608 2609 2610 2611 2612 2613 2614 2615 2616 2617 2618 2619 2620 2621 2622 2623 2624 2625 2626 2627 2628 2629 2630 2631 2632 2633 2634 2635 2636 2637 2638 2639 2640 2641 2642 2643 2644 2645 2646 2647 2648 2649 2650 2651 2652 2653 2654 2655 2656 2657 2658 2659 2660 2661 2662 2663 2664 2665 2666 2667 2668 2669 2670 2671 2672 2673 2674 2675 2676 2677 2678 2679 2680 2681 2682 2683 2684 2685 2686 2687 2688 2689 2690 2691 2692 2693 2694 2695 2696 2697 2698 2699 2700 2701 2702 2703 2704 2705 2706 2707 2708 2709 2710 2711 2712 2713 2714 2715 2716 2717 2718 2719 2720 2721 2722 2723 2724 2725 2726 2727 2728 2729 2730 2731 2732 2733 2734 2735 2736 2737 2738 2739 2740 2741 2742 2743 2744 2745 2746 2747 2748 2749 2750 2751 2752 2753 2754 2755 2756 2757 2758 2759 2760 2761 2762 2763 2764 2765 2766 2767 2768 2769 2770 2771 2772 2773 2774 2775 2776 2777 2778 2779 2780 2781 2782 2783 2784 2785 2786 2787 2788 2789 2790 2791 2792 2793 2794 2795 2796 2797 2798 2799 2800 2801 2802 2803 2804 2805 2806 2807 2808 2809 2810 2811 2812 2813 2814 2815 2816 2817 2818 2819 2820 2821 2822 2823 2824 2825 2826 2827 2828 2829 2830 2831 2832 2833 2834 2835 2836 2837 2838 2839 2840 2841 2842 2843 2844 2845 2846 2847 2848 2849 2850 2851 2852 2853 2854 2855 2856 2857 2858 2859 2860 2861 2862 2863 2864 2865 2866 2867 2868 2869 2870 2871 2872 2873 2874 2875 2876 2877 2878 2879 2880 2881 2882 2883 2884 2885 2886 2887 2888 2889 2890 2891 2892 2893 2894 2895 2896 2897 2898 2899 2900 2901 2902 2903 2904 2905 2906 2907 2908 2909 2910 2911 2912 2913 2914 2915 2916 2917 2918 2919 2920 2921 2922 2923 2924 2925 2926 2927 2928 2929 2930 2931 2932 2933 2934 2935 2936 2937 2938 2939 2940 2941 2942 2943 2944 2945 2946 2947 2948 2949 2950 2951 2952 2953 2954 2955 2956 2957 2958 2959 2960 2961 2962 2963 2964 2965 2966 2967 2968 2969 2970 2971 2972 2973 2974 2975 2976 2977 2978 2979 2980 2981 2982 2983 2984 2985 2986 2987 2988 2989 2990 2991 2992 2993 2994 2995 2996 2997 2998 2999 3000 3001 3002 3003 3004 3005 3006 3007 3008 3009 3010 3011 3012 3013 3014 3015 3016 3017 3018 3019 3020 3021 3022 3023 3024 3025 3026 3027 3028 3029 3030 3031 3032 3033 3034 3035 3036 3037 3038 3039 3040 3041 3042 3043 3044 3045 3046 3047 3048 3049 3050 3051 3052 3053 3054 3055 3056 3057 3058 3059 3060 3061 3062 3063 3064 3065 3066 3067 3068 3069 3070 3071 3072 3073 3074 3075 3076 3077 3078 3079 3080 3081 3082 3083 3084 3085 3086 3087 3088 3089 3090 3091 3092 3093 3094 3095 3096 3097 3098 3099 3100 3101 3102 3103 3104 3105 3106 3107 3108 3109 3110 3111 3112 3113 3114 3115 3116 3117 3118 3119 3120 3121 3122 3123 3124 3125 3126 3127 3128 3129 3130 3131 3132 3133 3134 3135 3136 3137 3138 3139 3140 3141 3142 3143 3144 3145 3146 3147 3148 3149 3150 3151 3152 3153 3154 3155 3156 3157 3158 3159 3160 3161 3162 3163 3164 3165 3166 3167 3168 3169 3170 3171 3172 3173 3174 3175 3176 3177 3178 3179 3180 3181 3182 3183 3184 3185 3186 3187 3188 3189 3190 3191 3192 3193 3194 3195 3196 3197 3198 3199 3200 3201 3202 3203 3204 3205 3206 3207 3208 3209 3210 3211 3212 3213 3214 3215 3216 3217 3218 3219 3220 3221 3222 3223 3224 3225 3226 3227 3228 3229 3230 3231 3232 3233 3234 3235 3236 3237 3238 3239 3240 3241 3242 3243 3244 3245 3246 3247 3248 3249 3250 3251 3252 3253 3254 3255 3256 3257 3258 3259 3260 3261 3262 3263 3264 3265 3266 3267 3268 3269 3270 3271 3272 3273 3274 3275 3276 3277 3278 3279 3280 3281 3282 3283 3284 3285 3286 3287 3288 3289 3290 3291 3292 3293 3294 3295 3296 3297 3298 3299 3300 3301 3302 3303 3304 3305 3306 3307 3308 3309 3310 3311 3312 3313 3314 3315 3316 3317 3318 3319 3320 3321 3322 3323 3324 3325 3326 3327 3328 3329 3330 3331 3332 3333 3334 3335 3336 3337 3338 3339 3340 3341 3342 3343 3344 3345 3346 3347 3348 3349 3350 3351 3352 3353 3354 3355 3356 3357 3358 3359 3360 3361 3362 3363 3364 3365 3366 3367 3368 3369 3370 3371 3372 3373 3374 3375 3376 3377 3378 3379 3380 3381 3382 3383 3384 3385 3386 3387 3388 3389 3390 3391 3392 3393 3394 3395 3396 3397 3398 3399 3400 3401 3402 3403 3404 3405 3406 3407 3408 3409 3410 3411 3412 3413 3414 3415 3416 3417 3418 3419 3420 3421 3422 3423 3424 3425 3426 3427 3428 3429 3430 3431 3432 3433 3434 3435 3436 3437 3438 3439 3440 3441 3442 3443 3444 3445 3446 3447 3448 3449 3450 3451 3452 3453 3454 3455 3456 3457 3458 3459 3460 3461 3462 3463 3464 3465 3466 3467 3468 3469 3470 3471 3472 3473 3474 3475 3476 3477 3478 3479 3480 3481 3482 3483 3484 3485 3486 3487 3488 3489 3490 3491 3492 3493 3494 3495 3496 3497 3498 3499 3500 3501 3502 3503 3504 3505 3506 3507 3508 3509 3510 3511 3512 3513 3514 3515 3516 3517 3518 3519 3520 3521 3522 3523 3524 3525 3526 3527 3528 3529 3530 3531 3532 3533 3534 3535 3536 3537 3538 3539 3540 3541 3542 3543 3544 3545 3546 3547 3548 3549 3550 3551 3552 3553 3554 3555 3556 3557 3558 3559 3560 3561 3562 3563 3564 3565 3566 3567 3568 3569 3570 3571 3572 3573 3574 3575 3576 3577 3578 3579 3580 3581 3582 3583 3584 3585 3586 3587 3588 3589 3590 3591 3592 3593 3594 3595 3596 3597 3598 3599 3600 3601 3602 3603 3604 3605 3606 3607 3608 3609 3610 3611 3612 3613 3614 3615 3616 3617 3618 3619 3620 3621 3622 3623 3624 3625 3626 3627 3628 3629 3630 3631 3632 3633 3634 3635 3636 3637 3638 3639 3640 3641 3642 3643 3644 3645 3646 3647 3648 3649 3650 3651 3652 3653 3654 3655 3656 3657 3658 3659 3660 3661 3662 3663 3664 3665 3666 3667 3668 3669 3670 3671 3672 3673 3674 3675 3676 3677 3678 3679 3680 3681 3682 3683 3684 3685 3686 3687 3688 3689 3690 3691 3692 3693 3694 3695 3696 3697 3698 3699 3700 3701 3702 3703 3704 3705 3706 3707 3708 3709 3710 3711 3712 3713 3714 3715 3716 3717 3718 3719 3720 3721 3722 3723 3724 3725 3726 3727 3728 3729 3730 3731 3732 3733 3734 3735 3736 3737 3738 3739 3740 3741 3742 3743 3744 3745 3746 3747 3748 3749 3750 3751 3752 3753 3754 3755 3756 3757 3758 3759 3760 3761 3762 3763 3764 3765 3766 3767 3768 3769 3770 3771 3772 3773 3774 3775 3776 3777 3778 3779 3780 3781 3782 3783 3784 3785 3786 3787 3788 3789 3790 3791 3792 3793 3794 3795 3796 3797 3798 3799 3800 3801 3802 3803 3804 3805 3806 3807 3808 3809 3810 3811 3812 3813 3814 3815 3816 3817 3818 3819 3820 3821 3822 3823 3824 3825 3826 3827 3828 3829 3830 3831 3832 3833 3834 3835 3836 3837 3838 3839 3840 3841 3842 3843 3844 3845 3846 3847 3848 3849 3850 3851 3852 3853 3854 3855 3856 3857 3858 3859 3860 3861 3862 3863 3864 3865 3866 3867 3868 3869 3870 3871 3872 3873 3874 3875 3876 3877 3878 3879 3880 3881 3882 3883 3884 3885 3886 3887 3888 3889 3890 3891 3892 3893 3894 3895 3896 3897 3898 3899 3900 3901 3902 3903 3904 3905 3906 3907 3908 3909 3910 3911 3912 3913 3914 3915 3916 3917 3918 3919 3920 3921 3922 3923 3924 3925 3926 3927 3928 3929 3930 3931 3932 3933 3934 3935 3936 3937 3938 3939 3940 3941 3942 3943 3944 3945 3946 3947 3948 3949 3950 3951 3952 3953 3954 3955 3956 3957 3958 3959 3960 3961 3962 3963 3964 3965 3966 3967 3968 3969 3970 3971 3972 3973 3974 3975 3976 3977 3978 3979 3980 3981 3982 3983 3984 3985 3986 3987 3988 3989 3990 3991 3992 3993 3994 3995 3996 3997 3998 3999 4000 4001 4002 4003 4004 4005 4006 4007 4008 4009 4010 4011 4012 4013 4014 4015 4016 4017 4018 4019 4020 4021 4022 4023 4024 4025 4026 4027 4028 4029 4030 4031 4032 4033 4034 4035 4036 4037 4038 4039 4040 4041 4042 4043 4044 4045 4046 4047 4048 4049 4050 4051 4052 4053 4054 4055 4056 4057 4058 4059 4060 4061 4062 4063 4064 4065 4066 4067 4068 4069 4070 4071 4072 4073 4074 4075 4076 4077 4078 4079 4080 4081 4082 4083 4084 4085 4086 4087 4088 4089 4090 4091 4092 4093 4094 4095 4096 4097 4098 4099 4100 4101 4102 4103 4104 4105 4106 4107 4108 4109 4110 4111 4112 4113 4114 4115 4116 4117 4118 4119 4120 4121 4122 4123 4124 4125 4126 4127 4128 4129 4130 4131 4132 4133 4134 4135 4136 4137 4138 4139 4140 4141 4142 4143 4144 4145 4146 4147 4148 4149 4150 4151 4152 4153 4154 4155 4156 4157 4158 4159 4160 4161 4162 4163 4164 4165 4166 4167 4168 4169 4170 4171 4172 4173 4174 4175 4176 4177 4178 4179 4180 4181 4182 4183 4184 4185 4186 4187 4188 4189 4190 4191 4192 4193 4194 4195 4196 4197 4198 4199 4200 4201 4202 4203 4204 4205 4206 4207 4208 4209 4210 4211 4212 4213 4214 4215 4216 4217 4218 4219 4220 4221 4222 4223 4224 4225 4226 4227 4228 4229 4230 4231 4232 4233 4234 4235 4236 4237 4238 4239 4240 4241 4242 4243 4244 4245 4246 4247 4248 4249 4250 4251 4252 4253 4254 4255 4256 4257 4258 4259 4260 4261 4262 4263 4264 4265 4266 4267 4268 4269 4270 4271 4272 4273 4274 4275 4276 4277 4278 4279 4280 4281 4282 4283 4284 4285 4286 4287 4288 4289 4290 4291 4292 4293 4294 4295 4296 4297 4298 4299 4300 4301 4302 4303 4304 4305 4306 4307 4308 4309 4310 4311 4312 4313 4314 4315 4316 4317 4318 4319 4320 4321 4322 4323 4324 4325 4326 4327 4328 4329 4330 4331 4332 4333 4334 4335 4336 4337 4338 4339 4340 4341 4342 4343 4344 4345 4346 4347 4348 4349 4350 4351 4352 4353 4354 4355 4356 4357 4358 4359 4360 4361 4362 4363 4364 4365 4366 4367 4368 4369 4370 4371 4372 4373 4374 4375 4376 4377 4378 4379 4380 4381 4382 4383 4384 4385 4386 4387 4388 4389 4390 4391 4392 4393 4394 4395 4396 4397 4398 4399 4400 4401 4402 4403 4404 4405 4406 4407 4408 4409 4410 4411 4412 4413 4414 4415 4416 4417 4418 4419 4420 4421 4422 4423 4424 4425 4426 4427 4428 4429 4430 4431 4432 4433 4434 4435 4436 4437 4438 4439 4440 4441 4442 4443 4444 4445 4446 4447 4448 4449 4450 4451 4452 4453 4454 4455 4456 4457 4458 4459 4460 4461 4462 4463 4464 4465 4466 4467 4468 4469 4470 4471 4472 4473 4474 4475 4476 4477 4478 4479 4480 4481 4482 4483 4484 4485 4486 4487 4488 4489 4490 4491 4492 4493 4494 4495 4496 4497 4498 4499 4500 4501 4502 4503 4504 4505 4506 4507 4508 4509 4510 4511 4512 4513 4514 4515 4516 4517 4518 4519 4520 4521 4522 4523 4524 4525 4526 4527 4528 4529 4530 4531 4532 4533 4534 4535 4536 4537 4538 4539 4540 4541 4542 4543 4544 4545 4546 4547 4548 4549 4550 4551 4552 4553 4554 4555 4556 4557 4558 4559 4560 4561 4562 4563 4564 4565 4566 4567 4568 4569 4570 4571 4572 4573 4574 4575 4576 4577 4578 4579 4580 4581 4582 4583 4584 4585 4586 4587 4588 4589 4590 4591 4592 4593 4594 4595 4596 4597 4598 4599 4600 4601 4602 4603 4604 4605 4606 4607 4608 4609 4610 4611 4612 4613 4614 4615 4616 4617 4618 4619 4620 4621 4622 4623 4624 4625 4626 4627 4628 4629 4630 4631 4632 4633 4634 4635 4636 4637 4638 4639 4640 4641 4642 4643 4644 4645 4646 4647 4648 4649 4650 4651 4652 4653 4654 4655 4656 4657 4658 4659 4660 4661 4662 4663 4664 4665 4666 4667 4668 4669 4670 4671 4672 4673 4674 4675 4676 4677 4678 4679 4680 4681 4682 4683 4684 4685 4686 4687 4688 4689 4690 4691 4692 4693 4694 4695 4696 4697 4698 4699 4700 4701 4702 4703 4704 4705 4706 4707 4708 4709 4710 4711 4712 4713 4714 4715 4716 4717 4718 4719 4720 4721 4722 4723 4724 4725 4726 4727 4728 4729 4730 4731 4732 4733 4734 4735 4736 4737 4738 4739 4740 4741 4742 4743 4744 4745 4746 4747 4748 4749 4750 4751 4752 4753 4754 4755 4756 4757 4758 4759 4760 4761 4762 4763 4764 4765 4766 4767 4768 4769 4770 4771 4772 4773 4774 4775 4776 4777 4778 4779 4780 4781 4782 4783 4784 4785 4786 4787 4788 4789 4790 4791 4792 4793 4794 4795 4796 4797 4798 4799 4800 4801 4802 4803 4804 4805 4806 4807 4808 4809 4810 4811 4812 4813 4814 4815 4816 4817 4818 4819 4820 4821 4822 4823 4824 4825 4826 4827 4828 4829 4830 4831 4832 4833 4834 4835 4836 4837 4838 4839 4840 4841 4842 4843 4844 4845 4846 4847 4848 4849 4850 4851 4852 4853 4854 4855 4856 4857 4858 4859 4860 4861 4862 4863 4864 4865 4866 4867 4868 4869 4870 4871 4872 4873 4874 4875 4876 4877 4878 4879 4880 4881 4882 4883 4884 4885 4886 4887 4888 4889 4890 4891 4892 4893 4894 4895 4896 4897 4898 4899 4900 4901 4902 4903 4904 4905 4906 4907 4908 4909 4910 4911 4912 4913 4914 4915 4916 4917 4918 4919 4920 4921 4922 4923 4924 4925 4926 4927 4928 4929 4930 4931 4932 4933 4934 4935 4936 4937 4938 4939 4940 4941 4942 4943 4944 4945 4946 4947 4948 4949 4950 4951 4952 4953 4954 4955 4956 4957 4958 4959 4960 4961 4962 4963 4964 4965 4966 4967 4968 4969 4970 4971 4972 4973 4974 4975 4976 4977 4978 4979 4980 4981 4982 4983 4984 4985 4986 4987 4988 4989 4990 4991 4992 4993 4994 4995 4996 4997 4998 4999 5000 5001 5002 5003 5004 5005 5006 5007 5008 5009 5010 5011 5012 5013 5014 5015 5016 5017 5018 5019 5020 5021 5022 5023 5024 5025 5026 5027 5028 5029 5030 5031 5032 5033 5034 5035 5036 5037 5038 5039 5040 5041 5042 5043 5044 5045 5046 5047 5048 5049 5050 5051 5052 5053 5054 5055 5056 5057 5058 5059 5060 5061 5062 5063 5064 5065 5066 5067 5068 5069 5070 5071 5072 5073 5074 5075 5076 5077 5078 5079 5080 5081 5082 5083 5084 5085 5086 5087 5088 5089 5090 5091 5092 5093 5094 5095 5096 5097 5098 5099 5100 5101 5102 5103 5104 5105 5106 5107 5108 5109 5110 5111 5112 5113 5114 5115 5116 5117 5118 5119 5120 5121 5122 5123 5124 5125 5126 5127 5128 5129 5130 5131 5132 5133 5134 5135 5136 5137 5138 5139 5140 5141 5142 5143 5144 5145 5146 5147 5148 5149 5150 5151 5152 5153 5154 5155 5156 5157 5158 5159 5160 5161 5162 5163 5164 5165 5166 5167 5168 5169 5170 5171 5172 5173 5174 5175 5176 5177 5178 5179 5180 5181 5182 5183 5184 5185 5186 5187 5188 5189 5190 5191 5192 5193 5194 5195 5196 5197 5198 5199 5200 5201 5202 5203 5204 5205 5206 5207 5208 5209 5210 5211 5212 5213 5214 5215 5216 5217 5218 5219 5220 5221 5222 5223 5224 5225 5226 5227 5228 5229 5230 5231 5232 5233 5234 5235 5236 5237 5238 5239 5240 5241 5242 5243 5244 5245 5246 5247 5248 5249 5250 5251 5252 5253 5254 5255 5256 5257 5258 5259 5260 5261 5262 5263 5264 5265 5266 5267 5268 5269 5270 5271 5272 5273 5274 5275 5276 5277 5278 5279 5280 5281 5282 5283 5284 5285 5286 5287 5288 5289 5290 5291 5292 5293 5294 5295 5296 5297 5298 5299 5300 5301 5302 5303 5304 5305 5306 5307 5308 5309 5310 5311 5312 5313 5314 5315 5316 5317 5318 5319 5320 5321 5322 5323 5324 5325 5326 5327 5328 5329 5330 5331 5332 5333 5334 5335 5336 5337 5338 5339 5340 5341 5342 5343 5344 5345 5346 5347 5348 5349 5350 5351 5352 5353 5354 5355 5356 5357 5358 5359 5360 5361 5362 5363 5364 5365 5366 5367 5368 5369 5370 5371 5372 5373 5374 5375 5376 5377 5378 5379 5380 5381 5382 5383 5384 5385 5386 5387 5388 5389 5390 5391 5392 5393 5394 5395 5396 5397 5398 5399 5400 5401 5402 5403 5404 5405 5406 5407 5408 5409 5410 5411 5412 5413 5414 5415 5416 5417 5418 5419 5420 5421 5422 5423 5424 5425 5426 5427 5428 5429 5430 5431 5432 5433 5434 5435 5436 5437 5438 5439 5440 5441 5442 5443 5444 5445 5446 5447 5448 5449 5450 5451 5452 5453 5454 5455 5456 5457 5458 5459 5460 5461 5462 5463 5464 5465 5466 5467 5468 5469 5470 5471 5472 5473 5474 5475 5476 5477 5478 5479 5480 5481 5482 5483 5484 5485 5486 5487 5488 5489 5490 5491 5492 5493 5494 5495 5496 5497 5498 5499 5500 5501 5502 5503 5504 5505 5506 5507 5508 5509 5510 5511 5512 5513 5514 5515 5516 5517 5518 5519 5520 5521 5522 5523 5524 5525 5526 5527 5528 5529 5530 5531 5532 5533 5534 5535 5536 5537 5538 5539 5540 5541 5542 5543 5544 5545 5546 5547 5548 5549 5550 5551 5552 5553 5554 5555 5556 5557 5558 5559 5560 5561 5562 5563 5564 5565 5566 5567 5568 5569 5570 5571 5572 5573 5574 5575 5576 5577 5578 5579 5580 5581 5582 5583 5584 5585 5586 5587 5588 5589 5590 5591 5592 5593 5594 5595 5596 5597 5598 5599 5600 5601 5602 5603 5604 5605 5606 5607 5608 5609 5610 5611 5612 5613 5614 5615 5616 5617 5618 5619 5620 5621 5622 5623 5624 5625 5626 5627 5628 5629 5630 5631 5632 5633 5634 5635 5636 5637 5638 5639 5640 5641 5642 5643 5644 5645 5646 5647 5648 5649 5650 5651 5652 5653 5654 5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 5728 5729 5730 5731 5732 5733 5734 5735 5736 5737 5738 5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 5813 5814 5815 5816 5817 5818 5819 5820 5821 5822 5823 5824 5825 5826 5827 5828 5829 5830 5831 5832 5833 5834 5835 5836 5837 5838 5839 5840 5841 5842 5843 5844 5845 5846 5847 5848 5849 5850 5851 5852 5853 5854 5855 5856 5857 5858 5859 5860 5861 5862 5863 5864 5865 5866 5867 5868 5869 5870 5871 5872 5873 5874 5875 5876 5877 5878 5879 5880 5881 5882 5883 5884 5885 5886 5887 5888 5889 5890 5891 5892 5893 5894 5895 5896 5897 5898 5899 5900 5901 5902 5903 5904 5905 5906 5907 5908 5909 5910 5911 5912 5913 5914 5915 5916 5917 5918 5919 5920 5921 5922 5923 5924 5925 5926 5927 5928 5929 5930 5931 5932 5933 5934 5935 5936 5937 5938 5939 5940 5941 5942 5943 5944 5945 5946 5947 5948 5949 5950 5951 5952 5953 5954 5955 5956 5957 5958 5959 5960 5961 5962 5963 5964 5965 5966 5967 5968 5969 5970 5971 5972 5973 5974 5975 5976 5977 5978 5979 5980 5981 5982 5983 5984 5985 5986 5987 5988 5989 5990 5991 5992 5993 5994 5995 5996 5997 5998 5999 6000 6001 6002 6003 6004 6005 6006 6007 6008 6009 6010 6011 6012 6013 6014 6015 6016 6017 6018 6019 6020 6021 6022 6023 6024 6025 6026 6027 6028 6029 6030 6031 6032 6033 6034 6035 6036 6037 6038 6039 6040 6041 6042 6043 6044 6045 6046 6047 6048 6049 6050 6051 6052 6053 6054 6055 6056 6057 6058 6059 6060 6061 6062 6063 6064 6065 6066 6067 6068 6069 6070 6071 6072 6073 6074 6075 6076 6077 6078 6079 6080 6081 6082 6083 6084 6085 6086 6087 6088 6089 6090 6091 6092 6093 6094 6095 6096 6097 6098 6099 6100 6101 6102 6103 6104 6105 6106 6107 6108 6109 6110 6111 6112 6113 6114 6115 6116 6117 6118 6119 6120 6121 6122 6123 6124 6125 6126 6127 6128 6129
|
% ^^A -*- japanese-latex -*-
%
\ifx\epTeXinputencoding\undefined\else
\epTeXinputencoding utf8 % ^^A added (2017-10-04)
\fi
%
% \iffalse meta-comment
%
% pLaTeX2ε新ドキュメントクラス(日本語 TeX 開発コミュニティ版)
% 原作者:奥村晴彦 <okumura@okumuralab.org>
%
% Copyright 1993-2022
% The LaTeX3 Project and any individual authors listed elsewhere
% in this file.
%
% Copyright 1995-1999 ASCII Corporation.
% Copyright 1999-2016 Haruhiko Okumura
% Copyright 2016-2022 Japanese TeX Development Community
%
% \fi
%
% \iffalse
%
% \begin{macrocode}
\NeedsTeXFormat{pLaTeX2e}
%<article>\ProvidesClass{jsarticle}
%<book>\ProvidesClass{jsbook}
%<report>\ProvidesClass{jsreport}
%<jspf>\ProvidesClass{jspf}
%<kiyou>\ProvidesClass{kiyou}
%<minijs>\ProvidesPackage{minijs}
%<*driver>
\ProvidesFile{jsclasses.dtx}
%</driver>
[2022/09/13 jsclasses (okumura, texjporg)]
%<*driver>
\RequirePackage{plautopatch}
\documentclass[dvipdfmx]{jsarticle}
\usepackage{doc}
\xspcode"5C=1 %% \
\xspcode"22=1 %% "
\addtolength{\textwidth}{-1in}
\addtolength{\evensidemargin}{1in}
\addtolength{\oddsidemargin}{1in}
\addtolength{\marginparwidth}{1in}
\setlength\marginparpush{0pt}
% \OnlyDescription
\CodelineNumbered
\DisableCrossrefs
\setcounter{StandardModuleDepth}{1}
\GetFileInfo{jsclasses.dtx}
\begin{document}
\DocInput{jsclasses.dtx}
\end{document}
%</driver>
% \end{macrocode}
%
% \fi
%
% \title{\pLaTeXe 新ドキュメントクラス}
% \author{奥村晴彦,日本語\TeX 開発コミュニティ}
% \date{\filedate}
% \maketitle
%
% \MakeShortVerb{\|}
%
% \section{はじめに}
%
% これは\LaTeX3 Projectの \texttt{classes.dtx} と
% 株式会社アスキーの \texttt{jclasses.dtx} に基づいて
% もともと奥村晴彦により作成されたものです。
% 現在は日本語\TeX 開発コミュニティによりGitHubで管理されています。
% \begin{quote}
% |https://github.com/texjporg/jsclasses|
% \end{quote}
%
% [2002-12-19] いろいろなものに収録していただく際にライセンスを明確にする
% 必要が生じてきました。アスキーのものが最近はmodified BSDライセンスになっ
% ていますので,私のものもそれに準じてmodified BSDとすることにします。
%
% [2016-07-13] 日本語\TeX 開発コミュニティによる管理に移行しました。
%
% [2009-02-22] 田中琢爾氏によるup\LaTeX 対応パッチを取り込みました。
%
% ここでは次のドキュメントクラス(スタイルファイル)を作ります。
%
% [2017-02-13] forum:2121の議論を機に,jsreportクラスを新設しました。
% 従来のjsbookの |report| オプションと比べると,|abstract| 環境の使い方
% および挙動がアスキーのjreportに近づきました。
%
% \begin{quote}
% \begin{tabular}{lll}
% $\langle$\textsf{article}$\rangle$ & \texttt{jsarticle.cls} & 論文・レポート用 \\
% $\langle$\textsf{book}$\rangle$ & \texttt{jsbook.cls} & 書籍用 \\
% $\langle$\textsf{report}$\rangle$ & \texttt{jsreport.cls} & レポート用 \\
% $\langle$\textsf{jspf}$\rangle$ & \texttt{jspf.cls} & 某学会誌用 \\
% $\langle$\textsf{kiyou}$\rangle$ & \texttt{kiyou.cls} & 某紀要用
% \end{tabular}
% \end{quote}
%
% \LaTeXe あるいは\pLaTeXe 標準のドキュメントクラスとの違いを説明してお
% きます。
%
% \paragraph{JISフォントメトリックの使用}
%
% ここでは和文TFM(\TeX フォントメトリック)として東京書籍印刷の小林肇さ
% んの作られたJISフォントメトリック \texttt{jis.tfm},\texttt{jisg.tfm}
% を標準で使います。従来のフォントメトリック \texttt{min10.tfm},
% \texttt{goth10.tfm} の類を使うには
% \begin{quote}
% |\documentclass[mingoth]{jsarticle}|
% \end{quote}
% のように \texttt{mingoth} オプションを付けます。
%
% \paragraph{サイズオプションの扱いが違う}
%
% 標準のドキュメントクラスでは本文のポイント数を指定するオプションがあり
% ましたが,ポイント数は10,11,12しかなく,それぞれ別のクラスオプション
% ファイルを読み込むようになっていました。しかも,標準の10ポイント以外で
% は多少フォントのバランスが崩れることがあり,あまり便利ではありませんで
% した。ここでは文字サイズを増すとページを小さくし,\TeX の |\mag| プリ
% ミティブで全体的に拡大するという手を使って,9ポイントや21,25,30,36,
% 43ポイント,12Q,14Qの指定を可能にしています。
%
% \StopEventually{}
%
% 以下では実際のコードに即して説明します。
%
% \texttt{minijs}は,\texttt{jsclasses}に似た設定を行うパッケージです。
%
% \begin{macrocode}
%<*minijs>
%% if jsclasses loaded, abort loading this package
\ifx\@jsc@uplatextrue\@undefined\else
\PackageInfo{minijs}{jsclasses does not need minijs, exiting}
\expandafter\endinput
\fi
%% "fake" jsarticle
\expandafter\def\csname ver@jsarticle.cls\endcsname{}
%</minijs>
% \end{macrocode}
%
% \begin{macro}{\jsc@clsname}
%
% 文書クラスの名前です。エラーメッセージ表示などで使われます。
%
% \begin{macrocode}
%<*class>
%<article>\def\jsc@clsname{jsarticle}
%<book>\def\jsc@clsname{jsbook}
%<report>\def\jsc@clsname{jsreport}
%<jspf>\def\jsc@clsname{jspf}
%<kiyou>\def\jsc@clsname{kiyou}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\ifjsc@needsp@tch}
%
% [2016-08-22] 従来\texttt{jsclasses}では,\pLaTeX や\LaTeX の
% 不都合な点に対して,クラスファイル内で独自に対策を施していま
% した。しかし,2016年以降,コミュニティ版\pLaTeX が次第に対策
% コードをカーネル内に取り込むようになりました。そこで,新しい
% \pLaTeX カーネルと衝突しないように,日付が古い場合だけパッチ
% をあてる場合があります。この処理に使用するフラグを定義します。
%
% \begin{macrocode}
%</class>
%<*class|minijs>
\newif\ifjsc@needsp@tch
\jsc@needsp@tchfalse
%</class|minijs>
%<*class>
% \end{macrocode}
% \end{macro}
%
% \section{オプション}
%
% これらのクラスは |\documentclass{jsarticle}|
% あるいは |\documentclass[オプション]{jsarticle}|
% のように呼び出します。
%
% まず,オプションに関連するいくつかのコマンドやスイッチ(論理変数)を定
% 義します。
%
% \begin{macro}{\if@restonecol}
%
% 段組のときに真になる論理変数です。
%
% \begin{macrocode}
\newif\if@restonecol
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\if@titlepage}
%
% これを真にすると表題,概要を独立したページに出力します。
%
% \begin{macrocode}
\newif\if@titlepage
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\if@openright}
%
% |\chapter|,|\part| を右ページ起こしにするかどうかです。
% 横組の書籍では真が標準で,要するに片起こし,奇数ページ起こしになります。
%
% \begin{macrocode}
%<book|report>\newif\if@openright
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\if@openleft}
%
% [2017-02-24] |\chapter|,|\part| を左ページ起こしにするかどうかです。
%
% \begin{macrocode}
%<book|report>\newif\if@openleft
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\if@mainmatter}
%
% 真なら本文,偽なら前付け・後付けです。
% 偽なら |\chapter| で章番号が出ません。
%
% \begin{macrocode}
%<book>\newif\if@mainmatter \@mainmattertrue
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\if@enablejfam}
%
% 和文フォントを数式フォントとして登録するかどうかを示すスイッチです。
%
% \begin{macrocode}
\newif\if@enablejfam \@enablejfamtrue
% \end{macrocode}
% \end{macro}
%
% 以下で各オプションを宣言します。
%
% \paragraph{用紙サイズ}
%
% JISやISOのA0判は面積 $1\,\mathrm{m}^2$,縦横比 $1:\sqrt{2}$
% の長方形の辺の長さを mm 単位に切り捨てたものです。
% これを基準として順に半截しては mm 単位に切り捨てたものがA1,A2,…です。
%
% B判はJISとISOで定義が異なります。
% JISではB0判の面積が $1.5\,\mathrm{m}^2$ ですが,
% ISOではB1判の辺の長さがA0判とA1判の辺の長さの幾何平均です。
% したがってISOのB0判は $1000\,\mathrm{mm} \times 1414\,\mathrm{mm}$ です。
% このため,\LaTeXe の \texttt{b5paper}
% は $250\,\mathrm{mm} \times 176\,\mathrm{mm}$ ですが,
% \pLaTeXe の \texttt{b5paper}
% は $257\,\mathrm{mm} \times 182\,\mathrm{mm}$ になっています。
% ここでは\pLaTeXe にならってJISに従いました。
%
% デフォルトは \texttt{a4paper} です。
%
% \texttt{b5var}(B5変形,182mm×230mm),
% \texttt{a4var}(A4変形,210mm×283mm)を追加しました。
%
% \begin{macrocode}
\DeclareOption{a3paper}{%
\setlength\paperheight {420mm}%
\setlength\paperwidth {297mm}}
\DeclareOption{a4paper}{%
\setlength\paperheight {297mm}%
\setlength\paperwidth {210mm}}
\DeclareOption{a5paper}{%
\setlength\paperheight {210mm}%
\setlength\paperwidth {148mm}}
\DeclareOption{a6paper}{%
\setlength\paperheight {148mm}%
\setlength\paperwidth {105mm}}
\DeclareOption{b4paper}{%
\setlength\paperheight {364mm}%
\setlength\paperwidth {257mm}}
\DeclareOption{b5paper}{%
\setlength\paperheight {257mm}%
\setlength\paperwidth {182mm}}
\DeclareOption{b6paper}{%
\setlength\paperheight {182mm}%
\setlength\paperwidth {128mm}}
\DeclareOption{a4j}{%
\setlength\paperheight {297mm}%
\setlength\paperwidth {210mm}}
\DeclareOption{a5j}{%
\setlength\paperheight {210mm}%
\setlength\paperwidth {148mm}}
\DeclareOption{b4j}{%
\setlength\paperheight {364mm}%
\setlength\paperwidth {257mm}}
\DeclareOption{b5j}{%
\setlength\paperheight {257mm}%
\setlength\paperwidth {182mm}}
\DeclareOption{a4var}{%
\setlength\paperheight {283mm}%
\setlength\paperwidth {210mm}}
\DeclareOption{b5var}{%
\setlength\paperheight {230mm}%
\setlength\paperwidth {182mm}}
\DeclareOption{letterpaper}{%
\setlength\paperheight {11in}%
\setlength\paperwidth {8.5in}}
\DeclareOption{legalpaper}{%
\setlength\paperheight {14in}%
\setlength\paperwidth {8.5in}}
\DeclareOption{executivepaper}{%
\setlength\paperheight {10.5in}%
\setlength\paperwidth {7.25in}}
% \end{macrocode}
%
% \paragraph{横置き}
%
% 用紙の縦と横の長さを入れ換えます。
%
% \begin{macrocode}
\newif\if@landscape
\@landscapefalse
\DeclareOption{landscape}{\@landscapetrue}
% \end{macrocode}
%
% \paragraph{slide}
%
% オプション \texttt{slide} を新設しました。
%
% [2016-10-08] \texttt{slide} オプションは article 以外では使い物にならなかったので,
% 簡単のため article のみで使えるオプションとしました。
%
% \begin{macrocode}
\newif\if@slide
\@slidefalse
% \end{macrocode}
%
% \paragraph{サイズオプション}
%
% 10pt,11pt,12pt のほかに,8pt,9pt,14pt,17pt,21pt,25pt,30pt,36pt,43pt を追加しました。
% これは等比数列になるように選んだものです(従来の 20pt も残しました)。
% |\@ptsize| の定義が変だったのでご迷惑をおかけしましたが,
% 標準的なドキュメントクラスと同様にポイント数から10を引いたものに直しました。
%
% [2003-03-22] 14Qオプションを追加しました。
%
% [2003-04-18] 12Qオプションを追加しました。
%
% [2016-07-08] |\mag| を使わずに各種寸法をスケールさせるためのオプション \texttt{nomag} を新設しました。
% \texttt{usemag} オプションの指定で従来通りの動作となります。デフォルトは \texttt{usemag} です。
%
% [2016-07-24] オプティカルサイズを調整するためにNFSSへパッチを当てるオプション \texttt{nomag*} を新設しました。
%
% \begin{macrocode}
\newcommand{\@ptsize}{0}
\newif\ifjsc@mag\jsc@magtrue
\newif\ifjsc@mag@xreal\jsc@mag@xrealfalse
\def\jsc@magscale{1}
%<*article>
\DeclareOption{slide}{%
\@slidetrue\def\jsc@magscale{3.583}
\renewcommand{\@ptsize}{26}
\@landscapetrue\@titlepagetrue}
%</article>
\DeclareOption{8pt}{\def\jsc@magscale{0.833}\renewcommand{\@ptsize}{-2}}
\DeclareOption{9pt}{\def\jsc@magscale{0.913}\renewcommand{\@ptsize}{-1}}
\DeclareOption{10pt}{\def\jsc@magscale{1}\renewcommand{\@ptsize}{0}}
\DeclareOption{11pt}{\def\jsc@magscale{1.095}\renewcommand{\@ptsize}{1}}
\DeclareOption{12pt}{\def\jsc@magscale{1.200}\renewcommand{\@ptsize}{2}}
\DeclareOption{14pt}{\def\jsc@magscale{1.440}\renewcommand{\@ptsize}{4}}
\DeclareOption{17pt}{\def\jsc@magscale{1.728}\renewcommand{\@ptsize}{7}}
\DeclareOption{20pt}{\def\jsc@magscale{2}\renewcommand{\@ptsize}{10}}
\DeclareOption{21pt}{\def\jsc@magscale{2.074}\renewcommand{\@ptsize}{11}}
\DeclareOption{25pt}{\def\jsc@magscale{2.488}\renewcommand{\@ptsize}{15}}
\DeclareOption{30pt}{\def\jsc@magscale{2.986}\renewcommand{\@ptsize}{20}}
\DeclareOption{36pt}{\def\jsc@magscale{3.583}\renewcommand{\@ptsize}{26}}
\DeclareOption{43pt}{\def\jsc@magscale{4.300}\renewcommand{\@ptsize}{33}}
\DeclareOption{12Q}{\def\jsc@magscale{0.923}\renewcommand{\@ptsize}{1200}}
\DeclareOption{14Q}{\def\jsc@magscale{1.077}\renewcommand{\@ptsize}{1400}}
\DeclareOption{10ptj}{\def\jsc@magscale{1.085}\renewcommand{\@ptsize}{1001}}
\DeclareOption{10.5ptj}{\def\jsc@magscale{1.139}\renewcommand{\@ptsize}{1051}}
\DeclareOption{11ptj}{\def\jsc@magscale{1.194}\renewcommand{\@ptsize}{1101}}
\DeclareOption{12ptj}{\def\jsc@magscale{1.302}\renewcommand{\@ptsize}{1201}}
\DeclareOption{usemag}{\jsc@magtrue\jsc@mag@xrealfalse}
\DeclareOption{nomag}{\jsc@magfalse\jsc@mag@xrealfalse}
\DeclareOption{nomag*}{\jsc@magfalse\jsc@mag@xrealtrue}
% \end{macrocode}
%
%
% \paragraph{トンボオプション}
%
% トンボ(crop marks)を出力します。
% 実際の処理は\pLaTeXe 本体で行います(\texttt{plcore.dtx} 参照)。
% オプション \texttt{tombow} で日付付きのトンボ,
% オプション \texttt{tombo} で日付なしのトンボを出力します。
% これらはアスキー版のままです。
% カウンタ |\hour|,|\minute| はp\LaTeXe 本体で宣言されています。
%
% \begin{macrocode}
\hour\time \divide\hour by 60\relax
\@tempcnta\hour \multiply\@tempcnta 60\relax
\minute\time \advance\minute-\@tempcnta
\DeclareOption{tombow}{%
\tombowtrue \tombowdatetrue
\setlength{\@tombowwidth}{.1\p@}%
\@bannertoken{%
\jobname\space(\number\year-\two@digits\month-\two@digits\day
\space\two@digits\hour:\two@digits\minute)}%
\maketombowbox}
\DeclareOption{tombo}{%
\tombowtrue \tombowdatefalse
\setlength{\@tombowwidth}{.1\p@}%
\maketombowbox}
% \end{macrocode}
%
% \paragraph{面付け}
%
% オプション \texttt{mentuke} で幅ゼロのトンボを出力します。
% 面付けに便利です。これもアスキー版のままです。
%
% \begin{macrocode}
\DeclareOption{mentuke}{%
\tombowtrue \tombowdatefalse
\setlength{\@tombowwidth}{\z@}%
\maketombowbox}
% \end{macrocode}
%
% \paragraph{両面,片面オプション}
%
% \texttt{twoside} で奇数ページ・偶数ページのレイアウトが変わります。
%
% [2003-04-29] \texttt{vartwoside} でどちらのページも傍注が右側になります。
%
% \begin{macrocode}
\DeclareOption{oneside}{\@twosidefalse \@mparswitchfalse}
\DeclareOption{twoside}{\@twosidetrue \@mparswitchtrue}
\DeclareOption{vartwoside}{\@twosidetrue \@mparswitchfalse}
% \end{macrocode}
%
% \paragraph{二段組}
%
% \texttt{twocolumn} で二段組になります。
%
% \begin{macrocode}
\DeclareOption{onecolumn}{\@twocolumnfalse}
\DeclareOption{twocolumn}{\@twocolumntrue}
% \end{macrocode}
%
% \paragraph{表題ページ}
%
% \texttt{titlepage} で表題・概要を独立したページに出力します。
%
% \begin{macrocode}
\DeclareOption{titlepage}{\@titlepagetrue}
\DeclareOption{notitlepage}{\@titlepagefalse}
% \end{macrocode}
%
% \paragraph{右左起こし}
%
% 書籍では章は通常は奇数ページ起こしになりますが,横組ではこれを
% \texttt{openright} と表すことにしてあります。
% \texttt{openany} で偶数ページからでも始まるようになります。
%
% [2017-02-24] \texttt{openright} は横組では奇数ページ起こし,縦組では
% 偶数ページ起こしを表します。ややこしいですが,これは\LaTeX の標準クラスが
% 西欧の横組事情しか考慮せずに,奇数ページ起こしと右起こしを一緒にしてしまっ
% たせいです。縦組での奇数ページ起こしと横組での偶数ページ起こしも表現したい
% ので,jsclassesでは新たに \texttt{openleft} も追加しました。
%
% \begin{macrocode}
%<book|report>\DeclareOption{openright}{\@openrighttrue\@openleftfalse}
%<book|report>\DeclareOption{openleft}{\@openlefttrue\@openrightfalse}
%<book|report>\DeclareOption{openany}{\@openrightfalse\@openleftfalse}
% \end{macrocode}
%
% \paragraph{eqnarray環境と数式の位置}
%
% 森本さんのご教示にしたがって前に移動しました。
%
% \begin{environment}{eqnarray}
%
% \LaTeX の |eqnarray| 環境では |&| でできるアキが大きすぎる
% ようですので,少し小さくします。
% また,中央の要素も |\displaystyle| にします。
%
% [2022-09-13] \LaTeXe~2021-11-15 (ltmath.dtx 2021/10/14 v1.2j)で
% |\@currentcounter|が追加されましたので,追随します。
%
% \begin{macrocode}
\def\eqnarray{%
\stepcounter{equation}%
\def\@currentlabel{\p@equation\theequation}%
\def\@currentcounter{equation}%
\global\@eqnswtrue
\m@th
\global\@eqcnt\z@
\tabskip\@centering
\let\\\@eqncr
$$\everycr{}\halign to\displaywidth\bgroup
\hskip\@centering$\displaystyle\tabskip\z@skip{##}$\@eqnsel
&\global\@eqcnt\@ne \hfil$\displaystyle{{}##{}}$\hfil
&\global\@eqcnt\tw@ $\displaystyle{##}$\hfil\tabskip\@centering
&\global\@eqcnt\thr@@ \hb@xt@\z@\bgroup\hss##\egroup
\tabskip\z@skip
\cr}
% \end{macrocode}
% \end{environment}
%
% \texttt{leqno} で数式番号が左側になります。
% \texttt{fleqn} で数式が本文左端から一定距離のところに出力されます。
% 森本さんにしたがって訂正しました。
%
% [2022-09-13] \LaTeXe~2021-11-15 (ltmath.dtx 2021/10/14 v1.2j)で
% |\@currentcounter|が追加されましたので,追随します。
%
% \begin{macrocode}
\DeclareOption{leqno}{\input{leqno.clo}}
\DeclareOption{fleqn}{\input{fleqn.clo}%
% fleqn用のeqnarray環境の再定義
\def\eqnarray{%
\stepcounter{equation}%
\def\@currentlabel{\p@equation\theequation}%
\def\@currentcounter{equation}%
\global\@eqnswtrue\m@th
\global\@eqcnt\z@
\tabskip\mathindent
\let\\=\@eqncr
\setlength\abovedisplayskip{\topsep}%
\ifvmode
\addtolength\abovedisplayskip{\partopsep}%
\fi
\addtolength\abovedisplayskip{\parskip}%
\setlength\belowdisplayskip{\abovedisplayskip}%
\setlength\belowdisplayshortskip{\abovedisplayskip}%
\setlength\abovedisplayshortskip{\abovedisplayskip}%
$$\everycr{}\halign to\linewidth% $$
\bgroup
\hskip\@centering$\displaystyle\tabskip\z@skip{##}$\@eqnsel
&\global\@eqcnt\@ne \hfil$\displaystyle{{}##{}}$\hfil
&\global\@eqcnt\tw@
$\displaystyle{##}$\hfil \tabskip\@centering
&\global\@eqcnt\thr@@ \hb@xt@\z@\bgroup\hss##\egroup
\tabskip\z@skip\cr
}}
% \end{macrocode}
%
% \paragraph{文献リスト}
%
% 文献リストをopen形式(著者名や書名の後に改行が入る)で出力します。
% これは使われることはないのでコメントアウトしてあります。
%
% \begin{macrocode}
% \DeclareOption{openbib}{%
% \AtEndOfPackage{%
% \renewcommand\@openbib@code{%
% \advance\leftmargin\bibindent
% \itemindent -\bibindent
% \listparindent \itemindent
% \parsep \z@}%
% \renewcommand\newblock{\par}}}
% \end{macrocode}
%
% \paragraph{数式フォントとして和文フォントを登録しないオプション}
%
% 数式中では16通りのフォントしか使えません。
% AMSFontsや \texttt{mathptmx} パッケージを使って数式フォントを
% たくさん使うと ``Too many math alphabets \ldots'' というエラーが
% 起こってしまいます。\texttt{disablejfam} オプションを付ければ,
% 明朝・ゴシックを数式用フォントとして登録するのをやめますので,
% 数式用フォントが二つ節約できます。
% いずれにしても |\textmc| や |\mbox| や \texttt{amsmath}
% パッケージの |\text| を使えば数式中で和文フォントが使えますので,
% この新ドキュメントクラスでは標準で和文フォントを数式用に登録
% しないことにしていたのですが,従来のドキュメントクラスの仕様に
% 合わせることにしました。
%
% \begin{macrocode}
\DeclareOption{disablejfam}{\@enablejfamfalse}
% \end{macrocode}
%
% \paragraph{ドラフト}
%
% \texttt{draft} でoverfull boxの起きた行末に5ptの罫線を引きます。
%
% [2016-07-13] |\ifdraft| を定義するのをやめました。
%
% \begin{macrocode}
\DeclareOption{draft}{\setlength\overfullrule{5pt}}
\DeclareOption{final}{\setlength\overfullrule{0pt}}
% \end{macrocode}
%
% \paragraph{和文フォントメトリックの選択}
%
% このクラスファイルでは,和文TFMとして東京書籍印刷の小林肇さんの
% 作られたJISフォントメトリック(\texttt{jis},\texttt{jisg})
% を標準で使うことにしますが,
% 従来の \texttt{min10},\texttt{goth10} などを使いたいときは
% \texttt{mingoth} というオプションを指定します。
% また,\texttt{winjis} オプションで \texttt{winjis} メトリック
% (OTFパッケージと同じpsitauさん作;ソースに書かれたWindowsの
% 機種依存文字がdvips, dvipdfmxなどで出力出来るようになる)が使えます。
%
% [2018-02-04] \texttt{winjis} オプションはコッソリ削除しました。
% 代替として,同等なものをパッケージ化(winjis.sty)して,
% GitHubにはコッソリ置いておきます。
%
% \begin{macrocode}
\newif\ifmingoth
\mingothfalse
\newif\ifjisfont
\jisfontfalse
\newif\if@jsc@uplatex
\@jsc@uplatexfalse
\newif\if@jsc@autodetect
\@jsc@autodetectfalse
\DeclareOption{winjis}{%
\ClassWarningNoLine{\jsc@clsname}{%
The option `winjis' has been removed;\MessageBreak
Use `\string\usepackage{winjis}' instead}}
\DeclareOption{mingoth}{\mingothtrue}
\DeclareOption{jis}{\jisfonttrue}
\DeclareOption{uplatex}{\@jsc@uplatextrue}
\DeclareOption{autodetect-engine}{\@jsc@autodetecttrue}
\def\jsc@JYn{\if@jsc@uplatex JY2\else JY1\fi}
\def\jsc@JTn{\if@jsc@uplatex JT2\else JT1\fi}
\def\jsc@pfx@{\if@jsc@uplatex u\else \fi}
% \end{macrocode}
%
% \paragraph{papersizeスペシャルの利用}
%
% dvipsやdvioutで用紙設定を自動化するには
% オプション \texttt{papersize} を与えます。
%
% \begin{macrocode}
\newif\ifpapersize
\papersizefalse
\DeclareOption{papersize}{\papersizetrue}
% \end{macrocode}
%
% \paragraph{英語化}
%
% オプション \texttt{english} を新設しました。
%
% \begin{macrocode}
\newif\if@english
\@englishfalse
\DeclareOption{english}{\@englishtrue}
% \end{macrocode}
%
% \paragraph{jsbookをjsreportもどきに}
%
% オプション \texttt{report} を新設しました。
%
% [2017-02-13] 従来は「jsreport相当」をjsbookの \texttt{report} オプションで提供して
% いましたが,新しくjsreportクラスも作りました。どちらでもお好きな方を使ってください。
%
% \begin{macrocode}
%<*book>
\newif\if@report
\@reportfalse
\DeclareOption{report}{\@reporttrue\@openrightfalse\@twosidefalse\@mparswitchfalse}
%</book>
% \end{macrocode}
%
% \paragraph{\texttt{jslogo}パッケージの読み込み}
%
% \LaTeX 関連のロゴを再定義する\texttt{jslogo}パッケージを
% 読み込まないオプション\texttt{nojslogo}を新設しました。
% \texttt{jslogo}オプションの指定で従来どおりの動作となります。
% デフォルトは\texttt{jslogo}で,すなわちパッケージを読み込みます。
% \begin{macrocode}
\newif\if@jslogo \@jslogotrue
\DeclareOption{jslogo}{\@jslogotrue}
\DeclareOption{nojslogo}{\@jslogofalse}
% \end{macrocode}
%
% \paragraph{オプションの実行}
%
% デフォルトのオプションを実行します。
% |multicols| や |url| を |\RequirePackage| するのはやめました。
%
% \begin{macrocode}
%<article>\ExecuteOptions{a4paper,oneside,onecolumn,notitlepage,final}
%<book>\ExecuteOptions{a4paper,twoside,onecolumn,titlepage,openright,final}
%<report>\ExecuteOptions{a4paper,oneside,onecolumn,titlepage,openany,final}
%<jspf>\ExecuteOptions{a4paper,twoside,twocolumn,notitlepage,fleqn,final}
%<kiyou>\ExecuteOptions{a4paper,twoside,twocolumn,notitlepage,final}
\ProcessOptions
% \end{macrocode}
%
% 後処理
%
% \begin{macrocode}
\if@slide
\def\maybeblue{\@ifundefined{ver@color.sty}{}{\color{blue}}}
\fi
\if@landscape
\setlength\@tempdima {\paperheight}
\setlength\paperheight{\paperwidth}
\setlength\paperwidth {\@tempdima}
\fi
% \end{macrocode}
%
% \paragraph{使用エンジンの検査・自動判定}
%
% ユーザが |uplatex| オプションの有無により指定したエンジンが,実際に
% 使われているものと一致しているかを検査し,一致しない場合はエラー
% メッセージを表示します。
%
% [2016-11-09] p\LaTeX / up\LaTeX を自動判別するオプション |autodetect-engine| を新設しました。
% up\LaTeX の場合は,グローバルオプションに |uplatex| を追加することで,
% 自動判定に応じて |otf| パッケージにも |uplatex| オプションが渡るようにします。
%
% \begin{macrocode}
\ifnum \ifx\ucs\@undefined\z@\else\ucs"3000 \fi ="3000
\if@jsc@autodetect
\ClassInfo\jsc@clsname{Autodetected engine: upLaTeX}
\@jsc@uplatextrue
\g@addto@macro\@classoptionslist{,uplatex}
\fi
\if@jsc@uplatex\else
\ClassError\jsc@clsname
{You are running upLaTeX.\MessageBreak
Please use pLaTeX instead, or add 'uplatex' to\MessageBreak
the class option list}
{\@ehc}
\@jsc@uplatextrue
\fi
% \end{macrocode}
%
% [2016-11-11] p\LaTeX の場合は,オプション |uplatex| が指定されていれば必ずエラーを出します。
% |autodetect-engine| が有効になっていてもエラーを出しますが,これは |otf| パッケージに
% |uplatex| オプションが渡ってしまうのを防ぐためです。
%
% \begin{macrocode}
\else
\if@jsc@uplatex
\ClassError\jsc@clsname
{You are running pLaTeX.\MessageBreak
Please use upLaTeX instead, or remove 'uplatex' from\MessageBreak
the class option list}
{\@ehc}
\@jsc@uplatexfalse
\fi
\if@jsc@autodetect
\ClassInfo\jsc@clsname{Autodetected engine: pLaTeX}
\@jsc@uplatexfalse
\fi
\fi
% \end{macrocode}
%
% \paragraph{papersizeスペシャルの出力}
%
% |dvi| ファイルの先頭にdvipsのpapersize specialを書き込むことで,
% 出力用紙サイズを設定します。これはdvipdfmxや最近のdvioutにも有効です。
% どうやらpapersize specialにはtrue付の単位は許されず,かつ単位は
% 常にtrueなものと扱われるようです。
% そこで,後で出てくる(☆)の部分,「|\mag|にあわせてスケール」よりも
% 手前で実行しておくことになります。
%
% トンボの付いたときの用紙サイズは無意味ですが,
% いわゆる「ノビ」サイズという縦横1インチずつ長い用紙に出力することを考えて,
% 1インチずつ加えました。
% ところが\pLaTeXe はトンボ出力幅を両側に1インチとっていますので,
% dvips使用時に
% \begin{quote}
% |-O -0.5in,-0.5in|
% \end{quote}
% というオプションを与えて両側0.5インチのトンボにするといいでしょう。
%
% [2003-05-17] トンボをプレビューに使うことを考えて1インチを2インチにしました。
%
% [2016-07-11] memoirクラスのマニュアルによると,トンボを含めた用紙の寸法は
% |\stockwidth|,|\stockheight|と呼ぶようですので,これを使うことにしました。
%
% [2017-01-11] トンボオプションが指定されているとき「だけ」|\stockwidth|,
% |\stockheight|を定義するようにしました。
%
% [2020-10-04] \LaTeXe~2020-10-01でカーネルの |\shipout| コードが拡張され
% |\AtBeginDvi| の実行タイミングが変化したので,この時点で
% 発行する |\special| の中身を展開しておくようにしました。
% こうしないと,用紙サイズ設定を間違ってしまいます(Issue \#72)。
%
% [2022-09-12] 次期\LaTeXe カーネルに|\stockwidth|,|\stockheight|が
% 追加されるようですので,
% クラスファイル側では未定義のときのみこれらの長さ変数を定義します。
% h20y6mさん,ありがとうございます。
%
% \begin{macrocode}
\iftombow
\ifx\stockwidth\@undefined\newdimen\stockwidth\fi
\ifx\stockheight\@undefined\newdimen\stockheight\fi
\setlength{\stockwidth}{\paperwidth}
\setlength{\stockheight}{\paperheight}
\advance \stockwidth 2in
\advance \stockheight 2in
\fi
\ifpapersize
\iftombow
\edef\jsc@papersize@special{papersize=\the\stockwidth,\the\stockheight}
\else
\edef\jsc@papersize@special{papersize=\the\paperwidth,\the\paperheight}
\fi
\AtBeginDvi{\special{\jsc@papersize@special}}
\fi
% \end{macrocode}
%
% \paragraph{基準となる行送り}
%
% \begin{macro}{\n@baseline}
%
% 基準となる行送りをポイント単位で表したものです。
%
% \begin{macrocode}
%<article|book|report>\if@slide\def\n@baseline{13}\else\def\n@baseline{16}\fi
%<jspf>\def\n@baseline{14.554375}
%<kiyou>\def\n@baseline{14.897}
% \end{macrocode}
% \end{macro}
%
% \paragraph{拡大率の設定}
%
% サイズの変更は\TeX のプリミティブ |\mag| を使って行います。
% 9ポイントについては行送りも若干縮めました。
% サイズについては全面的に見直しました。
%
% [2008-12-26] 1000 / |\mag| に相当する |\inv@mag| を定義しました。
% |truein| を使っていたところを |\inv@mag in| に直しましたので,
% |geometry| パッケージと共存できると思います。
% なお,新ドキュメントクラス側で |10pt| 以外にする場合の注意:
% \begin{itemize}
% \item |geometry| 側でオプション |truedimen| を指定してください。
% \item |geometry| 側でオプション |mag| は使えません。
% \end{itemize}
%
% [2016-07-08] |\jsc@mpt| および |\jsc@mmm| に,それぞれ1ptおよび1mmを拡大させた値を格納します。
% 以降のレイアウト指定ではこちらを使います。
%
% \begin{macrocode}
\newdimen\jsc@mpt
\newdimen\jsc@mmm
\def\inv@mag{1}
\ifjsc@mag
\jsc@mpt=1\p@
\jsc@mmm=1mm
\ifnum\@ptsize=-2
\mag 833
\def\inv@mag{1.20048}
\def\n@baseline{15}%
\fi
\ifnum\@ptsize=-1
\mag 913 % formerly 900
\def\inv@mag{1.09529}
\def\n@baseline{15}%
\fi
\ifnum\@ptsize=1
\mag 1095 % formerly 1100
\def\inv@mag{0.913242}
\fi
\ifnum\@ptsize=2
\mag 1200
\def\inv@mag{0.833333}
\fi
\ifnum\@ptsize=4
\mag 1440
\def\inv@mag{0.694444}
\fi
\ifnum\@ptsize=7
\mag 1728
\def\inv@mag{0.578704}
\fi
\ifnum\@ptsize=10
\mag 2000
\def\inv@mag{0.5}
\fi
\ifnum\@ptsize=11
\mag 2074
\def\inv@mag{0.48216}
\fi
\ifnum\@ptsize=15
\mag 2488
\def\inv@mag{0.401929}
\fi
\ifnum\@ptsize=20
\mag 2986
\def\inv@mag{0.334896}
\fi
\ifnum\@ptsize=26
\mag 3583
\def\inv@mag{0.279096}
\fi
\ifnum\@ptsize=33
\mag 4300
\def\inv@mag{0.232558}
\fi
\ifnum\@ptsize=1200
\mag 923
\def\inv@mag{1.0834236}
\fi
\ifnum\@ptsize=1400
\mag 1077
\def\inv@mag{0.928505}
\fi
\ifnum\@ptsize=1001
\mag 1085
\def\inv@mag{0.921659}
\fi
\ifnum\@ptsize=1051
\mag 1139
\def\inv@mag{0.877963}
\fi
\ifnum\@ptsize=1101
\mag 1194
\def\inv@mag{0.837521}
\fi
\ifnum\@ptsize=1201
\mag 1302
\def\inv@mag{0.768049}
\fi
\else
\jsc@mpt=\jsc@magscale\p@
\jsc@mmm=\jsc@magscale mm
\def\inv@mag{1}
\ifnum\@ptsize=-2
\def\n@baseline{15}%
\fi
\ifnum\@ptsize=-1
\def\n@baseline{15}%
\fi
\fi
%<*kiyou>
\def\jsc@magscale{0.9769230}
\ifjsc@mag
\mag 977
\def\inv@mag{1.02354}
\jsc@mpt=1\p@
\jsc@mmm=1mm
\else
\jsc@mpt=\jsc@magscale\p@
\jsc@mmm=\jsc@magscale mm
\def\inv@mag{1}
\fi
%</kiyou>
\ifjsc@mag@xreal
\RequirePackage{type1cm}
\mathchardef\jsc@csta=259
\def\jsc@invscale#1#2{%
\begingroup \@tempdima=#1\relax \@tempdimb#2\p@\relax
\@tempcnta\@tempdima \multiply\@tempcnta\@cclvi
\divide\@tempcnta\@tempdimb \multiply\@tempcnta\@cclvi
\@tempcntb\p@ \divide\@tempcntb\@tempdimb
\advance\@tempcnta-\@tempcntb \advance\@tempcnta-\tw@
\@tempdimb\@tempcnta\@ne
\advance\@tempcnta\@tempcntb \advance\@tempcnta\@tempcntb
\advance\@tempcnta\jsc@csta \@tempdimc\@tempcnta\@ne
\@whiledim\@tempdimb<\@tempdimc\do{%
\@tempcntb\@tempdimb \advance\@tempcntb\@tempdimc
\advance\@tempcntb\@ne \divide\@tempcntb\tw@
\ifdim #2\@tempcntb>\@tempdima
\advance\@tempcntb\m@ne \@tempdimc=\@tempcntb\@ne
\else \@tempdimb=\@tempcntb\@ne \fi}%
\xdef\jsc@gtmpa{\the\@tempdimb}%
\endgroup #1=\jsc@gtmpa\relax}
\expandafter\let\csname OT1/cmr/m/n/10\endcsname\relax
\expandafter\let\csname OMX/cmex/m/n/10\endcsname\relax
\let\jsc@get@external@font\get@external@font
\def\get@external@font{%
\jsc@preadjust@extract@font
\jsc@get@external@font}
\def\jsc@fstrunc#1{%
\edef\jsc@tmpa{\strip@pt#1}%
\expandafter\jsc@fstrunc@a\jsc@tmpa.****\@nil}
\def\jsc@fstrunc@a#1.#2#3#4#5#6\@nil{%
\if#5*\else
\edef\jsc@tmpa{#1%
\ifnum#2#3>\z@ .#2\ifnum#3>\z@ #3\fi\fi}%
\fi}
\def\jsc@preadjust@extract@font{%
\let\jsc@req@size\f@size
\dimen@\f@size\p@ \jsc@invscale\dimen@\jsc@magscale
\advance\dimen@.005pt\relax \jsc@fstrunc\dimen@
\let\jsc@ref@size\jsc@tmpa
\let\f@size\jsc@ref@size}
\def\execute@size@function#1{%
\let\jsc@cref@size\f@size
\let\f@size\jsc@req@size
\csname s@fct@#1\endcsname}
\let\jsc@DeclareErrorFont\DeclareErrorFont
\def\DeclareErrorFont#1#2#3#4#5{%
\@tempdimc#5\p@ \@tempdimc\jsc@magscale\@tempdimc
\edef\jsc@tmpa{{#1}{#2}{#3}{#4}{\strip@pt\@tempdimc}}
\expandafter\jsc@DeclareErrorFont\jsc@tmpa}
\def\gen@sfcnt{%
\edef\mandatory@arg{\mandatory@arg\jsc@cref@size}%
\empty@sfcnt}
\def\genb@sfcnt{%
\edef\mandatory@arg{%
\mandatory@arg\expandafter\genb@x\jsc@cref@size..\@@}%
\empty@sfcnt}
\DeclareErrorFont{OT1}{cmr}{m}{n}{10}
\fi
% \end{macrocode}
%
% [2016-11-16] latex.ltx (ltspace.dtx)で定義されている |\smallskip| の,
% 単位 |pt| を |\jsc@mpt| に置き換えた |\jsc@smallskip| を定義します。
% これは |\maketitle| で用いられます。
% |\jsc@medskip| と |\jsc@bigskip| は必要ないのでコメントアウトしています。
%
% \begin{macro}{\jsc@smallskip}
% \begin{macro}{\jsc@medskip}
% \begin{macro}{\jsc@bigskip}
% \begin{macrocode}
\def\jsc@smallskip{\vspace\jsc@smallskipamount}
%\def\jsc@medskip{\vspace\jsc@medskipamount}
%\def\jsc@bigskip{\vspace\jsc@bigskipamount}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\jsc@smallskipamount}
% \begin{macro}{\jsc@medskipamount}
% \begin{macro}{\jsc@bigskipamount}
% \begin{macrocode}
\newskip\jsc@smallskipamount
\jsc@smallskipamount=3\jsc@mpt plus 1\jsc@mpt minus 1\jsc@mpt
%\newskip\jsc@medskipamount
%\jsc@medskipamount =6\jsc@mpt plus 2\jsc@mpt minus 2\jsc@mpt
%\newskip\jsc@bigskipamount
%\jsc@bigskipamoun =12\jsc@mpt plus 4\jsc@mpt minus 4\jsc@mpt
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% |\paperwidth|,|\paperheight|を|\mag|にあわせてスケールしておきます(☆)。
%
% [2016-07-11] 新しく追加した|\stockwidth|,|\stockheight|も|\mag|にあわせて
% スケールします。
%
% [2017-01-11] トンボオプションが指定されているとき「だけ」|\stockwidth|,
% |\stockheight|が定義されています。
%
% \begin{macrocode}
\setlength\paperwidth{\inv@mag\paperwidth}%
\setlength\paperheight{\inv@mag\paperheight}%
\iftombow
\setlength\stockwidth{\inv@mag\stockwidth}%
\setlength\stockheight{\inv@mag\stockheight}%
\fi
% \end{macrocode}
%
% \paragraph{pagesizeスペシャルの出力}
%
% [2003-05-17] dvipdfm(x)のpagesizeスペシャルを出力します。
%
% [2004-08-08] 今のdvipdfmxはdvips用スペシャルを理解するようなので外しました。
%
% \begin{macrocode}
% \ifpapersize
% \setlength{\@tempdima}{\paperwidth}
% \setlength{\@tempdimb}{\paperheight}
% \iftombow
% \advance \@tempdima 2truein
% \advance \@tempdimb 2truein
% \fi
% \AtBeginDvi{\special{pdf: pagesize width \the\@tempdima\space height \the\@tempdimb}}
% \fi
% \end{macrocode}
%
% \section{和文フォントの変更}
%
% JISの1ポイントは0.3514mm(約1/72.28インチ),
% PostScriptの1ポイントは1/72インチですが,
% \TeX では1/72.27インチを1pt(ポイント),
% 1/72インチを1bp(ビッグポイント)と表します。
% QuarkXPressなどのDTPソフトは標準で1/72インチを1ポイント
% としますが,以下ではすべて1/72.27インチを1ptとしています。
% 1インチは定義により25.4mmです。
%
% さらにややこしいことに,\pTeX (アスキーが日本語化した\TeX )
% の公称10ポイントの和文フォント(\texttt{min10} など)は,
% 実寸(標準の字送り量)が9.62216ptです。
% これは3.3818mm,写研の写植機の単位では13.527級,
% PostScriptの単位では9.5862ポイントになります。
% \texttt{jis} フォントなどもこの値を踏襲しています。
%
% この公称10ポイントのフォントを,ここでは13級に縮小して
% 使うことにします。そのためには,$13/13.527 = 0.961$ 倍
% すればいいことになります(\texttt{min10} や \texttt{jis} の場合)。
% 9.62216ポイントの和文フォントをさらに0.961倍したことにより,
% 約9.25ポイント,
% DTPで使う単位(1/72インチ)では9.21ポイントということになり,
% 公称10ポイントといっても実は9ポイント強になります。
%
% [2018-02-04] 上記のとおりの「クラスファイルが意図する
% 和文スケール値($1\,\mathrm{zw} \div \textmc{要求サイズ}$)」を
% 表す実数値マクロ |\Cjascale| を定義します。このマクロが定義されて
% いる場合,OTFパッケージ(2018/02/01以降のバージョン)はこれに
% 従います。jsarticle, jsbook, jsreportでは,
% $9.62216\,\mathrm{pt} * 0.961 / 10\,\mathrm{pt} = 0.924690$ です。
%
% \begin{macrocode}
%</class>
%<*minijs>
%% min/goth -> jis/jisg (for pLaTeX only)
\ifnum\jis"2121="3000 \else
\@for\@tempa:=5,6,7,8,9,10,10.95,12,14.4,17.28,20.74,24.88\do{%
\expandafter\let\csname JY1/mc/m/n/\@tempa\endcsname\relax
\expandafter\let\csname JY1/gt/m/n/\@tempa\endcsname\relax
\expandafter\let\csname JT1/mc/m/n/\@tempa\endcsname\relax
\expandafter\let\csname JT1/gt/m/n/\@tempa\endcsname\relax
}
\def\Cjascale{0.924690}
\DeclareFontShape{JY1}{mc}{m}{n}{<-> s * [0.961] jis}{}
\DeclareFontShape{JY1}{gt}{m}{n}{<-> s * [0.961] jisg}{}
\DeclareFontShape{JT1}{mc}{m}{n}{<-> s * [0.961] tmin10}{}
\DeclareFontShape{JT1}{gt}{m}{n}{<-> s * [0.961] tgoth10}{}
\fi
%</minijs>
%<*class>
%<*!jspf>
\def\Cjascale{0.924690}
\ifmingoth
\DeclareFontShape{\jsc@JYn}{mc}{m}{n}{<-> s * [0.961] \jsc@pfx@ min10}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{n}{<-> s * [0.961] \jsc@pfx@ goth10}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{n}{<-> s * [0.961] \jsc@pfx@ tmin10}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{n}{<-> s * [0.961] \jsc@pfx@ tgoth10}{}
\else
\ifjisfont
\DeclareFontShape{\jsc@JYn}{mc}{m}{n}{<-> s * [0.961] \jsc@pfx@ jis}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{n}{<-> s * [0.961] \jsc@pfx@ jisg}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{n}{<-> s * [0.961] \jsc@pfx@ tmin10}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{n}{<-> s * [0.961] \jsc@pfx@ tgoth10}{}
\else
\if@jsc@uplatex
\DeclareFontShape{JY2}{mc}{m}{n}{<-> s * [0.924690] upjisr-h}{}
\DeclareFontShape{JY2}{gt}{m}{n}{<-> s * [0.924690] upjisg-h}{}
\DeclareFontShape{JT2}{mc}{m}{n}{<-> s * [0.924690] upjisr-v}{}
\DeclareFontShape{JT2}{gt}{m}{n}{<-> s * [0.924690] upjisg-v}{}
\else
\DeclareFontShape{\jsc@JYn}{mc}{m}{n}{<-> s * [0.961] \jsc@pfx@ jis}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{n}{<-> s * [0.961] \jsc@pfx@ jisg}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{n}{<-> s * [0.961] \jsc@pfx@ tmin10}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{n}{<-> s * [0.961] \jsc@pfx@ tgoth10}{}
\fi
\fi
\fi
%</!jspf>
% \end{macrocode}
%
% 某学会誌では,
% 和文フォントをPostScriptの9ポイントにするために,
% $9/(9.62216*72/72.27) = 0.93885$ 倍します。
%
% [2018-02-04] 和文スケール値 |\Cjascale| は
% $9.62216\,\mathrm{pt} * 0.93885 / 10\,\mathrm{pt} = 0.903375$ です。
%
% \begin{macrocode}
%<*jspf>
\def\Cjascale{0.903375}
\ifmingoth
\DeclareFontShape{\jsc@JYn}{mc}{m}{n}{<-> s * [0.93885] \jsc@pfx@ min10}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{n}{<-> s * [0.93885] \jsc@pfx@ goth10}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{n}{<-> s * [0.93885] \jsc@pfx@ tmin10}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{n}{<-> s * [0.93885] \jsc@pfx@ tgoth10}{}
\else
\ifjisfont
\DeclareFontShape{\jsc@JYn}{mc}{m}{n}{<-> s * [0.93885] \jsc@pfx@ jis}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{n}{<-> s * [0.93885] \jsc@pfx@ jisg}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{n}{<-> s * [0.93885] \jsc@pfx@ tmin10}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{n}{<-> s * [0.93885] \jsc@pfx@ tgoth10}{}
\else
\if@jsc@uplatex
\DeclareFontShape{JY2}{mc}{m}{n}{<-> s * [0.903375] upjisr-h}{}
\DeclareFontShape{JY2}{gt}{m}{n}{<-> s * [0.903375] upjisg-h}{}
\DeclareFontShape{JT2}{mc}{m}{n}{<-> s * [0.903375] upjisr-v}{}
\DeclareFontShape{JT2}{gt}{m}{n}{<-> s * [0.903375] upjisg-v}{}
\else
\DeclareFontShape{\jsc@JYn}{mc}{m}{n}{<-> s * [0.93885] \jsc@pfx@ jis}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{n}{<-> s * [0.93885] \jsc@pfx@ jisg}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{n}{<-> s * [0.93885] \jsc@pfx@ tmin10}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{n}{<-> s * [0.93885] \jsc@pfx@ tgoth10}{}
\fi
\fi
\fi
%</jspf>
% \end{macrocode}
%
% 和文でイタリック体,斜体,サンセリフ体,
% タイプライタ体の代わりにゴシック体を使うことにします。
%
% [2003-03-16] イタリック体,斜体について,和文でゴシックを当てていましたが,
% 数学の定理環境などで多量のイタリック体を使うことがあり,ゴシックに
% すると黒々となってしまうという弊害がありました。
% |amsthm| を使わない場合は定理の本文が明朝になるように |\newtheorem|
% 環境を手直ししてしのいでいましたが,
% \TeX が数学で多用されることを考えると,イタリック体に明朝体を
% 当てたほうがいいように思えてきましたので,
% イタリック体・斜体に対応する和文を明朝体に変えることにしました。
%
% [2004-11-03] |\rmfamily| も和文対応にしました。
%
% \begin{macrocode}
% \DeclareFontShape{\jsc@JYn}{mc}{bx}{n}{<->ssub*gt/m/n}{} % in \jsc@JYnmc
% \DeclareFontShape{\jsc@JYn}{gt}{bx}{n}{<->ssub*gt/m/n}{} % in \jsc@JYngt
\DeclareFontShape{\jsc@JYn}{mc}{m}{it}{<->ssub*mc/m/n}{}
\DeclareFontShape{\jsc@JYn}{mc}{m}{sl}{<->ssub*mc/m/n}{}
\DeclareFontShape{\jsc@JYn}{mc}{m}{sc}{<->ssub*mc/m/n}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{it}{<->ssub*gt/m/n}{}
\DeclareFontShape{\jsc@JYn}{gt}{m}{sl}{<->ssub*gt/m/n}{}
\DeclareFontShape{\jsc@JYn}{mc}{bx}{it}{<->ssub*gt/m/n}{}
\DeclareFontShape{\jsc@JYn}{mc}{bx}{sl}{<->ssub*gt/m/n}{}
% \DeclareFontShape{\jsc@JTn}{mc}{bx}{n}{<->ssub*gt/m/n}{} % in \jsc@JTnmc
% \DeclareFontShape{\jsc@JTn}{gt}{bx}{n}{<->ssub*gt/m/n}{} % in \jsc@JTngt
\DeclareFontShape{\jsc@JTn}{mc}{m}{it}{<->ssub*mc/m/n}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{sl}{<->ssub*mc/m/n}{}
\DeclareFontShape{\jsc@JTn}{mc}{m}{sc}{<->ssub*mc/m/n}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{it}{<->ssub*gt/m/n}{}
\DeclareFontShape{\jsc@JTn}{gt}{m}{sl}{<->ssub*gt/m/n}{}
\DeclareFontShape{\jsc@JTn}{mc}{bx}{it}{<->ssub*gt/m/n}{}
\DeclareFontShape{\jsc@JTn}{mc}{bx}{sl}{<->ssub*gt/m/n}{}
% \end{macrocode}
%
% [2020-02-02] \LaTeXe~2020-02-02でNFSSが拡張され,
% それに伴いオリジナルの |\rmfamily| などの定義が変化しました。
% |\DeclareRobustCommand| で直接定義すると,これを上書きして
% NFSSの拡張部分を壊してしまいますので,
% 新たに提供されたフックにコードを挿入します。
% 従来のコードも\LaTeXe~2019-10-01以前のために残してありますが,
% \texttt{mweights}パッケージ対策も施しました(forum:2763)。
%
% [2020-10-04] \LaTeXe~2020-10-01では |\AddToHook| を利用します。
%
% ^^A Note that |\AddToHook| is defined as follows:
% ^^A \begin{itemize}
% ^^A \item Format date 2020-02-02 or older: undefined
% ^^A \item Format date 2020-10-01 or newer: available
% ^^A \item ... under \texttt{latexrelease} rollback: defined but no-op
% ^^A \end{itemize}
%
% \begin{macrocode}
%</class>
%<*class|minijs>
%% ad-hoc "relation font"
\@ifl@t@r\fmtversion{2020/10/01}
{\jsc@needsp@tchfalse}{\jsc@needsp@tchtrue}
\ifjsc@needsp@tch % --- for 2020-02-02 or older BEGIN
\ifx\@rmfamilyhook\@undefined % old
\DeclareRobustCommand\rmfamily
{\not@math@alphabet\rmfamily\mathrm
\romanfamily\rmdefault\kanjifamily\mcdefault\selectfont}
\DeclareRobustCommand\sffamily
{\not@math@alphabet\sffamily\mathsf
\romanfamily\sfdefault\kanjifamily\gtdefault\selectfont}
\DeclareRobustCommand\ttfamily
{\not@math@alphabet\ttfamily\mathtt
\romanfamily\ttdefault\kanjifamily\gtdefault\selectfont}
\AtBeginDocument{%
\ifx\mweights@init\@undefined\else % mweights.sty is loaded
% my definitions above should have been overwritten, recover it!
% \selectfont is executed twice but I don't care about speed...
\expandafter\g@addto@macro\csname rmfamily \endcsname
{\kanjifamily\mcdefault\selectfont}%
\expandafter\g@addto@macro\csname sffamily \endcsname
{\kanjifamily\gtdefault\selectfont}%
\expandafter\g@addto@macro\csname ttfamily \endcsname
{\kanjifamily\gtdefault\selectfont}%
\fi}
\else % 2020-02-02
\g@addto@macro\@rmfamilyhook
{\prepare@family@series@update@kanji{mc}\mcdefault}
\g@addto@macro\@sffamilyhook
{\prepare@family@series@update@kanji{gt}\gtdefault}
\g@addto@macro\@ttfamilyhook
{\prepare@family@series@update@kanji{gt}\gtdefault}
\fi
\else % --- for 2020-02-02 or older END & for 2020-10-01 BEGIN
\AddToHook{rmfamily}%
{\prepare@family@series@update@kanji{mc}\mcdefault}
\AddToHook{sffamily}%
{\prepare@family@series@update@kanji{gt}\gtdefault}
\AddToHook{ttfamily}%
{\prepare@family@series@update@kanji{gt}\gtdefault}
\fi % --- for 2020-10-01 END
%</class|minijs>
%<*class>
% \end{macrocode}
%
% \begin{macro}{\textmc}
% \begin{macro}{\textgt}
%
% 次のコマンドはイタリック補正なども含めて定義されていますが,
% 和文ではイタリック補正はあまり役に立たず,
% 欧文・和文間のグルーが入らないという副作用もありますので,
% 単純な定義に直します。
%
% [2016-08-26] 和欧文間の |\xkanjiskip| が入らない問題は,
% plfonts.dtx v1.3i (2000/07/13)
% の時点で修正されていました。逆に,\texttt{amsmath}パッケージを
% 読み込んだ場合に,数式内の添字で文字サイズが変化するようになる
% はずのところが,変わらなくなっていましたので,修正しました。
%
% [2017-09-03] Yue ZHANGさん作の\texttt{fixjfm}パッケージが
% |\documentclass| より前に |\RequirePackage{fixjfm}| として
% 読み込まれていた場合には,その定義を優先するため,
% このクラスファイルでは再定義しません。
%
% [2017-09-19] 2010年の\pTeX の修正で,イタリック補正と和欧文間の
% |\xkanjiskip| の衝突が起きなくなっていますから,もうここにある
% ような単純化は必要ありません。ただし,このクラスファイルが
% 古い\TeX 環境で利用される可能性も捨てきれないので,とりあえず
% 残しておきます。
%
% \begin{macrocode}
\ifx\DeclareFixJFMCJKTextFontCommand\@undefined
\DeclareRobustCommand\textmc[1]{%
\relax\ifmmode \expandafter\nfss@text \fi{\mcfamily #1}}
\DeclareRobustCommand\textgt[1]{%
\relax\ifmmode \expandafter\nfss@text \fi{\gtfamily #1}}
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% 新クラスでも \texttt{disablejfam} オプションを与えなければ数式内で
% 日本語が使えるようにしました。
%
% さらに2005/12/01版のLaTeXに対応したpLaTeXに対応しました
% (Thanks: ymtさん)。
%
% [2010-03-14] |http://oku.edu.mie-u.ac.jp/tex/mod/forum/discuss.php?d=411|
% での山本さんのご指摘に従って修正しました。
%
% \begin{macrocode}
\def\reDeclareMathAlphabet#1#2#3{%
\edef\@tempa{\expandafter\@gobble\string#2}%
\edef\@tempb{\expandafter\@gobble\string#3}%
\edef\@tempc{\string @\expandafter\@gobbletwo\string#2}%
\ifx\@tempc\@tempa%
\edef\@tempa{\expandafter\@gobbletwo\string#2}%
\edef\@tempb{\expandafter\@gobbletwo\string#3}%
\fi
\begingroup
\let\protect\noexpand
\def\@tempaa{\relax}%
\expandafter\ifx\csname RDMAorg@\@tempa\endcsname\relax
\edef\@tempaa{\expandafter\def\expandafter\noexpand%
\csname RDMAorg@\@tempa\endcsname{%
\expandafter\noexpand\csname\@tempa\endcsname}}%
\fi
\def\@tempbb{\relax}%
\expandafter\ifx\csname RDMAorg@\@tempb\endcsname\relax
\edef\@tempbb{\expandafter\def\expandafter\noexpand%
\csname RDMAorg@\@tempb\endcsname{%
\expandafter\noexpand\csname\@tempb\endcsname}}%
\fi
\edef\@tempc{\@tempaa\@tempbb}%
\expandafter\endgroup\@tempc%
\edef#1{\noexpand\protect\expandafter\noexpand\csname%
\expandafter\@gobble\string#1\space\space\endcsname}%
\expandafter\edef\csname\expandafter\@gobble\string#1\space\space\endcsname%
{\noexpand\DualLang@mathalph@bet%
{\expandafter\noexpand\csname RDMAorg@\@tempa\endcsname}%
{\expandafter\noexpand\csname RDMAorg@\@tempb\endcsname}%
}%
}
\@onlypreamble\reDeclareMathAlphabet
\def\DualLang@mathalph@bet#1#2{%
\relax\ifmmode
\ifx\math@bgroup\bgroup% 2e normal style (\mathrm{...})
\bgroup\let\DualLang@Mfontsw\DLMfontsw@standard
\else
\ifx\math@bgroup\relax% 2e two letter style (\rm->\mathrm)
\let\DualLang@Mfontsw\DLMfontsw@oldstyle
\else
\ifx\math@bgroup\@empty% 2.09 oldlfont style ({\mathrm ...})
\let\DualLang@Mfontsw\DLMfontsw@oldlfont
\else% panic! assume 2e normal style
\bgroup\let\DualLang@Mfontsw\DLMfontsw@standard
\fi
\fi
\fi
\else
\let\DualLang@Mfontsw\@firstoftwo
\fi
\DualLang@Mfontsw{#1}{#2}%
}
\def\DLMfontsw@standard#1#2#3{#1{#2{#3}}\egroup}
\def\DLMfontsw@oldstyle#1#2{#1\relax\@fontswitch\relax{#2}}
\def\DLMfontsw@oldlfont#1#2{#1\relax#2\relax}
\if@enablejfam
\DeclareSymbolFont{mincho}{\jsc@JYn}{mc}{m}{n}
\DeclareSymbolFontAlphabet{\mathmc}{mincho}
\SetSymbolFont{mincho}{bold}{\jsc@JYn}{gt}{m}{n}
\jfam\symmincho
\DeclareMathAlphabet{\mathgt}{\jsc@JYn}{gt}{m}{n}
\AtBeginDocument{%
\reDeclareMathAlphabet{\mathrm}{\@mathrm}{\@mathmc}
\reDeclareMathAlphabet{\mathbf}{\@mathbf}{\@mathgt}}
\fi
% \end{macrocode}
%
% \begin{macro}{\textsterling}
%
% これは |\pounds| 命令で実際に呼び出される文字です。
% 従来からのOT1エンコーディングでは |\$| のイタリック体が |\pounds|
% なので \texttt{cmti} が使われていましたが,
% 1994年春からは \texttt{cmu}(upright italic,直立イタリック体)
% に変わりました。
% しかし \texttt{cmu} はその性格からして実験的なものであり,
% |\pounds| 以外で使われるとは思えないので,
% ここでは \texttt{cmti} に戻してしまいます。
%
% [2003-08-20] Computer Modernフォントを使う機会も減り,T1エンコーディング
% が一般的になってきました。この定義はもうあまり意味がないので消します。
%
% \begin{macrocode}
% \DeclareTextCommand{\textsterling}{OT1}{{\itshape\char`\$}}
% \end{macrocode}
% \end{macro}
%
% 禁則パラメータも若干修正します。
%
% アスキーの \texttt{kinsoku.dtx} では次の三つが5000に設定されています。
% これを10000に再設定します。
%
% \begin{macrocode}
\prebreakpenalty\jis"2147=10000 % 5000 ’
\postbreakpenalty\jis"2148=10000 % 5000 “
\prebreakpenalty\jis"2149=10000 % 5000 ”
% \end{macrocode}
%
% 「\TeX!」「〒515」の記号と数字の間に四分アキが入らないようにします。
%
% \begin{macrocode}
\inhibitxspcode`!=1
\inhibitxspcode`〒=2
% \end{macrocode}
%
% 以前の版では,たとえば「ベース名.拡張子」のように和文文字で書いたとき,
% ピリオドの後に四分アキが入らないようにするために
% \begin{macrocode}
% \xspcode`.=0
% \end{macrocode}
% のようにしていました。ただ,「Foo Inc.は……」のように書いたときにも
% スペースが入らなくなるので,ちょっとまずい修正だったかもしれません。
% 元に戻しました。
%
% とりあえず「|ベース名.\mbox{}拡張子|」と書いてください。
%
% 「CやC++では……」と書くと,C++の直後に四分アキが入らないのでバランスが悪くなります。
% 四分アキが入るようにしました。\% の両側も同じです。
%
% \begin{macrocode}
\xspcode`+=3
\xspcode`\%=3
% \end{macrocode}
%
% これ以外にT1エンコーディングで80〜ffの文字もすべて欧文文字ですので,
% 両側の和文文字との間にスペースが入らなければなりません。
%
% \begin{macrocode}
\xspcode`^^80=3
\xspcode`^^81=3
\xspcode`^^82=3
\xspcode`^^83=3
\xspcode`^^84=3
\xspcode`^^85=3
\xspcode`^^86=3
\xspcode`^^87=3
\xspcode`^^88=3
\xspcode`^^89=3
\xspcode`^^8a=3
\xspcode`^^8b=3
\xspcode`^^8c=3
\xspcode`^^8d=3
\xspcode`^^8e=3
\xspcode`^^8f=3
\xspcode`^^90=3
\xspcode`^^91=3
\xspcode`^^92=3
\xspcode`^^93=3
\xspcode`^^94=3
\xspcode`^^95=3
\xspcode`^^96=3
\xspcode`^^97=3
\xspcode`^^98=3
\xspcode`^^99=3
\xspcode`^^9a=3
\xspcode`^^9b=3
\xspcode`^^9c=3
\xspcode`^^9d=3
\xspcode`^^9e=3
\xspcode`^^9f=3
\xspcode`^^a0=3
\xspcode`^^a1=3
\xspcode`^^a2=3
\xspcode`^^a3=3
\xspcode`^^a4=3
\xspcode`^^a5=3
\xspcode`^^a6=3
\xspcode`^^a7=3
\xspcode`^^a8=3
\xspcode`^^a9=3
\xspcode`^^aa=3
\xspcode`^^ab=3
\xspcode`^^ac=3
\xspcode`^^ad=3
\xspcode`^^ae=3
\xspcode`^^af=3
\xspcode`^^b0=3
\xspcode`^^b1=3
\xspcode`^^b2=3
\xspcode`^^b3=3
\xspcode`^^b4=3
\xspcode`^^b5=3
\xspcode`^^b6=3
\xspcode`^^b7=3
\xspcode`^^b8=3
\xspcode`^^b9=3
\xspcode`^^ba=3
\xspcode`^^bb=3
\xspcode`^^bc=3
\xspcode`^^bd=3
\xspcode`^^be=3
\xspcode`^^bf=3
\xspcode`^^c0=3
\xspcode`^^c1=3
\xspcode`^^c2=3
\xspcode`^^c3=3
\xspcode`^^c4=3
\xspcode`^^c5=3
\xspcode`^^c6=3
\xspcode`^^c7=3
\xspcode`^^c8=3
\xspcode`^^c9=3
\xspcode`^^ca=3
\xspcode`^^cb=3
\xspcode`^^cc=3
\xspcode`^^cd=3
\xspcode`^^ce=3
\xspcode`^^cf=3
\xspcode`^^d0=3
\xspcode`^^d1=3
\xspcode`^^d2=3
\xspcode`^^d3=3
\xspcode`^^d4=3
\xspcode`^^d5=3
\xspcode`^^d6=3
\xspcode`^^d7=3
\xspcode`^^d8=3
\xspcode`^^d9=3
\xspcode`^^da=3
\xspcode`^^db=3
\xspcode`^^dc=3
\xspcode`^^dd=3
\xspcode`^^de=3
\xspcode`^^df=3
\xspcode`^^e0=3
\xspcode`^^e1=3
\xspcode`^^e2=3
\xspcode`^^e3=3
\xspcode`^^e4=3
\xspcode`^^e5=3
\xspcode`^^e6=3
\xspcode`^^e7=3
\xspcode`^^e8=3
\xspcode`^^e9=3
\xspcode`^^ea=3
\xspcode`^^eb=3
\xspcode`^^ec=3
\xspcode`^^ed=3
\xspcode`^^ee=3
\xspcode`^^ef=3
\xspcode`^^f0=3
\xspcode`^^f1=3
\xspcode`^^f2=3
\xspcode`^^f3=3
\xspcode`^^f4=3
\xspcode`^^f5=3
\xspcode`^^f6=3
\xspcode`^^f7=3
\xspcode`^^f8=3
\xspcode`^^f9=3
\xspcode`^^fa=3
\xspcode`^^fb=3
\xspcode`^^fc=3
\xspcode`^^fd=3
\xspcode`^^fe=3
\xspcode`^^ff=3
% \end{macrocode}
%
% \begin{macro}{\@}
%
% 欧文といえば,\LaTeX の |\def\@{\spacefactor\@m}| という定義(|\@m| は1000)
% では |I watch TV\@.| と書くと V とピリオドのペアカーニングが効かなくなります。
% そこで,次のような定義に直し,|I watch TV.\@| と書くことにします。
%
% [2016-07-14] 2015-01-01の\LaTeX で,auxiliary filesに書き出されたときに
% スペースが食われないようにする修正が入りました。これに合わせて |{}| を補いました。
%
% \begin{macrocode}
\def\@{\spacefactor3000{}}
% \end{macrocode}
% \end{macro}
%
% \section{フォントサイズ}
%
% フォントサイズを変える命令(|\normalsize|,|\small| など)
% の実際の挙動の設定は,三つの引数をとる命令 |\@setfontsize| を使って,
% たとえば
% \begin{quote}
% |\@setfontsize{\normalsize}{10}{16}|
% \end{quote}
% のようにして行います。これは
% \begin{quote}
% |\normalsize| は10ポイントのフォントを使い,行送りは16ポイントである
% \end{quote}
% という意味です。
% ただし,処理を速くするため,
% 以下では10と同義の\LaTeX の内部命令 |\@xpt| を使っています。
% この |\@xpt| の類は次のものがあり,\LaTeX 本体で定義されています。
%\begin{verbatim}
% \@vpt 5 \@vipt 6 \@viipt 7
% \@viiipt 8 \@ixpt 9 \@xpt 10
% \@xipt 10.95 \@xiipt 12 \@xivpt 14.4
%\end{verbatim}
%
% \begin{macro}{\@setfontsize}
%
% ここでは |\@setfontsize| の定義を少々変更して,
% 段落の字下げ |\parindent|,
% 和文文字間のスペース |\kanjiskip|,
% 和文・欧文間のスペース |\xkanjiskip| を変更しています。
%
% |\kanjiskip| は\pLaTeXe で |0pt plus .4pt minus .5pt| に設定していますが,
% これはそもそも文字サイズの変更に応じて変わるべきものです。
% それに,プラスになったりマイナスになったりするのは,
% 追い出しと追い込みの混在が生じ,統一性を欠きます。
% なるべく追い出しになるようにプラスの値だけにしたいところですが,
% ごくわずかなマイナスは許すことにしました。
%
% |\xkanjiskip| については,四分つまり全角の1/4を標準として,
% 追い出すために三分あるいは二分まで延ばすのが一般的ですが,
% ここではTimesやPalatinoのスペースがほぼ四分であることに着目して,
% これに一致させています。これなら書くときにスペースを空けても
% 空けなくても同じ出力になります。
%
% |\parindent| については,0(以下)でなければ全角幅(1zw)に直します。
%
% [2008-02-18] |english| オプションで |\parindent| を 1em にしました。
%
% \begin{macrocode}
%</class>
%<*class|minijs>
%% \@setfontsize with \parindent and \(x)kanjiskip settings
\def\@setfontsize#1#2#3{%
%<minijs> \@nomath#1%
\ifx\protect\@typeset@protect
\let\@currsize#1%
\fi
\fontsize{#2}{#3}\selectfont
\ifdim\parindent>\z@
%<class> \if@english
%<class> \parindent=1em
%<class> \else
\parindent=1zw
%<class> \fi
\fi
\kanjiskip=0zw plus .1zw minus .01zw
%<class> \ifdim\xkanjiskip>\z@
%<class> \if@slide \xkanjiskip=0.1em \else
\xkanjiskip=0.25em plus 0.15em minus 0.06em
%<class> \fi
%<class> \fi
}
%</class|minijs>
%<*class>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\jsc@setfontsize}
% クラスファイルの内部では,拡大率も考慮した |\jsc@setfontsize| を
% |\@setfontsize| の変わりに用いることにします。
% \begin{macrocode}
\def\jsc@setfontsize#1#2#3{%
\@setfontsize#1{#2\jsc@mpt}{#3\jsc@mpt}}
% \end{macrocode}
% \end{macro}
%
% これらのグルーをもってしても行分割ができない場合は,
% |\emergencystretch| に訴えます。
%
% \begin{macrocode}
\emergencystretch 3zw
% \end{macrocode}
%
% \begin{macro}{\ifnarrowbaselines}
% \begin{macro}{\narrowbaselines}
% \begin{macro}{\widebaselines}
%
% 欧文用に行間を狭くする論理変数と,それを真・偽にするためのコマンドです。
%
% [2003-06-30] 数式に入るところで |\narrowbaselines|
% を実行しているので |\abovedisplayskip| 等が初期化
% されてしまうというshintokさんのご指摘に対して,
% しっぽ愛好家さんが次の修正を教えてくださいました。
%
% [2008-02-18] |english| オプションで最初の段落のインデントをしないようにしました。
%
% TODO: Hasumiさん [qa:54539] のご指摘は考慮中です。
%
% \begin{macrocode}
\newif\ifnarrowbaselines
\if@english
\narrowbaselinestrue
\fi
\def\narrowbaselines{%
\narrowbaselinestrue
\skip0=\abovedisplayskip
\skip2=\abovedisplayshortskip
\skip4=\belowdisplayskip
\skip6=\belowdisplayshortskip
\@currsize\selectfont
\abovedisplayskip=\skip0
\abovedisplayshortskip=\skip2
\belowdisplayskip=\skip4
\belowdisplayshortskip=\skip6\relax}
\def\widebaselines{\narrowbaselinesfalse\@currsize\selectfont}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\normalsize}
%
% 標準のフォントサイズと行送りを選ぶコマンドです。
%
% 本文10ポイントのときの行送りは,
% 欧文の標準クラスファイルでは12ポイント,
% アスキーの和文クラスファイルでは15ポイントになっていますが,
% ここでは16ポイントにしました。
% ただし |\narrowbaselines| で欧文用の12ポイントになります。
%
% 公称10ポイントの和文フォントが約9.25ポイント
% (アスキーのものの0.961倍)であることもあり,
% 行送りがかなりゆったりとしたと思います。
% 実際,$16/9.25 \approx 1.73$ であり,
% 和文の推奨値の一つ「二分四分」(1.75)
% に近づきました。
%
% \begin{macrocode}
\renewcommand{\normalsize}{%
\ifnarrowbaselines
\jsc@setfontsize\normalsize\@xpt\@xiipt
\else
\jsc@setfontsize\normalsize\@xpt{\n@baseline}%
\fi
% \end{macrocode}
%
% 数式の上のアキ(|\abovedisplayskip|),
% 短い数式の上のアキ(|\abovedisplayshortskip|),
% 数式の下のアキ(|\belowdisplayshortskip|)の設定です。
%
% [2003-02-16] ちょっと変えました。
%
% [2009-08-26] \TeX\ Q\,\&\,A 52569から始まる議論について逡巡して
% いましたが,結局,微調節してみることにしました。
%
% \begin{macrocode}
\abovedisplayskip 11\jsc@mpt \@plus3\jsc@mpt \@minus4\jsc@mpt
\abovedisplayshortskip \z@ \@plus3\jsc@mpt
\belowdisplayskip 9\jsc@mpt \@plus3\jsc@mpt \@minus4\jsc@mpt
\belowdisplayshortskip \belowdisplayskip
% \end{macrocode}
%
% 最後に,リスト環境のトップレベルのパラメータ |\@listI| を,
% |\@listi| にコピーしておきます。|\@listI| の設定は後で出てきます。
%
% \begin{macrocode}
\let\@listi\@listI}
% \end{macrocode}
%
% ここで実際に標準フォントサイズで初期化します。
%
% \begin{macrocode}
%</class>
%<*class|minijs>
%% initialize
\normalsize
%</class|minijs>
%<*class>
% \end{macrocode}
%
% \end{macro}
%
% \begin{macro}{\Cht}
% \begin{macro}{\Cdp}
% \begin{macro}{\Cwd}
% \begin{macro}{\Cvs}
% \begin{macro}{\Chs}
%
% 基準となる長さの設定をします。
% \pLaTeXe カーネル(\texttt{plfonts.dtx})で宣言されている
% パラメータに実際の値を設定します。
% たとえば |\Cwd| は |\normalfont| の全角幅(1zw)です。
%
% [2017-08-31] 基準とする文字を「全角空白」(EUCコード\texttt{0xA1A1})から
% 「漢」(JISコード\texttt{0x3441})へ変更しました。
%
% [2017-09-19] 内部的に使った |\box0| を空にします。
% \begin{macrocode}
\setbox0\hbox{\char\jis"3441}%
\setlength\Cht{\ht0}
\setlength\Cdp{\dp0}
\setlength\Cwd{\wd0}
\setlength\Cvs{\baselineskip}
\setlength\Chs{\wd0}
\setbox0=\box\voidb@x
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\small}
%
% |\small| も |\normalsize| と同様に設定します。
% 行送りは,|\normalsize| が16ポイントなら,
% 割合からすれば$16 \times 0.9 = 14.4$ポイントになりますが,
% |\small| の使われ方を考えて,ここでは和文13ポイント,
% 欧文11ポイントとします。
% また,|\topsep| と |\parsep| は,元はそれぞれ$4 \pm 2$,$2 \pm 1$
% ポイントでしたが,ここではゼロ(|\z@|)にしました。
%
% \begin{macrocode}
\newcommand{\small}{%
\ifnarrowbaselines
%<!kiyou> \jsc@setfontsize\small\@ixpt{11}%
%<kiyou> \jsc@setfontsize\small{8.8888}{11}%
\else
%<!kiyou> \jsc@setfontsize\small\@ixpt{13}%
%<kiyou> \jsc@setfontsize\small{8.8888}{13.2418}%
\fi
\abovedisplayskip 9\jsc@mpt \@plus3\jsc@mpt \@minus4\jsc@mpt
\abovedisplayshortskip \z@ \@plus3\jsc@mpt
\belowdisplayskip \abovedisplayskip
\belowdisplayshortskip \belowdisplayskip
\def\@listi{\leftmargin\leftmargini
\topsep \z@
\parsep \z@
\itemsep \parsep}}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\footnotesize}
%
% |\footnotesize| も同様です。
% |\topsep| と |\parsep| は,元はそれぞれ$3 \pm 1$,$2 \pm 1$
% ポイントでしたが,ここではゼロ(|\z@|)にしました。
%
% \begin{macrocode}
\newcommand{\footnotesize}{%
\ifnarrowbaselines
%<!kiyou> \jsc@setfontsize\footnotesize\@viiipt{9.5}%
%<kiyou> \jsc@setfontsize\footnotesize{8.8888}{11}%
\else
%<!kiyou> \jsc@setfontsize\footnotesize\@viiipt{11}%
%<kiyou> \jsc@setfontsize\footnotesize{8.8888}{13.2418}%
\fi
\abovedisplayskip 6\jsc@mpt \@plus2\jsc@mpt \@minus3\jsc@mpt
\abovedisplayshortskip \z@ \@plus2\jsc@mpt
\belowdisplayskip \abovedisplayskip
\belowdisplayshortskip \belowdisplayskip
\def\@listi{\leftmargin\leftmargini
\topsep \z@
\parsep \z@
\itemsep \parsep}}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\scriptsize}
% \begin{macro}{\tiny}
% \begin{macro}{\large}
% \begin{macro}{\Large}
% \begin{macro}{\LARGE}
% \begin{macro}{\huge}
% \begin{macro}{\Huge}
% \begin{macro}{\HUGE}
%
% それ以外のサイズは,本文に使うことがないので,
% 単にフォントサイズと行送りだけ変更します。
% 特に注意すべきは |\large| で,
% これは二段組のときに節見出しのフォントとして使い,
% 行送りを |\normalsize| と同じにすることによって,
% 節見出しが複数行にわたっても段間で行が揃うようにします。
%
% [2004-11-03] |\HUGE| を追加。
%
% \begin{macrocode}
\newcommand{\scriptsize}{\jsc@setfontsize\scriptsize\@viipt\@viiipt}
\newcommand{\tiny}{\jsc@setfontsize\tiny\@vpt\@vipt}
\if@twocolumn
%<!kiyou> \newcommand{\large}{\jsc@setfontsize\large\@xiipt{\n@baseline}}
%<kiyou> \newcommand{\large}{\jsc@setfontsize\large{11.111}{\n@baseline}}
\else
%<!kiyou> \newcommand{\large}{\jsc@setfontsize\large\@xiipt{17}}
%<kiyou> \newcommand{\large}{\jsc@setfontsize\large{11.111}{17}}
\fi
%<!kiyou>\newcommand{\Large}{\jsc@setfontsize\Large\@xivpt{21}}
%<kiyou>\newcommand{\Large}{\jsc@setfontsize\Large{12.222}{21}}
\newcommand{\LARGE}{\jsc@setfontsize\LARGE\@xviipt{25}}
\newcommand{\huge}{\jsc@setfontsize\huge\@xxpt{28}}
\newcommand{\Huge}{\jsc@setfontsize\Huge\@xxvpt{33}}
\newcommand{\HUGE}{\jsc@setfontsize\HUGE{30}{40}}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% 別行立て数式の中では |\narrowbaselines| にします。
% 和文の行送りのままでは,行列や場合分けの行送り,
% 連分数の高さなどが不釣合いに大きくなるためです。
%
% 本文中の数式の中では |\narrowbaselines| にしていません。
% 本文中ではなるべく行送りが変わるような大きいものを使わず,
% 行列は |amsmath| の |smallmatrix| 環境を使うのがいいでしょう。
%
% \begin{macrocode}
\everydisplay=\expandafter{\the\everydisplay \narrowbaselines}
% \end{macrocode}
%
% しかし,このおかげで別行数式の上下のスペースが少し違ってしまいました。
% とりあえず |amsmath| の |equation| 関係は |okumacro| のほうで逃げていますが,
% もっとうまい逃げ道があればお教えください。
%
% 見出し用のフォントは |\bfseries| 固定ではなく,|\headfont|
% という命令で定めることにします。
% これは太ゴシックが使えるときは |\sffamily| |\bfseries|
% でいいと思いますが,通常の中ゴシックでは単に |\sffamily|
% だけのほうがよさそうです。
% 『p\LaTeXe 美文書作成入門』(1997年)では |\sffamily|
% |\fontseries{sbc}| として新ゴMと合わせましたが,
% |\fontseries{sbc}| はちょっと幅が狭いように感じました。
%
% \begin{macrocode}
% \newcommand{\headfont}{\bfseries}
\newcommand{\headfont}{\gtfamily\sffamily}
% \newcommand{\headfont}{\sffamily\fontseries{sbc}\selectfont}
% \end{macrocode}
%
% \section{レイアウト}
%
% \paragraph{二段組}
%
% \begin{macro}{\columnsep}
% \begin{macro}{\columnseprule}
%
% |\columnsep| は二段組のときの左右の段間の幅です。
% 元は10ptでしたが,2zwにしました。
% このスペースの中央に |\columnseprule| の幅の罫線が引かれます。
%
% \begin{macrocode}
%<!kiyou>\setlength\columnsep{2zw}
%<kiyou>\setlength\columnsep{28truebp}
\setlength\columnseprule{\z@}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \paragraph{段落}
%
% \begin{macro}{\lineskip}
% \begin{macro}{\normallineskip}
% \begin{macro}{\lineskiplimit}
% \begin{macro}{\normallineskiplimit}
%
% 上下の行の文字が |\lineskiplimit| より接近したら,
% |\lineskip| より近づかないようにします。
% 元は0ptでしたが1ptに変更しました。
% \texttt{normal...} の付いた方は保存用です。
%
% \begin{macrocode}
\setlength\lineskip{1\jsc@mpt}
\setlength\normallineskip{1\jsc@mpt}
\setlength\lineskiplimit{1\jsc@mpt}
\setlength\normallineskiplimit{1\jsc@mpt}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\baselinestretch}
%
% 実際の行送りが |\baselineskip| の何倍かを表すマクロです。たとえば
% \begin{quote}
% |\renewcommand{\baselinestretch}{2}|
% \end{quote}
% とすると,行送りが通常の2倍になります。ただし,
% これを設定すると,たとえ |\baselineskip| が伸縮するように
% 設定しても,行送りの伸縮ができなくなります。
% 行送りの伸縮はしないのが一般的です。
%
% \begin{macrocode}
\renewcommand{\baselinestretch}{}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\parskip}
% \begin{macro}{\parindent}
%
% |\parskip| は段落間の追加スペースです。
% 元は 0pt plus 1pt になっていましたが,ここではゼロにしました。
% |\parindent| は段落の先頭の字下げ幅です。
%
% \begin{macrocode}
\setlength\parskip{\z@}
\if@slide
\setlength\parindent{0zw}
\else
\setlength\parindent{1zw}
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@lowpenalty}
% \begin{macro}{\@medpenalty}
% \begin{macro}{\@highpenalty}
%
% |\nopagebreak|,|\nolinebreak| は引数に応じて次のペナルティ値
% のうちどれかを選ぶようになっています。
% ここはオリジナル通りです。
%
% \begin{macrocode}
\@lowpenalty 51
\@medpenalty 151
\@highpenalty 301
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\interlinepenalty}
%
% 段落中の改ページのペナルティです。デフォルトは 0 です。
%
% \begin{macrocode}
% \interlinepenalty 0
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\brokenpenalty}
%
% ページの最後の行がハイフンで終わる際のペナルティです。
% デフォルトは100です。
%
% \begin{macrocode}
% \brokenpenalty 100
% \end{macrocode}
% \end{macro}
%
% \subsection{ページレイアウト}
%
% \paragraph{縦方向のスペース}
%
% \begin{macro}{\headheight}
% \begin{macro}{\topskip}
%
% |\topskip| は本文領域上端と本文1行目のベースラインとの距離です。
% あまりぎりぎりの値にすると,本文中に $\int$ のような高い文字が
% 入ったときに1行目のベースラインが他のページより下がってしまいます。
% ここでは本文の公称フォントサイズ(10pt)にします。
%
% [2003-06-26] |\headheight| はヘッダの高さで,
% 元は12ptでしたが,新ドキュメントクラスでは |\topskip|
% と等しくしていました。ところが,|fancyhdr| パッケージ
% で |\headheight| が小さいとおかしいことになるようです
% ので,2倍に増やしました。代わりに,版面の上下揃えの
% 計算では |\headheight| ではなく |\topskip| を使う
% ことにしました。
%
% [2016-08-17] 圏点やルビが一行目に来た場合に下がるのを防ぐた
% め,|\topskip| を10ptから1.38zwに増やしました。
% |\headheight| は従来と同じ20ptのままとします。
%
% \begin{macrocode}
\setlength\topskip{1.38zw}%% from 10\jsc@mpt (2016-08-17)
\if@slide
\setlength\headheight{0\jsc@mpt}
\else
\setlength\headheight{20\jsc@mpt}%% from 2\topskip (2016-08-17); from \topskip (2003-06-26)
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\footskip}
%
% |\footskip| は本文領域下端とフッタ下端との距離です。
% 標準クラスファイルでは,book で0.35in(約8.89mm),
% book 以外で30pt(約10.54mm)となっていましたが,
% ここではA4判のときちょうど1cmとなるように,
% |\paperheight| の0.03367倍(最小 |\baselineskip|)としました。
% 書籍については,フッタは使わないことにして,ゼロにしました。
%
% \begin{macrocode}
%<*article|kiyou>
\if@slide
\setlength\footskip{0pt}
\else
\setlength\footskip{0.03367\paperheight}
\ifdim\footskip<\baselineskip
\setlength\footskip{\baselineskip}
\fi
\fi
%</article|kiyou>
%<jspf>\setlength\footskip{9\jsc@mmm}
%<*book>
\if@report
\setlength\footskip{0.03367\paperheight}
\ifdim\footskip<\baselineskip
\setlength\footskip{\baselineskip}
\fi
\else
\setlength\footskip{0pt}
\fi
%</book>
%<*report>
\setlength\footskip{0.03367\paperheight}
\ifdim\footskip<\baselineskip
\setlength\footskip{\baselineskip}
\fi
%</report>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\headsep}
%
% |\headsep| はヘッダ下端と本文領域上端との距離です。
% 元は book で18pt(約6.33mm),
% それ以外で25pt(約8.79mm)になっていました。
% ここでは article は |\footskip| $-$ |\topskip| としました。
%
% [2016-10-08] article の \texttt{slide} のとき,
% および book の非 \texttt{report} と kiyou のときに |\headsep| を
% 減らしそこねていたのを修正しました(2016-08-17での修正漏れ)。
%
% \begin{macrocode}
%<*article>
\if@slide
\setlength\headsep{0\jsc@mpt}
\addtolength\headsep{-\topskip}%% added (2016-10-08)
\addtolength\headsep{10\jsc@mpt}%% added (2016-10-08)
\else
\setlength\headsep{\footskip}
\addtolength\headsep{-\topskip}
\fi
%</article>
%<*book>
\if@report
\setlength\headsep{\footskip}
\addtolength\headsep{-\topskip}
\else
\setlength\headsep{6\jsc@mmm}
\addtolength\headsep{-\topskip}%% added (2016-10-08)
\addtolength\headsep{10\jsc@mpt}%% added (2016-10-08)
\fi
%</book>
%<*report>
\setlength\headsep{\footskip}
\addtolength\headsep{-\topskip}
%</report>
%<*jspf>
\setlength\headsep{9\jsc@mmm}
\addtolength\headsep{-\topskip}
%</jspf>
%<*kiyou>
\setlength\headheight{0\jsc@mpt}
\setlength\headsep{0\jsc@mpt}
\addtolength\headsep{-\topskip}%% added (2016-10-08)
\addtolength\headsep{10\jsc@mpt}%% added (2016-10-08)
%</kiyou>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\maxdepth}
%
% |\maxdepth| は本文最下行の最大の深さで,
% plain \TeX や\LaTeX~2.09では4ptに固定でした。
% \LaTeX2e では |\maxdepth| $+$ |\topskip| を本文フォントサイズ
% の1.5倍にしたいのですが,|\topskip| は本文フォントサイズ
% (ここでは10pt)に等しいので,結局 |\maxdepth| は |\topskip|
% の半分の値(具体的には5pt)にします。
%
% \begin{macrocode}
\setlength\maxdepth{.5\topskip}
% \end{macrocode}
% \end{macro}
%
% \paragraph{本文の幅と高さ}
%
% \begin{macro}{\fullwidth}
%
% 本文の幅が全角40文字を超えると読みにくくなります。
% そこで,書籍の場合に限って,
% 紙の幅が広いときは外側のマージンを余分にとって全角40文字に押え,
% ヘッダやフッタは本文領域より広く取ることにします。
% このときヘッダやフッタの幅を表す |\fullwidth| という長さを定義します。
%
% \begin{macrocode}
\newdimen\fullwidth
% \end{macrocode}
%
% この |\fullwidth| は article では紙幅 |\paperwidth|の0.76倍を超えない
% 全角幅の整数倍(二段組では全角幅の偶数倍)にします。0.76倍という数値は
% A4縦置きの場合に紙幅から約2インチを引いた値になるように選びました。
% book では紙幅から36ミリを引いた値にしました。
%
% \begin{macro}{\textwidth}
%
% 書籍以外では本文領域の幅 |\textwidth| は |\fullwidth| と等しくします。
% |article| ではA4縦置きで49文字となります。
% 某学会誌スタイルでは50zw(25文字×2段)+段間8mmとします。
%
% \begin{macrocode}
%<*article>
\if@slide
\setlength\fullwidth{0.9\paperwidth}
\else
\setlength\fullwidth{0.76\paperwidth}
\fi
\if@twocolumn \@tempdima=2zw \else \@tempdima=1zw \fi
\divide\fullwidth\@tempdima \multiply\fullwidth\@tempdima
\setlength\textwidth{\fullwidth}
%</article>
%<*book>
\if@report
\setlength\fullwidth{0.76\paperwidth}
\else
\setlength\fullwidth{\paperwidth}
\addtolength\fullwidth{-36\jsc@mmm}
\fi
\if@twocolumn \@tempdima=2zw \else \@tempdima=1zw \fi
\divide\fullwidth\@tempdima \multiply\fullwidth\@tempdima
\setlength\textwidth{\fullwidth}
\if@report \else
\if@twocolumn \else
\ifdim \fullwidth>40zw
\setlength\textwidth{40zw}
\fi
\fi
\fi
%</book>
%<*report>
\setlength\fullwidth{0.76\paperwidth}
\if@twocolumn \@tempdima=2zw \else \@tempdima=1zw \fi
\divide\fullwidth\@tempdima \multiply\fullwidth\@tempdima
\setlength\textwidth{\fullwidth}
%</report>
%<*jspf>
\setlength\fullwidth{50zw}
\addtolength\fullwidth{8\jsc@mmm}
\setlength\textwidth{\fullwidth}
%</jspf>
%<*kiyou>
\setlength\fullwidth{48zw}
\addtolength\fullwidth{\columnsep}
\setlength\textwidth{\fullwidth}
%</kiyou>
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\textheight}
%
% 紙の高さ |\paperheight| は,1インチと |\topmargin|
% と |\headheight| と |\headsep| と |\textheight|
% と |\footskip| とページ下部の余白を加えたものです。
%
% 本文部分の高さ |\textheight| は,
% 紙の高さ |\paperheight| の0.83倍から,
% ヘッダの高さ,ヘッダと本文の距離,本文とフッタ下端の距離,
% |\topskip| を引き,
% それを |\baselineskip| の倍数に切り捨て,
% 最後に |\topskip| を加えます。
% 念のため0.1ポイント余分に加えておきます。
% 0.83倍という数値は,A4縦置きの場合に紙の高さから
% 上下マージン各約1インチを引いた値になるように選びました。
%
% 某学会誌スタイルでは44行にします。
%
% [2003-06-26] |\headheight| を |\topskip| に直しました。
% 以前はこの二つは値が同じであったので,変化はないはずです。
%
% [2016-08-26] |\topskip| を10ptから1.38zwに増やしましたので,
% その分 |\textheight| を増やします(2016-08-17での修正漏れ)。
%
% [2016-10-08] article の slide のときに |\headheight| はゼロ
% なので,さらに修正しました(2016-08-17での修正漏れ)。
%
% \begin{macrocode}
%<*article|book|report>
\if@slide
\setlength{\textheight}{0.95\paperheight}
\else
\setlength{\textheight}{0.83\paperheight}
\fi
\addtolength{\textheight}{-10\jsc@mpt}%% from -\topskip (2016-10-08); from -\headheight (2003-06-26)
\addtolength{\textheight}{-\headsep}
\addtolength{\textheight}{-\footskip}
\addtolength{\textheight}{-\topskip}
\divide\textheight\baselineskip
\multiply\textheight\baselineskip
%</article|book|report>
%<jspf>\setlength{\textheight}{51\baselineskip}
%<kiyou>\setlength{\textheight}{47\baselineskip}
\addtolength{\textheight}{\topskip}
\addtolength{\textheight}{0.1\jsc@mpt}
%<jspf>\setlength{\mathindent}{10\jsc@mmm}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\flushbottom}
%
% [2016-07-18] |\textheight| に念のため0.1ポイント余裕を持たせて
% いるのと同様に,|\flushbottom| にも余裕を持たせます。
% 元の\LaTeXe での完全な |\flushbottom| の定義は
%\begin{verbatim}
% \def\flushbottom{%
% \let\@textbottom\relax \let\@texttop\relax}
%\end{verbatim}
% ですが,次のようにします。
%
% \begin{macrocode}
\def\flushbottom{%
\def\@textbottom{\vskip \z@ \@plus.1\jsc@mpt}%
\let\@texttop\relax}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\marginparsep}
% \begin{macro}{\marginparpush}
%
% |\marginparsep| は欄外の書き込みと本文との間隔です。
% |\marginparpush| は欄外の書き込みどうしの最小の間隔です。
%
% \begin{macrocode}
\setlength\marginparsep{\columnsep}
\setlength\marginparpush{\baselineskip}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\oddsidemargin}
% \begin{macro}{\evensidemargin}
%
% それぞれ奇数ページ,偶数ページの左マージンから1インチ引いた値です。
% 片面印刷では |\oddsidemargin| が使われます。
% \TeX は上・左マージンに |1truein| を挿入しますが,
% トンボ関係のオプションが指定されるとp\LaTeXe (|plcore.ltx|)
% はトンボの内側に |1in| のスペース(|1truein| ではなく)を挿入するので,
% 場合分けしています。
%
% \begin{macrocode}
\setlength{\oddsidemargin}{\paperwidth}
\addtolength{\oddsidemargin}{-\fullwidth}
\setlength{\oddsidemargin}{.5\oddsidemargin}
\iftombow
\addtolength{\oddsidemargin}{-1in}
\else
\addtolength{\oddsidemargin}{-\inv@mag in}
\fi
\setlength{\evensidemargin}{\oddsidemargin}
\if@mparswitch
\addtolength{\evensidemargin}{\fullwidth}
\addtolength{\evensidemargin}{-\textwidth}
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\marginparwidth}
%
% |\marginparwidth| は欄外の書き込みの横幅です。
% 外側マージンの幅(|\evensidemargin| $+$ 1インチ)から1センチを引き,
% さらに |\marginparsep|(欄外の書き込みと本文のアキ)を引いた値に
% しました。最後に1\,zwの整数倍に切り捨てます。
%
% \begin{macrocode}
\setlength\marginparwidth{\paperwidth}
\addtolength\marginparwidth{-\oddsidemargin}
\addtolength\marginparwidth{-\inv@mag in}
\addtolength\marginparwidth{-\textwidth}
\addtolength\marginparwidth{-10\jsc@mmm}
\addtolength\marginparwidth{-\marginparsep}
\@tempdima=1zw
\divide\marginparwidth\@tempdima
\multiply\marginparwidth\@tempdima
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\topmargin}
%
% 上マージン(紙の上端とヘッダ上端の距離)
% から1インチ引いた値です。
%
% [2003-06-26] |\headheight| を |\topskip| に直しました。
% 以前はこの二つは値が同じであったので,変化はないはずです。
%
% [2016-08-17] |\topskip| を10ptから1.38zwに直しましたが,
% |\topmargin| は従来の値から変わらないように調節しました。
% …のつもりでしたが,|\textheight| を増やし忘れていたので
% 変わってしまっていました(2016-08-26修正済み)。
%
% \begin{macrocode}
\setlength\topmargin{\paperheight}
\addtolength\topmargin{-\textheight}
\if@slide
\addtolength\topmargin{-\headheight}
\else
\addtolength\topmargin{-10\jsc@mpt}%% from -\topskip (2016-10-08); from -\headheight (2003-06-26)
\fi
\addtolength\topmargin{-\headsep}
\addtolength\topmargin{-\footskip}
\setlength\topmargin{0.5\topmargin}
%<kiyou>\setlength\topmargin{81truebp}
\iftombow
\addtolength\topmargin{-1in}
\else
\addtolength\topmargin{-\inv@mag in}
\fi
% \end{macrocode}
% \end{macro}
%
% \paragraph{脚注}
%
% \begin{macro}{\footnotesep}
%
% 各脚注の頭に入る支柱(strut)の高さです。
% 脚注間に余分のアキが入らないように,
% |\footnotesize| の支柱の高さ(行送りの0.7倍)に等しくします。
%
% \begin{macrocode}
{\footnotesize\global\setlength\footnotesep{\baselineskip}}
\setlength\footnotesep{0.7\footnotesep}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\footins}
%
% |\skip\footins| は本文の最終行と最初の脚注との間の距離です。
% 標準の10ポイントクラスでは 9 plus 4 minus 2 ポイントになっていますが,
% 和文の行送りを考えてもうちょっと大きくします。
%
% \begin{macrocode}
\setlength{\skip\footins}{16\jsc@mpt \@plus 5\jsc@mpt \@minus 2\jsc@mpt}
% \end{macrocode}
% \end{macro}
%
% \paragraph{フロート関連}
%
% フロート(図,表)関連のパラメータは\LaTeXe 本体で定義されていますが,
% ここで設定変更します。本文ページ(本文とフロートが共存するページ)
% とフロートだけのページで設定が異なります。
% ちなみに,カウンタは内部では |\c@| を名前に冠したマクロになっています。
%
% \begin{macro}{\c@topnumber}
%
% |topnumber| カウンタは本文ページ上部のフロートの最大数です。
%
% [2003-08-23] ちょっと増やしました。
%
% \begin{macrocode}
\setcounter{topnumber}{9}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\topfraction}
%
% 本文ページ上部のフロートが占有できる最大の割合です。
% フロートが入りやすいように,元の値 0.7 を 0.8 [2003-08-23: 0.85] に変えてあります。
%
% \begin{macrocode}
\renewcommand{\topfraction}{.85}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\c@bottomnumber}
%
% |bottomnumber| カウンタは本文ページ下部のフロートの最大数です。
%
% [2003-08-23] ちょっと増やしました。
%
% \begin{macrocode}
\setcounter{bottomnumber}{9}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\bottomfraction}
%
% 本文ページ下部のフロートが占有できる最大の割合です。元は 0.3 でした。
%
% \begin{macrocode}
\renewcommand{\bottomfraction}{.8}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\c@totalnumber}
%
% |totalnumber| カウンタは本文ページに入りうるフロートの最大数です。
%
% [2003-08-23] ちょっと増やしました。
%
% \begin{macrocode}
\setcounter{totalnumber}{20}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\textfraction}
%
% 本文ページに最低限入らなければならない本文の割合です。
% フロートが入りやすいように元の 0.2 を 0.1 に変えました。
%
% \begin{macrocode}
\renewcommand{\textfraction}{.1}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\floatpagefraction}
%
% フロートだけのページでのフロートの最小割合です。
% これも 0.5 を 0.8 に変えてあります。
%
% \begin{macrocode}
\renewcommand{\floatpagefraction}{.8}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\c@dbltopnumber}
%
% 二段組のとき本文ページ上部に出力できる
% 段抜きフロートの最大数です。
%
% [2003-08-23] ちょっと増やしました。
%
% \begin{macrocode}
\setcounter{dbltopnumber}{9}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\dbltopfraction}
%
% 二段組のとき本文ページ上部に出力できる
% 段抜きフロートが占めうる最大の割合です。
% 0.7 を 0.8 に変えてあります。
%
% \begin{macrocode}
\renewcommand{\dbltopfraction}{.8}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\dblfloatpagefraction}
%
% 二段組のときフロートだけのページに入るべき
% 段抜きフロートの最小割合です。
% 0.5 を 0.8 に変えてあります。
%
% \begin{macrocode}
\renewcommand{\dblfloatpagefraction}{.8}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\floatsep}
% \begin{macro}{\textfloatsep}
% \begin{macro}{\intextsep}
%
% |\floatsep| はページ上部・下部のフロート間の距離です。
% |\textfloatsep| はページ上部・下部のフロートと本文との距離です。
% |\intextsep| は本文の途中に出力されるフロートと本文との距離です。
%
% \begin{macrocode}
\setlength\floatsep {12\jsc@mpt \@plus 2\jsc@mpt \@minus 2\jsc@mpt}
\setlength\textfloatsep{20\jsc@mpt \@plus 2\jsc@mpt \@minus 4\jsc@mpt}
\setlength\intextsep {12\jsc@mpt \@plus 2\jsc@mpt \@minus 2\jsc@mpt}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\dblfloatsep}
% \begin{macro}{\dbltextfloatsep}
%
% 二段組のときの段抜きのフロートについての値です。
%
% \begin{macrocode}
\setlength\dblfloatsep {12\jsc@mpt \@plus 2\jsc@mpt \@minus 2\jsc@mpt}
\setlength\dbltextfloatsep{20\jsc@mpt \@plus 2\jsc@mpt \@minus 4\jsc@mpt}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@fptop}
% \begin{macro}{\@fpsep}
% \begin{macro}{\@fpbot}
%
% フロートだけのページに入るグルーです。
% |\@fptop| はページ上部,
% |\@fpbot| はページ下部,
% |\@fpsep| はフロート間に入ります。
%
% \begin{macrocode}
\setlength\@fptop{0\jsc@mpt \@plus 1fil}
\setlength\@fpsep{8\jsc@mpt \@plus 2fil}
\setlength\@fpbot{0\jsc@mpt \@plus 1fil}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@dblfptop}
% \begin{macro}{\@dblfpsep}
% \begin{macro}{\@dblfpbot}
%
% 段抜きフロートについての値です。
%
% \begin{macrocode}
\setlength\@dblfptop{0\jsc@mpt \@plus 1fil}
\setlength\@dblfpsep{8\jsc@mpt \@plus 2fil}
\setlength\@dblfpbot{0\jsc@mpt \@plus 1fil}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \section{改ページ(日本語\TeX{}開発コミュニティ版のみ)}\label{sec:cleardoublepage}
%
% \begin{macro}{\pltx@cleartorightpage}
% \begin{macro}{\pltx@cleartoleftpage}
% \begin{macro}{\pltx@cleartooddpage}
% \begin{macro}{\pltx@cleartoevenpage}
% [2017-02-24] コミュニティ版\pLaTeX の標準クラス2017/02/15に合わせて,
% 同じ命令を追加しました。
% \begin{enumerate}
% \item|\pltx@cleartorightpage|:右ページになるまでページを繰る命令
% \item|\pltx@cleartoleftpage|:左ページになるまでページを繰る命令
% \item|\pltx@cleartooddpage|:奇数ページになるまでページを繰る命令
% \item|\pltx@cleartoevenpage|:偶数ページになるまでページを繰る命令
% \end{enumerate}
% となっています。
%
% \begin{macrocode}
%<*article|book|report>
\def\pltx@cleartorightpage{\clearpage\if@twoside
\ifodd\c@page
\iftdir
\hbox{}\thispagestyle{empty}\newpage
\if@twocolumn\hbox{}\newpage\fi
\fi
\else
\ifydir
\hbox{}\thispagestyle{empty}\newpage
\if@twocolumn\hbox{}\newpage\fi
\fi
\fi\fi}
\def\pltx@cleartoleftpage{\clearpage\if@twoside
\ifodd\c@page
\ifydir
\hbox{}\thispagestyle{empty}\newpage
\if@twocolumn\hbox{}\newpage\fi
\fi
\else
\iftdir
\hbox{}\thispagestyle{empty}\newpage
\if@twocolumn\hbox{}\newpage\fi
\fi
\fi\fi}
\def\pltx@cleartooddpage{\clearpage\if@twoside
\ifodd\c@page\else
\hbox{}\thispagestyle{empty}\newpage
\if@twocolumn\hbox{}\newpage\fi
\fi\fi}
\def\pltx@cleartoevenpage{\clearpage\if@twoside
\ifodd\c@page
\hbox{}\thispagestyle{empty}\newpage
\if@twocolumn\hbox{}\newpage\fi
\fi\fi}
%</article|book|report>
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\cleardoublepage}
% [2017-02-24] コミュニティ版\pLaTeX の標準クラス2017/02/15に合わせて,
% reportとbookクラスの場合に|\cleardoublepage|を再定義します。
% \begin{macrocode}
%<*book|report>
\if@openleft
\let\cleardoublepage\pltx@cleartoleftpage
\else\if@openright
\let\cleardoublepage\pltx@cleartorightpage
\fi\fi
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \section{ページスタイル}\label{sec:pagestyle}
%
% ページスタイルとして,\LaTeXe (欧文版)の標準クラス
% では |empty|,|plain|,|headings|,|myheadings| があります。
% このうち |empty|,|plain| スタイルは\LaTeXe 本体
% で定義されています。
%
% アスキーのクラスファイルでは |headnombre|,|footnombre|,
% |bothstyle|,|jpl@in| が追加されていますが,
% ここでは欧文標準のものだけにしました。
%
% ページスタイルは |\ps@...| の形のマクロで定義されています。
%
% \begin{macro}{\@evenhead}
% \begin{macro}{\@oddhead}
% \begin{macro}{\@evenfoot}
% \begin{macro}{\@oddfoot}
%
% |\@oddhead|,|\@oddfoot|,|\@evenhead|,|\@evenfoot| は
% 偶数・奇数ページの柱(ヘッダ,フッタ)を出力する命令です。
% これらは |\fullwidth| 幅の |\hbox| の中で呼び出されます。
% |\ps@...| の中で定義しておきます。
%
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% 柱の内容は,|\chapter| が呼び出す |\chaptermark{何々}|,
% |\section| が呼び出す |\sectionmark{何々}| で設定します。
% 柱を扱う命令には次のものがあります。
%
% \begin{quote}
% \begin{tabbing}
% |\markboth{左}{右} | \= 両方の柱を設定します。\\
% |\markright{右}| \> 右の柱を設定します。\\
% |\leftmark| \> 左の柱を出力します。\\
% |\rightmark| \> 右の柱を出力します。
% \end{tabbing}
% \end{quote}
%
% 柱を設定する命令は,右の柱が左の柱の下位にある場合は十分まともに
% 動作します。たとえば左マークを |\chapter|,右マークを |\section|
% で変更する場合がこれにあたります。
% しかし,同一ページに複数の |\markboth| があると,
% おかしな結果になることがあります。
%
% |\tableofcontents| のような命令で使われる |\@mkboth| は,
% |\ps@...| コマンド中で |\markboth| か |\@gobbletwo|(何もしない)
% に |\let| されます。
%
% \begin{macro}{\ps@empty}
%
% |empty| ページスタイルの定義です。
% \LaTeX 本体で定義されているものをコメントアウトした形で
% 載せておきます。
%
% \begin{macrocode}
% \def\ps@empty{%
% \let\@mkboth\@gobbletwo
% \let\@oddhead\@empty
% \let\@oddfoot\@empty
% \let\@evenhead\@empty
% \let\@evenfoot\@empty}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\ps@plainhead}
% \begin{macro}{\ps@plainfoot}
% \begin{macro}{\ps@plain}
%
% |plainhead| はシンプルなヘッダだけのページスタイルです。
%
% |plainfoot| はシンプルなフッタだけのページスタイルです。
%
% |plain| は |book| では |plainhead|,それ以外では |plainfoot| になります。
%
% \begin{macrocode}
\def\ps@plainfoot{%
\let\@mkboth\@gobbletwo
\let\@oddhead\@empty
\def\@oddfoot{\normalfont\hfil\thepage\hfil}%
\let\@evenhead\@empty
\let\@evenfoot\@oddfoot}
\def\ps@plainhead{%
\let\@mkboth\@gobbletwo
\let\@oddfoot\@empty
\let\@evenfoot\@empty
\def\@evenhead{%
\if@mparswitch \hss \fi
\hbox to \fullwidth{\textbf{\thepage}\hfil}%
\if@mparswitch\else \hss \fi}%
\def\@oddhead{%
\hbox to \fullwidth{\hfil\textbf{\thepage}}\hss}}
%<book>\if@report \let\ps@plain\ps@plainfoot \else \let\ps@plain\ps@plainhead \fi
%<!book>\let\ps@plain\ps@plainfoot
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\ps@headings}
%
% |headings| スタイルはヘッダに見出しとページ番号を出力します。
% ここではヘッダにアンダーラインを引くようにしてみました。
%
% まず article の場合です。
%
% \begin{macrocode}
%<*article|kiyou>
\if@twoside
\def\ps@headings{%
\let\@oddfoot\@empty
\let\@evenfoot\@empty
\def\@evenhead{\if@mparswitch \hss \fi
\underline{\hbox to \fullwidth{\textbf{\thepage}\hfil\leftmark}}%
\if@mparswitch\else \hss \fi}%
\def\@oddhead{%
\underline{%
\hbox to \fullwidth{{\rightmark}\hfil\textbf{\thepage}}}\hss}%
\let\@mkboth\markboth
\def\sectionmark##1{\markboth{%
\ifnum \c@secnumdepth >\z@ \thesection \hskip1zw\fi
##1}{}}%
\def\subsectionmark##1{\markright{%
\ifnum \c@secnumdepth >\@ne \thesubsection \hskip1zw\fi
##1}}%
}
\else % if not twoside
\def\ps@headings{%
\let\@oddfoot\@empty
\def\@oddhead{%
\underline{%
\hbox to \fullwidth{{\rightmark}\hfil\textbf{\thepage}}}\hss}%
\let\@mkboth\markboth
\def\sectionmark##1{\markright{%
\ifnum \c@secnumdepth >\z@ \thesection \hskip1zw\fi
##1}}}
\fi
%</article|kiyou>
% \end{macrocode}
%
% 次は book および report の場合です。
% [2011-05-10] しっぽ愛好家さん [qa:6370] のパッチを取り込ませていただきました
% (北見さん [qa:55896] のご指摘ありがとうございます)。
%
% \begin{macrocode}
%<*book|report>
\newif\if@omit@number
\def\ps@headings{%
\let\@oddfoot\@empty
\let\@evenfoot\@empty
\def\@evenhead{%
\if@mparswitch \hss \fi
\underline{\hbox to \fullwidth{\autoxspacing
\textbf{\thepage}\hfil\leftmark}}%
\if@mparswitch\else \hss \fi}%
\def\@oddhead{\underline{\hbox to \fullwidth{\autoxspacing
{\if@twoside\rightmark\else\leftmark\fi}\hfil\textbf{\thepage}}}\hss}%
\let\@mkboth\markboth
\def\chaptermark##1{\markboth{%
\ifnum \c@secnumdepth >\m@ne
%<book> \if@mainmatter
\if@omit@number\else
\@chapapp\thechapter\@chappos\hskip1zw
\fi
%<book> \fi
\fi
##1}{}}%
\def\sectionmark##1{\markright{%
\ifnum \c@secnumdepth >\z@ \thesection \hskip1zw\fi
##1}}}%
%</book|report>
% \end{macrocode}
%
% 最後は学会誌の場合です。
%
% \begin{macrocode}
%<*jspf>
\def\ps@headings{%
\def\@oddfoot{\normalfont\hfil\thepage\hfil}
\def\@evenfoot{\normalfont\hfil\thepage\hfil}
\def\@oddhead{\normalfont\hfil \@title \hfil}
\def\@evenhead{\normalfont\hfil プラズマ・核融合学会誌\hfil}}
%</jspf>
% \end{macrocode}
%
% \end{macro}
%
% \begin{macro}{\ps@myheadings}
%
% |myheadings| ページスタイルではユーザが |\markboth| や |\markright| で
% 柱を設定するため,ここでの定義は非常に簡単です。
%
% [2004-01-17] 渡辺徹さんのパッチを適用しました。
%
% \begin{macrocode}
\def\ps@myheadings{%
\let\@oddfoot\@empty\let\@evenfoot\@empty
\def\@evenhead{%
\if@mparswitch \hss \fi%
\hbox to \fullwidth{\thepage\hfil\leftmark}%
\if@mparswitch\else \hss \fi}%
\def\@oddhead{%
\hbox to \fullwidth{\rightmark\hfil\thepage}\hss}%
\let\@mkboth\@gobbletwo
%<book|report> \let\chaptermark\@gobble
\let\sectionmark\@gobble
%<!book&!report> \let\subsectionmark\@gobble
}
% \end{macrocode}
% \end{macro}
%
% \section{文書のマークアップ}
%
% \subsection{表題}
%
% \begin{macro}{\title}
% \begin{macro}{\author}
% \begin{macro}{\date}
%
% これらは\LaTeX 本体で次のように定義されています。
% ここではコメントアウトした形で示します。
%
% \begin{macrocode}
% \newcommand*{\title}[1]{\gdef\@title{#1}}
% \newcommand*{\author}[1]{\gdef\@author{#1}}
% \newcommand*{\date}[1]{\gdef\@date{#1}}
% \date{\today}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\etitle}
% \begin{macro}{\eauthor}
% \begin{macro}{\keywords}
%
% 某学会誌スタイルで使う英語のタイトル,英語の著者名,キーワード,メールアドレスです。
%
% \begin{macrocode}
%<*jspf>
\newcommand*{\etitle}[1]{\gdef\@etitle{#1}}
\newcommand*{\eauthor}[1]{\gdef\@eauthor{#1}}
\newcommand*{\keywords}[1]{\gdef\@keywords{#1}}
\newcommand*{\email}[1]{\gdef\authors@mail{#1}}
\newcommand*{\AuthorsEmail}[1]{\gdef\authors@mail{author's e-mail:\ #1}}
%</jspf>
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\plainifnotempty}
%
% 従来の標準クラスでは,文書全体のページスタイルを |empty| に
% しても表題のあるページだけ |plain| になってしまうことが
% ありました。これは |\maketitle| の定義中
% に |\thispagestyle|\hspace{0pt}|{plain}| が入っている
% ためです。この問題を解決するために,
% 「全体のページスタイルが |empty| でないなら
% このページのスタイルを |plain| にする」という次の
% 命令を作ることにします。
%
% \begin{macrocode}
\def\plainifnotempty{%
\ifx \@oddhead \@empty
\ifx \@oddfoot \@empty
\else
\thispagestyle{plainfoot}%
\fi
\else
\thispagestyle{plainhead}%
\fi}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\maketitle}
%
% 表題を出力します。
% 著者名を出力する部分は,欧文の標準クラスファイルでは |\large|,
% 和文のものでは |\Large| になっていましたが,ここでは |\large|
% にしました。
%
% [2016-11-16] 新設された \texttt{nomag} および \texttt{nomag*} オプション
% の場合をデフォルト(\texttt{usemag} 相当)に合わせるため,|\smallskip| を
% |\jsc@smallskip| に置き換えました。|\smallskip| のままでは
% \texttt{nomag(*)} の場合にスケールしなくなり,レイアウトが変わってしまいます。
%
% \begin{macrocode}
%<*article|book|report|kiyou>
\if@titlepage
\newcommand{\maketitle}{%
\begin{titlepage}%
\let\footnotesize\small
\let\footnoterule\relax
\let\footnote\thanks
\null\vfil
\if@slide
{\footnotesize \@date}%
\begin{center}
\mbox{} \\[1zw]
\large
{\maybeblue\hrule height0\jsc@mpt depth2\jsc@mpt\relax}\par
\jsc@smallskip
\@title
\jsc@smallskip
{\maybeblue\hrule height0\jsc@mpt depth2\jsc@mpt\relax}\par
\vfill
{\small \@author}%
\end{center}
\else
\vskip 60\jsc@mpt
\begin{center}%
{\LARGE \@title \par}%
\vskip 3em%
{\large
\lineskip .75em
\begin{tabular}[t]{c}%
\@author
\end{tabular}\par}%
\vskip 1.5em
{\large \@date \par}%
\end{center}%
\fi
\par
\@thanks\vfil\null
\end{titlepage}%
\setcounter{footnote}{0}%
\global\let\thanks\relax
\global\let\maketitle\relax
\global\let\@thanks\@empty
\global\let\@author\@empty
\global\let\@date\@empty
\global\let\@title\@empty
\global\let\title\relax
\global\let\author\relax
\global\let\date\relax
\global\let\and\relax
}%
\else
\newcommand{\maketitle}{\par
\begingroup
\renewcommand\thefootnote{\@fnsymbol\c@footnote}%
\def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}%
\long\def\@makefntext##1{\advance\leftskip 3zw
\parindent 1zw\noindent
\llap{\@textsuperscript{\normalfont\@thefnmark}\hskip0.3zw}##1}%
\if@twocolumn
\ifnum \col@number=\@ne
\@maketitle
\else
\twocolumn[\@maketitle]%
\fi
\else
\newpage
\global\@topnum\z@ % Prevents figures from going at top of page.
\@maketitle
\fi
\plainifnotempty
\@thanks
\endgroup
\setcounter{footnote}{0}%
\global\let\thanks\relax
\global\let\maketitle\relax
\global\let\@thanks\@empty
\global\let\@author\@empty
\global\let\@date\@empty
\global\let\@title\@empty
\global\let\title\relax
\global\let\author\relax
\global\let\date\relax
\global\let\and\relax
}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@maketitle}
%
% 独立した表題ページを作らない場合の表題の出力形式です。
%
% \begin{macrocode}
\def\@maketitle{%
\newpage\null
\vskip 2em
\begin{center}%
\let\footnote\thanks
{\LARGE \@title \par}%
\vskip 1.5em
{\large
\lineskip .5em
\begin{tabular}[t]{c}%
\@author
\end{tabular}\par}%
\vskip 1em
{\large \@date}%
\end{center}%
\par\vskip 1.5em
%<article|report|kiyou> \ifvoid\@abstractbox\else\centerline{\box\@abstractbox}\vskip1.5em\fi
}
\fi
%</article|book|report|kiyou>
%<*jspf>
\newcommand{\maketitle}{\par
\begingroup
\renewcommand\thefootnote{\@fnsymbol\c@footnote}%
\def\@makefnmark{\rlap{\@textsuperscript{\normalfont\@thefnmark}}}%
\long\def\@makefntext##1{\advance\leftskip 3zw
\parindent 1zw\noindent
\llap{\@textsuperscript{\normalfont\@thefnmark}\hskip0.3zw}##1}%
\twocolumn[\@maketitle]%
\plainifnotempty
\@thanks
\endgroup
\setcounter{footnote}{0}%
\global\let\thanks\relax
\global\let\maketitle\relax
\global\let\@thanks\@empty
\global\let\@author\@empty
\global\let\@date\@empty
% \global\let\@title\@empty % \@title は柱に使う
\global\let\title\relax
\global\let\author\relax
\global\let\date\relax
\global\let\and\relax
\ifx\authors@mail\@undefined\else{%
\def\@makefntext{\advance\leftskip 3zw \parindent -3zw}%
\footnotetext[0]{\itshape\authors@mail}%
}\fi
\global\let\authors@mail\@undefined}
\def\@maketitle{%
\newpage\null
\vskip 6em % used to be 2em
\begin{center}
\let\footnote\thanks
\ifx\@title\@undefined\else{\LARGE\headfont\@title\par}\fi
\lineskip .5em
\ifx\@author\@undefined\else
\vskip 1em
\begin{tabular}[t]{c}%
\@author
\end{tabular}\par
\fi
\ifx\@etitle\@undefined\else
\vskip 1em
{\large \@etitle \par}%
\fi
\ifx\@eauthor\@undefined\else
\vskip 1em
\begin{tabular}[t]{c}%
\@eauthor
\end{tabular}\par
\fi
\vskip 1em
\@date
\end{center}
\vskip 1.5em
\centerline{\box\@abstractbox}
\ifx\@keywords\@undefined\else
\vskip 1.5em
\centerline{\parbox{157\jsc@mmm}{\textsf{Keywords:}\\ \small\@keywords}}
\fi
\vskip 1.5em}
%</jspf>
% \end{macrocode}
% \end{macro}
%
% \subsection{章・節}
%
% \paragraph{構成要素}
%
% |\@startsection| マクロは6個の必須引数と,オプションとして |*| と
% 1個のオプション引数と1個の必須引数をとります。
%
% \begin{quote}
% |\@startsection{名}{レベル}{字下げ}{前アキ}{後アキ}{スタイル}| \\
% | *[別見出し]{見出し}|
% \end{quote}
%
% それぞれの引数の意味は次の通りです。
%
% \begin{description}
% \item[名] ユーザレベルコマンドの名前です(例: section)。
% \item[レベル] 見出しの深さを示す数値です
% (chapter=1, section=2, \ldots )。
% この数値が |secnumdepth| 以下のとき見出し番号を出力します。
% \item[字下げ] 見出しの字下げ量です。
% \item[前アキ] この値の絶対値が見出し上側の空きです。
% 負の場合は,見出し直後の段落をインデントしません。
% \item[後アキ] 正の場合は,見出しの下の空きです。
% 負の場合は,絶対値が見出しの右の空きです
% (見出しと同じ行から本文を始めます)。
% \item[スタイル] 見出しの文字スタイルの設定です。
% \item[\texttt{*}] この \texttt{*} 印がないと,見出し番号を付け,
% 見出し番号のカウンタに1を加算します。
% \item[別見出し] 目次や柱に出力する見出しです。
% \item[見出し] 見出しです。
% \end{description}
%
% 見出しの命令は通常 |\@startsection| とその最初の6個の引数として
% 定義されます。
%
% 次は |\@startsection| の定義です。
% 情報処理学会論文誌スタイルファイル(\texttt{ipsjcommon.sty})
% を参考にさせていただきましたが,完全に行送りが |\baselineskip|
% の整数倍にならなくてもいいから前の行と重ならないようにしました。
%
% \begin{macrocode}
\def\@startsection#1#2#3#4#5#6{%
\if@noskipsec \leavevmode \fi
\par
% 見出し上の空きを \@tempskipa にセットする
\@tempskipa #4\relax
% \@afterindent は見出し直後の段落を字下げするかどうかを表すスイッチ
\if@english \@afterindentfalse \else \@afterindenttrue \fi
% 見出し上の空きが負なら見出し直後の段落を字下げしない
\ifdim \@tempskipa <\z@
\@tempskipa -\@tempskipa \@afterindentfalse
\fi
\if@nobreak
% \everypar{\everyparhook}% これは間違い
\everypar{}%
\else
\addpenalty\@secpenalty
% 次の行は削除
% \addvspace\@tempskipa
% 次の \noindent まで追加
\ifdim \@tempskipa >\z@
\if@slide\else
\null
\vspace*{-\baselineskip}%
\fi
\vskip\@tempskipa
\fi
\fi
\noindent
% 追加終わり
\@ifstar
{\@ssect{#3}{#4}{#5}{#6}}%
{\@dblarg{\@sect{#1}{#2}{#3}{#4}{#5}{#6}}}}
% \end{macrocode}
%
% |\@sect| と |\@xsect| は,
% 前のアキがちょうどゼロの場合にもうまくいくように,多少変えてあります。
% |\everyparhook| も挿入しています。
%
% \begin{macrocode}
\def\@sect#1#2#3#4#5#6[#7]#8{%
\ifnum #2>\c@secnumdepth
\let\@svsec\@empty
\else
\refstepcounter{#1}%
\protected@edef\@svsec{\@seccntformat{#1}\relax}%
\fi
% 見出し後の空きを \@tempskipa にセット
\@tempskipa #5\relax
% 条件判断の順序を入れ換えました
\ifdim \@tempskipa<\z@
\def\@svsechd{%
#6{\hskip #3\relax
\@svsec #8}%
\csname #1mark\endcsname{#7}%
\addcontentsline{toc}{#1}{%
\ifnum #2>\c@secnumdepth \else
\protect\numberline{\csname the#1\endcsname}%
\fi
#7}}% 目次にフルネームを載せるなら #8
\else
\begingroup
\interlinepenalty \@M % 下から移動
#6{%
\@hangfrom{\hskip #3\relax\@svsec}%
% \interlinepenalty \@M % 上に移動
#8\@@par}%
\endgroup
\csname #1mark\endcsname{#7}%
\addcontentsline{toc}{#1}{%
\ifnum #2>\c@secnumdepth \else
\protect\numberline{\csname the#1\endcsname}%
\fi
#7}% 目次にフルネームを載せるならここは #8
\fi
\@xsect{#5}}
% \end{macrocode}
%
% 二つ挿入した |\everyparhook| のうち後者が |\paragraph| 類の後で2回実行され,
% それ以降は前者が実行されます。
%
% [2016-07-28] \texttt{slide}オプションと\texttt{twocolumn}オプションを
% 同時に指定した場合の罫線の位置を微調整しました。
%
% \begin{macrocode}
\def\@xsect#1{%
% 見出しの後ろの空きを \@tempskipa にセット
\@tempskipa #1\relax
% 条件判断の順序を変えました
\ifdim \@tempskipa<\z@
\@nobreakfalse
\global\@noskipsectrue
\everypar{%
\if@noskipsec
\global\@noskipsecfalse
{\setbox\z@\lastbox}%
\clubpenalty\@M
\begingroup \@svsechd \endgroup
\unskip
\@tempskipa #1\relax
\hskip -\@tempskipa
\else
\clubpenalty \@clubpenalty
\everypar{\everyparhook}%
\fi\everyparhook}%
\else
\par \nobreak
\vskip \@tempskipa
\@afterheading
\fi
\if@slide
{\vskip\if@twocolumn-5\jsc@mpt\else-6\jsc@mpt\fi
\maybeblue\hrule height0\jsc@mpt depth1\jsc@mpt
\vskip\if@twocolumn 4\jsc@mpt\else 7\jsc@mpt\fi\relax}%
\fi
\par % 2000-12-18
\ignorespaces}
\def\@ssect#1#2#3#4#5{%
\@tempskipa #3\relax
\ifdim \@tempskipa<\z@
\def\@svsechd{#4{\hskip #1\relax #5}}%
\else
\begingroup
#4{%
\@hangfrom{\hskip #1}%
\interlinepenalty \@M #5\@@par}%
\endgroup
\fi
\@xsect{#3}}
% \end{macrocode}
%
% \paragraph{柱関係の命令}
%
% \begin{macro}{\chaptermark}
% \begin{macro}{\sectionmark}
% \begin{macro}{\subsectionmark}
% \begin{macro}{\subsubsectionmark}
% \begin{macro}{\paragraphmark}
% \begin{macro}{\subparagraphmark}
%
% |\...mark| の形の命令を初期化します(第\ref{sec:pagestyle}節参照)。
% |\chaptermark| 以外は\LaTeX 本体で定義済みです。
%
% \begin{macrocode}
\newcommand*\chaptermark[1]{}
% \newcommand*{\sectionmark}[1]{}
% \newcommand*{\subsectionmark}[1]{}
% \newcommand*{\subsubsectionmark}[1]{}
% \newcommand*{\paragraphmark}[1]{}
% \newcommand*{\subparagraphmark}[1]{}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \paragraph{カウンタの定義}
%
% \begin{macro}{\c@secnumdepth}
%
% |secnumdepth| は第何レベルの見出しまで
% 番号を付けるかを決めるカウンタです。
%
% \begin{macrocode}
%<!book&!report>\setcounter{secnumdepth}{3}
%<book|report>\setcounter{secnumdepth}{2}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\c@chapter}
% \begin{macro}{\c@section}
% \begin{macro}{\c@subsection}
% \begin{macro}{\c@subsubsection}
% \begin{macro}{\c@paragraph}
% \begin{macro}{\c@subparagraph}
%
% 見出し番号のカウンタです。
% |\newcounter| の第1引数が新たに作るカウンタです。
% これは第2引数が増加するたびに 0 に戻されます。
% 第2引数は定義済みのカウンタです。
%
% \begin{macrocode}
\newcounter{part}
%<book|report>\newcounter{chapter}
%<book|report>\newcounter{section}[chapter]
%<!book&!report>\newcounter{section}
\newcounter{subsection}[section]
\newcounter{subsubsection}[subsection]
\newcounter{paragraph}[subsubsection]
\newcounter{subparagraph}[paragraph]
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\thepart}
% \begin{macro}{\thechapter}
% \begin{macro}{\thesection}
% \begin{macro}{\thesubsection}
% \begin{macro}{\thesubsubsection}
% \begin{macro}{\theparagraph}
% \begin{macro}{\thesubparagraph}
%
% カウンタの値を出力する命令 |\the何々| を定義します。
%
% カウンタを出力するコマンドには次のものがあります。
%
% \begin{quote}
% |\arabic{COUNTER} | 1, 2, 3, \ldots \\
% |\roman{COUNTER} | i, ii, iii, \ldots \\
% |\Roman{COUNTER} | I, II, III, \ldots \\
% |\alph{COUNTER} | a, b, c, \ldots \\
% |\Alph{COUNTER} | A, B, C, \ldots \\
% |\kansuji{COUNTER} | 一, 二, 三, \ldots
% \end{quote}
%
% 以下ではスペース節約のため |@| の付いた内部表現を多用しています。
%
% \begin{macrocode}
\renewcommand{\thepart}{\@Roman\c@part}
%<!book&!report>% \renewcommand{\thesection}{\@arabic\c@section}
%<!book&!report>\renewcommand{\thesection}{\presectionname\@arabic\c@section\postsectionname}
%<!book&!report>\renewcommand{\thesubsection}{\@arabic\c@section.\@arabic\c@subsection}
%<*book|report>
\renewcommand{\thechapter}{\@arabic\c@chapter}
\renewcommand{\thesection}{\thechapter.\@arabic\c@section}
\renewcommand{\thesubsection}{\thesection.\@arabic\c@subsection}
%</book|report>
\renewcommand{\thesubsubsection}{%
\thesubsection.\@arabic\c@subsubsection}
\renewcommand{\theparagraph}{%
\thesubsubsection.\@arabic\c@paragraph}
\renewcommand{\thesubparagraph}{%
\theparagraph.\@arabic\c@subparagraph}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@chapapp}
% \begin{macro}{\@chappos}
%
% |\@chapapp| の初期値は |\prechaptername|(第)です。
%
% |\@chappos| の初期値は |\postchaptername|(章)です。
%
% |\appendix| は |\@chapapp| を |\appendixname| に,
% |\@chappos| を空に再定義します。
%
% [2003-03-02] |\@secapp| は外しました。
%
% \begin{macrocode}
%<book|report>\newcommand{\@chapapp}{\prechaptername}
%<book|report>\newcommand{\@chappos}{\postchaptername}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \paragraph{前付,本文,後付}
%
% 本のうち章番号があるのが「本文」,
% それ以外が「前付」「後付」です。
%
% \begin{macro}{\frontmatter}
%
% ページ番号をローマ数字にし,章番号を付けないようにします。
%
% [2017-03-05] |\frontmatter| と |\mainmatter| の2つの命令は,
% 改丁または改ページした後で |\pagenumbering{...}| でノンブルを1に
% リセットします。長い間 |\frontmatter| は \texttt{openany} のときに
% 単なる改ページとしていましたが,これではノンブルをリセットする際に
% 偶奇逆転が起こる場合がありました。\texttt{openany} かどうかに依らず
% 奇数ページまで繰るように修正することで,問題を解消しました。
% 実は,\LaTeX の標準クラスでは1998年に修正されていた問題です
% (コミュニティ版\pLaTeX の標準クラス2017/03/05も参照)。
%
% \begin{macrocode}
%<*book>
\newcommand\frontmatter{%
\pltx@cleartooddpage
\@mainmatterfalse
\pagenumbering{roman}}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\mainmatter}
%
% ページ番号を算用数字にし,章番号を付けるようにします。
%
% \begin{macrocode}
\newcommand\mainmatter{%
\pltx@cleartooddpage
\@mainmattertrue
\pagenumbering{arabic}}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\backmatter}
%
% 章番号を付けないようにします。ページ番号の付け方は変わりません。
%
% \begin{macrocode}
\newcommand\backmatter{%
\if@openleft
\cleardoublepage
\else\if@openright
\cleardoublepage
\else
\clearpage
\fi\fi
\@mainmatterfalse}
%</book>
% \end{macrocode}
% \end{macro}
%
% \paragraph{部}
%
% \begin{macro}{\part}
%
% 新しい部を始めます。
%
% |\secdef| を使って見出しを定義しています。
% このマクロは二つの引数をとります。
%
% \begin{quote}
% |\secdef{星なし}{星あり}|
% \end{quote}
%
% \begin{description}
% \item[星なし] \texttt{*} のない形の定義です。
% \item[星あり] \texttt{*} のある形の定義です。
% \end{description}
%
% |\secdef| は次のようにして使います。
%
%\begin{verbatim}
% \def\chapter { ... \secdef \CMDA \CMDB }
% \def\CMDA [#1]#2{....} % \chapter[...]{...} の定義
% \def\CMDB #1{....} % \chapter*{...} の定義
%\end{verbatim}
%
% まず |book| と |report| のクラス以外です。
%
% \begin{macrocode}
%<*!book&!report>
\newcommand\part{%
\if@noskipsec \leavevmode \fi
\par
\addvspace{4ex}%
\if@english \@afterindentfalse \else \@afterindenttrue \fi
\secdef\@part\@spart}
%</!book&!report>
% \end{macrocode}
%
% |book| および |report| クラスの場合は,少し複雑です。
%
% \begin{macrocode}
%<*book|report>
\newcommand\part{%
\if@openleft
\cleardoublepage
\else\if@openright
\cleardoublepage
\else
\clearpage
\fi\fi
\thispagestyle{empty}% 欧文用標準スタイルでは plain
\if@twocolumn
\onecolumn
\@restonecoltrue
\else
\@restonecolfalse
\fi
\null\vfil
\secdef\@part\@spart}
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@part}
%
% 部の見出しを出力します。
% |\bfseries| を |\headfont| に変えました。
%
% |book| および |report| クラス以外では |secnumdepth| が $-1$ より大きいとき
% 部番号を付けます。
%
% \begin{macrocode}
%<*!book&!report>
\def\@part[#1]#2{%
\ifnum \c@secnumdepth >\m@ne
\refstepcounter{part}%
\addcontentsline{toc}{part}{%
\prepartname\thepart\postpartname\hspace{1zw}#1}%
\else
\addcontentsline{toc}{part}{#1}%
\fi
\markboth{}{}%
{\parindent\z@
\raggedright
\interlinepenalty \@M
\normalfont
\ifnum \c@secnumdepth >\m@ne
\Large\headfont\prepartname\thepart\postpartname
\par\nobreak
\fi
\huge \headfont #2%
\markboth{}{}\par}%
\nobreak
\vskip 3ex
\@afterheading}
%</!book&!report>
% \end{macrocode}
%
% |book| および |report| クラスでは |secnumdepth| が $-2$ より大きいとき部番号を付けます。
%
% \begin{macrocode}
%<*book|report>
\def\@part[#1]#2{%
\ifnum \c@secnumdepth >-2\relax
\refstepcounter{part}%
\addcontentsline{toc}{part}{%
\prepartname\thepart\postpartname\hspace{1zw}#1}%
\else
\addcontentsline{toc}{part}{#1}%
\fi
\markboth{}{}%
{\centering
\interlinepenalty \@M
\normalfont
\ifnum \c@secnumdepth >-2\relax
\huge\headfont \prepartname\thepart\postpartname
\par\vskip20\jsc@mpt
\fi
\Huge \headfont #2\par}%
\@endpart}
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@spart}
%
% 番号を付けない部です。
%
% \begin{macrocode}
%<*!book&!report>
\def\@spart#1{{%
\parindent \z@ \raggedright
\interlinepenalty \@M
\normalfont
\huge \headfont #1\par}%
\nobreak
\vskip 3ex
\@afterheading}
%</!book&!report>
%<*book|report>
\def\@spart#1{{%
\centering
\interlinepenalty \@M
\normalfont
\Huge \headfont #1\par}%
\@endpart}
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@endpart}
%
% |\@part| と |\@spart| の最後で実行されるマクロです。
% 両面印刷のときは白ページを追加します。
% 二段組のときには,二段組に戻します。
%
% [2016-12-13] \texttt{openany} のときには白ページが追加されるのは変なので,
% その場合は追加しないようにしました。このバグは\LaTeX では
% classes.dtx v1.4b (2000/05/19)
% で修正されています。
%
% \begin{macrocode}
%<*book|report>
\def\@endpart{\vfil\newpage
\if@twoside
\if@openleft %% added (2017/02/24)
\null\thispagestyle{empty}\newpage
\else\if@openright %% added (2016/12/13)
\null\thispagestyle{empty}\newpage
\fi\fi %% added (2016/12/13, 2017/02/24)
\fi
\if@restonecol
\twocolumn
\fi}
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \paragraph{章}
%
% \begin{macro}{\chapter}
%
% 章の最初のページスタイルは,全体が |empty| でなければ |plain| に
% します。
% また,|\@topnum| を 0 にして,
% 章見出しの上に図や表が来ないようにします。
%
% \begin{macrocode}
%<*book|report>
\newcommand{\chapter}{%
\if@openleft\cleardoublepage\else
\if@openright\cleardoublepage\else\clearpage\fi\fi
\plainifnotempty % 元: \thispagestyle{plain}
\global\@topnum\z@
\if@english \@afterindentfalse \else \@afterindenttrue \fi
\secdef
{\@omit@numberfalse\@chapter}%
{\@omit@numbertrue\@schapter}}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@chapter}
%
% 章見出しを出力します。
% |secnumdepth| が0以上かつ |\@mainmatter| が真のとき章番号を出力します。
%
% \begin{macrocode}
\def\@chapter[#1]#2{%
\ifnum \c@secnumdepth >\m@ne
%<book> \if@mainmatter
\refstepcounter{chapter}%
\typeout{\@chapapp\thechapter\@chappos}%
\addcontentsline{toc}{chapter}%
{\protect\numberline
% {\if@english\thechapter\else\@chapapp\thechapter\@chappos\fi}%
{\@chapapp\thechapter\@chappos}%
#1}%
%<book> \else\addcontentsline{toc}{chapter}{#1}\fi
\else
\addcontentsline{toc}{chapter}{#1}%
\fi
\chaptermark{#1}%
\addtocontents{lof}{\protect\addvspace{10\jsc@mpt}}%
\addtocontents{lot}{\protect\addvspace{10\jsc@mpt}}%
\if@twocolumn
\@topnewpage[\@makechapterhead{#2}]%
\else
\@makechapterhead{#2}%
\@afterheading
\fi}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@makechapterhead}
%
% 実際に章見出しを組み立てます。
% |\bfseries| を |\headfont| に変えました。
%
% \begin{macrocode}
\def\@makechapterhead#1{%
\vspace*{2\Cvs}% 欧文は50pt
{\parindent \z@ \raggedright \normalfont
\ifnum \c@secnumdepth >\m@ne
%<book> \if@mainmatter
\huge\headfont \@chapapp\thechapter\@chappos
\par\nobreak
\vskip \Cvs % 欧文は20pt
%<book> \fi
\fi
\interlinepenalty\@M
\Huge \headfont #1\par\nobreak
\vskip 3\Cvs}} % 欧文は40pt
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@schapter}
%
% |\chapter*{...}| コマンドの本体です。
% |\chaptermark| を補いました。
%
% \begin{macrocode}
\def\@schapter#1{%
\chaptermark{#1}%
\if@twocolumn
\@topnewpage[\@makeschapterhead{#1}]%
\else
\@makeschapterhead{#1}\@afterheading
\fi}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@makeschapterhead}
%
% 番号なしの章見出しです。
%
% \begin{macrocode}
\def\@makeschapterhead#1{%
\vspace*{2\Cvs}% 欧文は50pt
{\parindent \z@ \raggedright
\normalfont
\interlinepenalty\@M
\Huge \headfont #1\par\nobreak
\vskip 3\Cvs}} % 欧文は40pt
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \paragraph{下位レベルの見出し}
%
% \begin{macro}{\section}
%
% 欧文版では |\@startsection| の第4引数を負にして最初の段落の
% 字下げを禁止していますが,
% 和文版では正にして字下げするようにしています。
%
% 段組のときはなるべく左右の段が狂わないように工夫しています。
%
% \begin{macrocode}
\if@twocolumn
\newcommand{\section}{%
%<jspf>\ifx\maketitle\relax\else\maketitle\fi
\@startsection{section}{1}{\z@}%
%<!kiyou> {0.6\Cvs}{0.4\Cvs}%
%<kiyou> {\Cvs}{0.5\Cvs}%
% {\normalfont\large\headfont\@secapp}}
{\normalfont\large\headfont\raggedright}}
\else
\newcommand{\section}{%
\if@slide\clearpage\fi
\@startsection{section}{1}{\z@}%
{\Cvs \@plus.5\Cdp \@minus.2\Cdp}% 前アキ
{.5\Cvs \@plus.3\Cdp}% 後アキ
% {\normalfont\Large\headfont\@secapp}}
{\normalfont\Large\headfont\raggedright}}
\fi
% \end{macrocode}
%
% \end{macro}
%
% \begin{macro}{\subsection}
%
% 同上です。
%
% \begin{macrocode}
\if@twocolumn
\newcommand{\subsection}{\@startsection{subsection}{2}{\z@}%
{\z@}{\if@slide .4\Cvs \else \z@ \fi}%
{\normalfont\normalsize\headfont}}
\else
\newcommand{\subsection}{\@startsection{subsection}{2}{\z@}%
{\Cvs \@plus.5\Cdp \@minus.2\Cdp}% 前アキ
{.5\Cvs \@plus.3\Cdp}% 後アキ
{\normalfont\large\headfont}}
\fi
% \end{macrocode}
%
% \end{macro}
%
% \begin{macro}{\subsubsection}
%
% [2016-07-22] \texttt{slide}オプション指定時に |\subsubsection| の文字列
% と罫線が重なる問題に対処しました(forum:1982)。
%
% \begin{macrocode}
\if@twocolumn
\newcommand{\subsubsection}{\@startsection{subsubsection}{3}{\z@}%
{\z@}{\if@slide .4\Cvs \else \z@ \fi}%
{\normalfont\normalsize\headfont}}
\else
\newcommand{\subsubsection}{\@startsection{subsubsection}{3}{\z@}%
{\Cvs \@plus.5\Cdp \@minus.2\Cdp}%
{\if@slide .5\Cvs \@plus.3\Cdp \else \z@ \fi}%
{\normalfont\normalsize\headfont}}
\fi
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\paragraph}
% \begin{macro}{\jsParagraphMark}
%
% 見出しの後ろで改行されません。
%
% [2016-11-16] 従来は |\paragraph| の最初に出るマークを「■」に固定して
% いましたが,このマークを変更可能にするため |\jsParagraphMark| というマクロ
% に切り出しました。これで,たとえば
%\begin{verbatim}
% \renewcommand{\jsParagraphMark}{★}
%\end{verbatim}
% とすれば「★」に変更できますし,マークを空にすることも容易です。
% なお,某学会クラスでは従来どおりマークは付きません。
%
% \begin{macrocode}
%<!jspf>\newcommand{\jsParagraphMark}{■}
\if@twocolumn
\newcommand{\paragraph}{\@startsection{paragraph}{4}{\z@}%
{\z@}{\if@slide .4\Cvs \else -1zw\fi}% 改行せず 1zw のアキ
%<jspf> {\normalfont\normalsize\headfont}}
%<!jspf> {\normalfont\normalsize\headfont\jsParagraphMark}}
\else
\newcommand{\paragraph}{\@startsection{paragraph}{4}{\z@}%
{0.5\Cvs \@plus.5\Cdp \@minus.2\Cdp}%
{\if@slide .5\Cvs \@plus.3\Cdp \else -1zw\fi}% 改行せず 1zw のアキ
%<jspf> {\normalfont\normalsize\headfont}}
%<!jspf> {\normalfont\normalsize\headfont\jsParagraphMark}}
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\subparagraph}
%
% 見出しの後ろで改行されません。
%
% \begin{macrocode}
\if@twocolumn
\newcommand{\subparagraph}{\@startsection{subparagraph}{5}{\z@}%
{\z@}{\if@slide .4\Cvs \@plus.3\Cdp \else -1zw\fi}%
{\normalfont\normalsize\headfont}}
\else
\newcommand{\subparagraph}{\@startsection{subparagraph}{5}{\z@}%
{\z@}{\if@slide .5\Cvs \@plus.3\Cdp \else -1zw\fi}%
{\normalfont\normalsize\headfont}}
\fi
% \end{macrocode}
% \end{macro}
%
% \subsection{リスト環境}
%
% 第 $k$ レベルのリストの初期化をするのが |\@list|$k$ です
% ($k = \mathtt{i}, \mathtt{ii}, \mathtt{iii}, \mathtt{iv}$)。
% |\@list|$k$ は |\leftmargin| を |\leftmargin|$k$ に設定します。
%
% \begin{macro}{\leftmargini}
%
% 二段組であるかないかに応じてそれぞれ 2em,2.5em でしたが,
% ここでは全角幅の2倍にしました。
%
% [2002-05-11] 3zw に変更しました。
%
% [2005-03-19] 二段組は 2zw に戻しました。
%
% \begin{macrocode}
\if@slide
\setlength\leftmargini{1zw}
\else
\if@twocolumn
\setlength\leftmargini{2zw}
\else
\setlength\leftmargini{3zw}
\fi
\fi
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\leftmarginii}
% \begin{macro}{\leftmarginiii}
% \begin{macro}{\leftmarginiv}
% \begin{macro}{\leftmarginv}
% \begin{macro}{\leftmarginvi}
%
% |ii|,|iii|,|iv| は |\labelsep| と
% それぞれ `(m)',`vii.',`M.' の幅との和より大きくする
% ことになっています。ここでは全角幅の整数倍に丸めました。
%
% \begin{macrocode}
\if@slide
\setlength\leftmarginii {1zw}
\setlength\leftmarginiii{1zw}
\setlength\leftmarginiv {1zw}
\setlength\leftmarginv {1zw}
\setlength\leftmarginvi {1zw}
\else
\setlength\leftmarginii {2zw}
\setlength\leftmarginiii{2zw}
\setlength\leftmarginiv {2zw}
\setlength\leftmarginv {1zw}
\setlength\leftmarginvi {1zw}
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\labelsep}
% \begin{macro}{\labelwidth}
%
% |\labelsep| はラベルと本文の間の距離です。
% |\labelwidth| はラベルの幅です。
% これは二分に変えました。
%
% \begin{macrocode}
\setlength \labelsep {0.5zw} % .5em
\setlength \labelwidth{\leftmargini}
\addtolength\labelwidth{-\labelsep}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\partopsep}
%
% リスト環境の前に空行がある場合,
% |\parskip| と |\topsep| に |\partopsep| を
% 加えた値だけ縦方向の空白ができます。
% 0 に改変しました。
%
% \begin{macrocode}
\setlength\partopsep{\z@} % {2\p@ \@plus 1\p@ \@minus 1\p@}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@beginparpenalty}
% \begin{macro}{\@endparpenalty}
% \begin{macro}{\@itempenalty}
%
% リストや段落環境の前後,リスト項目間に挿入されるペナルティです。
%
% \begin{macrocode}
\@beginparpenalty -\@lowpenalty
\@endparpenalty -\@lowpenalty
\@itempenalty -\@lowpenalty
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@listi}
% \begin{macro}{\@listI}
%
% |\@listi| は |\leftmargin|,|\parsep|,|\topsep|,|\itemsep| などの
% トップレベルの定義をします。
% この定義は,フォントサイズコマンドによって変更されます
% (たとえば |\small| の中では小さい値に設定されます)。
% このため,|\normalsize| がすべてのパラメータを戻せるように,
% |\@listI| で |\@listi| のコピーを保存します。
% 元の値はかなり複雑ですが,ここでは簡素化してしまいました。
% 特に最初と最後に行送りの半分の空きが入るようにしてあります。
% アスキーの標準スタイルでは
% トップレベルの |itemize|,|enumerate| 環境でだけ
% 最初と最後に行送りの半分の空きが入るようになっていました。
%
% [2004-09-27] |\topsep| のグルー $_{-0.1}^{+0.2}$ |\baselineskip|
% を思い切って外しました。
%
% \begin{macrocode}
\def\@listi{\leftmargin\leftmargini
\parsep \z@
\topsep 0.5\baselineskip
\itemsep \z@ \relax}
\let\@listI\@listi
% \end{macrocode}
%
% 念のためパラメータを初期化します(実際には不要のようです)。
%
% \begin{macrocode}
\@listi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@listii}
% \begin{macro}{\@listiii}
% \begin{macro}{\@listiv}
% \begin{macro}{\@listv}
% \begin{macro}{\@listvi}
%
% 第2〜6レベルのリスト環境のパラメータの設定です。
%
% \begin{macrocode}
\def\@listii{\leftmargin\leftmarginii
\labelwidth\leftmarginii \advance\labelwidth-\labelsep
\topsep \z@
\parsep \z@
\itemsep\parsep}
\def\@listiii{\leftmargin\leftmarginiii
\labelwidth\leftmarginiii \advance\labelwidth-\labelsep
\topsep \z@
\parsep \z@
\itemsep\parsep}
\def\@listiv {\leftmargin\leftmarginiv
\labelwidth\leftmarginiv
\advance\labelwidth-\labelsep}
\def\@listv {\leftmargin\leftmarginv
\labelwidth\leftmarginv
\advance\labelwidth-\labelsep}
\def\@listvi {\leftmargin\leftmarginvi
\labelwidth\leftmarginvi
\advance\labelwidth-\labelsep}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \paragraph{enumerate環境}
%
% |enumerate| 環境はカウンタ |enumi|,|enumii|,|enumiii|,
% |enumiv| を使います。|enum|$n$ は第 $n$ レベルの番号です。
%
% \begin{macro}{\theenumi}
% \begin{macro}{\theenumii}
% \begin{macro}{\theenumiii}
% \begin{macro}{\theenumiv}
%
% 出力する番号の書式を設定します。
% これらは\LaTeX 本体(\texttt{ltlists.dtx} 参照)で定義済みですが,
% ここでは表し方を変えています。
% |\@arabic|,|\@alph|,|\@roman|,|\@Alph| はそれぞれ
% 算用数字,小文字アルファベット,小文字ローマ数字,大文字アルファベット
% で番号を出力する命令です。
%
% \begin{macrocode}
\renewcommand{\theenumi}{\@arabic\c@enumi}
\renewcommand{\theenumii}{\@alph\c@enumii}
\renewcommand{\theenumiii}{\@roman\c@enumiii}
\renewcommand{\theenumiv}{\@Alph\c@enumiv}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\labelenumi}
% \begin{macro}{\labelenumii}
% \begin{macro}{\labelenumiii}
% \begin{macro}{\labelenumiv}
%
% |enumerate| 環境の番号を出力する命令です。
% 第2レベル以外は最後に欧文のピリオドが付きますが,
% これは好みに応じて取り払ってください。
% 第2レベルの番号のかっこは和文用に換え,
% その両側に入る余分なグルーを |\inhibitglue| で
% 取り除いています。
%
% \begin{macrocode}
\newcommand{\labelenumi}{\theenumi.}
\newcommand{\labelenumii}{\inhibitglue (\theenumii )\inhibitglue}
\newcommand{\labelenumiii}{\theenumiii.}
\newcommand{\labelenumiv}{\theenumiv.}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\p@enumii}
% \begin{macro}{\p@enumiii}
% \begin{macro}{\p@enumiv}
%
% |\p@enum|$n$ は |\ref| コマンドで |enumerate| 環境の第 $n$ レベルの
% 項目が参照されるときの書式です。
% これも第2レベルは和文用かっこにしました。
%
% \begin{macrocode}
\renewcommand{\p@enumii}{\theenumi}
\renewcommand{\p@enumiii}{\theenumi\inhibitglue (\theenumii )}
\renewcommand{\p@enumiv}{\p@enumiii\theenumiii}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \paragraph{itemize環境}
%
% \begin{macro}{\labelitemi}
% \begin{macro}{\labelitemii}
% \begin{macro}{\labelitemiii}
% \begin{macro}{\labelitemiv}
% |itemize| 環境の第 $n$ レベルのラベルを作るコマンドです。
% \begin{macrocode}
\newcommand\labelitemi{\textbullet}
\newcommand\labelitemii{\normalfont\bfseries \textendash}
\newcommand\labelitemiii{\textasteriskcentered}
\newcommand\labelitemiv{\textperiodcentered}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \paragraph{description環境}
%
% \begin{environment}{description}
%
% 本来の |description| 環境では,項目名が短いと,説明部分の頭が
% それに引きずられて左に出てしまいます。
% これを解決した新しい |description| の実装です。
%
% \begin{macrocode}
\newenvironment{description}{%
\list{}{%
\labelwidth=\leftmargin
\labelsep=1zw
\advance \labelwidth by -\labelsep
\let \makelabel=\descriptionlabel}}{\endlist}
% \end{macrocode}
% \end{environment}
%
% \begin{macro}{\descriptionlabel}
%
% |description| 環境のラベルを出力するコマンドです。
% 好みに応じて |#1| の前に適当な空き
% (たとえば |\hspace{1zw}|)を入れるのもいいと思います。
%
% \begin{macrocode}
\newcommand*\descriptionlabel[1]{\normalfont\headfont #1\hfil}
% \end{macrocode}
% \end{macro}
%
% \paragraph{概要}
%
% \begin{environment}{abstract}
%
% 概要(要旨,梗概)を出力する環境です。
% |book| クラスでは各章の初めにちょっとしたことを書くのに使います。
% |titlepage| オプション付きの |article| クラスでは,
% 独立したページに出力されます。
% |abstract| 環境は元は |quotation| 環境で作られていましたが,
% |quotation| 環境の右マージンをゼロにしたので,
% |list| 環境で作り直しました。
%
% JSPFスタイルでは実際の出力は |\maketitle| で行われます。
%
% \begin{macrocode}
%<*book>
\newenvironment{abstract}{%
\begin{list}{}{%
\listparindent=1zw
\itemindent=\listparindent
\rightmargin=0pt
\leftmargin=5zw}\item[]}{\end{list}\vspace{\baselineskip}}
%</book>
%<*article|report|kiyou>
\newbox\@abstractbox
\if@titlepage
\newenvironment{abstract}{%
\titlepage
\null\vfil
\@beginparpenalty\@lowpenalty
\begin{center}%
\headfont \abstractname
\@endparpenalty\@M
\end{center}}%
{\par\vfil\null\endtitlepage}
\else
\newenvironment{abstract}{%
\if@twocolumn
\ifx\maketitle\relax
\section*{\abstractname}%
\else
\global\setbox\@abstractbox\hbox\bgroup
\begin{minipage}[b]{\textwidth}
\small\parindent1zw
\begin{center}%
{\headfont \abstractname\vspace{-.5em}\vspace{\z@}}%
\end{center}%
\list{}{%
\listparindent\parindent
\itemindent \listparindent
\rightmargin \leftmargin}%
\item\relax
\fi
\else
\small
\begin{center}%
{\headfont \abstractname\vspace{-.5em}\vspace{\z@}}%
\end{center}%
\list{}{%
\listparindent\parindent
\itemindent \listparindent
\rightmargin \leftmargin}%
\item\relax
\fi}{\if@twocolumn
\ifx\maketitle\relax
\else
\endlist\end{minipage}\egroup
\fi
\else
\endlist
\fi}
\fi
%</article|report|kiyou>
%<*jspf>
\newbox\@abstractbox
\newenvironment{abstract}{%
\global\setbox\@abstractbox\hbox\bgroup
\begin{minipage}[b]{157\jsc@mmm}{\sffamily Abstract}\par
\small
\if@english \parindent6\jsc@mmm \else \parindent1zw \fi}%
{\end{minipage}\egroup}
%</jspf>
% \end{macrocode}
% \end{environment}
%
% \paragraph{キーワード}
%
% \begin{environment}{keywords}
%
% キーワードを準備する環境です。
% 実際の出力は |\maketitle| で行われます。
%
% \begin{macrocode}
%<*jspf>
%\newbox\@keywordsbox
%\newenvironment{keywords}{%
% \global\setbox\@keywordsbox\hbox\bgroup
% \begin{minipage}[b]{1570\jsc@mmm}{\sffamily Keywords:}\par
% \small\parindent0zw}%
% {\end{minipage}\egroup}
%</jspf>
% \end{macrocode}
% \end{environment}
%
% \paragraph{verse環境}
%
% \begin{environment}{verse}
%
% 詩のための |verse| 環境です。
%
% \begin{macrocode}
\newenvironment{verse}{%
\let \\=\@centercr
\list{}{%
\itemsep \z@
\itemindent -2zw % 元: -1.5em
\listparindent\itemindent
\rightmargin \z@
\advance\leftmargin 2zw}% 元: 1.5em
\item\relax}{\endlist}
% \end{macrocode}
% \end{environment}
%
% \paragraph{quotation環境}
%
% \begin{environment}{quotation}
%
% 段落の頭の字下げ量を1.5emから |\parindent| に変えました。
% また,右マージンを 0 にしました。
%
% \begin{macrocode}
\newenvironment{quotation}{%
\list{}{%
\listparindent\parindent
\itemindent\listparindent
\rightmargin \z@}%
\item\relax}{\endlist}
% \end{macrocode}
% \end{environment}
%
% \paragraph{quote環境}
%
% \begin{environment}{quote}
%
% |quote| 環境は,段落がインデントされないことを除き,
% |quotation| 環境と同じです。
%
% \begin{macrocode}
\newenvironment{quote}%
{\list{}{\rightmargin\z@}\item\relax}{\endlist}
% \end{macrocode}
% \end{environment}
%
% \paragraph{定理など}
%
% |ltthm.dtx| 参照。たとえば次のように定義します。
%\begin{verbatim}
% \newtheorem{definition}{定義}
% \newtheorem{axiom}{公理}
% \newtheorem{theorem}{定理}
%\end{verbatim}
%
% [2001-04-26] 定理の中はイタリック体になりましたが,
% これでは和文がゴシック体になってしまうので,
% |\itshape| を削除しました。
%
% [2009-08-23] |\bfseries| を |\headfont| に直し,
% |\labelsep| を 1\,zw にし,括弧を全角にしました。
%
% \begin{macrocode}
\def\@begintheorem#1#2{\trivlist\labelsep=1zw
\item[\hskip \labelsep{\headfont #1\ #2}]}
\def\@opargbegintheorem#1#2#3{\trivlist\labelsep=1zw
\item[\hskip \labelsep{\headfont #1\ #2(#3)}]}
% \end{macrocode}
%
% \begin{environment}{titlepage}
%
% タイトルを独立のページに出力するのに使われます。
%
% [2017-02-24] コミュニティ版\pLaTeX の標準クラス2017/02/15に合わせて,
% bookクラスでタイトルを必ず奇数ページに送るようにしました。といっても,
% 横組クラスしかありませんでしたので,従来の挙動は何も変わっていません。
% また,book以外の場合のページ番号のリセットもコミュニティ版\pLaTeX の
% 標準クラス2017/02/15に合わせましたが,こちらも片面印刷あるいは
% 独立のタイトルページを作らないクラスばかりでしたので,従来の挙動は
% 何も変わらずに済みました。
%
% \begin{macrocode}
\newenvironment{titlepage}{%
%<book> \pltx@cleartooddpage %% 2017-02-24
\if@twocolumn
\@restonecoltrue\onecolumn
\else
\@restonecolfalse\newpage
\fi
\thispagestyle{empty}%
\ifodd\c@page\setcounter{page}\@ne\else\setcounter{page}\z@\fi %% 2017-02-24
}%
{\if@restonecol\twocolumn \else \newpage \fi
\if@twoside\else
\setcounter{page}\@ne
\fi}
% \end{macrocode}
% \end{environment}
%
% \paragraph{付録}
%
% \begin{macro}{\appendix}
%
% 本文と付録を分離するコマンドです。
%
% \begin{macrocode}
%<*!book&!report>
\newcommand{\appendix}{\par
\setcounter{section}{0}%
\setcounter{subsection}{0}%
\gdef\presectionname{\appendixname}%
\gdef\postsectionname{}%
% \gdef\thesection{\@Alph\c@section}% [2003-03-02]
\gdef\thesection{\presectionname\@Alph\c@section\postsectionname}%
\gdef\thesubsection{\@Alph\c@section.\@arabic\c@subsection}}
%</!book&!report>
%<*book|report>
\newcommand{\appendix}{\par
\setcounter{chapter}{0}%
\setcounter{section}{0}%
\gdef\@chapapp{\appendixname}%
\gdef\@chappos{}%
\gdef\thechapter{\@Alph\c@chapter}}
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \subsection{パラメータの設定}
%
% \paragraph{arrayとtabular環境}
%
% \begin{macro}{\arraycolsep}
%
% |array| 環境の列間には |\arraycolsep| の2倍の幅の空きが入ります。
%
% \begin{macrocode}
\setlength\arraycolsep{5\jsc@mpt}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\tabcolsep}
%
% |tabular| 環境の列間には |\tabcolsep| の2倍の幅の空きが入ります。
%
% \begin{macrocode}
\setlength\tabcolsep{6\jsc@mpt}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\arrayrulewidth}
%
% |array|,|tabular| 環境内の罫線の幅です。
%
% \begin{macrocode}
\setlength\arrayrulewidth{.4\jsc@mpt}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\doublerulesep}
%
% |array|,|tabular| 環境での二重罫線間のアキです。
%
% \begin{macrocode}
\setlength\doublerulesep{2\jsc@mpt}
% \end{macrocode}
% \end{macro}
%
% \paragraph{tabbing環境}
%
% \begin{macro}{\tabbingsep}
%
% |\'| コマンドで入るアキです。
%
% \begin{macrocode}
\setlength\tabbingsep{\labelsep}
% \end{macrocode}
% \end{macro}
%
% \paragraph{minipage環境}
%
% \begin{macro}{\@mpfootins}
%
% |minipage| 環境の脚注の |\skip|\hspace{0pt}|\@mpfootins|
% は通常のページの |\skip|\hspace{0pt}|\footins|
% と同じ働きをします。
%
% \begin{macrocode}
\skip\@mpfootins = \skip\footins
% \end{macrocode}
% \end{macro}
%
% \paragraph{framebox環境}
%
% \begin{macro}{\fboxsep}
%
% |\fbox|,|\framebox| で内側のテキストと枠との間の空きです。
%
% \begin{macro}{\fboxrule}
%
% |\fbox|,|\framebox| の罫線の幅です。
%
% \begin{macrocode}
\setlength\fboxsep{3\jsc@mpt}
\setlength\fboxrule{.4\jsc@mpt}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \paragraph{equationとeqnarray環境}
%
% \begin{macro}{\theequation}
%
% 数式番号を出力するコマンドです。
%
% \begin{macrocode}
%<!book&!report>\renewcommand \theequation {\@arabic\c@equation}
%<*book|report>
\@addtoreset{equation}{chapter}
\renewcommand\theequation
{\ifnum \c@chapter>\z@ \thechapter.\fi \@arabic\c@equation}
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\jot}
%
% |eqnarray| の行間に余分に入るアキです。
% デフォルトの値をコメントアウトして示しておきます。
%
% \begin{macrocode}
% \setlength\jot{3pt}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@eqnnum}
%
% 数式番号の形式です。
% デフォルトの値をコメントアウトして示しておきます。
%
% |\inhibitglue (\theequation )\inhibitglue| のように和文かっこ
% を使うことも可能です。
%
% \begin{macrocode}
% \def\@eqnnum{(\theequation)}
% \end{macrocode}
% \end{macro}
%
% |amsmath| パッケージを使う場合は |\tagform@| を次のように修正します。
%
% \begin{macrocode}
% \def\tagform@#1{\maketag@@@{(\ignorespaces#1\unskip\@@italiccorr )}}
% \end{macrocode}
%
% \subsection{フロート}
%
% タイプ \texttt{TYPE} のフロートオブジェクトを
% 扱うには,次のマクロを定義します。
% \begin{description}
% \item[\texttt{\bslash fps@TYPE}]
% フロートを置く位置(float placement specifier)です。
% \item[\texttt{\bslash ftype@TYPE}]
% フロートの番号です。2の累乗(1,2,4,\ldots )でなければなりません。
% \item[\texttt{\bslash ext@TYPE}]
% フロートの目次を出力するファイルの拡張子です。
% \item[\texttt{\bslash fnum@TYPE}]
% キャプション用の番号を生成するマクロです。
% \item[\texttt{\bslash @makecaption}{\meta{num}}{\meta{text}}]
% キャプションを出力するマクロです。
% \meta{num} は |\fnum@...| の生成する番号,
% \meta{text} はキャプションのテキストです。
% テキストは適当な幅の |\parbox| に入ります。
% \end{description}
%
% \paragraph{figure環境}
%
% \begin{macro}{\c@figure}
%
% 図番号のカウンタです。
%
% \begin{macro}{\thefigure}
%
% 図番号を出力するコマンドです。
%
% \begin{macrocode}
%<*!book&!report>
\newcounter{figure}
\renewcommand \thefigure {\@arabic\c@figure}
%</!book&!report>
%<*book|report>
\newcounter{figure}[chapter]
\renewcommand \thefigure
{\ifnum \c@chapter>\z@ \thechapter.\fi \@arabic\c@figure}
%</book|report>
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\fps@figure}
% \begin{macro}{\ftype@figure}
% \begin{macro}{\ext@figure}
% \begin{macro}{\fnum@figure}
%
% |figure| のパラメータです。
% |\figurename| の直後に |~| が入っていましたが,
% ここでは外しました。
%
% \begin{macrocode}
\def\fps@figure{tbp}
\def\ftype@figure{1}
\def\ext@figure{lof}
\def\fnum@figure{\figurename\nobreak\thefigure}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{environment}{figure}
% \begin{environment}{figure*}
%
% |*| 形式は段抜きのフロートです。
%
% \begin{macrocode}
\newenvironment{figure}%
{\@float{figure}}%
{\end@float}
\newenvironment{figure*}%
{\@dblfloat{figure}}%
{\end@dblfloat}
% \end{macrocode}
% \end{environment}
% \end{environment}
%
% \paragraph{table環境}
%
% \begin{macro}{\c@table}
% \begin{macro}{\thetable}
%
% 表番号カウンタと表番号を出力するコマンドです。
% アスキー版では |\thechapter.| が |\thechapter{}・| になっていますが,
% ここではオリジナルのままにしています。
%
% \begin{macrocode}
%<*!book&!report>
\newcounter{table}
\renewcommand\thetable{\@arabic\c@table}
%</!book&!report>
%<*book|report>
\newcounter{table}[chapter]
\renewcommand \thetable
{\ifnum \c@chapter>\z@ \thechapter.\fi \@arabic\c@table}
%</book|report>
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\fps@table}
% \begin{macro}{\ftype@table}
% \begin{macro}{\ext@table}
% \begin{macro}{\fnum@table}
%
% |table| のパラメータです。
% |\tablename| の直後に |~| が入っていましたが,
% ここでは外しました。
%
% \begin{macrocode}
\def\fps@table{tbp}
\def\ftype@table{2}
\def\ext@table{lot}
\def\fnum@table{\tablename\nobreak\thetable}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{environment}{table}
% \begin{environment}{table*}
%
% |*| は段抜きのフロートです。
%
% \begin{macrocode}
\newenvironment{table}%
{\@float{table}}%
{\end@float}
\newenvironment{table*}%
{\@dblfloat{table}}%
{\end@dblfloat}
% \end{macrocode}
% \end{environment}
% \end{environment}
%
% \subsection{キャプション}
%
% \begin{macro}{\@makecaption}
%
% |\caption| コマンドにより呼び出され,
% 実際にキャプションを出力するコマンドです。
% 第1引数はフロートの番号,
% 第2引数はテキストです。
%
% \begin{macro}{\abovecaptionskip}
% \begin{macro}{\belowcaptionskip}
%
% それぞれキャプションの前後に挿入されるスペースです。
% |\belowcaptionskip| が0になっていましたので,
% キャプションを表の上につけた場合にキャプションと表が
% くっついてしまうのを直しました。
%
% \begin{macrocode}
\newlength\abovecaptionskip
\newlength\belowcaptionskip
\setlength\abovecaptionskip{5\jsc@mpt} % 元: 10\p@
\setlength\belowcaptionskip{5\jsc@mpt} % 元: 0\p@
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% 実際のキャプションを出力します。
% オリジナルと異なり,文字サイズを |\small| にし,
% キャプションの幅を2cm狭くしました。
%
% [2003-11-05] ロジックを少し変えてみました。
%
% [2018-12-11] 遅くなりましたが,|listings| パッケージを使うときに
% |title| を指定すると ``1zw'' が出力されてしまう
% 問題 (forum:1543,Issue \#71) に対処しました。
%
% \begin{macrocode}
%<*!jspf>
% \long\def\@makecaption#1#2{{\small
% \advance\leftskip10\jsc@mmm
% \advance\rightskip10\jsc@mmm
% \vskip\abovecaptionskip
% \sbox\@tempboxa{#1\hskip1zw\relax #2}%
% \ifdim \wd\@tempboxa >\hsize
% #1\hskip1zw\relax #2\par
% \else
% \global \@minipagefalse
% \hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%
% \fi
% \vskip\belowcaptionskip}}
\long\def\@makecaption#1#2{{\small
\advance\leftskip .0628\linewidth
\advance\rightskip .0628\linewidth
\vskip\abovecaptionskip
\sbox\@tempboxa{#1\hskip1zw\relax #2}%
\ifdim \wd\@tempboxa <\hsize \centering \fi
#1{\hskip1zw\relax}#2\par
\vskip\belowcaptionskip}}
%</!jspf>
%<*jspf>
\long\def\@makecaption#1#2{%
\vskip\abovecaptionskip
\sbox\@tempboxa{\small\sffamily #1\quad #2}%
\ifdim \wd\@tempboxa >\hsize
{\small\sffamily
\list{#1}{%
\renewcommand{\makelabel}[1]{##1\hfil}
\itemsep \z@
\itemindent \z@
\labelsep \z@
\labelwidth 11\jsc@mmm
\listparindent\z@
\leftmargin 11\jsc@mmm}\item\relax #2\endlist}
\else
\global \@minipagefalse
\hb@xt@\hsize{\hfil\box\@tempboxa\hfil}%
\fi
\vskip\belowcaptionskip}
%</jspf>
% \end{macrocode}
% \end{macro}
%
% \section{フォントコマンド}
%
% ここでは\LaTeX~2.09で使われていたコマンドを定義します。
% これらはテキストモードと数式モードのどちらでも動作します。
% これらは互換性のためのもので,
% できるだけ |\text...| と |\math...| を使ってください。
%
% \begin{macro}{\mc}
% \begin{macro}{\gt}
% \begin{macro}{\rm}
% \begin{macro}{\sf}
% \begin{macro}{\tt}
%
% フォントファミリを変更します。
%
% \begin{macrocode}
\DeclareOldFontCommand{\mc}{\normalfont\mcfamily}{\mathmc}
\DeclareOldFontCommand{\gt}{\normalfont\gtfamily}{\mathgt}
\DeclareOldFontCommand{\rm}{\normalfont\rmfamily}{\mathrm}
\DeclareOldFontCommand{\sf}{\normalfont\sffamily}{\mathsf}
\DeclareOldFontCommand{\tt}{\normalfont\ttfamily}{\mathtt}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\bf}
%
% ボールドシリーズにします。通常のミーディアムシリーズに戻す
% コマンドは |\mdseries| です。
%
% \begin{macrocode}
\DeclareOldFontCommand{\bf}{\normalfont\bfseries}{\mathbf}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\it}
% \begin{macro}{\sl}
% \begin{macro}{\sc}
%
% フォントシェイプを変えるコマンドです。
% 斜体とスモールキャップスは数式中では何もしません
% (警告メッセージを出力します)。
% 通常のアップライト体に戻すコマンドは |\upshape| です。
%
% \begin{macrocode}
\DeclareOldFontCommand{\it}{\normalfont\itshape}{\mathit}
\DeclareOldFontCommand{\sl}{\normalfont\slshape}{\@nomath\sl}
\DeclareOldFontCommand{\sc}{\normalfont\scshape}{\@nomath\sc}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\cal}
% \begin{macro}{\mit}
%
% 数式モード以外では何もしません(警告を出します)。
%
% \begin{macrocode}
\DeclareRobustCommand*{\cal}{\@fontswitch\relax\mathcal}
\DeclareRobustCommand*{\mit}{\@fontswitch\relax\mathnormal}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \section{相互参照}
%
% \subsection{目次の類}
%
% |\section| コマンドは |.toc| ファイルに次のような行を出力します。
% \begin{quote}
% |\contentsline{section}{タイトル}{ページ}|
% \end{quote}
% たとえば |\section| に見出し番号が付く場合,上の「タイトル」は
% \begin{quote}
% |\numberline{番号}{見出し}|
% \end{quote}
% となります。
% この「番号」は |\thesection| コマンドで生成された見出し番号です。
%
% |figure| 環境の |\caption| コマンドは |.lof| ファイルに
% 次のような行を出力します。
% \begin{quote}
% |\contentsline{figure}{\numberline{番号}{キャプション}{ページ}|
% \end{quote}
% この「番号」は |\thefigure| コマンドで生成された図番号です。
%
% |table| 環境も同様です。
%
% |\contentsline{...}| は |\l@...| というコマンドを実行するので,
% あらかじめ |\l@chapter|,|\l@section|,|\l@figure| などを
% 定義しておかなければなりません。
% これらの多くは |\@dottedtocline| コマンドを使って定義します。
% これは
% \begin{quote}
% |\@dottedtocline{レベル}{インデント}{幅}{タイトル}{ページ}|
% \end{quote}
% という書式です。
% \begin{description}
% \item[レベル] この値が |tocdepth| 以下のときだけ出力されます。
% |\chapter| はレベル0,|\section| はレベル1,等々です。
% \item[インデント] 左側の字下げ量です。
% \item[幅] 「タイトル」に |\numberline| コマンドが含まれる場合,
% 節番号が入る箱の幅です。
% \end{description}
%
% \begin{macro}{\@pnumwidth}
%
% ページ番号の入る箱の幅です。
%
% \begin{macro}{\@tocrmarg}
%
% 右マージンです。
% |\@tocrmarg| $\ge$ |\@pnumwidth| とします。
%
% \begin{macro}{\@dotsep}
%
% 点の間隔です(単位 mu)。
%
% \begin{macro}{\c@tocdepth}
%
% 目次ページに出力する見出しレベルです。
% 元は \texttt{article} で3,その他で2でしたが,
% ここでは一つずつ減らしています。
%
% \begin{macrocode}
\newcommand\@pnumwidth{1.55em}
\newcommand\@tocrmarg{2.55em}
\newcommand\@dotsep{4.5}
%<!book&!report>\setcounter{tocdepth}{2}
%<book|report>\setcounter{tocdepth}{1}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \paragraph{目次}
%
% \begin{macro}{\tableofcontents}
%
% 目次を生成します。
%
% \begin{macro}{\jsc@tocl@width}
%
% [2013-12-30] |\prechaptername| などから見積もった目次のラベルの長さです。(by ts)
%
% \begin{macrocode}
\newdimen\jsc@tocl@width
\newcommand{\tableofcontents}{%
%<*book|report>
\settowidth\jsc@tocl@width{\headfont\prechaptername\postchaptername}%
\settowidth\@tempdima{\headfont\appendixname}%
\ifdim\jsc@tocl@width<\@tempdima \setlength\jsc@tocl@width{\@tempdima}\fi
\ifdim\jsc@tocl@width<2zw \divide\jsc@tocl@width by 2 \advance\jsc@tocl@width 1zw\fi
\if@twocolumn
\@restonecoltrue\onecolumn
\else
\@restonecolfalse
\fi
\chapter*{\contentsname}%
\@mkboth{\contentsname}{}%
%</book|report>
%<*!book&!report>
\settowidth\jsc@tocl@width{\headfont\presectionname\postsectionname}%
\settowidth\@tempdima{\headfont\appendixname}%
\ifdim\jsc@tocl@width<\@tempdima\relax\setlength\jsc@tocl@width{\@tempdima}\fi
\ifdim\jsc@tocl@width<2zw \divide\jsc@tocl@width by 2 \advance\jsc@tocl@width 1zw\fi
\section*{\contentsname}%
\@mkboth{\contentsname}{\contentsname}%
%</!book&!report>
\@starttoc{toc}%
%<book|report> \if@restonecol\twocolumn\fi
}
% \end{macrocode}
% \end{macro}\end{macro}
%
% \begin{macro}{\l@part}
%
% 部の目次です。
%
% \begin{macrocode}
\newcommand*{\l@part}[2]{%
\ifnum \c@tocdepth >-2\relax
%<!book&!report> \addpenalty\@secpenalty
%<book|report> \addpenalty{-\@highpenalty}%
\addvspace{2.25em \@plus\jsc@mpt}%
\begingroup
\parindent \z@
% \@pnumwidth should be \@tocrmarg
% \rightskip \@pnumwidth
\rightskip \@tocrmarg
\parfillskip -\rightskip
{\leavevmode
\large \headfont
\setlength\@lnumwidth{4zw}%
#1\hfil \hb@xt@\@pnumwidth{\hss #2}}\par
\nobreak
%<book|report> \global\@nobreaktrue
%<book|report> \everypar{\global\@nobreakfalse\everypar{}}%
\endgroup
\fi}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\l@chapter}
%
% 章の目次です。|\@lnumwidth| を4.683zwに増やしました。
%
% [2013-12-30] |\@lnumwidth| を |\jsc@tocl@width| から
% 決めるようにしてみました。(by ts)
%
% \begin{macrocode}
%<*book|report>
\newcommand*{\l@chapter}[2]{%
\ifnum \c@tocdepth >\m@ne
\addpenalty{-\@highpenalty}%
\addvspace{1.0em \@plus\jsc@mpt}
% \vskip 1.0em \@plus\p@ % book.clsでは↑がこうなっている
\begingroup
\parindent\z@
% \rightskip\@pnumwidth
\rightskip\@tocrmarg
\parfillskip-\rightskip
\leavevmode\headfont
% \if@english\setlength\@lnumwidth{5.5em}\else\setlength\@lnumwidth{4.683zw}\fi
\setlength\@lnumwidth{\jsc@tocl@width}\advance\@lnumwidth 2.683zw
\advance\leftskip\@lnumwidth \hskip-\leftskip
#1\nobreak\hfil\nobreak\hbox to\@pnumwidth{\hss#2}\par
\penalty\@highpenalty
\endgroup
\fi}
%</book|report>
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\l@section}
%
% 節の目次です。
%
% \begin{macrocode}
%<*!book&!report>
\newcommand*{\l@section}[2]{%
\ifnum \c@tocdepth >\z@
\addpenalty{\@secpenalty}%
\addvspace{1.0em \@plus\jsc@mpt}%
\begingroup
\parindent\z@
% \rightskip\@pnumwidth
\rightskip\@tocrmarg
\parfillskip-\rightskip
\leavevmode\headfont
%\setlength\@lnumwidth{4zw}% 元1.5em [2003-03-02]
\setlength\@lnumwidth{\jsc@tocl@width}\advance\@lnumwidth 2zw
\advance\leftskip\@lnumwidth \hskip-\leftskip
#1\nobreak\hfil\nobreak\hbox to\@pnumwidth{\hss#2}\par
\endgroup
\fi}
%</!book&!report>
% \end{macrocode}
%
% インデントと幅はそれぞれ1.5em,2.3emでしたが,
% 1zw,3.683zwに変えました。
% \begin{macrocode}
%<book|report> % \newcommand*{\l@section}{\@dottedtocline{1}{1zw}{3.683zw}}
% \end{macrocode}
%
% [2013-12-30] 上のインデントは |\jsc@tocl@width| から決めるように
% しました。(by ts)
%
% \end{macro}
%
% \begin{macro}{\l@subsection}
% \begin{macro}{\l@subsubsection}
% \begin{macro}{\l@paragraph}
% \begin{macro}{\l@subparagraph}
%
% さらに下位レベルの目次項目の体裁です。
% あまり使ったことがありませんので,要修正かもしれません。
%
% [2013-12-30] ここも |\jsc@tocl@width| から決めるように
% してみました。(by ts)
%
% \begin{macrocode}
%<*!book&!report>
% \newcommand*{\l@subsection} {\@dottedtocline{2}{1.5em}{2.3em}}
% \newcommand*{\l@subsubsection}{\@dottedtocline{3}{3.8em}{3.2em}}
% \newcommand*{\l@paragraph} {\@dottedtocline{4}{7.0em}{4.1em}}
% \newcommand*{\l@subparagraph} {\@dottedtocline{5}{10em}{5em}}
%
% \newcommand*{\l@subsection} {\@dottedtocline{2}{1zw}{3zw}}
% \newcommand*{\l@subsubsection}{\@dottedtocline{3}{2zw}{3zw}}
% \newcommand*{\l@paragraph} {\@dottedtocline{4}{3zw}{3zw}}
% \newcommand*{\l@subparagraph} {\@dottedtocline{5}{4zw}{3zw}}
%
\newcommand*{\l@subsection}{%
\@tempdima\jsc@tocl@width \advance\@tempdima -1zw
\@dottedtocline{2}{\@tempdima}{3zw}}
\newcommand*{\l@subsubsection}{%
\@tempdima\jsc@tocl@width \advance\@tempdima 0zw
\@dottedtocline{3}{\@tempdima}{4zw}}
\newcommand*{\l@paragraph}{%
\@tempdima\jsc@tocl@width \advance\@tempdima 1zw
\@dottedtocline{4}{\@tempdima}{5zw}}
\newcommand*{\l@subparagraph}{%
\@tempdima\jsc@tocl@width \advance\@tempdima 2zw
\@dottedtocline{5}{\@tempdima}{6zw}}
%</!book&!report>
%<*book|report>
% \newcommand*{\l@subsection} {\@dottedtocline{2}{3.8em}{3.2em}}
% \newcommand*{\l@subsubsection}{\@dottedtocline{3}{7.0em}{4.1em}}
% \newcommand*{\l@paragraph} {\@dottedtocline{4}{10em}{5em}}
% \newcommand*{\l@subparagraph} {\@dottedtocline{5}{12em}{6em}}
\newcommand*{\l@section}{%
\@tempdima\jsc@tocl@width \advance\@tempdima -1zw
\@dottedtocline{1}{\@tempdima}{3.683zw}}
\newcommand*{\l@subsection}{%
\@tempdima\jsc@tocl@width \advance\@tempdima 2.683zw
\@dottedtocline{2}{\@tempdima}{3.5zw}}
\newcommand*{\l@subsubsection}{%
\@tempdima\jsc@tocl@width \advance\@tempdima 6.183zw
\@dottedtocline{3}{\@tempdima}{4.5zw}}
\newcommand*{\l@paragraph}{%
\@tempdima\jsc@tocl@width \advance\@tempdima 10.683zw
\@dottedtocline{4}{\@tempdima}{5.5zw}}
\newcommand*{\l@subparagraph}{%
\@tempdima\jsc@tocl@width \advance\@tempdima 16.183zw
\@dottedtocline{5}{\@tempdima}{6.5zw}}
%</book|report>
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\numberline}
% \begin{macro}{\@lnumwidth}
%
% 欧文版\LaTeX では |\numberline{...}| は幅 |\@tempdima| の箱に左詰め
% で出力する命令ですが,
% アスキー版では |\@tempdima| の代わりに |\@lnumwidth| という変数
% で幅を決めるように再定義しています。
% 後続文字が全角か半角かでスペースが変わらないように |\hspace|
% を入れておきました。
%
% \begin{macrocode}
\newdimen\@lnumwidth
\def\numberline#1{\hb@xt@\@lnumwidth{#1\hfil}\hspace{0pt}}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@dottedtocline}
% \begin{macro}{\jsTocLine}
%
% \LaTeX 本体(\texttt{ltsect.dtx} 参照)での定義と同じですが,
% |\@tempdima| を |\@lnumwidth| に変えています。
%
% [2018-06-23] デフォルトでは\jsTocLine のようにベースラインになります。\par
% これを変更可能にするため,|\jsTocLine| というマクロに切り出しました。
% 例えば,仮想ボディの中央
% {\renewcommand{\jsTocLine}{\leaders \hbox {\hss ・\hss}\hfill}\jsTocLine}
% に変更したい場合は
%\begin{verbatim}
% \renewcommand{\jsTocLine}{\leaders \hbox {\hss ・\hss}\hfill}
%\end{verbatim}
% とします。
%
% \begin{macrocode}
\def\jsTocLine{\leaders\hbox{%
$\m@th \mkern \@dotsep mu\hbox{.}\mkern \@dotsep mu$}\hfill}
\def\@dottedtocline#1#2#3#4#5{\ifnum #1>\c@tocdepth \else
\vskip \z@ \@plus.2\jsc@mpt
{\leftskip #2\relax \rightskip \@tocrmarg \parfillskip -\rightskip
\parindent #2\relax\@afterindenttrue
\interlinepenalty\@M
\leavevmode
\@lnumwidth #3\relax
\advance\leftskip \@lnumwidth \null\nobreak\hskip -\leftskip
{#4}\nobreak
\jsTocLine \nobreak\hb@xt@\@pnumwidth{%
\hfil\normalfont \normalcolor #5}\par}\fi}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \paragraph{図目次と表目次}
%
% \begin{macro}{\listoffigures}
%
% 図目次を出力します。
%
% \begin{macrocode}
\newcommand{\listoffigures}{%
%<*book|report>
\if@twocolumn\@restonecoltrue\onecolumn
\else\@restonecolfalse\fi
\chapter*{\listfigurename}%
\@mkboth{\listfigurename}{}%
%</book|report>
%<*!book&!report>
\section*{\listfigurename}%
\@mkboth{\listfigurename}{\listfigurename}%
%</!book&!report>
\@starttoc{lof}%
%<book|report> \if@restonecol\twocolumn\fi
}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\l@figure}
%
% 図目次の項目を出力します。
%
% \begin{macrocode}
\newcommand*{\l@figure}{\@dottedtocline{1}{1zw}{3.683zw}}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\listoftables}
%
% 表目次を出力します。
%
% \begin{macrocode}
\newcommand{\listoftables}{%
%<*book|report>
\if@twocolumn\@restonecoltrue\onecolumn
\else\@restonecolfalse\fi
\chapter*{\listtablename}%
\@mkboth{\listtablename}{}%
%</book|report>
%<*!book&!report>
\section*{\listtablename}%
\@mkboth{\listtablename}{\listtablename}%
%</!book&!report>
\@starttoc{lot}%
%<book|report> \if@restonecol\twocolumn\fi
}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\l@table}
%
% 表目次は図目次と同じです。
%
% \begin{macrocode}
\let\l@table\l@figure
% \end{macrocode}
% \end{macro}
%
% \subsection{参考文献}
%
% \begin{macro}{\bibindent}
%
% オープンスタイルの参考文献で使うインデント幅です。
% 元は 1.5em でした。
%
% \begin{macrocode}
\newdimen\bibindent
\setlength\bibindent{2zw}
% \end{macrocode}
% \end{macro}
%
% \begin{environment}{thebibliography}
%
% 参考文献リストを出力します。
%
% \begin{macrocode}
\newenvironment{thebibliography}[1]{%
\global\let\presectionname\relax
\global\let\postsectionname\relax
%<article|jspf> \section*{\refname}\@mkboth{\refname}{\refname}%
%<*kiyou>
\vspace{1.5\baselineskip}
\subsubsection*{\refname}\@mkboth{\refname}{\refname}%
\vspace{0.5\baselineskip}
%</kiyou>
%<book|report> \chapter*{\bibname}\@mkboth{\bibname}{}%
%<book|report> \addcontentsline{toc}{chapter}{\bibname}%
\list{\@biblabel{\@arabic\c@enumiv}}%
{\settowidth\labelwidth{\@biblabel{#1}}%
\leftmargin\labelwidth
\advance\leftmargin\labelsep
\@openbib@code
\usecounter{enumiv}%
\let\p@enumiv\@empty
\renewcommand\theenumiv{\@arabic\c@enumiv}}%
%<kiyou> \small
\sloppy
\clubpenalty4000
\@clubpenalty\clubpenalty
\widowpenalty4000%
\sfcode`\.\@m}
{\def\@noitemerr
{\@latex@warning{Empty `thebibliography' environment}}%
\endlist}
% \end{macrocode}
% \end{environment}
%
% \begin{macro}{\newblock}
%
% |\newblock| はデフォルトでは小さなスペースを生成します。
%
% \begin{macrocode}
\newcommand{\newblock}{\hskip .11em\@plus.33em\@minus.07em}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@openbib@code}
%
% |\@openbib@code| はデフォルトでは何もしません。
% この定義は |openbib| オプションによって変更されます。
%
% \begin{macrocode}
\let\@openbib@code\@empty
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@biblabel}
%
% |\bibitem[...]| のラベルを作ります。
% \texttt{ltbibl.dtx} の定義の半角 [] を全角[]に変え,
% 余分なスペースが入らないように |\inhibitglue| ではさみました。
% とりあえずコメントアウトしておきますので,必要に応じて生かしてください。
%
% \begin{macrocode}
% \def\@biblabel#1{\inhibitglue [#1]\inhibitglue}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\cite}
% \begin{macro}{\@cite}
% \begin{macro}{\@citex}
%
% 文献の番号を出力する部分は \texttt{ltbibl.dtx} で定義されていますが,
% コンマとかっこを和文フォントにするには次のようにします。
% とりあえずコメントアウトしておきましたので,必要に応じて生かしてください。
% かっこの前後に入るグルーを |\inhibitglue| で取っていますので,
% オリジナル同様,\verb*+Knuth~\cite{knu} + のように半角空白
% で囲んでください。
%
% \begin{macrocode}
% \def\@citex[#1]#2{\leavevmode
% \let\@citea\@empty
% \@cite{\@for\@citeb:=#2\do
% {\@citea\def\@citea{,\inhibitglue\penalty\@m\ }%
% \edef\@citeb{\expandafter\@firstofone\@citeb\@empty}%
% \if@filesw\immediate\write\@auxout{\string\citation{\@citeb}}\fi
% \@ifundefined{b@\@citeb}{\mbox{\normalfont\bfseries ?}%
% \G@refundefinedtrue
% \@latex@warning
% {Citation `\@citeb' on page \thepage \space undefined}}%
% {\@cite@ofmt{\csname b@\@citeb\endcsname}}}}{#1}}
% \def\@cite#1#2{\inhibitglue [{#1\if@tempswa ,#2\fi}]\inhibitglue}
% \end{macrocode}
%
% 引用番号を上ツキの 1)のようなスタイルにするには次のようにします。
% |\cite| の先頭に |\unskip| を付けて先行のスペース(\verb|~| も)
% を帳消しにしています。
%
% \begin{macrocode}
% \DeclareRobustCommand\cite{\unskip
% \@ifnextchar [{\@tempswatrue\@citex}{\@tempswafalse\@citex[]}}
% \def\@cite#1#2{$^{\hbox{\scriptsize{#1\if@tempswa
% ,\inhibitglue\ #2\fi})}}$}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \subsection{索引}
%
% \begin{environment}{theindex}
%
% 2〜3段組の索引を作成します。
% 最後が偶数ページのときにマージンがずれる現象を直しました(Thanks: 藤村さん)。
%
% \begin{macrocode}
\newenvironment{theindex}{% 索引を3段組で出力する環境
\if@twocolumn
\onecolumn\@restonecolfalse
\else
\clearpage\@restonecoltrue
\fi
\columnseprule.4pt \columnsep 2zw
\ifx\multicols\@undefined
%<book|report> \twocolumn[\@makeschapterhead{\indexname}%
%<book|report> \addcontentsline{toc}{chapter}{\indexname}]%
%<!book&!report> \def\presectionname{}\def\postsectionname{}%
%<!book&!report> \twocolumn[\section*{\indexname}]%
\else
\ifdim\textwidth<\fullwidth
\setlength{\evensidemargin}{\oddsidemargin}
\setlength{\textwidth}{\fullwidth}
\setlength{\linewidth}{\fullwidth}
%<book|report> \begin{multicols}{3}[\chapter*{\indexname}%
%<book|report> \addcontentsline{toc}{chapter}{\indexname}]%
%<!book&!report> \def\presectionname{}\def\postsectionname{}%
%<!book&!report> \begin{multicols}{3}[\section*{\indexname}]%
\else
%<book|report> \begin{multicols}{2}[\chapter*{\indexname}%
%<book|report> \addcontentsline{toc}{chapter}{\indexname}]%
%<!book&!report> \def\presectionname{}\def\postsectionname{}%
%<!book&!report> \begin{multicols}{2}[\section*{\indexname}]%
\fi
\fi
%<book|report> \@mkboth{\indexname}{}%
%<!book&!report> \@mkboth{\indexname}{\indexname}%
\plainifnotempty % \thispagestyle{plain}
\parindent\z@
\parskip\z@ \@plus .3\jsc@mpt\relax
\let\item\@idxitem
\raggedright
\footnotesize\narrowbaselines
}{
\ifx\multicols\@undefined
\if@restonecol\onecolumn\fi
\else
\end{multicols}
\fi
\clearpage
}
% \end{macrocode}
% \end{environment}
%
% \begin{macro}{\@idxitem}
% \begin{macro}{\subitem}
% \begin{macro}{\subsubitem}
%
% 索引項目の字下げ幅です。|\@idxitem| は |\item| の項目の字下げ幅です。
%
% \begin{macrocode}
\newcommand{\@idxitem}{\par\hangindent 4zw} % 元 40pt
\newcommand{\subitem}{\@idxitem \hspace*{2zw}} % 元 20pt
\newcommand{\subsubitem}{\@idxitem \hspace*{3zw}} % 元 30pt
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\indexspace}
%
% 索引で先頭文字ごとのブロックの間に入るスペースです。
%
% \begin{macrocode}
\newcommand{\indexspace}{\par \vskip 10\jsc@mpt \@plus5\jsc@mpt \@minus3\jsc@mpt\relax}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\seename}
% \begin{macro}{\alsoname}
%
% 索引の |\see|,|\seealso| コマンドで出力されるものです。
% デフォルトはそれぞれ \emph{see},\emph{see also} という英語ですが,
% ここではとりあえず両方とも「→」に変えました。
% $\Rightarrow$(|$\Rightarrow$|)などでもいいでしょう。
%
% \begin{macrocode}
\newcommand\seename{\if@english see\else →\fi}
\newcommand\alsoname{\if@english see also\else →\fi}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \subsection{脚注}
%
% \begin{macro}{\footnote}
% \begin{macro}{\footnotemark}
%
% 和文の句読点・閉じかっこ類の直後で用いた際に
% 余分なアキが入るのを防ぐため,
% |\inhibitglue| を入れることにします。
% p\LaTeX の日付が2016/09/03より新しい場合は,このパッチが不要なのであてません。
%
% \begin{macrocode}
\@ifl@t@r\pfmtversion{2016/09/03}
{\jsc@needsp@tchfalse}{\jsc@needsp@tchtrue}
\ifjsc@needsp@tch
\let\footnotes@ve=\footnote
\def\footnote{\inhibitglue\footnotes@ve}
\let\footnotemarks@ve=\footnotemark
\def\footnotemark{\inhibitglue\footnotemarks@ve}
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\@makefnmark}
%
% 脚注番号を付ける命令です。
% ここでは脚注番号の前に記号 $*$ を付けています。
% 「注1」の形式にするには |\textasteriskcentered|
% を |注\kern0.1em| にしてください。
% |\@xfootnotenext| と合わせて,
% もし脚注番号が空なら記号も出力しないようにしてあります。
%
% [2002-04-09] インプリメントの仕方を変えたため消しました。
%
% [2013-04-23] 新しい\pTeX では脚注番号のまわりにスペースが入りすぎることを防ぐため,
% 北川さんのパッチ [qa:57090] を取り込みました。
%
% [2013-05-14] plcore.ltx に倣った形に書き直しました(Thanks: 北川さん)。
%
% [2016-07-11] コミュニティ版p\LaTeX の変更に追随しました(Thanks: 角藤さん)。
% p\LaTeX の日付が2016/04/17より新しい場合は,このパッチが不要なのであてません。
%
% \begin{macrocode}
\@ifl@t@r\pfmtversion{2016/04/17}
{\jsc@needsp@tchfalse}{\jsc@needsp@tchtrue}
\ifjsc@needsp@tch
\renewcommand\@makefnmark{%
\ifydir \hbox{}\hbox{\@textsuperscript{\normalfont\@thefnmark}}\hbox{}%
\else\hbox{\yoko\@textsuperscript{\normalfont\@thefnmark}}\fi}
\fi
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\thefootnote}
%
% 脚注番号に * 印が付くようにしました。
% ただし,番号がゼロのときは * 印も脚注番号も付きません。
%
% [2003-08-15] |\textasteriskcentered| ではフォントによって
% 下がりすぎるので変更しました。
%
% [2016-10-08] TODO: 脚注番号が |newtxtext| や |newpxtext| の使用時に
% おかしくなってしまいます。これらのパッケージは内部で |\thefootnote| を
% 再定義していますので,気になる場合はパッケージを読み込むときに
% \texttt{defaultsups} オプションを付けてください(qa:57284, qa:57287)。
%
% \begin{macrocode}
\def\thefootnote{\ifnum\c@footnote>\z@\leavevmode\lower.5ex\hbox{*}\@arabic\c@footnote\fi}
% \end{macrocode}
%
% 「注1」の形式にするには次のようにしてください。
%
% \begin{macrocode}
% \def\thefootnote{\ifnum\c@footnote>\z@ 注\kern0.1zw\@arabic\c@footnote\fi}
% \end{macrocode}
%
% \end{macro}
%
% \begin{macro}{\footnoterule}
%
% 本文と脚注の間の罫線です。
%
% \begin{macrocode}
\renewcommand{\footnoterule}{%
\kern-3\jsc@mpt
\hrule width .4\columnwidth height 0.4\jsc@mpt
\kern 2.6\jsc@mpt}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\c@footnote}
%
% 脚注番号は章ごとにリセットされます。
%
% \begin{macrocode}
%<book|report>\@addtoreset{footnote}{chapter}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@footnotetext}
%
% 脚注で |\verb| が使えるように改変してあります。
% Jeremy Gibbons, \textit{\TeX\ and TUG NEWS},
% Vol.~2, No.~4 (1993), p.~9)
%
% [2016-08-25] コミュニティ版\pLaTeX の「閉じ括弧類の直後に
% |\footnotetext| が続く場合に改行が起きることがある問題に対処」
% と同等のコードを追加しました。
%
% [2016-09-08] コミュニティ版\pLaTeX のバグ修正に追随しました。
%
% [2016-11-29] 古い\pLaTeX で使用された場合を考慮してコードを改良。
% ^^A 脚注直後に改行を可能にするために|\null|を入れる場合,
% ^^A 同時にペナルティも考慮しなければ誤った改行が起きる可能性がある。
% ^^A このため,|\ifhmode\null\fi|は
% ^^A |\ifx\pltx@foot@penalty\@undefined\else ... \fi|
% ^^A 条件の内側に置いておくのが安全。
%
% [2018-03-11] |\next|などいくつかの内部命令を |\jsc@...| 付きの
% ユニークな名前にしました。
%
% [2022-09-13] \LaTeXe~2021-11-15 (ltfloat.dtx 2021/10/14 v1.2g)で
% |\@currentcounter|が追加されましたので,追随します。
% なお,\LaTeXe~2021-06-01 (ltfloat.dtx 2021/02/10 v1.2e)で
% parhook対応として\cs{par}が追加されていますが,
% 実は同時に\cs{color@endgroup}も\cs{endgraf}するように変更
% されていますので,不要だと思います。というわけで追加しません。
% \begin{macrocode}
\long\def\@footnotetext{%
\insert\footins\bgroup
\normalfont\footnotesize
\interlinepenalty\interfootnotelinepenalty
\splittopskip\footnotesep
\splitmaxdepth \dp\strutbox \floatingpenalty \@MM
\hsize\columnwidth \@parboxrestore
\def\@currentcounter{footnote}%
\protected@edef\@currentlabel{%
\csname p@footnote\endcsname\@thefnmark
}%
\color@begingroup
\@makefntext{%
\rule\z@\footnotesep\ignorespaces}%
\futurelet\jsc@next\jsc@fo@t}
\def\jsc@fo@t{\ifcat\bgroup\noexpand\jsc@next \let\jsc@next\jsc@f@@t
\else \let\jsc@next\jsc@f@t\fi \jsc@next}
\def\jsc@f@@t{\bgroup\aftergroup\jsc@@foot\let\jsc@next}
\def\jsc@f@t#1{#1\jsc@@foot}
\def\jsc@@foot{\@finalstrut\strutbox\color@endgroup\egroup
\ifx\pltx@foot@penalty\@undefined\else
\ifhmode\null\fi
\ifnum\pltx@foot@penalty=\z@\else
\penalty\pltx@foot@penalty
\pltx@foot@penalty\z@
\fi
\fi}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@makefntext}
%
% 実際に脚注を出力する命令です。
% |\@makefnmark| は脚注の番号を出力する命令です。
% ここでは脚注が左端から一定距離に来るようにしてあります。
%
% \begin{macrocode}
\newcommand\@makefntext[1]{%
\advance\leftskip 3zw
\parindent 1zw
\noindent
\llap{\@makefnmark\hskip0.3zw}#1}
% \end{macrocode}
% \end{macro}
%
% \begin{macro}{\@xfootnotenext}
%
% 最初の |\footnotetext{...}| は番号が付きません。
% 著者の所属などを脚注の欄に書くときに便利です。
%
% すでに |\footnote| を使った後なら |\footnotetext[0]{...}|
% とすれば番号を付けない脚注になります。
% ただし,この場合は脚注番号がリセットされてしまうので,
% 工夫が必要です。
%
% [2002-04-09] インプリメントの仕方を変えたため消しました。
%
% \begin{macrocode}
% \def\@xfootnotenext[#1]{%
% \begingroup
% \ifnum#1>\z@
% \csname c@\@mpfn\endcsname #1\relax
% \unrestored@protected@xdef\@thefnmark{\thempfn}%
% \else
% \unrestored@protected@xdef\@thefnmark{}%
% \fi
% \endgroup
% \@footnotetext}
% \end{macrocode}
% \end{macro}
%
% \section{段落の頭へのグルー挿入禁止}
%
% 段落頭のかぎかっこなどを見かけ1字半下げから全角1字下げに直します。
%
% [2016-07-18] |\inhibitglue| の発行対象を |\inhibitxspcode| が2に
% 設定されているものすべてに拡大しました。
%
% [2016-12-01] すぐ上の変更で |\@tempa| を使っていたのがよくなかった
% ので,プレフィックスを付けて |\jsc@tempa| にしました(forum:2085)。
%
% [2017-02-13] |\jsc@tempa| は実はテンポラリではなく「この処理専用の
% ユニーク制御綴」である必要があります。間違って別の箇所で使う危険性が
% 高いので,専用の命令 |\jsc@ig@temp| に置き換えました(Issue \#54)。
%
% \begin{macrocode}
\def\@inhibitglue{%
\futurelet\@let@token\@@inhibitglue}
\begingroup
\let\GDEF=\gdef
\let\CATCODE=\catcode
\let\ENDGROUP=\endgroup
\CATCODE`k=12
\CATCODE`a=12
\CATCODE`n=12
\CATCODE`j=12
\CATCODE`i=12
\CATCODE`c=12
\CATCODE`h=12
\CATCODE`r=12
\CATCODE`t=12
\CATCODE`e=12
\GDEF\KANJI@CHARACTER{kanji character }
\ENDGROUP
\def\@@inhibitglue{%
\expandafter\expandafter\expandafter\jsc@inhibitglue\expandafter\meaning\expandafter\@let@token\KANJI@CHARACTER\relax\jsc@end}
\expandafter\def\expandafter\jsc@inhibitglue\expandafter#\expandafter1\KANJI@CHARACTER#2#3\jsc@end{%
\def\jsc@ig@temp{#1}%
\ifx\jsc@ig@temp\@empty
\ifnum\the\inhibitxspcode`#2=2\relax
\inhibitglue
\fi
\fi}
\let\everyparhook=\@inhibitglue
\AtBeginDocument{\everypar{\everyparhook}}
% \end{macrocode}
%
% これだけではいけないようです。あちこちに |\everypar| を初期化するコマンドが
% 隠されていました。
%
% まず,環境の直後の段落です。
%
% [2016-11-19] ltlists.dtx 2015/05/10 v1.0tの変更に追随して |\clubpenalty| の
% リセットを追加しました。
%
% \begin{macrocode}
\def\@doendpe{%
\@endpetrue
\def\par{%
\@restorepar\clubpenalty\@clubpenalty\everypar{\everyparhook}\par\@endpefalse}%
\everypar{{\setbox\z@\lastbox}\everypar{\everyparhook}\@endpefalse\everyparhook}}
% \end{macrocode}
%
% [2017-08-31] minipage環境にも対策します。
%
% \begin{macrocode}
\def\@setminipage{%
\@minipagetrue
\everypar{\@minipagefalse\everypar{\everyparhook}}%
}
% \end{macrocode}
%
% |\item| 命令の直後です。
%
% \begin{macrocode}
\def\@item[#1]{%
\if@noparitem
\@donoparitem
\else
\if@inlabel
\indent \par
\fi
\ifhmode
\unskip\unskip \par
\fi
\if@newlist
\if@nobreak
\@nbitem
\else
\addpenalty\@beginparpenalty
\addvspace\@topsep
\addvspace{-\parskip}%
\fi
\else
\addpenalty\@itempenalty
\addvspace\itemsep
\fi
\global\@inlabeltrue
\fi
\everypar{%
\@minipagefalse
\global\@newlistfalse
\if@inlabel
\global\@inlabelfalse
{\setbox\z@\lastbox
\ifvoid\z@
\kern-\itemindent
\fi}%
\box\@labels
\penalty\z@
\fi
\if@nobreak
\@nobreakfalse
\clubpenalty \@M
\else
\clubpenalty \@clubpenalty
\everypar{\everyparhook}%
\fi\everyparhook}%
\if@noitemarg
\@noitemargfalse
\if@nmbrlist
\refstepcounter\@listctr
\fi
\fi
\sbox\@tempboxa{\makelabel{#1}}%
\global\setbox\@labels\hbox{%
\unhbox\@labels
\hskip \itemindent
\hskip -\labelwidth
\hskip -\labelsep
\ifdim \wd\@tempboxa >\labelwidth
\box\@tempboxa
\else
\hbox to\labelwidth {\unhbox\@tempboxa}%
\fi
\hskip \labelsep}%
\ignorespaces}
% \end{macrocode}
%
% 二つ挿入した |\everyparhook| のうち後者が |\section| 類の直後に2回,
% 前者が3回目以降に実行されます。
%
% \begin{macrocode}
\def\@afterheading{%
\@nobreaktrue
\everypar{%
\if@nobreak
\@nobreakfalse
\clubpenalty \@M
\if@afterindent \else
{\setbox\z@\lastbox}%
\fi
\else
\clubpenalty \@clubpenalty
\everypar{\everyparhook}%
\fi\everyparhook}}
% \end{macrocode}
%
% |\@gnewline| についてはちょっと複雑な心境です。
% もともとのp\LaTeXe は段落の頭にグルーが入る方で統一されていました。
% しかし |\\| の直後にはグルーが入らず,不統一でした。
% そこで |\\| の直後にもグルーを入れるように直していただいた経緯があります。
% しかし,ここでは逆にグルーを入れない方で統一したいので,
% また元に戻してしまいました。
%
% しかし単に戻すだけでも駄目みたいなので,ここでも最後にグルーを消しておきます。
%
% \begin{macrocode}
\def\@gnewline #1{%
\ifvmode
\@nolnerr
\else
\unskip \reserved@e {\reserved@f#1}\nobreak \hfil \break \null
\inhibitglue \ignorespaces
\fi}
% \end{macrocode}
%
% \section{いろいろなロゴ}
%
% \LaTeX 関連のロゴを作り直します。
%
% [2016-07-14] ロゴの定義は\texttt{jslogo}パッケージに移転しました。
% 後方互換のため,\texttt{jsclasses}ではデフォルトでこれを読み込みます。
% \texttt{nojslogo}オプションが指定されている場合は読み込みません。
%
% \begin{macro}{\小}
% \begin{macro}{\上小}
%
% 文字を小さめに出したり上寄りに小さめに出したりする命令を,
% \texttt{jslogo.sty}では名称変更してありますので,コピーします。
% \begin{macrocode}
\if@jslogo
\IfFileExists{jslogo.sty}{%
\RequirePackage{jslogo}%
\def\小{\jslg@small}%
\def\上小{\jslg@uppersmall}%
}{%
\ClassWarningNoLine{\jsc@clsname}{%
The redefinitions of LaTeX-related logos has\MessageBreak
been moved to jslogo.sty since 2016, but\MessageBreak
jslogo.sty not found. Current release of\MessageBreak
'jsclasses' includes it, so please check\MessageBreak
the installation}%
}
\fi
% \end{macrocode}
% \end{macro}
% \end{macro}
%
%
% \section{\texttt{amsmath} との衝突の回避}
%
% \begin{macro}{\ltx@ifnextchar}
% \begin{macro}{\ProvidesFile}
%
% \texttt{amsmath} パッケージでは行列中で |\@ifnextchar|
% を再定義していますが,これが\LaTeX の |\ProvidesFile|
% で悪さをする例がFTeXで報告されています。
% これを避けるためのtDBさんのフィックスを挿入しておきます。
% 副作用がありましたらお知らせください。
%
% この現象については私のTeX掲示板 4273〜,16058〜 で議論がありました。
% なお,AMS関係のパッケージを読み込む際に psamsfonts オプションを
% 与えても回避できます(Thanks: しっぽ愛好家さん)。
%
% [2016-11-19] 本家の ltclass.dtx 2004/01/28 v1.1g で修正されているので
% コメントアウトしました。
%
% \begin{macrocode}
%\let\ltx@ifnextchar\@ifnextchar
%\def\ProvidesFile#1{%
% \begingroup
% \catcode`\ 10 %
% \ifnum \endlinechar<256 %
% \ifnum \endlinechar>\m@ne
% \catcode\endlinechar 10 %
% \fi
% \fi
% \@makeother\/%
% \@makeother\&%
% \ltx@ifnextchar[{\@providesfile{#1}}{\@providesfile{#1}[]}}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \section{初期設定}
%
% \paragraph{いろいろな語}
%
% \begin{macro}{\prepartname}
% \begin{macro}{\postpartname}
% \begin{macro}{\prechaptername}
% \begin{macro}{\postchaptername}
% \begin{macro}{\presectionname}
% \begin{macro}{\postsectionname}
% \begin{macrocode}
\newcommand{\prepartname}{\if@english Part~\else 第\fi}
\newcommand{\postpartname}{\if@english\else 部\fi}
%<book|report>\newcommand{\prechaptername}{\if@english Chapter~\else 第\fi}
%<book|report>\newcommand{\postchaptername}{\if@english\else 章\fi}
\newcommand{\presectionname}{}% 第
\newcommand{\postsectionname}{}% 節
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\contentsname}
% \begin{macro}{\listfigurename}
% \begin{macro}{\listtablename}
% \begin{macrocode}
\newcommand{\contentsname}{\if@english Contents\else 目次\fi}
\newcommand{\listfigurename}{\if@english List of Figures\else 図目次\fi}
\newcommand{\listtablename}{\if@english List of Tables\else 表目次\fi}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\refname}
% \begin{macro}{\bibname}
% \begin{macro}{\indexname}
% \begin{macrocode}
\newcommand{\refname}{\if@english References\else 参考文献\fi}
\newcommand{\bibname}{\if@english Bibliography\else 参考文献\fi}
\newcommand{\indexname}{\if@english Index\else 索引\fi}
% \end{macrocode}
% \end{macro}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\figurename}
% \begin{macro}{\tablename}
% \begin{macrocode}
%<!jspf>\newcommand{\figurename}{\if@english Fig.~\else 図\fi}
%<jspf>\newcommand{\figurename}{Fig.~}
%<!jspf>\newcommand{\tablename}{\if@english Table~\else 表\fi}
%<jspf>\newcommand{\tablename}{Table~}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \begin{macro}{\appendixname}
% \begin{macro}{\abstractname}
% \begin{macrocode}
% \newcommand{\appendixname}{\if@english Appendix~\else 付録\fi}
\newcommand{\appendixname}{\if@english \else 付録\fi}
%<!book>\newcommand{\abstractname}{\if@english Abstract\else 概要\fi}
% \end{macrocode}
% \end{macro}
% \end{macro}
%
% \paragraph{今日の日付}
%
% \LaTeX で処理した日付を出力します。
% ^^A |jarticle| などと違って,標準を西暦にし,
% ^^A 余分な空白が入らないように改良しました。
% ^^A -- 2018年7月以降は |jarticle| なども標準が西暦,
% ^^A -- 2019年4月以降は余分な空白が入らなくなっています。
% 和暦にするには |\和暦| と書いてください。
% ちなみにこの文章の作成日は西暦では{\西暦\today}で,
% 和暦では{\和暦\today}です。
%
% \begin{macro}{\today}
% \begin{macrocode}
\newif\if西暦 \西暦true
\def\西暦{\西暦true}
\def\和暦{\西暦false}
\newcount\heisei \heisei\year \advance\heisei-1988\relax
\def\pltx@today@year@#1{%
\ifnum\numexpr\year-#1=1 元\else
\ifnum1=\iftdir\ifmdir0\else1\fi\else0\fi
\kansuji\numexpr\year-#1\relax
\else
\number\numexpr\year-#1\relax\nobreak
\fi
\fi 年
}
\def\pltx@today@year{%
\ifnum\numexpr\year*10000+\month*100+\day<19890108
昭和\pltx@today@year@{1925}%
\else\ifnum\numexpr\year*10000+\month*100+\day<20190501
平成\pltx@today@year@{1988}%
\else
令和\pltx@today@year@{2018}%
\fi\fi}
\def\today{%
\if@english
\ifcase\month\or
January\or February\or March\or April\or May\or June\or
July\or August\or September\or October\or November\or December\fi
\space\number\day, \number\year
\else\if西暦
\ifnum1=\iftdir\ifmdir0\else1\fi\else0\fi \kansuji\year
\else\number\year\nobreak\fi 年
\else
\pltx@today@year
\fi
\ifnum1=\iftdir\ifmdir0\else1\fi\else0\fi
\kansuji\month 月
\kansuji\day 日
\else
\number\month\nobreak 月
\number\day\nobreak 日
\fi\fi}
% \end{macrocode}
% \end{macro}
%
% \paragraph{ハイフネーション例外}
%
% \TeX のハイフネーションルールの補足です(ペンディング:eng-lish)
%
% \begin{macrocode}
\hyphenation{ado-be post-script ghost-script phe-nom-e-no-log-i-cal man-u-script}
% \end{macrocode}
%
% \paragraph{ページ設定}
%
% ページ設定の初期化です。
%
% \begin{macrocode}
%<article>\if@slide \pagestyle{empty} \else \pagestyle{plain} \fi
%<book>\if@report \pagestyle{plain} \else \pagestyle{headings} \fi
%<report|kiyou>\pagestyle{plain}
%<jspf>\pagestyle{headings}
\pagenumbering{arabic}
\if@twocolumn
\twocolumn
\sloppy
\flushbottom
\else
\onecolumn
\raggedbottom
\fi
\if@slide
\renewcommand\kanjifamilydefault{\gtdefault}
\renewcommand\familydefault{\sfdefault}
\raggedright
\xkanjiskip=0.1em\relax
\fi
% \end{macrocode}
%
%
% \section{実験的コード}
%
% [2016-11-29] コミュニティ版p\LaTeX で新設されたテスト用パッケージ
% (\texttt{exppl2e}パッケージ)が文書クラスより先に読み込まれていた
% 場合は,jsclassesもテスト版として動作します。この処置は
% jsarticle,jsbook,jsreportにのみ行い,jspfとkiyouは除外しておきます。
% exppl2eパッケージが読みこまれていない場合は通常版として動作しますので,
% ここで終了します。
%
% \begin{macrocode}
%<*article|book|report>
\@ifpackageloaded{exppl2e}{\jsc@needsp@tchtrue}{\jsc@needsp@tchfalse}
\ifjsc@needsp@tch\else
\expandafter\endinput
\fi
% \end{macrocode}
%
% 以下は実験的コードです。具体的には,2016/11/29の\texttt{exppl2e}パッケージ
% で説明されている|\@gnewline|のパッチを入れてあります。
%
% \begin{macro}{\@gnewline}
% \begin{macrocode}
\def\@gnewline #1{%
\ifvmode
\@nolnerr
\else
\unskip \reserved@e {\reserved@f#1}\nobreak \hfil \break \hskip \z@
\ignorespaces
\fi}
%</article|book|report>
%</class>
% \end{macrocode}
% \end{macro}
%
% 以上です。
%
% \Finale
%
\endinput
|