Discussion:
memoir and subfig package
(too old to reply)
Žarko F. Čučej
2005-03-26 02:21:19 UTC
Permalink
Hi,
for subfigures I use (up to now) the subfig package. It is well
integrated with memoir, so I was able to design caption style by memoir
commands and use subfigure syntax for subfigure placement in text, for
example:
\begin{figure}
\subfigure[subfigure caption \label{subfig:1}]{ figure}
\subfigure[subfigure caption \label{subfig:2}]{ figure}
\subfigure[subfigure caption \label{subfig:3}]{ figure}
\subfigure[subfigure caption \label{subfig:4}]{ figure}
\caption{figure caption}
\label{fig:figure}
\end{figure}
Now I read, that subfigure is replaced by subfig. I try to use it with
memoir. My test shows, that it work with memoir, but it not obey memoir'
caption formating anymore. Consequently, the subfig or caption package
captionsetup should be used. This setup also work fine with memoir, but
anyway, I'm curious if there are plans to accommodate the memoir to
subfig package such that it can be used on the same way as now is
possible with subfigure?

Regards, Zarko
Peter Wilson
2005-03-26 04:52:23 UTC
Permalink
Hi,
for subfigures I use (up to now) the subfig package. It is well integrated
with memoir, so I was able to design caption style by memoir commands and
\begin{figure}
\subfigure[subfigure caption \label{subfig:1}]{ figure}
\subfigure[subfigure caption \label{subfig:2}]{ figure}
\subfigure[subfigure caption \label{subfig:3}]{ figure}
\subfigure[subfigure caption \label{subfig:4}]{ figure}
\caption{figure caption}
\label{fig:figure}
\end{figure}
Now I read, that subfigure is replaced by subfig. I try to use it with
memoir. My test shows, that it work with memoir, but it not obey memoir'
caption formating anymore. Consequently, the subfig or caption package
captionsetup should be used. This setup also work fine with memoir, but
anyway, I'm curious if there are plans to accommodate the memoir to subfig
package such that it can be used on the same way as now is possible with
subfigure?
Memoir provides subfloats by itself (based, by permission of Steven
Douglas Cochran, on some of the subfigure code) without the subfig(ure)
package. It is not my intention to try and make memoir cooperate with all
packages that an author might want to use --- that is more properly the
province of package authors. A package can check which class is being used
while a class can only check on packages at \begin{document}.

Peter W.
Žarko F. Čučej
2005-03-29 22:56:15 UTC
Permalink
Post by Peter Wilson
Hi,
for subfigures I use (up to now) the subfig package. It is well integrated
with memoir, so I was able to design caption style by memoir commands and
[...]
Post by Peter Wilson
anyway, I'm curious if there are plans to accommodate the memoir to subfig
package such that it can be used on the same way as now is possible with
subfigure?
Memoir provides subfloats by itself (based, by permission of Steven
Douglas Cochran, on some of the subfigure code) without the subfig(ure)
package. It is not my intention to try and make memoir cooperate with all
packages that an author might want to use --- that is more properly the
province of package authors. A package can check which class is being used
while a class can only check on packages at \begin{document}.
Peter W.
Thank you very much for above explanation. I was just curious. You have
right about packages.

And thank you for memoir. It's great!

Regards, Zarko
Axel Sommerfeldt
2005-03-26 13:22:39 UTC
Permalink
Post by Žarko F. Čučej
Now I read, that subfigure is replaced by subfig.
Yes, but if the subfigure package works fine for you there is no reason to
migrate to subfig.
Post by Žarko F. Čučej
My test shows, that it work with memoir, but it not obey memoir'
caption formating anymore.
Try loading the caption package with the option "caption=false" first,
which leaves the original \caption code intact:

\documentclass{memoir}
\usepackage[caption=false]{caption}
\usepackage[...]{subfig}
...

HTH,
Axel
Žarko F. Čučej
2005-03-29 23:08:28 UTC
Permalink
Post by Axel Sommerfeldt
Post by Žarko F. Čučej
Now I read, that subfigure is replaced by subfig.
Yes, but if the subfigure package works fine for you there is no reason to
migrate to subfig.
I observe that subfig better handle with referencing of subfigures, and
in package is emphasized, that it is replacement for subfigure...
Post by Axel Sommerfeldt
Post by Žarko F. Čučej
My test shows, that it work with memoir, but it not obey memoir'
caption formating anymore.
Try loading the caption package with the option "caption=false" first,
\documentclass{memoir}
\usepackage[caption=false]{caption}
\usepackage[...]{subfig}
Great! This solve some small problems. Not only that I can furdher use
the old code for caption formating, the memoir code gives sligthly
different (better) results -- I observe that in case if you select for
label separator "newline", subfig with caption always insert a new line
(regardles if the text is in it or not), meanwhile memor insert it only
if there is caption text ...
Post by Axel Sommerfeldt
...
HTH,
Axel
Regards, Zarko
Axel Sommerfeldt
2005-03-30 11:07:54 UTC
Permalink
Post by Žarko F. Čučej
I observe that in case if you select for
label separator "newline", subfig with caption always insert a new
line (regardles if the text is in it or not)
This should not be, it sounds like a bug for me. Do you have a small (and
complete) example file for me which shows this behaviour?

Axel
Žarko F. Čučej
2005-03-31 00:13:43 UTC
Permalink
Post by Axel Sommerfeldt
Post by Žarko F. Čučej
I observe that in case if you select for
label separator "newline", subfig with caption always insert a new
line (regardles if the text is in it or not)
This should not be, it sounds like a bug for me. Do you have a small (and
complete) example file for me which shows this behaviour?
Axel
I will give my best to do this, but it is not so simple. I should
recollect already erased piece of a quite complex code ... but just now
I receive language correction of the my text book, which I like to
finish asap ... I hope that over this weekend I will be able reproduce
minimal example with mentioned behavior.

Regards, Zarko
Axel Sommerfeldt
2005-03-31 11:36:28 UTC
Permalink
Hi Zarko,
Post by Axel Sommerfeldt
Post by Žarko F. Čučej
I observe that in case if you select for
label separator "newline", subfig with caption always insert a new
line (regardles if the text is in it or not)
This should not be, it sounds like a bug for me. Do you have a small
(and complete) example file for me which shows this behaviour?
[...] I hope that over this weekend I will be able reproduce
minimal example with mentioned behavior.
That would be very kind, thank you. So far I can't reproduce the problem,
for example

\documentclass{memoir}
\usepackage[labelformat=simple,labelsep=colon]{subfig}
\newcommand\FIG{\fbox{\parbox{.4\textwidth}{\strut}}}
\begin{document}
\begin{figure}[ht] \centering
\subfloat[with caption]{\FIG}
\subfloat[]{\FIG}
\caption{}
\end{figure}
\end{document}

shows that captions without text are fine, especially without caption
separator.

Regards,
Axel

Loading...