diff options
author | Karl Berry <karl@freefriends.org> | 2022-08-26 20:00:02 +0000 |
---|---|---|
committer | Karl Berry <karl@freefriends.org> | 2022-08-26 20:00:02 +0000 |
commit | 7db05bd7cf0604d9882f6397b874e5fb707acab2 (patch) | |
tree | 814695899d5a13d39d99eb7dea66f088ba04bbe4 /Master/texmf-dist | |
parent | 101fac7a38ade15f231c5dd87b6a09eea096ba1e (diff) |
swungdash (26aug22)
git-svn-id: svn://tug.org/texlive/trunk@64204 c570f23f-e606-0410-a88d-b1316a301751
Diffstat (limited to 'Master/texmf-dist')
-rw-r--r-- | Master/texmf-dist/doc/latex/swungdash/README | 14 | ||||
-rw-r--r-- | Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.pdf | bin | 0 -> 63795 bytes | |||
-rw-r--r-- | Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.tex | 121 | ||||
-rw-r--r-- | Master/texmf-dist/tex/latex/swungdash/swungdash.sty | 34 |
4 files changed, 169 insertions, 0 deletions
diff --git a/Master/texmf-dist/doc/latex/swungdash/README b/Master/texmf-dist/doc/latex/swungdash/README new file mode 100644 index 00000000000..546eb217ed6 --- /dev/null +++ b/Master/texmf-dist/doc/latex/swungdash/README @@ -0,0 +1,14 @@ +swungdash - make a swungdash + +version: 1.0.0 + +swungdash produces a swung dash, a character useful for dictionaries and referencee works. + +This work may be distributed and/or modified under the conditions of the +LaTeX Project Public License (LPPL), version 1.3 or later. + + +For suggestions, feature requests, and bug reports, please use the project's +GitHub site: https://github.com/ezgranet/swungdash + +Version history: 24/08/2022 —package creation diff --git a/Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.pdf b/Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.pdf Binary files differnew file mode 100644 index 00000000000..af40e695000 --- /dev/null +++ b/Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.pdf diff --git a/Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.tex b/Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.tex new file mode 100644 index 00000000000..9b55699d13b --- /dev/null +++ b/Master/texmf-dist/doc/latex/swungdash/swungdash-documentation.tex @@ -0,0 +1,121 @@ +\documentclass[12pt]{article} +\usepackage{swungdash} +\usepackage{xcolor} +\usepackage{fontspec}\definecolor{darkspringgreen}{rgb}{0.09, 0.45, 0.27} +\usepackage{titlesec} +\titleformat{\subsection} + {\bfseries}{\thesection.\thesubsection}{1em}{\normalfont\bfseries} +\usepackage[hidelinks]{hyperref} +\usepackage{hologo} +\usepackage[british]{babel} +\usepackage[useregional]{datetime2} +\DTMlangsetup[en-GB]{ord=omit} +\definecolor{LightGray}{gray}{0.9} +%\usepackage{mathpazo} +\IfFontExistsTF{Palatine Parliamentary}{\setromanfont[RawFeature={+calt,+hlig,+liga,+dlig,+onum,+pnum}, +BoldFont={Palatine Parliamentary Bold}, +ItalicFont={Palatine Parliamentary Italic} +]{Palatine Parliamentary Regular} +}{\setromanfont[RawFeature={+onum,+pnum}]{TeX Gyre PagellaX}} +\setmonofont[Scale=.9,BoldFont=Source Code Pro Bold]{Source Code Pro} + +\usepackage{minted} +\date{\today\\\smallskip\ttfamily Version \swungdashversionnumber} +\author{Elijah Z Granet\thanks{e-mail: \href{mailto:me@ezgra.net}{\ttfamily me@ezgra.net}}} + +\title{\texttt{swungdash}:\\A package for a swung dash} +\begin{document} +\maketitle +\tableofcontents +\clearpage +\section{Overview} +The `swung dash' (\swungdash) is a rare but very useful mark of punctuation used in typesetting dictionaries and reference works as a stand in to avoid repeating the defined term in examples or definitions, and thus to save space. For example, a quoted example of the term `extraterritoriality' might save space by omitting repeating the long word: +\begin{quote} + \swungdash, in this as in every other case, is a fiction only, for diplomatic envoys are in reality not without, but within, the territories of the receiving States. The term `\swungdash' is nevertheless valuable because it demonstrates clearly the fact that envoys must, in most respects, be treated as though they were not within the territory of the receiving States. \footnote{Sir H Lauterpacht \textsc{qc} (ed) \textit{Oppenheim on International Law}, vol 1 (8\textsuperscript{th} edn, Longmans, Green \& C\textsuperscript{o} 1955), 793} +\end{quote} + +Although the swung dash is included in Unicode as \texttt{U+2053}, few typefaces include it. This package turns a tilde in any given typeface into a swung dash of 1 \textsc{m} width, and then, using the \texttt{accsup} package, overwrites this extended tilde into the Unicode character so that it will be read as a swung dash. +\section{Usage} +In your preamble put: +\begin{minted}[ +framesep=2mm, +baselinestretch=1.2, +bgcolor=LightGray, +fontsize=\footnotesize, +breaklines, +firstnumber=last +] +{latex} +\usepackage{swungdash} +\end{minted} + +To typeset a swung dash, simply use the command: +\begin{minted}[ +framesep=2mm, +baselinestretch=1.2, +bgcolor=LightGray, +fontsize=\footnotesize, +breaklines, +firstnumber=last +] +{latex} +\swungdash +\end{minted} +\section{Development} +Bugs, feature requests, \textit{etc}, should be submitted to the project's official Githup page: (\url{github.com/ezgranet/swungdash}). +\section{Licence} + This project is licensed under the Latex Public Project Licence version 1.3\textit{c}. This documentation is copyright of the author but licensed under CC-BY-SA 3.0. +\section{Implementation} +\begin{minted}[ +frame=lines, +framesep=2mm, +baselinestretch=1.2, +bgcolor=LightGray, +fontsize=\footnotesize, +linenos, +breaklines, +firstnumber=last +] +{latex} + +\def\swungdashversionnumber{1.0.0} +\ProvidesPackage{swungdash} + [2022/08/24 v1.0 code to typeset a swung dash] + % !TeX program = lualatex +% !TeX encoding = utf8 +% This work may be distributed and/or modified under the +% conditions of the LaTeX Project Public License, either version 1.3 +% of this license or (at your option) any later version. +% The latest version of this license is in +% http://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX +% version 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% +% The Current Maintainer of this work is Elijah Z Granet + +\RequirePackage{accsupp}\RequirePackage{graphicx} +\RequirePackage{iftex} +\newcommand{\thetilde}{\symbol{"007E}} +\newcommand{\swungdash}{\BeginAccSupp{method=hex,unicode,ActualText= 2053}% +\resizebox{1em}{!}{{\raisebox{-.1ex}{\scalebox{1.75}[1.1]{\thetilde}}}} +\EndAccSupp{}% +} +\newcommand{\twiddle}{$\sim$} +\ifPDFTeX { + \PackageError{swungdash} + {You are using pdfTeX but this package only works + \MessageBreak with XeTeX or LuaTeX}{} + } +\fi + +\end{minted} + +\section{Version History} +\subsection{\texttt{1.0.0}} + +\ttfamily 24 August 2022: Package creation + + +\end{document}
\ No newline at end of file diff --git a/Master/texmf-dist/tex/latex/swungdash/swungdash.sty b/Master/texmf-dist/tex/latex/swungdash/swungdash.sty new file mode 100644 index 00000000000..f580a6c2c43 --- /dev/null +++ b/Master/texmf-dist/tex/latex/swungdash/swungdash.sty @@ -0,0 +1,34 @@ +\def\swungdashversionnumber{1.0.0} +\ProvidesPackage{swungdash} + [2022/08/24 v1.0 code to typeset a swung dash] + % !TeX program = lualatex +% !TeX encoding = utf8 +% This work may be distributed and/or modified under the +% conditions of the LaTeX Project Public License, either version 1.3 +% of this license or (at your option) any later version. +% The latest version of this license is in +% http://www.latex-project.org/lppl.txt +% and version 1.3 or later is part of all distributions of LaTeX +% version 2005/12/01 or later. +% +% This work has the LPPL maintenance status `maintained'. +% +% The Current Maintainer of this work is Elijah Z Granet + +\RequirePackage{accsupp}\RequirePackage{graphicx} +\RequirePackage{iftex} +\newcommand{\thetilde}{\symbol{"007E}} +\newcommand{\swungdash}% +{\BeginAccSupp{method=hex,unicode,ActualText= 2053}% +\resizebox{1em}{!}{{\raisebox{-.1ex}% +{\scalebox{1.75}[1.1]{\thetilde}}}}% +\EndAccSupp{}% +} +\newcommand{\twiddle}{$\sim$} +\ifPDFTeX { + \PackageError{swungdash} + {You are using pdfTeX but this package only works + \MessageBreak with XeTeX or LuaTeX}{} + } +\fi + |