├── .github └── ISSUE_TEMPLATE │ └── bug_report.md ├── .gitignore ├── DEPENDS.txt ├── LICENSE ├── Makefile ├── README.md ├── TODO ├── microtype-logo.dtx ├── microtype-lssample.dtx ├── microtype-utf.dtx ├── microtype.dtx ├── microtype.ins └── testsuite ├── error-algorithm.tex ├── error-amsalign_lualatex.tex ├── error-amsmath.tex ├── error-asterisk.tex ├── error-asteriskcentered.tex ├── error-chmath.tex ├── error-cjk.tex ├── error-cjkutf8.tex ├── error-dofont_lualatex.tex ├── error-eplain_luatex.tex ├── error-eplain_pdftex.tex ├── error-eplainlua_luatex.tex ├── error-expanding.tex ├── error-filespec_lualatex.tex ├── error-fontdimen6.tex ├── error-fontdimen6_dvilualatex.tex ├── error-fontsize-dimen.tex ├── error-fontspec_lualatex.tex ├── error-generic_dvilualatex.tex ├── error-getslot_xelatex.tex ├── error-leftprotrusion-beamer.tex ├── error-leftprotrusion-csq.tex ├── error-leftprotrusion.tex ├── error-leftprotrusion_lualatex.tex ├── error-letterspace-qs.tex ├── error-letterspace-sc.tex ├── error-letterspace1.tex ├── error-letterspace2.tex ├── error-letterspace3.tex ├── error-letterspace4.tex ├── error-letterspace_lualatex.tex ├── error-listings-luatexja_lualatex.tex ├── error-listings1.tex ├── error-listings2.tex ├── error-listings3.tex ├── error-listings4-disc.tex ├── error-listings5-ae.tex ├── error-listings6_xelatex.tex ├── error-luainput-math_lualatex.tex ├── error-mathchoice.tex ├── error-miniltx_pdftex.tex ├── error-noauto.tex ├── error-nofontspec_xelatex.tex ├── error-overflow.tex ├── error-polyglossia_lualatex.tex ├── error-psnfss.tex ├── error-soul.tex ├── error-svjour3.tex ├── error-tabular.tex ├── error-tagpdf.tex ├── error-tcolorbox.tex ├── error-tikz.tex ├── error-tikz_pdftex.tex ├── error-titlesec.tex ├── error-tracking-zero-fontdimen.tex ├── error-uplatex_uplatex.tex ├── error-varwidth-standalone.tex ├── error-x.tex ├── error-xkeyval.tex ├── errorx-wordcount.tex ├── output-ABD.tex ├── output-beamer.tex ├── output-capitalcaron.tex ├── output-etex-spaces.tex ├── output-exscale.tex ├── output-fontdimen6.tex ├── output-fontdimen6_lualatex.tex ├── output-generic_lualatex.tex ├── output-ls-math1.tex ├── output-ls-math2.tex ├── output-lslig.tex ├── output-nolig_lualatex.tex ├── output-nonolig_lualatex.tex ├── output-patchspanish.tex ├── output-pinyin.tex ├── output-polyglossia_lualatex.tex ├── output-protrusion-changebar.tex ├── output-protrusion-eqnum-ieeetran.tex ├── output-protrusion-fnbreak.tex ├── output-reledmac_lualatex.tex ├── output-subst-context.tex ├── output-subst.tex ├── output-tag-footnote.tex ├── output-tracking-context_lualatex.tex ├── output-xecjk_xelatex.tex ├── unknown-charis_lualatex.tex ├── unknown-charis_xelatex.tex ├── unknown-csquotes-utf8.tex ├── unknown-csquotes.tex ├── unknown-euenc_lualatex.tex ├── unknown-euenc_xelatex.tex ├── unknown-frenchpro.tex ├── unknown-german.tex ├── unknown-luatexja_lualatex.tex ├── unknown-mathastext.tex ├── unknown-newcomputermodern_lualatex.tex ├── unknown-newunicodechar_xelatex.tex ├── unknown-removetlig_lualatex.tex ├── unknown-removetlig_xelatex.tex ├── unknown-shortvrb.tex ├── unknown-spanish.tex ├── unknown-tex4ht.tex ├── unknown-tuenc_lualatex.tex ├── unknown-tuenc_xelatex.tex ├── unknown-utf8.tex └── unknown-xecjk_xelatex.tex /.github/ISSUE_TEMPLATE/bug_report.md: -------------------------------------------------------------------------------- 1 | --- 2 | name: Bug report 3 | about: Create a report to help us improve 4 | title: '' 5 | labels: '' 6 | assignees: schlcht 7 | 8 | --- 9 | 10 | ## Description 11 | A sentence or two describing the issue. 12 | 13 | _Please also indicate the engine(s) with which the issue occurs: pdfTeX/LuaTeX/XeTeX_ 14 | 15 | _Links to discussion if appropriate_ 16 | 17 | ## Minimal example demonstrating the issue 18 | ``` 19 | \documentclass{article} 20 | \usepackage[verbose]{microtype} 21 | \begin{document} 22 | Hello, bug! 23 | \end{document} 24 | ``` 25 | -------------------------------------------------------------------------------- /.gitignore: -------------------------------------------------------------------------------- 1 | # .gitignore for microtype 2 | 3 | # generated files 4 | microtype.sty 5 | microtype-luatex.def 6 | microtype-pdftex.def 7 | microtype-xetex.def 8 | microtype-show.sty 9 | letterspace.sty 10 | microtype.lua 11 | test-microtype.tex 12 | microtype-doc.sty 13 | microtype-gind.ist 14 | *.cfg 15 | 16 | # auxiliary files 17 | *.aux 18 | *.bcf 19 | *.cdx 20 | *.glo 21 | *.gls 22 | *.glg 23 | *.hd 24 | *.idx 25 | *.ind 26 | *.ilg 27 | *.lof 28 | *.log 29 | *.lot 30 | *.nav 31 | *.out 32 | *.run.xml 33 | *.snm 34 | *.tmp 35 | *.toc 36 | *.dvi 37 | *.ps 38 | *.1 39 | *.1R 40 | *.swp 41 | 42 | *.mtx 43 | *.pl 44 | justification.png 45 | 46 | make-normal-sty 47 | make-doc-sty 48 | *-stamp 49 | 50 | # distribution 51 | *.pdf 52 | *.zip 53 | 54 | test.tex 55 | other/* 56 | -------------------------------------------------------------------------------- /DEPENDS.txt: -------------------------------------------------------------------------------- 1 | etoolbox # with etex 2 | -------------------------------------------------------------------------------- /LICENSE: -------------------------------------------------------------------------------- 1 | The LaTeX Project Public License 2 | =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=- 3 | 4 | LPPL Version 1.3c 2008-05-04 5 | 6 | Copyright 1999 2002-2008 LaTeX3 Project 7 | Everyone is allowed to distribute verbatim copies of this 8 | license document, but modification of it is not allowed. 9 | 10 | 11 | PREAMBLE 12 | ======== 13 | 14 | The LaTeX Project Public License (LPPL) is the primary license under 15 | which the LaTeX kernel and the base LaTeX packages are distributed. 16 | 17 | You may use this license for any work of which you hold the copyright 18 | and which you wish to distribute. This license may be particularly 19 | suitable if your work is TeX-related (such as a LaTeX package), but 20 | it is written in such a way that you can use it even if your work is 21 | unrelated to TeX. 22 | 23 | The section `WHETHER AND HOW TO DISTRIBUTE WORKS UNDER THIS LICENSE', 24 | below, gives instructions, examples, and recommendations for authors 25 | who are considering distributing their works under this license. 26 | 27 | This license gives conditions under which a work may be distributed 28 | and modified, as well as conditions under which modified versions of 29 | that work may be distributed. 30 | 31 | We, the LaTeX3 Project, believe that the conditions below give you 32 | the freedom to make and distribute modified versions of your work 33 | that conform with whatever technical specifications you wish while 34 | maintaining the availability, integrity, and reliability of 35 | that work. If you do not see how to achieve your goal while 36 | meeting these conditions, then read the document `cfgguide.tex' 37 | and `modguide.tex' in the base LaTeX distribution for suggestions. 38 | 39 | 40 | DEFINITIONS 41 | =========== 42 | 43 | In this license document the following terms are used: 44 | 45 | `Work' 46 | Any work being distributed under this License. 47 | 48 | `Derived Work' 49 | Any work that under any applicable law is derived from the Work. 50 | 51 | `Modification' 52 | Any procedure that produces a Derived Work under any applicable 53 | law -- for example, the production of a file containing an 54 | original file associated with the Work or a significant portion of 55 | such a file, either verbatim or with modifications and/or 56 | translated into another language. 57 | 58 | `Modify' 59 | To apply any procedure that produces a Derived Work under any 60 | applicable law. 61 | 62 | `Distribution' 63 | Making copies of the Work available from one person to another, in 64 | whole or in part. Distribution includes (but is not limited to) 65 | making any electronic components of the Work accessible by 66 | file transfer protocols such as FTP or HTTP or by shared file 67 | systems such as Sun's Network File System (NFS). 68 | 69 | `Compiled Work' 70 | A version of the Work that has been processed into a form where it 71 | is directly usable on a computer system. This processing may 72 | include using installation facilities provided by the Work, 73 | transformations of the Work, copying of components of the Work, or 74 | other activities. Note that modification of any installation 75 | facilities provided by the Work constitutes modification of the Work. 76 | 77 | `Current Maintainer' 78 | A person or persons nominated as such within the Work. If there is 79 | no such explicit nomination then it is the `Copyright Holder' under 80 | any applicable law. 81 | 82 | `Base Interpreter' 83 | A program or process that is normally needed for running or 84 | interpreting a part or the whole of the Work. 85 | 86 | A Base Interpreter may depend on external components but these 87 | are not considered part of the Base Interpreter provided that each 88 | external component clearly identifies itself whenever it is used 89 | interactively. Unless explicitly specified when applying the 90 | license to the Work, the only applicable Base Interpreter is a 91 | `LaTeX-Format' or in the case of files belonging to the 92 | `LaTeX-format' a program implementing the `TeX language'. 93 | 94 | 95 | 96 | CONDITIONS ON DISTRIBUTION AND MODIFICATION 97 | =========================================== 98 | 99 | 1. Activities other than distribution and/or modification of the Work 100 | are not covered by this license; they are outside its scope. In 101 | particular, the act of running the Work is not restricted and no 102 | requirements are made concerning any offers of support for the Work. 103 | 104 | 2. You may distribute a complete, unmodified copy of the Work as you 105 | received it. Distribution of only part of the Work is considered 106 | modification of the Work, and no right to distribute such a Derived 107 | Work may be assumed under the terms of this clause. 108 | 109 | 3. You may distribute a Compiled Work that has been generated from a 110 | complete, unmodified copy of the Work as distributed under Clause 2 111 | above, as long as that Compiled Work is distributed in such a way that 112 | the recipients may install the Compiled Work on their system exactly 113 | as it would have been installed if they generated a Compiled Work 114 | directly from the Work. 115 | 116 | 4. If you are the Current Maintainer of the Work, you may, without 117 | restriction, modify the Work, thus creating a Derived Work. You may 118 | also distribute the Derived Work without restriction, including 119 | Compiled Works generated from the Derived Work. Derived Works 120 | distributed in this manner by the Current Maintainer are considered to 121 | be updated versions of the Work. 122 | 123 | 5. If you are not the Current Maintainer of the Work, you may modify 124 | your copy of the Work, thus creating a Derived Work based on the Work, 125 | and compile this Derived Work, thus creating a Compiled Work based on 126 | the Derived Work. 127 | 128 | 6. If you are not the Current Maintainer of the Work, you may 129 | distribute a Derived Work provided the following conditions are met 130 | for every component of the Work unless that component clearly states 131 | in the copyright notice that it is exempt from that condition. Only 132 | the Current Maintainer is allowed to add such statements of exemption 133 | to a component of the Work. 134 | 135 | a. If a component of this Derived Work can be a direct replacement 136 | for a component of the Work when that component is used with the 137 | Base Interpreter, then, wherever this component of the Work 138 | identifies itself to the user when used interactively with that 139 | Base Interpreter, the replacement component of this Derived Work 140 | clearly and unambiguously identifies itself as a modified version 141 | of this component to the user when used interactively with that 142 | Base Interpreter. 143 | 144 | b. Every component of the Derived Work contains prominent notices 145 | detailing the nature of the changes to that component, or a 146 | prominent reference to another file that is distributed as part 147 | of the Derived Work and that contains a complete and accurate log 148 | of the changes. 149 | 150 | c. No information in the Derived Work implies that any persons, 151 | including (but not limited to) the authors of the original version 152 | of the Work, provide any support, including (but not limited to) 153 | the reporting and handling of errors, to recipients of the 154 | Derived Work unless those persons have stated explicitly that 155 | they do provide such support for the Derived Work. 156 | 157 | d. You distribute at least one of the following with the Derived Work: 158 | 159 | 1. A complete, unmodified copy of the Work; 160 | if your distribution of a modified component is made by 161 | offering access to copy the modified component from a 162 | designated place, then offering equivalent access to copy 163 | the Work from the same or some similar place meets this 164 | condition, even though third parties are not compelled to 165 | copy the Work along with the modified component; 166 | 167 | 2. Information that is sufficient to obtain a complete, 168 | unmodified copy of the Work. 169 | 170 | 7. If you are not the Current Maintainer of the Work, you may 171 | distribute a Compiled Work generated from a Derived Work, as long as 172 | the Derived Work is distributed to all recipients of the Compiled 173 | Work, and as long as the conditions of Clause 6, above, are met with 174 | regard to the Derived Work. 175 | 176 | 8. The conditions above are not intended to prohibit, and hence do not 177 | apply to, the modification, by any method, of any component so that it 178 | becomes identical to an updated version of that component of the Work as 179 | it is distributed by the Current Maintainer under Clause 4, above. 180 | 181 | 9. Distribution of the Work or any Derived Work in an alternative 182 | format, where the Work or that Derived Work (in whole or in part) is 183 | then produced by applying some process to that format, does not relax or 184 | nullify any sections of this license as they pertain to the results of 185 | applying that process. 186 | 187 | 10. a. A Derived Work may be distributed under a different license 188 | provided that license itself honors the conditions listed in 189 | Clause 6 above, in regard to the Work, though it does not have 190 | to honor the rest of the conditions in this license. 191 | 192 | b. If a Derived Work is distributed under a different license, that 193 | Derived Work must provide sufficient documentation as part of 194 | itself to allow each recipient of that Derived Work to honor the 195 | restrictions in Clause 6 above, concerning changes from the Work. 196 | 197 | 11. This license places no restrictions on works that are unrelated to 198 | the Work, nor does this license place any restrictions on aggregating 199 | such works with the Work by any means. 200 | 201 | 12. Nothing in this license is intended to, or may be used to, prevent 202 | complete compliance by all parties with all applicable laws. 203 | 204 | 205 | NO WARRANTY 206 | =========== 207 | 208 | There is no warranty for the Work. Except when otherwise stated in 209 | writing, the Copyright Holder provides the Work `as is', without 210 | warranty of any kind, either expressed or implied, including, but not 211 | limited to, the implied warranties of merchantability and fitness for a 212 | particular purpose. The entire risk as to the quality and performance 213 | of the Work is with you. Should the Work prove defective, you assume 214 | the cost of all necessary servicing, repair, or correction. 215 | 216 | In no event unless required by applicable law or agreed to in writing 217 | will The Copyright Holder, or any author named in the components of the 218 | Work, or any other party who may distribute and/or modify the Work as 219 | permitted above, be liable to you for damages, including any general, 220 | special, incidental or consequential damages arising out of any use of 221 | the Work or out of inability to use the Work (including, but not limited 222 | to, loss of data, data being rendered inaccurate, or losses sustained by 223 | anyone as a result of any failure of the Work to operate with any other 224 | programs), even if the Copyright Holder or said author or said other 225 | party has been advised of the possibility of such damages. 226 | 227 | 228 | MAINTENANCE OF THE WORK 229 | ======================= 230 | 231 | The Work has the status `author-maintained' if the Copyright Holder 232 | explicitly and prominently states near the primary copyright notice in 233 | the Work that the Work can only be maintained by the Copyright Holder 234 | or simply that it is `author-maintained'. 235 | 236 | The Work has the status `maintained' if there is a Current Maintainer 237 | who has indicated in the Work that they are willing to receive error 238 | reports for the Work (for example, by supplying a valid e-mail 239 | address). It is not required for the Current Maintainer to acknowledge 240 | or act upon these error reports. 241 | 242 | The Work changes from status `maintained' to `unmaintained' if there 243 | is no Current Maintainer, or the person stated to be Current 244 | Maintainer of the work cannot be reached through the indicated means 245 | of communication for a period of six months, and there are no other 246 | significant signs of active maintenance. 247 | 248 | You can become the Current Maintainer of the Work by agreement with 249 | any existing Current Maintainer to take over this role. 250 | 251 | If the Work is unmaintained, you can become the Current Maintainer of 252 | the Work through the following steps: 253 | 254 | 1. Make a reasonable attempt to trace the Current Maintainer (and 255 | the Copyright Holder, if the two differ) through the means of 256 | an Internet or similar search. 257 | 258 | 2. If this search is successful, then enquire whether the Work 259 | is still maintained. 260 | 261 | a. If it is being maintained, then ask the Current Maintainer 262 | to update their communication data within one month. 263 | 264 | b. If the search is unsuccessful or no action to resume active 265 | maintenance is taken by the Current Maintainer, then announce 266 | within the pertinent community your intention to take over 267 | maintenance. (If the Work is a LaTeX work, this could be 268 | done, for example, by posting to comp.text.tex.) 269 | 270 | 3a. If the Current Maintainer is reachable and agrees to pass 271 | maintenance of the Work to you, then this takes effect 272 | immediately upon announcement. 273 | 274 | b. If the Current Maintainer is not reachable and the Copyright 275 | Holder agrees that maintenance of the Work be passed to you, 276 | then this takes effect immediately upon announcement. 277 | 278 | 4. If you make an `intention announcement' as described in 2b. above 279 | and after three months your intention is challenged neither by 280 | the Current Maintainer nor by the Copyright Holder nor by other 281 | people, then you may arrange for the Work to be changed so as 282 | to name you as the (new) Current Maintainer. 283 | 284 | 5. If the previously unreachable Current Maintainer becomes 285 | reachable once more within three months of a change completed 286 | under the terms of 3b) or 4), then that Current Maintainer must 287 | become or remain the Current Maintainer upon request provided 288 | they then update their communication data within one month. 289 | 290 | A change in the Current Maintainer does not, of itself, alter the fact 291 | that the Work is distributed under the LPPL license. 292 | 293 | If you become the Current Maintainer of the Work, you should 294 | immediately provide, within the Work, a prominent and unambiguous 295 | statement of your status as Current Maintainer. You should also 296 | announce your new status to the same pertinent community as 297 | in 2b) above. 298 | 299 | 300 | WHETHER AND HOW TO DISTRIBUTE WORKS UNDER THIS LICENSE 301 | ====================================================== 302 | 303 | This section contains important instructions, examples, and 304 | recommendations for authors who are considering distributing their 305 | works under this license. These authors are addressed as `you' in 306 | this section. 307 | 308 | Choosing This License or Another License 309 | ---------------------------------------- 310 | 311 | If for any part of your work you want or need to use *distribution* 312 | conditions that differ significantly from those in this license, then 313 | do not refer to this license anywhere in your work but, instead, 314 | distribute your work under a different license. You may use the text 315 | of this license as a model for your own license, but your license 316 | should not refer to the LPPL or otherwise give the impression that 317 | your work is distributed under the LPPL. 318 | 319 | The document `modguide.tex' in the base LaTeX distribution explains 320 | the motivation behind the conditions of this license. It explains, 321 | for example, why distributing LaTeX under the GNU General Public 322 | License (GPL) was considered inappropriate. Even if your work is 323 | unrelated to LaTeX, the discussion in `modguide.tex' may still be 324 | relevant, and authors intending to distribute their works under any 325 | license are encouraged to read it. 326 | 327 | A Recommendation on Modification Without Distribution 328 | ----------------------------------------------------- 329 | 330 | It is wise never to modify a component of the Work, even for your own 331 | personal use, without also meeting the above conditions for 332 | distributing the modified component. While you might intend that such 333 | modifications will never be distributed, often this will happen by 334 | accident -- you may forget that you have modified that component; or 335 | it may not occur to you when allowing others to access the modified 336 | version that you are thus distributing it and violating the conditions 337 | of this license in ways that could have legal implications and, worse, 338 | cause problems for the community. It is therefore usually in your 339 | best interest to keep your copy of the Work identical with the public 340 | one. Many works provide ways to control the behavior of that work 341 | without altering any of its licensed components. 342 | 343 | How to Use This License 344 | ----------------------- 345 | 346 | To use this license, place in each of the components of your work both 347 | an explicit copyright notice including your name and the year the work 348 | was authored and/or last substantially modified. Include also a 349 | statement that the distribution and/or modification of that 350 | component is constrained by the conditions in this license. 351 | 352 | Here is an example of such a notice and statement: 353 | 354 | %% pig.dtx 355 | %% Copyright 2005 M. Y. Name 356 | % 357 | % This work may be distributed and/or modified under the 358 | % conditions of the LaTeX Project Public License, either version 1.3 359 | % of this license or (at your option) any later version. 360 | % The latest version of this license is in 361 | % http://www.latex-project.org/lppl.txt 362 | % and version 1.3 or later is part of all distributions of LaTeX 363 | % version 2005/12/01 or later. 364 | % 365 | % This work has the LPPL maintenance status `maintained'. 366 | % 367 | % The Current Maintainer of this work is M. Y. Name. 368 | % 369 | % This work consists of the files pig.dtx and pig.ins 370 | % and the derived file pig.sty. 371 | 372 | Given such a notice and statement in a file, the conditions 373 | given in this license document would apply, with the `Work' referring 374 | to the three files `pig.dtx', `pig.ins', and `pig.sty' (the last being 375 | generated from `pig.dtx' using `pig.ins'), the `Base Interpreter' 376 | referring to any `LaTeX-Format', and both `Copyright Holder' and 377 | `Current Maintainer' referring to the person `M. Y. Name'. 378 | 379 | If you do not want the Maintenance section of LPPL to apply to your 380 | Work, change `maintained' above into `author-maintained'. 381 | However, we recommend that you use `maintained', as the Maintenance 382 | section was added in order to ensure that your Work remains useful to 383 | the community even when you can no longer maintain and support it 384 | yourself. 385 | 386 | Derived Works That Are Not Replacements 387 | --------------------------------------- 388 | 389 | Several clauses of the LPPL specify means to provide reliability and 390 | stability for the user community. They therefore concern themselves 391 | with the case that a Derived Work is intended to be used as a 392 | (compatible or incompatible) replacement of the original Work. If 393 | this is not the case (e.g., if a few lines of code are reused for a 394 | completely different task), then clauses 6b and 6d shall not apply. 395 | 396 | 397 | Important Recommendations 398 | ------------------------- 399 | 400 | Defining What Constitutes the Work 401 | 402 | The LPPL requires that distributions of the Work contain all the 403 | files of the Work. It is therefore important that you provide a 404 | way for the licensee to determine which files constitute the Work. 405 | This could, for example, be achieved by explicitly listing all the 406 | files of the Work near the copyright notice of each file or by 407 | using a line such as: 408 | 409 | % This work consists of all files listed in manifest.txt. 410 | 411 | in that place. In the absence of an unequivocal list it might be 412 | impossible for the licensee to determine what is considered by you 413 | to comprise the Work and, in such a case, the licensee would be 414 | entitled to make reasonable conjectures as to which files comprise 415 | the Work. 416 | 417 | -------------------------------------------------------------------------------- /Makefile: -------------------------------------------------------------------------------- 1 | # microtype makefile 2 | 3 | SHELL = /bin/sh 4 | .SUFFIXES: 5 | 6 | # path 7 | # (adapt to your needs) 8 | ARCH := x86_64-darwinlegacy 9 | COMPAT := $(shell which tlmgr | sed 's/.*\/\(.*\)\/bin\/.*/\1/') 10 | ifeq ($(shell expr $(COMPAT) \< 2021 ),1) 11 | ARCH := x86_64-darwin 12 | endif 13 | ifeq ($(shell expr $(COMPAT) \< 2014 ),1) 14 | ARCH := universal-darwin 15 | endif 16 | TLPATH := ~/Library/texlive/$(COMPAT)/bin/$(ARCH) 17 | 18 | ifdef DEV 19 | override DEV=-dev 20 | endif 21 | 22 | TESTDIR = ./testsuite 23 | WORDCOUNT = ~/texmf/scripts/wordcount/wordcount.sh 24 | # Redefine to print output: 25 | REDIRECT = > /dev/null 26 | 27 | help: 28 | @echo 'microtype makefile targets:' 29 | @echo ' ' 30 | @echo ' help - (this message)' 31 | @echo ' unpack - extract all files' 32 | @echo ' doc - compile user and code documentation' 33 | @echo ' userdoc - compile user documentation' 34 | @echo ' ctan - generate archive for CTAN' 35 | @echo ' all - unpack & doc' 36 | @echo ' world - all & ctan' 37 | @echo ' mostlyclean - remove all intermediary files' 38 | @echo ' clean - remove all generated and built files' 39 | @echo ' tag - edit tags (v=VERSION d=DATE, both optional)' 40 | @echo ' manifest - print file list' 41 | @echo ' ' 42 | @echo ' install - install the complete package into your home texmf tree' 43 | @echo ' sty-install - install the package code only' 44 | @echo ' install TEXMFROOT= - install the package into the path ' 45 | @echo ' ' 46 | @echo ' test - run the test suite' 47 | @echo ' testerrors - ... or a' 48 | @echo ' testunknown - ... part' 49 | @echo ' testoutput - ... of it' 50 | @echo ' test... COMPAT= - test with other TeX Live release' 51 | @echo ' test... DEV=1 - test with development version' 52 | 53 | NAME = microtype 54 | NAMEC = $(NAME)-code 55 | NAMEU = $(NAME)-utf 56 | DOC = $(NAME).pdf 57 | CODEDOC = $(NAMEC).pdf 58 | UTFDOC = $(NAMEU).pdf 59 | INS = $(NAME).ins 60 | DTX = $(NAME).dtx 61 | UTFDTX = $(NAMEU).dtx 62 | ALLDTX = $(DTX) $(UTFDTX) 63 | README = README.md 64 | DEPENDS = DEPENDS.txt 65 | 66 | # Files grouped by generation mode 67 | COMPILED = $(DOC) $(CODEDOC) 68 | UNPACKED = microtype.sty letterspace.sty microtype.lua microtype.cfg \ 69 | microtype-pdftex.def microtype-luatex.def microtype-xetex.def \ 70 | mt-bch.cfg mt-blg.cfg mt-cmr.cfg mt-euf.cfg mt-eur.cfg mt-eus.cfg \ 71 | mt-msa.cfg mt-msb.cfg mt-EBGaramond.cfg mt-ppl.cfg mt-pmn.cfg mt-ptm.cfg \ 72 | mt-ugm.cfg mt-mvs.cfg mt-zpeu.cfg \ 73 | mt-CharisSIL.cfg mt-LatinModernRoman.cfg mt-NewComputerModern.cfg mt-Palatino.cfg \ 74 | mt-TU-basic.cfg mt-TU-empty.cfg \ 75 | microtype-show.sty test-microtype.tex 76 | SOURCE = $(ALLDTX) $(INS) $(README) $(DEPENDS) 77 | GENERATED = $(UNPACKED) $(COMPILED) 78 | 79 | CTAN_FILES = $(SOURCE) $(COMPILED) 80 | 81 | # Files grouped by installation location 82 | UNPACKED_DOC = test-microtype.tex 83 | RUNFILES = $(filter-out $(UNPACKED_DOC), $(UNPACKED)) 84 | DOCFILES = $(COMPILED) $(UNPACKED_DOC) $(README) $(DEPENDS) 85 | SRCFILES = $(ALLDTX) $(INS) 86 | 87 | ALL_FILES = $(RUNFILES) $(DOCFILES) $(SRCFILES) 88 | 89 | # Installation locations 90 | FORMAT = latex 91 | RUNDIR = $(TEXMFROOT)/tex/$(FORMAT)/$(NAME) 92 | DOCDIR = $(TEXMFROOT)/doc/$(FORMAT)/$(NAME) 93 | SRCDIR = $(TEXMFROOT)/source/$(FORMAT)/$(NAME) 94 | TEXMFROOT = $(shell kpsewhich --var-value TEXMFHOME) 95 | 96 | CTAN_ZIP = $(NAME).zip 97 | TDS_ZIP = $(NAME).tds.zip 98 | ZIPS = $(CTAN_ZIP) $(TDS_ZIP) 99 | 100 | DO_PDFLATEX_DOC = pdflatex$(DEV) --interaction=nonstopmode $(DTX) $(REDIRECT) 101 | DO_PDFLATEX_CODE = pdflatex$(DEV) --jobname=$(NAMEC) --interaction=nonstopmode $(DTX) $(REDIRECT) || \ 102 | if ! grep -i '* Checksum passed *' $(NAMEC).log > /dev/null ; then \ 103 | if grep 'has no checksum\|Checksum not passed' $(NAMEC).log ; then \ 104 | false ; \ 105 | fi ; \ 106 | fi 107 | DO_LUALATEX = lualatex$(DEV) --interaction=nonstopmode $(UTFDTX) $(REDIRECT) 108 | DO_MAKEINDEX_DOC = \ 109 | makeindex -s microtype-gind.ist -t $(NAME).ilg -o $(NAME).ind $(NAME).idx $(REDIRECT) 2>&1 && \ 110 | echo "Creating user index" 111 | DO_MAKEINDEX_CODE = \ 112 | makeindex -r -s microtype-gind.ist -t $(NAMEC).ilg -o $(NAMEC).ind \ 113 | $(NAME).idx $(NAMEC).idx $(NAMEU).idx $(NAME).cdx $(REDIRECT) 2>&1 && \ 114 | makeindex -s gglo.ist -t $(NAMEC).glg -o $(NAMEC).gls \ 115 | $(NAME).glo $(NAMEC).glo $(NAMEU).glo $(REDIRECT) 2>&1 && \ 116 | echo "Creating code index" 117 | 118 | all: $(GENERATED) 119 | doc: $(COMPILED) 120 | userdoc: $(DOC) 121 | unpack: $(UNPACKED) 122 | ctan: $(CTAN_ZIP) 123 | tds: $(TDS_ZIP) 124 | world: all ctan 125 | 126 | .PHONY: help install sty-install manifest mostlyclean clean \ 127 | test testerrors testunknown testoutput 128 | 129 | # for the documentation we need the debug version of microtype.sty 130 | # as well as microtype-doc.sty and microtype-gind.ist 131 | make-doc-sty: $(INS) $(DTX) docstrip.cfg 132 | @echo "Creating doc sty" 133 | @sed -i '' '/\\def\\DEBUG/s/^%//' $< 134 | @sed -i '' '/microtype-gind/s/^%//' $< 135 | @sed -i '' '/microtype-doc/s/^%//' $< 136 | @pdflatex --interaction=nonstopmode $< $(REDIRECT) 137 | @touch make-doc-sty 138 | @rm -f make-normal-sty 139 | 140 | # undo 141 | make-normal-sty: $(INS) $(DTX) docstrip.cfg 142 | @echo "Creating normal sty" 143 | @sed -i '' '/\\def\\DEBUG/s/^\\/%\\/' $< 144 | @sed -i '' '/microtype-doc/s/^\\/%\\/' $< 145 | @sed -i '' '/microtype-gind/s/^\\/%\\/' $< 146 | @pdflatex --interaction=nonstopmode $< $(REDIRECT) 147 | @touch make-normal-sty 148 | @rm -f make-doc-sty 149 | 150 | RERUN_STR = 'Rerun to get \|pdfTeX warning (dest)' 151 | 152 | define rerun-check 153 | @while `grep $(RERUN_STR) $(NAMEU).log > /dev/null` ; do \ 154 | echo "Re-compiling Unicode documentation" ; \ 155 | $(DO_LUALATEX) ; \ 156 | done 157 | @while `grep $(RERUN_STR) $(NAMEC).log > /dev/null` ; do \ 158 | shasum $(NAME).glo $(NAMEC).glo $(NAMEU).glo $(NAME).idx $(NAMEC).idx $(NAMEU).idx $(NAME).cdx > $(NAMEC)-stamp2 ; \ 159 | if cmp -s $(NAMEC)-stamp2 $(NAMEC)-stamp; then rm $(NAMEC)-stamp2; \ 160 | else mv -f $(NAMEC)-stamp2 $(NAMEC)-stamp; $(DO_MAKEINDEX_CODE); fi ; \ 161 | echo "Re-compiling code documentation" ; \ 162 | $(DO_PDFLATEX_CODE) ; \ 163 | shasum $(NAME).idx > $(NAME)-stamp2 ; \ 164 | if cmp -s $(NAME)-stamp2 $(NAME)-stamp; then rm $(NAME)-stamp2; \ 165 | else mv -f $(NAME)-stamp2 $(NAME)-stamp; $(DO_MAKEINDEX_DOC); fi ; \ 166 | echo "Re-compiling user documentation" ; \ 167 | $(DO_PDFLATEX_DOC) ; \ 168 | done 169 | @while `grep $(RERUN_STR) $(NAME).log > /dev/null` ; do \ 170 | shasum $(NAME).idx > $(NAME)-stamp2 ; \ 171 | if cmp -s $(NAME)-stamp2 $(NAME)-stamp; then rm $(NAME)-stamp2; \ 172 | else mv -f $(NAME)-stamp2 $(NAME)-stamp; $(DO_MAKEINDEX_DOC); fi ; \ 173 | echo "Re-compiling user documentation" ; \ 174 | $(DO_PDFLATEX_DOC) ; \ 175 | done 176 | endef 177 | 178 | $(DOC): make-doc-sty $(DTX) $(NAME).ind 179 | @if `grep $(RERUN_STR) $(NAME).log > /dev/null` ; then \ 180 | echo "Re-compiling user documentation" ; \ 181 | $(DO_PDFLATEX_DOC) ; \ 182 | fi 183 | 184 | $(CODEDOC): make-doc-sty $(DTX) $(UTFDOC) $(NAMEC).gls $(NAMEC).ind 185 | @echo "Compiling code documentation (including Unicode part)" 186 | @$(DO_PDFLATEX_CODE) 187 | $(rerun-check) 188 | 189 | $(UTFDOC): make-doc-sty $(UTFDTX) $(NAMEC).tmp 190 | @echo "Compiling Unicode documentation" 191 | @$(DO_LUALATEX) 192 | @if `grep $(RERUN_STR) $(NAMEU).log > /dev/null` ; then \ 193 | echo "Re-compiling Unicode documentation" ; \ 194 | $(DO_LUALATEX) ; \ 195 | fi 196 | 197 | $(NAME).idx: $(DTX) 198 | @echo "Compiling user documentation (idx)" 199 | @$(DO_PDFLATEX_DOC) 200 | 201 | $(NAME).ind: $(NAME)-stamp 202 | @$(DO_MAKEINDEX_DOC) 203 | 204 | $(NAME)-stamp: $(NAME).idx 205 | @shasum $^ > $@2 206 | @if cmp -s $@2 $@; then rm $@2; else mv -f $@2 $@; fi 207 | 208 | $(NAMEC).idx $(NAMEC).glo: $(DTX) 209 | @echo "Compiling code documentation (idx,glo)" 210 | @$(DO_PDFLATEX_CODE) 211 | 212 | $(NAMEC).ind $(NAMEC).gls: $(NAMEC)-stamp 213 | @$(DO_MAKEINDEX_CODE) 214 | 215 | $(NAMEC)-stamp: $(NAME).glo $(NAMEC).glo $(NAMEU).glo $(NAME).idx $(NAMEC).idx $(NAMEU).idx $(NAME).cdx 216 | @shasum $^ > $@2 217 | @if cmp -s $@2 $@; then rm $@2; else mv -f $@2 $@; fi 218 | 219 | # microtype-code.tmp is used to communicate counters 220 | # from microtype.dtx (code) to microtype-utf.dtx 221 | $(NAMEC).tmp: 222 | @echo "Compiling code documentation (for Unicode part)" 223 | @$(DO_PDFLATEX_CODE) 224 | @if `grep $(RERUN_STR) $(NAMEC).log > /dev/null` ; then \ 225 | $(DO_MAKEINDEX_CODE) ; \ 226 | echo "Re-compiling code documentation (for Unicode part)" ; \ 227 | $(DO_PDFLATEX_CODE) ; \ 228 | fi 229 | 230 | $(UNPACKED): $(INS) $(DTX) $(UTFDTX) docstrip.cfg 231 | @echo "Extracting package" 232 | @pdflatex $< $(REDIRECT) 233 | @if test ! -f $@ ; then \ 234 | echo "!! $@ not created!" ; \ 235 | false ; \ 236 | fi 237 | 238 | docstrip.cfg: 239 | @echo "\\\\askforoverwritefalse" > docstrip.cfg 240 | 241 | $(CTAN_ZIP): manifest doc $(CTAN_FILES) $(TDS_ZIP) 242 | @echo "Making $@ for CTAN upload." 243 | @$(RM) -- $@ 244 | @mkdir -p ./$(NAME) 245 | @cp $(CTAN_FILES) ./$(NAME) 246 | @zip -9 -r $@ ./$(NAME) $(TDS_ZIP) $(REDIRECT) 247 | @$(RM) -r ./$(NAME) 248 | @unzip -l $@ 249 | 250 | define run-install 251 | @mkdir -p $(RUNDIR) && cp $(RUNFILES) $(RUNDIR) 252 | @mkdir -p $(DOCDIR) && cp $(DOCFILES) $(DOCDIR) 253 | @mkdir -p $(SRCDIR) && cp $(SRCFILES) $(SRCDIR) 254 | endef 255 | 256 | define run-sty-install 257 | @mkdir -p $(RUNDIR) && cp $(RUNFILES) $(RUNDIR) 258 | endef 259 | 260 | $(TDS_ZIP): TEXMFROOT=./tmp-texmf 261 | $(TDS_ZIP): make-normal-sty $(ALL_FILES) 262 | @echo "Making TDS-ready archive $@." 263 | @$(RM) -- $@ 264 | $(run-install) 265 | @cd $(TEXMFROOT) && zip -9 ../$@ -r . $(REDIRECT) 266 | @$(RM) -r -- $(TEXMFROOT) 267 | 268 | install: doc $(ALL_FILES) 269 | @if test ! -n "$(TEXMFROOT)" ; then \ 270 | echo "Cannot locate your home texmf tree. Specify manually with\n\n make install TEXMFROOT=/path/to/texmf\n" ; \ 271 | false ; \ 272 | fi ; 273 | @echo "Installing in '$(TEXMFROOT)'." 274 | $(run-install) 275 | 276 | sty-install: $(RUNFILES) 277 | @if test ! -n "$(TEXMFROOT)" ; then \ 278 | echo "Cannot locate your home texmf tree. Specify manually with\n\n make install TEXMFROOT=/path/to/texmf\n" ; \ 279 | false ; \ 280 | fi ; 281 | @echo "Installing in '$(TEXMFROOT)'." 282 | $(run-sty-install) 283 | 284 | tag: $(ALLDTX) $(README) 285 | @if test ! -n "$(v)" ; then \ 286 | v="$(shell LANG=C && \ 287 | sed -n '/%<\*package|letterspace|m-t|pdf-|lua-|xe-|show>$$/{N;s/.*\[.* v\(.*\)$$/\1/p;}' $(DTX))" ; \ 288 | echo "Version not set .. using current one ($$v)" ; \ 289 | fi ; \ 290 | if test ! -n "$(d)" ; then \ 291 | d="$(shell date '+%Y/%m/%d')" ; \ 292 | echo "Date not set .. using today ($$d)" ; \ 293 | fi ; \ 294 | echo "Tagging: $$v -- $$d" ; \ 295 | LANG=C && \ 296 | sed -i '' -e "/^%<\*package|letterspace|m-t|pdf-|lua-|xe-|show>$$/{N;s:\( *\[\).* .*$$:\1$$d v$$v:;}" \ 297 | -e "s:\(% *version *= \)\".*\":\1\"$$v\":" \ 298 | -e "s:\(% *date *= \)\".*\":\1\"$$d\":" $(DTX) && \ 299 | sed -i '' -e "/^%<\*driver>$$/{N;s:\[.* v.*\]$$:\[$$d v$$v\]:;}" $(UTFDTX) && \ 300 | sed -i '' -e "s:^ (v.* -- .*)$$: (v$$v -- $$d):" $(README) ; 301 | 302 | manifest: $(SOURCE) 303 | @echo "=== Source files ===" 304 | @LANG=C && sed -n '/%<\*package|letterspace|m-t|pdf-|lua-|xe-|show>$$/{N;s/.*\[\(.*\)$$/-- \1 ($(DTX))/p;}' $(DTX) 305 | @LANG=C && sed -n '/ *version *= *.*$$/{N;s/^.*= *"\(.*\)",.*date *= *"\(.*\)",/ (\2 v\1 (microtype.lua))/p;}' $(DTX) 306 | @sed -n '/%<\*driver>$$/{N;/{\\jobname\.dtx}/ s/^.*\[\(.*\)\]$$/-- \1 ($(UTFDTX))/p;}' $(UTFDTX) 307 | @sed -n 's/^ *(\(v[^ ]*\) *-- *\([^ ]*\))$$/-- \2 \1 ($(README))/p' $(README) 308 | @echo "" 309 | @echo "=== Derived files ===" 310 | @for f in $(UNPACKED); do echo "$$f"; done 311 | @echo "----------------------------" 312 | @if grep '\-\-'`date -v-1y +%Y` $(SOURCE); then echo "!!!! Copyright strings not up to date !!!!" ; fi 313 | 314 | mostlyclean: 315 | @$(RM) -- *.log *.aux *.toc *.idx *.cdx *.ind *.ilg *.glo *.gls *.glg *.lof *.lot *.out *.synctex* *.tmp *.pl *.mtx \ 316 | docstrip.cfg $(UTFDOC) microtype-doc.sty microtype-gind.ist make-*-sty *-stamp 317 | 318 | clean: mostlyclean 319 | @$(RM) -- $(GENERATED) $(ZIPS) 320 | 321 | # testing the package 322 | 323 | test: testerrors testunknown testoutput 324 | @$(RM) $(TESTDIR)/*.log 325 | @$(RM) $(TESTDIR)/*.aux 326 | @$(RM) $(TESTDIR)/*.pdf 327 | @$(RM) $(TESTDIR)/*.tmp 328 | @$(RM) $(TESTDIR)/*.out 329 | @$(RM) $(TESTDIR)/*.4ct 330 | @$(RM) $(TESTDIR)/*.4tc 331 | @$(RM) $(TESTDIR)/*.dvi 332 | @$(RM) $(TESTDIR)/*.xref 333 | # @$(RM) $(TESTDIR)/*.1 334 | # @$(RM) $(TESTDIR)/*.1R 335 | @$(RM) $(TESTDIR)/*.pgf 336 | @$(RM) $(TESTDIR)/*.toc 337 | @$(RM) $(TESTDIR)/*.nav 338 | @$(RM) $(TESTDIR)/*.snm 339 | @$(RM) $(TESTDIR)/*.hd 340 | @$(RM) $(TESTDIR)/*.bcf 341 | @$(RM) $(TESTDIR)/*.run.xml 342 | @$(RM) $(TESTDIR)/*.cb 343 | @$(RM) $(TESTDIR)/*.cb2 344 | 345 | testerrors: $(wildcard $(TESTDIR)/error-*.tex) 346 | @echo "* Errors:" 347 | @cd $(TESTDIR) && \ 348 | $(foreach file,$^,$(call run-test-file,error,$(notdir $(basename $(file))))) 349 | @echo " - wordcount" 350 | @cd $(TESTDIR) && \ 351 | if ! `$(WORDCOUNT) errorx-wordcount > /dev/null` ; \ 352 | then $(not-ok) ; \ 353 | fi 354 | 355 | testunknown: $(wildcard $(TESTDIR)/unknown-*.tex) 356 | @echo "* Unknown slots:" 357 | @cd $(TESTDIR) && \ 358 | $(foreach file,$^,$(call run-unknown-file,$(notdir $(basename $(file))))) 359 | 360 | testoutput: $(wildcard $(TESTDIR)/output-*.tex) 361 | @echo "* Output:" 362 | @cd $(TESTDIR) && \ 363 | $(foreach file,$^,$(call run-output-file,$(notdir $(basename $(file))))) 364 | 365 | # parts of the filename after `_' signify an engine other than pdflatex 366 | run-test-file = \ 367 | echo " - $(subst $1-,,$2)" | sed 's/\(.*\)_\(.*\)/\1 (\2)/' ; \ 368 | if ! `$(if $(shell echo $2 | grep _),\ 369 | $(TLPATH)/$(shell echo $2 | sed -n 's/.*_\(.*\)/\1/p' | sed -e '/latex/s/$$/$(DEV)/'),\ 370 | $(TLPATH)/pdflatex$(DEV)) --interaction=batchmode $2 > /dev/null` ; \ 371 | then $(not-ok) ; \ 372 | fi ; 373 | 374 | # there mustn't be unknown slots 375 | run-unknown-file = \ 376 | $(call run-test-file,unknown,$1) \ 377 | if `grep 'Unknown slot number' $1.log > /dev/null` ; \ 378 | then $(not-ok) ; \ 379 | fi ; 380 | 381 | # the test files themselves contain the relevant grep command 382 | run-output-file = \ 383 | $(call run-test-file,output,$1) \ 384 | if ! $$(eval $$(grep grep $1.tex) $1.log > /dev/null) ; \ 385 | then $(not-ok) ; \ 386 | fi ; 387 | 388 | not-ok = echo " ... NOT OK !!! <-------" 389 | 390 | -------------------------------------------------------------------------------- /README.md: -------------------------------------------------------------------------------- 1 | 2 | The `microtype` package 3 | ======================= 4 | 5 | **Subliminal refinements towards typographical perfection** 6 | 7 | (v3.2a -- 2025/02/11) 8 | 9 | 10 | Overview 11 | -------- 12 | 13 | The `microtype` package provides a LaTeX interface to the micro-typographic 14 | extensions that were introduced by pdfTeX and some of which have since also 15 | propagated to LuaTeX and XeTeX: most prominently, character protrusion and 16 | font expansion, furthermore the adjustment of interword spacing and additional 17 | kerning, as well as hyphenatable letterspacing (tracking) and the possibility 18 | to disable all or selected ligatures. 19 | 20 | These features may be applied to customisable sets of fonts, and all 21 | micro-typographic aspects of the fonts can be configured in a straight-forward 22 | and flexible way. Settings for various fonts are provided. 23 | 24 | *Note that character protrusion requires pdfTeX (version 0.14f or later), 25 | LuaTeX, or XeTeX (at least version 0.9997). Font expansion works with pdfTeX 26 | (version 1.20 for automatic expansion) or LuaTeX. The package will by default 27 | enable protrusion and expansion if they can safely be assumed to work. 28 | Disabling ligatures requires pdfTeX (at least version 1.30) or LuaTeX, while 29 | the adjustment of interword spacing and of kerning only works with pdfTeX 30 | (at least 1.40). Letterspacing is available with pdfTeX (1.40), LuaTeX (0.62) 31 | or XeTeX.* 32 | 33 | The alternative package `letterspace`, which also works with plain TeX, 34 | provides the user commands for letterspacing only, omitting support for all 35 | other extensions. 36 | 37 | The documentation can be found in `microtype.pdf` (User manual) and 38 | `microtype-code.pdf` (Implementation). 39 | 40 | 41 | Installation 42 | ------------ 43 | 44 | To install the package, use one of the following methods 45 | (in decreasing order of simplicity): 46 | 47 | - Use the package manager of your TeX system 48 | (TeXLive: `tlmgr install microtype`; 49 | MiKTeX: MiKTeX Package Manager). 50 | 51 | - Download `microtype.tds.zip` from CTAN, 52 | extract it in the root of one of your TDS trees, 53 | and update the filename database. 54 | 55 | - Get the source (`microtype.zip`) from CTAN and extract it, 56 | run `latex` on `microtype.ins` to generate the package and configuration files, 57 | and move all generated files into a directory where LaTeX will find them, 58 | e.g., `TEXMF/tex/latex/microtype/`. 59 | 60 | - To use the latest development version, clone the github repository at 61 | `https://github.com/schlcht/microtype` and run `make` 62 | (or just `latex microtype.ins` to generate the run files). 63 | 64 | 65 | License 66 | ------- 67 | 68 | This work may be distributed and/or modified under the conditions of the 69 | LaTeX Project Public License, either version 1.3c of this license or (at 70 | your option) any later version. The latest version of this license is in: 71 | https://www.latex-project.org/lppl.txt, and version 1.3c or later is part 72 | of all distributions of LaTeX version 2005/12/01 or later. 73 | 74 | This work has the LPPL maintenance status 'maintained'. 75 | 76 | This work consists of the files `microtype.dtx`, `microtype-utf.dtx` and 77 | `microtype.ins` and the derived files `microtype.sty`, `microtype-pdftex.def`, 78 | `microtype-luatex.def`, `microtype-xetex.def`, `microtype.lua`, `letterspace.sty` 79 | and `microtype-show.sty`. 80 | 81 | Modified versions of the configuration files (`*.cfg`) may be distributed 82 | provided that: (1) the original copyright statement is not removed, and 83 | (2) the identification string is changed. 84 | 85 | ------------------------------------------------------ 86 | Copyright (c) 2004--2025 R Schlicht `` 87 | -------------------------------------------------------------------------------- /TODO: -------------------------------------------------------------------------------- 1 | * update CTAN blurb 2 | * fix spacing in tracking with XeTeX 3 | * make microtype-show work with xetex 4 | * different md* (etc.) for different fonts 5 | * check contexts in lua again -> contexts 6 | * luatex: reimplement spacing feature (see https://tex.stackexchange.com/questions/498032/how-do-i-define-a-new-tex-register-with-arguments-in-luatex) 7 | * end of \MT@tr@set@space@@: ? 8 | %% \MT@if@fontspec@font{\advance\@tempdima \dimexpr\MT@letterspace@ sp*\MT@dimen@six/1000\relax}\relax 9 | * what to do about lualatex -ini ? 10 | * fix (outer) spacing with luatex 11 | --- 12 | % from Vadim Radionov <@> 13 | % http://tex.stackexchange.com/questions/149165/microtype-and-word-spacing 14 | % 2013/12/10 15 | we have to take \fontdimens from \MT@font, not \MT@lsfont (in tr@set@space...) 16 | and we must check whether \spaceskip<>0pt 17 | --- 18 | * expansion settings for luatex 19 | * "override" key? (could also automatically load the relevant file) 20 | * let scrubfeatures relax (splitname) 21 | --- 22 | * add this to microtype.ins? -: 23 | ---------------------------------- 24 | % Extracting the Unicode files requires latex, pdf(la)tex, or xe(la)tex, 25 | % and won't work with tex or lua(la)tex 26 | \def\quit{\errmessage{Run latex, pdf(la)tex, or xe(la)tex to extract the files.^^J% 27 | ! I will quit now}\end} 28 | \let\wrongengine\relax 29 | \ifx\luatexversion\undefined 30 | \ifx\pdftexversion\undefined 31 | \ifx\XeTeXversion\undefined 32 | \def\format{plain} 33 | \ifx\fmtname\format 34 | \let\wrongengine\quit 35 | \fi 36 | \fi 37 | \fi 38 | \else 39 | \let\wrongengine\quit 40 | \fi 41 | \wrongengine 42 | 43 | -------------------------------------------------------------------------------- /microtype-logo.dtx: -------------------------------------------------------------------------------- 1 | % 2 | \ProvidesFile{microtype-logo.dtx}[2009/06/08] 3 | % 4 | % ^^A don't count the backslashes in this document 5 | %\makeatletter 6 | %\let\orig@step@checksum\step@checksum 7 | %\let\step@checksum\relax 8 | %\makeatother 9 | % 10 | % \section{The title logo} 11 | % \label{sec:title-logo} 12 | % 13 | %^^A\iffalse meta-comment 14 | % ^^A ======================================================================== 15 | % This is \file{microtype-logo.dtx}. 16 | % You may treat this file in three different ways: 17 | %\begin{itemize} 18 | % \item compile it by itself 19 | % \item \verb|\input| it in the body of a \file{dtx} file 20 | % \item \verb|\input| it in the preamble: it then provides the command 21 | % \verb|\printlogo|, which will do just that 22 | %\end{itemize} 23 | % The first two cases require the style file \file{microtype-doc.sty}, which can 24 | % be generated from \file{microtype.ins} with: 25 | %\begin{verbatim} 26 | %\makefile{microtype-doc.sty}{docsty} 27 | %\end{verbatim} 28 | % ^^A ======================================================================== 29 | %^^A\fi 30 | % 31 | % \begin{macrocode} 32 | %<*logo> 33 | % \end{macrocode} 34 | % Here's how the logo on the title page was created.\footnote{ 35 | % Note that the |logo| module will not be created when installing 36 | % \microtype. Instead, the source file \file{microtype-logo.dtx} 37 | % is included as an attachment in the \acronym{PDF} file. 38 | % If your \acronym{PDF} reader supports this, you can 39 | % \textattachfile 40 | % [color={0.02 0.04 0.48},mimetype=text/plain]{microtype-logo.dtx} 41 | % {click here} 42 | % to extract it; alternatively, you may use the |pdftk| tool.} 43 | % It has nothing to do with \microtype, actually, but uses \pkg{fontinst}. It is 44 | % based on an experiment I posted to the \url{de.comp.text.tex} newsgroup.\footnote{ 45 | % Message ID: \nolinkurl{42aa3687$0$24366$9b4e6d93@newsread2.arcor-online.net}} 46 | % It will show: 47 | %\begin{itemize} 48 | % \item the character 49 | % \item the \TeX\ box 50 | % \item the bounding box 51 | % \item kerns 52 | %\end{itemize} 53 | % 54 | % \subsection{Macros} 55 | % 56 | % To run this file, \TeX\ needs to find the \file{afm} file (either in the 57 | % |TEXINPUTS| path, or in the current working directory). 58 | % 59 | % First input \pkg{fontinst}. 60 | % \begin{macrocode} 61 | \input fontinst.sty 62 | % \end{macrocode} 63 | % \file{bbox.sty} is an addition to \pkg{fontinst}, which makes dimensions of 64 | % the bounding boxes available (and was written by \thanh, by the way). These 65 | % dimensions are specified in the \file{afm} file, but not used by \TeX, which 66 | % is why \pkg{fontinst} will discard them otherwise. 67 | % \begin{macrocode} 68 | \input bbox.sty 69 | % \end{macrocode} 70 | %\begin{macro}{\tempdim} 71 | % Allocate some dimen registers. 72 | % \begin{macrocode} 73 | \newdimen\tempdim 74 | % \end{macrocode} 75 | %\end{macro} 76 | %\begin{macro}{\fboxrulei} 77 | % Frame width of the box as \TeX\ sees it. 78 | % \begin{macrocode} 79 | \newdimen\fboxrulei 80 | \fboxrulei=0.1pt 81 | % \end{macrocode} 82 | %\end{macro} 83 | %\begin{macro}{\fboxruleii} 84 | % Frame width of the bounding box. 85 | % \begin{macrocode} 86 | \newdimen\fboxruleii 87 | \fboxruleii=0.1pt 88 | % \end{macrocode} 89 | %\end{macro} 90 | %\begin{macro}{\kernboxheight} 91 | % Height of the box indicating the kern. 92 | % \begin{macrocode} 93 | \newdimen\kernboxheight 94 | \kernboxheight=5pt 95 | % \end{macrocode} 96 | %\end{macro} 97 | %\begin{macro}{\scaletoem} 98 | % An auxiliary macro. Return a dimension relative to the |em|-width of the font. 99 | % Requires \etex. 100 | % \begin{macrocode} 101 | \setcommand\scaletoem#1{\dimexpr #1 sp*\fontdimen6\font/1000\relax} 102 | % \end{macrocode} 103 | %\end{macro} 104 | %\begin{macro}{\showlogo} 105 | % A \pkg{fontinst} incantation whose sole purpose is to produce the logo. 106 | % Its argument is a string (letters only). 107 | % \begin{macrocode} 108 | \fontinstcc 109 | \def\showlogo#1{% 110 | % \end{macrocode} 111 | % Some fonts do not specify the \fontdim6 (width of an |em|) in the |afm| 112 | % file. In this case, use the font size, which is correct in most cases. 113 | % \begin{macrocode} 114 | \ifdim\fontdimen6\font = 0pt 115 | \typeout{***~Warning:~no~fontdimen~6~specified~***^^J% 116 | ***~setting~it~to~\pdffontsize\font \ifnum\pdftexversion < 130 pt\fi~***} 117 | \fontdimen6\font=\pdffontsize\font \ifnum\pdftexversion < 130 pt\fi\relax 118 | \fi 119 | \installfonts 120 | \input_metrics{}{\logofont,\metrics\printbbs{#1}\relax} 121 | \endinstallfonts 122 | } 123 | \normalcc 124 | % \end{macrocode} 125 | %\end{macro} 126 | % Layers. 127 | % \begin{macrocode} 128 | \makeatletter 129 | \def\mtl@layer#1#2{\pdfliteral{/OC/#1 BDC}#2\pdfliteral{EMC}} 130 | \ifx\mt@objects\@undefined\let\mt@objects\@empty\fi 131 | \ifx\mt@order \@undefined\let\mt@order \@empty\fi 132 | \xdef\mt@order{\mt@order[(Logo)} 133 | \let\mtl@resources\@empty 134 | \def\mtl@register#1{% 135 | \immediate\pdfobj{<< /Type/OCG /Name(#1) >>} 136 | \expandafter\xdef\csname mtl@#1\endcsname{\the\pdflastobj\space 0 R } 137 | \xdef\mt@objects{\mt@objects\csname mtl@#1\endcsname} 138 | \xdef\mt@order{\mt@order\csname mtl@#1\endcsname} 139 | \xdef\mtl@resources{\mtl@resources/#1 \csname mtl@#1\endcsname}} 140 | \mtl@register{canvas} 141 | \mtl@register{characters} 142 | \mtl@register{bounding-boxes} 143 | \mtl@register{TeX-boxes} 144 | \xdef\mt@order{\mt@order]} 145 | \global\let\mtl@objects\mt@objects 146 | \def\togglelayer#1#2{% 147 | \pdfstartlink width \wd\logobox height \ht\logobox depth \dp\logobox 148 | user{/Subtype/Link 149 | /BS << /Type/Border/W 0 >> /H/O 150 | /A << /S/SetOCGState 151 | /State[/Toggle \csname mtl@#1\endcsname] >> 152 | }#2\pdfendlink 153 | } 154 | % \end{macrocode} 155 | %\begin{macro}{\printbbs} 156 | % Preparation. 157 | % \begin{macrocode} 158 | \setcommand\printbbs#1{% 159 | \setbox0\hbox{#1}% 160 | \leavevmode 161 | \kern-\fboxrulei 162 | % \end{macrocode} 163 | % The canvas in the natural width of the text minus protrusion, in color 164 | % |bgcolor|. 165 | % \begin{macrocode} 166 | \mtl@layer{canvas}{% 167 | \getboundarychars#1\relax 168 | \tempdim=\dimexpr\wd0 - (\scaletoem{\lpcode\font\firstchar}+ 169 | \scaletoem{\rpcode\font\lastchar})\relax 170 | \kern\dimexpr\scaletoem{\lpcode\font\firstchar}\relax 171 | \lower\dimexpr\dp0+0.05em \relax \vbox{\color{bgcolor}% 172 | \hrule width \tempdim 173 | height \dimexpr\dp0+\ht0+0.15em\relax}% 174 | \kern-\tempdim 175 | % \end{macrocode} 176 | % The baseline, in color |blcolor|. 177 | % \begin{macrocode} 178 | \vbox{\color{blcolor}% 179 | \hrule width \tempdim 180 | height \fboxrulei}% 181 | }% 182 | \kern-\dimexpr\wd0 -\scaletoem{\rpcode\font\lastchar}\relax 183 | % \end{macrocode} 184 | % The string. 185 | % \begin{macrocode} 186 | \printbbss #1\relax\relax 187 | } 188 | % \end{macrocode} 189 | %\end{macro} 190 | %\begin{macro}{\getboundarychars} 191 | % Get first~\dots. 192 | % \begin{macrocode} 193 | \def\getboundarychars#1#2\relax{% 194 | \def\firstchar{`#1}% 195 | \getlastchar#1#2\relax 196 | } 197 | % \end{macrocode} 198 | %\end{macro} 199 | %\begin{macro}{\getlastchar} 200 | % \dots~and last character. 201 | % \begin{macrocode} 202 | \def\getlastchar#1#2{% 203 | \ifx\relax#2\relax 204 | \def\lastchar{`#1}% 205 | \else 206 | \expandafter\getlastchar 207 | \fi #2% 208 | } 209 | % \end{macrocode} 210 | %\end{macro} 211 | %\begin{macro}{\printbbss} 212 | % Loop over all characters of the string. 213 | % \begin{macrocode} 214 | \def\printbbss#1#2#3\relax{% 215 | \ifx\relax#1\relax 216 | \else 217 | \ifx\relax#2\relax 218 | \printbb{#1}{}% 219 | \else 220 | \printbb{#1}{#2}% 221 | \fi 222 | \expandafter\printbbss 223 | \fi #2#3\relax 224 | } 225 | % \end{macrocode} 226 | %\end{macro} 227 | %\begin{macro}{\printbb} 228 | % Record the kern between the current and the following character, then print the 229 | % character. \cmd{\kerning} is a \pkg{fontinst} command. 230 | % \begin{macrocode} 231 | \setcommand\printbb#1#2{% 232 | \setbox0\hbox{\kerning{#1}{#2}\xdef\thekern{\number\result}}% 233 | \showboxes{#1}% 234 | % \end{macrocode} 235 | % This could be another application. 236 | % \begin{macrocode} 237 | % \quad 238 | % w: \the\scaletoem{\width{#1}}, 239 | % bb: \the\scaletoem{\bbleft{#1}}/% 240 | % \the\scaletoem{\bbright{#1}}, 241 | % \the\scaletoem{\number\numexpr\width{#1}-\bbright{#1}\relax} 242 | % h: \height{#1}/\bbtop{#1}, \bbbottom{#1}/\depth{#1}\par 243 | } 244 | % \end{macrocode} 245 | %\end{macro} 246 | %\begin{macro}{\showboxes} 247 | % Print the boxes for char \meta{\#1}. This won't work if \meta{\#1} isn't 248 | % also the PostScript name of the glyph (\eg, `comma' =\llap{/\,} `,'). 249 | % \begin{macrocode} 250 | \setcommand\showboxes#1{% 251 | \leavevmode 252 | \color{texcolor}% 253 | % \end{macrocode} 254 | % We have to record the width of the glyph. 255 | % \begin{macrocode} 256 | \setbox0\hbox{{\color{textcolor}#1}}% 257 | \global\tempdim=\wd0\relax 258 | \kern-\fboxrulei 259 | % \end{macrocode} 260 | %\begin{enumerate} 261 | %\item \textit{The \TeX\ box:} 262 | % Print a frame in color |texcolor|. This frame shows the glyph as \TeX\ sees 263 | % it. 264 | % \begin{macrocode} 265 | \mtl@layer{TeX-boxes}{% 266 | \hbox{% 267 | \lower\dimexpr \dp0 + \fboxrulei\relax 268 | \hbox{% 269 | \vbox{% 270 | \hrule height\fboxrulei 271 | \hbox{% 272 | \vrule width\fboxrulei height \dimexpr\ht0 + 2\fboxrulei\relax 273 | \phantom{\unhcopy0}% 274 | \vrule width\fboxrulei 275 | }% 276 | \hrule height\fboxrulei}}}% 277 | }% 278 | % \end{macrocode} 279 | %\item \textit{The character:} 280 | % Now we step back and print the actual glyph. We hold it back until now, so 281 | % that it will be printed \emph{on top} of its box. 282 | % \begin{macrocode} 283 | \kern-\wd0 284 | \mtl@layer{characters}{\hbox{\box0}}% 285 | % \end{macrocode} 286 | % Step back by the amount that the character's bounding box differs from the 287 | % \TeX\ box on the left side. 288 | % \begin{macrocode} 289 | \kern\dimexpr\scaletoem{\bbleft{#1}}-\tempdim-\fboxruleii\relax 290 | % \end{macrocode} 291 | %\item \textit{The bounding box:} 292 | % will be printed in color |bbcolor|. 293 | % \begin{macrocode} 294 | \mtl@layer{bounding-boxes}{% 295 | {\color{bbcolor}% 296 | \hbox{% 297 | \lower\dimexpr-\scaletoem{\bbbottom{#1}}+\fboxruleii\relax 298 | \hbox{% 299 | \vbox{% 300 | \hrule height\fboxruleii 301 | \hbox to \dimexpr\scaletoem{\numexpr 302 | \bbright{#1}-\bbleft{#1}\relax}+2\fboxruleii\relax{% 303 | \vrule height \dimexpr\scaletoem{\numexpr 304 | \bbtop{#1}-\bbbottom{#1}\relax}% 305 | width\fboxruleii 306 | \hfill 307 | \vrule width\fboxruleii}% 308 | \hrule height\fboxruleii}}}% 309 | }% 310 | \kern-\dimexpr\fboxruleii+\fboxrulei\relax 311 | }% 312 | % \end{macrocode} 313 | %\item \textit{The kern:} 314 | % We also print a small box in color |kerncolor| indicating the kerning between 315 | % the current and the next character; filled for negative kerns, empty for 316 | % positive kerns. 317 | % \begin{macrocode} 318 | \kern\scaletoem{\numexpr\width{#1}-\bbright{#1}\relax}% 319 | \mtl@layer{TeX-boxes}{% 320 | {\ifnum\thekern<0 321 | \color{kerncolor}% 322 | \kern\scaletoem{\thekern}% 323 | \lower\kernboxheight\hbox{\vrule width -\dimexpr\scaletoem{\thekern}\relax 324 | height \kernboxheight}% 325 | \kern\scaletoem{\thekern}% 326 | \else 327 | \color{texcolor}% 328 | \ifnum\thekern=0 \else 329 | \lower\kernboxheight 330 | \hbox{% 331 | \vbox{% 332 | % \hrule height\fboxrulei 333 | \hbox{% 334 | \vrule height \kernboxheight width\fboxrulei 335 | \kern\dimexpr\scaletoem{\thekern}-2\fboxrulei\relax 336 | \vrule width\fboxrulei 337 | }% 338 | \hrule height\fboxrulei}}% 339 | \fi 340 | \fi 341 | }% 342 | }% 343 | % \kern-\fboxrulei 344 | } 345 | % \end{macrocode} 346 | %\end{enumerate} 347 | %\end{macro} 348 | %\begin{macro}{\printlogo} 349 | % \begin{macrocode} 350 | \newbox\logobox 351 | \def\printlogo{% 352 | \setbox\logobox=\hbox{\vbox{% 353 | \MakePercentComment 354 | % \end{macrocode} 355 | % This is the Kepler MM font used in the logo. 356 | % \begin{macrocode} 357 | \def\logofont{pkpri9e10} 358 | \transformfont{\logofont}{\reencodefont{8r}{\fromafm{pkpmmri8a10}}} 359 | \font\thelogofont=\logofont\space at 82pt 360 | % \end{macrocode} 361 | % This would load the italic Palatino font instead. 362 | % \begin{macrocode} 363 | %\def\logofont{pplri} 364 | %\transformfont{\logofont8r}{\reencodefont{8r}{\fromafm{\logofont8a}}} 365 | %\edef\logofont{\logofont8r} 366 | %\font\thelogofont=\logofont\space at 78pt 367 | % \end{macrocode} 368 | % Load the font. 369 | % \begin{macrocode} 370 | \thelogofont 371 | % \end{macrocode} 372 | % Protrusion values (overdone for didactic reasons). 373 | % \begin{macrocode} 374 | \lpcode\font`M=96 375 | \rpcode\font`e=46 376 | % \end{macrocode} 377 | % Now we can generate the logo. 378 | % \begin{macrocode} 379 | \pdfliteral direct{/SXS gs}% 380 | \showlogo{Microtype}% 381 | % \rlap{\normalfont\normalsize\raisebox{55pt}{\footnotemark[1]}}% 382 | % \kern5pt\\[3\baselineskip] 383 | % \long\def\@makefntext##1{% 384 | % \leftskip 0pt 385 | % \parindent 0pt 386 | % \everypar{\parindent 0pt}% 387 | % \leavevmode\hbox to 15pt{\@thefnmark\hss}##1} 388 | % \footnotetext[1]{This graphic displays on a 389 | % \togglelayer{canvas}{canvas} the \togglelayer{characters}{characters}, 390 | % their \togglelayer{bounding-boxes}{bounding boxes} 391 | % and \togglelayer{TeX-boxes}{\TeX\ boxes}.} 392 | }}% 393 | \edef\logodimens{width \the\wd\logobox height \the\ht\logobox depth \the\dp\logobox} 394 | \immediate\pdfobj{<>}% 395 | \immediate\pdfxform 396 | attr {/Group <>} 397 | resources {/Properties <<\mtl@resources>> 398 | /ExtGState << /SXS \the\pdflastobj\space 0 R >> } 399 | \logobox 400 | % \vskip-2.5\baselineskip 401 | % \leavevmode 402 | % \togglelayer{characters}{% 403 | % \pdfrefxform\pdflastxform 404 | % }% 405 | \pdfannot\logodimens{% 406 | /Subtype/Widget /FT/Btn /T(Logo) 407 | %/F 4 % why did I say this? 408 | /AP << /N \the\pdflastxform\space 0 R >> 409 | /AA << /E << /S/SetOCGState /State[/Toggle \mtl@characters] >> 410 | /X << /S/SetOCGState /State[/Toggle \mtl@characters] >> 411 | /D << /S/SetOCGState /State[/Toggle \csname mtl@bounding-boxes\endcsname] >> 412 | /U << /S/SetOCGState /State[/Toggle \csname mtl@TeX-boxes\endcsname] >> 413 | >> }% 414 | \vspace{3\baselineskip} 415 | } 416 | \IfFileExists{pkpmmri8a10.afm}\relax{\def\printlogo{\MT@warning{File pkpmmri8a10.afm not found. 417 | \MessageBreak Cannot create logo}}} 418 | % \end{macrocode} 419 | %\end{macro} 420 | % Our font. 421 | % \begin{macrocode} 422 | \pdfmapline{+pkpmmri8r10 KeplMM-It_385_575_10_ " TeXBase1Encoding ReEncodeFont " <8r.enc > >>} 459 | \makeatother 460 | \begin{document} 461 | % \end{macrocode} 462 | % You are currently reading this. 463 | % \begin{macrocode} 464 | \DocInput{microtype-logo.dtx} 465 | \newpage 466 | And here it is:\vspace{6\baselineskip} 467 | \begin{center} 468 | \printlogo 469 | \end{center} 470 | \expandafter\enddocument 471 | \fi 472 | % \end{macrocode} 473 | % That's it. 474 | % 475 | %^^A resume counting backslashes 476 | %\makeatletter 477 | %\let\step@checksum\orig@step@checksum 478 | %^^A\makeatother 479 | % 480 | % \begin{macrocode} 481 | % 482 | % \end{macrocode} 483 | % 484 | \endinput 485 | -------------------------------------------------------------------------------- /microtype-lssample.dtx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schlcht/microtype/fe0c12ea97dd79f0c311a616d7b8519215db32e5/microtype-lssample.dtx -------------------------------------------------------------------------------- /microtype-utf.dtx: -------------------------------------------------------------------------------- 1 | %\iffalse meta-comment 2 | % 3 | % ------------------------------------------------------------------------ 4 | % The `microtype' package 5 | % Subliminal refinements towards typographical perfection 6 | % Copyright (c) 2004--2025 R Schlicht 7 | % 8 | % This work may be distributed and/or modified under the conditions of the 9 | % LaTeX Project Public License, either version 1.3c of this license or (at 10 | % your option) any later version. The latest version of this license is in: 11 | % https://www.latex-project.org/lppl.txt, and version 1.3c or later is part 12 | % of all distributions of LaTeX version 2005/12/01 or later. 13 | % 14 | % This work has the LPPL maintenance status `maintained'. 15 | % 16 | % This work consists of the files microtype.dtx, microtype-utf.dtx and 17 | % microtype.ins and the derived files microtype.sty, microtype-pdftex.def, 18 | % microtype-luatex.def, microtype-xetex.def, microtype.lua, letterspace.sty 19 | % and microtype-show.sty. 20 | % 21 | % Modified versions of the configuration files (*.cfg) may be distributed 22 | % provided that: (1) the original copyright statement is not removed, and 23 | % (2) the identification string is changed. 24 | % ------------------------------------------------------------------------ 25 | % 26 | %<*!EBGaramond> 27 | \ProvidesFile 28 | % 29 | %<*driver> 30 | {\jobname.dtx}[2025/02/11 v3.2a] 31 | % 32 | % {mt-CharisSIL.cfg}[2017/07/07 v1.1 microtype config. file: Charis SIL (RS)] 33 | % {mt-LatinModernRoman.cfg}[2021/02/21 v1.1 microtype config. file: Latin Modern Roman (RS)] 34 | % {mt-NewComputerModern.cfg}[2021/11/09 v1.1 microtype config. file: New Computer Modern (AT)] 35 | % {mt-Palatino.cfg}[2012/03/10 v1.0 microtype config. file: Palatino and similar fonts (LBD)] 36 | % {mt-TU-basic.cfg}[2021/06/22 v1.1 microtype config. file: fonts with basic glyph set (RS)] 37 | % {mt-TU-empty.cfg}[2021/06/22 v1.1 microtype config. file: fonts with nonstandard glyph set (RS)] 38 | %<*driver> 39 | \makeatletter 40 | \documentclass[10pt,a4paper,doc2]{ltxdoc} 41 | \usepackage{fontspec} 42 | \usepackage{luatexbase} 43 | \RequireLuaModule{luainputenc} 44 | % microtype-doc.sty is 8-bit, and the following is a hack 45 | \luatexbase@directlua{luatexbase.add_to_callback('process_input_buffer', luainputenc.fake_utf_read, 'luainputenc.fake_utf_read')} 46 | \usepackage{microtype-doc} 47 | \luatexbase@directlua{luatexbase.remove_from_callback('process_input_buffer', 'luainputenc.fake_utf_read')} 48 | \def\setmacrofont#1{\par\def\macro@font{#1}\footnotesize} 49 | \defaultfontfeatures{RawFeature={notdef=false},WordSpace=2} 50 | \def\normalwordspace{\fontdimen2\font=.5\fontdimen2\font} 51 | \newfontface\LMR{Latin Modern Roman} 52 | \newfontface\NCM{NewCM10-Book.otf}[WordSpace=1] 53 | \newfontface\CharisSIL{Charis SIL} 54 | \newfontface\Palatino{TeX Gyre Pagella} 55 | \newfontface\EBGaramond{EBGaramond-Regular} 56 | % \newfontface\Palatino[RawFeature={fallback=charisfallback}]{TeX Gyre Pagella} 57 | % \directlua{luaotfload.add_fallback("charisfallback",{"CharisSIL:color=F70A12;mode=harf;"})} 58 | \usepackage{luacode} 59 | \tracinglostchars2 60 | % we replace any missing characters (in Palatino) with CharisSIL 61 | % the lua code is mostly stolen from https://tex.stackexchange.com/a/120529 and https://tex.stackexchange.com/a/119945 62 | {\CharisSIL\footnotesize\global\expandafter\let\expandafter\fallbackfont\the\font} 63 | \begin{luacode} 64 | local fontcharacters = { } 65 | local nullfont = 0 66 | local glyph_t = nodes.nodecodes.glyph 67 | local whatsit_t = nodes.nodecodes.whatsit 68 | local colorst_t = node.subtype("pdf_colorstack") 69 | local color_push = node.new(whatsit_t,colorst_t) 70 | local color_pop = node.new(whatsit_t,colorst_t) 71 | color_push.stack, color_pop.stack = 0,0 72 | color_push.command,color_pop.command = 1,2 73 | color_push.data = "0.97 0.04 0.07 rg" -- red 74 | local fallbackfont = font.id("fallbackfont") 75 | local fallbackchar = 0xFFFD -- Unicode replacement character 76 | table.setmetatableindex(fontcharacters, function (t, k) 77 | if k == true then 78 | return fontcharacters[currentfont()] 79 | else 80 | local tfmdata = fonts.hashes.identifiers[k] 81 | if not tfmdata then --- unsafe 82 | tfmdata = font.fonts[k] 83 | if not (tfmdata and type (tfmdata) == "table") then 84 | return false 85 | end 86 | end 87 | local characters = tfmdata.characters 88 | t[k] = characters 89 | return characters 90 | end 91 | end) 92 | local nodeprocessor = function (head) 93 | local lastfont, characters = nil, nil 94 | for n in node.traverse_id(glyph_t, head) do 95 | local currfont = n.font 96 | local char = n.char 97 | if currfont ~= lastfont and currfont ~= nullfont then 98 | characters = fontcharacters[currfont] 99 | end 100 | if characters ~= false then 101 | lastfont = currfont 102 | if not characters[char] then 103 | head = node.insert_before(head,n,node.copy(color_push)) 104 | -- node.remove(head,node.next(n)) -- remove .notdef char (new in luaotfload 2.98) 105 | node.insert_after(head,n,node.copy(color_pop)) 106 | n.font = fallbackfont 107 | if not fontcharacters[fallbackfont][char] then -- not even in Charis SIL 108 | n.char = fallbackchar 109 | end 110 | end 111 | end 112 | end 113 | return head, false 114 | end 115 | luatexbase.add_to_callback("pre_linebreak_filter", nodeprocessor, "replace missing glyphs") 116 | \end{luacode} 117 | % communicate counters and bookmarks in microtype-utf.tmp 118 | % (via aux file to get page numbers right) 119 | \let\UTF@bookmarks\@gobble 120 | \def\addto@UTF@bookmarks#1{\edef\UTF@bookmarks{\UTF@bookmarks,#1}} 121 | \def\MT@rempt#1.#2\@nil{#1} 122 | \def\addtoUTFbookmarks#1{% 123 | \protected@write\@auxout{}{% 124 | \string\addto@UTF@bookmarks{% page,section,level,heading,label 125 | \string\number\numexpr\thepage-\startpage,% 126 | \expandafter\MT@rempt\@currentHref\@nil,% 127 | \the\c@section@level,\@currentlabelname,#1}}} 128 | \AddToHook{enddocument/afteraux}{ 129 | \begingroup 130 | \def\setcounter#1#2{\expandafter\ifnum\csname c@#1\endcsname=#2 \else\@tempswatrue\fi} 131 | \def\UTF@setbookmarks#1{\MT@ifstreq{#1}{\UTF@bookmarks}\relax\@tempswatrue} 132 | \InputIfFileExists{microtype-utf.tmp}\@tempswafalse\@tempswatrue 133 | \if@tempswa % only write file if anything has changed 134 | \newwrite\utftmp 135 | \immediate\openout \utftmp=microtype-utf.tmp 136 | \immediate\write \utftmp{\string\setcounter{CodelineNo}{\the\c@CodelineNo}} 137 | \immediate\write \utftmp{\string\setcounter{footnote}{\the\c@footnote}} 138 | \immediate\write \utftmp{\string\UTF@setbookmarks{\UTF@bookmarks}} 139 | \immediate\closeout\utftmp 140 | \fi 141 | \endgroup} 142 | \AddToHook{begindocument}{ 143 | \InputIfFileExists{microtype-code.tmp}\relax\relax 144 | \edef\startpage{\thepage} 145 | \stepcounter{page}} 146 | \CodelineIndex 147 | \DisableCrossrefs 148 | \RecordChanges 149 | \begin{document} 150 | \DocInput{\jobname.dtx} 151 | \end{document} 152 | % 153 | % \fi 154 | %\StopEventually{} 155 | % 156 | % ^^A ------------------------------------------------------------------------- 157 | %\GeneralChanges* 158 | %\changes{v2.8a}{2021/02/22}{rename \file{mt-PalatinoLinotype.cfg} to \file{mt-Palatino.cfg} 159 | % (requested by \contributor Karl Berry )} 160 | % ^^A private mail, 2021/02/22 161 | % 162 | %\GeneralChanges{Documentation} 163 | %\changes{v2.5a}{2013/05/15}{include OpenType configuration files} 164 | %\changes{v2.6}{2015/12/07}{missing characters printed with Charis } 165 | %\ImplementationSettings 166 | % 167 | %\section{OpenType configuration files} 168 | %\addtoUTFbookmarks{sec:OpenType} 169 | % 170 | % These are the configuration files for the following OpenType fonts:\footnote{This is file \file{\jobname.dtx}.} 171 | % 172 | %\begin{itemize} 173 | % \item {\LMR\normalwordspace Latin Modern Roman} 174 | % \item {\NCM New Computer Modern}\footnote{These settings have been contributed by 175 | % \contributor Antonis Tsolomitis .} 176 | % \item {\CharisSIL\normalwordspace Charis } 177 | % \item {\EBGaramond\normalwordspace Garamond} 178 | % \item {\Palatino Palatino}\footnote{These settings have been contributed by 179 | % \contributor Loren~B. Davis .} 180 | %\end{itemize} 181 | % 182 | %\noindent 183 | % The settings are typeset in the respective font. 184 | % 185 | %\subsection{Character inheritance} 186 | %\GeneralChanges{Inheritance} 187 | %\addtoUTFbookmarks{sub:OT-inheritance} 188 | % 189 | % OpenType fonts may differ considerably in how complete their arsenal of glyphs is. 190 | % Therefore, each font family should have their own inheritance settings. 191 | % 192 | %\NoIndexing 193 | % \begin{macrocode} 194 | 195 | %%% ----------------------------------------------------------------------- 196 | %%% INHERITANCE 197 | 198 | %% for xetex (EU1) and luatex (EU2), resp. both (TU) 199 | % \end{macrocode} 200 | %\subsubsection{Latin Modern Roman/New Computer Modern} 201 | %\addtoUTFbookmarks{subsub:OT-inh-LMR} 202 | % \begin{macrocode} 203 | %<*LatinModernRoman|NewComputerModern> 204 | \DeclareCharacterInheritance 205 | { encoding = {TU,EU1,EU2}, 206 | % family = Latin Modern Roman } 207 | % family = {New Computer Modern} } 208 | % \end{macrocode} 209 | %\changes{v2.8a}{2021/02/21}{specify `ff' ligature as Unicode instead of glyph name} 210 | %\changes{v3.0}{2021/08/08}{settings for New Computer Modern (provided by 211 | % \contributor Antonis Tsolomitis )} 212 | %{\setmacrofont\NCM 213 | % \begin{macrocode} 214 | { 215 | A = {À,Á,Â,Ã,Ä,Å,Ā,Ă,Ą,Ǻ,Ȁ,Ạ,Ả,Ấ,Ầ,Ẩ,Ẫ,Ậ,Ắ,Ằ,Ẳ,Ặ, 216 | % Α % Greek 217 | % Α,Ά,ᾼ,Ά,Ᾰ,Ᾱ % Ἁ,Ἂ,Ἃ,Ἄ,Ἅ,Ἆ,Ἇ,ᾈ,ᾉ,ᾊ,ᾋ,ᾌ,ᾍ,ᾎ,ᾏ,Ὰ, % Greek 218 | }, 219 | Æ = {Ǽ}, 220 | B = {฿, 221 | Β}, % Greek 222 | C = {Ç,Ć,Ĉ,Ċ,Č}, 223 | D = {Ð,Ď,Đ,Ḍ,Ḏ}, 224 | E = {È,É,Ê,Ë,Ē,Ĕ,Ė,Ę,Ě,Ȅ,Ẹ,Ẻ,Ẽ,Ề,Ế,Ễ,Ể,Ệ, 225 | Ε}, % Greek 226 | % (l)E = {Έ,Ἐ,Ἑ,Ἒ,Ἓ,Ἔ,Ἕ,Ὲ,Έ}, % Greek accents fully protruded left 227 | G = {Ĝ,Ğ,Ġ,Ģ,Ǧ,Ǵ}, 228 | H = {Ĥ,Ħ,Ḥ,Ḧ,Ḫ, 229 | % Η % Greek 230 | % Η,ῌ % Greek 231 | }, 232 | % (l)H = {Ἠ,Ἡ,Ἢ,Ἣ,Ἤ,Ἥ,Ἦ,Ἧ,ᾘ,ᾙ,ᾚ,ᾛ,ᾜ,ᾝ,ᾞ,ᾟ}, % Greek accents fully protruded left 233 | % %(l)/uni1FCC.alt = {/uni1F98.alt}, 234 | I = {Ì,Í,Î,Ï,Ĩ,Ī,Ĭ,Į,İ,Ȉ,Ỉ,Ị, 235 | % Ι % Greek 236 | % Ι,Ῐ,Ῑ % Greek 237 | }, 238 | % (l)I = {Ἰ,Ἱ,Ἲ,Ἳ,Ἴ,Ἵ,Ἶ,Ἷ,Ὶ,Ί}, % Greek 239 | J = {Ĵ}, 240 | K = {Ķ, 241 | Κ}, % Greek 242 | L = {Ĺ,Ļ,Ł,Ḷ}, % Ľ,Ŀ,Ḹ 243 | M = {Μ}, % Greek 244 | N = {Ñ,Ń,Ņ,Ň,Ṅ,Ṇ, 245 | Ν}, % Greek 246 | O = {Ò,Ó,Ô,Õ,Ö,Ø,Ō,Ŏ,Ő,Ọ,Ơ,Ǫ,Ǿ,Ȍ,Ỏ,Ố,Ồ,Ổ,Ỗ,Ộ,Ớ,Ờ,Ỡ,Ở,Ợ, 247 | Ο}, % Greek 248 | % (l)O = {Ό,Ὀ,Ὁ,Ὂ,Ὃ,Ὄ,Ὅ,Ὸ}, % Greek accents except Ό that has indep. protrusion numbers (below) 249 | P = {Ρ}, % Greek 250 | % (l)P = {Ῥ}, % Greek accents fully protruded left 251 | R = {Ŕ,Ŗ,Ř,Ȑ,Ṛ,Ṙ,Ṝ}, 252 | S = {Ś,Ŝ,Ş,Š,Ș,Ṣ}, 253 | T = {Ţ,Ť,Ț,Ṭ,Ṯ, 254 | Τ}, % Greek 255 | U = {Ù,Ú,Û,Ü,Ũ,Ū,Ŭ,Ů,Ű,Ų,Ư,Ȕ,Ụ,Ủ,Ứ,Ừ,Ử,Ữ,Ự}, 256 | W = {Ŵ,Ẁ,Ẃ,Ẅ}, 257 | X = {Χ}, % Greek 258 | Y = {Ý,Ŷ,Ÿ,Ỵ,Ỷ,Ỹ}, 259 | % Υ = {Ϋ,Ῠ,Ῡ}, 260 | % (l)Υ = {Ύ,Ὺ,Ύ,Ὑ,Ὓ,Ὕ,Ὗ}, 261 | Z = {Ź,Ż,Ž,Ẓ, 262 | Ζ}, % Greek 263 | a = {à,á,â,ã,ä,å,ā,ă,ą,ǻ,ȁ,ạ,ả,ấ,ầ,ẩ,ẫ,ậ,ắ,ằ,ẳ,ẵ}, 264 | æ = {ǽ}, 265 | c = {ç,ć,ĉ,ċ,č}, 266 | d = {đ,ḍ,ḏ}, 267 | e = {è,é,ê,ë,ē,ĕ,ė,ę,ě,ȅ,ẹ,ẻ,ẽ,ế,ề,ể,ễ,ệ}, 268 | f = {ff}, % Unicode 64256, glyph name in Latin Modern Roman: /f_f ; in New Computer Modern: /ff 269 | g = {ĝ,ğ,ġ,ģ,ǧ,ǵ}, 270 | h = {ĥ,ħ,ḥ,ḧ,ḫ}, 271 | i = {ì,í,î,ï,ĩ,ī,ĭ,į,ı,ȉ,ỉ,ị}, 272 | j = {ĵ}, 273 | k = {ķ}, 274 | l = {ĺ,ļ,ł,ḷ,ḹ}, % ľ,l· 275 | n = {ñ,ń,ņ,ň,ṅ,ṇ}, 276 | o = {ò,ó,ô,õ,ö,ø,ō,ŏ,ő,ọ,ơ,ǫ,ǿ,ȍ,ỏ,ố,ồ,ổ,ỗ,ộ,ớ,ờ,ỡ,ở,ợ 277 | % ,ο,ό,ὀ,ὁ,ὂ,ὃ,ὄ,ὅ,ὸ,ό % Greek 278 | }, 279 | r = {ŕ,ŗ,ř,ȑ,ṛ,ṙ,ṝ}, 280 | s = {ś,ŝ,ş,š,ș,ṣ}, 281 | t = {ţ,ț,ṭ,ṯ,ẗ}, % ť 282 | u = {ù,ú,û,ü,ũ,ū,ŭ,ů,ű,ų,ư,ȕ,ụ,ủ,ứ,ừ,ử,ữ,ự}, 283 | w = {ŵ,ẁ,ẃ,ẅ}, 284 | y = {ý,ŷ,ÿ,ỳ,ỵ,ỷ,ỹ}, 285 | z = {ź,ż,ž,ẓ}, 286 | %<*NewComputerModern> 287 | α = {ἁ,ἂ,ἃ,ἄ,ἅ,ἆ,ἇ,ᾀ,ᾁ,ᾂ,ᾃ,ᾄ,ᾅ,ᾆ,ᾇ,ὰ}, 288 | ε = {έ,ἐ,ἑ,ἒ,ἓ,ἔ,ἕ,ὲ,έ}, 289 | η = {ἠ,ἡ,ἢ,ἣ,ἤ,ἥ,ἦ,ἧ,ᾐ,ᾑ,ᾒ,ᾓ,ᾔ,ᾕ,ᾖ}, 290 | ι = {ἰ,ἱ,ὶ,ί,ῐ,ῑ,ϊ,ΐ}, 291 | ϊ = {ἲ,ἳ,ἴ,ἵ,ἶ,ἷ,ῐ,ῑ,ΐ}, 292 | υ = {ύ,ὺ,ύ,ὑ,ὓ,ὕ,ὗ,ϋ,ῠ,ῡ,ϋ,ΰ}, 293 | ω = {ώ,ὠ,ὡ,ὢ,ὣ,ὤ,ὥ,ὦ,ὧ,ᾠ,ᾡ,ᾢ,ᾣ,ᾤ,ᾥ,ᾦ}, 294 | % 295 | } 296 | % \end{macrocode} 297 | %} 298 | % \begin{macrocode} 299 | % 300 | % \end{macrocode} 301 | %\subsubsection{Charis SIL} 302 | %\addtoUTFbookmarks{subsub:OT-inh-Charis} 303 | % \begin{macrocode} 304 | %<*CharisSIL> 305 | \DeclareCharacterInheritance 306 | { encoding = {TU,EU1,EU2}, 307 | family = Charis SIL } 308 | % \end{macrocode} 309 | %{\setmacrofont\CharisSIL 310 | % \begin{macrocode} 311 | { A = {À,Á,Â,Ã,Ä,Å,Ā,Ă,Ą,Ǎ,Ǟ,Ǡ,Ȧ,Ǻ,Ȁ,Ȃ,Ḁ,Ạ,Ả,Ấ,Ầ,Ẩ,Ẫ,Ậ,Ắ,Ằ,Ẳ,Ẵ,Ặ,Ꜳ, 312 | А,Ӑ,Ӓ}, % Cyrillic 313 | Æ = {Ǣ, 314 | Ǽ,Ӕ}, % Cyrillic 315 | B = {Ḃ,Ḅ,Ḇ, 316 | В}, % Cyr 317 | C = {Ç,Ć,Ĉ,Ḉ,Ċ,Č, 318 | С,Ҫ}, % Cyr 319 | D = {Ď,Ḋ,Ḍ,Ḏ,Ḑ,Ḓ,Đ}, 320 | E = {È,É,Ê,Ë,Ē,Ĕ,Ė,Ę,Ě,Ȅ,Ȩ,Ȇ,Ḕ,Ḗ,Ḙ,Ḛ,Ḝ,Ẹ,Ẻ,Ẽ,Ế,Ề,Ể,Ễ,Ệ, 321 | Е,Ѐ,Ё,Ӗ}, % Cyr 322 | F = {Ḟ}, 323 | G = {Ĝ,Ğ,Ġ,Ģ,Ǧ,Ǵ,Ḡ,Ԍ}, 324 | H = {Ĥ,Ȟ,Ḣ,Ḥ,Ḧ,Ḩ,Ḫ, 325 | Н,Ң,Ҥ,Ӈ,Ӊ}, % Cyr 326 | I = {Ì,Í,Î,Ȉ,Ï,Į,Ĩ,Ị,Ī,İ,Ǐ,Ỉ,Ȋ,Ĭ,Ḭ,Ï, 327 | І,Ї,Ӏ,ӏ}, % Cyr 328 | J = {Ĵ, 329 | Ј}, % Cyr 330 | K = {Ķ,Ǩ,Ḱ,Ḳ,Ḵ, 331 | К,Ќ,Қ,Ҝ,Ҟ,Ҡ,Ӄ,Ԟ}, % Cyr 332 | L = {Ĺ,Ļ,Ľ,Ḷ,Ḹ,Ḻ,Ḽ}, % L· 333 | M = {Ḿ,Ṁ,Ṃ, 334 | М,Ӎ}, % Cyr 335 | N = {Ñ,Ń,Ņ,Ň,Ǹ,Ṅ,Ṇ,Ṉ,Ṋ, 336 | И,Й,Ѝ,Ҋ,Ӣ,Ӥ}, % Cyr 337 | O = {Ò,Ó,Ô,Õ,Ö,Ō,Ŏ,Ő,Ǒ,Ǫ,Ǭ,Ȍ,Ȏ,Ȫ,Ȭ,Ȯ,Ȱ,Ṍ,Ṏ,Ṑ,Ṓ,Ọ,Ỏ,Ố,Ồ,Ổ,Ỗ,Ộ,Ớ,Ờ,Ở,Ỡ,Ơ, 338 | О,Ѳ,Ӧ,Ө,Ӫ, % Cyr 339 | Θ}, % Greek 340 | P = {Ṕ,Ṗ, 341 | Р,Ҏ}, % Cyr 342 | Q = {Ԛ}, % Cyr 343 | R = {Ŕ,Ŗ,Ř,Ȑ,Ȓ,Ṙ,Ṛ,Ṝ,Ṟ}, 344 | S = {Ś,Ŝ,Ş,Š,Ș,Ṡ,Ṣ,Ṥ,Ṧ,Ṩ, 345 | Ѕ}, % Cyr 346 | T = {Ţ,Ť,Ț,Ṫ,Ṭ,Ṯ,Ṱ, 347 | Т,Ҭ}, % Cyr 348 | U = {Ù,Ú,Û,Ü,Ũ,Ū,Ŭ,Ů,Ű,Ų,Ǔ,Ǖ,Ǘ,Ǚ,Ǜ,Ȕ,Ȗ,Ṳ,Ṵ,Ṷ,Ṹ,Ṻ,Ụ,Ủ,Ứ,Ừ,Ử,Ữ,Ự}, 349 | V = {Ṽ,Ṿ}, 350 | W = {Ŵ,Ẁ,Ẃ,Ẅ,Ẇ,Ẉ, 351 | Ԝ}, % Cyr 352 | X = {Ẋ,Ẍ, 353 | Х,Ҳ,Ӽ,Ӿ}, % Cyr 354 | Y = {Ý,Ŷ,Ÿ,Ȳ,Ẏ,Ỳ,Ỵ,Ỷ,Ỹ, 355 | Ү,Ұ}, % Cyr 356 | Z = {Ź,Ż,Ž,Ẑ,Ẓ,Ẕ}, 357 | a = {à,á,â,ã,ä,å,ā,ă,ą,ǎ,ǟ,ǡ,ȧ,ǻ,ȁ,ȃ,ḁ,ạ,ả,ầ,ấ,ẩ,ẫ,ậ,ắ,ằ,ẳ,ẵ,ặ, % aʾ 358 | а,ӑ,ӓ}, % Cyr 359 | æ = {ǽ, 360 | ӕ}, % Cyr 361 | b = {ḃ,ḅ,ḇ}, 362 | c = {ç,ć,ĉ,ċ,č,ḉ, 363 | с,ҫ}, % Cyr 364 | d = {ď,ḋ,ḍ,ḏ,ḑ,ḓ}, 365 | e = {è,é,ê,ë,ē,ĕ,ė,ę,ě,ȅ,ȩ,ȇ,ḕ,ḗ,ḙ,ḛ,ḝ,ẹ,ẻ,ẽ,ề,ế,ể,ễ,ệ, 366 | е,ѐ,ё,ӗ}, % Cyr 367 | f = {ḟ,ff}, % /f_f 368 | g = {ĝ,ğ,ġ,ģ,ǧ,ǵ,ḡ}, 369 | h = {ĥ,ȟ,ḣ,ḥ,ḧ,ḩ,ḫ,ẖ, 370 | Һ,һ}, % Cyr 371 | i = {ı,ì,í,î,ȉ,ǐ,ï,į,ī,ị,ĩ,ḭ,ḯ,ỉ,ȋ,ĭ, 372 | і,ї}, % Cyr 373 | j = {ĵ,ǰ, 374 | ј}, % Cyr 375 | k = {ķ,ǩ,ḱ,ḳ,ḵ}, 376 | l = {ĺ,ļ,ḻ,ḷ,ḹ,ḽ}, % ľ,l· 377 | m = {ḿ,ṁ,ṃ}, 378 | n = {ñ,ń,ņ,ň,ǹ,ṅ,ṇ,ṉ,ṋ}, % ʼn 379 | o = {ò,ó,ô,õ,ö,ō,ŏ,ő,ǒ,ǫ,ǭ,ȍ,ȏ,ȫ,ȭ,ȯ,ȱ,ṍ,ṏ,ṑ,ṓ,ọ,ỏ,ồ,ố,ổ,ỗ,ộ,ớ,ờ,ở,ỡ,ợ, 380 | о,ѳ,ӧ,ө,ӫ}, % Cyr 381 | p = {ṕ,ṗ, 382 | р,ҏ}, % Cyr 383 | q = {ԛ}, % Cyr 384 | r = {ŕ,ŗ,ř,ȑ,ȓ,ṙ,ṛ,ṝ,ṟ}, 385 | s = {ś,ŝ,ş,š,ș,ṡ,ṣ,ṥ,ṧ,ṩ, 386 | ѕ}, % Cyr 387 | t = {ţ,ț,ṫ,ṭ,ṯ,ṱ,ẗ}, % ť 388 | u = {ù,ú,û,ü,ũ,ū,ŭ,ů,ű,ų,ǔ,ǖ,ǘ,ǚ,ǜ,ȕ,ȗ,ṳ,ṵ,ṷ,ṹ,ṻ,ụ,ủ,ứ,ừ,ử,ữ,ự}, 389 | v = {ṽ,ṿ}, 390 | w = {ŵ,ẁ,ẃ,ẅ,ẇ,ẉ,ẘ, 391 | ԝ}, % Cyr 392 | x = {ẋ,ẍ, 393 | х,ҳ}, % Cyr 394 | y = {ý,ÿ,ŷ,ȳ,ẏ,ẙ,ỳ,ỵ,ỷ,ỹ, 395 | у,ў,ӯ,ӱ,ӳ}, % Cyr 396 | z = {ź,ż,ž,ẑ,ẓ,ẕ}, 397 | % Cyrillic 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 | Г = {Γ}, % Greek 427 | П = {Π}, % Greek 428 | % missing: tipa, math, symbols, ... 429 | } 430 | % \end{macrocode} 431 | %} 432 | % \begin{macrocode} 433 | % 434 | % \end{macrocode} 435 | %\subsubsection{EB~Garamond} 436 | %\addtoUTFbookmarks{subsub:OT-inh-EBGaramond} 437 | %\changes{v3.0}{2021/08/08}{settings for Garamond (OpenType)} 438 | % \begin{macrocode} 439 | %<*EBGaramond> 440 | \DeclareCharacterInheritance 441 | { encoding = {TU,EU1,EU2}, 442 | family = EBGaramond } 443 | % \end{macrocode} 444 | %{\setmacrofont\EBGaramond 445 | % \begin{macrocode} 446 | { 447 | A = {À,Á,Â,Ã,Ä,Å,Ā,Ă,Ą,Ǎ,Ǟ,Ǡ,Ǻ,Ȁ,Ȃ,Ȧ,Ạ,Ả,Ấ,Ầ,Ẩ,Ẫ,Ậ,Ắ,Ằ,Ẳ,Ẵ,Ặ,Å,/Adieresis.deu, 448 | А,Ӑ,Ӓ, % Cyrillic 449 | Α,Ά,Ἀ,Ἁ,Ἂ,Ἃ,Ἄ,Ἅ,Ἆ,Ἇ,ᾈ,ᾉ,ᾊ,ᾋ,ᾌ,ᾍ,ᾎ,ᾏ,Ᾰ,Ᾱ,Ὰ,Ά,ᾼ}, % Greek 450 | % (l)Α {Ά,Ἀ,Ἁ,Ἂ,Ἃ,Ἄ,Ἅ,Ἆ,Ἇ,ᾈ,ᾉ,ᾊ,ᾋ,ᾌ,ᾍ,ᾎ,ᾏ,Ᾰ,Ᾱ,Ὰ,Ά,ᾼ}, % (accents not protruded) 451 | B = {Ḃ,Ḅ,Ḇ, 452 | В, % Cyrillic 453 | Β}, % Greek 454 | C = {Ç,Ć,Ĉ,Ċ,Č,Ḉ, 455 | Ϲ,С,Ҫ, % Cyrillic 456 | Ⅽ}, % Roman numeral 457 | D = {Ď,Đ,Ð,Ḋ,Ḍ,Ḏ,Ḑ,Ḓ, 458 | Ɖ,Ɗ, % Cyrillic 459 | Ⅾ}, % Roman numeral 460 | E = {È,É,Ê,Ë,Ē,Ĕ,Ė,Ę,Ě,Ḕ,Ḗ,Ȩ,Ḙ,Ḛ,Ḝ,Ẹ,Ẻ,Ẽ,Ế,Ề,Ể,Ễ,Ệ,Ȅ,Ȇ, 461 | Ѐ,Ё,Ӗ,Е, % Cyrillic 462 | Ε}, % Greek 463 | (l)Ε = {Έ,Ἐ,Ἑ,Ἒ,Ἓ,Ἔ,Ἕ,Ὲ,Έ}, % Greek (accents protruded) 464 | F = {Ḟ}, 465 | G = {Ĝ,Ğ,Ġ,Ģ,Ǥ,Ǧ,Ǵ,Ḡ}, 466 | H = {Ĥ,Ħ,Ȟ,Ḣ,Ḥ,Ḧ,Ḩ,Ḫ,ῌ,Ⱨ, 467 | Н,Ң,Ӊ,Ӈ, % Ҥ % Cyrillic 468 | Η}, % Greek 469 | (l)Η = {Ή,Ἠ,Ἡ,Ἢ,Ἣ,Ἤ,Ἥ,Ἦ,Ἧ,Ὴ,Ή,ᾘ,ᾙ,ᾚ,ᾛ,ᾜ,ᾝ,ᾞ,ᾟ}, 470 | I = {Ì,Í,Î,Ï,Ĩ,Ī,Ĭ,Į,İ,Ǐ,Ȉ,Ȋ,Ḭ,Ḯ,Ỉ,Ị, 471 | І,Ї,Ӏ, % Cyrillic 472 | Ι, % Greek 473 | Ⅰ,Ⅱ,Ⅲ}, % Roman numeral 474 | (l)Ι = {Ί,Ϊ,Ἰ,Ἱ,Ἲ,Ἳ,Ἴ,Ἵ,Ἶ,Ἷ,Ῐ,Ῑ,Ὶ,Ί}, % Greek 475 | J = {Ĵ, 476 | Ј}, % Cyrillic 477 | K = {Ķ,Ǩ,Ḱ,Ḳ,Ḵ,Ⱪ, 478 | Κ,K}, % Greek 479 | L = {Ĺ,Ļ,Ľ,Ŀ,Ł,Ḷ,Ḹ,Ḻ,Ḽ,Ⱡ,Ɫ, 480 | Ⅼ}, % Roman numeral 481 | M = {Ḿ,Ṁ,Ṃ, 482 | М,Ӎ, % Cyrillic 483 | Μ, % Greek 484 | Ⅿ}, % Roman numeral 485 | N = {Ñ,Ń,Ņ,Ň,Ŋ,Ǹ,Ṅ,Ṇ,Ṉ,Ṋ, 486 | Ν}, % Greek 487 | O = {Ò,Ó,Ô,Õ,Ö,Ø,Ō,Ŏ,Ő,Ǒ,Ǫ,Ǭ,Ǿ,Ȍ,Ȏ,Ȫ,Ȭ,Ȯ,Ȱ,Ṍ,Ṏ,Ṑ,Ṓ,Ọ,Ỏ,Ố,Ồ,Ổ,Ỗ,Ộ,Ớ,Ờ,Ở,Ỡ,Ợ,Ơ,/Odieresis.deu, 488 | О,Ӧ,Ө,Ӫ, % Cyrillic 489 | Ο,Ό,Ὀ,Ὁ,Ὂ,Ὃ,Ὄ,Ὅ,Ὸ,Ό}, % Greek 490 | % (l)Ο = {Ό,Ὀ,Ὁ,Ὂ,Ὃ,Ὄ,Ὅ,Ὸ,Ό}, % (accents not protruded) 491 | P = {Ṕ,Ṗ,Ᵽ, 492 | Р,Ҏ, % Cyrillic 493 | Ρ}, % Greek 494 | (l)Ρ = {Ῥ}, % Greek 495 | Q = {Ԛ}, % Cyrillic 496 | R = {Ŕ,Ŗ,Ř,Ȑ,Ȓ,Ṙ,Ṛ,Ṝ,Ṟ,Ɽ,}, 497 | S = {Ś,Ŝ,Ş,Š,Ș,Ṡ,Ṣ,Ṥ,Ṧ,Ṩ, 498 | Ѕ}, % Cyrillic 499 | T = {Ţ,Ť,Ŧ,Ț,Ṫ,Ṭ,Ṯ,Ṱ, 500 | Т,Ҭ, % Cyrillic 501 | Τ}, % Greek 502 | U = {Ù,Ú,Û,Ü,Ũ,Ū,Ŭ,Ů,Ű,Ų,Ǔ,Ǖ,Ǘ,Ǚ,Ǜ,Ȕ,Ȗ,Ṳ,Ṵ,Ṷ,Ṹ,Ṻ,Ụ,Ủ,Ứ,Ừ,Ử,Ữ,Ự}, % /Udieresis.deu ? 503 | V = {Ṽ,Ṿ,/U.LAT, 504 | Ⅴ}, % Roman numeral 505 | W = {Ŵ,Ẁ,Ẃ,Ẅ,Ẇ,Ẉ, 506 | Ԝ}, % Cyrillic 507 | X = {Ẋ,Ẍ, 508 | Х,Ҳ,Ӽ,Ӿ, % Cyrillic 509 | Χ, % Greek 510 | Ⅹ}, % Roman numeral 511 | Y = {Ý,Ŷ,Ÿ,Ȳ,Ẏ,Ỳ,Ỵ,Ỷ,Ỹ, 512 | Ү,Ұ}, % Cyrillic 513 | Z = {Ź,Ż,Ž,Ẑ,Ẓ,Ẕ,Ⱬ, 514 | Ζ}, % Greek 515 | a = {à,á,â,ã,ä,å,ā,ă,ą,ǎ,ǟ,ǡ,ǻ,ȁ,ȃ,ȧ,ḁ,ạ,ả,ấ,ầ,ẩ,ẫ,ậ,ắ,ằ,ẳ,ẵ,ặ,ẚ, 516 | а,ӑ,ӓ}, % Cyrillic 517 | b = {ḃ,ḅ,ḇ}, 518 | c = {ç,ć,ĉ,ċ,č,ḉ, 519 | с,ҫ, % Cyrillic 520 | ⅽ}, % Roman numeral 521 | d = {ď,đ,ḋ,ḍ,ḏ,ḑ,ḓ, 522 | ⅾ}, % Roman numeral 523 | e = {è,é,ê,ë,ē,ĕ,ė,ę,ě,ȩ,ḕ,ḗ,ḙ,ḛ,ḝ,ẹ,ẻ,ẽ,ế,ề,ể,ễ,ệ,ȅ,ȇ, 524 | е,ѐ,ё,ӗ}, % Cyrillic 525 | f = {ḟ,ff,/f.long,/f.DEU,/f_f}, 526 | fl = {ffl,/longs_l,/longs_longs_l,/f_l}, 527 | fi = {ffi,/longs_i,/longs_longs_i,/f_i}, 528 | /f.short = {/f_f.short}, 529 | g = {ĝ,ğ,ġ,ģ,ḡ,ǥ,ǧ,ǵ}, 530 | h = {ĥ,ħ,ḣ,ḥ,ḧ,ḩ,ḫ,ẖ,ȟ,ⱨ, 531 | ԧ,ԧ}, % Cyrillic 532 | i = {ì,í,î,ï,ĩ,ī,ĭ,į,ı,ǐ,ȉ,ȋ,ḭ,ỉ,ị,ḯ,/i.TRK, 533 | і,ї, % Cyrillic 534 | ⅰ,ⅱ,ⅲ}, % Roman numeral 535 | j = {ĵ,ǰ, 536 | ј}, % Cyrillic 537 | k = {ķ,ǩ,ḱ,ḳ,ḵ,ⱪ}, 538 | l = {ĺ,ļ,ľ,ŀ,ł,ḷ,ḹ,ḻ,ḽ,ⱡ, 539 | ӏ, % palochka 540 | ⅼ}, % Roman numeral 541 | m = {ḿ,ṁ,ṃ, 542 | ⅿ}, % Roman numeral 543 | n = {ñ,ń,ņ,ň,ŋ,ṅ,ṇ,ṉ,ṋ,ǹ}, % ʼn 544 | o = {ò,ó,ô,õ,ö,ø,ō,ŏ,ő,ǒ,ǫ,ǭ,ǿ,ȍ,ȏ,ȫ,ȭ,ȯ,ȱ,ṍ,ṏ,ṑ,ṓ,ọ,ỏ,ố,ồ,ổ,ỗ,ộ,ớ,ờ,ở,ỡ,ợ, 545 | о,ӧ}, % Cyrillic 546 | p = {ṕ,ṗ, 547 | р,ҏ}, % Cyrillic 548 | q = {ԛ}, % Cyrillic 549 | r = {ŕ,ŗ,ř,ȑ,ȓ,ṙ,ṛ,ṝ,ṟ}, 550 | s = {ś,ŝ,ş,š,ș,ṡ,ṣ,ṥ,ṧ,ṩ, 551 | ѕ}, % Cyrillic 552 | t = {ţ,ť,ŧ,ț,ṫ,ṭ,ṯ,ṱ,ẗ}, 553 | u = {ù,ú,û,ü,ũ,ū,ŭ,ů,ű,ų,ǔ,ǖ,ǘ,ǚ,ǜ,ȕ,ȗ,ṳ,ṵ,ṷ,ṹ,ṻ,ụ,ủ,ứ,ừ,ử,ữ,ự,/u.LATmedi}, 554 | v = {ṽ,ṿ, 555 | ⅴ}, % Roman numeral 556 | w = {ŵ,ẁ,ẃ,ẅ,ẇ,ẉ,ẘ, 557 | ԝ}, % Cyrillic 558 | x = {ẋ,ẍ, 559 | х,ҳ, % Cyrillic 560 | ⅹ}, % Roman numeral 561 | y = {ý,ÿ,ŷ,ȳ,ẏ,ẙ,ỳ,ỵ,ỷ,ỹ, 562 | у,ӯ,ӱ,ӳ,ў}, % Cyrillic 563 | z = {ź,ż,ž,ⱬ,ẑ,ẓ,ẕ}, 564 | Æ = {Ǣ,Ǽ, 565 | Ӕ}, % Cyrillic 566 | æ = {ǣ,ǽ, 567 | ӕ}, % Cyrillic 568 | DZ = {DŽ}, 569 | Dz = {Dž}, 570 | dz = {dž}, 571 | % Smallcaps 572 | /a.sc = {/A.sc}, 573 | /ae.sc = {/AE.sc}, 574 | /d.sc = {/D.sc}, 575 | /f.sc = {/F.sc}, 576 | /g.sc = {/G.sc}, 577 | /j.sc = {/J.sc}, 578 | /l.sc = {/L.sc}, 579 | /o.sc = {/O.sc}, 580 | /oe.sc = {/OE.sc}, 581 | /q.sc = {/Q.sc}, 582 | /r.sc = {/R.sc}, 583 | /t.sc = {/T.sc}, 584 | /y.sc = {/Y.sc}, 585 | % Cyrillic 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 | % Greek 624 | Υ = {Ϋ,ϒ,ϔ,Ῠ,Ῡ}, 625 | (l)Υ = {Ύ,ϓ,Ὑ,Ὓ,Ὕ,Ὗ,Ὺ,Ύ}, 626 | (l)Ω = {Ώ,Ὠ,Ὡ,Ὢ,Ὣ,Ὤ,Ὥ,Ὦ,Ὧ,ᾨ,ᾩ,ᾪ,ᾫ,ᾬ,ᾭ,ᾮ,ᾯ,Ὼ,Ώ}, 627 | Ω = {ῼ,Ω}, % math 628 | Δ = {∆}, % math 629 | Π = {∏}, % math 630 | α = {ά,ἀ,ἁ,ἂ,ἃ,ἄ,ἅ,ἆ,ἇ,ὰ,ά,ᾀ,ᾁ,ᾂ,ᾃ,ᾄ,ᾅ,ᾆ,ᾇ,ᾰ,ᾱ,ᾲ,ᾳ,ᾴ,ᾶ,ᾷ}, 631 | ε = {έ,ἐ,ἑ,ἒ,ἓ,ἔ,ἕ,ὲ,έ}, 632 | η = {ή,ἠ,ἡ,ἢ,ἣ,ἤ,ἥ,ἦ,ἧ,ὴ,ή,ῂ,ῃ,ῄ,ῆ,ῇ,ᾐ,ᾑ,ᾒ,ᾓ,ᾔ,ᾕ,ᾖ,ᾗ}, 633 | ι = {ί,ϊ,ἰ,ἱ,ἲ,ἳ,ἴ,ἵ,ἶ,ἷ,ὶ,ί,ῐ,ῑ,ῒ,ΐ,ῖ,ῗ,ΐ}, 634 | ο = {ό,ϙ,ὀ,ὁ,ὂ,ὃ,ὄ,ὅ,ὸ,ό}, 635 | ρ = {ῤ,ῥ}, 636 | υ = {ΰ,ϋ,ύ,ὐ,ὑ,ὒ,ὓ,ὔ,ὕ,ὖ,ὗ,ὺ,ύ,ῠ,ῡ,ῢ,ΰ,ῦ,ῧ}, 637 | ω = {ώ,ὠ,ὡ,ὢ,ὣ,ὤ,ὥ,ὦ,ὧ,ὼ,ώ,ᾠ,ᾡ,ᾢ,ᾣ,ᾤ,ᾥ,ᾦ,ᾧ,ῲ,ῳ,ῴ,ῶ,ῷ}, 638 | % other 639 | ⑴ = {⑵,⑶,⑷,⑸,⑹,⑺,⑻,⑼,⑽,⑾,⑿,⒀,⒁,⒂,⒃,⒄,⒅,⒆,⒇}, 640 | ⒜ = {⒝,⒞,⒟,⒠,⒡,⒢,⒣,⒤,⒥,⒦,⒧,⒨,⒩,⒪,⒫,⒬,⒭,⒮,⒯,⒰,⒱,⒲,⒳,⒴,⒵}, 641 | 🇦 = {🇧,🇨,🇩,🇪,🇫,🇬,🇭,🇮,🇯,🇰,🇱,🇲,🇳,🇴,🇵,🇶,🇷,🇸,🇹,🇺,🇻,🇼,🇽,🇾,🇿}, 642 | ! = {‼}, 643 | ? = {⁇}, 644 | . = {/onedotenleader}, 645 | /endash = {/figuredash}, 646 | } 647 | % \end{macrocode} 648 | %} 649 | % \begin{macrocode} 650 | % 651 | % \end{macrocode} 652 | %\subsubsection{Palatino} 653 | %\addtoUTFbookmarks{subsub:OT-inh-Palatino} 654 | % \begin{macrocode} 655 | %<*Palatino> 656 | \DeclareCharacterInheritance 657 | { encoding = {TU,EU1,EU2}, 658 | family = {Palatino} } 659 | % \end{macrocode} 660 | % Unfortunately, I don't have a Palatino variant containing all of the following 661 | % glyphs. The settings are typeset in \TeX\ Gyre Pagella; 662 | % missing glyphs, printed in red, are taken from Charis ; 663 | % glyphs missing even in Charis appear as `\char"FFFD'. 664 | % To see the real settings, consult \file{mt-Palatino.cfg}. 665 | %{\setmacrofont\Palatino 666 | % \begin{macrocode} 667 | { A = {À,Á,Â,Ã,Ä,Ā,Ă,Ą,Ǎ,Ǟ,Ǡ,Ȧ,Ǻ,Ȁ,Ȃ,Ḁ,Ạ,Ả,Ấ,Ầ,Ẩ,Ẫ,Ậ,Ắ,Ằ,Ẳ,Ẵ,Ặ,Ꜳ}, 668 | B = {Ḃ,Ḅ,Ḇ}, 669 | C = {Ç,Ć,Ĉ,Ḉ,Ċ,Č}, 670 | D = {Ď,Ḋ,Ḍ,Ḏ,Ḑ,Ḓ}, 671 | E = {È,É,Ê,Ë,Ē,Ĕ,Ė,Ę,Ě,Ȅ,Ȩ,Ȇ,Ḕ,Ḗ,Ḙ,Ḛ,Ḝ,Ẹ,Ẻ,Ẽ,Ế,Ề,Ể,Ễ,Ệ}, 672 | F = {Ḟ}, 673 | G = {Ĝ,Ğ,Ġ,Ģ,Ǧ,Ǵ,Ḡ}, 674 | H = {Ĥ,Ȟ,Ḣ,Ḥ,Ḧ,Ḩ,Ḫ}, 675 | I = {Ì,Í,Î,Ȉ,Ï,Į,Ĩ,Ị,Ī,İ,Ǐ,Ỉ,Ȋ,Ĭ,Ḭ,Ï}, 676 | J = {Ĵ}, 677 | K = {Ķ,Ǩ,Ḱ,Ḳ,Ḵ}, 678 | L = {Ĺ,Ļ,Ľ,Ḷ,Ḹ,Ḻ,Ḽ,Ỻ,Ŀ,Ł}, % L· 679 | M = {Ḿ,Ṁ,Ṃ}, 680 | N = {Ñ,Ń,Ņ,Ň,Ǹ,Ṅ,Ṇ,Ṉ,Ṋ}, 681 | O = {Ò,Ó,Ô,Õ,Ö,Ō,Ŏ,Ő,Ǒ,Ǫ,Ǭ,Ȍ,Ȏ,Ȫ,Ȭ,Ȯ,Ȱ,Ṍ,Ṏ,Ṑ,Ṓ,Ọ,Ỏ,Ố,Ồ,Ổ,Ỗ,Ộ,Ớ,Ờ,Ở,Ỡ,Ơ}, 682 | P = {Ṕ,Ṗ}, 683 | R = {Ŕ,Ŗ,Ř,Ȑ,Ȓ,Ṙ,Ṛ,Ṝ,Ṟ}, 684 | S = {Ś,Ŝ,Ş,Š,Ș,Ṡ,Ṣ,Ṥ,Ṧ,Ṩ}, 685 | T = {Ţ,Ť,Ț,Ṫ,Ṭ,Ṯ,Ṱ}, 686 | U = {Ù,Ú,Û,Ü,Ũ,Ū,Ŭ,Ů,Ű,Ų,Ǔ,Ǖ,Ǘ,Ǚ,Ǜ,Ȕ,Ȗ,Ṳ,Ṵ,Ṷ,Ṹ,Ṻ,Ụ,Ủ,Ứ,Ừ,Ử,Ữ,Ự}, 687 | V = {Ṽ,Ṿ}, 688 | W = {Ŵ,Ẁ,Ẃ,Ẅ,Ẇ,Ẉ}, 689 | X = {Ẋ,Ẍ}, 690 | Y = {Ý,Ŷ,Ÿ,Ȳ,Ẏ,Ỳ,Ỵ,Ỷ,Ỹ}, 691 | Z = {Ź,Ż,Ž,Ẑ,Ẓ,Ẕ}, 692 | a = {à,á,â,ã,ä,å,ā,ă,ą,ǎ,ǟ,ǡ,ȧ,ǻ,ȁ,ȃ,ḁ,ạ,ả,ầ,ấ,ẩ,ẫ,ậ,ắ,ằ,ẳ,ẵ,ặ}, % aʾ 693 | b = {ḃ,ḅ,ḇ}, 694 | c = {ç,ć,ĉ,ċ,č,ḉ}, 695 | d = {ď,ḋ,ḍ,ḏ,ḑ,ḓ}, 696 | e = {è,é,ê,ë,ē,ĕ,ė,ę,ě,ȅ,ȩ,ȇ,ḕ,ḗ,ḙ,ḛ,ḝ,ẹ,ẻ,ẽ,ề,ế,ể,ễ,ệ}, 697 | f = {ḟ,ff}, 698 | g = {ĝ,ğ,ġ,ģ,ǧ,ǵ,ḡ}, 699 | h = {ĥ,ȟ,ḣ,ḥ,ḧ,ḩ,ḫ,ẖ}, 700 | i = {ı,ì,í,î,ȉ,ǐ,ï,į,ī,ị,ĩ,ḭ,ḯ,ỉ,ȋ,ĭ}, 701 | j = {ĵ,ǰ}, 702 | k = {ķ,ǩ,ḱ,ḳ,ḵ}, 703 | l = {ĺ,ļ,ḻ,ḷ,ḹ,ḽ}, % ľ,l· 704 | m = {ḿ,ṁ,ṃ}, 705 | n = {ñ,ń,ņ,ň,ǹ,ṅ,ṇ,ṉ,ṋ}, % ʼn 706 | o = {ò,ó,ô,õ,ö,ō,ŏ,ő,ǒ,ǫ,ǭ,ȍ,ȏ,ȫ,ȭ,ȯ,ȱ,ṍ,ṏ,ṑ,ṓ,ọ,ỏ,ồ,ố,ổ,ỗ,ộ,ớ,ờ,ở,ỡ,ợ}, 707 | p = {ṕ,ṗ}, 708 | r = {ŕ,ŗ,ř,ȑ,ȓ,ṙ,ṛ,ṝ,ṟ}, 709 | s = {ś,ŝ,ş,š,ș,ṡ,ṣ,ṥ,ṧ,ṩ}, 710 | t = {ţ,ț,ṫ,ṭ,ṯ,ṱ,ẗ}, % ť 711 | u = {ù,ú,û,ü,ũ,ū,ŭ,ů,ű,ų,ǔ,ǖ,ǘ,ǚ,ǜ,ȕ,ȗ,ṳ,ṵ,ṷ,ṹ,ṻ,ụ,ủ,ứ,ừ,ử,ữ,ự}, 712 | v = {ṽ,ṿ}, 713 | w = {ŵ,ẁ,ẃ,ẅ,ẇ,ẉ,ẘ}, 714 | x = {ẋ,ẍ}, 715 | y = {ý,ÿ,ŷ,ȳ,ẏ,ẙ,ỳ,ỵ,ỷ,ỹ}, 716 | z = {ź,ż,ž,ẑ,ẓ,ẕ}, 717 | } 718 | % \end{macrocode} 719 | %} 720 | % \begin{macrocode} 721 | % 722 | % \end{macrocode} 723 | %\subsubsection{Basic glyph set} 724 | %\addtoUTFbookmarks{subsub:OT-inh-basic} 725 | % There are quite a few fonts out there that don't even fill the glyph set. 726 | % To prevent a plethora of warnings, they may be aliased to the surrogate font 727 | % |TU-basic|. Examples of such fonts are: Lato, Fontin and Bergamo. 728 | %\changes{v2.8b}{2021/02/21}{settings for the Lato font (\file{mt-Lato.cfg}) 729 | % (reported by \contributor dsedivec <@\at @>)} 730 | % ^^A https://tex.stackexchange.com/questions/380812/microtype-warning-unknown-slot-number-of-character-with-lato-font 731 | %\changes{v3.0}{2021/06/22}{generalise basic inheritance settings} 732 | % \begin{macrocode} 733 | %<*TU-basic> 734 | \DeclareCharacterInheritance 735 | { encoding = {TU,EU1,EU2}, 736 | family = {TU-basic} } 737 | { A = {À,Á,Â,Ã,Ä,Å}, 738 | a = {à,á,â,ã,ä,å}, 739 | C = {Ç}, 740 | c = {ç}, 741 | D = {Ð}, 742 | E = {È,É,Ê,Ë}, 743 | e = {è,é,ê,ë}, 744 | I = {Ì,Í,Î,Ï}, 745 | i = {ì,í,î,ï,ı}, 746 | L = {Ł}, 747 | l = {ł}, 748 | N = {Ñ}, 749 | n = {ñ}, 750 | O = {Ø,Ò,Ó,Ô,Õ,Ö}, 751 | o = {ø,ò,ó,ô,õ,ö}, 752 | S = {Š}, 753 | s = {š}, 754 | U = {Ù,Ú,Û,Ü}, 755 | u = {ù,ú,û,ü}, 756 | Y = {Ý,Ÿ}, 757 | % \end{macrocode} 758 | % For some reason, the \"y in the next line comes out as \ss. 759 | % Don't worry, there's really a |y diaeresis| in the source. 760 | % \begin{macrocode} 761 | y = {ý,ÿ}, 762 | Z = {Ž}, 763 | z = {ž} 764 | } 765 | % 766 | % \end{macrocode} 767 | %\subsubsection{Empty glyph set} 768 | %\addtoUTFbookmarks{subsub:OT-inh-empty} 769 | % Other fonts, \eg, the self-professedly awesone Font Awesome font, 770 | % have no meaningful glyph arsenal at all, and should therefore be 771 | % aliased so that empty settings are applied. 772 | %\changes{v2.8b}{2021/02/21}{dummy settings for the Font Awesome font (\file{mt-FontAwesome.cfg})} 773 | %\changes{v3.0}{2021/06/22}{generalise empty settings} 774 | % \begin{macrocode} 775 | %<*TU-empty> 776 | \DeclareCharacterInheritance 777 | { encoding = {TU,EU1,EU2}, 778 | family = {TU-empty} } 779 | { } 780 | % 781 | % \end{macrocode} 782 | % 783 | %\subsection{Character protrusion} 784 | %\GeneralChanges{Protrusion} 785 | %\addtoUTFbookmarks{sub:OT-protrusion} 786 | % 787 | % \begin{macrocode} 788 | 789 | %%% ----------------------------------------------------------------------- 790 | %%% PROTRUSION 791 | 792 | % \end{macrocode} 793 | %\subsubsection{Latin Modern Roman/New Computer Modern} 794 | %\addtoUTFbookmarks{subsub:OT-prot-LMR} 795 | %\changes{v3.0}{2021/08/08}{settings for New Computer Modern (provided by 796 | % \contributor Antonis Tsolomitis )} 797 | %\changes{v3.0}{2021/08/13}{fix quotation marks in } 798 | % \begin{macrocode} 799 | %<*LatinModernRoman|NewComputerModern> 800 | \SetProtrusion 801 | % [ name = LMR-default ] 802 | % [ name = NCM-default ] 803 | % { encoding = {TU,EU1,EU2}, 804 | % family = Latin Modern Roman } 805 | % { } 806 | { 807 | % \end{macrocode} 808 | %{\setmacrofont\NCM 809 | % \begin{macrocode} 810 | A = {50,50}, 811 | Æ = {50, }, 812 | F = { ,50}, 813 | J = {50, }, 814 | K = { ,50}, 815 | L = { ,50}, 816 | T = {50,50}, 817 | V = {50,50}, 818 | W = {50,50}, 819 | X = {50,50}, 820 | Y = {50,50}, 821 | k = { ,50}, 822 | r = { ,50}, 823 | t = { ,70}, 824 | v = {50,50}, 825 | w = {50,50}, 826 | x = {50,50}, 827 | y = {50,70}, 828 | 0 = { ,50}, 829 | 1 = {100,200}, 830 | 2 = {50,50}, 831 | 3 = {50,50}, 832 | 4 = {70,70}, 833 | 5 = { ,50}, 834 | 6 = { ,50}, 835 | 7 = {50,100}, 836 | 8 = { ,50}, 837 | 9 = { ,50}, 838 | . = { ,700}, 839 | {,}= { ,500}, 840 | : = { ,500}, 841 | ; = { ,500}, 842 | ! = { ,100}, 843 | ? = { ,200}, 844 | @ = {50,50}, 845 | ~ = {200,250}, 846 | \% = {50,50}, 847 | * = {300,300}, 848 | + = {250,250}, 849 | - = {400,500}, % /hyphen 850 | – = {400,300}, % /endash 851 | — = {300,200}, % /emdash 852 | _ = {200,200}, % /underscore 853 | / = {200,300}, 854 | /backslash = {200,300}, 855 | ' = {300,400}, % /quotesingle 856 | ‘ = {300,400}, ’ = {300,400}, 857 | “ = {300,300}, ” = {300,300}, 858 | ‚ = {400,400}, „ = {400,400}, 859 | ‹ = {400,400}, › = {300,500}, 860 | « = {300,200}, » = {100,400}, 861 | ¡ = {100, }, ¿ = {100, }, 862 | ( = {300, }, ) = { ,300}, 863 | < = {200,100}, > = {100,200}, 864 | /braceleft = {400,200}, /braceright = {200,400}, 865 | /angleleft = {400, }, /angleright = { ,400}, 866 | † = {100,100}, 867 | ‡ = { 80, 80}, 868 | • = {200,200}, 869 | · = {400,450}, % / periodcentered 870 | ℃ = { 80, 50}, 871 | ₡ = { , 50}, 872 | ° = {400,400}, 873 | ™ = {100,200}, 874 | © = {100,100}, 875 | ® = {100,100}, 876 | ª = {100,200}, 877 | º = {100,200}, 878 | ¹ = {200,250}, 879 | ² = { 50,100}, 880 | ³ = { 50,100}, 881 | ¬ = {200, }, 882 | − = {300,300}, 883 | ± = {150,200}, 884 | × = {150,250}, 885 | ÷ = {150,250}, 886 | € = {100, }, 887 | %<*LatinModernRoman> 888 | /one.oldstyle = {100,100}, 889 | /two.oldstyle = { 50, 50}, 890 | /three.oldstyle = { 30, 80}, 891 | /four.oldstyle = { 50, 50}, 892 | /seven.oldstyle = { 50, 80}, 893 | % 894 | %<*NewComputerModern> 895 | Ά = {50,50}, % /Alphatonos 896 | Ὰ = {120,50}, % 897 | Ἀ = {120,50}, % 898 | Ἁ = {80,50}, % 899 | Ἂ = {220,50}, % 900 | Ἃ = {220,50}, % 901 | Ἄ = {170,50}, % 902 | Ἅ = {170,50}, % 903 | Ἆ = {190,50}, % 904 | Ἇ = {190,50}, % 905 | ᾈ = {150,50}, % 906 | ᾉ = {80,50}, % 907 | ᾊ = {220,50}, % 908 | ᾋ = {220,50}, % 909 | ᾌ = {170,50}, % 910 | ᾍ = {170,50}, % 911 | ᾎ = {210,50}, % 912 | ᾏ = {210,50}, % 913 | /uni1FBC.alt = {,205}, % Alpha prosgegrammeni 914 | /uni1F88.alt = {50,190}, %Alpha psili prosgegrammeni 915 | /uni1F89.alt = {,200}, %Alpha dasia prosgegrammeni 916 | /uni1F8A.alt = {130,180}, %Alpha psili baria prosgegrammeni 917 | /uni1F8B.alt = {130,190}, %Alpha dasia baria prosgegrammeni 918 | /uni1F8C.alt = {100,190}, %Alpha psili oxia prosgegrammeni 919 | /uni1F8D.alt = {70,190}, %Alpha dasia oxia prosgegrammeni 920 | /uni1F8E.alt = {120,190}, %Alpha psili perispomeni prosgegrammeni 921 | /uni1F8F.alt = {120,190}, %Alpha dasia perispomeni prosgegrammeni 922 | % 923 | /uni1FCC.alt = {,205}, % Eta prosgegrammeni 924 | /uni1F98.alt = {185,170}, %Eta psili prosgegrammeni 925 | /uni1F99.alt = {185,170}, %Eta dasia prosgegrammeni 926 | /uni1F9A.alt = {220,170}, %Eta psili baria prosgegrammeni 927 | /uni1F9B.alt = {220,170}, %Eta dasia baria prosgegrammeni 928 | /uni1F9C.alt = {220,170}, %Eta psili oxia prosgegrammeni 929 | /uni1F9D.alt = {220,170}, %Eta dasia oxia prosgegrammeni 930 | /uni1F9E.alt = {255,170}, %Eta psili perispomeni prosgegrammeni 931 | /uni1F9F.alt = {255,170}, %Eta dasia perispomeni prosgegrammeni 932 | % 933 | Ό = {95,50}, % 934 | % 935 | Γ = { ,180}, % /Gamma 936 | % Δ = {100,100}, % /Delta 937 | % Δ = {50,50}, % /Delta 938 | Θ = { 50, 50}, % /Theta 939 | % Λ = {100,100}, % /Lambda 940 | % Λ = {50,50}, % /Lambda 941 | % Ξ = {,}, % /Xi 942 | % Π = {,}, % /Pi 943 | Σ = { 50, 50}, % /Sigma 944 | % Υ = {100,100}, % /Upsilon 945 | % Υ = {80,80}, % /Upsilon 946 | Φ = { 50, 50}, % /Phi 947 | Ψ = { 50, 50}, % /Psi 948 | %<*NewComputerModern> 949 | Ω = { 20, 30}, % /Omega 950 | Ώ = {150,30}, 951 | Ὠ = {220,30}, 952 | Ὡ = {205,30}, 953 | Ὢ = {285,30}, 954 | Ὣ = {285,30}, 955 | Ὤ = {270,30}, 956 | Ὥ = {270,30}, 957 | Ὦ = {310,30}, 958 | Ὧ = {310,30}, 959 | ᾨ = {205,30}, 960 | ᾩ = {205,30}, 961 | ᾪ = {285,30}, 962 | ᾫ = {285,30}, 963 | ᾬ = {270,30}, 964 | ᾭ = {270,30}, 965 | ᾮ = {310,30}, 966 | ᾯ = {310,30}, 967 | /uni1FFC.alt = {,230}, % Omega prosgegrammeni 968 | /uni1FA8.alt = {185,190}, %Omega psili prosgegrammeni 969 | /uni1FA9.alt = {185,190}, %Omega dasia prosgegrammeni 970 | /uni1FAA.alt = {220,190}, %Omega psili baria prosgegrammeni 971 | /uni1FAB.alt = {220,190}, %Omega dasia baria prosgegrammeni 972 | /uni1FAC.alt = {220,190}, %Omega psili oxia prosgegrammeni 973 | /uni1FAD.alt = {220,190}, %Omega dasia oxia prosgegrammeni 974 | /uni1FAE.alt = {255,190}, %Omega psili perispomeni prosgegrammeni 975 | /uni1FAF.alt = {255,190}, %Omega dasia perispomeni prosgegrammeni 976 | % 977 | α = {,50}, 978 | γ = {50,50}, 979 | ζ = {,50}, 980 | θ = {30,40}, 981 | ι = {,50}, 982 | ϊ = {-20,-30}, 983 | κ = {50,50}, 984 | λ = {50,50}, 985 | ν = {50,25}, 986 | π = {50,50}, 987 | σ = {,50}, 988 | ς = {,50}, 989 | τ = {50,50}, 990 | χ = {50,50}, 991 | ψ = {50,50}, 992 | % /uni1F98.alt = {,}, 993 | % \end{macrocode} 994 | %} 995 | % Serif doesn't include |*.end| glyphs, and the OldStyle numbers' names differ. 996 | % \begin{macrocode} 997 | } 998 | 999 | \SetProtrusion 1000 | [ name = NCM-TU, 1001 | load = NCM-default ] 1002 | { encoding = {TU,EU1,EU2}, 1003 | family = {New Computer Modern} } 1004 | { 1005 | /a.end = {,330}, 1006 | /e.end = {,350}, 1007 | /k.alt = { ,50}, 1008 | /r.end = {,300}, 1009 | /m.end = {,200}, 1010 | /n.end = {,300}, 1011 | /one.oldstyle = {100,100}, 1012 | /two.oldstyle = { 50, 50}, 1013 | /three.oldstyle = { 30, 80}, 1014 | /four.oldstyle = { 50, 50}, 1015 | /seven.oldstyle = { 50, 80}, 1016 | } 1017 | 1018 | \SetProtrusion 1019 | [ name = CMU-TU, 1020 | load = NCM-default ] 1021 | { encoding = {TU,EU1,EU2}, 1022 | family = {CMU Serif} } 1023 | { 1024 | /oneoldstyle = {100,100}, 1025 | /twooldstyle = { 50, 50}, 1026 | /threeoldstyle = { 30, 80}, 1027 | /fouroldstyle = { 50, 50}, 1028 | /sevenoldstyle = { 50, 80}, 1029 | % 1030 | } 1031 | 1032 | \SetProtrusion 1033 | % [ name = LMR-it ] 1034 | % [ name = NCM-it ] 1035 | % { encoding = {TU,EU1,EU2}, 1036 | % family = Latin Modern Roman, 1037 | % shape = {it,sl} } 1038 | % { } 1039 | { 1040 | % \end{macrocode} 1041 | %{\setmacrofont\NCM 1042 | % \begin{macrocode} 1043 | A = {125,100}, 1044 | Æ = {125,-55}, 1045 | B = {90,-40}, 1046 | C = {145,-75}, 1047 | D = {75, -28}, 1048 | E = {80,-55}, 1049 | F = {85,-80}, 1050 | G = {153,-15}, 1051 | H = {73,-60}, 1052 | I = {140,-120}, 1053 | IJ = {140,-80}, 1054 | J = {135,-80}, 1055 | K = {70,-30}, 1056 | L = {87, 40}, 1057 | M = {67,-45}, 1058 | N = {75,-55}, 1059 | O = {150,-30}, 1060 | Œ = {150,-55}, 1061 | P = {82,-50}, 1062 | Q = {150,-30}, 1063 | R = {75, 15}, 1064 | S = {90,-65}, 1065 | $ = {100,-20}, 1066 | T = {220,-85}, 1067 | U = {230,-55}, 1068 | V = {260,-60}, 1069 | W = {185,-55}, 1070 | X = {70,-30}, 1071 | Y = {250,-60}, 1072 | Z = {90,-60}, 1073 | a = {150,-10}, 1074 | b = {170, }, 1075 | c = {173,-10}, 1076 | d = {150,-55}, 1077 | e = {180, }, 1078 | f = { ,-250}, 1079 | g = {150,-10}, 1080 | h = {100, }, 1081 | i = {210, }, 1082 | ij = {210,-40}, 1083 | j = { ,-40}, 1084 | k = {110,-50}, 1085 | l = {240,-110}, 1086 | m = {80, }, 1087 | n = {115, }, 1088 | o = {155, }, 1089 | q = {170,-40}, 1090 | r = {155,-40}, 1091 | s = {130, }, 1092 | t = {230,-10}, 1093 | u = {120, }, 1094 | v = {140,-25}, 1095 | w = {98,-20}, 1096 | x = {65,-40}, 1097 | y = {130,-20}, 1098 | z = {110,-80}, 1099 | 0 = {170,-85}, 1100 | 1 = {230,110}, 1101 | 2 = {130,-70}, 1102 | 3 = {140,-70}, 1103 | 4 = {130,80}, 1104 | 5 = {160, }, 1105 | 6 = {175,-30}, 1106 | 7 = {250,-150}, 1107 | 8 = {130,-40}, 1108 | 9 = {155,-80}, 1109 | . = { ,500}, 1110 | {,}= { ,450}, 1111 | : = { ,300}, 1112 | ; = { ,300}, 1113 | & = {130,30}, 1114 | \% = {180,50}, 1115 | * = {380,20}, 1116 | + = {180,200}, 1117 | @ = {180,10}, 1118 | ~ = {200,150}, 1119 | ( = {300, }, ) = { ,70}, 1120 | / = {100,100}, 1121 | - = {500,300}, % /hyphen 1122 | – = {500,300}, % /endash 1123 | — = {400,170}, % /emdash 1124 | _ = {100,200}, % /underscore 1125 | ' = {300,400}, % /quotesingle 1126 | " = {500,300}, 1127 | ‘ = {800,200}, ’ = {800,-20}, 1128 | “ = {540,100}, ” = {500,100}, 1129 | ‚ = {300,700}, „ = {200,600}, 1130 | ‹ = {500,300}, › = {400,400}, 1131 | « = {400,100}, » = {200,300}, 1132 | ¡ = {200, }, ¿ = {200, }, 1133 | < = {300,100}, > = {200,100}, 1134 | /backslash = {300,300}, 1135 | /braceleft = {400,100}, /braceright = {200,200}, 1136 | † = {200, 80}, 1137 | ‡ = {120, 80}, 1138 | • = {220,100}, 1139 | · = {550,300}, % / periodcentered 1140 | ℃ = {170, }, 1141 | ₡ = {100, 50}, 1142 | ¶ = {200, }, 1143 | ° = {500,300}, 1144 | ™ = {200, 70}, 1145 | © = { 50, 70}, 1146 | ® = { 50, 70}, 1147 | ª = {140,100}, 1148 | º = {140,100}, 1149 | ¹ = {400,150}, 1150 | ² = {250, 80}, 1151 | ³ = {250, 80}, 1152 | ¬ = {250, 80}, 1153 | − = {300,200}, 1154 | ± = {150,170}, 1155 | × = {200,200}, 1156 | ÷ = {200,200}, 1157 | € = {150, }, 1158 | %<*LatinModernRoman> 1159 | /one.oldstyle = {100,100}, 1160 | /two.oldstyle = {100, 80}, 1161 | /three.oldstyle = { 80, 50}, 1162 | /four.oldstyle = { 80, 80}, 1163 | /five.oldstyle = { 50, }, 1164 | /six.oldstyle = { 50, }, 1165 | /seven.oldstyle = { 80, 80}, 1166 | /eight.oldstyle = { 50, }, 1167 | % 1168 | Γ = {100,120}, % /Gamma 1169 | Δ = {120,100}, % /Delta 1170 | Θ = {120, 50}, % /Theta 1171 | % Λ = {130,100}, % /Lambda 1172 | % Λ = {160,100}, % /Lambda 1173 | Ξ = {100,}, % /Xi 1174 | Π = {100,}, % /Pi 1175 | Σ = {100, 50}, % /Sigma 1176 | % Υ = {180,100}, % /Upsilon 1177 | % Υ = {260,100}, % /Upsilon 1178 | Φ = {130, 70}, % /Phi 1179 | Ψ = {130, 50}, % /Psi 1180 | Ω = { 50,}, % /Omega 1181 | %<*NewComputerModern> 1182 | Ὰ = {190,50}, % 1183 | Ἀ = {220,50}, % 1184 | Ἁ = {200,50}, % 1185 | Ἂ = {300,50}, % 1186 | Ἃ = {300,50}, % 1187 | Ἄ = {300,50}, % 1188 | Ἅ = {300,50}, % 1189 | Ἆ = {320,50}, % 1190 | Ἇ = {320,50}, % 1191 | ᾈ = {200,50}, % 1192 | ᾉ = {200,50}, % 1193 | ᾊ = {300,50}, % 1194 | ᾋ = {300,50}, % 1195 | ᾌ = {300,50}, % 1196 | ᾍ = {300,50}, % 1197 | ᾎ = {320,50}, % 1198 | ᾏ = {320,50}, % 1199 | /uni1FBC.alt = {,205}, % Alpha prosgegrammeni 1200 | /uni1F88.alt = {50,190}, %Alpha psili prosgegrammeni 1201 | /uni1F89.alt = {,200}, %Alpha dasia prosgegrammeni 1202 | /uni1F8A.alt = {130,180}, %Alpha psili baria prosgegrammeni 1203 | /uni1F8B.alt = {130,190}, %Alpha dasia baria prosgegrammeni 1204 | /uni1F8C.alt = {100,190}, %Alpha psili oxia prosgegrammeni 1205 | /uni1F8D.alt = {70,190}, %Alpha dasia oxia prosgegrammeni 1206 | /uni1F8E.alt = {120,190}, %Alpha psili perispomeni prosgegrammeni 1207 | /uni1F8F.alt = {120,190}, %Alpha dasia perispomeni prosgegrammeni 1208 | % 1209 | /uni1FCC.alt = {,205}, % Eta prosgegrammeni 1210 | /uni1F98.alt = {185,170}, %Eta psili prosgegrammeni 1211 | /uni1F99.alt = {185,170}, %Eta dasia prosgegrammeni 1212 | /uni1F9A.alt = {220,170}, %Eta psili baria prosgegrammeni 1213 | /uni1F9B.alt = {220,170}, %Eta dasia baria prosgegrammeni 1214 | /uni1F9C.alt = {220,170}, %Eta psili oxia prosgegrammeni 1215 | /uni1F9D.alt = {220,170}, %Eta dasia oxia prosgegrammeni 1216 | /uni1F9E.alt = {255,170}, %Eta psili perispomeni prosgegrammeni 1217 | /uni1F9F.alt = {255,170}, %Eta dasia perispomeni prosgegrammeni 1218 | % 1219 | Ό = {95,50}, % 1220 | Ω = {120, 30}, % /Omega 1221 | Ώ = {160,30}, 1222 | Ὠ = {250,30}, 1223 | Ὡ = {250,30}, 1224 | Ὢ = {300,30}, 1225 | Ὣ = {300,30}, 1226 | Ὤ = {300,30}, 1227 | Ὥ = {300,30}, 1228 | Ὦ = {330,30}, 1229 | Ὧ = {330,30}, 1230 | ῼ = {30,30}, 1231 | ᾨ = {230,30}, 1232 | ᾩ = {230,30}, 1233 | ᾪ = {300,30}, 1234 | ᾫ = {300,30}, 1235 | ᾬ = {300,30}, 1236 | ᾭ = {300,30}, 1237 | ᾮ = {330,30}, 1238 | ᾯ = {330,30}, 1239 | /uni1FFC.alt = {,230}, % Omega prosgegrammeni 1240 | /uni1FA8.alt = {185,190}, %Omega psili prosgegrammeni 1241 | /uni1FA9.alt = {185,190}, %Omega dasia prosgegrammeni 1242 | /uni1FAA.alt = {220,190}, %Omega psili baria prosgegrammeni 1243 | /uni1FAB.alt = {220,190}, %Omega dasia baria prosgegrammeni 1244 | /uni1FAC.alt = {220,190}, %Omega psili oxia prosgegrammeni 1245 | /uni1FAD.alt = {220,190}, %Omega dasia oxia prosgegrammeni 1246 | /uni1FAE.alt = {255,190}, %Omega psili perispomeni prosgegrammeni 1247 | /uni1FAF.alt = {255,190}, %Omega dasia perispomeni prosgegrammeni 1248 | % 1249 | α = {50,50}, 1250 | γ = {100,50}, 1251 | δ = {30,50}, 1252 | ε = {30,}, 1253 | ζ = {20,50}, 1254 | θ = {30,40}, 1255 | ι = {,50}, 1256 | ϊ = {-20,-30}, 1257 | κ = {50,50}, 1258 | λ = {-20,50}, 1259 | ν = {50,25}, 1260 | ο ={40,}, 1261 | π = {50,50}, 1262 | σ = {40,50}, 1263 | ς = {20,50}, 1264 | τ = {50,50}, 1265 | υ = {80,}, 1266 | φ = {80,}, 1267 | χ = {20,}, 1268 | ψ = {80,}, 1269 | % /uni1F98.alt = {,}, 1270 | % \end{macrocode} 1271 | %} 1272 | % \begin{macrocode} 1273 | } 1274 | 1275 | \SetProtrusion 1276 | [ name = NCM-it-TU, 1277 | load = NCM-it ] 1278 | { encoding = {TU,EU1,EU2}, 1279 | family = {New Computer Modern}, 1280 | shape = {it,sl} } 1281 | { 1282 | /a.end = {,330}, %Fix 1283 | /e.end = {,350}, %Fix 1284 | /k.alt = { ,50}, %Fix 1285 | /r.end = {,300}, %Fix 1286 | /m.end = {,200}, %Fix 1287 | /n.end = {,300}, %Fix 1288 | /one.oldstyle = {100,100}, 1289 | /two.oldstyle = {100, 80}, 1290 | /three.oldstyle = { 80, 50}, 1291 | /four.oldstyle = { 80, 80}, 1292 | /five.oldstyle = { 50, }, 1293 | /six.oldstyle = { 50, }, 1294 | /seven.oldstyle = { 80, 80}, 1295 | /eight.oldstyle = { 50, }, 1296 | } 1297 | 1298 | \SetProtrusion 1299 | [ name = CMU-it-TU, 1300 | load = NCM-it ] 1301 | { encoding = {TU,EU1,EU2}, 1302 | family = {CMU Serif}, 1303 | shape = {it,sl} } 1304 | { 1305 | /oneoldstyle = {100,100}, 1306 | /twooldstyle = {100, 80}, 1307 | /threeoldstyle = { 80, 50}, 1308 | /fouroldstyle = { 80, 80}, 1309 | /fiveoldstyle = { 50, }, 1310 | /sixoldstyle = { 50, }, 1311 | /sevenoldstyle = { 80, 80}, 1312 | /eightoldstyle = { 50, }, 1313 | % 1314 | } 1315 | % 1316 | % \end{macrocode} 1317 | %\subsubsection{Charis SIL} 1318 | %\addtoUTFbookmarks{subsub:OT-prot-Charis} 1319 | % \begin{macrocode} 1320 | %<*CharisSIL> 1321 | \SetProtrusion 1322 | [ name = Charis-default ] 1323 | { encoding = {TU,EU1,EU2}, 1324 | family = Charis SIL } 1325 | { 1326 | % \end{macrocode} 1327 | %{\setmacrofont\CharisSIL 1328 | % \begin{macrocode} 1329 | A = {50,50}, 1330 | Æ = {50,50}, 1331 | C = {50, }, 1332 | D = { ,50}, 1333 | F = { ,50}, 1334 | G = {50, }, 1335 | J = {100, }, 1336 | K = { ,50}, 1337 | L = { ,50}, 1338 | Ŀ = { ,100}, 1339 | O = {50,50}, 1340 | Œ = {50, }, 1341 | P = { ,50}, 1342 | Q = {50,70}, 1343 | R = { ,50}, 1344 | ẞ = { ,40}, % capital sharp s 1345 | T = {50,50}, 1346 | V = {50,50}, 1347 | W = {50,50}, 1348 | X = {50,50}, 1349 | Y = {50,50}, 1350 | k = { ,50}, 1351 | ŀ = { ,150}, 1352 | r = { ,50}, 1353 | t = { ,50}, 1354 | v = {50,50}, 1355 | w = {50,50}, 1356 | x = {50,50}, 1357 | y = { ,50}, 1358 | 1 = {150,150}, 1359 | 2 = {50,50}, 1360 | 3 = {50, }, 1361 | 4 = {100,50}, 1362 | 6 = {50, }, 1363 | 7 = {50,80}, 1364 | 9 = {50,50}, 1365 | . = { ,600}, 1366 | {,}= { ,500}, 1367 | : = { ,400}, 1368 | ; = { ,300}, 1369 | ! = { ,100}, 1370 | ? = { ,200}, 1371 | @ = {50,50}, 1372 | ~ = {200,250}, 1373 | \% = { ,50}, 1374 | * = {300,300}, 1375 | + = {200,250}, 1376 | / = { ,200}, 1377 | /backslash = {150,200}, 1378 | | = {200,200}, 1379 | - = {400,500}, % hyphen 1380 | – = {200,300}, % endash 1381 | — = {150,250}, % emdash 1382 | ― = {200,200}, % Horizontal Bar = \texttwelveudash 1383 | ‒ = {150,150}, % Figure Dash = \textthreequartersemdash 1384 | _ = {100,100}, 1385 | {=} = {100,100}, 1386 | ‘ = {300,400}, ’ = {300,400}, 1387 | “ = {300,300}, ” = {300,300}, 1388 | ‚ = {400,400}, „ = {300,300}, 1389 | ‹ = {400,300}, › = {300,400}, 1390 | « = {200,200}, » = {150,300}, 1391 | ¡ = {100, }, ¿ = {100, }, 1392 | ( = {200, }, ) = { ,200}, 1393 | < = {200,150}, > = {100,200}, 1394 | [ = {100, }, ] = { ,100}, 1395 | /braceleft = {200, }, /braceright = { ,300}, 1396 | † = { 80, 80}, 1397 | ‡ = {100,100}, 1398 | • = {200,200}, 1399 | ° = {150,200}, 1400 | ™ = {150,150}, 1401 | ¢ = { 50, }, 1402 | £ = { 50, }, 1403 | ¦ = {200,200}, 1404 | © = {100,100}, 1405 | ® = {100,100}, 1406 | ª = {100,200}, 1407 | º = {200,200}, 1408 | ¬ = {200, 50}, 1409 | µ = { ,100}, 1410 | ¶ = { ,100}, 1411 | · = {300,400}, 1412 | ¹ = {200,300}, 1413 | ² = {100,200}, 1414 | ³ = {100,200}, 1415 | € = {100, }, 1416 | ± = {150,200}, 1417 | × = {200,200}, 1418 | ÷ = {250,250}, 1419 | /minus = {200,200}, 1420 | − = {200,200}, 1421 | % Cyrillic 1422 | Б = { ,50}, 1423 | Г = { ,130}, 1424 | Ж = {50,50}, 1425 | З = {30,50}, 1426 | Л = {50, }, 1427 | У = {50,50}, 1428 | Ф = {50,50}, 1429 | Ч = {100, }, 1430 | Ъ = { ,50}, 1431 | Ь = { ,50}, 1432 | Э = {50,50}, 1433 | Ю = { ,40}, 1434 | Я = {50, }, 1435 | Ѵ = {50,50}, 1436 | Ҽ = {50, }, 1437 | Ђ = {50,100}, 1438 | Є = {50, }, 1439 | Љ = {50,50}, 1440 | Њ = { ,50}, 1441 | Ћ = {50,50}, 1442 | Ԅ = {100,100}, 1443 | Ԇ = {50,50}, 1444 | Ѣ = { ,50}, 1445 | Ҍ = { ,50}, 1446 | Ԉ = {50,80}, 1447 | Ԋ = { ,80}, 1448 | Ԏ = {50,50}, 1449 | Ԓ = {50, }, 1450 | Ԕ = {50,40}, 1451 | Ԗ = { ,50}, 1452 | Ԙ = {50, }, 1453 | Ԡ = { ,50}, 1454 | Ԣ = { ,50}, 1455 | Ԃ = { ,100}, 1456 | б = {50,50}, 1457 | г = { ,70}, 1458 | к = { ,50}, 1459 | л = {50, }, 1460 | т = {50,50}, 1461 | ф = {50,50}, 1462 | ч = {50, }, 1463 | ъ = { ,50}, 1464 | ь = { ,50}, 1465 | э = { ,50}, 1466 | я = {50, }, 1467 | љ = {50, }, 1468 | њ = { ,50}, 1469 | ѣ = { ,50}, 1470 | ѵ = {50,50}, 1471 | ҽ = {50, }, 1472 | ҍ = { ,50}, 1473 | ү = {50,50}, 1474 | ҕ = { ,50}, 1475 | ҧ = { ,50}, 1476 | ԃ = { ,100}, 1477 | ԅ = {100,100}, 1478 | ԇ = {50,50}, 1479 | ԉ = {50,70}, 1480 | ԋ = { ,70}, 1481 | ԙ = {50,30}, 1482 | ԡ = { ,50}, 1483 | ԣ = { ,50}, 1484 | % Д П Ц Ш Щ Ы Ҕ Ҧ Ҩ Ә Ҵ Џ Ӭ Ӡ Ԑ Ԁ 1485 | % в д ж з и м н п ц ш ы ю ђ є ћ џ ә ԑ ҩ ҵ ӡ ԁ ԍ ԏ ԓ ԕ ԗ 1486 | % Greek 1487 | Δ = {50,50}, 1488 | Ψ = {50,50}, 1489 | γ = {70,70}, 1490 | λ = {40,70}, 1491 | π = {40,50}, 1492 | ρ = { ,50}, 1493 | σ = { ,50}, 1494 | χ = {50,50}, 1495 | % \end{macrocode} 1496 | %} 1497 | % \begin{macrocode} 1498 | } 1499 | 1500 | \SetProtrusion 1501 | [ name = Charis-it ] 1502 | { encoding = {TU,EU1,EU2}, 1503 | family = Charis SIL, 1504 | shape = {it,sl} } 1505 | { 1506 | % \end{macrocode} 1507 | %{\setmacrofont\CharisSIL 1508 | % \begin{macrocode} 1509 | C = {50, }, 1510 | G = {50, }, 1511 | J = {50, }, 1512 | L = {50,50}, 1513 | O = {50, }, 1514 | Œ = {50, }, 1515 | Q = {50, }, 1516 | S = {50, }, 1517 | $ = {50, }, 1518 | T = {70, }, 1519 | o = {50,50}, 1520 | p = { ,50}, 1521 | q = {50, }, 1522 | t = { ,50}, 1523 | w = { ,50}, 1524 | y = { ,50}, 1525 | 1 = {150,100}, 1526 | 3 = {50, }, 1527 | 4 = {100, }, 1528 | 6 = {50, }, 1529 | 7 = {100, }, 1530 | . = { ,700}, 1531 | {,}= { ,600}, 1532 | : = { ,400}, 1533 | ; = { ,400}, 1534 | ? = { ,150}, 1535 | & = { ,80}, 1536 | \% = {50,50}, 1537 | * = {300,200}, 1538 | + = {250,250}, 1539 | @ = {80,50}, 1540 | ~ = {150,150}, 1541 | / = { ,150}, 1542 | /backslash = {150,150}, 1543 | - = {300,400}, % hyphen 1544 | – = {200,300}, % endash 1545 | — = {150,200}, % emdash 1546 | _ = { ,100}, 1547 | {=} = {200,200}, 1548 | ± = {150,200}, 1549 | × = {250,250}, 1550 | ÷ = {250,250}, 1551 | ° = {150,200}, 1552 | · = {300,400}, 1553 | ‘ = {400,200}, ’ = {400,200}, 1554 | “ = {300,200}, ” = {400,200}, 1555 | ‚ = {200,500}, „ = {150,500}, 1556 | ‹ = {300,400}, › = {200,500}, 1557 | « = {200,300}, » = {150,400}, 1558 | ( = {200, }, ) = { ,200}, 1559 | < = {200,200}, > = {200,200}, 1560 | /braceleft = {300, }, /braceright = { ,200}, 1561 | % Cyrillic 1562 | Ж = {50,30}, 1563 | Л = {50, }, 1564 | У = {50,30}, 1565 | Ф = {50, }, 1566 | Ч = {100, }, 1567 | Ъ = { ,50}, 1568 | Ь = { ,50}, 1569 | Э = {50,50}, 1570 | Я = {50, }, 1571 | Ѵ = {50,50}, 1572 | Љ = {50,50}, 1573 | Ԅ = {140,100}, 1574 | Ԇ = {70,50}, 1575 | Ԉ = {50,80}, 1576 | Ԋ = { ,80}, 1577 | Ԏ = {50,50}, 1578 | г = {50,50}, 1579 | д = {50,30}, 1580 | м = {50, }, 1581 | ф = {50, }, 1582 | ч = {50, }, 1583 | ъ = { ,50}, 1584 | ь = { ,50}, 1585 | э = { ,50}, 1586 | я = {50, }, 1587 | љ = {50,50}, 1588 | њ = { ,50}, 1589 | ѵ = {50,50}, 1590 | ҍ = { ,50}, 1591 | ԅ = {140,100}, 1592 | ԇ = {70,50}, 1593 | ԉ = {50,70}, 1594 | ԋ = { ,70}, 1595 | % Greek 1596 | Γ = { ,130}, 1597 | Δ = {50,50}, 1598 | Ψ = {50,50}, 1599 | γ = {70,70}, 1600 | λ = {40,70}, 1601 | π = {40,50}, 1602 | ρ = { ,50}, 1603 | σ = { ,50}, 1604 | χ = {50,50}, 1605 | % \end{macrocode} 1606 | %} 1607 | % \begin{macrocode} 1608 | } 1609 | % \end{macrocode} 1610 | % The small caps glyph names in Charis have changed with version 5.0 1611 | % of the font. We try to get the names right both with \luatex\ (where we 1612 | % can simply query the font version) and with \xetex\ (where we check for 1613 | % glyph name). 1614 | %\changes{v2.7}{2017/07/06}{automatically choose correct names for Charis small caps 1615 | % (reported by `\contributor ltcomdata <@\at @>')} 1616 | % ^^A https://tex.stackexchange.com/questions/324294/ 1617 | % \begin{macrocode} 1618 | 1619 | % quick and dirty -- maybe we'll promote this to a 1620 | % regular key some time 1621 | \define@key{MT@pr@c}{command}{\csname #1\endcsname} 1622 | 1623 | % glyph names have changed with version 5.0 of Charis SIL: 1624 | % before: /a.SC, /b.SC, ... 1625 | % after: /a.sc, /b.sc, ... 1626 | \ifx\MT@lua\@undefined 1627 | \gdef\MT@get@CHARIS@SC{ 1628 | % test whether glyph "a.sc" exists 1629 | \ifnum\numexpr\XeTeXglyphindex "a.sc"\relax > 0 1630 | \gdef\MT@CHARIS@SC{sc}% 1631 | \else 1632 | \gdef\MT@CHARIS@SC{SC}% 1633 | \fi 1634 | } 1635 | \else 1636 | \gdef\MT@get@CHARIS@SC{ 1637 | \gdef\MT@CHARIS@SC{\MT@lua{ 1638 | % check font version 1639 | % -- why doesn't this work?: 1640 | % f = font.getfont(font.current()); 1641 | % i = fontloader.info(f.filename); 1642 | % if (tonumber(i.version) < 5) then; 1643 | if (tonumber(fontloader.info(font.getfont(font.current()).filename).version) < 5) then; 1644 | tex.print("SC"); 1645 | else; 1646 | tex.print("sc"); 1647 | end 1648 | }} 1649 | } 1650 | \fi 1651 | 1652 | \SetProtrusion 1653 | [ name = Charis-sc, 1654 | load = Charis-default, 1655 | command = {MT@get@CHARIS@SC} ] 1656 | { encoding = {TU,EU1,EU2}, 1657 | family = Charis SIL, 1658 | shape = {sc} } 1659 | { 1660 | % ᴀ = {100,100}, % etc., doesn't work with \textsc 1661 | /a.\MT@CHARIS@SC = {100,100}, 1662 | /c.\MT@CHARIS@SC = {50, }, 1663 | /d.\MT@CHARIS@SC = { ,50}, 1664 | /f.\MT@CHARIS@SC = { ,50}, 1665 | /g.\MT@CHARIS@SC = {50, }, 1666 | /j.\MT@CHARIS@SC = {100, }, 1667 | /k.\MT@CHARIS@SC = { ,50}, 1668 | /l.\MT@CHARIS@SC = { ,50}, 1669 | /f_l.\MT@CHARIS@SC = { ,50}, 1670 | /o.\MT@CHARIS@SC = {50,50}, 1671 | /oe.\MT@CHARIS@SC = {50, }, 1672 | /q.\MT@CHARIS@SC = {50,70}, 1673 | /r.\MT@CHARIS@SC = { ,50}, 1674 | /t.\MT@CHARIS@SC = {50,100}, 1675 | /v.\MT@CHARIS@SC = {50,50}, 1676 | /w.\MT@CHARIS@SC = {50,50}, 1677 | /x.\MT@CHARIS@SC = {50,50}, 1678 | /y.\MT@CHARIS@SC = {50,50} 1679 | } 1680 | % 1681 | % \end{macrocode} 1682 | %\subsubsection{EB~Garamond} 1683 | %\addtoUTFbookmarks{subsub:OT-prot-EBGaramond} 1684 | %\changes{v3.0}{2021/10/25}{settings for Garamond (OpenType)} 1685 | % \begin{macrocode} 1686 | %<*EBGaramond> 1687 | \SetProtrusion 1688 | [ name = EBGaramond-TU, 1689 | load = EBGaramond-T1-LF ] 1690 | { encoding = {TU,EU1,EU2}, 1691 | family = EBGaramond } 1692 | { 1693 | /one.tosf = {150,150}, 1694 | /two.tosf = {50,50}, 1695 | /three.tosf = {50,50}, 1696 | /four.tosf = {50,50}, 1697 | /five.tosf = {50,50}, 1698 | /six.tosf = {50,50}, 1699 | /seven.tosf = {50,80}, 1700 | /eight.tosf = {50,50}, 1701 | /nine.tosf = {50,50}, 1702 | /one.lf = {50,50}, 1703 | /two.lf = {50,50}, 1704 | /four.lf = {50,50}, 1705 | /seven.lf = {50,50}, 1706 | /one.osf = {50,50}, 1707 | /two.osf = {50,50}, 1708 | /four.osf = {50,50}, 1709 | /seven.osf = {50,50}, 1710 | % \end{macrocode} 1711 | %{\setmacrofont\EBGaramond 1712 | % \begin{macrocode} 1713 | Ⅳ = { , 35}, 1714 | Ⅵ = { 35, }, 1715 | Ⅶ = { 30, }, 1716 | Ⅷ = { 25, }, 1717 | Ⅸ = { , 35}, 1718 | Ⅺ = { 35, }, 1719 | Ⅻ = { 30, }, 1720 | ⅳ = { , 25}, 1721 | ⅵ = { 25, }, 1722 | ⅶ = { 20, }, 1723 | ⅷ = { 20, }, 1724 | ⅸ = { , 25}, 1725 | ⅺ = { 25, }, 1726 | ⅻ = { 20, }, 1727 | % textcomp 1728 | \textquotesingle = {400,500}, 1729 | ˷ = {200,250}, 1730 | ƒ = { ,100}, 1731 | ₡ = { 50, }, 1732 | † = {100,100}, 1733 | ‡ = { 80, 80}, 1734 | • = { ,100}, 1735 | · = {300,400}, % periodcentered 1736 | /twodotenleader = {150,200}, 1737 | /ellipsis = {100,150}, 1738 | ℃ = { 80, }, 1739 | ° = {400,400}, 1740 | ™ = {100,100}, 1741 | © = {100,100}, 1742 | ® = {100,100}, 1743 | ª = {200,200}, 1744 | º = {200,200}, 1745 | ¹ = {200,200}, 1746 | ² = {200,200}, 1747 | ³ = {200,200}, 1748 | ¬ = {200, }, 1749 | ¶ = { ,100}, 1750 | − = {300,300}, % minus 1751 | ± = {150,200}, 1752 | × = {100,150}, 1753 | ÷ = {150,200}, 1754 | € = { 50,100}, 1755 | ¥ = { 50, 50}, 1756 | % Greek 1757 | Γ = { ,150}, 1758 | Δ = {100,100}, 1759 | Θ = { 50, 50}, 1760 | Λ = {100,100}, 1761 | Ξ = { 50, 50}, 1762 | Υ = {100,100}, 1763 | Φ = { 50, 50}, 1764 | Ψ = { 50, 50}, 1765 | Ω = { , 50}, 1766 | ζ = { , 50}, 1767 | λ = { 50, 50}, 1768 | γ = { 50, 50}, 1769 | π = { 50, 50}, 1770 | ρ = { , 50}, 1771 | σ = { 50, 50}, 1772 | τ = { 50, 50}, 1773 | χ = { 50, 50}, 1774 | φ = { 50, 50}, 1775 | ϙ = { 50, 50}, 1776 | ψ = { 50, 50}, 1777 | % Cyrillic 1778 | Г = { ,150}, 1779 | Д = { 50, 50}, 1780 | Ж = { 50, 50}, 1781 | К = { , 50}, 1782 | Л = { 50, }, 1783 | Љ = { 50, 50}, 1784 | З = { 50, 50}, 1785 | У = { 50,100}, 1786 | Ф = { 50, 50}, 1787 | Ч = { 70, }, 1788 | Я = { 50, }, 1789 | Ъ = { 50, 50}, 1790 | Ь = { , 50}, 1791 | ж = { 50, 50}, 1792 | ф = { 50, 50}, 1793 | ъ = { 50, 50}, 1794 | Ѱ = { 50, 50}, 1795 | г = { , 50}, 1796 | Ѵ = { 50, 50}, 1797 | % other 1798 | Þ = { , 50}, 1799 | þ = { , 50}, 1800 | Ʌ = {100,100}, 1801 | ⑴ = { 35, 65}, 1802 | ⒜ = { 30, 60}, 1803 | % \end{macrocode} 1804 | %} 1805 | % \begin{macrocode} 1806 | } 1807 | 1808 | \SetProtrusion 1809 | [ name = EBGaramond-it-TU, 1810 | load = EBGaramond-it-T1-LF ] 1811 | { encoding = {TU,EU1,EU2}, 1812 | family = EBGaramond, 1813 | shape = it } 1814 | { 1815 | /zero.tosf = {150,150}, 1816 | /one.tosf = {150,150}, 1817 | /two.tosf = {80,80}, 1818 | /three.tosf = {50,80}, 1819 | /four.tosf = {50,80}, 1820 | /five.tosf = {50,80}, 1821 | /six.tosf = {50,50}, 1822 | /seven.tosf = {50,100}, 1823 | /eight.tosf = {50,50}, 1824 | /nine.tosf = {50,80}, 1825 | /one.lf = {50,50}, 1826 | /two.lf = {50,50}, 1827 | /three.lf = {80,50}, 1828 | /four.lf = {50,50}, 1829 | /five.lf = {50,50}, 1830 | /six.lf = {50,50}, 1831 | /seven.lf = {50,50}, 1832 | /eight.lf = {50,50}, 1833 | /nine.lf = {50, }, 1834 | /one.osf = {50,50}, 1835 | /two.osf = {50,50}, 1836 | /three.osf = { ,80}, 1837 | /four.osf = {50,50}, 1838 | /seven.osf = {50,50}, 1839 | % \end{macrocode} 1840 | %{\setmacrofont\EBGaramond 1841 | % \begin{macrocode} 1842 | % textcomp 1843 | \textquotesingle = {800,100}, 1844 | − = {300,300}, % minus 1845 | ˷ = {200,250}, 1846 | † = {200,100}, 1847 | ‡ = { 80, 80}, 1848 | • = {300, }, 1849 | ℃ = {200, }, 1850 | ƒ = {100, }, 1851 | ₡ = {100, }, 1852 | ™ = {200, }, 1853 | © = {200,100}, 1854 | ® = {200,100}, 1855 | ¬ = {300, }, 1856 | ° = {500,100}, 1857 | ± = {200,150}, 1858 | ¹ = {300,100}, 1859 | ² = {300, }, 1860 | ³ = {300, }, 1861 | · = {300,500}, % periodcentered 1862 | /twodotenleader = {150,300}, 1863 | /ellipsis = {100,200}, 1864 | € = {100, }, 1865 | × = {200,100}, 1866 | ÷ = {200,200}, 1867 | ¶ = { ,100}, 1868 | ª = {200,200}, 1869 | º = {200,200}, 1870 | ¥ = { 50, 50}, 1871 | % Greek 1872 | Δ = {150, }, 1873 | Θ = { 50, }, 1874 | Λ = {150, }, 1875 | Υ = {100, 50}, 1876 | Φ = { 50, }, 1877 | Χ = { 50, }, 1878 | Ψ = {100, }, 1879 | Ω = { 50, }, 1880 | γ = { , 50}, 1881 | λ = { 50, }, 1882 | % Cyrillic 1883 | Ү = { 50, }, 1884 | Ч = {100, }, 1885 | З = {100, }, 1886 | % other 1887 | Þ = { 50, 50}, 1888 | þ = { , 50}, 1889 | % \end{macrocode} 1890 | %} 1891 | % \begin{macrocode} 1892 | } 1893 | 1894 | \SetProtrusion 1895 | [ name = EBGaramond-sc-TU, 1896 | load = EBGaramond-TU ] 1897 | { encoding = {TU,EU1,EU2}, 1898 | family = EBGaramond, 1899 | shape = sc } 1900 | { 1901 | % \end{macrocode} 1902 | %{\setmacrofont\EBGaramond 1903 | % \begin{macrocode} 1904 | a = {50,50}, 1905 | \ae = {50, }, 1906 | d = { ,50}, 1907 | f = { ,50}, 1908 | g = {50, }, 1909 | j = {50, }, 1910 | l = { ,50}, 1911 | o = {50,50}, 1912 | \oe = {50, }, 1913 | q = {50,70}, 1914 | r = { , 0}, 1915 | t = {50,50}, 1916 | y = {50,50}, 1917 | % Greek 1918 | α = {50,50}, 1919 | γ = { ,50}, 1920 | δ = {50,50}, 1921 | λ = {50,50}, 1922 | ο = {50,50}, 1923 | τ = {50,50}, 1924 | υ = {50,50}, 1925 | ψ = {50,50}, 1926 | % Cyrillic 1927 | т = {50,50}, 1928 | % \end{macrocode} 1929 | %} 1930 | % \begin{macrocode} 1931 | } 1932 | 1933 | \SetProtrusion 1934 | [ name = EBGaramond-scit-TU, 1935 | load = EBGaramond-it-TU ] 1936 | { encoding = {TU,EU1,EU2}, 1937 | family = EBGaramond, 1938 | shape = scit } 1939 | { 1940 | % \end{macrocode} 1941 | %{\setmacrofont\EBGaramond 1942 | % \begin{macrocode} 1943 | a = {50,50}, 1944 | \ae = {50, }, 1945 | d = { ,50}, 1946 | f = { ,50}, 1947 | g = {50, }, 1948 | j = {50, }, 1949 | l = { ,50}, 1950 | o = {50,50}, 1951 | \oe = {50, }, 1952 | q = {50,70}, 1953 | r = { , 0}, 1954 | t = {50,50}, 1955 | y = {50,50}, 1956 | % Greek 1957 | α = {50,50}, 1958 | γ = { ,50}, 1959 | δ = {50,50}, 1960 | λ = {50,50}, 1961 | ο = {50,50}, 1962 | τ = {50,50}, 1963 | υ = {50,50}, 1964 | ψ = {50,50}, 1965 | % Cyrillic 1966 | т = {50,50}, 1967 | % \end{macrocode} 1968 | %} 1969 | % \begin{macrocode} 1970 | } 1971 | % 1972 | % \end{macrocode} 1973 | %\subsubsection{Palatino} 1974 | %\addtoUTFbookmarks{subsub:OT-prot-Palatino} 1975 | % \begin{macrocode} 1976 | %<*Palatino> 1977 | \SetProtrusion 1978 | [ name = palatino-default ] 1979 | { encoding = {TU,EU1,EU2}, 1980 | family = {Palatino} } 1981 | { 1982 | % \end{macrocode} 1983 | %{\setmacrofont\Palatino 1984 | % \begin{macrocode} 1985 | A = {50,50}, 1986 | D = { ,50}, 1987 | J = {50, }, 1988 | K = { ,50}, 1989 | L = { ,50}, 1990 | O = {25, }, 1991 | T = {50,50}, 1992 | V = {50,50}, 1993 | W = {50,50}, 1994 | X = {50,50}, 1995 | Y = {50,50}, 1996 | b = { ,25}, 1997 | d = {25,30}, 1998 | f = { ,50}, 1999 | g = { ,100}, 2000 | k = { ,50}, 2001 | p = { ,50}, 2002 | q = {50, }, 2003 | r = { ,50}, 2004 | t = { ,50}, st = { ,50}, ſt = { ,50}, 2005 | v = {75,50}, 2006 | w = {50,50}, 2007 | x = {50,50}, 2008 | y = {50,70}, 2009 | 1 = {100,50}, 2010 | 2 = {25,50}, 2011 | 4 = {50, }, 2012 | 6 = {50, }, 2013 | 9 = {25, }, 2014 | Æ = {100, }, 2015 | Œ = {25, }, 2016 | . = { ,700}, ‥ = { ,350}, … = {,150}, 2017 | {,}= { ,500}, 2018 | : = { ,500}, 2019 | ; = { ,500}, 2020 | ! = { ,100}, ‼ = { ,100}, 2021 | ? = { ,200}, ‽ = { ,200}, 2022 | @ = {50,50}, 2023 | ~ = {200,250}, 2024 | & = {50,100}, 2025 | \% = {100,100}, 2026 | * = {200,200}, 2027 | + = {250,250}, 2028 | ( = {100, }, ) = { ,300}, 2029 | / = {200,300}, 2030 | - = {400,500}, 2031 | \textendash = {300,300}, \textemdash = {200,200}, 2032 | \textquoteleft = {500,700}, \textquoteright = {500,700}, 2033 | \textquotedblleft = {300,400}, \textquotedblright = {300,400}, 2034 | \textbackslash = {200,300}, 2035 | \quotesinglbase = {400,400}, \quotedblbase = {400,400}, 2036 | \guilsinglleft = {400,400}, \guilsinglright = {300,500}, 2037 | \guillemotleft = {300,300}, \guillemotright = {200,400}, 2038 | \textexclamdown = {100, }, \textquestiondown = {100, }, 2039 | \textbraceleft = {400,200}, \textbraceright = {200,400}, 2040 | \textless = {200,100}, \textgreater = {100,200}, 2041 | ≤ = {200,100}, ≥ = {100,200}, 2042 | \textminus = {300,300}, 2043 | \texttrademark = {200,200}, 2044 | \textcopyright = {200,200}, 2045 | \textregistered = {200,200}, 2046 | \textdegree = {300,300}, 2047 | ¦ = {450,500}, ¬ = {250,150}, 2048 | ⌐ = {150,250}, 2049 | · = {850, 700}, 2050 | ¶ = {100,0}, 2051 | × = {150, 300}, 2052 | ª = {300,300}, º = {300,300}, 2053 | ⁰ = {200,400}, 2054 | ¹ = {400,350}, ² = {200,300}, ³ = {250,400}, 2055 | ⁴ = {250,350}, ⁵ = {200,300}, ⁶ = {250,400}, 2056 | ⁷ = {200,450}, ⁸ = {250,400}, ⁹ = {200,350}, 2057 | ₀ = {200,400}, 2058 | ₁ = {400,250}, ₂ = {200,300}, ₃ = {250,400}, 2059 | ₄ = {250,350}, ₅ = {200,300}, ₆ = {250,400}, 2060 | ₇ = {200,450}, ₈ = {250,400}, ₉ = {200,350}, 2061 | ± = {150,100}, ÷ = {300,300}, 2062 | þ = { ,25}, 2063 | ₊ = {300,450}, ₋ = {300,450}, 2064 | ⁺ = {300,450}, ⁻ = {300,450}, 2065 | † = {200,250}, ‡ = {200,250}, 2066 | π = {50, }, 2067 | ſ = { ,50}, 2068 | № = {100,150}, 2069 | \textservicemark = {100,200}, 2070 | ‐ = {400,500}, ‑ = {400,500}, ‒ = {200,300}, 2071 | – = {205,305}, — = {200,300}, ― = {50,150}, 2072 | • = {125,200}, 2073 | % /a.sc = {50,50}, 2074 | % \end{macrocode} 2075 | %} 2076 | % \begin{macrocode} 2077 | } 2078 | 2079 | \SetProtrusion 2080 | [ name = palatino-it ] 2081 | { encoding = {TU,EU1,EU2}, 2082 | family = {Palatino}, 2083 | shape = {it,sl} } 2084 | { 2085 | % \end{macrocode} 2086 | %{\setmacrofont\Palatino 2087 | % \begin{macrocode} 2088 | A = {50,50}, 2089 | Æ = {50, }, 2090 | B = {50, }, 2091 | C = {50, }, 2092 | D = {50,50}, 2093 | E = {50, }, 2094 | F = {50, }, 2095 | G = {50, }, 2096 | H = {50, }, 2097 | K = {50, }, 2098 | L = {50, }, 2099 | O = {50, }, 2100 | Œ = {50, }, 2101 | P = {50, }, 2102 | Q = {50, }, 2103 | R = {50, }, 2104 | S = {50, }, 2105 | $ = {50, }, 2106 | T = {100, }, 2107 | U = {50, }, 2108 | V = {100,50}, 2109 | W = {50, }, 2110 | X = {50, }, 2111 | Y = {100,50}, 2112 | b = { ,50}, 2113 | c = {25, }, 2114 | g = {75, }, 2115 | i = {25, }, 2116 | m = { ,50}, 2117 | n = { ,50}, 2118 | p = { ,25}, 2119 | q = {25, }, 2120 | x = { ,50}, 2121 | 1 = {100, }, 2122 | 2 = {50, }, 2123 | 4 = {50, }, 2124 | 7 = {50, }, 2125 | . = { ,500}, ‥ = { ,350}, … = { ,200}, 2126 | {,}= { ,500}, 2127 | : = { ,300}, 2128 | ; = { ,300}, 2129 | ? = { ,300}, ‽ = { ,300}, 2130 | & = {50,50}, 2131 | \% = {100,100}, 2132 | * = {200,200}, 2133 | + = {150,200}, 2134 | @ = {50,50}, 2135 | ~ = {200,150}, 2136 | ( = {200, }, ) = { ,200}, 2137 | / = {100,200}, 2138 | - = {300,500}, 2139 | \textendash = {300,300}, \textemdash = {200,200}, 2140 | \textquoteleft = {700,400}, \textquoteright = {700,400}, 2141 | \textquotedblleft = {500,300}, \textquotedblright = {500,300}, 2142 | _ = {100,100}, 2143 | \textbackslash = {100,200}, 2144 | \quotesinglbase = {500,500}, \quotedblbase = {400,400}, 2145 | \guilsinglleft = {400,400}, \guilsinglright = {300,500}, 2146 | \guillemotleft = {300,300}, \guillemotright = {300,300}, 2147 | \textexclamdown = {100, }, \textquestiondown = {200, }, 2148 | \textbraceleft = {200,100}, \textbraceright = {200,200}, 2149 | \textless = {300,100}, \textgreater = {200,100}, 2150 | ≤ = {200,100}, ≥ = {100,200}, 2151 | ¦ = {450,500}, ¬ = {250,150}, 2152 | · = {850, 700}, 2153 | ¶ = {100,0}, 2154 | × = {150, 300}, 2155 | ª = {300,250}, ° = {300,300}, º = {300,250}, 2156 | ⁰ = {300,200}, 2157 | ¹ = {300,150}, ² = {350,200}, ³ = {250,150}, 2158 | ⁴ = {350,100}, ⁵ = {300, 50}, ⁶ = {400,100}, 2159 | ⁷ = {400, 50}, ⁸ = {250, 50}, ⁹ = {300, 50}, 2160 | ₀ = {300,300}, 2161 | ₁ = {300,350}, ₂ = {300,150}, ₃ = {250,250}, 2162 | ₄ = {400,200}, ₅ = {300,100}, ₆ = {450,200}, 2163 | ₇ = {450,150}, ₈ = {400,250}, ₉ = {400,200}, 2164 | ± = {150,100}, ÷ = {300,300}, 2165 | þ = { 50, }, 2166 | † = {250,200}, ‡ = {250,200}, 2167 | ₊ = {300,450}, ₋ = {300,450}, 2168 | ⁺ = {300,450}, ⁻ = {300,450}, 2169 | ‐ = {300,500}, ‑ = {300,500}, ‒ = {100,300}, 2170 | – = {125,305}, — = {200,300}, ― = {125,150}, 2171 | • = {125,200} 2172 | % \end{macrocode} 2173 | %} 2174 | % \begin{macrocode} 2175 | } 2176 | 2177 | \SetProtrusion 2178 | [ name = palatino-sc, 2179 | load = palatino-default ] 2180 | { encoding = {TU,EU1,EU2}, 2181 | family = {Palatino}, 2182 | shape = sc } 2183 | { 2184 | % \end{macrocode} 2185 | %{\setmacrofont\Palatino 2186 | % \begin{macrocode} 2187 | a = {50,50}, 2188 | æ = {50, }, 2189 | b = { 0, 0}, 2190 | d = { 0, 0}, 2191 | f = { 0, 0}, 2192 | g = { 0, 0}, 2193 | j = {50, }, 2194 | l = { ,50}, 2195 | o = { 0, 0}, 2196 | p = { 0, 0}, 2197 | q = { 0, }, 2198 | r = { , 0}, 2199 | t = {50,50}, 2200 | y = {50,50}, 2201 | fl = { 0,50}, 2202 | ffl = { 0,50}, 2203 | ſt = { 0,50}, 2204 | st = { 0,50} 2205 | % \end{macrocode} 2206 | %} 2207 | % \begin{macrocode} 2208 | } 2209 | % 2210 | % \end{macrocode} 2211 | %\subsubsection{Basic glyph set} 2212 | % The protrusion settings will still be loaded from \file{microtype.cfg}. 2213 | %\addtoUTFbookmarks{subsub:OT-prot-basic} 2214 | % \begin{macrocode} 2215 | % %% No settings. 2216 | % \end{macrocode} 2217 | %\subsubsection{Empty glyph set} 2218 | %\addtoUTFbookmarks{subsub:OT-prot-empty} 2219 | % \begin{macrocode} 2220 | %<*TU-empty> 2221 | \SetProtrusion 2222 | [ name = empty ] 2223 | { encoding = {TU,EU1,EU2}, 2224 | family = {TU-empty} } 2225 | { } 2226 | % 2227 | 2228 | % \end{macrocode} 2229 | % 2230 | \endinput 2231 | % 2232 | % % vim: ts=2:sw=2:et: 2233 | -------------------------------------------------------------------------------- /microtype.dtx: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schlcht/microtype/fe0c12ea97dd79f0c311a616d7b8519215db32e5/microtype.dtx -------------------------------------------------------------------------------- /microtype.ins: -------------------------------------------------------------------------------- 1 | % 2 | % ------------------------------------------------------------------------ 3 | \input docstrip 4 | \keepsilent 5 | \askonceonly 6 | \let\MetaPrefix\relax 7 | \preamble 8 | 9 | ------------------------------------------------------------------------ 10 | 11 | The `microtype' package 12 | Subliminal refinements towards typographical perfection 13 | Copyright (c) 2004--2025 R Schlicht 14 | 15 | This work may be distributed and/or modified under the conditions of the 16 | LaTeX Project Public License, either version 1.3c of this license or (at 17 | your option) any later version. The latest version of this license is in: 18 | https://www.latex-project.org/lppl.txt, and version 1.3c or later is part 19 | of all distributions of LaTeX version 2005/12/01 or later. 20 | 21 | This work has the LPPL maintenance status `maintained'. 22 | 23 | This work consists of the files microtype.dtx, microtype-utf.dtx and 24 | microtype.ins and the derived files microtype.sty, microtype-pdftex.def, 25 | microtype-luatex.def, microtype-xetex.def, microtype.lua, letterspace.sty 26 | and microtype-show.sty. 27 | 28 | % Modified versions of the configuration files (*.cfg) may be distributed 29 | % provided that: (1) the original copyright statement is not removed, and 30 | % (2) the identification string is changed. 31 | ------------------------------------------------------------------------ 32 | 33 | \endpreamble 34 | {\catcode`\^^M=13 % 35 | \gdef\declarepreambleX#1#2 36 | \endpreamble{\endgroup% 37 | \def^^M{^^J\MetaPrefix\space}% 38 | \edef#1{\firstpreamblepart\checkeoln#2\lastpreamblepart\empty}}} 39 | \def\defaultlastpreamblepart{^^J\MetaPrefix\space 40 | ------------------------------------------------------------------------ 41 | ^^J\MetaPrefix} 42 | \let\firstpreamblepart\defaultpreamble 43 | \let\lastpreamblepart \defaultlastpreamblepart 44 | \declarepreamble\lsppreamble 45 | This is a stand-alone version that only provides the letterspacing 46 | commands. Do not use this package together with the `microtype' package. 47 | Please refer to section 7 of the `microtype' documentation. 48 | \endpreamble 49 | \declarepreamble\defpreamble 50 | This file contains enginge-specific definitions. 51 | \endpreamble 52 | \declarepreamble\luapreamble 53 | This file contains auxiliary lua functions. 54 | It was originally contributed by Elie Roux . 55 | (Bugs are mine.) 56 | \endpreamble 57 | \declarepreamble\cfgpreamble 58 | This is the main configuration file for the `microtype' package. 59 | It contains settings for font expansion and character protrusion, 60 | tracking, interword spacing and additional kerning, as well as 61 | character inheritance and font set declarations. 62 | You may customise these settings here, or in a different file. 63 | Please consult the documentation for details.^^M 64 | If you think you have found improvements to these settings, please 65 | let me know.^^M 66 | When modifying this file, also change the identification line below. 67 | \endpreamble 68 | \declarepreamble\fontpreamble 69 | This is a font-specific configuration file for the `microtype' package. 70 | It may contain settings for font expansion and character protrusion, 71 | tracking, interword spacing and additional kerning, as well as 72 | character inheritance declarations. 73 | Please consult the documentation for details.^^M 74 | If you think you have found improvements to these settings, please 75 | let me know.^^M 76 | When modifying this file, also change the identification line below. 77 | \endpreamble 78 | \declarepreamble\showpreamble 79 | This companion package offers various commands that might be helpful 80 | when creating protrusion settings. See the documentation in microtype's 81 | User manual, section 10, and the examples in test-microtype.tex. 82 | \endpreamble 83 | \declarepreamble\testpreamble 84 | This file might be useful to test protrusion settings for a font. 85 | You may do with it whatever you want. 86 | \endpreamble 87 | \let\firstpreamblepart\fontpreamble 88 | \let\lastpreamblepart \empty 89 | \declarepreamble\contribpreamble^^M 90 | These settings have been prepared by, and are copied with the 91 | generous permission of: 92 | \endpreamble 93 | \let\firstpreamblepart\contribpreamble 94 | \let\lastpreamblepart \defaultlastpreamblepart 95 | \declarepreamble\haraldandkarlpreamble^^M 96 | Harald Harders and 97 | Karl Karlsson .^^M 98 | \endpreamble 99 | \declarepreamble\antonispreamble^^M 100 | Antonis Tsolomitis ^^M 101 | \endpreamble 102 | \declarepreamble\lorenpreamble^^M 103 | Loren B. Davis. (c) 2012 104 | 105 | ------------------------------------------------------------------------ 106 | Palatino is a registered trademark of Linotype GmbH. 107 | Used without permission. 108 | \endpreamble 109 | \declarepostamble\emptypostamble 110 | \endpostamble 111 | 112 | % ------------------------------------------------------------------------ 113 | 114 | \def\makefile#1#2{\file{#1}{\from{microtype.dtx}{#2}}} 115 | \def\makecfg#1#2{\makefile{mt-#2.cfg}{config,cfg-#1,#2}} 116 | \def\makeutfcfg#1{\file{mt-#1.cfg}{\from{microtype-utf.dtx}{#1}}} 117 | \def\makemixedcfg#1#2{\file{mt-#1.cfg} 118 | {\from{microtype.dtx}{config,cfg-t,#2} 119 | \from{microtype-utf.dtx}{#1}}} 120 | 121 | \usedir{tex/latex/microtype} 122 | \let\MetaPrefix\DoubleperCent 123 | \let\DEBUG\empty 124 | %\def\DEBUG{,debug} 125 | 126 | \generate{ 127 | \makefile{microtype.sty}{package\DEBUG} 128 | \usepreamble\defpreamble 129 | \makefile{microtype-pdftex.def}{pdf-\DEBUG} 130 | \makefile{microtype-luatex.def}{lua-\DEBUG} 131 | \makefile{microtype-xetex.def} {xe-\DEBUG} 132 | \usepreamble\lsppreamble 133 | \makefile{letterspace.sty}{letterspace,plain} 134 | \usepreamble\cfgpreamble 135 | \makefile{microtype.cfg}{config,cfg-t,m-t} 136 | \usepreamble\fontpreamble 137 | \makecfg{t}{bch} 138 | \makecfg{t}{blg} 139 | \makecfg{t}{cmr} 140 | \makecfg{t}{ppl} 141 | \makecfg{t}{ptm} 142 | \makecfg{t}{ugm} 143 | \makecfg{u}{msa} 144 | \makecfg{u}{msb} 145 | \makecfg{u}{euf} 146 | \makecfg{u}{eur} 147 | \makecfg{u}{eus} 148 | \makecfg{e}{zpeu} 149 | \makecfg{e}{mvs} 150 | \makeutfcfg{LatinModernRoman} 151 | \makeutfcfg{CharisSIL} 152 | \makeutfcfg{TU-basic} 153 | \makeutfcfg{TU-empty} 154 | \makemixedcfg{EBGaramond}{ebg} 155 | \usepreamble\haraldandkarlpreamble 156 | \makecfg{t}{pmn} 157 | \usepreamble\lorenpreamble 158 | \makeutfcfg{Palatino} 159 | \usepreamble\antonispreamble 160 | \makeutfcfg{NewComputerModern} 161 | \usepreamble\showpreamble 162 | \makefile{microtype-show.sty}{show\DEBUG} 163 | \usepreamble\testpreamble 164 | \makefile{test-microtype.tex}{test} 165 | } 166 | 167 | \usepostamble\emptypostamble 168 | 169 | %% package for the extra documentation 170 | %% (microtype-utf.dtx, microtype-logo.dtx, microtype-lssample.dtx): 171 | %\generate{\makefile{microtype-doc.sty}{docsty}} 172 | %% makeindex style 173 | %\generate{\makefile{microtype-gind.ist}{docist}} 174 | 175 | \def\MetaPrefix{--} 176 | \generate{ 177 | \usepreamble\luapreamble 178 | \makefile{microtype.lua}{luafile} 179 | } 180 | 181 | \obeyspaces 182 | \Msg{***********************************************************************} 183 | \Msg{* To finish installation, move all files to their appropriate places. *} 184 | \Msg{* See the documentation for details. *} 185 | \Msg{***********************************************************************} 186 | 187 | \endbatchfile 188 | -------------------------------------------------------------------------------- /testsuite/error-algorithm.tex: -------------------------------------------------------------------------------- 1 | % http://tex.stackexchange.com/questions/213164/combination-of-microtype-and-algorithm-package-fails-to-compile 2 | \documentclass{article} 3 | \usepackage[activate=true,final,tracking=true,kerning=true,spacing=true]{microtype} % improves font appearance. http://www.khirevich.com/latex/microtype/ 4 | \usepackage{algorithm} 5 | \usepackage[noend]{algpseudocode} 6 | 7 | \begin{document} 8 | 9 | \begin{algorithm} 10 | \begin{algorithmic}[1] 11 | \State $W_{out}\gets\{w_{out,1},\dots\}$ 12 | \State $W_{in}\gets\{w_{in,1},w_{in,2},\dots\}$ 13 | \State $g \gets\Call{initialGraph}{W_{in},W_{out}}$ 14 | \end{algorithmic} 15 | \end{algorithm} 16 | 17 | \end{document} 18 | -------------------------------------------------------------------------------- /testsuite/error-amsalign_lualatex.tex: -------------------------------------------------------------------------------- 1 | % https://tex.stackexchange.com/questions/590265/improper-halign-inside-s-with-lmodern-microtype-fontspec/590298#590298 2 | \documentclass{article} 3 | \usepackage{amsmath} 4 | \usepackage{lmodern} % (1) 5 | \usepackage{fontspec} % (2) 6 | \usepackage{microtype} % (3) 7 | \setmainfont{Libertinus Serif} % (4) 8 | \begin{document} 9 | \begin{align} 10 | a & b 11 | \end{align} 12 | \end{document} 13 | -------------------------------------------------------------------------------- /testsuite/error-amsmath.tex: -------------------------------------------------------------------------------- 1 | % Scott Pakin 2 | % 2012/02/09 3 | \documentclass{article} 4 | \usepackage[tracking=all]{microtype} 5 | \usepackage{amsmath} 6 | \begin{document} 7 | \begin{equation} 8 | E = mc^2 9 | \end{equation} 10 | \end{document} 11 | -------------------------------------------------------------------------------- /testsuite/error-asterisk.tex: -------------------------------------------------------------------------------- 1 | % https://tex.stackexchange.com/questions/401668/microtype-tracking-for-bold-fonts/ 2 | \documentclass{article} 3 | \usepackage[sfdefault]{FiraSans} 4 | \usepackage[verbose,tracking]{microtype} 5 | \DeclareMicrotypeSet*[tracking]{bold} 6 | { encoding = *, series = {b,bx,b*} } 7 | \SetTracking 8 | [ unit = 1pc ] 9 | { encoding = *, series = {b,x,r*} } 10 | { 550 } 11 | \begin{document} 12 | 13 | \textbf{Es irrt der Mensch.} 14 | 15 | \section{First section} 16 | 17 | Some more text. 18 | \end{document} 19 | -------------------------------------------------------------------------------- /testsuite/error-asteriskcentered.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{microtype} 3 | \SetProtrusion{font=TS1/*/*/*/*}{\textasteriskcentered={,}} 4 | \begin{document} 5 | ABC\textasteriskcentered 6 | \end{document} 7 | -------------------------------------------------------------------------------- /testsuite/error-chmath.tex: -------------------------------------------------------------------------------- 1 | % Geoff Vallis 2 | % 2007/06/07 3 | \documentclass{article} 4 | \usepackage[T1]{fontenc} 5 | \makeatletter 6 | \DeclareTextCompositeCommand{\r}{T1}{A}{% 7 | \leavevmode 8 | \setbox0\hbox{h}% 9 | \dimen@\ht0 % 10 | \advance\dimen@-1ex% 11 | \hmode@bgroup 12 | \ooalign{\hfil\raise.65\dimen@\hbox{\r{}}\hfil\crcr A}% 13 | \egroup 14 | } 15 | \makeatother 16 | \usepackage{microtype} 17 | \begin{document} 18 | \r A -- \char"C5 19 | \end{document} 20 | -------------------------------------------------------------------------------- /testsuite/error-cjk.tex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schlcht/microtype/fe0c12ea97dd79f0c311a616d7b8519215db32e5/testsuite/error-cjk.tex -------------------------------------------------------------------------------- /testsuite/error-cjkutf8.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | %\usepackage{cmap} 3 | \usepackage[T1]{CJKutf8} 4 | \usepackage{microtype} 5 | \begin{document} 6 | 7 | I am Chinese! Täst. 8 | 9 | \end{document} 10 | -------------------------------------------------------------------------------- /testsuite/error-dofont_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{fontspec} 3 | \usepackage[ngerman]{babel} 4 | \usepackage[expansion=alltext]{microtype} 5 | \setmainfont{Linux Libertine O} 6 | \newfontfamily\EBG[OpticalSize=12]{EB Garamond} 7 | \begin{document} 8 | \glqq aber\grqq\ 9 | {\EBG doch} 10 | \end{document} 11 | -------------------------------------------------------------------------------- /testsuite/error-eplain_luatex.tex: -------------------------------------------------------------------------------- 1 | \input{error-eplain_pdftex} 2 | -------------------------------------------------------------------------------- /testsuite/error-eplain_pdftex.tex: -------------------------------------------------------------------------------- 1 | \input eplain 2 | \beginpackages 3 | \tracingassigns1 4 | \tracingifs1 5 | \usepackage[letterspace=250]{letterspace} 6 | \usepackage{soul} 7 | \endpackages 8 | \input protcode 9 | \setprotcode\font 10 | \hsize=30em 11 | 12 | Here: $2_{\textls{AAA}}$ 13 | 14 | `Margin kerning is the \textls[200]{adjustments of \tenit\lsstyle the \lslig{ch}aracters at the margins} of a 15 | typeset text. A simplified employment of margin kerning is \textls*{hanging 16 | punctuation}. Margin kerning is needed for \textls*[150]{optical alignment} of the margins 17 | of a typeset text, because mechanical justification of the margins makes 18 | them look rather ragged. Some characters can make a line appear shorter to 19 | the human eye than others. Shifting \textls{such} characters by an appropriate 20 | amount into the margins would greatly improve the appearance of a typeset 21 | text. 22 | 23 | A\lslig{fi} \textls*[1200]{This} \lslig{fi} \textls{whatever or \lslig{fi} that}, 24 | 25 | \vfill \eject 26 | 27 | `Margin kerning is the \so{adjustments of the characters at the margins} of a 28 | typeset text. A simplified employment of margin kerning is \so{hanging 29 | punctuation}. Margin kerning is needed for \so{optical alignment} of the margins 30 | of a typeset text, because mechanical justification of the margins makes 31 | them look rather ragged. Some characters can make a line appear shorter to 32 | the human eye than others. Shifting such characters by an appropriate 33 | amount into the margins would greatly improve the appearance of a typeset 34 | text. 35 | 36 | \bye 37 | -------------------------------------------------------------------------------- /testsuite/error-eplainlua_luatex.tex: -------------------------------------------------------------------------------- 1 | \input luaotfload.sty 2 | \input{error-eplain_pdftex} 3 | -------------------------------------------------------------------------------- /testsuite/error-expanding.tex: -------------------------------------------------------------------------------- 1 | % https://tex.stackexchange.com/questions/687763 2 | \documentclass{article} 3 | \usepackage[T1]{fontenc} 4 | \usepackage{textcomp} 5 | \usepackage{microtype} 6 | \usepackage{listings} 7 | \renewcommand*\thelstnumber{\oldstylenums{\arabic{lstnumber}}} % nicer numbering 8 | \usepackage{hyperref} 9 | \begin{document} 10 | 11 | We are at page \pageref{sec:here}.\label{sec:here} 12 | \begin{lstlisting} 13 | import numpy as np 14 | \end{lstlisting} 15 | 16 | \end{document} 17 | -------------------------------------------------------------------------------- /testsuite/error-filespec_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{fontspec} \setmainfont{texgyrepagella-regular.otf} 3 | \usepackage{microtype} 4 | \DeclareMicrotypeAlias{texgyrepagella-regular.otf}{Palatino Linotype} 5 | \DeclareMicrotypeAlias{texgyrepagella-math.otf}{Palatino Linotype} 6 | \usepackage{unicode-math} \setmathfont{texgyrepagella-math.otf} 7 | 8 | \begin{document} 9 | \textls[400]{yyyy} 10 | \textls[300]{$xxxx$} 11 | \end{document} 12 | -------------------------------------------------------------------------------- /testsuite/error-fontdimen6.tex: -------------------------------------------------------------------------------- 1 | % https://tex.stackexchange.com/questions/600852/force-fontdimen-6-for-a-specific-font-to-silent-a-microtype-warning/ 2 | \documentclass{article} 3 | \usepackage{fdsymbol} 4 | \usepackage[tracking=all]{microtype} 5 | \begin{document} 6 | \textls[1000]{\ensuremath{\varheartsuit\varheartsuit\varheartsuit\varheartsuit\varheartsuit}} 7 | \end{document} 8 | -------------------------------------------------------------------------------- /testsuite/error-fontdimen6_dvilualatex.tex: -------------------------------------------------------------------------------- 1 | \input{error-fontdimen6} 2 | -------------------------------------------------------------------------------- /testsuite/error-fontsize-dimen.tex: -------------------------------------------------------------------------------- 1 | % https://github.com/schlcht/microtype/issues/36 2 | \documentclass{article} 3 | 4 | \ExplSyntaxOn 5 | \makeatletter 6 | 7 | % Example using \@setfontsize with ExplSyntax 8 | 9 | \dim_new:N \l__module_normalsize_size_dim 10 | \skip_new:N \l__module_normalsize_baselineskip_skip 11 | 12 | \dim_set:Nn \l__module_normalsize_size_dim { 10pt } 13 | \skip_set:Nn \l__module_normalsize_baselineskip_skip { 12pt } 14 | 15 | \DeclareDocumentCommand \normalsize { } 16 | { 17 | \@setfontsize \normalsize \l__module_normalsize_size_dim 18 | \l__module_normalsize_baselineskip_skip 19 | } 20 | 21 | % Example using \fontsize + \selectfont with ExplSyntax 22 | 23 | \dim_new:N \l__module_large_size_dim 24 | \skip_new:N \l__module_large_baselineskip_skip 25 | 26 | \dim_set:Nn \l__module_large_size_dim { 12pt } 27 | \skip_set:Nn \l__module_large_baselineskip_skip { 14pt } 28 | 29 | \DeclareDocumentCommand \large { } 30 | { 31 | \fontsize \l__module_large_size_dim \l__module_large_baselineskip_skip 32 | \selectfont 33 | } 34 | 35 | \makeatother 36 | \ExplSyntaxOff 37 | 38 | 39 | \makeatletter 40 | 41 | % Example using \@setfontsize without ExplSyntax 42 | 43 | \newdimen\small@size 44 | \newskip\small@baselineskip 45 | \small@size=9.5pt 46 | \small@baselineskip=10.5pt\relax 47 | \DeclareDocumentCommand\small{}{% 48 | \@setfontsize\small\small@size\small@baselineskip% 49 | } 50 | 51 | % Example using \fontsize + \selectfont without ExplSyntax 52 | 53 | \newdimen\footnotesize@size 54 | \newskip\footnotesize@baselineskip 55 | \footnotesize@size=8.5pt 56 | \footnotesize@baselineskip=9.5pt\relax 57 | \DeclareDocumentCommand\footnotesize{}{% 58 | \fontsize\footnotesize@size\footnotesize@baselineskip\selectfont% 59 | } 60 | 61 | \makeatother 62 | 63 | \usepackage{fix-cm} 64 | \usepackage{microtype} 65 | \usepackage{lipsum} % placeholder text 66 | 67 | \begin{document} 68 | 69 | \normalsize 70 | \lipsum[1] 71 | 72 | \large 73 | \lipsum[1] 74 | 75 | \small 76 | \lipsum[1] 77 | 78 | \footnotesize 79 | \lipsum[1] 80 | 81 | \end{document} 82 | 83 | 84 | -------------------------------------------------------------------------------- /testsuite/error-fontspec_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass[10pt]{article} 2 | \usepackage{fontspec} 3 | \usepackage[verbose,tracking]{microtype} 4 | \setmainfont[OpticalSize=12,Renderer=Basic]{EB Garamond} 5 | \begin{document} 6 | \tracingmacros1 7 | μικρός 8 | τύπος 9 | 10 | Η \textsc{Αθήνα} (Ἀθῆναι στα αρχαία ελληνικά και την καθαρεύουσα) είναι η 11 | πρωτεύουσα της Ελλάδας. Επίσης είναι η έδρα της Περιφέρειας 12 | Αττικής. Βρίσκεται στη Στερεά (Κεντρική) Ελλάδα και αποτελεί εύρωστο 13 | οικονομικό, πολιτιστικό και διοικητικό κέντρο της χώρας. Πήρε το όνομά 14 | της από τη θεά Αθηνά που ήταν και η προστάτιδά της. Η Αθήνα σήμερα 15 | είναι μία σύγχρονη πόλη αλλά και διάσημη, καθώς στην αρχαιότητα ήταν 16 | πανίσχυρη πόλη-κράτος και σημαντικότατο κέντρο πολιτισμού· θεωρείται η 17 | ιστορικότερη πόλη της Ευρώπης μαζί με τη Ρώμη. Είναι γνωστή σε όλο τον 18 | κόσμο για τα ιστορικά της μνημεία που διασώθηκαν,έστω και μερικώς, στο 19 | πέρασμα των αιώνων. Επίνειο της ιστορικής πόλης είναι το λιμάνι του 20 | Πειραιά. Πολιούχος της Πόλης των Αθηνών είναι ο Άγιος Διονύσιος ο 21 | Αρεοπαγίτης. 22 | 23 | Some \textsc{small caps}! 24 | 25 | Типогра́фика (от греч. τύπος — «\textsc{отпечаток}» и γράφω — «\textsc{пишу}») — это 26 | художественное оформление текста посредством набора и верстки. 27 | Оформление текста включает его расположение, выбор гарнитуры, 28 | кегля, длины строк и расстояния между ними (интерлиньяж), 29 | изменение пробелов между буквами (кернинг) и группами букв (трекинг). 30 | С типографикой тесно связан шрифтовой дизайн, хотя большинство 31 | типографов не рисуют шрифтов, а некоторые шрифтовые дизайнеры 32 | не считают себя типографами 33 | 34 | \end{document} 35 | 36 | -------------------------------------------------------------------------------- /testsuite/error-generic_dvilualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{microtype} 3 | \usepackage{fontspec} 4 | \setmainfont{Times New Roman} 5 | \font\test=cmr10 6 | \begin{document} 7 | \noindent Hello World.\\ 8 | \sffamily Hello World.\\ 9 | \test Hello 10 | \end{document} 11 | 12 | -------------------------------------------------------------------------------- /testsuite/error-getslot_xelatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | %\usepackage{textcomp} 3 | \usepackage{microtype} 4 | \usepackage{siunitx} 5 | \begin{document} 6 | \SI{1}{\micro\second} 7 | \end{document} 8 | 9 | -------------------------------------------------------------------------------- /testsuite/error-leftprotrusion-beamer.tex: -------------------------------------------------------------------------------- 1 | % github/38 2 | \documentclass{beamer} 3 | 4 | \usepackage[T1]{fontenc} 5 | \usepackage[verbose]{microtype} 6 | %\microtypesetup{nopatch=item} 7 | 8 | \begin{document} 9 | \begin{frame}{Overlays}{test} 10 | 11 | \begin{itemize} 12 | \item \textbf {--- Bold} 13 | \item \only<1>{---Ok} ---or not 14 | \item \textbf<2->{---Fail} ---or not 15 | \item \color<3>[rgb]{1,0,0}{---red on 3} 16 | \item \color[rgb]{1,0,0}{---red} 17 | \end{itemize} 18 | 19 | \leftprotrusion\textbf<1>{Bye} 20 | 21 | \end{frame} 22 | 23 | \end{document} 24 | -------------------------------------------------------------------------------- /testsuite/error-leftprotrusion-csq.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[french,german,english]{babel} 3 | \usepackage[T1]{fontenc} 4 | \usepackage{microtype} 5 | \SetProtrusion{font = *}{ 6 | \textquotedblleft = {1000,}, 7 | \textquoteleft = {1000,}, 8 | \guillemotleft = {1000,}, 9 | \quotedblbase = {1000,}, 10 | \quotesinglbase = {1000,}, 11 | \textemdash = {-1000,} 12 | } 13 | \SetProtrusion{font = */sf*/*/*/*}{ 14 | \textemdash = {1000,} 15 | } 16 | \usepackage{biblatex} 17 | \usepackage[autostyle]{csquotes} 18 | \MakeAutoQuote{«}{»} 19 | \MakeOuterQuote{+} 20 | \MakeForeignQuote{french}{‚}{‘} 21 | \parindent=0pt 22 | \setlength\labelsep{-.2em} 23 | \def\labelitemi{|} 24 | \def\test#1{\item#1{abc}} 25 | \begin{document} 26 | 27 | \begin{itemize} 28 | \item M 29 | \test\enquote 30 | \test{\enquote*} 31 | \item ‚abc‘ 32 | \selectlanguage{german} 33 | \item\enquote{abc\item \enquote{ABC}} 34 | \item«abc» 35 | \item+abc+ 36 | \selectlanguage{french} 37 | \test\enquote 38 | \test\textquote 39 | \test{\textquote[punct]} 40 | \test{\textquote*[\cite{citekey}][punct]} 41 | \selectlanguage{english} 42 | \test{\foreignquote{french}} 43 | \test{\foreignquote*{french}} 44 | \test{\hyphenquote{german}} 45 | \test{\hyphenquote*{german}} 46 | \test{\foreigntextquote{french}} 47 | \test{\hyphentextquote*{german}} 48 | \item\textcquote{citekey}{abcD} 49 | \item\textcquote[pre][post]{citekey}[punct]{abcF}! 50 | \item\textcquote*[pre][post]{citekey}[punct]{abcF}! 51 | \item\foreigntextcquote{french}[pre][post]{citekey}[punct]{abcG} 52 | \item\foreigntextcquote*{french}[pre][post]{citekey}[punct]{abcG} 53 | \item\blockquote{Some longer text} 54 | \item M 55 | \end{itemize} 56 | M\par 57 | \blockquote{Some longer text} 58 | \blockquote{Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text. Some longer text.} 59 | \end{document} 60 | 61 | -------------------------------------------------------------------------------- /testsuite/error-leftprotrusion.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \ifx\pdfprotrudechars\undefined 3 | \usepackage{fontspec} 4 | \else 5 | \usepackage[T1]{fontenc} 6 | \fi 7 | \usepackage[verbose]{microtype} 8 | \usepackage{csquotes,color} 9 | \usepackage{listings,verbatim,fancyvrb,hyperref} 10 | \MakeAutoQuote{“}{”} 11 | \MakeOuterQuote{"} 12 | {\catcode`<=13 13 | \gdef<#1>{\textls{#1}}} 14 | \makeatletter 15 | \long\def\@makefntext#1{% 16 | \leftskip 0pt 17 | \parindent 0pt 18 | \everypar{\parindent 0pt}% 19 | \leavevmode\llap{\@thefnmark\hskip\marginparsep}#1} 20 | \makeatother 21 | \begin{document} 22 | \catcode`<=13 23 | 24 | \def\mytitle{% issue #3 25 | \begin{center}{title\par} 26 | \end{center}} 27 | \mytitle 28 | 29 | \begin{abstract} % issue #4 30 | Test 31 | \end{abstract} 32 | 33 | \rightprotrusion{\sffamily--abc def--} 34 | 35 | \leftprotrusion{\sffamily--abc\par def--} 36 | 37 | {\leftprotrusion\color[rgb]{1,0.2,0.3}-- rgb} 38 | 39 | {\leftprotrusion\color{red}-- red} 40 | 41 | \leftprotrusion\textcolor{red}{-- text} % doesn't work yet 42 | 43 | % the following cases will not be protruded 44 | \def\xxx{--abc\par def--} 45 | \leftprotrusion\xxx % issue #6 46 | 47 | \rightprotrusion\xxx 48 | 49 | \begin{itemize} 50 | \item \"And 51 | \item --- some words (wrong output with xetex)\newline --- a new line 52 | \item — some words\newline — a new line 53 | \item \textls{Aa\par Aaa} \textemdash\ some words\newline \textemdash\ a new line \par last line 54 | \item {\lsstyle Aa\par Aaa} 55 | \item \textemdash\ some words\newline \textemdash\ a new line \par last line 56 | \item {—} some words\newline {—} a new line 57 | \item {---} some words\newline {---} a new line 58 | \item {\textemdash} some words\newline {\textemdash} a new line 59 | \item “quote” 60 | \item \enquote{A\par B} 61 | \item "quote" 62 | \item \bgroup "quote"\egroup % issue #10 63 | \item def 64 | \microtypesetup{nopatch=item} 65 | \item --- some words (without patch)\newline --- a new line 66 | \microtypesetup{patch=item} 67 | \item \textbf{---bold} 68 | \item \sffamily\textbf{---sans}\rmfamily 69 | \item \MakeUppercase{---upper} % #29 70 | \item {\sffamily\MakeUppercase{---upper sans}} 71 | \item \MakeUppercase[lang=en]{\sffamily---upper sans} 72 | \item \textbf{\Huge{---Throws an error in 3.1a}} % #31 73 | \item \texttt{\^} 74 | \end{itemize} 75 | 76 | % https://tex.stackexchange.com/questions/647223 77 | % (= issue #6) 78 | \blockquote{foo\footnote{bar.}.} 79 | 80 | \begin{flushleft} 81 | ()\\ 82 | ()\\ 83 | () 84 | \end{flushleft} 85 | 86 | \begin{verse} 87 | --A verse\\ 88 | --(very terse)\footnote{-- footnote\newline -- text\par -- end} 89 | \end{verse} 90 | \begin{equation} 91 | \label{eq:abc} 92 | a+b=c 93 | \end{equation} 94 | Test. Test. Test. Test. Test. Test. Test. Test.\hfill (1)\linebreak 95 | Test. Test. Test. Test. Test. Test. Test. Test. 96 | 97 | \begin{table} 98 | \begin{minipage}{\textwidth} 99 | ABC\footnote{--DE\newline --EF} 100 | \end{minipage} 101 | \end{table} 102 | 103 | \leftprotrusion{-- a\verb|b|i \par ic} 104 | 105 | \leftprotrusion\verb|--| 106 | 107 | \leftprotrusion{\begin{tabular}{ll}ab&bc\\de&x\end{tabular}} 108 | 109 | \leftprotrusion {-- 110 | \begin{verbatim} 111 | $ verbatim 112 | $ 2nd line 113 | \end{verbatim} 114 | } 115 | 116 | \leftprotrusion {-- 117 | %[commentchar=!] % doesn't work (because of ^^M) 118 | \begin{Verbatim} 119 | $ Verbatim 120 | ! extra text 121 | \end{Verbatim} 122 | } 123 | 124 | \leftprotrusion{--\begin{lstlisting} 125 | listing 126 | end 127 | \end{lstlisting}} 128 | 129 | \end{document} 130 | -------------------------------------------------------------------------------- /testsuite/error-leftprotrusion_lualatex.tex: -------------------------------------------------------------------------------- 1 | \input{error-leftprotrusion} 2 | -------------------------------------------------------------------------------- /testsuite/error-letterspace-qs.tex: -------------------------------------------------------------------------------- 1 | \documentclass[10pt]{article} 2 | \usepackage[T1]{fontenc} 3 | \usepackage{microtype} 4 | \usepackage{qstest} 5 | \IncludeTests{*} 6 | \LogTests{log}{*}{*} 7 | 8 | \begin{document} 9 | 10 | \newdimen\testdim 11 | 12 | \tracingoutput1 13 | \showboxbreadth\maxdimen 14 | \showboxdepth\maxdimen 15 | \def\ispace#1{(\dimexpr#1sp * \fontdimen6\font/1000\relax)} 16 | \def\okern#1{(\dimexpr#1sp * \fontdimen6\font/2000\relax)} 17 | 18 | \begin{qstest}{A}{A} 19 | \newcommand\Test[7][]{% 20 | \SetTracking[% 21 | spacing={#3},% 22 | outer spacing={#4},% 23 | outer kerning={#5}] 24 | {font=*/*/*/*/*} 25 | {#6} 26 | \ifx\relax#1\relax 27 | \setbox0\hbox{Z#2Z}% 28 | \else 29 | \setbox0\hbox{#1 #2 #1}% 30 | \fi 31 | \testdim=\wd0 32 | \typeout{=====A. \the\wd0}% 33 | #6: \fbox{\unhbox0}\par 34 | \ifx\relax#1\relax 35 | \setbox0=\hbox{Z\textls{#2}Z}% 36 | \else 37 | \setbox0=\hbox{#1 \textls{#2} #1}% 38 | \fi 39 | \typeout{=====B. \the\wd0}% 40 | \Expect*{\the\dimexpr\testdim+.#6\fontdimen6\font#7\relax}*\NearTo[0.001pt]{\the\wd0} 41 | #6: \fbox{\unhbox0}\par\hrule\par 42 | } 43 | \Test{A}{*,*,*}{*,*,*}{*,*}{999}{} 44 | \Test{A}{*,*,*}{*,*,*}{0,0} {998}{-\okern{998}*2} 45 | \Test{A A}{0,*,*}{*,*,*}{*,*}{997}{*2-\fontdimen2\font-\ispace{997}} 46 | \Test{A A}{0,0,0}{,,}{*,*}{996}{*2-\fontdimen2\font-\ispace{996}} 47 | \Test{A A}{0,0,0}{,,}{0,0}{995}{*2-\fontdimen2\font-\okern{995}*4} 48 | \Test{A A}{,,}{,,}{*,*}{994}{*2} 49 | \Test[Y]{A A}{,,}{,,}{*,*}{993}{*2} 50 | \Test[Y]{A A}{0,*,*}{,,}{*,*}{992}{*2-3\fontdimen2\font-\ispace{992}*3} % ? 51 | \Test[Y]{A A}{,,}{0,,}{*,*}{991}{*2-2\fontdimen2\font-\ispace{991}} 52 | \Test[Y]{A A}{,,}{1000*,,}{*,*}{990}{*2+2\fontdimen2\font} 53 | \Test[Y]{AA} {,,}{1000*,,}{*,*}{989}{*2+2\fontdimen2\font} 54 | \Test[Y]{A A}{,,}{500*,,}{*,*}{988}{*2+\fontdimen2\font} 55 | \Test[Y]{A A}{,,}{1000,,}{*,*}{987}{*2-2\fontdimen2\font+2\fontdimen6\font-\ispace{987}} 56 | \Test[Y]{A A}{1000*,,}{,,}{*,*}{986}{*2+3\fontdimen2\font} 57 | \Test[Y]{A A}{1000,,}{,,}{*,*}{985}{*2-3\fontdimen2\font+3\fontdimen6\font-\ispace{985}*3} 58 | \Test[Y]{A A}{1000,,}{0,,}{*,*}{984}{*2-3\fontdimen2\font+\fontdimen6\font-\ispace{984}*2} 59 | \Test{A\textls{A}}{*,*,*}{*,*,*}{*,*}{983}{} 60 | \Test{A\textls*{A}}{*,*,*}{*,*,*}{*,*}{982}{} % wrong !!! 61 | \end{qstest} 62 | \end{document} 63 | -------------------------------------------------------------------------------- /testsuite/error-letterspace-sc.tex: -------------------------------------------------------------------------------- 1 | \documentclass{book} 2 | \usepackage{microtype,xspace} 3 | %\tracingmicrotype4 4 | \SetTracking 5 | [ name = test, 6 | outer spacing = {1000*,,}, 7 | no ligatures = {f} ] 8 | { font = */*/*/sc/* } 9 | { 050 } 10 | \makeatletter 11 | \def\test#1#2{% 12 | \setbox0\hbox{#1}% 13 | \ifdim\wd0=#2 \else\showthe\wd0 \fi 14 | \box0 15 | } 16 | \def\testa#1{\test{#1}{64.04149pt }} 17 | \def\testb#1{\test{#1}{67.63034pt }} 18 | \def\x{\textsc{\textls{Hello}}\xspace} 19 | \begin{document} 20 | \testa{\textsc{\textls{Hello }}world!} 21 | 22 | \testa{\textls{\textsc{Hello }}world!} 23 | 24 | \testb{\textsc{\textls{Hello}} world!} 25 | 26 | %\testb{\textls{\textsc{Hello}} world!} % !wrong?! 27 | 28 | \testb{\textls{\textsc{Hello} }world!} 29 | 30 | \testb{\x world!} 31 | \end{document} 32 | -------------------------------------------------------------------------------- /testsuite/error-letterspace1.tex: -------------------------------------------------------------------------------- 1 | \documentclass{memoir} 2 | \usepackage[letterspace=200]{letterspace} 3 | \usepackage[T1]{fontenc} 4 | \usepackage{lmodern} 5 | \parindent=0pt 6 | \begin{document} 7 | {\lsstyle stealing sheep} 8 | 9 | A\textls*{BC}D 10 | 11 | \textls{A\lslig{ff}e} 12 | 13 | `Margin kerning is the \textls*[1200]{adjustments of the characters at the margins} of a 14 | typeset text. A simplified employment of margin kerning is \textls{hanging 15 | punctuation}. Margin kerning is needed for \textls{optical alignment} of the margins 16 | of a typeset text, because mechanical justification of the margins makes 17 | them look rather ragged. Some characters can make a line appear shorter to 18 | the human eye than others. Shifting such characters by an appropriate 19 | amount into the margins would greatly improve the appearance of a typeset 20 | text. 21 | 22 | \end{document} 23 | -------------------------------------------------------------------------------- /testsuite/error-letterspace2.tex: -------------------------------------------------------------------------------- 1 | % Maverick Woo, 2009/02/07 2 | \documentclass{article} 3 | \usepackage[tracking,letterspace=100,verbose]{microtype} 4 | \DeclareMicrotypeSet*[tracking]{mytrackingset}{encoding=OT1,size=tiny} 5 | \SetTracking 6 | [ name = default, 7 | outer kerning = {0,0}, 8 | no ligatures = {f} ] 9 | { encoding = {OT1,T1,LY1,OT4,QX}, 10 | } 11 | { } 12 | \usepackage{listings} 13 | \lstset{language=ML,breaklines=true,prebreak=\mbox{\tiny$\searrow$}} 14 | \begin{document} 15 | 16 | \begin{lstlisting} 17 | fun (f >> g) = g o f (* a wordy comment to break the line *) 18 | \end{lstlisting} 19 | 20 | \end{document} 21 | -------------------------------------------------------------------------------- /testsuite/error-letterspace3.tex: -------------------------------------------------------------------------------- 1 | \documentclass[10pt]{article} 2 | \usepackage{german} 3 | \usepackage[T1]{fontenc} 4 | \usepackage[utf8]{inputenc} 5 | \usepackage{amstext} 6 | \usepackage[letterspace=260]{microtype} 7 | \textwidth=25em 8 | \begin{document} 9 | Aber die \textls*{Tätigkeiten des täglichen Bedarfs} sind nicht zu übersehen, da es 10 | \textls{auch andere Möglichkeiten} gibt, als nur die Fragen zu stellen, die keiner zu stellen 11 | wünscht. Mit anderen Worten, es ist \textls{möglich oder gar nötig}, sich nicht nur mit 12 | solchen Fragen zu beschäftigen, auf die es nicht \textls*[400]{ankommt}, sondern sogar auch mit 13 | denjenigen, die \textls{der Welt, wie wir sie kennen}, nicht oder nicht mehr zu Gesicht stehen. 14 | 15 | Aber $A_{\text{A\textls{so wie es geht}\null}}B$ geht es nicht. 16 | 17 | Aber $A_{\textrm{\textls{so wie es geht}}}$ geht es nicht. 18 | 19 | Aber \[A_{\textrm{\textls*{so wie es geht}}} \times B\] geht es nicht. 20 | 21 | \end{document} 22 | -------------------------------------------------------------------------------- /testsuite/error-letterspace4.tex: -------------------------------------------------------------------------------- 1 | % Maverick Woo, 2009/02/24 2 | \listfiles 3 | \documentclass{article} 4 | \usepackage[tracking]{microtype} 5 | \DeclareMicrotypeSet*[tracking]{mytrackingset}{encoding=OT1,size=small} 6 | \usepackage[font=small]{caption} 7 | \begin{document} 8 | \begin{figure} 9 | \caption{Some Caption} 10 | \end{figure} 11 | 12 | \end{document} 13 | -------------------------------------------------------------------------------- /testsuite/error-letterspace_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{ebgaramond} 3 | \usepackage[letterspace=200]{microtype} 4 | \parindent=0pt 5 | \begin{document} 6 | {\lsstyle stealing sheep} 7 | 8 | A\textls*{BC}D 9 | 10 | \textls{A\lslig{ff}e} 11 | 12 | `Margin kerning is the \textls*[1200]{adjustments of the characters at the margins} of a 13 | typeset text. A simplified employment of margin kerning is \textls{hanging 14 | punctuation}. Margin kerning is needed for \textls{optical alignment} of the margins 15 | of a typeset text, because mechanical justification of the margins makes 16 | them look rather ragged. Some characters can make a line appear shorter to 17 | the human eye than others. Shifting such characters by an appropriate 18 | amount into the margins would greatly improve the appearance of a typeset 19 | text. 20 | 21 | \end{document} 22 | -------------------------------------------------------------------------------- /testsuite/error-listings-luatexja_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{listings} 3 | \usepackage{luatexja-fontspec} 4 | \usepackage{microtype} 5 | \lstMakeShortInline÷ 6 | \begin{document} 7 | Foo 8 | ÷\foo÷ 9 | \end{document} 10 | 11 | -------------------------------------------------------------------------------- /testsuite/error-listings1.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{listings} 3 | % just to make sure that microtype will have to do its work *inside* 4 | % the lstlistings (when the ptm font is loaded): 5 | \lstset{keywords=test,keywordstyle=\fontfamily{ptm}\selectfont} 6 | \usepackage[verbose,expansion=false]{microtype} 7 | \begin{document} 8 | \begin{lstlisting} 9 | test 10 | \end{lstlisting} 11 | \end{document} 12 | -------------------------------------------------------------------------------- /testsuite/error-listings2.tex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schlcht/microtype/fe0c12ea97dd79f0c311a616d7b8519215db32e5/testsuite/error-listings2.tex -------------------------------------------------------------------------------- /testsuite/error-listings3.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{listings} 3 | \usepackage{ae,aecompl} 4 | \usepackage{microtype} 5 | \begin{document} 6 | \lstset{numbers=left, numberstyle=\tiny} 7 | \lstset{emph={sin}, emphstyle=\emph} 8 | \begin{lstlisting} 9 | sin 10 | \end{lstlisting} 11 | \end{document} 12 | -------------------------------------------------------------------------------- /testsuite/error-listings4-disc.tex: -------------------------------------------------------------------------------- 1 | %\changes{v2.3d}{2009/02/08}{fix: don't adjust inside discretionary 2 | % (reported by \contributor Maverick Woo )} 3 | % ^^A private mail, 2009/02/07 4 | \documentclass{article} 5 | \usepackage[tracking]{microtype} 6 | \DeclareMicrotypeSet*[tracking]{mytrackingset}{encoding=OT1,size=tiny} 7 | \usepackage{listings} 8 | \lstset{language=ML,breaklines=true,prebreak=\mbox{\tiny$\searrow$}} 9 | \begin{document} 10 | \begin{lstlisting} 11 | fun (f >> g) = g o f (* a wordy comment to break the line *) 12 | \end{lstlisting} 13 | \end{document} 14 | -------------------------------------------------------------------------------- /testsuite/error-listings5-ae.tex: -------------------------------------------------------------------------------- 1 | % Steven Bath 2 | % 2006/09/15 3 | \documentclass{article} 4 | \usepackage{listings} 5 | \usepackage{ae,aecompl} 6 | \usepackage{microtype} 7 | \begin{document} 8 | \lstset{numbers=left, numberstyle=\tiny} 9 | \lstset{emph={sin}, emphstyle=\emph} 10 | 11 | \begin{lstlisting} 12 | sin 13 | \end{lstlisting} 14 | 15 | \end{document} 16 | 17 | -------------------------------------------------------------------------------- /testsuite/error-listings6_xelatex.tex: -------------------------------------------------------------------------------- 1 | % !TeX program = xelatex 2 | % !TeX encoding = utf-8 3 | % usage: pdflatex | lualatex | xelatex 4 | % Rolf Dieterich 5 | % 2011/04/30 6 | \documentclass{article} 7 | \pagestyle{empty}\parindent0pt 8 | \usepackage{listings,microtype} 9 | %\usepackage{unicode-math} % defines \carriagereturn 10 | 11 | \begin{document} 12 | 13 | \lstset{% 14 | breaklines=true,% 15 | prebreak=\mbox{\tiny$\searrow$},% --> FAILURE 16 | %prebreak=\carriagereturn,% --> OK 17 | } 18 | 19 | \begin{lstlisting} 20 | case(wert; 21 | 1: F_DoEins(); 22 | 2: F_DoZwei(); 23 | : F_DoSonst() 24 | ) 25 | \end{lstlisting} 26 | 27 | \end{document} 28 | -------------------------------------------------------------------------------- /testsuite/error-luainput-math_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[utf8]{luainputenc} 3 | \usepackage{fontspec} 4 | \setmainfont{Palatino} 5 | \usepackage{microtype} 6 | \usepackage{unicode-math} 7 | \begin{document} 8 | MWE $A¹$ 9 | \end{document} 10 | -------------------------------------------------------------------------------- /testsuite/error-mathchoice.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{amstext} 3 | \makeatletter 4 | \@fileswfalse 5 | \makeatother 6 | \usepackage[verbose,letterspace=200,activate=false,tracking=smallcaps]{microtype} 7 | %\usepackage[letterspace=200]{letterspace} 8 | \SetTracking 9 | [ name = XXXX, 10 | no ligatures = {f}, 11 | outer spacing = {1000,,} ] 12 | { encoding = OT1, 13 | family = *, 14 | series = m, 15 | shape = n } 16 | { } 17 | \begin{document} 18 | \tracingoutput1 19 | \showboxdepth\maxdimen 20 | \showboxbreadth\maxdimen 21 | 22 | Z \textls{AAAAA\textls*[500]{BBB}CCC\textit{CCCC}DDD\textls*{EEE}} 23 | 24 | Z \textls{AAA} BBB 25 | 26 | Z $\textls{AAA} \textls{BBB}$ BBB 27 | 28 | Z $\textrm{\textls{AAA}} BBB$ 29 | 30 | $\textrm{Z \textls*{AAA}.B \textls{BBB}}$ 31 | 32 | $\mathchoice{a B}{HH \textls{\lslig{ff}} BB}{}{}$ 33 | 34 | $\mathchoice{\textls{AAA}}{\textls{BBB}}{C}{D}$ 35 | 36 | \[\mathchoice{\textls{AA\lslig{fi}AA}}{\textls{BBB}}{C}{D}\] 37 | 38 | \[\mathchoice{\text{Z \textls{AAA} Z}}{\textls{BBB}}{C}{D}\] 39 | 40 | \[\mathchoice{Z \text{\textls{AAA}} Z}{\textls{BBB}}{C}{D}\] 41 | 42 | \[\mathchoice{\textsc{AA\lslig{fi}AA}}{\textsc{BBB}}{C}{D}\] 43 | 44 | \[\mathchoice{\text{Z {\scshape AAA} Z}}{\textsc{BBB}}{C}{D}\] 45 | 46 | \[\mathchoice{Z \text{\scshape AAA} Z}{\textsc{BBB}}{C}{D}\] 47 | 48 | % this doesn't work, by design: 49 | % $\mathchoice{\lsstyle AAA}{\lsstyle BBB}{C}{D}$ 50 | % $\mathchoice{{\lsstyle AAA}}{{\lsstyle BBB}}{C}{D}$ 51 | 52 | % but this does: 53 | $\mathchoice{\textrm{\lsstyle AAA}}{\textrm{\lsstyle BBB}}{C}{D}$ 54 | 55 | %\tracingmacros1 56 | \end{document} 57 | -------------------------------------------------------------------------------- /testsuite/error-miniltx_pdftex.tex: -------------------------------------------------------------------------------- 1 | \input miniltx 2 | \input letterspace.sty 3 | \input soul.sty 4 | \input protcode 5 | \setprotcode\font 6 | \hsize=30em 7 | 8 | Here: $2_{\textls{AAA}}$, and: $$2_{\lsstyle AAA}$$ again: $$2_{\lsstyle AAA}$$ and once more: $$2_{\textls{AAA}}$$ 9 | 10 | `Margin kerning is the \textls[200]{adjustments of \tenit\lsstyle the \lslig{ch}aracters at the margins} of a 11 | typeset text. A simplified employment of margin kerning is \textls*{hanging 12 | punctuation}. Margin kerning is needed for \textls*[150]{optical alignment} of the margins 13 | of a typeset text, because mechanical justification of the margins makes 14 | them look rather ragged. Some characters can make a line appear shorter to 15 | the human eye than others. Shifting \textls{such} characters by an appropriate 16 | amount into the margins would greatly improve the appearance of a typeset 17 | text. 18 | 19 | A\lslig{fi} \textls*[1200]{sduwbef} \lslig{fi} \textls{moglich oder gar\lslig{fi} notig}, 20 | 21 | \vfill \eject 22 | 23 | `Margin kerning is the \so{adjustments of the characters at the margins} of a 24 | typeset text. A simplified employment of margin kerning is \so{hanging 25 | punctuation}. Margin kerning is needed for \so{optical alignment} of the margins 26 | of a typeset text, because mechanical justification of the margins makes 27 | them look rather ragged. Some characters can make a line appear shorter to 28 | the human eye than others. Shifting such characters by an appropriate 29 | amount into the margins would greatly improve the appearance of a typeset 30 | text. 31 | 32 | \bye 33 | -------------------------------------------------------------------------------- /testsuite/error-noauto.tex: -------------------------------------------------------------------------------- 1 | \documentclass[12pt]{article} 2 | \ifdefined\directlua 3 | \pdfextension mapfile{+pkpmm} 4 | \pdfvariable compresslevel=0 5 | \else 6 | \pdfmapfile{+pkpmm} 7 | \pdfcompresslevel=0 8 | \fi 9 | \usepackage[T1]{fontenc} 10 | \renewcommand\rmdefault{pkpx} 11 | \usepackage[verbose,expansion,auto=false,stretch=50,step=5]{microtype} 12 | \begin{document} 13 | \hsize=8cm 14 | The microtype package provides a LaTeX interface to the micro-typographic extensions that were introduced by pdfTeX and have since also propagated to LuaTeX and XeTeX: most prominently, character protrusion and font expansion, furthermore the adjustment of interword spacing and additional kerning, as well as hyphenatable letterspacing (tracking) and the possibility to disable all or selected ligatures. These features may be applied to customisable sets of fonts, and all micro-typographic aspects of the fonts can be configured in a straight-forward and flexible way. Settings for various fonts are provided. 15 | \end{document} 16 | -------------------------------------------------------------------------------- /testsuite/error-nofontspec_xelatex.tex: -------------------------------------------------------------------------------- 1 | % https://tex.stackexchange.com/questions/416310/problem-of-amsart-and-microtype-under-xelatex 2 | \documentclass{article} 3 | %\usepackage{fontspec} 4 | \usepackage{microtype} 5 | \setlength\parindent{0pt} 6 | \SetProtrusion{font = *}{/braceleft = {1000,0}, /cwm = {100,0}} 7 | \SetProtrusion{font = */*/*/sc/*}{a = {1000,0}} 8 | \begin{document} 9 | 10 | A 11 | 12 | \textbraceleft 13 | 14 | \scshape a 15 | \end{document} 16 | -------------------------------------------------------------------------------- /testsuite/error-overflow.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{microtype,lmodern} 3 | \usepackage[T1]{fontenc} 4 | \begin{document} 5 | \fontsize{260}{280}\selectfont A 6 | \end{document} 7 | -------------------------------------------------------------------------------- /testsuite/error-polyglossia_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{polyglossia} 3 | \usepackage[babel,verbose]{microtype} 4 | \DeclareMicrotypeBabelHook 5 | {french,spanish} 6 | {protrusion=more} 7 | \SetProtrusion[factor=3000,context=more,load=T1-default,name=poly]{encoding=*}{} 8 | \setmainlanguage{english} 9 | \setotherlanguage{spanish} 10 | \setotherlanguage[autospacing]{french} 11 | \textwidth=8cm 12 | \begin{document} 13 | 14 | If you are familiar with the babel package, you will note that polyglossia’s language naming slightly differs. Whereas babel has a unique name for each language variety (e.g., american and british), polyglossia differentiates language varieties via language options (e.g., english, variant=american). 15 | 16 | \foreignlanguage{spanish}{% 17 | If you are familiar with the babel package, you will note that polyglossia’s language naming slightly differs. Whereas babel has a unique name for each language variety (e.g., american and british), polyglossia differentiates language varieties via language options (e.g., english, variant=american).\par} 18 | 19 | \begin{french} 20 | If you are familiar with the babel package: you will note that polyglossia’s language naming slightly differs. Whereas babel has a unique name for each language variety (e.g., american and british), polyglossia differentiates language varieties via language options (e.g., english, variant=american).\par 21 | \end{french} 22 | 23 | \end{document} 24 | -------------------------------------------------------------------------------- /testsuite/error-psnfss.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[T1]{fontenc} 3 | %\usepackage{amsmath,amsfonts} 4 | \usepackage{mathpazo} 5 | \usepackage[verbose,letterspace=400]{microtype} 6 | %\usepackage{letterspace} 7 | \begin{document} 8 | \textls{$bb$-cda} 9 | $aa$ hhhh 10 | 11 | $\textls{\Bigg(}$ 12 | 13 | \[\sum^1_0\] 14 | \end{document} 15 | 16 | -------------------------------------------------------------------------------- /testsuite/error-soul.tex: -------------------------------------------------------------------------------- 1 | % https://github.com/latex3/babel/issues/53 2 | \documentclass{article} 3 | \usepackage{microtype} 4 | \usepackage{soul} 5 | \makeatletter 6 | %\let\MT@SOUL@doword\SOUL@doword 7 | %\def\SOUL@doword{\pdfadjustspacing=0\MT@SOUL@doword} 8 | \makeatother 9 | 10 | % this is the default for textsterling and it works 11 | \DeclareTextCommandDefault{\textsterling}{\UseTextSymbol{TS1}{\textsterling}} 12 | \DeclareTextSymbol\textsterling{TS1}{163} 13 | 14 | % this one fails also fails if I point to OT1 15 | % the moment microtype is added 16 | 17 | \DeclareTextCommandDefault{\textsterling}{\UseTextSymbol{T1}{\textsterling}} 18 | \DeclareTextSymbol\textsterling{T1}{191} 19 | %\def\pounds{Pounding} 20 | 21 | 22 | \begin{document} 23 | 24 | \pounds 25 | 26 | \hl{a b \pounds{} c} 27 | 28 | \end{document} 29 | -------------------------------------------------------------------------------- /testsuite/error-svjour3.tex: -------------------------------------------------------------------------------- 1 | \documentclass[final]{svjour3} 2 | \usepackage{newtxmath} 3 | \usepackage{microtype} 4 | \begin{document} 5 | abc 6 | \end{document} 7 | 8 | -------------------------------------------------------------------------------- /testsuite/error-tabular.tex: -------------------------------------------------------------------------------- 1 | % From: gmx.net> 2 | % Subject: Re: microstyle.sty and \textbf 3 | % Newsgroups: gmane.comp.tex.live, gmane.comp.tex.macosx 4 | % Date: 2004-11-16 19:17:38 GMT 5 | % 6 | \documentclass{article} 7 | \renewcommand{\rmdefault}{ppl} 8 | \usepackage[expansion=false]{microtype} 9 | \begin{document} 10 | \begin{tabular}{c} 11 | \textbf{Ha!} 12 | \end{tabular} 13 | \end{document} 14 | -------------------------------------------------------------------------------- /testsuite/error-tagpdf.tex: -------------------------------------------------------------------------------- 1 | % https://github.com/u-fischer/tagpdf/issues/49 2 | \RequirePackage{pdfmanagement-testphase} 3 | \DeclareDocumentMetadata 4 | { 5 | testphase = tagpdf, % load 6 | } 7 | \documentclass{article} 8 | \usepackage{microtype} 9 | \begin{document} 10 | \begin{quotation} 11 | Hello world 12 | \end{quotation} 13 | 14 | \end{document} 15 | 16 | -------------------------------------------------------------------------------- /testsuite/error-tcolorbox.tex: -------------------------------------------------------------------------------- 1 | % MID: 2 | \documentclass[10pt]{scrbook} 3 | \KOMAoptions{BCOR=1cm} 4 | \usepackage[osf,sc]{mathpazo} 5 | 6 | % ohne ellipsis kommt ein anderer fehler 7 | \usepackage[xspace]{ellipsis} 8 | 9 | % parameters from 10 | % http://texdoc.net/texmf-dist/doc/latex/microtype/microtype.pdf 11 | % page 17 12 | \usepackage[tracking=true]{microtype} 13 | \DeclareMicrotypeSet*[tracking]{my} 14 | { encoding = *, 15 | size = {-small,Large-}, 16 | font = */*/*/sc/* } 17 | 18 | \usepackage{tcolorbox} 19 | \tcbuselibrary{theorems,breakable} 20 | \newtcbtheorem 21 | [] 22 | {mydefinition} 23 | {Definition} 24 | {breakable,top=4pt} 25 | {definition} 26 | 27 | \begin{document} 28 | 29 | \chapter{A} 30 | \newpage 31 | a\newpage 32 | 33 | \newcommand{\textI}{textJ textJ} 34 | \newcommand{\textH}{\textI \textI} 35 | \newcommand{\textG}{\textH \textH} 36 | \newcommand{\textF}{\textG \textG} 37 | \newcommand{\textE}{\textF \textF} 38 | \newcommand{\textD}{\textE \textE} 39 | \newcommand{\textC}{\textD \textD} 40 | \newcommand{\textB}{\textC \textC} 41 | \newcommand{\textA}{\textB \textB} 42 | 43 | \textA 44 | \textA 45 | \textC 46 | \textD 47 | 48 | % \section{abc} liefert keinen fehler 49 | \section{$\text{abc}$} 50 | \textA\textB\textC 51 | 52 | \begin{mydefinition}{x}{x} 53 | \begin{math} 54 | a\\ 55 | a 56 | \end{math} 57 | \end{mydefinition} 58 | 59 | \end{document} 60 | 61 | -------------------------------------------------------------------------------- /testsuite/error-tikz.tex: -------------------------------------------------------------------------------- 1 | \documentclass{scrreprt} 2 | \usepackage[letterspace=150]{microtype} 3 | \usepackage{tikz} 4 | \usetikzlibrary{automata,positioning} 5 | \usepackage{pgfplots} 6 | \SetTracking 7 | [ name = XXXX, 8 | no ligatures = {f}, 9 | outer spacing = {1000,,} ] 10 | { encoding = OT1, 11 | family = *, 12 | series = m, 13 | shape = n } 14 | { } 15 | 16 | \begin{document} 17 | A \textls{BBB} A 18 | 19 | \begin{tikzpicture} 20 | \draw(0,0) -- node[anchor=west,text width=5cm]{\textls[200]{test}}(1,1); 21 | \draw(0,0) -- node[anchor=west,text width=5cm]{a \textls[200]{test} A}(10,1); 22 | \draw(0,0) -- node[anchor=west,text width=5cm]{\textls*[200]{test}}(5,1); 23 | \end{tikzpicture} 24 | 25 | \begin{tikzpicture} 26 | \draw(0,0) -- node[anchor=west,text width=5cm]{\textls*{test}}(1,1); 27 | % The following reported by \contributor Daniel Dumke 28 | % http://tug.org/pipermail/tex-live/2013-July/034007.html 29 | \node[rotate=-270] at (0.646,4.683) {\lsstyle Supply}; 30 | \end{tikzpicture} 31 | 32 | % The following reported by \contributor Christian Stark 33 | % 2009/07/28, MID: <7d81lgF2ad3ckU1@mid.dfncis.de> 34 | \begin{tikzpicture} 35 | \node[state] (N0) {N0}; 36 | \node[state] (N1) [above right=of N0] {N1}; 37 | \path[->,bend left] (N0) edge node {A\textls{abc}A} (N1); 38 | \path[->,bend right] (N0) edge node {\lsstyle xyz} (N1); 39 | \end{tikzpicture} 40 | 41 | A \textls{BBB} A 42 | 43 | % The following reported by \contributor Karl Karlsson 44 | % ^^A private mail, 2009/10/21 45 | \begin{tikzpicture} 46 | \begin{loglogaxis}[ 47 | xlabel=\lsstyle\textsc{Dof}, 48 | ylabel=\lsstyle $L_2$ Error 49 | ] 50 | \axispath\draw 51 | (7.49165,-10.02171) 52 | |- (8.31801,-11.32467) 53 | node[near start,left] {$\frac{dy}{dx} = -1.58$}; 54 | \addplot plot coordinates { 55 | (5, 8.312e-02) 56 | (17, 2.547e-02) 57 | (49, 7.407e-03) 58 | (129, 2.102e-03) 59 | (321, 5.874e-04) 60 | (769, 1.623e-04) 61 | (1793, 4.442e-05) 62 | (4097, 1.207e-05) 63 | (9217, 3.261e-06) 64 | }; 65 | \legend{$d=2$\\$d=3$\\$d=4$\\$d=5$\\$d=6$\\} 66 | 67 | \end{loglogaxis} 68 | \end{tikzpicture} 69 | 70 | \end{document} 71 | 72 | -------------------------------------------------------------------------------- /testsuite/error-tikz_pdftex.tex: -------------------------------------------------------------------------------- 1 | \input miniltx.tex 2 | \input tikz.tex 3 | \usetikzlibrary{automata,positioning} 4 | \input letterspace.sty 5 | 6 | A \textls{BBB} A 7 | 8 | \tikzpicture 9 | \draw(0,0) -- node[anchor=west,text width=5cm]{\textls[200]{test}}(1,1); 10 | \draw(0,0) -- node[anchor=west,text width=5cm]{a \textls[200]{test} A}(10,1); 11 | \draw(0,0) -- node[anchor=west,text width=5cm]{\textls*[200]{test}}(5,1); 12 | \endtikzpicture 13 | 14 | \tikzpicture 15 | \draw(0,0) -- node[anchor=west,text width=5cm]{\textls*{test}}(1,1); 16 | % The following reported by \contributor Daniel Dumke 17 | % http://tug.org/pipermail/tex-live/2013-July/034007.html 18 | \node[rotate=-270] at (0.646,4.683) {\lsstyle Supply}; 19 | \endtikzpicture 20 | 21 | % The following reported by \contributor Christian Stark 22 | % 2009/07/28, MID: <7d81lgF2ad3ckU1@mid.dfncis.de> 23 | \tikzpicture 24 | \node[state] (N0) {N0}; 25 | \node[state] (N1) [above right=of N0] {N1}; 26 | \path[->,bend left] (N0) edge node {A\textls{abc}A} (N1); 27 | \path[->,bend right] (N0) edge node {\lsstyle xyz} (N1); 28 | \endtikzpicture 29 | 30 | A \textls{BBB} A 31 | 32 | \bye 33 | -------------------------------------------------------------------------------- /testsuite/error-titlesec.tex: -------------------------------------------------------------------------------- 1 | \documentclass{memoir} 2 | \usepackage[raggedright]{titlesec} 3 | \usepackage{microtype} 4 | \titleformat*{\chapter}{\lsstyle} 5 | 6 | \begin{document} 7 | \chapter{~Quick Reference~}~ 8 | 9 | \textls{~} 10 | \end{document} 11 | -------------------------------------------------------------------------------- /testsuite/error-tracking-zero-fontdimen.tex: -------------------------------------------------------------------------------- 1 | %\changes{v2.3e}{2009/08/31}{fix: gobble settings correctly with tracking 2 | % (found by \contributor Leo )} 3 | % ^^A MID: 4 | \documentclass{article} 5 | \usepackage{fourier} 6 | \usepackage{microtype} 7 | \begin{document} 8 | \textls[160]{$2\times2$} 9 | \end{document} 10 | -------------------------------------------------------------------------------- /testsuite/error-uplatex_uplatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass[dvipdfmx]{utarticle} 2 | \usepackage{microtype} 3 | \begin{document} 4 | \section{芥川龍之介「るしへる」} 5 | 破提宇子と云う天主教を弁難した書物のある事は、知っている人も少くあるまい。これは、元和六年、加賀の禅僧巴毗弇なるものの著した書物である。巴毗弇は当初南蛮寺に住した天主教徒であったが、その後何かの事情から、DS 如来を捨てて仏門に帰依する事になった。書中に云っている所から推すと、彼は老儒の学にも造詣のある、一かどの才子だったらしい。 6 | 7 | \section{樋口一葉「大つごもり」} 8 | お母樣御機嫌よう好い新年をお迎へなされませ、左樣ならば參りますと、暇乞わざと恭しく、お峰下駄を直せ、お玄關からお歸りではないお出かけだぞとづぶ〳〵しく大手を振りて、行先は何處、父が涙は一夜の [...] 9 | 10 | \end{document} 11 | 12 | -------------------------------------------------------------------------------- /testsuite/error-varwidth-standalone.tex: -------------------------------------------------------------------------------- 1 | % gh/#43 2 | \documentclass[varwidth=5.5cm,border=1cm]{standalone} 3 | \usepackage{microtype} 4 | \begin{document} 5 | \section{varwidth} 6 | 7 | Likewise, the varwidth package de- and reassembles vboxes line by line, in the course of which margin kerns will get lost. 8 | \end{document} 9 | -------------------------------------------------------------------------------- /testsuite/error-x.tex: -------------------------------------------------------------------------------- 1 | % Peter Meier 2 | % 2007/11/13 3 | \documentclass{memoir} 4 | \usepackage[english,french]{babel} 5 | \usepackage[T1]{fontenc} 6 | \let\eTeXversion\undefined 7 | \usepackage[kerning,tracking,verbose,babel]{microtype} 8 | \begin{document} 9 | Lorem ipsum dolor sit amet, consectetuer adipiscing elit, sed diam nonummy nibh euismod tincidunt ut laoreet 10 | dolore magna aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit 11 | lobortis nisl ut aliquip ex ea commodo consequat. Duis autem vel eum iriure dolor in hendrerit in vulputate velit 12 | esse molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero et accumsan et iusto odio dignissim qui 13 | blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. \textls{Lorem ipsum dolor sit} 14 | amet, consectetuer adipiscing elit, sed diam no\textls*{num}my nibh euismod tincidunt ut laoreet dolore magna 15 | aliquam erat volutpat. Ut wisi enim ad minim veniam, quis nostrud exerci tation ullamcorper suscipit lobortis nisl ut 16 | aliquip ex ea commodo consequat. Duis autem vel eum \textls[200]{iriure dolor in hendrerit in vulputate velit 17 | esse} molestie consequat, vel illum dolore eu feugiat nulla facilisis at vero et accumsan et iusto odio dignissim qui 18 | blandit praesent luptatum zzril delenit augue duis dolore te feugait nulla facilisi. Nam liber tempor cum soluta nobis 19 | eleifend option congue nihil imperdiet doming id quod mazim placerat facer possim assum. 20 | 21 | \textmicrotypecontext{spacing=nonfrench}{AAA. BBB} 22 | 23 | \ifx\x\undefined\else 24 | \PackageError{microtype}{\string\x\space is defined:\MessageBreak\x} 25 | \fi 26 | 27 | \ifx\y\undefined\else 28 | \PackageError{microtype}{\string\y\space is defined:\MessageBreak\y} 29 | \fi 30 | 31 | \end{document} 32 | -------------------------------------------------------------------------------- /testsuite/error-xkeyval.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{xkeyval} 3 | \usepackage[ factor = 1500 , verbose,expansion = false]{microtype} 4 | \SetProtrusion 5 | [ name = test , 6 | factor = 750 ] 7 | { font = * } 8 | { - = {1000,1000}, 9 | A = {1000,1000}, 10 | l = {1000,1000} } 11 | \textwidth=10cm 12 | 13 | \begin{document} 14 | `Margin kerning is the adjustments of the characters at the margins of a 15 | typeset text. A simplified employment of margin kerning is hanging 16 | punctuation. Margin kerning is needed for optical alignment of the margins 17 | of a typeset text, because mechanical justification of the margins makes 18 | them look rather ragged. Some characters can make a line appear shorter to 19 | the human eye than others. Shifting such characters by an appropriate 20 | amount into the margins would greatly improve the appearance of a typeset 21 | text. 22 | 23 | Composing with font expansion is the method to use a wider or narrower 24 | variant of a font to make interword spacing more even. A font in a loose 25 | line can be substituted by a wider variant so the interword spaces are 26 | stretched by a smaller amount. Similarly, a font in a tight line can be 27 | replaced by a narrower variant to reduce the amount that the interword 28 | spaces are shrunk by. There is certainly a potential danger of font 29 | distortion when using such manipulations, thus they must be used with 30 | extreme care. The potentiality to adjust a line width by font expansion can 31 | be taken into consideration while a paragraph is being broken into lines, 32 | in order to choose better breakpoints.' 33 | 34 | \end{document} 35 | -------------------------------------------------------------------------------- /testsuite/errorx-wordcount.tex: -------------------------------------------------------------------------------- 1 | % Newsgroups: comp.text.tex 2 | % Von: Ross Hetherington 3 | % Datum: Sun, 11 Feb 2007 17:13:41 +0000 4 | % Lokal: So 11 Feb. 2007 18:13 5 | % Betreff: wordcount.sh + microtype 6 | % 7 | \documentclass{minimal} 8 | \usepackage{microtype} 9 | \begin{document} 10 | Test 11 | \end{document} 12 | -------------------------------------------------------------------------------- /testsuite/output-ABD.tex: -------------------------------------------------------------------------------- 1 | % Marcin Borkowski 2 | % 2009/08/31 3 | \documentclass[11pt]{article} 4 | \tracingoutput1 5 | \showboxbreadth100 6 | \showboxdepth100 7 | \AtBeginDocument{!} 8 | \usepackage{microtype} 9 | \begin{document} 10 | ! 11 | \end{document} 12 | 13 | ! grep '\.\.\.\.\\glue 4' 14 | 15 | -------------------------------------------------------------------------------- /testsuite/output-beamer.tex: -------------------------------------------------------------------------------- 1 | \documentclass{beamer} 2 | \usepackage{microtype} 3 | \begin{document} 4 | \begin{frame} 5 | 0\footnote{--2} 6 | \end{frame} 7 | \end{document} 8 | 9 | ! grep 'Unable to apply patch' 10 | -------------------------------------------------------------------------------- /testsuite/output-capitalcaron.tex: -------------------------------------------------------------------------------- 1 | % 2 | % \capitalcaron 3 | % 4 | % Newsgroups: de.comp.text.tex 5 | % Von: Stephan Hennig 6 | % Datum: Mon, 13 Jun 2005 18:14:13 +0200 7 | % Lokal: Mo 13 Jun. 2005 17:14 8 | % Betreff: microtype und \capitalcaron 9 | % 10 | \tracingoutput1 11 | \showboxbreadth\maxdimen 12 | \showboxdepth\maxdimen 13 | \documentclass{article} 14 | \usepackage{textcomp} 15 | \usepackage{microtype} 16 | \begin{document} 17 | \capitalcaron{C} 18 | \end{document} 19 | 20 | grep '\.\.\.\.\\kern -6\.1105 (for accent)' 21 | 22 | -------------------------------------------------------------------------------- /testsuite/output-etex-spaces.tex: -------------------------------------------------------------------------------- 1 | % 2 | % spaces with non-etex 3 | % 4 | % Newsgroups: de.comp.text.tex 5 | % Von: Mark Rossi 6 | % Datum: Tue, 24 May 2005 08:24:16 +0200 7 | % Lokal: Di 24 Mai 2005 07:24 8 | % Betreff: [microtype] 2 x seltsames Verhalten 9 | % 10 | \tracingoutput1 11 | \showboxbreadth\maxdimen 12 | \showboxdepth\maxdimen 13 | \documentclass[a4paper]{scrartcl} 14 | \usepackage[ansinew]{inputenc} 15 | \usepackage[T1]{fontenc} 16 | \usepackage{german} 17 | \let\eTeXversion\undefined 18 | \usepackage[protrusion={true,nocompatibility}, expansion={false}]{microtype} 19 | %\usepackage{hyperref} 20 | \begin{document} 21 | \begin{abstract} 22 | Bla blablub bla rum bla der das. \textit{Terhardt} Bla blablub bla rum bla der das. Bla blablub bla rum bla der das. 23 | Bla blablub bla rum bla der das. 24 | \end{abstract} 25 | 26 | Bla blablub bla rum bla der das. Bla blablub bla rum bla der das. Bla blablub bla rum bla der das. Bla blablub bla rum 27 | bla der das\footnote{Bla blablub bla rum bla der das. Bla blablub bla rum bla der das. Bla blablub bla rum bla der 28 | das. Bla blablub bla rum bla der das. Bla blablub bla rum bla der das.}. 29 | \end{document} 30 | 31 | ! grep '^Overfull ' 32 | 33 | -------------------------------------------------------------------------------- /testsuite/output-exscale.tex: -------------------------------------------------------------------------------- 1 | % http://tex.stackexchange.com/questions/316231/microtype-and-exscale-crashing-in-texlive-2016 2 | % cf. error-psnfss.tex 3 | \documentclass{article} 4 | \usepackage{microtype} 5 | \usepackage{exscale} 6 | \tracingoutput1 7 | \showboxdepth\maxdimen 8 | \showboxbreadth\maxdimen 9 | \begin{document} 10 | \textls[123]{$abc$} 11 | \end{document} 12 | 13 | grep 'OML/cmm/m/it/10/123ls' 14 | -------------------------------------------------------------------------------- /testsuite/output-fontdimen6.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{microtype} 3 | \DeclareMicrotypeSet*{test}{encoding = U, family = dsrom } 4 | \SetProtrusion[unit=1em]{encoding = U, family = dsrom } 5 | {A = {500,500}} 6 | \begin{document} 7 | \def\test#1{#1\dotfill #1\linebreak} 8 | \tracingoutput1 9 | \showboxbreadth\maxdimen 10 | \showboxdepth\maxdimen 11 | \noindent 12 | \test{A} 13 | \test{{\fontencoding{U}\fontfamily{dsrom}\selectfont A}} 14 | \end{document} 15 | 16 | grep '\kern-5.0 (right margin)' 17 | 18 | -------------------------------------------------------------------------------- /testsuite/output-fontdimen6_lualatex.tex: -------------------------------------------------------------------------------- 1 | \input{output-fontdimen6} 2 | 3 | grep '\kern-5.0 (right margin)' 4 | -------------------------------------------------------------------------------- /testsuite/output-generic_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | %\usepackage{fontspec} 3 | \usepackage[verbose]{microtype} 4 | %\DeclareMicrotypeAlias{lmr} {Latin Modern Roman} 5 | \begin{document} 6 | blbl 7 | \end{document} 8 | 9 | ! grep 'Loading generic settings' 10 | -------------------------------------------------------------------------------- /testsuite/output-ls-math1.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{amsmath} 3 | \usepackage{microtype} 4 | \textwidth=7cm 5 | \DeclareMathOperator{\MyOp}{MyVeryLargeOperator} 6 | 7 | \begin{document} 8 | Before: $\MyOp(1,2,3)$. % this is how it should be. 9 | 10 | {\lsstyle $X^2 + Y^2 = Z^2$} % \lsstyle and math inside a group. 11 | 12 | %\makeatletter\let\glb@currsize\@empty\makeatother 13 | After: $\MyOp(1,2,3)$. % now math has wrong letterspacing. 14 | 15 | \end{document} 16 | 17 | ! grep '^Overfull ' 18 | 19 | -------------------------------------------------------------------------------- /testsuite/output-ls-math2.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[verbose,activate=false]{microtype} 3 | \begin{document} 4 | \textls[200]{ABC} 5 | 6 | \textls[500]{$abc$} 7 | 8 | \end{document} 9 | 10 | grep 'Setting up font `OML/cmm/m/it/10/500ls' 11 | -------------------------------------------------------------------------------- /testsuite/output-lslig.tex: -------------------------------------------------------------------------------- 1 | % issue #12 2 | \documentclass{article} 3 | \usepackage[activate=false]{microtype} 4 | \begin{document} 5 | \makeatletter 6 | \textls{a\lslig{ff}e {\sffamily sans} a\lslig{ff\typeout{\meaning\font@name}}e} 7 | \end{document} 8 | 9 | grep '^macro:->OT1/cmr/m/n/10' 10 | -------------------------------------------------------------------------------- /testsuite/output-nolig_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{fontspec} 3 | \setmainfont{Adobe Garamond Pro} 4 | \usepackage[verbose]{microtype} 5 | \SetTracking[no ligatures={T}]{font=*}{} 6 | \tracingoutput1 7 | \showboxdepth\maxdimen 8 | \showboxbreadth\maxdimen 9 | \begin{document} 10 | \textls{Th ff} 11 | \end{document} 12 | 13 | ! grep '(ligature Th)' 14 | -------------------------------------------------------------------------------- /testsuite/output-nonolig_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{fontspec} 3 | \setmainfont{Adobe Garamond Pro} 4 | \usepackage[verbose]{microtype} 5 | \SetTracking[no ligatures={T}]{font=*}{} 6 | \tracingoutput1 7 | \showboxdepth\maxdimen 8 | \showboxbreadth\maxdimen 9 | \begin{document} 10 | \textls{Th ff} 11 | \end{document} 12 | 13 | grep 'ff' 14 | -------------------------------------------------------------------------------- /testsuite/output-patchspanish.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[spanish]{babel} 3 | \usepackage{microtype} 4 | \begin{document} 5 | <> 6 | 7 | \microtypesetup{nopatch=item} 8 | <> 9 | 10 | \microtypesetup{patch=item} 11 | <> 12 | 13 | \deactivatequoting 14 | \microtypesetup{nopatch=item} 15 | <> 16 | 17 | \microtypesetup{patch=item} 18 | <> 19 | \end{document} 20 | 21 | ! grep "Unable to apply" 22 | -------------------------------------------------------------------------------- /testsuite/output-pinyin.tex: -------------------------------------------------------------------------------- 1 | % 2 | % pinyin 3 | % 4 | % Newsgroups: de.comp.text.tex 5 | % Von: Sven Naumann 6 | % Datum: Sun, 14 Jan 2007 19:43:26 +0100 7 | % Lokal: So 14 Jan. 2007 19:43 8 | % Betreff: microtype + pinyin 9 | % 10 | \tracingoutput1 11 | \showboxbreadth\maxdimen 12 | \showboxdepth\maxdimen 13 | \documentclass{article} 14 | \usepackage{pinyin} 15 | \usepackage{microtype} 16 | \begin{document} 17 | \shang1 18 | 19 | % Zum Vergleich der erste Ton ohne pinyin-Paket: 20 | %sh\={a}ng 21 | \end{document} 22 | 23 | grep '\.\.\.\.\\kern -5\.00002 (for accent)' 24 | 25 | -------------------------------------------------------------------------------- /testsuite/output-polyglossia_lualatex.tex: -------------------------------------------------------------------------------- 1 | % https://tex.stackexchange.com/questions/616329/using-polyglossia-microtype-and-newcomputermodern-with-lualatex-results-in-0-0 2 | \documentclass{article} 3 | \usepackage{polyglossia} 4 | \usepackage{microtype} 5 | \usepackage{newcomputermodern} 6 | 7 | \begin{document} 8 | \section{Test Section} 9 | \end{document} 10 | 11 | ! grep '^Overfull \\hbox' 12 | -------------------------------------------------------------------------------- /testsuite/output-protrusion-changebar.tex: -------------------------------------------------------------------------------- 1 | % github/45 2 | \documentclass{article} 3 | \usepackage{changebar} 4 | \usepackage[verbose]{microtype} 5 | \begin{document} 6 | \cbstart 7 | Hello, bug!\footnote{---\cbstart A footnote\cbend} 8 | \cbend 9 | \end{document} 10 | 11 | ! grep "Unable to apply" 12 | -------------------------------------------------------------------------------- /testsuite/output-protrusion-eqnum-ieeetran.tex: -------------------------------------------------------------------------------- 1 | \documentclass{IEEEtran} 2 | \usepackage{amsmath,mathtools} 3 | \usepackage{microtype} 4 | \usepackage{showkeys} 5 | \begin{document} 6 | \begin{equation}\label{a+b} 7 | a+b 8 | \end{equation} 9 | (1) a+b \hfill (1)\linebreak a+b 10 | \end{document} 11 | 12 | ! grep "Unable to apply" 13 | 14 | -------------------------------------------------------------------------------- /testsuite/output-protrusion-fnbreak.tex: -------------------------------------------------------------------------------- 1 | % github/44 2 | \documentclass{article} 3 | \usepackage{fnbreak} 4 | \usepackage[verbose]{microtype} 5 | \begin{document} 6 | Hello, bug! 7 | \end{document} 8 | 9 | ! grep "Unable to apply" 10 | -------------------------------------------------------------------------------- /testsuite/output-reledmac_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{lipsum} 3 | \usepackage[series={A,B,C,D,E,F,G,H,I,J},noend,nofamiliar,noledgroup,noeledsec]{reledmac}%Declare series to be used 4 | \usepackage{reledpar} 5 | \usepackage[english]{babel} 6 | %\setmainlanguage{english} 7 | \usepackage{libertine} 8 | \usepackage{microtype} 9 | \SetProtrusion[unit=1pt]{encoding=*,family=*}{. = {,2750},{,}={,2750},v={2750,},w={2750,}} 10 | \tracingoutput1 11 | \showboxbreadth1000 12 | \showboxdepth100 13 | % Here is the loop system: 14 | \makeatletter% We need to use command with @ 15 | % Two counters: one for left and one for right 16 | \newcounter{mynotelevel}% 17 | \renewcommand{\themynotelevel}{\Alph{mynotelevel}}% Print the counter as a letter 18 | \newcounter{mynotelevelR}% 19 | \renewcommand{\themynotelevelR}{\Alph{mynotelevelR}}% Print the counter as a letter 20 | \setcounter{mynotelevelR}{5} 21 | 22 | % Following lines are called at each \pstart 23 | \AtEveryPstartCall{% 24 | \ifledRcol%If it's a right pstart 25 | \addtocounter{mynotelevelR}{1}%Step counter 26 | \ifnumequal{\arabic{mynotelevelR}}{11}{%No more than J series (10) 27 | \setcounter{mynotelevelR}{6}% If more than J => restart to F (6) 28 | }{}% 29 | \global\letcs{\mynote}{\themynotelevelR footnote}% And let mynote equal to footnote, where is the current level \letcs is defined by etoolbox which is called by reledmac 30 | \else% If it's a left page 31 | \addtocounter{mynotelevel}{1}%Step counter 32 | \ifnumequal{\arabic{mynotelevel}}{6}{%No more than E series (5) 33 | \setcounter{mynotelevel}{1}%If more than J => restart to A (1) 34 | }{}% 35 | \global\letcs{\mynote}{\themynotelevel footnote}%And let mynote equal to footnote, where is the current level \letcs is defined by etoolbox which called by reledmac 36 | \fi% 37 | } 38 | % This code is called when beginnings of each pstart are printed 39 | \AtEveryPstart{% 40 | \ifodd\c@page%If we are on a left page 41 | \addtocounter{mynotelevelR}{1}%Step counter 42 | \ifnumequal{\arabic{mynotelevelR}}{11}{%No more than J series (10) 43 | \setcounter{mynotelevelR}{6}}{}% If more than J => restart to F (6) 44 | \seriesatend{\themynotelevelR}% The series should be at the end 45 | \else% 46 | \addtocounter{mynotelevel}{1}%Step counter 47 | \ifnumequal{\arabic{mynotelevel}}{6}{%No more than E series (5) 48 | \setcounter{mynotelevel}{1}}{}%% If more than E => restart to A (1) 49 | \seriesatend{\themynotelevel}% The series should be at the end 50 | \fi% 51 | } 52 | 53 | \makeatother 54 | \begin{document} 55 | 56 | \begin{pages} 57 | \begin{Leftside} 58 | \beginnumbering 59 | 60 | \pstart 61 | \edtext{\themynotelevel Here}{\mynote{First footnote in \themynotelevel. Und, so, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter.}} is the 62 | \edtext{\themynotelevel first}{\mynote{Second footnote in \themynotelevel.}} paragraph: 63 | \lipsum[1] 64 | \pend 65 | \endnumbering 66 | \end{Leftside} 67 | 68 | \begin{Rightside} 69 | \beginnumbering 70 | 71 | \pstart 72 | \edtext{\themynotelevelR Here}{\mynote{First footnote in \themynotelevelR. Und, so, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter, weiter.}} is the 73 | \edtext{\themynotelevelR first}{\mynote{Second footnote in \themynotelevelR.}} paragraph: 74 | \lipsum[1] 75 | \pend 76 | \endnumbering 77 | \end{Rightside} 78 | \end{pages} 79 | \setcounter{mynotelevel}{0}%Restart the left counter 80 | \setcounter{mynotelevelR}{5}% And restart the right counter 81 | \Pages 82 | 83 | \end{document} 84 | 85 | grep "\\kern-2\.752 (.* margin)" 86 | -------------------------------------------------------------------------------- /testsuite/output-subst-context.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \pdfmapfile{+MinionPro} 3 | \usepackage[T1]{fontenc} 4 | \usepackage[french]{babel} 5 | \PassOptionsToPackage{verbose,babel, kerning=true}{microtype} 6 | \usepackage[loosequotes]{MinionPro} 7 | 8 | \SetExtraKerning[ name = french-custom, 9 | context = french, 10 | unit = space ] 11 | { encoding = *} 12 | { 13 | ' ={100,200}, 14 | ’ ={100,200} 15 | } 16 | 17 | \pagestyle{headings} 18 | \begin{document} 19 | 20 | l'éléphant \textit{l'éléphant} 21 | 22 | \newpage 23 | l'éléphant \textit{l'éléphant \typeout{\the\rpcode\font`-/\the\knaccode\font`'}} 24 | \end{document} 25 | 26 | grep '250/46' 27 | -------------------------------------------------------------------------------- /testsuite/output-subst.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[T1]{fontenc} 3 | \renewcommand\rmdefault{pilx} 4 | \usepackage[kerning=true,expansion=true,protrusion=true]{microtype} 5 | \SetProtrusion 6 | { encoding = *, family = * } 7 | { - = {,1000}} 8 | \SetExtraKerning[ name = french-custom, 9 | unit = space ] 10 | { family = *, encoding = *, font = {*/*/*/sl/*, */*/*/it/*} } 11 | { 12 | ' ={1500,1500}, 13 | } 14 | \def\text{Additionally, we hook into do@subst, which is called if a substitution has taken place, to record the name of the ersatz font. Unfortunately, this will only work for one-level substitutions. We have to remember the substitute for the rest of the document, not just for the first time it is called, since we need it every time {a font is letterspaced}.} 15 | 16 | \pagestyle{empty} 17 | \begin{document} 18 | 19 | l'elephant \text 20 | 21 | \textit{l'elephant \text} 22 | 23 | \textsl{l'elephant \text} 24 | 25 | \textit{l'elephant \text \typeout{\the\rpcode\font`- /\the\knaccode\font`'}} 26 | 27 | \end{document} 28 | 29 | grep '370/417' 30 | -------------------------------------------------------------------------------- /testsuite/output-tag-footnote.tex: -------------------------------------------------------------------------------- 1 | % github/40 2 | \DocumentMetadata{ 3 | lang = de, 4 | pdfversion = 2.0, 5 | pdfstandard = ua-2, 6 | pdfstandard = a-4f, %or a-4 7 | testphase = 8 | {phase-III, 9 | title, 10 | table, 11 | math, 12 | firstaid} 13 | } 14 | \tracingoutput1 15 | \showboxbreadth1000 16 | \showboxdepth1000 17 | 18 | \documentclass{article} 19 | 20 | \usepackage{microtype} 21 | 22 | \title{test title} 23 | 24 | \begin{document} 25 | 26 | Simple text\footnote{--- proof} 27 | 28 | \end{document} 29 | 30 | ! grep 'Unable to apply patch' 31 | -------------------------------------------------------------------------------- /testsuite/output-tracking-context_lualatex.tex: -------------------------------------------------------------------------------- 1 | % github/47 2 | \documentclass{article} 3 | \usepackage[tracking=true,verbose]{microtype} 4 | \DeclareMicrotypeSet*[tracking]{my} { encoding = *, } 5 | \SetTracking { encoding = *, }{ 100 } 6 | \SetTracking [ context = ttrack, ] { encoding = *, }{ 500 } 7 | \parindent=0pt 8 | \begin{document} 9 | Sophisticated sphinxes. 10 | 11 | \parbox{4cm}{\textmicrotypecontext{tracking=ttrack}{Aaaaaaaaaaaaaaa}} 12 | 13 | \parbox{2.5cm}{\textls[1000]{Aaaaaaaaa}} 14 | \end{document} 15 | 16 | grep '^Overfull ' 17 | -------------------------------------------------------------------------------- /testsuite/output-xecjk_xelatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{xeCJK} 3 | \usepackage[verbose]{microtype} 4 | \setCJKmainfont{SimSun} 5 | \begin{document} 6 | 7 | 上述示例设置了中文字体 8 | SimSun 9 | (宋体)。运行此示例要求系统安装了设置的字体,源文件用 10 | UTF-8 11 | 12 | \end{document} 13 | 14 | ! grep 'Command \\pickup@font' 15 | -------------------------------------------------------------------------------- /testsuite/unknown-charis_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{fontspec} 3 | \setmainfont{Charis SIL} 4 | \usepackage{microtype} 5 | \begin{document} 6 | A \textsc{test}. 7 | \end{document} 8 | -------------------------------------------------------------------------------- /testsuite/unknown-charis_xelatex.tex: -------------------------------------------------------------------------------- 1 | \input{unknown-charis_lualatex} 2 | -------------------------------------------------------------------------------- /testsuite/unknown-csquotes-utf8.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[utf8]{inputenc} 3 | \usepackage[T1]{fontenc} 4 | \usepackage[german,british]{babel} 5 | \usepackage[babel,german=guillemets]{csquotes} 6 | \MakeAutoQuote{›}{‹} 7 | \MakeForeignQuote{german}{»}{«} 8 | \usepackage{microtype} 9 | \SetProtrusion 10 | {font = *} 11 | { » = {0,0}, 12 | « = {0,0}, 13 | › = {0,0}, 14 | ‹ = {0,0}} 15 | \begin{document} 16 | ›a‹ 17 | 18 | »This is a sentence.« 19 | \end{document} 20 | -------------------------------------------------------------------------------- /testsuite/unknown-csquotes.tex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schlcht/microtype/fe0c12ea97dd79f0c311a616d7b8519215db32e5/testsuite/unknown-csquotes.tex -------------------------------------------------------------------------------- /testsuite/unknown-euenc_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[euenc]{fontspec} 3 | \setmainfont{Vollkorn} 4 | \usepackage{microtype} 5 | \begin{document} 6 | Bla 7 | \end{document} 8 | -------------------------------------------------------------------------------- /testsuite/unknown-euenc_xelatex.tex: -------------------------------------------------------------------------------- 1 | \input{unknown-euenc_lualatex} 2 | -------------------------------------------------------------------------------- /testsuite/unknown-frenchpro.tex: -------------------------------------------------------------------------------- 1 | % Bernard Gaulle 2 | % 2005/01/28 3 | \documentclass{article} 4 | %\usepackage[T1]{fontenc} 5 | %\usepackage[frenchb]{babel} 6 | \makeatletter 7 | \input kbconfig.tex 8 | \makeatother 9 | %\expandafter\show\csname OT1\string\i\endcsname 10 | \usepackage[verbose,expansion=false]{microtype} 11 | \begin{document} 12 | test 13 | \end{document} 14 | -------------------------------------------------------------------------------- /testsuite/unknown-german.tex: -------------------------------------------------------------------------------- 1 | % 2 | % german 3 | % 4 | % From: Gerben Wierda 5 | % Subject: Re: microtype.sty and german.sty 6 | % Newsgroups: gmane.comp.tex.macosx 7 | % Date: 2004-11-15 19:13:46 GMT 8 | % 9 | \documentclass[12pt]{article} 10 | \usepackage{german} 11 | \usepackage{microtype} 12 | \begin{document} 13 | a 14 | \end{document} 15 | -------------------------------------------------------------------------------- /testsuite/unknown-luatexja_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{etoolbox} 3 | \usepackage{luatexja-fontspec} 4 | \setmainfont[Ligatures=TeX]{TeX Gyre Pagella} 5 | \usepackage{microtype} 6 | \begin{document} 7 | Lots of warnings. 8 | \end{document} 9 | -------------------------------------------------------------------------------- /testsuite/unknown-mathastext.tex: -------------------------------------------------------------------------------- 1 | % http://tex.stackexchange.com/questions/24248 2 | \documentclass{article} 3 | \usepackage{mathastext} 4 | \usepackage{microtype} 5 | \SetProtrusion 6 | {font = *} 7 | { \# = {,}, 8 | $ = {,}, 9 | \% = {,}, 10 | & = {,}, 11 | } 12 | \begin{document} 13 | Here is some text 14 | \end{document} 15 | -------------------------------------------------------------------------------- /testsuite/unknown-newcomputermodern_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage{microtype-show} 3 | \usepackage{newcomputermodern} 4 | \begin{document} 5 | \ShowProtrusion 6 | \end{document} 7 | -------------------------------------------------------------------------------- /testsuite/unknown-newunicodechar_xelatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | %\usepackage[utf8]{inputenc} 3 | %\usepackage[T1]{fontenc} 4 | \usepackage{fontspec} 5 | \usepackage{microtype} 6 | \usepackage{newunicodechar} 7 | \newunicodechar{å}{\r a} 8 | \newunicodechar{€}{\texteuro} 9 | \newunicodechar{œ}{œ} 10 | 11 | \SetProtrusion{font=*}{å = {0,0},€={10,10},œ = {20,20}} 12 | %\tracingmicrotype4 13 | 14 | \tracingcommands2 15 | \tracingmacros2 16 | \begin{document} 17 | å € œ 18 | \end{document} 19 | -------------------------------------------------------------------------------- /testsuite/unknown-removetlig_lualatex.tex: -------------------------------------------------------------------------------- 1 | % https://github.com/latex3/latex2e/issues/165 2 | \documentclass{article} 3 | \makeatletter 4 | \@ifl@t@r\fmtversion{2015/10/02}\relax 5 | {\expandafter\stop} % unknown slots are to be expected with TL15 and earlier 6 | \makeatother 7 | \usepackage{microtype} 8 | \SetProtrusion{font = *} 9 | {\textquotesingle = {1000,1000}, 10 | \textasciigrave = {1000,1000}, 11 | \textquotedbl = {1000,1000}, 12 | \textasteriskcentered = {1000,1000}} 13 | \begin{document} 14 | \textquotesingle A 15 | \textasciigrave B 16 | \textquotedbl C 17 | \textasteriskcentered D 18 | \end{document} 19 | -------------------------------------------------------------------------------- /testsuite/unknown-removetlig_xelatex.tex: -------------------------------------------------------------------------------- 1 | \input{unknown-removetlig_lualatex.tex} 2 | -------------------------------------------------------------------------------- /testsuite/unknown-shortvrb.tex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schlcht/microtype/fe0c12ea97dd79f0c311a616d7b8519215db32e5/testsuite/unknown-shortvrb.tex -------------------------------------------------------------------------------- /testsuite/unknown-spanish.tex: -------------------------------------------------------------------------------- https://raw.githubusercontent.com/schlcht/microtype/fe0c12ea97dd79f0c311a616d7b8519215db32e5/testsuite/unknown-spanish.tex -------------------------------------------------------------------------------- /testsuite/unknown-tex4ht.tex: -------------------------------------------------------------------------------- 1 | \pdfoutput=0 2 | \documentclass{report} 3 | \usepackage{microtype} 4 | \usepackage[T1]{fontenc} 5 | \usepackage[ngerman]{babel} 6 | \usepackage{textcomp} 7 | \usepackage{tex4ht} 8 | \renewcommand{\rmdefault}{ppl} 9 | \renewcommand{\sfdefault}{ma1} 10 | \renewcommand{\ttdefault}{pcr} 11 | %\renewcommand{\rmdefault}{ptm} 12 | %\renewcommand{\sfdefault}{phv} 13 | 14 | \begin{document} 15 | 16 | \sffamily 17 | 18 | \emph{This is a \textbf{short} text} in (microsoft) \textbf{Monotype Arial}. 19 | 20 | \end{document} 21 | -------------------------------------------------------------------------------- /testsuite/unknown-tuenc_lualatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[tuenc]{fontspec} 3 | \setmainfont{DejaVuSans} 4 | \usepackage{microtype} 5 | \begin{document} 6 | Bla 7 | \end{document} 8 | -------------------------------------------------------------------------------- /testsuite/unknown-tuenc_xelatex.tex: -------------------------------------------------------------------------------- 1 | \input{unknown-tuenc_lualatex} 2 | -------------------------------------------------------------------------------- /testsuite/unknown-utf8.tex: -------------------------------------------------------------------------------- 1 | \documentclass{article} 2 | \usepackage[utf8]{inputenc} 3 | \usepackage[LY1]{fontenc} 4 | \usepackage{times} 5 | \usepackage[german,british]{babel} 6 | \usepackage{microtype} 7 | %\tracingmicrotype3 8 | \SetProtrusion 9 | {font = *} 10 | { » = {0,0}, 11 | « = {0,0}, 12 | › = {0,0}, 13 | ‹ = {0,0}} 14 | \begin{document} 15 | ›ä‹ œ »¡« 16 | 17 | »there we go.« 18 | \end{document} 19 | -------------------------------------------------------------------------------- /testsuite/unknown-xecjk_xelatex.tex: -------------------------------------------------------------------------------- 1 | \documentclass[twoside,10pt,a4paper]{report}%,twocolumn 2 | \usepackage{fontspec} 3 | \setmainfont{Minion Pro} 4 | \usepackage{xeCJK} 5 | \usepackage[verbose]{microtype} 6 | %\DeclareCharacterInheritance 7 | % { font = * } 8 | % { A = {\'A,\`A} } 9 | %\SetProtrusion 10 | % { font = * } 11 | % { A = {,} } 12 | %\usepackage{xunicode} 13 | \begin{document} 14 | \dj 15 | lipsum 16 | \end{document} 17 | 18 | --------------------------------------------------------------------------------