texlive[46722] Master: thaispec (23feb18)

commits+karl at tug.org commits+karl at tug.org
Fri Feb 23 23:07:15 CET 2018


Revision: 46722
          http://tug.org/svn/texlive?view=revision&revision=46722
Author:   karl
Date:     2018-02-23 23:07:15 +0100 (Fri, 23 Feb 2018)
Log Message:
-----------
thaispec (23feb18)

Modified Paths:
--------------
    trunk/Master/tlpkg/bin/tlpkg-ctan-check
    trunk/Master/tlpkg/tlpsrc/collection-langother.tlpsrc

Added Paths:
-----------
    trunk/Master/texmf-dist/doc/latex/thaispec/
    trunk/Master/texmf-dist/doc/latex/thaispec/README.md
    trunk/Master/texmf-dist/doc/latex/thaispec/thaispec.pdf
    trunk/Master/texmf-dist/source/latex/thaispec/
    trunk/Master/texmf-dist/source/latex/thaispec/thaispec.dtx
    trunk/Master/texmf-dist/source/latex/thaispec/thaispec.ins
    trunk/Master/texmf-dist/tex/latex/thaispec/
    trunk/Master/texmf-dist/tex/latex/thaispec/thaispec.sty
    trunk/Master/tlpkg/tlpsrc/thaispec.tlpsrc

