First time here? Check out the FAQ!
1

shortening the path names in the project tree window

When a directory is added to the project window the whole path shows up. See example image: image description

I have a bunch of directories that I want to add to the project window. They all have very long path names (longer than in the image example above) and the only difference may be the last subfolder or two. Having the project window option "View as Tree" active, I need to make the project window very wide to see which project is which, or use the horizontal scroll. I find the horizontal scrolling annoying.

Is there any way of shortening the path names in the project tree window? maybe just showing the last subfolder name? in the example image that would be just showing "librealsense2" as name of the directory.

martinako's avatar
78
martinako
asked 2019-05-02 07:33:29 -0500, updated 2019-05-03 04:26:54 -0500
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

2 Answers

0

View as Tree when selected in the Project tool's Options menu should just be showing the filename. Does the solve it for you, or is it an issue with the depth of directories adding too much white space for the tree indentations?

Wingware Support's avatar
4.1k
Wingware Support
answered 2019-05-02 09:04:35 -0500
edit flag offensive 0 remove flag delete link

Comments

the problem I described happens with "View as Tree" selected.

martinako's avatar martinako (2019-05-02 10:25:04 -0500) edit

I've just clarified the question

martinako's avatar martinako (2019-05-02 10:28:34 -0500) edit

I'm still not clear on what is happening. Can you please send a screenshot to support@wingware.com? Or I think you can attach one here also. Thanks.

Wingware Support's avatar Wingware Support (2019-05-02 10:45:50 -0500) edit

I've rephrased the question again and added an image

martinako's avatar martinako (2019-05-03 04:27:42 -0500) edit
add a comment see more comments
0

Thanks, that edit clarifies it. This happens if you store the project in a different directory than the ones you are adding, I think past a certain depth of '..'s to go back up (rather than displaying something like ../../../../develop/thirdparty/librealsense2. Is it possible to move the project so it's say in ~/develop? If so, doing Save Project As from the Project menu should solve it.

In general Wing tries to use relative path from project to files as the way to keep track of them so that if both the projects and files are moved but relative path stays the same then it can still find the files from the project. So there's some value of coupling project location to the location of the files in it.

Another thing to note: You don't need to add code you're using but not going to work on to the project, as long as Wing can find it through the Python Path. In general it's better to restrict what's in the project to files you'll actually want to search in the Search in Project scope or include in the Open from Project feature. Wing will still find the files for Find Uses, Goto Definition, Refactor, etc, as long as they are on the Python Path, and in fact it won't treat the project contents as Python Path, so adding them there won't cause Wing to resolve for example an import from librealsense2. I mention this just since it's in directory called 'thirdparty'; it may not be relevant to your use case.

Please let me know if this doesn't solve it for you. As far as I can tell there's no way right now to get the path to display differently in the case where Wing falls back to showing the full path to a directory in the Project tree, due to relative location of projects.

Wingware Support's avatar
4.1k
Wingware Support
answered 2019-05-03 07:59:33 -0500, updated 2019-05-03 08:01:36 -0500
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account. This space is reserved only for answers. If you would like to engage in a discussion, please instead post a comment under the question or an answer that you would like to discuss.

Add Answer