-------- Original Message -------- Subject: Re: Images & Directories Date: Fri, 24 Feb 2012 02:05:07 +0200 From: BOB Merhebi <bobmerh...@gmail.com> To: Jacob Bishop <bishop.ja...@gmail.com>
Hello Jacob, On Wed 22 Feb 2012 02:48:35 AM EET, Jacob Bishop wrote: > Bob, > > On Tue, Feb 21, 2012 at 2:22 PM, BOB Merhebi <bobmerh...@gmail.com > <mailto:bobmerh...@gmail.com>> wrote: > <snip> > > Indeed, that's what I do too. I have a folder -call it A- inside of > which there are 3 folders (one for figures -B-, one for my report > -C- & > another for my beamer -presentation -D-). I use the figure folder for > both the report & the beamer. But if I rename A, the images links are > broken.! > > > Interesting. I just did a simple test on LyX 2.0 with the exact > example you provided, and I do not experience that problem. Renaming > or moving A causes absolutely no issue for me. > I did not mention that I'm using LyX 1.6.7 on a Linux Lucid! > The only thing I can think of is that you might be using absolute > rather than relative paths. I wouldn't initially think this is the > problem, because I know that LyX uses relative paths by default. Honestly, I am not aware of what you're talking about! Never heard of abs/rel paths. > However, it's the only logical explanation I can come up with for the > behavior you're describing (Which I am not able to reproduce). You > should not have to explicitly provide relative paths, but why don't > you try that and see if it resolves the problem? > > If you understand relative paths vs. complete paths, you can skip this > explanation and try that. Otherwise, I will try to explain using the > folder setup you gave. Your report is in -C-, which is in -A-. Your > figures are in -B-, which is also in -A-. When you insert an image and > it puts in the complete path, then it's something like > "C:\Users\YourName\A\B\someFigure.png" and that is a problem. If you > rename A to Alpha, you have the problem that when LyX looks for your > image in "C:\Users\YourName\A\B\someFigure.png" it will find nothing > because "C:\Users\YourName\A\B\someFigure.png" does not exist (because > A does not exist). It should be looking in > "C:\Users\YourName\Alpha\B\someFigure.png" That's the problem. > > The solution is to use relative paths. You can explicitly use a > relative path by specifying it in the textbox that comes up under > input->graphics. If an absolute path is listed there, that is likely > the problem. So, if you're in C, you can change the path in the figure > reference to "..\B\someFigure.png" (which is a relative path) rather > than "C:\Users\YourName\A\B\someFigure.png" (which is a complete > path). This means that LyX simply checks up one directory, then tries > to move down, not caring what drive we're on, or what the master > folder is named, since it never reaches that point in the tree. > I think I catch what you mean. In my version: under the "Graphics" tab, "File". I tried it but still the image breaks! I just checked this:http://lyx.475766.n2.nabble.com/How-to-stop-Figure-location-broken-when-I-open-file-in-different-computer-td480875.html In the third post, it says that the images should be at the same level or below that of the lyx file? I also checked this: http://comments.gmane.org/gmane.editors.lyx.general/66263 & then this: http://wiki.lyx.org/FAQ/RelativeFiguresLocation I tried all but none worked except the last (after relocating my figures folder within the lyx folder). It worked :D I guess having the figures folder on the same level doesn't work with 1.6.7 > If you're using relative paths and still have the problem, then I'm > stumped. Hope this helps. > > Jacob Thank you Jacob :D You saved me loads of to-come waste of time. -- Sincerely Yours, -Merhebi, Bob Thunderbird Signature -- Sincerely Yours, -Merhebi, Bob Thunderbird Signature