# Getting Started with Paligo

### Using the Source Code Editor

While the Paligo editor is made to make structured authoring as natural as possible, there may be times when you need to edit the actual source XML.

To edit the XML in the code editor:

1. open the Source Code Editor, available in the toolbar: . The editor opens in a separate window:

3. Click Update.

Note that this does not save the topic, it just updates the content just as if you had made any regular edit directly in the main editor view. You can also still undo any changes back in the main editor. Only when you save will your changes be stored.

### Warning

Please note that while convenient, editing XML directly in plain code view requires that you are sure of what you are doing. Although you won't be able to save invalid XML as Paligo will validate it (as long as you have the auto-validation turned on), you should still be careful so you don't accidentally make unintentional changes.

You should be especially careful not to edit attributes such as xinfo:text, and xml:id as these are id:s in Paligo if you are not sure what the results are. More on that below.

The default theme is called Monokai, a dark theme easy on the eye. But you can use any of a number of themes for the look and feel of the Source Code Editor, whatever is more comfortable for you. Just click the cog wheel icon in the toolbar, and select Code Editor.

Example using the Chrome theme

#### Copying elements in the Source Code Editor

If you copy an element in the code editor, and paste it in another place, you will by default get the text content as "Reuse text". The same as if you had used the Reuse text search feature or used the Copy as reuse keyboard shortcut.

If you do not want the text reused, this is one time where it can be useful to touch the xinfo:text attribute (see the warning above though). To not have the text reused, simply remove the xinfo:text attributes:

### Warning

If you do this, only change it on the copied element, not the original. Otherwise you will create a completely new text fragment for the original text as well. If you e.g had translated it before, that translation would then be lost.