由买买提看人间百态

boards

本页内容为未名空间相应帖子的节选和存档,一周内的贴子最多显示50字,超过一周显示500字 访问原贴
TeX版 - Shaded Box Around Text
相关主题
How to Shade A Piece of Text in Latexhow to number the itemized sentences like [1], [2]...
问一个beamer里面的colorcould not add line numbering in the abstract part?
如何把显示的定理、定义变成正体、粗体格式?moderncv的简历模板中背景色的问题
求救:reference list不按照作者名字排序how to put text around a figure
How to write text into the background?what is the problem?
page number问题怎么把一系列的式子对齐?
lyx下如何让文献引用1-3, not 1,2,3add caption above floating table using floatflt
请问如何写contingent function?a problem of page layout
相关话题的讨论汇总
话题: shaded话题: text话题: around话题: box话题: shadedbox
进入TeX版参与讨论
1 (共1页)
c*******n
发帖数: 32
1
Hi,
I am trying to put a shaded box around some text but I can't seem to do
it... Can someone help me? I tried using the "shadethm" package but
can't figure out how to get un-numbered theorems:
\newshadetheorem*{shadequote}
doesn't work, LaTeX compiler complains that \* is already defined.
I also found this piece of code online but can't figure out how to get
it to work either:
\usepackage{color,calc}
\definecolor{shade}{gray}{0.8}
\newenvironment{myshadedbox}[1][]%
{
%\set
a**e
发帖数: 5794
2
我看不懂你的例子,就自己写了一个。
\documentclass{article}
\usepackage{color,calc}
\definecolor{demo@bgcolor}{gray}{.8}
\let\oldfboxsep\fboxsep
\newsavebox{\mybox}
\newenvironment{shadedbox}{
\noindent
\begin{lrbox}{\mybox}
\begin{minipage}[c]{.945\textwidth}
}{
\end{minipage}
\end{lrbox}%
\setlength{\fboxsep}{8pt}
\colorbox{demo@bgcolor}{\usebox{\mybox}}
\setlength{\fboxsep}{\oldfboxsep}
}
\begin{document}
\begin{shadedbox}
blar
\end{shadedbox}
\end{document}

【在 c*******n 的大作中提到】
: Hi,
: I am trying to put a shaded box around some text but I can't seem to do
: it... Can someone help me? I tried using the "shadethm" package but
: can't figure out how to get un-numbered theorems:
: \newshadetheorem*{shadequote}
: doesn't work, LaTeX compiler complains that \* is already defined.
: I also found this piece of code online but can't figure out how to get
: it to work either:
: \usepackage{color,calc}
: \definecolor{shade}{gray}{0.8}

1 (共1页)
进入TeX版参与讨论
相关主题
a problem of page layoutHow to write text into the background?
怎样从 tex 得到 doc 或者 rtf 文件page number问题
页面onecolumn和two column转换一问lyx下如何让文献引用1-3, not 1,2,3
问个文献引用的问题请问如何写contingent function?
How to Shade A Piece of Text in Latexhow to number the itemized sentences like [1], [2]...
问一个beamer里面的colorcould not add line numbering in the abstract part?
如何把显示的定理、定义变成正体、粗体格式?moderncv的简历模板中背景色的问题
求救:reference list不按照作者名字排序how to put text around a figure
相关话题的讨论汇总
话题: shaded话题: text话题: around话题: box话题: shadedbox