Rubymine: Change Code Language - rubymine

I'm working with a file that is one type (php), but the code is predominantly another language (html). Is there a way that I can switch the syntax highlighting (if that's what it's called) from php to html?

associate *.php as PHP files, and DONE

Related

How to parse a C/C++ header file in dart?

I'm working on a flutter desktop app which should (according to my plan) has the ability to open C/C++ header files (as a plain text) and parse the source code and find all structures and get theirs properties, is there any existing package fits my need, or, maybe I should go with regex instead?

What is the correct way to import/require "vscode" inside the developer tools inside VS Code? [duplicate]

Is there any way to use variable vscode to get editor content just like Atom without writing Extension.
After getting editor content, I can do more things like:
Use Javascript to modify text literally
Custom format
vscode image
atom image
No. This is not supported.
You can use the extension API to extend VS Code. This API lets you get and modify editor contents

Questions regarding language translation using .pot file

I have a .pot file that I wish to translate to a native language and get the final .po file. At this moment, the only plausible option that I have is to open the set of .pot files in a text editor and convert each phrase to the native language.
I would like to know if this can be automated by using some tool/software . I tried POEDIT (in Windows) for converting my .pot file to the native language (Hindi) but it could not perform a single translation. Please provide some inputs.
Thanks
You can use Translator Toolkit provided by Google.
https://translate.google.com/toolkit
(you need a Google account)
Before uploading your file you have to change the file extension to .po so google can accept it.
After translation; download the translated file and use your editor of choice to manage and optimize your translations.

Netbeans - Is it possible to change editor default programming language?

I would like to edit file.html with javascript mark ups? Simple open my .html file as .js file.
Go to Tools|Options -> Miscellaneous|Files and for File Extension html change Associated mime type to text/javascript
The answer is yes you probably can, but why would you want to edit an HTML file with Javascript markups/syntax highlighting? Whilst there is nothing preventing you doing it, it is not really good practise to have any significant amount of Javascript in an HTML file, so if you have a large amount it should be in a separate .js file

firefox addon development and Unicode

So I started developing my firefox addon.
Most of the work is performed by a referenced javascript file.
Problem is that when I edit some of the html elements on the page and say, set their text it's written as pure giberish. I am writing the text in hebrew. Can't for the life of me figure the reason.
Any ideas?
Javascript strings are already Unicode at runtime. However, you have to make sure that your files are encoded correctly.
Always use utf-8 (without BOM) file encoding for all your js, XUL, DTD, properties files to be sure.
Firefox might try to guess the file character set incorrectly otherwise, and even worse some stuff might not even try guessing the encoding and instead simply always assume utf-8.
Better yet, do not hard-code strings in js/xul, but use DTD/properties files for localization (XUL tutorial, XUL School).
This, e.g. snippet works pretty well for me (on this very page):
document.getElementsByTagName("h1")[0].textContent="русский язык";
(Just fire up the Firefox Web Console)
"Inline" hewbrew embedded in js files might create additional problems because it is right-to-left and bidi sucks, so the localization approach should be preferred.