From c10a33be6840662ca8be85974ba51638178812db Mon Sep 17 00:00:00 2001 From: Karl Berry Date: Fri, 30 Jul 2021 20:16:24 +0000 Subject: palette (30jul21) git-svn-id: svn://tug.org/texlive/trunk@60119 c570f23f-e606-0410-a88d-b1316a301751 --- Master/texmf-dist/source/latex/palette/palette.dtx | 48 +++++++++++----------- 1 file changed, 25 insertions(+), 23 deletions(-) (limited to 'Master/texmf-dist/source/latex') diff --git a/Master/texmf-dist/source/latex/palette/palette.dtx b/Master/texmf-dist/source/latex/palette/palette.dtx index b66fc4875e1..d4e09f3d8ad 100644 --- a/Master/texmf-dist/source/latex/palette/palette.dtx +++ b/Master/texmf-dist/source/latex/palette/palette.dtx @@ -17,11 +17,11 @@ \iffalse % %<*readme> -# The LaTeX package palette - version 1.0.0 (2021/07/27) +# The LaTeX package palette - version 1.1.0 (2021/07/29) **palette** provides the ability to create custom color palettes and symbol palettes ("symbol suites"), and swap one palette in for another easily. It also allows the user to create a variable that represents the selected palette, and provides checks in case the variable represents a palette that does not exist. -The package is split into `colorpalette` and `symbolsuite`. +The package is split into `colorpalette` and `symbolpalette`. ## Installation instructions @@ -123,14 +123,14 @@ This package consists of the file palette.dtx, % %\NeedsTeXFormat{LaTeX2e} %\ProvidesPackage{colorpalette} -%\ProvidesPackage{symbolsuite} -%[2021/07/27 v1.0.0 Create palettes for colors and symbols] +%\ProvidesPackage{symbolpalette} +%[2021/07/29 v1.1.0 Create palettes for colors and symbols] %\RequirePackage{xcolor} %<*color|symbol> \RequirePackage{macrolist} % %<*driver> -\ProvidesFile{\jobname.dtx}[2021/07/27 v1.0.0 Create palettes for colors and symbols] +\ProvidesFile{\jobname.dtx}[2021/07/29 v1.1.0 Create palettes for colors and symbols] \documentclass{ltxdoc} \EnableCrossrefs @@ -147,6 +147,7 @@ This package consists of the file palette.dtx, % % \GetFileInfo{\jobname.dtx} % +% \changes{v1.1.0}{2021/07/29}{Update macrolist (to get compatibility with etoolbox)} % \changes{v1.0.0}{2021/07/27}{Initial version} % % \title{\textsf{palette} -- Create palettes for colors and symbols} @@ -160,7 +161,7 @@ This package consists of the file palette.dtx, % \end{abstract} % % \section{Overview} -% We will go over the basic structure of the user interface in broad terms first (i.e. no macros or environments yet). We will use \textsf{colorpalette} as our example here, but \textsf{symbolsuite} behaves virtually identically. +% We will go over the basic structure of the user interface in broad terms first (i.e. no macros or environments yet). We will use \textsf{colorpalette} as our example here, but \textsf{symbolpalette} behaves virtually identically. % % First, the user can create palette \emph{themes}, which are independent from each other. Then, you can add colors to themes. Finally, you can make a palette associated with a theme and set its colors. % @@ -174,8 +175,8 @@ This package consists of the file palette.dtx, % \iffalse %<*color> \newcommand\newpalettetheme[1]{ - \newlist{colorpalette@theme@#1@palettes} - \newlist{colorpalette@theme@#1@colors} + \macronewlist{colorpalette@theme@#1@palettes} + \macronewlist{colorpalette@theme@#1@colors} } % % \fi @@ -186,7 +187,7 @@ This package consists of the file palette.dtx, %<*color> \newcommand\addcolortotheme[2]{ \colorpalette@themecheck{#1} - \listadd{colorpalette@theme@#1@colors}{#2} + \macrolistadd{colorpalette@theme@#1@colors}{#2} } % % \fi @@ -201,7 +202,7 @@ This package consists of the file palette.dtx, \newcommand\newpalette[2]{ % Check that the theme exists \colorpalette@themecheck{#1} - \listadd{colorpalette@theme@#1@palettes}{#2} + \macrolistadd{colorpalette@theme@#1@palettes}{#2} } % % \fi @@ -266,9 +267,9 @@ This package consists of the file palette.dtx, % \subsection{Error Messages} % \iffalse %<*color> -\newcommand\colorpalette@themecheck[1]{\listexists{colorpalette@theme@#1@palettes}{}{\colorpalette@error@theme{#1}}} -\newcommand\colorpalette@palettecheck[2]{\listcontains{colorpalette@theme@#1@palettes}{#2}{}{\colorpalette@error@palette{#1}{#2}}} -\newcommand\colorpalette@colorcheck[2]{\listcontains{colorpalette@theme@#1@colors}{#2}{}{\colorpalette@error@color{#1}{#2}}} +\newcommand\colorpalette@themecheck[1]{\macrolistexists{colorpalette@theme@#1@palettes}{}{\colorpalette@error@theme{#1}}} +\newcommand\colorpalette@palettecheck[2]{\macrolistcontains{colorpalette@theme@#1@palettes}{#2}{}{\colorpalette@error@palette{#1}{#2}}} +\newcommand\colorpalette@colorcheck[2]{\macrolistcontains{colorpalette@theme@#1@colors}{#2}{}{\colorpalette@error@color{#1}{#2}}} % % \fi % @@ -307,8 +308,8 @@ This package consists of the file palette.dtx, % \iffalse %<*symbol> \newcommand\newsuitetheme[1]{ - \newlist{symbolsuite@theme@#1@suites} - \newlist{symbolsuite@theme@#1@symbols} + \macronewlist{symbolsuite@theme@#1@suites} + \macronewlist{symbolsuite@theme@#1@symbols} } % % \fi @@ -319,7 +320,7 @@ This package consists of the file palette.dtx, %<*symbol> \newcommand\addsymboltotheme[2]{ \symbolsuite@themecheck{#1} - \listadd{symbolsuite@theme@#1@symbols}{#2} + \macrolistadd{symbolsuite@theme@#1@symbols}{#2} } % % \fi @@ -333,7 +334,7 @@ This package consists of the file palette.dtx, %<*symbol> \newcommand\newsuite[2]{ \symbolsuite@themecheck{#1} - \listadd{symbolsuite@theme@#1@suites}{#2} + \macrolistadd{symbolsuite@theme@#1@suites}{#2} } % % \fi @@ -373,9 +374,9 @@ This package consists of the file palette.dtx, % \subsection{Error Messages} % \iffalse %<*symbol> -\newcommand\symbolsuite@themecheck[1]{\listexists{symbolsuite@theme@#1@suites}{}{\symbolsuite@error@theme{#1}}} -\newcommand\symbolsuite@suitecheck[2]{\listcontains{symbolsuite@theme@#1@suites}{#2}{}{\symbolsuite@error@suite{#1}{#2}}} -\newcommand\symbolsuite@symbolcheck[2]{\listcontains{symbolsuite@theme@#1@symbols}{#2}{}{\symbolsuite@error@symbol{#1}{#2}}} +\newcommand\symbolsuite@themecheck[1]{\macrolistexists{symbolsuite@theme@#1@suites}{}{\symbolsuite@error@theme{#1}}} +\newcommand\symbolsuite@suitecheck[2]{\macrolistcontains{symbolsuite@theme@#1@suites}{#2}{}{\symbolsuite@error@suite{#1}{#2}}} +\newcommand\symbolsuite@symbolcheck[2]{\macrolistcontains{symbolsuite@theme@#1@symbols}{#2}{}{\symbolsuite@error@symbol{#1}{#2}}} % % \fi % @@ -383,21 +384,22 @@ This package consists of the file palette.dtx, % \begin{verbatim}The palette passed in is not a defined palette of theme `#1'\end{verbatim} % where |#1| is the name of the theme. % \iffalse -%\newcommand\symbolsuite@error@theme[1]{\PackageError{symbolsuite}{The theme `#1' passed in is not defined}{}} +%\newcommand\symbolsuite@error@theme[1]{\PackageError{symbolpalette}{The theme `#1' passed in is not defined}{}} % \fi % % If a suite that does not belong to a theme is passed in, the following error will be thrown: % \begin{verbatim}The suite `#2' passed in is not a defined suite of theme `#1'\end{verbatim} % where |#1| is the name of the theme and |#2| is the name of the suite. % \iffalse -%\newcommand\symbolsuite@error@suite[2]{\PackageError{symbolsuite}{The suite `#2' passed in is not a defined suite of theme `#1'}{}} +%\newcommand\symbolsuite@error@suite[2]{\PackageError{symbolpalette}{The suite `#2' passed in is not a defined suite of theme `#1'}{}} % \fi % % If a symbol that does not belong to a theme is passed in, the following error will be thrown: % \begin{verbatim}The symbol `#2' passed in is not a defined symbol of theme `#1'\end{verbatim} % where |#1| is the name of the theme and |#2| is the name of the symbol. +% \changes{v1.0.1}{2020/07/28}{Make error message refer to symbol, not color} % \iffalse -%\newcommand\symbolsuite@error@symbol[2]{\PackageError{symbolsuite}{The symbol `#2' passed in is not a defined color of theme `#1'}{}} +%\newcommand\symbolsuite@error@symbol[2]{\PackageError{symbolpalette}{The symbol `#2' passed in is not a defined symbol of theme `#1'}{}} % \fi % \Finale % -- cgit v1.2.3