There are two things here
- You want this only for one page. You can use a
minipage
- You want it for all pages. You can use
background
package.
Only for one page
\documentclass[a4paper]{article}
\usepackage{tikz}
\usetikzlibrary{calc}
\usepackage{kantlipsum}
\usepackage[a4paper,left=1in,right = 1in,top = 1in,bottom=1in]{geometry}
%\pagestyle{empty}
\begin{document}
\noindent
\begin{minipage}[t]{.5\linewidth}
\kant[1-3]
\end{minipage}
\begin{tikzpicture}[remember picture,overlay]
\node[anchor =north east, inner sep=0pt,outer sep=0pt] at (current page.north east) {\includegraphics[width=0.45\paperwidth,height=\paperheight]{example-image-a}};
\end{tikzpicture}
\end{document}
For all pages
This uses background
package and a same image for all pages. You can choose different images if you like but I will leave it to you. For details refer background
documentation (texdoc background
from command line/prompt or visit www.texdoc.net)
\documentclass[a4paper]{article}
\usepackage{background}
\usetikzlibrary{calc}
\backgroundsetup{%
scale=1,
angle=0,
opacity=1, %% adjust
contents={
\begin{tikzpicture}[remember picture,overlay]
\node[anchor =north east, inner sep=0pt,outer sep=0pt] at (current page.north east) {\includegraphics[width=0.45\paperwidth,height=\paperheight]{example-image-a}};
\end{tikzpicture}
}
}
\usepackage{kantlipsum}
\usepackage[a4paper,left=1in,right = 0.5\paperwidth,top = 1in,bottom=1in]{geometry}
%\pagestyle{empty}
\begin{document}
\kant[1-100]
\end{document}
This will take at least 2-3 compilations to stabilize.
You don't need tabbing
; just make a command that typesets the verse number in a zero width box:
\documentclass{article}
\usepackage[margin=1.5cm]{geometry}
\usepackage{lipsum} % just for the example
\usepackage{xeCJK}
\setmainfont{Linux Libertine O}
\setCJKmainfont{Hiragino Mincho Pro}
\newcommand{\versenum}[1]{%
\makebox[0pt][r]{[#1]\enspace}\ignorespaces
}
\begin{document}
\lipsum[2]
\begin{flushleft}
\versenum{11-9}
顏淵死、子曰:「噫天喪予、天喪予。」\\*
When Yanyuan died, the master cried: “How cruel! Heaven is killing me! Heaven is killing me!”
\end{flushleft}
\lipsum[3]
\begin{list}{}{\leftmargin=5em \rightmargin=5em}\raggedright\item\relax
\versenum{11-9}
顏淵死、子曰:「噫天喪予、天喪予。」\\*
When Yanyuan died, the master cried: “How cruel! Heaven is killing me! Heaven is killing me!”
\end{list}
\lipsum[2]
\end{document}
You may want to look at the quoting
package instead of making up a list manually.
You get the same result as with flushleft
also using tabbing
:
\begin{tabbing}
\=\=\kill
\>\versenum{11-9}\>
顏淵死、子曰:「噫天喪予、天喪予。」\\*
When Yanyuan died, the master cried: “How cruel! Heaven is killing me! Heaven is killing me!”
\end{tabbing}
but you need to set the verse number in a zero width box anyway.
A convenient definition for this would be
\newenvironment{vt}
{\begin{tabbing}\=\=\kill}
{\end{tabbing}}
\newcommand{\vtnum}[1]{\>\makebox[0pt][r]{[#1]\enspace}\>}
and the input would be
\begin{vt}
\vtnum{11-9}
顏淵死、子曰:「噫天喪予、天喪予。」\\*
When Yanyuan died, the master cried: “How cruel! Heaven is killing me! Heaven is killing me!”
\end{vt}
Best Answer
Memoir
class has optionshowtrims
and commands\trimFrame
,\settrimmedsize
,\settrims
. Example: