Where can tooltips be enabled in VS Code - visual-studio-code

I use VS Code to read C# code and it always showed me tooltips (hints or whatever they're called). I could just hover the mouse cursor over the fragment of code and it told me if that's a class or method or anything else.
I'm not a programmer so that was helpful.
It also allowed me to click on the code fragment with the CTRL button pressed. It opened the related file to the code in an adjacent tab.
But then something happened and I can't do anything of the above. It makes work very uncomfortable.
Can you please give any advice as to how to return these functions?

Related

How do I get imports to show up when I press ctrl+dot in javascript in vscode?

When writing JSX (or any typescript code really) if you have an available import that's not yet imported, you get a squiggly line under it and can press ctrl+dot on it and then automatically import the code as a "refactoring."
How can I set this up in Javascript? I've seen a screenshot of someone else's VSC where it is available underneath "more options" and so I'm pretty sure it's possible, but when I press ctrl+dot I get nothing.
Note: I'm aware I can press ctrl+space. However, I don't want to do this, for two reasons. (1) alt+space is pretty bad UX because if you press it in the middle of a word it continues to autocomplete even if you already had the full name there and so you are left with an incorrect tag (e.g. if your cursor was after the d in Keyboard for a component called KeyboardRow you are left with KeyboardRowRow) and (2) I want to rebind quick fix to alt+enter to match pycharm; and I want the same hotkey & UX in both Typescript and Javascript.
I haven't worked too much with JS, mainly with TS, but I have two extensions installed in my vscode that helped me a lot while coding in vanilla JS.
Path intellisense and Auto import
You can try if My Code Actions can be used to construct a Quick Fix for these types of PROBLEMS/squiggles

Weird snippet in VSCode

Does anybody know what this weird snippet is? It doesn't expand into anything.
These block-looking snippets underneath are VSCode's built-in snippets, but this first one is useless and it forces me to press the down arrow every time I want to use any loop. It doesn't have anything to do with my extensions and options and I can't get rid of it.
It is not a snippet, for is a keyword in the language you're coding. So it's just a suggestion for code completion.
In Python def is a keyword to create functions:
Check this page from document to see the explanation of the other icons.
Also if "pressing down arrow" bothers you, you have an option to set the visibility of the snippets on the top of the suggestion list:
"editor.snippetSuggestions": "top",

Atom popup, really annoying

I have no idea what plugin is doing this, but it's incredibly annoying everytime I move mouse mouse to constantly get a popup. When I am coping and pasting code it pops up, and I have to click somewhere else, and it blocks so much of screen. Anyone know what plugin might be doing this?
For me, this was happening because of the atom-ide-datatip package. I went into the settings for that package and unchecked "Show datatip automatically on mouse hover", and checked "Show datatip automatically on cursor stay" as that got in the way for me less.
In my opinion, it would be nice if you could turn off those datatips for certain data types, like int and str. I mostly use this package for the function parameter popups.

VS Code settings

I would like to change the following VS code behavior but can't find a way to do so:
When the cursor is on some items a box pops up with info about that item. I find this extremely annoying as it often blocks what I'm trying to edit. How to disable the pop up?
I code CSS on a single line, such as:
h1 {something; something; something; } And the next CSS on the next line. No Spaces!
But when I save it VS code automatically reformulates it, putting each something on a new line. This is extremely, extremely annoying! It horribly wastes space, and forces me to scroll down a lot to find something I want to edit. How do I get VS code to stop messing with My Coding Style?
To disable the pop up. Do these necessary changes Disable pop up
To stop the CSS formatting, just see in the extensions if you have downloaded CSS formatter, if so then uninstall it or disable it.

Netbeans: Hide specific lines in source code

Is it possible in Netbeans to hide some pieces of code, especially debugging code, from the Source Code View?
For example I would want to hide: System.out.println("DEBUG: ...");, with ... being whatever is needed to print some variables.
I don't like that it misses up how my code looks, but if I remove it entirely then I might need it again tomorrow for example.
In NetBeans you can hide code in editor folds. Just put the code you would like to hide in between comments of the form:
//<editor-fold defaultstate="collapsed" desc="comment">
//</editor-fold>
For example, I use this to automatically hide code with sensitive information when screen casting, giving presentations, or the like. This way the code is still functional, but I can only expose the parts that are important to the discussion.
//<editor-fold defaultstate="collapsed" desc="API-KEY">
private static final String API_KEY = "Not to be shared";
//</editor-fold>
You can also add a fold by selecting the code you wish to hide with the mouse. A light bulb icon will appear in the editor's margin. Click the light bulb and pick
Surround with //<editor-fold defaultstate="collapsed" desc="comment">...
to have the editor add the needed comments for you.
Netbeans editor allows you to hide (fold):
entire methods
inner classes
imports
Javadoc and
initial Comment and tags.
Discreet statement lines are not part of this list.
Options-->Editor-->General allows you the control of what will be collapsed.
Imagine the mess you would get into, if you have a few selected hidden statement lines and you try to find what goes wrong in a source code you can partially view.
Print statements is not the way you should use in order to test your code. Do it with the excellent Visual Debugger or with JUnit. This way you will have no more issues with mixing debugging print instructions with your actual code.