1

I've installed the latest version of pgf and tcolorbox but I still get an error :

I do not know the key 'tcb/shadow'...

The following is the first part of the preamble

\documentclass[xcolor=svgnames,a5paper]{article}
\usepackage[T1]{fontenc}
\usepackage[utf8]{inputenc}

\usepackage[frenchb]{babel}
\usepackage{multicol}
\usepackage{amssymb,amsmath,amsthm,amsfonts}
\usepackage{cases}
\usepackage[svgnames]{xcolor}
\usepackage{tcolorbox}
\tcbuselibrary{skins}
%\usepackage{tikz}
\usepackage{tkz-tab}
\usepackage{tkz-base}
%\usepackage{tkz-arith}
\usepackage{tkz-fct}
\usepackage{tkz-tukey}
\usepackage{pgfplots}
\pgfplotsset{width=10cm,compat=newest}


\usetikzlibrary{arrows,decorations.pathmorphing,shadows}
\usepackage{mdframed, graphicx, xkeyval,ifthen, ifpdf, etoolbox}
\usepackage{tabularx}

\usepackage{pifont}

\usepackage{colortbl}
\usepackage[tikz]{bclogo}

\usepackage{alterqcm}


\usepackage{mdframed, graphicx, xkeyval,ifthen, ifpdf, etoolbox,fp,calc}

\usepackage{fancybox}

\usepackage{framed}
\usepackage[right]{eurosym}
\usepackage{multicol}
\providecommand{\subtitle}[1]{%essai commande de sous-titre
  \usepackage{titling}
  \posttitle{%
    \par\large#1\end{center}}
}

\frenchbsetup{StandardLists=true}
\usepackage{enumitem}
\setlist[itemize,1]{label=$\diamond$}
\setlist[itemize,2]{label=$\bullet$}
\usepackage{fancyhdr}
\pagestyle{fancy}

\usepackage{answers}
\usepackage{lmodern}
\usepackage{textcomp} % provides euro and other symbols


\usepackage{hyperref}
\hypersetup{
            colorlinks=true,
            linkcolor=blue,
            citecolor=Blue,
            urlcolor=Blue,
            breaklinks=true}
\urlstyle{same}  % don't use monospace font for urls

\usepackage[margin=2cm]{geometry}

And here is the code for a \newcommand which uses tcolorbox

\newcommand{\imps}[2]{%
\tcbset{skin=enhanced,colback=red!5!white,
  colframe=red!75!black,fonttitle=\bfseries}

\begin{tcolorbox}[skin=beamer,shadow={2mm}{-1mm}{0mm}{gris0!80!white},width=#1cm]
#2.
\end{tcolorbox}
}

Thanks a lot for your help

TeXwriter 1.6.9 : Android

An error occures using the option "most" or "all" Here is a shorter document to help you.

\documentclass[xcolor=svgnames,a5paper,]{article}
\usepackage[utf8]{inputenc}
\usepackage{pgfplots}
\pgfplotsset{width=10cm,compat=newest}

\usepackage{colortbl}

\usepackage{tcolorbox}
\tcbuselibrary{skins}

\definecolor{gris}{gray}{.80}
\newcommand{\imps}[2]{%
\tcbset{skin=enhanced,colback=red!5!white,
  colframe=red!75!black,fonttitle=\bfseries}

\begin{tcolorbox}[skin=beamer,shadow={2mm}{-1mm}{0mm}{gris!80!white},width=#1cm]
#2.
\end{tcolorbox}
}
\begin{document}
\imps{4}{L'abscisse figure toujours en première position et l'ordonnée en seconde position}
\end{document}
  • 1
    Please post a complete document, not only fragments. The package is called tcolorbox, not tcbcolor. The whole preamble is quite messy. Isolating the tcolorbox call it works (apart from the unknown color 'gris') – user31729 Dec 29 '17 at 20:32
  • have you tried \usepackage[most]{tcolorbox} or (overkill) \usepackage[all]{tcolorbox}, for example? – cmhughes Dec 29 '17 at 21:19
  • @cmhughes: It should work with the skins library already (which is loaded according to the code) – user31729 Dec 29 '17 at 21:21
  • @cmhughes yes but it doesn't work. – imotep81 Dec 30 '17 at 6:59
  • @ChristianHupfer Thanks for your quick answer I have posted a new shorter document. It doesn't work anymore. – imotep81 Dec 30 '17 at 7:02
0

Here's an extract from the CHANGELOG file in the sources for tcolorbox:

version 2.31 (2013/06/18)
- several internal changes
[...]
- new shadow features for the 'skins' library with the options:
  'shadow', 'fuzzy shadow', 'drop shadow', 'drop fuzzy shadow', 'halo', 'fuzzy halo'

Indeed, if I compile your example with TeX Live 2013, I get no error; the error appears when I compile with TeX Live 2012.

Thus it appears that the TeX distribution shipped with your version of TeX Writer is quite old. I don't think you can upgrade just the TeX distribution without a (paid) yearly subscription to TeX Writer; however, in the developer’s site there’s no indication of what is the currently shipped version of TeX Live, so it’s best to ask the developer before paying.

  • You ' re absolutly right. I also have red about the changelog and thought to the same conclusion. I will ask the developper and post the solution if there is one. – imotep81 Dec 30 '17 at 11:09
  • According to the developper TeXwriter 1.6.9 is based on texlive 2013. It's planed to update in the new year, but not very soon. – imotep81 Dec 31 '17 at 11:49
  • In fact the developper himself said that tex writer for android is using an old version of latex, but they are going to use the latest version on the next update. Thank you for your kind help. – imotep81 Jan 1 '18 at 14:45
  • In fact I wanted to get a shade effect inside a box of mines. With tikz I get what I wish : \begin{tikzpicture} \node [copy shadow={fill=blue,shadow xshift=0.5ex,shadow yshift=-0.5ex},rounded corners=3pt, shade,top color=green!40 ,draw=blue,thick,text width=#1cm] {#2}; \end{tikzpicture} in the definition of the newcommand \imps – imotep81 Jan 3 '18 at 21:31

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.