
スライドを作ろうとしています
\documentclass[11pt] {beamer}
\usepackage{caption}
\usepackage{graphicx}
\begin{document}
\section{my photos}
\begin{frame}
\footnotesize\textbf Is this the same as previous figure?
\begin{figure}[h!]
\caption{This is amazing photo}
\centering
\includegraphics[width=0.4\textwidth]{photo1.jpg}
\end{figure}
\end{frame}
\end{document}
このファイルは機能しますが、キャプションの前の図の上に「図」が印刷されます。
答え1
あなたが入手しようとしているのはこのようなものですか?
\documentclass{beamer}
\usepackage[labelformat=empty]{caption}
\begin{document}
\begin{frame}
\frametitle{my photos}
\footnotesize\textbf Is this the same as previous figure?
\begin{figure}[h!]
\caption{This is an amazing photo}
\centering
\includegraphics[width=0.4\textwidth]{TasmanianDevil.jpg}
\end{figure}
\end{frame}
\end{document}
答え2
パッケージを使用する必要はありませんcaption
。キャプションのビーマー テンプレートを次のように変更できます。
\documentclass[11pt]{beamer}
\setbeamertemplate{caption}{%
\raggedright
\insertcaption\par
}
\begin{document}
\section{my photos}
\begin{frame}
\footnotesize\textbf{Is this the same as previous figure?}
\begin{figure}
\caption{This is amazing photo}
%\centering
\includegraphics[width=0.4\textwidth]{example-image-duck}
\end{figure}
\end{frame}
\end{document}
問題とは関係ありません:
graphicx
ビーマー付きのパッケージは必要ありませんビーマーには浮動小数点機構がないので、[h!]のような浮動小数点指定子を追加しても意味がありません。
\centering
図は不要です。ビーマーはデフォルトで図を中央に配置します。(1文字だけ太字にしたい場合を除いて)
\textbf{....}
の代わりに\textbf ....