How to format code in Xcode? 

Select first the text you want to format and then press Ctrl+I. Use Cmd+A first if you wish to format all text in the selected file. Note: this procedure only re-indents the lines, it does not do any advanced formatting. In XCode 12 beta: The new key binding to re-indent is control+I.

Autoindent on Sublime Text

That’s quite simple in Sublime. Just Ctrl+Shift+P (or Command+Shift+P on MacOS) to open the tools pallet, type reindent, and pick Indentation: Reindent Lines. It should reindent all the file you are in, just remember to save before running the command, or it may not appear.

How do you display code snippets in MS Word preserving format and syntax highlighting?

Here is the best way, for me, to add code inside word: Go to Insert tab, Text section, click Object button (it’s on the right) Choose OpenDocument Text which will open a new embedded word document Copy and paste your code from Visual Studio / Eclipse inside this embedded word page Save and close Advantages The result looks very nice. Here are the … Read more

Is there a command for formatting HTML in the Atom editor?

Atom does not have a built-in command for formatting html. However, you can install the atom-beautify package to get this behavior. Press CTRL + SHFT + P to bring up the command palette (CMD + SHFT + P on a Mac). Type Install Packages to bring up the package manager. Type beautify into the search box. Choose atom-beautify or one of the other packages and click Install. Now you can use the default keybinding for … Read more

How do I format XML in Notepad++?

Try Plugins -> XML Tools -> Pretty Print (libXML) or (XML only – with line breaks Ctrl + Alt + Shift + B) You may need to install XML Tools using your plugin manager in order to get this option in your menu. In my experience, libXML gives nice output but only if the file is 100% correctly formed.

How do you format code in Visual Studio Code (VSCode)?

The code formatting is available in Visual Studio Code through the following shortcuts: On Windows Shift + Alt + F On Mac Shift + Option + F On Linux Ctrl + Shift + I Alternatively, you can find the shortcut, as well as other shortcuts, through the ‘Command Palette’ provided in the editor with Ctrl +Shift+ P (or Command + Shift + P on Mac), and then searching for format document. For unsaved snippets Open command palette (Win: F1 or Ctrl+Shift+P) Find ‘Change Language … Read more