syntax-highlighting

Syntax highlighting rules and definitions

|▌冷眼眸甩不掉的悲伤 提交于 2019-12-05 01:10:39
Are there any standard syntax highlighting rules for R? If yes, where can they be found? Or does each editor, IDE, package (e.g., the highlight package) create their own rule set? Richie Cotton Each editor creates their own rule set. For historical reasons, each editor has implemented syntax highlighting in its own way. Having a cross-editor standard may be possible using, for example, GeSHi , but it would almost certainly require a lot of effort getting editor makers to sign up to it, especially if they already have their own system. Eclipse uses .hrc files for storing syntax information.

How do I make Dreamweaver to show me closing tags?

情到浓时终转凉″ 提交于 2019-12-04 22:46:35
I would like Dreamweaver to show me the opening/closing tag when I select a tag. This functionality is seen in many editors, I know for sure Eclipse has it. To make things clearer: When I select/highlight a <div> opening tag with my mouse I would like Dreamweaver to select/highlight the </div> closing tag. My main questions: Does anybody know what this functionality is called? Does anybody know how to add this functionality to Dreamweaver? I've tried searching the Dreamweaver extensions on the Adobe exchange but couldn't find what I'm looking for. David Powers Dreamweaver has two different

Visual Studio: Custom code highlighting based on regex

蓝咒 提交于 2019-12-04 22:46:16
问题 As my application supports some paranoid debug level (every data assignment, every step in the code is written to a log destination), my code is littered with logging calls in some methods, e.g. logger.Log(LogLevel.Debug, 0, "Initializing i18n..."); Lang.Language = SystemInfo.Language; Logger.Log(LogLevel.Debug, 0, "Default system language: " + Lang.Language); string[] languageFiles = Directory.GetFiles(ClientEnvironment.LanguagePath); Logger.Log(LogLevel.Debug, 0, "Initializing local

How do I add intellisense to my application?

别来无恙 提交于 2019-12-04 19:32:39
问题 We have a proprietary macro language in one of our products, edited through our Windows software. I would like to add intellisense, but I have no idea how to go about this (at least not without completely reinventing the wheel). Is there any sample code or 3rd party package that can at least get me started? It doesn't have to be free. The application uses .NET, written in C#. 回答1: There is a CodeProject article about adding intellisense to your own applications: DIY Intellisense It should

Change face of plain text between double quotation marks in Emacs

元气小坏坏 提交于 2019-12-04 18:17:52
I am looking for a way to highlight or use different face of quoted text in plain text. It seems that there should be a sophisticated/enhanced text mode but I cannot find it. If there isn't a easy solution, can you let me know where should I begin to write a function? Thank you very much! A noob who has been using Emacs from 19.xx I'm not sure about a major-mode that already does this, but you can make one easily enough using define-derived-mode (define-derived-mode rich-text-mode text-mode "Rich Text" "text mode with string highlighting." ;;register keywords (setq rich-text-font-lock-keywords

Eclipse stops highlighting references after a while

情到浓时终转凉″ 提交于 2019-12-04 18:05:05
问题 When I open a Java file for editing in Eclipse, references highlighting works well for a while, but then suddenly stops working after some minutes. On this example, parameters was the last variable correctly highlighted, but now it's no longer working and not highlighting anything else (it should highlight password ): Toggling Mark Occurrences off and back on doesn't solve it. I've already tried restarting Eclipse and rebooting the computer (had this problem for weeks actually). The only

Syntax coloring of own types in Visual Studio (C++)

跟風遠走 提交于 2019-12-04 17:44:07
问题 How can I get Visual Studio to highlight my own class types? This works fine for C# but not for C++... 回答1: For those running Visual Studio 2010 Highlighterr may fit your needs. It's also in the MSDN Visual Studio Gallery. It leverages the improved C++ IntelliSense in 2010. It makes you set special highlighters in Environment -> Fonts and Colors for the types it detects, but overall it works quite well from what I've seen. 回答2: you can use viusal-assist or Re-sharper both have setting for

How to manually specify syntax highlighting for a specific extension in Eclipse?

耗尽温柔 提交于 2019-12-04 17:15:23
问题 I am editing some files with the extension '.ctp'. Although these files are perfectly valid PHP files, Eclipse doesn't seem to know that and refuses to do any syntax highlighting with them. How can I manually instruct it to use PHP syntax coloring for '.ctp' files? Is there even a way to do that? 回答1: In Preferences , go to General -> Content Types . Unfold Text , then go to PHP Content Type . Click Add and input * .ctp . Then apply your changes. You may need to restart eclipse to take effect

How to set syntax highlighting to a code section to a specific language programmatically/with comments?

邮差的信 提交于 2019-12-04 15:29:26
I have a Laravel blade template (.blade.php) which contains plain JavaScript as a section that will be later inserted into a generic wrapper. So the example would be: <div>Some HTML content</div> @section('js') var a = "b"; someCall(); @endsection Now PhpStorm would recognize the JavaScript if it was in <script> tag, which it can't be. So I've tried this which I would expect to work like a section highlighter hint: @section('js') // @lang JavaScript var a = "b"; someCall(); // @endlang @endsection and this @section('js') // language=JavaScript var a = "b"; someCall(); @endsection But nothing

What does the three slashes in javascript do?

会有一股神秘感。 提交于 2019-12-04 13:38:57
I'm still new to Javascript so when my editor highlights it I'm intrigued. what exactly does it do? Example: /// things go after here Some documentation generators regard three slashes /// as introducing documentation comments to JavaScript. See http://msdn.microsoft.com/en-us/library/bb514138(v=vs.110).aspx So three slashes work the same as two slashes as far as JavaScript is concerned (it's a comment-to-end-of-line), but three slashes can be interpreted by documentation generators to indicate a documentation section. Example: function getArea(radius) { /// <summary>Determines the area of a