문서 이미지 또는 사용자 정의 상자의 워터마크

문서 이미지 또는 사용자 정의 상자의 워터마크

다음을 사용하여 워터마크를 추가했습니다.\backgroundsetup

\backgroundsetup{
angle=45,
scale=1,contents={\includegraphics[allpages,
    ]{water_mark.png}}}

\usepackage[most]{tcolorbox}\tcbset{colback=blue!8!white,colframe=blue!25!white, boxrule=0pt, left=10pt,right=10pt,top=10pt,bottom=10pt, arc=0pt,outer arc=0pt}

\begin{tcolorbox}\begin{verbatim} texts in box\end{verbatim} \end{tcolorbox}

이것이 내가 달성한 것입니다:

이것이 내가 달성한 것입니다

모든 페이지에 워터마크가 있어서 기쁘지만 문제는 일부 페이지에 이미지와 사용자 정의 상자가 있다는 것입니다. 이러한 페이지에서는 워터마크가 이미지와 상자 아래에 있습니다. 이미지나 상자 위에 워터마크를 추가하고 싶습니다.

답변1

background패키지를 사용하는 대신 xwatermark.

별표(*) \newwatermark명령 변형은 배경 대신 전경에 워터마크를 배치합니다.

\documentclass{article}
\usepackage[printwatermark]{xwatermark}

\usepackage[most]{tcolorbox}
\tcbset{colback=blue!8!white,colframe=blue!25!white, boxrule=0pt, left=10pt,right=10pt,top=10pt,bottom=10pt, arc=0pt,outer arc=0pt}

\usepackage{mwe}% for test purpose only, you don't need to use this in your document

\begin{document}

\newwatermark*[angle=45,scale=1,xpos=0,ypos=40, allpages]{\includegraphics[height=2cm,width=10cm]{example-image}}% put your image here with the correct height and width

\section{An example of section}

\blindtext

\begin{tcolorbox}
\begin{verbatim} 
texts in box
\end{verbatim} 
\end{tcolorbox}

\blindtext
\newpage
\blindtext
\end{document}

여기에 이미지 설명을 입력하세요

관련 정보