First time here? Check out the FAQ!
0

The option for disabling the spaces adding around path separator, i.e., "/".

Hi,

When I input some pathes in wingpro like the following:

/etc/docker/daemon.json

I noticed that it will be converted to the following automatically:

/ etc / docker / daemon.json

But this is really not the result I want to have. So, I want to how I can disable the spaces adding around path separator, i.e., "/", but at the same time keep other spaces to add functions.

Regards, HY

hongyi-zhao's avatar
547
hongyi-zhao
asked 2020-11-21 21:17:37 -0500
Wingware Support's avatar
4.1k
Wingware Support
updated 2020-11-23 07:43:00 -0500
edit flag offensive 0 remove flag close merge delete

Comments

add a comment see more comments

2 Answers

0

The answer for this one seems to be that auto-reformatting was enabled and the line was pasted w/o quotes around teh string so the auto-reformatter added spaces.

Wingware Support's avatar
4.1k
Wingware Support
answered 2021-01-15 08:31:23 -0500
edit flag offensive 0 remove flag delete link

Comments

add a comment see more comments
0

Is this in a Python file or some other file type? It should not be adding spaces around / except outside of strings or comments in Python code. If you do want to disable this, use the Editor > Auto-Editing > Auto-Enter Spaces preference.

Wingware Support's avatar
4.1k
Wingware Support
answered 2020-11-23 07:56:00 -0500
edit flag offensive 0 remove flag delete link

Comments

A python file.

I hope wing behave differently according to the specific situations as described below. For the case where "/" is an operator, for example, in 2/3, the spaces should be added automatically, otherwise, say, for my case, the path separator, don't add them.

hongyi-zhao's avatar hongyi-zhao (2020-11-23 09:39:31 -0500) edit

Are you typing this outside of a comment or string? It shouldn't be adding spaces in a comment or string (if it is, then it's a bug) but otherwise it thinks you are entering an expression and should do auto-spacing.

Wingware Support's avatar Wingware Support (2020-11-23 15:02:31 -0500) edit

Yes. This happened when I paste some URLs into my python script.

hongyi-zhao's avatar hongyi-zhao (2020-11-28 07:48:21 -0500) edit

If it added spaces after paste then it's not the auto-editing feature doing this. That is activated by individual keystrokes. It may be that you have one of the third party code reformatters enabled from the Editor > Auto-formatting preferences page or the Options tab in Project Properties.

Wingware Support's avatar Wingware Support (2020-11-30 07:42:45 -0500) edit

The spaces adding behavior only happened after the <cr> keystroke for the pasted line.

hongyi-zhao's avatar hongyi-zhao (2020-12-01 02:32:20 -0500) edit
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