How to make two windows in Sublime Text 3

Create two windows in Sublime Text 3 w/ an example: split view, open two files simultaneously, & customize layout.

Creating Two Windows in Sublime Text 3

Sublime Text 3 is a powerful text editor with many features and customization options. One of the most useful features is the ability to have multiple windows open at the same time. This can be particularly useful when working on complex projects with multiple files.

To create two windows in Sublime Text 3, you must first open the main window. To do this, select the "Open" option from the File menu or press the keyboard shortcut Command + N (Mac) or Ctrl + N (Windows). This will open a blank window in Sublime Text 3.

Once the main window is open, you can create a new window by selecting the "New Window" option from the File menu or pressing the keyboard shortcut Command + Shift + N (Mac) or Ctrl + Shift + N (Windows). This will open a second blank window in Sublime Text 3.

You can now begin editing in either window. To switch between windows, press the keyboard shortcut Command + ` (Mac) or Ctrl + ` (Windows). This will toggle between the two windows.

You can open files in either window by selecting the "Open" option from the File menu or pressing the keyboard shortcut Command + O (Mac) or Ctrl + O (Windows). To open a file in the other window, simply press the keyboard shortcut Command + Shift + O (Mac) or Ctrl + Shift + O (Windows).

You can also split the current window into two parts and edit files in both parts simultaneously. To do this, select the "Split" option from the View menu, or press the keyboard shortcut Command + Option + 2 (Mac) or Ctrl + Alt + 2 (Windows). This will split the current window into two parts.

You can now open files in either part of the window. To switch between the two parts, press the keyboard shortcut Command + Option + 1 (Mac) or Ctrl + Alt + 1 (Windows). You can also resize the parts of the window by dragging the edges of each part.

In addition to splitting the window into two parts, you can also split the window into three or four parts. To do this, select the "Split" option from the View menu and select the desired number of parts. You can switch between the different parts by pressing the keyboard shortcut Command + Option + [number] (Mac) or Ctrl + Alt + [number] (Windows).

Sublime Text 3 also provides an easy way to move files between windows. To do this, select the "Move File" option from the File menu or press the keyboard shortcut Command + Shift + M (Mac) or Ctrl + Shift + M (Windows). This will open a dialog box where you can select the window to which you want to move the file.

// This is an example of JavaScript code

function sayHello() {
  console.log("Hello!");
}

sayHello();

By taking advantage of Sublime Text 3's multiple windows and splitting features, you can easily manage multiple projects and files. This can save you time and make it easier to work on complex projects.

Answers (0)