I have a SublimeText 3 and RubyMine 2016.1 versions installed. When I work with HAML files in Sublime, I have a nice auto-completion similar to this:
As I type h1 and press Tab it becomes %h1, so I don't have to type % symbol.
Tried the same thing in RubyMine and nothing happened.
How can I achieve same auto-completion feature in RubyMine HAML as I had in a Sublime? Is that even possible or should I consider this behaviour as a feature of RubyMine IDE?
Thanks!
I don't think this kind of auto completion is supported in Rubymine.
By the way, even the code completion in HTML templates requires you to first type the < character so that auto-completion starts presenting suggestions, so I guess it is a general intention of the Jetbrains team to require the user to type the special character (such as % in HAML) first.
For a while I thought you might be able to add this functionality using Textmate Bundles import (Textmate bundles use the same format as Sublime bundles), but it appears that only the syntax-highlighting rules in them are supported in Rubymine. So this approach probably won't work either even if you managed to find a bundle with the auto completion feature for HAML files.
I'm a pretty heavy user of colon hashes but the default Aptana Studio Ruby doesn't provide any highlighting for them.
Here's a colon hash in Ruby 1.9:
{ animal: "duck" }
Does anyone know what bits I need to punch to make the "animal:" part display in another colour?
Update:
It seems from reading the source that the PLists file isn't being used by Aptana and that the feature is presently incomplete.
https://github.com/textmate/ruby.tmbundle/issues/17
I've tried changing the scopes in source but it doesn't seem to update for me.
To find the scope Aptana is trying to highlight
Commands -> Bundle Development -> Show Scope and Matching Theme Rule (alternatively the default shortcut is Ctrl+Alt+P)
Read the box. It may list several scopes.
The way you add a scope:
Window -> Preferences
Select Aptana Studio then the Themes option.
Press the + button next to the Scope Selector textbox.
Add your scope and set the colours.
Apply and click OK
I'm all out of ideas. Hopefully this will help someone get closer.
Aptana Studio 3 uses TextMate themes for syntax highlighting, so you just need to find a TextMate theme that supports it.
How do I get Aptana to apply the same syntax highlighting and auto-complete that exists on .html files to my files that end in .handlebars?
I'm assuming there must be some setting in Preferences to allow this, but I'm not seeing it.
If it helps, I'm using version 3.0.7.2011
Ok, recently figured this one out.
Under Windows > Preferences select General > Editors > File Associations.
Here, you can simple add whatever extension you want, then the editor that you want to apply it to.
Here's a screenshot:
After you click "Ok" you will have whatever syntax highlighting or code completion that the editor you specified has.
I'm writing some documentation that will occasionally include C# or C++ code snippets.
In Visual Studio, the Edit/Copy command includes syntax coloring. You can see this if you paste the text into, e.g., Word or Outlook. In fact, if you use the "Paste Special..." command, you can see that it's "Rich Text (RTF)".
However, when pasting this text into an HTML file in Visual Studio, none of the colouring (or even formatting) is preserved.
Any ideas? I'm looking specifically for something that works locally (preferably in Visual Studio), not JavaScript-based solutions (such as SyntaxHighlighter).
There's an addin called CopySourceAsHtml which does a pretty neat job. I've used it a few times, but I use a Javascript to do the highlighting on my blog these days (so it's "plaintext readable").
You can use existing C to HTML syntax highlighter tools for converting your snippets into HTML and copy&pasting from there. Here's a list of such tools (not exhaustive and in no particular order):
GNU Enscript
GNU Emacs with htmlize.el module allows you to dump a highlighted Emacs buffer as HTML
There might also exist web services that allow you to copy&paste C code into a form and get highlighted HTML back.
I use this for highlighting code on webpages. It's simple to use and easy to extend.
http://code.google.com/p/syntaxhighlighter/
It also supports C#.
If you've ever used Eclipse, you've probably noticed the great keyboard shortcuts that let you hit a shortcut key combination, then just type the first few characters of a function, class, filename, etc. It's even smart enough to put open files first in the list.
I'm looking for a similar functionality for Visual Studio 2008. I know there's a findfiles plugin on codeproject, but that one is buggy and a little weird, and doesn't give me access to functions or classes.
Vs11 (maybe 2010 had it too) has the Navigate To... functionality which (on my machine) has the Ctrl+, shortcut.
By the way it understands capitals as camelcase-shortucts (eclipse does so too). For instance type HH to get HtmlHelper.
This isn't exactly the same as Eclipse from your description, but Visual Studio has some similar features out of the box (I've never used Visual Assist X, but it does sound interesting).
The Find ComboBox in the toolbar ends up being a sort of "Visual Studio command line". You can press Ctrl+/ (by default) to set focus there, and Visual Studio will insert an ">" at the beginning of the text (indicating that you want to enter a command instead of search). It even auto-completes as you type, helping you to find commands.
Anyway, to open a file from there, type "open <filename>". It will display any matching files in the drop down as you type (it pulls the list of files from the currently open solution).
To quickly navigate to a function, in the code editor press Ctrl+I to start an incremental search. Then just start typing until you find what you are looking for. Press Escape to cancel the search, or F3 to search again using the same query. As you are typing in the search query, the status bar in the lower left corner will contain what Visual Studio is searching for. Granted, this won't search across multiple files (I've never used Eclipse much, but that sounds like what it does from your description), but hopefully it will help you at least a little bit.
If anyone stumbles upon this thread:
There's a free plugin (created by me) for Visual Studio 2008 that mimics the Eclipse Ctrl+Shift+R Open Resource dialog (note, not the Open Type dialog). It works with any language and/or project type.
You can find it at Visual Studio Gallery.
Some of the neat features are available in Visual Assist X, though not all of them. I've asked on their forums, but they haven't appeared as yet. VAX gets updated regularly on a rough 4 week period for bug fixes and a new feature every couple of months.
If you are looking for an add-in like this to quickly navigate to source files in your project:
try the Visual Studio 2005/2008 add-in SonicFileFinder.
Resharper does this with the Ctrl-N keyword. Unfortunately it doesn't come for free.
Visual Studio doesn't have anything like this feature beyond Find.
Found this thread while searching for Eclipse's Ctrl+Shift+R, and after seeing the Visual Studio Gallery, found the DPack Tools (they are free, and no, I'm not endorsed in any way by them).
But it's exactly what I was searching:
- Alt+U -> File Browser (a la Eclipse Ctrl+Shift+R)
- Alt+M -> Code Browser (Method list in the actual class)
It has more features, but I'm happy with these ones.
I have been using biterScripting along with Visual Studio to do more flexible searching and manipulation.
It can search the entire workspace.
It can search within any project - EVEN IF THAT PROJECT IS NOT LOADED OR EVEN PART OF A WORKSPACE.
It can find things using regular expressions.
AND, ABOVE ALL, it can make bulk changes. For example, want to change the name of a class from CCustomer to CUser, I can do it in just a few command lines - Actually, I have written scripts for things like this I do often. I DON'T HAVE TO CLICK ON EACH INSTANCE AND MANUALLY DO THE CHANGE.
And, it is inexpensive ($0). I downloaded it from http://www.biterscripting.com .
I'm also comming from the Java Development side and was looking for the CTRL+T feature in the Visual Studio. The other answers refer to open file, but since in C# the class name and file name can be different this is not what i was looking for.
With the Class View or the Object Browser you can search for Objects and Classes
[View]->[Class View] or [View]->[Object]