Skip to content

Instantly share code, notes, and snippets.

Avatar
💭
🍣🦆

Takayuki YATO zr-tex8r

💭
🍣🦆
View GitHub Profile
@zr-tex8r
zr-tex8r / jsclasses.dtx.diff
Created Feb 7, 2014
LaTeX* Adding to jsclasses support for new base font size settings
View jsclasses.dtx.diff
--- org/jsclasses.dtx Thu Jan 02 19:42:00 2014
+++ jsclasses.dtx Mon Feb 03 01:51:42 2014
@@ -301,6 +301,10 @@
\DeclareOption{43pt}{\renewcommand{\@ptsize}{33}}
\DeclareOption{12Q}{\renewcommand{\@ptsize}{1200}}
\DeclareOption{14Q}{\renewcommand{\@ptsize}{1400}}
+\DeclareOption{10ptj}{\renewcommand{\@ptsize}{1001}}
+\DeclareOption{10.5ptj}{\renewcommand{\@ptsize}{1051}}
+\DeclareOption{11ptj}{\renewcommand{\@ptsize}{1101}}
+\DeclareOption{12ptj}{\renewcommand{\@ptsize}{1201}}
@zr-tex8r
zr-tex8r / hello.tex
Created Mar 22, 2014
An example of a TeX document that is not a LaTeX document. (plain TeX)
View hello.tex
Hello, plain {\TeX} world!\bye
@zr-tex8r
zr-tex8r / sample.tex
Last active Aug 29, 2015
LaTeX source for a sample image
View sample.tex
\documentclass{article}
\usepackage[papersize=60bp,margin=10bp]{geometry}
\begin{document}
\pdfpageattr{/CropBox[5 5 55 55]}
\noindent\TeX!
\end{document}
@zr-tex8r
zr-tex8r / bxxbb.sty
Last active Aug 29, 2015
LaTeX: to create xbb files (for use with dvipdfmx) only using pdfLaTeX
View bxxbb.sty
% bxxbb.sty
%
% package declaration
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{bxxbb}[2014/06/15 v0.1]
% preparationd
\def\bxxb@pkgname{bxxbb}
% environment check
@zr-tex8r
zr-tex8r / image.tex
Last active Aug 29, 2015
LaTeX: What kind of bounding boxes do dvipdfmx use in including PDF image files?
View image.tex
% This is a pdfLaTeX document.
\documentclass{article}
% The papersize is set to 250bp x 250bp, which will
% make the MediaBox equal [0 0 250 250].
\usepackage[papersize=250bp,margin=0pt,noheadfoot]{geometry}
\pagestyle{empty}
% No compression; PDF version still might be 1.5.
\pdfcompresslevel=0
\pdfobjcompresslevel=0
\setlength{\parindent}{0pt}
@zr-tex8r
zr-tex8r / image.tex
Created Jun 30, 2014
LaTeX: mediabb が結局アレな件
View image.tex
% This is a pdfLaTeX document.
\documentclass{article}
\usepackage[papersize=250bp,margin=0pt,noheadfoot]{geometry}
\pagestyle{empty}
\pdfcompresslevel=0
\pdfobjcompresslevel=0
\setlength{\parindent}{0pt}
\begin{document}
\pdfpageattr{%
/CropBox [50 50 150 150]
@zr-tex8r
zr-tex8r / bxdpx-pstricks.sty
Created Jul 12, 2014
LaTeX: to use PSTricks with dvipdfmx
View bxdpx-pstricks.sty
% bxdpx-pstricks.sty
\ifx\documentclass\undefined\long\def\nxt#1#2\nxt{#1}\nxt\fi
%[LaTeX code]
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{bxdpx-pstricks}[2014/07/12 v0.2]
\def\bxqtd@pkgname{bxdpx-pstricks}
% package options
\DeclareOption{dvipdfmx}{\let\bxqtd@t=1}
\ProcessOptions*
\ifx\bxqtd@t\@undefined \expandafter\endinput\fi\relax
@zr-tex8r
zr-tex8r / tcxmediabb.sty
Created Aug 5, 2014
LaTeX: dvipdfmx で mediabb できるかも知れないやつ
View tcxmediabb.sty
% tcxmediabb.sty
%% package declaration
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{tcxmediabb}[2014/08/05 v0.1]
%% preparations
\def\tcqmb@pkgname{tcxmediabb}
\def\tcqmb@error{\PackageError\tcqmb@pkgname}
\def\tcqmb@warn{\PackageWarningNoLine\tcqmb@pkgname}
@zr-tex8r
zr-tex8r / tceasylist.sty
Last active Aug 29, 2015
LaTeX: An extension to easylist, where an arbitrary symbol can be used as list starters
View tceasylist.sty
%
% tceasylist.sty
%
%% package declaratoin
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{tceasylist}[2014/09/15 v0.2]
%% preparations
\def\tcel@pkgname{tceasylist}
\def\tcel@error{\PackageError\tcel@pkgname}
@zr-tex8r
zr-tex8r / tcpdfcrop.bat
Created Oct 16, 2014
バッチで作る、劣化版pdfcrop
View tcpdfcrop.bat
@echo off
setlocal
set FROM=%~n1
set TO=%~n2
set TPX=_tcpc
if not exist %FROM%.pdf exit /B
if "%TO%"=="" exit /B
if exist %TO%.pdf del %TO%.pdf
if exist %TO%.pdf del exit /B
gswin32c -dBATCH -dNOPAUSE -q -sDEVICE=bbox %FROM%.pdf 2>%TPX%1.tex