Skip to content

Instantly share code, notes, and snippets.

@zr-tex8r
zr-tex8r / reviewbreakall.tex
Last active Mar 15, 2019
LaTeX: \reviewbreakall のようなナニカ
View reviewbreakall.tex
\documentclass{article}
\makeatletter %!!!!!!!!!!!!!!!!!!!!!!!!! TeX code BEGIN
\newif\ifreview@ba@break
\def\review@ba@end{\review@ba@end@}
\DeclareRobustCommand{\reviewbreakall}[1]{%
\begingroup
\review@ba@breakfalse
\review@break@all@a#1\review@ba@end
\endgroup
}
@zr-tex8r
zr-tex8r / test.enc
Created Feb 21, 2019
TeX: IPAex明朝で欧文TFMしてdvipdfmxするとアレ
View test.enc
/test [
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/zero /one /two /three /four /five /six /seven
/eight /nine /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
/.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef /.notdef
@zr-tex8r
zr-tex8r / test-bad.tex
Created Feb 2, 2019
TeX言語:表組み(alignment)中でチョット複雑なコードを動かすとアレ
View test-bad.tex
% This code gives an error.
\documentclass[a4paper]{article}
\makeatletter %!!!!!!!!!!!!!!!!!!!!!!!!! TeX code BEGIN
\newcount\xx@k \newcount\xx@n
% \EvenOddTable{<max-number>}
\newcommand*\EvenOddTable[1]{%
\global\xx@k=\z@ \global\xx@n=#1\relax
\begin{tabular}{cc}%
Even&Odd\\\hline
\@whilenum{\xx@k<\xx@n}\do{%
@zr-tex8r
zr-tex8r / squareroot.saty
Created Jan 7, 2019
SATySFi:サイン・コサインを使って平方根を求める
View squareroot.saty
@require: stdja
@require: list
% sqrt r = sin(acos(1 - 2r)/2) (for 0 < r < 1)
let sqrt-b r =
sin (acos (1. -. r *. 2.) /. 2.)
% NOTE: behavior undefined
let get-invalid-value () = 0. /. 0.
@zr-tex8r
zr-tex8r / fillsnowman.satyh
Created Jan 5, 2019
SATySFi:傾いた☃を出す
View fillsnowman.satyh
% fillsnowman.satyh
%
% Copyright (c) 2019 Takayuki YATO (aka. "ZR")
% GitHub: https:%github.com/zr-tex8r
% Twitter: @zr_tex8r
% Distributed under the MIT License.
@require: pervasives
@require: list
@zr-tex8r
zr-tex8r / nyc2019.tex
Created Jan 3, 2019
LaTeX:2019年の年賀状
View nyc2019.tex
\documentclass{article}
\usepackage[papersize={100mm,148mm},margin=0cm,
noheadfoot]{geometry}
\usepackage{luatexja-fontspec}
\usepackage{amsmath,tikz,graphicx,xcolor,xparse}
\usetikzlibrary{calc}
\newfontface{\fSegoe}{segoeuiz.ttf}
\newfontface{\fUniv}{UniversalisADFStd-BoldCond.otf}
\newfontface{\fNishiki}{Nishiki-teki.ttf}
\newjfontface{\jNishiki}{Nishiki-teki.ttf}
@zr-tex8r
zr-tex8r / texmas.readme.md
Last active Dec 29, 2018
LaTeX: Merry TeXmas 2018
View texmas.readme.md

This is a plain XeTeX documnt, so you must compile it with xetex command.

@zr-tex8r
zr-tex8r / bxrawstr.lua
Last active Dec 22, 2018
LaTeX:「verbatimな文字列」を任意の場所で使う(bxrawstrパッケージ)
View bxrawstr.lua
--
-- This is file 'bxrawstr.lua'.
--
-- Copyright (c) 2018 Takayuki YATO (aka. "ZR")
-- GitHub: https://github.com/zr-tex8r
-- Twitter: @zr_tex8r
--
-- This package is distributed under the MIT License.
--
luatexbase.provides_module{
View affsnowman.satyh
% affsnowman.satyh: Affine-transformed snowman pictures
%
% Copyright (c) 2018 Takayuki YATO (aka. "ZR")
% GitHub: https:%github.com/zr-tex8r
% Twitter: @zr_tex8r
% Distributed under the MIT License.
@require: pervasives
@require: list
@zr-tex8r
zr-tex8r / scarticle.satyh
Last active Dec 23, 2018
SATySFi:非常に画期的な文書クラス
View scarticle.satyh
% scarticle.satyh: An essential docuemnt class for SATySFi
%
% Copyright (c) 2018 Takayuki YATO (aka. "ZR")
% GitHub: https:%github.com/zr-tex8r
% Twitter: @zr_tex8r
% Distributed under the MIT License.
@require: pervasives
@require: list
You can’t perform that action at this time.