Making Wing IDE wrap lines on one file - ide

I have one file in my project, (the readme file,) which I would like Wing IDE to display with wrapped lines. Is it possible?

Yes this is possible. Here's how you would do this:
Edit > Preferences > Editor > Line Wrapping
In this window, make sure that the "Wrap Long Lines" box is checked. You can then edit settings in the same window like at what position the line show wrap, etc.

Source -> Justify text will reflow one paragraph of text. Unfortuneatly you have to invoke it one paragraph at a time if you want the whole file reformatted.
I realize you may actually be looking for a viewing transformation that does not modify the file.

It seems like it's currently not possible.

Related

How can I force IntelliJ to wrap a very long line in a *.txt file?

I made a program that saves in a *.txt file the factorial of a number. It is possible to wrap the content of a line to fit in the visible area of the screen?
IntelliJ:
Notepad:
1. Open setting either by selecting File -> Settings or (Ctrl + Alt +
s).
2. Navigate to Editor -> General
3. You should find an option '**Soft-Wrap these files**', add the desired file formats and apply the changes.
This should solve your problem.
No solution is viable (except a text editor with line wrap, but you've stated that's not what you're seeking), as the potential line breaks depend on a specific user's screen resolution, set text size etc.
You could read the screen resolution and make some assumptions with that information, but I would advise against it.

Is there a way to isolate the view of code-regions in IntelliJ?

I have some static HTML and want to generate templates out of it. Looking through the HTML tags I often find myself adding the tags I don't want to have in my templates because I went too far down in the hierarchy. Is there a way to kind of isolate the view of a marked code area? Like greying all unmarked code out somehow?
I'm still not 100% sure what you mean by "mark". I'm assuming you mean "select", that is highlight with the cursor, like this:
If that is the case... here is some info.
There is no way to "highlight" the selected portion and work with it, nor a way "dither out" the non selected portion as you go on to work with the desired portion. You could, however, make use of scratch files to work on the desired text. (Scratch files at IntelliJ IDEA help documentation)
With the portion you want to modify selected, if you create a new scratch file (Ctrl+Alt+Shift+Insert / ⇧⇧N or Tools > New Scratch File), the selected portion will be copied into a scratch file:
You could then work in that scratch file, then copy and paste the final result back into the original file (the changes you make in the scratch file are not "linked" to the original file).
Because you have a portion selected when you launch the scratch file, IDEA creates a scratch file of the same type (HTML in this case) as the selected content. (If done without selected text, a popup is shown asking the type of scratch file you want to create.) If you want JSP syntax awareness, in the HTML scratch file, open the context menu (i.e. right click) and select "Change Language" and select JSP from the menu (inline search is available, so you can just start typing JSP).

How to add line seperators to PhpStorm?

Does anyone know how to add a line separator in PhpStorm?
I know it can be done and I see it a lot but for some reason I can't figure it out how to add one even after researching google for a couple hours.
Check out the image below, there are two line separators, one at the top and one in the middle.
Settings > Editor > Appearance > Show method separators

Can I make IntelliJ IDEAs auto indent ignore previous lines?

Auto-indenting in IntelliJ IDEA seems to automatically takes lines previous to the selection in to consideration. This means that if the indentation is incorrect in the part of the file you're working on (e.g., 3 or 5 spaces where there should be 4, or even worse, a mix of tabs and spaces) it's annoyingly difficult to add correctly indented code.
Both new lines I'm adding and lines I use auto-indent on because I've changed them anyway get messed up like this. Since the file I'm working on is being worked on by someone else as well on another branch, I really don't want to modify over a third of the file just to indent everything correctly, but I would still like the lines that I'm actually modifying/adding to be correct - I don't see any reason to perpetuate the error when it's not necessary.
Currently the best mechanism for fixing it I've found is to manually do the spaces on a line and go from there, but it's really quite annoying, especially since I can't use the tab key or IntelliJ will immediately move to the incorrect indentation. It's barely better than copy/pasting the text to Sublime Text, fix the indentation there and paste it back without formatting.
My apologies if this has already been asked, I've tried to search for it, but it's very hard to search for this as there's so many auto-indent questions.
IntelliJ IDEA recently added a feature (in v14 or 1v4.1 if I recall) where it will detect indentation that is different from your settings. It will honor those indentations (in order to keep the file consistent). Usually as soon as you start editing the file, you get a banner, although that can be turned off. The banner looks like this:
This allows you to modify this setting on a per file basis, or turn it off completely (i.e. the "Show Settings" option).
I suspect this feature is what is causing you the issue. I am not sure how it handles a case where a file has mixed indentation (e.g. most of the file is 4, but some sections are 3 or 5 spaces). You can try turning this feature off in Settings > Editor > Code Style > "Detect and use existing file indents for editing"

Notepad++ stopped color-coding my source code... How to fix?

For no apparent reason, it just stopped. No more color-coding. Is there a mystery setting I accidentally turned off?
I had the same problem and discovered it was because I had enabled global foreground color under Global Styles.
Try out the following:
Select a language manually from the "Languages" menu.
In Settings/Preferences, check the File Associatons.
In worst case, reinstall.
In the Language menu select your corresponding language. For example H and then html
The solution for me was to go into the Style Configurator, select the 'Global Styles' from the Language selection box and uncheck the 'Enable global foreground colour' option. I am not sure why that was checked, but all of the code coloring worked after unchecking it. Thanks Richard!
Have a look in Settings -> Style Configurator. Maybe your styles got messed up somehow. You could try changing the selected style to see if it makes a difference.
I think the saved styles are stored in the "themes" directory under your Notepad++ installation directory, so you could also check that the files have not become corrupted in some way.
I had the same problem (I Googled "notepad++ file coloring quit" to find this discussion.) In my case the coloring quit mid file in a single file. I finally realized that adjacent string literals with one of them a macro was fooling Notepad++.
My code that broke it read:
Write_Supplemental_Configuration(privateData->new_config, FTP_ROOT_DIR"/lists.csv");
and the fix was to add a space after the macro:
Write_Supplemental_Configuration(privateData->new_config, FTP_ROOT_DIR "/lists.csv");
I tried replacing the macro FTP_ROOT_DIR with "foo" and the problem went away.
So in my case it was a macro that fooled the Notepad++ coloring.
watch out for the single quote that you copy from the web. if you get one of those "upper commas" instead of the tic mark it will confuse the code and kill the coloring (in SQL). just delete and replace.
Make sure that when you save the file it's saved as an .html instead of a .txt. This make a difference because the .html allows you to see the different colour codes whereas .txt doesn't.
Check, if you have saved the documents as .HTML and not as .txt
in the menu, choose Settings>Style configurator...
and in the list in the left pan select html, check if the colors for different tags are being shown in the color blocks. if yes, chosse a font and then save and exit.
Check only after you save the document in .html, whether it is working or not.
The language setting solved the issue for (all) 3 Javascript files (.js) which suffered from it, which previously were all recognized correctly as Javascript. For some reason it forgot they were Javascript files apparently!?
First type any thing and Save the file in any format you are working with (i-e; .cpp if c++, .js if JavaScript....etc)
And make sure global foreground color is disabled.
And it should work fine.
File > Save As > Format Type = Structured Query Language > Name the file with '*.sql'. THIS SHOULD BRING ALL THE COLOR CODES.....to differentiate your code and make it look pretty. J
If you want to display text in SQL format, then in menu select Language => S => SQL
Got to Setting -> Style Configuration and remove the global style checkbox
I just had the same thing happen to me. The only way I could fix it was to rename the file (I just added one character). Then open it with notepad++. The code was colored again. Then renamed the file back to the original name and it is still colored.
I have since found that if I close Notepad++ without closing the file first this happens. Try closing the file first then close Notepad++ then reopen the file.
This bug seems to be fixed as of version 7.8.6
If the coloring only stopped working for one file, you should check the extension name of your file. You might have accidentally saved the file as .txt
A couple years late here, but I'm pretty sure you're opening ".txt" files that contain your source code. Because the file doesn't have the language's extension, Notepad++ can't determine how to color-code it. You'll have to select the language under the "Language" tab.