%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%% For support : Yolande Koh, <ykoh@wspc.com.sg>
%% Technical assistance : D. Rajesh Babu, <rajesh@wspc.com.sg>
%% WS Template (updated on 08-09-2016)
%% Trim Size: 9in x 6in
%% Text Area: 7.35in (include runningheads) x 4.5in
%% Main Text: 10/13pt
%%
%% The content, structure, format and layout of this style file is
%% the property of World Scientific Publishing Co. Pte. Ltd.
%% Copyright 2016 by World Scientific Publishing Co.
%% All rights are reserved.
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
%
\NeedsTeXFormat{LaTeX2e}
\ProvidesPackage{ws-crop9x6}[2015/10/05 WSPC Crop 9x6]
% do not adjust these values
\paperwidth=152.4truemm % 6in
\paperheight=228.6truemm % 9in
\oddsidemargin=-.25in % adjust this value to center the text
\evensidemargin=-.25in % adjust this value to center the text
\topmargin=-.32in % adjust this value to center the text
\RequirePackage[a4,center,cam]{crop}
\RequirePackage{ifthen}
%
\newcount\minute
\newcount\hour
\def\currenttime{%
    \minute\time
    \hour\minute
    \divide\hour60
    \the\hour:\multiply\hour60\advance\minute-\hour\the\minute}
\makeatletter
\def\@getcl@ss#1.cls#2\relax{\def\@currentclass{#1}}
\def\@getclass{\expandafter\@getcl@ss\@filelist\relax}
\@getclass
\@ifundefined{projecttitle}{\newtoks\projecttitle\projecttitle{}}{}
\newtoks\classtitle
\classtitle{
 \ifthenelse{\equal{\@currentclass}{ws-book9x6}}{\@currentclass}{\@currentclass-9x6}
}
\def\cropnote{\scriptsize\sf\today\enskip\currenttime\quad\hfill
            \the\classtitle\quad\hfill{\the\projecttitle}\quad\hfill
            \jobname\quad page~\thepage\hfill\ \strut\\[3em]}
\renewcommand*\CROP@@info{{%
    \global\advance\CROP@index\@ne
    \def\x{\discretionary{}{}{\hbox{\kern.5em---\kern.5em}}}%
    \advance\paperwidth-20\p@
    \dimen@4pt
    \ifx\CROP@pagecolor\@empty
    \else
        \advance\dimen@\CROP@overlap
    \fi
    \hb@xt@\z@{%
        \hss
        \vbox to\z@{%
            \centering
            \hsize\paperwidth
            \vss
            \cropnote
            \vskip\dimen@
            }%
        \hss
    }%
}}

\renewcommand*\CROP@@ulc{%
    \begin{picture}(0,0)
        \unitlength\p@\thinlines
        \put(-35,0){\line(1,0){20}}
        \put(0,35){\line(0,-1){20}}
    \end{picture}%
}
\renewcommand*\CROP@@urc{%
    \begin{picture}(0,0)
        \unitlength\p@\thinlines
        \put(35,0){\line(-1,0){20}}
        \put(0,35){\line(0,-1){20}}
    \end{picture}%
}
\renewcommand*\CROP@@llc{%
    \begin{picture}(0,0)
        \unitlength\p@\thinlines
        \put(-35,0){\line(1,0){20}}
        \put(0,-35){\line(0,1){20}}
    \end{picture}%
}
\renewcommand*\CROP@@lrc{%
    \begin{picture}(0,0)
        \unitlength\p@\thinlines
        \put(35,0){\line(-1,0){20}}
        \put(0,-35){\line(0,1){20}}
    \end{picture}%
}
\cropdef\CROP@@ulc\CROP@@urc\CROP@@llc\CROP@@lrc{cam}
\crop[cam]
\makeatother
\endinput