Georg Baum wrote:
> The attached archive contains a lyx file and two eps files:
> test_a.eps and test/a.eps. Unfortunately the mangled name of both
> files is the same: _home_me_test_a.eps. Therefore the dvi output is
> wrong, you get two times test/a.eps instead of a_test.eps and a.eps.
> This bug is also in current 1.3cvs.
> IMHO it is not a good idea to increase the chance that such a name
> clash happens by putting every included file into the same temp
> directory.
> 
> The question now is: How to solve that name clash? It seems that the
> current filename mangling needs to be replaced by something else.
> One possibility:
> 
> _  <->  _0
> /  <->  _1
> .  <->  _2
> 
> or something similar.

Looks like a very good idea. But I'd suggest using something human 
readable as the mangling. Eg, this:

dir1/main.lyx
dir2/sub.lyx
dir3/sub.lyx

becomes:
main.lyx
dot_dot_slash_dir2_slash_sub.lyx
dot_dot_slash_dir3_slash_sub.lyx

Ie, we do not mangle '.' in the file name. Further, I don't see any 
need to mangle '_' itself. 

My understanding is that you intend to place all included files in the 
directory of the master lyx file. Will it cope with this:

main.lyx
foo1/doc/sub.lyx # contains \includegraphics{../image.eps}
foo1/fig/image.eps
foo2/doc/sub.lyx # contains \includegraphics{../image.eps}
foo2/doc/image.eps

Presumably the temp dir should contain

main.lyx
foo1_doc_sub.lyx
foo1_fig_image.eps
foo2_doc_sub.lyx
foo2_fig_image.eps

(modulo any changes to the name mangling.)

-- 
Angus

Reply via email to