In order to distinguish files with same name but located in different directories LyX displays the complete path. However, some window managers truncate such paths so that different files cannot be distinguished if they are in the same directory and their path is long.

The attached patch follows the same strategy of gvim, i.e., display the file name first and then the path enclosed in paranthesis.

--
Enrico
diff --git a/src/support/FileName.cpp b/src/support/FileName.cpp
index 7fbd2f4b4c..864f38770c 100644
--- a/src/support/FileName.cpp
+++ b/src/support/FileName.cpp
@@ -748,7 +748,8 @@ docstring const FileName::absoluteFilePath() const
 
 docstring FileName::displayName(int threshold) const
 {
-       return makeDisplayPath(absFileName(), threshold);
+       return from_utf8(onlyFileName()) + " ("
+               +  makeDisplayPath(onlyPath().absFileName(), threshold) + ")";
 }
 
 
-- 
lyx-devel mailing list
lyx-devel@lists.lyx.org
http://lists.lyx.org/mailman/listinfo/lyx-devel

Reply via email to