I'm using the Visual Studio Code. I never want auto semicolon after CSS properties. But VS Code gives me an auto-complete option which I don't like.
How can I stop auto-complete semicolon at the end of CSS properties?
Settings > Extensions > CSS , uncheck the Complete Property With Semicolon.
or
You can change the default values in the Settings editor.
search the code & change it from true to false.
// Insert semicolon at end of line when completing CSS properties
"scss.completion.completePropertyWithSemicolon": false,
From: https://code.visualstudio.com/docs/getstarted/settings
Press Control + Shift + P in VSCode.
Search For Preferences: Open Settings (UI).
Again in the Searchbar, search for Semicolon.
Choose CSS or your preferred language from where you want to remove auto
semicolon.
Untick Insert semicolon at the end of line when completing CSS properties.
And you are done.
In Settings go to Extensions -> CSS and uncheck 'Completion: Complete Property With Semicolon'
Related
Is it possible to configure the editor that when you type a tag like:
body
and hit enter/tab, the editor will autocomplete it to:
body {
}
and indent the selection to where the first property would be typed?
I've looked into Editor/Codestyle/Stylesheets/CSS but found nothing.
Yes. A few different options:
Type body { and hit Enter. With default settings the IDE will insert missing }, add a new line and auto indent.
This is controlled by options at "Settings/Preferences | Editor | General | Smart Keys".
Type body and hit Ctrl + Shift +Enter (or whatever other shortcut you may have there in your Keymap for Code | Code Completion | Complete Current Statement action).
Write your own snippet (using Live Templates) that once expanded will replace the trigger code by inserting the snippet instead.
Lets assume that you have selected bb as the abbreviation for this snippet. Then typing bb and hitting Tab (or whatever other expand key you may select for this) will inert the whole block at once.
I used to work with a developer who, selects a text in aspx page and applies a keyboard shortcut to enclose it in double quotes.
Eg: runat=server. when i select server and press ctrl+somekey, it should be runat="server"
Could someone tell me what is the keyboard shortcut, i tried googling a lot, but couldnt find one..
Currently we are overhauling a page, and need this badly...
Thanks in advance.
As far as I know this is a setting in Visual Studio which enables you to immediatelly place quotes when you type attribute and press equals sign or if you type a few letter and press CTRL+Space. This will autocomplete the attribute and place quotes. In order to enable the quotes click on Tools then Options. If it is not checked, check Show all settings. Expand Text Editor, then HTML and click on Formatting. On the right side enable Insert attribute values quote when typing and Insert attribute value quotes when formatting
Format selection: ctrl+k, ctrl+f
I also have Tools > Options > HTML > Formatting > Insert attribute value quotes when formatting checked.
I think you should try this with the replace function
search : runat=server
replace: runat="server"
The developer may have been using a refactoring tool such as CodeRush or Resharper. Have a look at this link for how you may be able to do something similar without extra tools.
The demo web project that ships with the VS2010 contains a system.web.ui.webcontrols.menu control.
That particular menu includes the IncludeStyleBlock property.
When the IncludeStyleBlock property is set to False the menu is displayed as it supposed to. The menu gets destroyed if i set that property to True. So here is my main question...
Is there any way of preserving the appearence of the menu, with the IncludeStyleBlock property set to false?
P.S. I have to set it to False... since my provider does not support the forth generation of the .NET framework.
If the generate elements got id's and classes, you can style them with a normal CSS file. Does it generated inline CSS with the option turned on? If so you can copy that to an external file to start with
Does this page give you some clue, specifically in the Remarks section?
In short, if you set the property to false, you must provide "your own block of CSS definitions in the page, or include a link to an external CSS file that contains the definitions." In addition, you won't be able to set style properties.
So, conversely, if you set the property to true, it would ignore the style properties you provide.
You misspoke in your question. You begin by saying the menu is perfect when IncludeStyleBlock property is set to False and breaks when True. Then you say it is broken when False and you want a workaround for making in work under False.
Because of this confusion I am basing this answer off the assumption that you want to mimic the default style set by ASP.NET when IncludeStyleBlock is set to true but while keeping IncludeStyleBlock="False"
First: Since the menu displays perfectly when IncludeStyleBlock="True" , what you need to do is set it to true and preview the rendered source code. From the source code you can find the copy of the default CSS block that the Menu control generates by default. This is what you need.
Second: Once you have the CSS block, simply copy and paste it into your markup (inline or externally). Once you do that, you can make IncludeStyleBlock="False" and the now inline/external CSS block will preserve the appearance of the menu. (As a bonus, this is a small performance boost from caching CSS)
In VS2008, it used to be that whenever I was typing an html attribute in an .aspx page when I hit '=' a pair of double quotes was automatically inserted and the cursor placed inside them. I guess I've changed a setting, but I don't know what to change to get that functionality back.
I am using Resharper if it makes a difference.
In VS2008. Tools -> Options -> Text Editor -> HTML -> Format -> Click "Insert attribute value quotes when typing".
Not sure how this is impacted with Resharper.
The felx builder (on eclipse) next/previous word command, usually bound to CTRL-RIGHTARROW on OPTION-RIGHTARROW on the mac, doesn't stop for ":" and "." and in a few other cases.
It's clearly a wrong behaviour for action script development!
How can I change it?
Here is the fix:
http://www.visible-form.com/blog/mac-eclipse-word-boundary-issue-fix/
"Go to System Preferences > Language & Text > Text, and set the ‘Word Break’ dropdown to ‘English, United States (Computer)’."
Remember Quit Flex Builder and restart it. If this doesn't work, try restarting the OS.
This option is missing in Mavericks… you can fix it with:
defaults write .GlobalPreferences AppleTextBreakLocale en_US_POSIX