How to I stop this Netbeans IDE highlighting? - html

I am currently using Netbeans IDE 7.4 to write some basic HTML code. Whenever I type a tag, it immediately highlights it, making it next to impossible to read until I click somewhere else. This is incredibly annoying. I have looked at all previous solutions, but for some reason they only work with Java and not HTML. Does anybody know how to fix this?

After ongoing bouts of frustration with the NetBeans highlighting, I finally figured out this was not so much of an issue of highlighting being turned on or off, but more an issue of how the highlighting is being rendered.
Turning highlighting off completely (as suggested above) has never been fully successful in my case in either NetBeans 8.x or 9.0 (I'm currently using 9.0), and the highlighting can seriously become so annoying in that it's too difficult to read the highlighted text, that it becomes a distraction and negatively impacts productivity.
Having determined that this is a question of rendering verses IDE functionality, the original answer is on target as far as modifying the Mark Occurrences styling in:
Tools > Options > Fonts & Colors > Syntax -> Mark Occurrences.
However, since I work in multiple projects of multiple types, I selected 'All Languages' in the drop-down, set the foreground and background colors to 'Inherited' (getting rid of the sickly yellow background (I'm using the Sublime Theme) and added Bold and Italic styling to the inherited font setting.
Now, no matter the project or the language, highlighting is still working as intended, but it's no longer an annoyance.
Hope this helps for others who have been likewise frustrated by this feature of NetBeans! It was getting to the point of almost driving me to another IDE.

The mark-occurrences color can be modified in Options->Fonts & Colors
-> Syntax, language: Java, Category: Mark Occurrences. To turn it off completely go to Options->Java code -> Mark Occurrences and
disable the first checkbox.
http://netbeans-org.1045718.n5.nabble.com/Turn-off-or-change-the-automatic-highlight-of-the-mark-occurrence-feature-td2949743.html

Try to change profile. That works for me.
Tools > Options > Fonts & Colors > profile.
Hope it will help.

In Netbeans 12.5, this is configurable in Tools|Options|Editor tab|Highlighting tab under Editor tab

Related

vs code , snippets, templates, quick entry of classes and attributes

I apologize in advance for the question with syntactic and semantic errors, English is not my native language.
I recently started learning web development, I'm currently learning bootstrap 5 and I've come across some incomprehensible moments:
what are the sane snippets or templates for writing elementary constructions, for example, if I want to make an elementary container construction
<div class="container">
</div>
when I try to enter cont or .cont and then press "ctrl + space" then this is not offered automatically
emmet is set, and when you type .cont a block with the class "cont" is created, which is naturally not what I need
Let's also assume that the i have file bootstrap.css file is connected to the project, and there are a lot of default classes in it, it happens that when I'm already in the tag, I want to register a class, and I start to enter a class, VScode behaves differently, sometimes it will show the options in the drop-down the menu, but sometimes it doesn’t show anything, what these glitches are connected with, can someone tell me how to get rid of different behavior? The IntelliSense for CSS class names in HTML extension is installed, but it doubles up in the dropdown list that VScode gives by default, and it's not clear how to disable the default behavior of VScode.
being in the tag or in the tag (link) you need to enter the data-bs-toggle attribute, the attribute is visible in the drop-down menu, and you can quickly select it, but when I get into quotes, the attribute value can be system will offer or maybe not offer, also with what it can be connected? Example data-bs-toggle="pill" , the value "pill" is not always displayed in the drop down menu and has to be searched for or entered manually.
for example, I am in the tag and start typing "cla" in one case, until I press ctrl + space, the class will not be offered, in the other case, literally further in the "a" tag, when typing "cla", almost immediately it is proposed to automatically make a class ="" (empty), again in this case VScode again behaves differently, all other things being equal, at these moments there are no reinstallation of extensions or other settings
Windows 10, projects and the system are all on a good ssd nvme, there should be no problems with loading a text file. All these questions came to me while studying Bootstrap 5.
I would be grateful for advice from experienced people, with the organization of the process of automating code entry. Maybe there are good extensions that I don’t know about yet, maybe the code editor chose the wrong one, maybe there are editors where you don’t need to install any extensions and everything works out of the box, intuitively?

VS won't color my code, intellisense won't work, and go to definition and other functions won't work

I can't provide any code because I'm under NDA, but as the title says, VS won't color my code or let me use any of the built-in tools it has. It allows me to rebuild and such, just not anything that directly edits or reveals any files. Google has absolutely nothing about the problem, everything is always VS Code. It's only for one specific project and it makes it very hard to work, does anyone know a solution? Has anyone ever heard of this problem?
It's Visual Studio 2022.
Edit:
The code is in TypeScript, with the .ts file extension, if that wasn't obvious, not to mention that it doesn't even interact with plain HTML. The only time it even colors the text is when I restart VS, then it goes back to not interacting with the text at all until I restart again, then it only highlights 2 of the files and stops again. This is the most information I could possibly give from my perspective, ask for any more you need.
I can usually fix this by simply closing VS and then reopening it. It's definitely a glitch in Visual Studio with both Typescript and Javascript files. If closing/reopening gets too annoying, there's some other things to try on this post:
Visual Studio 2022 - for typescript files Intellisense not working

Who or what is injecting "data-contrast" spans into my website (at night) and how to stop it?

It has been brought to my attention that a website I'm helping out with sometimes has problems with span elements being injected. Those spans will break the whitespaces and make the text hard to read. Those spans look something like this:
<span data-contrast="auto">words</span>
<span data-contrast="auto">,</span>
<span data-contrast="auto">b</span>
<span data-contrast="auto">ut</span>
<span data-contrast="auto">sometimes also only single chars</span>
The website is run with/by WordPress, but that does not seem to be the cause because the affected posts look fine and show no sign of this markup in the post editor or database.
Also, those spans only seem to occur at nighttime. I tried to nail that down, but as so often, I couldn't really verify it yet, as it did not occur again to me, not even at night. Right now everything is fine and none of these spans are present.
I'm guessing it has got something to do with night-mode in browsers (although behaviour was the same in Edge and Firefox) or the night-mode in Windows but then on the other hand I haven't noticed this on any other page yet.
So, this is somewhat strange and hard to nail down, but you'll find copied texts that contain the same markup, when you use a search engine and search for "data-contrast span". So, at least I'm not the only one with this problem.
Any ideas how to nail this down and find out what causes it?
Browser plug-ins are usually given permission to modify page source at run time. I would guess the culprit is a cross-browser extension like Night Eye or Dark Reader.
In general, adding a <span> shouldn't mess with your layout unless your CSS is changing span properties away from the browser defaults.
Option 1
You might be able to fix the issue by adding CSS to control how the layout looks:
span[data-contrast="auto"] {...}
That will select all spans that have that data attribute. Then add styling to counteract the layout issues you see. That said, since the extension is adding the code after the page renders, it may override whatever you do.
Option 2
A better solution would be to create your own dark mode. Most plugins/OS night modes won't mess with your code if you provide your own theme options. A "dark" theme is the 2020 version of being mobile responsive; you should provide it in your code or live with the consequences when users, browser makers, and operating systems make their own decisions.
If you need help creating an alternate theme, CSS Tricks has a good write up.
Since it's not clear what software they are copying from, I've personally experienced this when copying from a Word Doc that's been opened in Microsoft Teams or in SharePoint, and then pasting directly into a website's editor (our site uses the TinyMCE text editor, a commonly utilized free text editor).
My recommendation: copy directly from the desktop version of Word, then paste into the editor and that prevents the "data-contrast" spans.
I assume there must be some hidden spans in non-desktop versions of Word Docs that they add to ensure the document displays the same way as the desktop version. The text editor doesn't know what to do with it, so it strips out everything, but the "data-contrast" portion.
Hope this helps someone out there as the original post was as asked some time ago.

ckeditor and codesnippets plugin

I'm baffled! I built ckeditor 4.13 using the online builder, and included the codesnippet plugin. Now when I chose the plugin within the editor from the toolbar it allows me to add the code under which ever language I choose, but the syntax highlighting doesn't work for all languages. For example CSS is not highlighted. The background of the chosen theme is there, but no highlighting. SQL queries are fine as are some others, but not CSS or PHP it would seem!
Also, I'm editing in one place and then viewing the article on another place (pulling the article from a database). The styling is completely missing altogether when it's the article is viewed. I tried to find a CSS file which may contain the classes that had been attached to the snippets (such as language-php) but couldn't. I thought if I just linked to the CSS file in my header it would attach the styling...I was wrong!
Any ideas how I can tackle this issue please? Google has brought nothing so far.
For anyone interested, I've found the best way to deal with the syntax highlighting issue is to download prism. This will work with the classes produced by ckeditors codesnippet plugin and colour code the syntax according the theme you chose from Prism. Look at prismjs.com.

PyCharm - remove green lines which appeared upon inserting language reference

I'm working with django in PyCharm and these green lines are really annoying me.
They appeared when I inserted some language reference (I can't recall which one exactly...) and I don't know how to turn it off.
I tried editing some PyCharm settings but to no avail...
On the below picture I tried turning all inspections off, but it didn't work.
What is this sorcery and how do I brake it?
I've just realized that I needed to turn off Language injections.
To make sure that they all disappear, you should uncheck all of these:
In my case, I had to turn off xml:head, xml:div and xml:script.
You can uncheck one by one to see if which one it is exactly.
Cheers :)