LyX ⇒ Rotated floating Figure Error
-
- Posts: 8
- Joined: Mon Jul 11, 2011 3:27 pm
Rotated floating Figure Error
I'm using Lyx 2.0, and tried to rotate a floating figure by checking the "rotate 90 deg" box in the float settings. But when I wanted to view the output I got the following error:
LaTeX Error: File `rotfloat.sty' not found.
I've had the same error with the *.sty files units.sty, nicefrac.sty and rotating.sty. They were all solved by:
- Downloading the *.sty files manually
- Placing them in the correct MikTex folder (C:\Documents and Settings\User\Application Data\MikTex\tex\latex\contrib\)
- Refreshing the MikTex file name database
- Reconfiguring Lyx and restarting it.
By this approach the problems with the other *.sty files were solved. But when I did the same with rotfloat.sty (placed in C:\Documents and Settings\User\Application Data\MikTex\tex\latex\contrib\rotfloat\rotfloat.sty) I got the following error for all the included graphics in the document:
LaTex Error: Cannot determine size of graphic in 0F_FolderName_GraphicName.pdf (no BoundingBox).
Floating graphic works fine, I can even rotate the graphic itself, but I get this error when I rotate only one of the floats.
Anyone have a solution?
I've attached an example lyx file with an *.eps graphic that gives me this error (but works great when the float is not rotated). I've also included the rotfloat.sty file that I donwloaded.
- Attachments
-
- Example file.zip
- (2.61 KiB) Downloaded 376 times
NEW: TikZ book now 40% off at Amazon.com for a short time.
And: Currently, Packt sells ebooks for $4.99 each if you buy 5 of their over 1000 ebooks. If you choose only a single one, $9.99. How about combining 3 LaTeX books with Python, gnuplot, mathplotlib, Matlab, ChatGPT or other AI books? Epub and PDF. Bundle (3 books, add more for higher discount): https://packt.link/MDH5p
Re: Rotated floating Figure Error
-
- Posts: 8
- Joined: Mon Jul 11, 2011 3:27 pm
Re: Rotated floating Figure Error
I tried converting the file to pdf, but I got the same error. Did you use the attached rotfloat.sty file? I think that's what causing my problem. I'm having trouble with MikTex package manager not being able to connect, so I have to install the .sty packages myself.
- Attachments
-
- Graphic.eps
- (80.82 KiB) Downloaded 440 times
Re: Rotated floating Figure Error
Yes, I noticed rotfloat.sty file, tried with and without it (though it is exactly the same version as the one installed on my machine).
And, finally, try creating a folder directly on C:\, e.g. C:\Test, put files in that folder and try compiling your doc. I wouldn't be surprised if it turns out that a space in the path to your doc is responsible for the issue.
-
- Posts: 8
- Joined: Mon Jul 11, 2011 3:27 pm
Rotated floating Figure Error
Code: Select all
%% LyX 2.0.0 created this file. For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[english]{article}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage{rotfloat}
\usepackage{graphicx}
\usepackage{babel}
\begin{document}
\begin{sidewaysfigure}
\includegraphics{Graphic}
\caption{Text.}
\end{sidewaysfigure}
\end{document}
LaTex errors
C:NewFolder\test.tex | 11 | Overfull \hbox (16.11499pt too wide) in paragraph at lines 11--12.
Running the .lyx file from the same folder gives me the same error as before.
I've included the output pdf from the .tex file as well.
- Attachments
-
- test.pdf
- (4.88 KiB) Downloaded 383 times
Rotated floating Figure Error
Code: Select all
\includegraphics[scale=0.95]{Graphic}
-
- Posts: 8
- Joined: Mon Jul 11, 2011 3:27 pm
Re: Rotated floating Figure Error
It seems the problem was with my 'rotating.sty' file. It was one of the missing .sty files that I installed manually. The one you provided was different than mine, and when replaced rotating floats worked like a charm. I even tried it in Lyx with .jpeg and .bmp with no problems.
Thanks again for your help!
Rotated floating Figure Error
Why aren't you using the MikTeX package manager to install packages? This way you always get the latest versions and can easily update your TeX system (if necessary).Brukernavn wrote:It was one of the missing .sty files that I installed manually.
-
- Posts: 8
- Joined: Mon Jul 11, 2011 3:27 pm
Rotated floating Figure Error
I created a topic in the MikTex subforum to try to sort out the issue:Brukernavn wrote:I'm having trouble with MikTex package manager not being able to connect, so I have to install the .sty packages myself.
http://www.latex-community.org/forum/vi ... =9&t=14111