Ask Your Question
1

shortening the path names in the project tree window

asked 2019-05-02 07:33:29 -0500

martinako gravatar image

updated 2019-05-03 04:26:54 -0500

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.

edit retag flag offensive close merge delete

2 Answers

Sort by ยป oldest newest most voted
0

answered 2019-05-03 07:59:33 -0500

updated 2019-05-03 08:01:36 -0500

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.

edit flag offensive delete link more
0

answered 2019-05-02 09:04:35 -0500

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?

edit flag offensive delete link more

Comments

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

martinako gravatar imagemartinako ( 2019-05-02 10:25:04 -0500 )edit

I've just clarified the question

martinako gravatar imagemartinako ( 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 gravatar imageWingware Support ( 2019-05-02 10:45:50 -0500 )edit

I've rephrased the question again and added an image

martinako gravatar imagemartinako ( 2019-05-03 04:27:42 -0500 )edit

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

Question Tools

2 followers

Stats

Asked: 2019-05-02 07:33:29 -0500

Seen: 101 times

Last updated: May 03