Added: trunk/Master/texmf-dist/doc/latex/thaispec/README.md
===================================================================
--- trunk/Master/texmf-dist/doc/latex/thaispec/README.md	                        (rev 0)
+++ trunk/Master/texmf-dist/doc/latex/thaispec/README.md	2018-02-23 22:07:15 UTC (rev 46722)
@@ -0,0 +1,49 @@
+# thaispec
+Thai Language Typesetting in XeLaTeX
+
+# Version
+0.1 [2018-FEB-23]
+
+# Author
+Ratthaprom Promkam
+
+## Prerequisite
+Thai national fonts, i.e., SIPAFonts (See https://github.com/epsilonxe/sipafonts)
+
+## Recommendation
+Install TeX Gyre font family (Possibly included with your TeX distribution)
+
+## Usage
+If you already have TeX Gyre font family, just simply add the preamble
+```
+\usepackage{thaispec}
+```
+Otherwise
+```
+\usepackage[texgyrefont=false]{thaispec}
+```
+This package allows you to input Thai characters directly to ```.tex``` file,
+and choose any Thai fonts to be used in the document.
+In order to choose the font, please make sure that the font is system wide, then use
+```
+\usepackage[thaifont = <SYSTEM THAI FONT NAME>]{thaispec}
+```
+Moreover, the package give you options to choose any system wide fonts for
+```mainfont```,```sansfont```, ```monofont``` too
+
+
+## Credit
+This package is motivated by a set of LaTex commands for typesetting Thai documents
+provided by Dittaya Wanvarie from Chulalongkorn University.
+(See http://pioneer.netserv.chula.ac.th/~wdittaya/)
+
+## License
+Copyright 2018 Ratthaprom Promkam
+
+This work may be distributed and/or modified under the
+conditions of the LaTeX Project Public License, either version 1.3
+of this license of (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.


Property changes on: trunk/Master/texmf-dist/doc/latex/thaispec/README.md
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/doc/latex/thaispec/thaispec.pdf
===================================================================
(Binary files differ)

Index: trunk/Master/texmf-dist/doc/latex/thaispec/thaispec.pdf
===================================================================
--- trunk/Master/texmf-dist/doc/latex/thaispec/thaispec.pdf	2018-02-23 22:06:11 UTC (rev 46721)
+++ trunk/Master/texmf-dist/doc/latex/thaispec/thaispec.pdf	2018-02-23 22:07:15 UTC (rev 46722)

Property changes on: trunk/Master/texmf-dist/doc/latex/thaispec/thaispec.pdf
___________________________________________________________________
Added: svn:mime-type
## -0,0 +1 ##
+application/pdf
\ No newline at end of property
Added: trunk/Master/texmf-dist/source/latex/thaispec/thaispec.dtx
===================================================================
--- trunk/Master/texmf-dist/source/latex/thaispec/thaispec.dtx	                        (rev 0)
+++ trunk/Master/texmf-dist/source/latex/thaispec/thaispec.dtx	2018-02-23 22:07:15 UTC (rev 46722)
@@ -0,0 +1,396 @@
+%\iffalse
+% thaispec.dtx generated using makedtx version 0.94b (c) Nicola Talbot
+% Command line args:
+%   -doc "thaispec.tex"
+%   -src "thaispec\.sty=>thaispec.sty"
+%   -author "Ratthaprom Promkam"
+%   thaispec
+% Created on 2018/2/23 22:01
+%\fi
+%\iffalse
+%<*package>
+%% \CharacterTable
+%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
+%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
+%%   Digits        \0\1\2\3\4\5\6\7\8\9
+%%   Exclamation   \!     Double quote  \"     Hash (number) \#
+%%   Dollar        \$     Percent       \%     Ampersand     \&
+%%   Acute accent  \'     Left paren    \(     Right paren   \)
+%%   Asterisk      \*     Plus          \+     Comma         \,
+%%   Minus         \-     Point         \.     Solidus       \/
+%%   Colon         \:     Semicolon     \;     Less than     \<
+%%   Equals        \=     Greater than  \>     Question mark \?
+%%   Commercial at \@     Left bracket  \[     Backslash     \\
+%%   Right bracket \]     Circumflex    \^     Underscore    \_
+%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
+%%   Right brace   \}     Tilde         \~}
+%</package>
+%\fi
+% \iffalse
+% Doc-Source file to use with LaTeX2e
+% Copyright (C) 2018 Ratthaprom Promkam, all rights reserved.
+% \fi
+% \iffalse
+%<*driver>
+%!TEX engine = xelatex
+%!TEX root = thaispec.tex
+%!TEX enableSynctex = yes
+%!TEX outputDirectory = OutputDir
+%!TEX spellcheck = en_US
+%!TEX encoding = UTF-8
+
+\documentclass[a4paper,10pt]{article}
+\usepackage{thaispec}
+\usepackage{mathtools,amssymb,amsthm}
+
+\title{บทความภาษาไทย}
+\author{ชื่อผู้แต่ง}
+
+\begin{document}
+\DocInput{thaispec.dtx}
+\end{document}
+%</driver>
+%\fi
+%\maketitle
+%คอนดักเตอร์ซีริลลิกคลอไรด์ ลินุกซ์ออกเทนดอปเพลอร์ไพธอนฮิรางานะ ไอพ็อดแอพพลิเคชัน
+%อินทิเกรตออกเทนแพลตฟอร์มดิจิตอล ไลเซนส์เวิร์กสเตชันไฮโดรลิกพาเนล พาร์ทิชันแท็กโมบายล์กูเกิลแล็ปท็อป
+%พาราโบลาโพรเซสเซอร์ พร็อกซีอินพุทแท็บ เซ็กเมนต์มัลแวร์ออกเทน เดลไฟไมถิลีทัชแพดชิป
+%ซีริลลิกโปรโตคอลเคอราตินแกนีมีด เทอร์โมฮาร์ดดิสก์ เทฟลอน กิกะไบต์สแต็กชิคุนกุนยา
+%เมลเอ็กซ์โพเนนเชียลไดออกไซด์ฟีโรโมนไบต์
+%
+%เวกเตอร์ดีวีดีอินทิเกรตฮาร์ดแวร์ ธาลัสซีเมียกราฟิกแล็ปท็อปสปายแวร์ลิงก์โน้ตบุ๊ค
+%บลูเรย์เทฟลอนลินุกซ์โปรเซสเซอร์ ทรานแซ็กชันเวิร์คสเตชั่นไมถิลี อัปเดตดีบั๊กไอคอนแอนิเมชัน
+%พิกเซลอีเมลโพรโทคอลพร็อกซีสแกนเนอร์ กูเกิ้ลลินุกซ์แอพพลิเคชั่นมอดูล
+%ไฟล์เดลไฟริงโทนอาร์กิวเมนต์คลิปอาร์ต อูบุนตูโน้ตบุ๊คอัปโหลดแอสเซมเบลอร์
+%ไดเรกทอรีซัพพอร์ทไอโฟน มัลติทัชสล็อตอีเมล์พาเนลเน็ตเวิร์คยูนิโคดเรียลไทม์
+%
+%\begin{equation}
+%	\int_a^b\;f(x)\;\mathrm{d}x = F(b) - F(a) \quad\text{ถ้า}\quad \dfrac{\mathrm{d}}{\mathrm{d}x}F(x) = f(x).
+%\end{equation}
+%\section{หัวข้อแรก}
+%ไลบรารีไอโฟนซีดีรอมเราเตอร์บิทเอนจิน ยูนิโคดบัฟเฟอร์เวิร์กสเตชั่น
+%โมบายล์เบราว์เซอร์์แอนะล็อกแพลตฟอร์ม
+%เอาต์พุตมัลติทัชแฮ็กเกอร์ไอโฟน เดลไฟแพกเก็ตเวิร์คสเตชั่นเวิร์คสเตชัน
+%บลูทูธอินเทอร์เฟซ เวิร์คสเตชัน เบราว์เซอร์บลูเรย์เอาท์พุตเน็ตเวิร์คมัลติ
+%ทวีตโค้ดซอฟท์แวร์ดอสโน้ตบุ๊กอีเมล์ บลูทูธพารามิเตอร์โมบายล์เอาต์พุต ชิปฟีเจอร์ทรานแซ็คชัน
+%\begin{equation}
+%	\dfrac{\mathrm{d}}{\mathrm{d}x}\sin(2x) = 2\cos(2x).
+%\end{equation}
+%
+%\begin{definition}
+%เซ็กเมนต์ฟอสซิลครอสโนวาไดนามิคพาราเซตามอล ไฮเพอร์โบลาคูลอมบ์
+%ควอนตัมปฏิยานุพันธ์ไดนามิคโซนาร์เวกเตอร์ไดนามิกส์
+%ไดนามิกส์ควอนตัม ไททันไฮดรอลิกเทอร์โมยูเรียซิลิเกต ไฮเพอร์โบลาวีก้าไพรเมตเนกาตีฟ
+%เมทริกซ์เซ็กเมนต์ โมเมนตัมแอสพาร์แตมเมตริกซ์
+%\end{definition}
+%
+%\begin{theorem}
+%ไทฟอยด์ดอปเพลอร์เพอร์ออกไซด์ ฟิชชันฮิวมัสไดออกไซด์เอทานอล
+%ไดนามิคโอเซลทามิเวียร์เทฟลอนวีก้า อีโบลาแคโรทีนเมตริกซ์ออกเทน พันธุศาสตร์ยูริกอัลตราซาวนด์เคอราติน
+%อีโบล่าควอนตัม ดอปเปลอร์โพลาไรซ์มอนอกไซด์เวก้าอินทิกรัล ทามิฟลูทามิฟลูจุลชีววิทยาโครมาโทกราฟีฟอสซิล
+%ซัลไฟด์ฟิชชันกลีเซอรีนเอทิลีนแคสสินี ไดนามิกฟอสซิลทามิฟลูแอสพาร์แตม
+%\end{theorem}
+%
+%\section{หัวข้อที่สอง}
+%เกตเวย์เอาต์พุทโหลด ไฟร์วอลล์สแปมเอาท์พุตอีเมลเวอร์ชวล
+%ไลบรารีพร็อกซีแอปพลิเคชันโปรเซสพร็อกซี ดิจิทัลแอนิเมชั่นไอพ็อด ไดโอดซอร์สเดลไฟเน็ตบุ๊ค
+%โฮสต์กราฟิกเอาท์พุตคอมไพเลอร์ อินพุทดาวน์โหลด แอสเซมเบลอร์อินเทอร์เน็ตเดเบียนเคอร์เซอร์อัพโหลด
+%เฟิร์มแวร์โพรโทคอลไลบรารีเอนจินโน้ตบุค โค้ดเชลล์ริงโทน แอพพลิเคชั่นมอนิเตอร์อีเมลสปายแวร์ไฟล์
+%เทเลคอมเน็ตเวิร์กโฮสต์โหลด
+%\begin{table}[!ht]
+%\begin{center}
+%\begin{tabular}{|c|c|}
+%\hline
+%\textbf{ไลบรารีพร็อกซี} & \textbf{โค้ดเชลล์ริงโทน}\\ \hline
+%ดิจิตอลมินิมอล & $\tan(2x)-16x^2$ \\ \hline
+%อลูมิเนียมไลบรารี & $\cos(x^2)$ \\ \hline
+%\end{tabular}
+%\caption{ไลบรารีเอนจินโน้ตบุค}
+%\end{center}
+%\end{table}
+%ไฮดรอกไซด์พาร์ทิชัน เบงกาลี แล็ปท็อปกุมภาพันธ์พร็อกซีแคสสินี ตุลาคมทรานแซ็กชั่น
+%แพลตฟอร์มไดโอดอัปเดตพารามิเตอร์โพลาไรซ์ ไฟเบอร์เจ๊บอแรกซ์ดิจิทัล คลิกเยลลี่สงบสุขโมดูล
+%พาเนลเมตริกซ์ คอนโดมิเนียมคลัสเตอร์ เวิร์คสเตชั่น แท็บไอซีแฮปปี้ยีสต์ซัลฟิวริก โน้ตบุ๊กสงบสุขแอสพาร์แตม
+%ดิสเครดิตเตี๊ยมคลอไรด์สวาฮิลีสแกนเนอร์ ออโรร่าไบต์ฮันกึลสปีชีส์อัลตราซาวด์ อารบิกกิกะไบต์
+%แพตเทิร์นบาร์บีคิวมีเดียริงโทน
+%
+%กลีเซอรีนโน้ตบุค ชิพฟีโรโมนละตินอินเทอร์เฟซ เกตเวย์คอเลสเตอรอลแพตช์วีเจ ฮิวมัสโบกี้โนวาเวิร์ลด์
+%แจ๊กพอตป๋าไอโฟนทามิฟลูคอมพ์ ไดเรกทอรีเจ็ตทัชแพดคลาสโฮสต์ บอแรกซ์ไชน่าแบนด์วิดท์พอร์ทจุลชีววิทยา
+%ซัลฟิวริกเทคโนแครตโมเมนตัมโฮสต์ สต๊อคยีสต์โอริยา ภูมิทัศน์ดอสแคมเปญ เวกเตอร์คอเลสเตอรอลบึ้มสเปก
+%เปียโนฟิวชันไอพ็อดมิถุนายนชิคุนกุนยา นายพรานอินพุตพอร์ทปูอัด
+%
+%ดิจิทัลสมิติเวชบอแรกซ์แพกเก็ต คลอไรด์ทัวริสต์ไชน่าโน้ตบุค คลาสสปายแวร์ไททันอะซีติกคอมพิวติ้ง
+%ไฟเบอร์จิ๊กเคลมตากาล็อก เวสิเคิลโมไบล์อ่วม อูบันตูบึ้มไอโฟนโอริยาชิป พะเรอดิจิทัลอัพเกรด
+%คลิกโซนาร์เลเยอร์มาร์เก็ต วอล์กเมลานินฮิรางานะธาลัสซีเมียภคันทลาพาธ กรีนฟอนต์
+%เกย์ไฮดรอกไซด์ครูเสดบาร์บีคิวคีย์ คอร์สเปกฟีโรโมนล็อบบี้ปูอัด เพทนาการดิจิทัลกรีน
+%ไอคอนบลูทูธไททันซาดิสม์ไฮดรอกไซด์ อัลกอริทึมไอซีโอริยามอนอกไซด์แอสพาร์แตม
+%
+%
+%\StopEventually{}
+%\section{The Code}
+%\iffalse
+%    \begin{macrocode}
+%<*thaispec.sty>
+%    \end{macrocode}
+%\fi
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{thaispec}[2018/02/23 thaispec version 0.1]
+
+\RequirePackage{kvoptions}
+\RequirePackage[no-math]{fontspec}
+\RequirePackage[Latin, Thai]{ucharclasses}
+\RequirePackage{setspace}
+\RequirePackage{polyglossia}
+\RequirePackage[calc]{datetime2}
+\RequirePackage{xstring}
+\RequirePackage{fp-basic, fp-snap}
+\RequirePackage{afterpackage}
+\RequirePackage{xpatch}
+
+% Key-Value Options
+\SetupKeyvalOptions{
+family=THL,
+prefix=THL@
+}
+\DeclareStringOption[TH Sarabun New]{thaifont}[TH Sarabun New]
+\DeclareStringOption[TeX Gyre Termes]{mainfont}[TeX Gyre Termes]
+\DeclareStringOption[TeX Gyre Heros]{sansfont}[TeX Gyre Heros]
+\DeclareStringOption[TeX Gyre Cursor]{monofont}[TeX Gyre Cursor]
+
+\DeclareVoidOption{thainum}{\renewcommand{\thesection}{\thainum{section}}}
+\DeclareBoolOption[true]{texgyrefont}
+
+\DeclareStringOption[default]{thmcount}[default]
+
+\ProcessKeyvalOptions{THL}
+
+
+% TeX Commands
+
+\newcommand{\testvar}{\THL at thmcount}
+
+% Set Thai language
+\XeTeXlinebreaklocale "th"
+\XeTeXlinebreakskip = 0pt plus 0pt
+\sloppy
+\defaultfontfeatures{Mapping=tex-text}
+
+
+% Select Thai fonts
+\ifTHL at texgyrefont
+\setmainfont{\THL at mainfont}
+\setsansfont{\THL at sansfont}
+\setmonofont{\THL at monofont}
+\else
+\setmainfont[Scale=1.23]{\THL at thaifont}
+\fi
+
+
+% Control English/Thai Fonts
+\newfontfamily{\thaifont}[Scale=MatchUppercase,Mapping=tex-text]{\THL at thaifont}
+
+\newenvironment{thailang}
+{\thaifont}
+{}
+
+\setTransitionTo{Thai}{\begin{thailang}}
+\setTransitionFrom{Thai}{\end{thailang}}
+
+\setdefaultlanguage{english}
+\setotherlanguage{thai}
+\AtBeginDocument\captionsthai
+
+% In case of Beamer class
+\@ifclassloaded{beamer}
+{
+% TODO: Serif math font in beamer
+}
+{
+%% Normally set onehalf spacing
+\onehalfspacing
+}
+
+
+% Define Thai alpha/number/digit for enumerated items
+\def\thaialph#1{\expandafter\thalph\csname c@#1\endcsname}
+\def\thalph#1{%
+    \ifcase#1\or ก\or ข\or ค\or ง\or จ\or ฉ\or ช\or ซ\or
+    ฌ\or ญ\or ฎ\or ฏ\or ฐ\or ฑ\or ฒ\or ณ\or ด\or ต\or ถ\or ท\or ธ\or น\or
+    บ\or ป\or ผ\or ฝ\or พ\or ฟ\or ภ\or ม\or ย\or ร\or ฤ\or ล\or ฦ\or ว\or
+    ศ\or ษ\or ส\or ห\or ฬ\or อ\else ฮ\else\xpg at ill@value{#1}{thalph}\fi}
+\def\thainum#1{\expandafter\thainumber\csname c@#1\endcsname}
+\def\thainumber#1{%
+    \thaidigits{\number#1}%
+}
+\def\thaidigits#1{\expandafter\thdigits #1@ }
+\def\thdigits#1{%
+    \ifx @#1% then terminate
+    \else
+    \ifx0#1๐\else\ifx1#1๑\else\ifx2#1๒\else\ifx3#1๓\else\ifx4#1๔\else\ifx5#1๕\else\ifx6#1๖\else\ifx7#1๗\else\ifx8#1๘\else\ifx9#1๙\else#1\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi
+    \expandafter\thdigits
+    \fi
+}
+
+% Define Thai datetime
+% \today - Print today in short format d-M-Y(BD)
+% \Today - Print today in long format dow-d-M-Y(BD)
+\DTMsavenow{now}
+\newcommand{\dtdow}{\IfStrEqCase{\DTMfetchdow{now}}{{0}{วันจันทร์}
+{1}{วันอังคาร}
+{2}{วันพุธ}
+{3}{วันพฤหัสบดี}
+{4}{วันศุกร์}
+{5}{วันเสาร์}
+{6}{วันอาทิตย์}
+}}
+
+\newcommand{\dtmonth}{\IfStrEqCase{\DTMfetchmonth{now}}{{1}{มกราคม}
+{2}{กุมภาพันธ์}
+{3}{มีนาคม}
+{4}{เมษายน}
+{5}{พฤษภาคม}
+{6}{มิถุนายน}
+{7}{กรกฎาคม}
+{8}{สิงหาคม}
+{9}{กันยายน}
+{10}{ตุลาคม}
+{11}{พฤศจิกายน}
+{12}{ธันวาคม}
+}}
+
+\newcommand{\dtyearbd}{\FPadd{\tmpdtyearbd}{\DTMfetchyear{now}}{543}\FPclip{\rtmpdtyearbd}{\tmpdtyearbd}พ.ศ.\;\rtmpdtyearbd}
+\AtBeginDocument{
+\def\Today{\dtdow\;\DTMfetchday{now}\;\dtmonth\;\dtyearbd}
+\def\today{\DTMfetchday{now}\;\dtmonth\;\dtyearbd}
+}
+
+
+% Thai theorem environments
+
+\AfterPackage{amsthm}{%
+\IfStrEqCase{\THL at thmcount}{%
+{default}{%
+\newtheorem{theorem}{ทฤษฎีบท}
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{no}{%
+\newtheorem*{theorem}{ทฤษฎีบท}
+\newtheorem*{lemma}{บทตั้ง}
+\newtheorem*{corollary}{บทแทรก}
+\newtheorem*{proposition}{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem*{definition}{บทนิยาม}
+\newtheorem*{undefinedterm}{อนิยาม}
+\newtheorem*{axiom}{สัจพจน์}
+\newtheorem*{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{full}{%
+\newtheorem{theorem}{ทฤษฎีบท}
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}
+\newtheorem{note}{บันทึก}
+}%
+{section}{%
+\newtheorem{theorem}{ทฤษฎีบท}[section]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{chapter}{%
+\newtheorem{theorem}{ทฤษฎีบท}[chapter]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{kind}{%
+\newtheorem{theorem}{ทฤษฎีบท}
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}{บทนิยาม}
+\newtheorem{undefinedterm}[definition]{อนิยาม}
+\newtheorem{axiom}[definition]{สัจพจน์}
+\newtheorem{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}
+\newtheorem{note}{บันทึก}
+}%
+{kind-section}{%
+\newtheorem{theorem}{ทฤษฎีบท}[section]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}{บทนิยาม}[section]
+\newtheorem{undefinedterm}[definition]{อนิยาม}
+\newtheorem{axiom}[definition]{สัจพจน์}
+\newtheorem{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}[section]
+\newtheorem{note}{บันทึก}[section]
+}%
+{kind-chapter}{%
+\newtheorem{theorem}{ทฤษฎีบท}[chapter]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}{บทนิยาม}[chapter]
+\newtheorem{undefinedterm}[definition]{อนิยาม}
+\newtheorem{axiom}[definition]{สัจพจน์}
+\newtheorem{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}[chapter]
+\newtheorem{note}{บันทึก}[chapter]
+}%
+}%
+\xpatchcmd{\@thm}{\thm at headpunct{.}}{\thm at headpunct{}}{}{}
+}
+
+
+\endinput
+%\iffalse
+%    \begin{macrocode}
+%</thaispec.sty>
+%    \end{macrocode}
+%\fi
+%\Finale
+\endinput


Property changes on: trunk/Master/texmf-dist/source/latex/thaispec/thaispec.dtx
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Added: trunk/Master/texmf-dist/source/latex/thaispec/thaispec.ins
===================================================================
--- trunk/Master/texmf-dist/source/latex/thaispec/thaispec.ins	                        (rev 0)
+++ trunk/Master/texmf-dist/source/latex/thaispec/thaispec.ins	2018-02-23 22:07:15 UTC (rev 46722)
@@ -0,0 +1,31 @@
+% thaispec.ins generated using makedtx version 0.94b 2018/2/23 22:01
+\input docstrip
+
+\preamble
+
+ thaispec.dtx
+ Copyright 2018 Ratthaprom Promkam
+
+ This work may be distributed and/or modified under the
+ conditions of the LaTeX Project Public License, either version 1.3
+ of this license of (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 Ratthaprom Promkam.
+
+ This work consists of the files thaispec.dtx and thaispec.ins and the derived file thaispec.sty.
+
+\endpreamble
+
+\askforoverwritefalse
+
+\generate{\file{thaispec.sty}{\usepreamble\defaultpreamble
+\usepostamble\defaultpostamble\from{thaispec.dtx}{thaispec.sty,package}}
+}
+
+\endbatchfile

Added: trunk/Master/texmf-dist/tex/latex/thaispec/thaispec.sty
===================================================================
--- trunk/Master/texmf-dist/tex/latex/thaispec/thaispec.sty	                        (rev 0)
+++ trunk/Master/texmf-dist/tex/latex/thaispec/thaispec.sty	2018-02-23 22:07:15 UTC (rev 46722)
@@ -0,0 +1,278 @@
+%%
+%% This is file `thaispec.sty',
+%% generated with the docstrip utility.
+%%
+%% The original source files were:
+%%
+%% thaispec.dtx  (with options: `thaispec.sty,package')
+%% 
+%%  thaispec.dtx
+%%  Copyright 2018 Ratthaprom Promkam
+%% 
+%%  This work may be distributed and/or modified under the
+%%  conditions of the LaTeX Project Public License, either version 1.3
+%%  of this license of (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 Ratthaprom Promkam.
+%% 
+%%  This work consists of the files thaispec.dtx and thaispec.ins and the derived file thaispec.sty.
+%% 
+%% \CharacterTable
+%%  {Upper-case    \A\B\C\D\E\F\G\H\I\J\K\L\M\N\O\P\Q\R\S\T\U\V\W\X\Y\Z
+%%   Lower-case    \a\b\c\d\e\f\g\h\i\j\k\l\m\n\o\p\q\r\s\t\u\v\w\x\y\z
+%%   Digits        \0\1\2\3\4\5\6\7\8\9
+%%   Exclamation   \!     Double quote  \"     Hash (number) \#
+%%   Dollar        \$     Percent       \%     Ampersand     \&
+%%   Acute accent  \'     Left paren    \(     Right paren   \)
+%%   Asterisk      \*     Plus          \+     Comma         \,
+%%   Minus         \-     Point         \.     Solidus       \/
+%%   Colon         \:     Semicolon     \;     Less than     \<
+%%   Equals        \=     Greater than  \>     Question mark \?
+%%   Commercial at \@     Left bracket  \[     Backslash     \\
+%%   Right bracket \]     Circumflex    \^     Underscore    \_
+%%   Grave accent  \`     Left brace    \{     Vertical bar  \|
+%%   Right brace   \}     Tilde         \~}
+\NeedsTeXFormat{LaTeX2e}
+\ProvidesPackage{thaispec}[2018/02/23 thaispec version 0.1]
+
+\RequirePackage{kvoptions}
+\RequirePackage[no-math]{fontspec}
+\RequirePackage[Latin, Thai]{ucharclasses}
+\RequirePackage{setspace}
+\RequirePackage{polyglossia}
+\RequirePackage[calc]{datetime2}
+\RequirePackage{xstring}
+\RequirePackage{fp-basic, fp-snap}
+\RequirePackage{afterpackage}
+\RequirePackage{xpatch}
+
+\SetupKeyvalOptions{
+family=THL,
+prefix=THL@
+}
+\DeclareStringOption[TH Sarabun New]{thaifont}[TH Sarabun New]
+\DeclareStringOption[TeX Gyre Termes]{mainfont}[TeX Gyre Termes]
+\DeclareStringOption[TeX Gyre Heros]{sansfont}[TeX Gyre Heros]
+\DeclareStringOption[TeX Gyre Cursor]{monofont}[TeX Gyre Cursor]
+
+\DeclareVoidOption{thainum}{\renewcommand{\thesection}{\thainum{section}}}
+\DeclareBoolOption[true]{texgyrefont}
+
+\DeclareStringOption[default]{thmcount}[default]
+
+\ProcessKeyvalOptions{THL}
+
+
+\newcommand{\testvar}{\THL at thmcount}
+
+\XeTeXlinebreaklocale "th"
+\XeTeXlinebreakskip = 0pt plus 0pt
+\sloppy
+\defaultfontfeatures{Mapping=tex-text}
+
+\ifTHL at texgyrefont
+\setmainfont{\THL at mainfont}
+\setsansfont{\THL at sansfont}
+\setmonofont{\THL at monofont}
+\else
+\setmainfont[Scale=1.23]{\THL at thaifont}
+\fi
+
+\newfontfamily{\thaifont}[Scale=MatchUppercase,Mapping=tex-text]{\THL at thaifont}
+
+\newenvironment{thailang}
+{\thaifont}
+{}
+
+\setTransitionTo{Thai}{\begin{thailang}}
+\setTransitionFrom{Thai}{\end{thailang}}
+
+\setdefaultlanguage{english}
+\setotherlanguage{thai}
+\AtBeginDocument\captionsthai
+
+\@ifclassloaded{beamer}
+{
+}
+{
+%% Normally set onehalf spacing
+\onehalfspacing
+}
+
+\def\thaialph#1{\expandafter\thalph\csname c@#1\endcsname}
+\def\thalph#1{%
+    \ifcase#1\or ก\or ข\or ค\or ง\or จ\or ฉ\or ช\or ซ\or
+    ฌ\or ญ\or ฎ\or ฏ\or ฐ\or ฑ\or ฒ\or ณ\or ด\or ต\or ถ\or ท\or ธ\or น\or
+    บ\or ป\or ผ\or ฝ\or พ\or ฟ\or ภ\or ม\or ย\or ร\or ฤ\or ล\or ฦ\or ว\or
+    ศ\or ษ\or ส\or ห\or ฬ\or อ\else ฮ\else\xpg at ill@value{#1}{thalph}\fi}
+\def\thainum#1{\expandafter\thainumber\csname c@#1\endcsname}
+\def\thainumber#1{%
+    \thaidigits{\number#1}%
+}
+\def\thaidigits#1{\expandafter\thdigits #1@ }
+\def\thdigits#1{%
+    \ifx @#1% then terminate
+    \else
+    \ifx0#1๐\else\ifx1#1๑\else\ifx2#1๒\else\ifx3#1๓\else\ifx4#1๔\else\ifx5#1๕\else\ifx6#1๖\else\ifx7#1๗\else\ifx8#1๘\else\ifx9#1๙\else#1\fi\fi\fi\fi\fi\fi\fi\fi\fi\fi
+    \expandafter\thdigits
+    \fi
+}
+
+\DTMsavenow{now}
+\newcommand{\dtdow}{\IfStrEqCase{\DTMfetchdow{now}}{{0}{วันจันทร์}
+{1}{วันอังคาร}
+{2}{วันพุธ}
+{3}{วันพฤหัสบดี}
+{4}{วันศุกร์}
+{5}{วันเสาร์}
+{6}{วันอาทิตย์}
+}}
+
+\newcommand{\dtmonth}{\IfStrEqCase{\DTMfetchmonth{now}}{{1}{มกราคม}
+{2}{กุมภาพันธ์}
+{3}{มีนาคม}
+{4}{เมษายน}
+{5}{พฤษภาคม}
+{6}{มิถุนายน}
+{7}{กรกฎาคม}
+{8}{สิงหาคม}
+{9}{กันยายน}
+{10}{ตุลาคม}
+{11}{พฤศจิกายน}
+{12}{ธันวาคม}
+}}
+
+\newcommand{\dtyearbd}{\FPadd{\tmpdtyearbd}{\DTMfetchyear{now}}{543}\FPclip{\rtmpdtyearbd}{\tmpdtyearbd}พ.ศ.\;\rtmpdtyearbd}
+\AtBeginDocument{
+\def\Today{\dtdow\;\DTMfetchday{now}\;\dtmonth\;\dtyearbd}
+\def\today{\DTMfetchday{now}\;\dtmonth\;\dtyearbd}
+}
+
+
+\AfterPackage{amsthm}{%
+\IfStrEqCase{\THL at thmcount}{%
+{default}{%
+\newtheorem{theorem}{ทฤษฎีบท}
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{no}{%
+\newtheorem*{theorem}{ทฤษฎีบท}
+\newtheorem*{lemma}{บทตั้ง}
+\newtheorem*{corollary}{บทแทรก}
+\newtheorem*{proposition}{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem*{definition}{บทนิยาม}
+\newtheorem*{undefinedterm}{อนิยาม}
+\newtheorem*{axiom}{สัจพจน์}
+\newtheorem*{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{full}{%
+\newtheorem{theorem}{ทฤษฎีบท}
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}
+\newtheorem{note}{บันทึก}
+}%
+{section}{%
+\newtheorem{theorem}{ทฤษฎีบท}[section]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{chapter}{%
+\newtheorem{theorem}{ทฤษฎีบท}[chapter]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}[theorem]{บทนิยาม}
+\newtheorem{undefinedterm}[theorem]{อนิยาม}
+\newtheorem{axiom}[theorem]{สัจพจน์}
+\newtheorem{example}[theorem]{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem*{remark}{หมายเหตุ}
+\newtheorem*{note}{บันทึก}
+}%
+{kind}{%
+\newtheorem{theorem}{ทฤษฎีบท}
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}{บทนิยาม}
+\newtheorem{undefinedterm}[definition]{อนิยาม}
+\newtheorem{axiom}[definition]{สัจพจน์}
+\newtheorem{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}
+\newtheorem{note}{บันทึก}
+}%
+{kind-section}{%
+\newtheorem{theorem}{ทฤษฎีบท}[section]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}{บทนิยาม}[section]
+\newtheorem{undefinedterm}[definition]{อนิยาม}
+\newtheorem{axiom}[definition]{สัจพจน์}
+\newtheorem{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}[section]
+\newtheorem{note}{บันทึก}[section]
+}%
+{kind-chapter}{%
+\newtheorem{theorem}{ทฤษฎีบท}[chapter]
+\newtheorem{lemma}[theorem]{บทตั้ง}
+\newtheorem{corollary}[theorem]{บทแทรก}
+\newtheorem{proposition}[theorem]{ทฤษฎีบทประกอบ}
+\theoremstyle{definition}
+\newtheorem{definition}{บทนิยาม}[chapter]
+\newtheorem{undefinedterm}[definition]{อนิยาม}
+\newtheorem{axiom}[definition]{สัจพจน์}
+\newtheorem{example}{ตัวอย่าง}
+\theoremstyle{remark}
+\newtheorem{remark}{หมายเหตุ}[chapter]
+\newtheorem{note}{บันทึก}[chapter]
+}%
+}%
+\xpatchcmd{\@thm}{\thm at headpunct{.}}{\thm at headpunct{}}{}{}
+}
+
+\endinput
+%%
+%% End of file `thaispec.sty'.


Property changes on: trunk/Master/texmf-dist/tex/latex/thaispec/thaispec.sty
___________________________________________________________________
Added: svn:eol-style
## -0,0 +1 ##
+native
\ No newline at end of property
Modified: trunk/Master/tlpkg/bin/tlpkg-ctan-check
===================================================================
--- trunk/Master/tlpkg/bin/tlpkg-ctan-check	2018-02-23 22:06:11 UTC (rev 46721)
+++ trunk/Master/tlpkg/bin/tlpkg-ctan-check	2018-02-23 22:07:15 UTC (rev 46722)
@@ -612,7 +612,7 @@
     texliveonfly texloganalyser texlogos texmate texments
     texosquery texpower texproposal texshade textualicomma texvc
     textcase textfit textglos textgreek textmerg textopo textpath textpos
-    tfrupee thaienum thalie theatre theoremref
+    tfrupee thaienum thaispec thalie theatre theoremref
     thesis-ekf thesis-gwu thesis-titlepage-fhac
     thinsp thmbox thmtools threadcol threeddice threeparttable threeparttablex
     thumb thumbpdf thumbs thumby thuthesis

Modified: trunk/Master/tlpkg/tlpsrc/collection-langother.tlpsrc
===================================================================
--- trunk/Master/tlpkg/tlpsrc/collection-langother.tlpsrc	2018-02-23 22:06:11 UTC (rev 46721)
+++ trunk/Master/tlpkg/tlpsrc/collection-langother.tlpsrc	2018-02-23 22:07:15 UTC (rev 46722)
@@ -51,6 +51,7 @@
 depend sanskrit
 depend sanskrit-t1
 depend thaienum
+depend thaispec
 depend velthuis
 depend vntex
 depend wnri

Added: trunk/Master/tlpkg/tlpsrc/thaispec.tlpsrc
===================================================================


More information about the tex-live-commits mailing list