interface.rst 5.1 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140
  1. .. _interface:
  2. The JupyterLab Interface
  3. ------------------------
  4. JupyterLab provides flexible building blocks for interactive,
  5. exploratory computing. While JupyterLab has many features found in
  6. traditional integrated development environments (IDEs), it remains
  7. focused on interactive, exploratory computing.
  8. The JupyterLab interface consists of a :ref:`main work area <main_area>` containing tabs of
  9. documents and activities, a collapsible :ref:`left sidebar <left_sidebar>`, and a :ref:`menu bar <menu_bar>`.
  10. The left sidebar contains a :ref:`file browser <working_with_files>`, the :ref:`list of running kernels
  11. and terminals <running>`, the :ref:`command palette <commands>`, the :ref:`notebook cell tools inspector <notebook>`,
  12. and the :ref:`tabs list <tabs>`.
  13. .. image:: images/interface_jupyterlab.png
  14. :class: imageshadow
  15. .. _menu_bar:
  16. Menu Bar
  17. ~~~~~~~~
  18. The menu bar at the top of JupyterLab has top-level menus that expose
  19. actions available in JupyterLab with their keyboard shortcuts. The
  20. default menus are:
  21. - **File**: actions related to files and directories
  22. - **Edit**: actions related to editing documents and other activities
  23. - **View**: actions that alter the appearance of JupyterLab
  24. - **Run**: actions for running code in different activities such as
  25. notebooks and code consoles
  26. - **Kernel**: actions for managing kernels, which are separate processes
  27. for running code
  28. - **Tabs**: a list of the open documents and activities in the dock panel
  29. - **Settings**: common settings and an advanced settings editor
  30. - **Help**: a list of JupyterLab and kernel help links
  31. :ref:`JupyterLab extensions <user_extensions>` can also create new top-level menus in the menu
  32. bar.
  33. .. _left_sidebar:
  34. Left Sidebar
  35. ~~~~~~~~~~~~
  36. The left sidebar contains a number of commonly-used tabs, such as a file
  37. browser, a list of running kernels and terminals, the command palette,
  38. and a list of tabs in the main area:
  39. .. image:: images/interface_left.png
  40. :align: center
  41. :class: imageshadow
  42. The left sidebar can be collapsed or expanded by clicking on the active
  43. sidebar tab:
  44. .. raw:: html
  45. <iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/PlJGecfetek?rel=0&amp;showinfo=0" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen class="imageshadow"></iframe>
  46. JupyterLab extensions can add additional panels to the left sidebar.
  47. .. _main_area:
  48. Main Work Area
  49. ~~~~~~~~~~~~~~
  50. The main work area in JupyterLab allows you to arrange documents
  51. (notebooks, text files, etc.) and other activities (terminals, code
  52. consoles, etc.) into panels of tabs that can be resized or subdivided:
  53. .. raw:: html
  54. <iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/Ka8qS7CO1XQ?rel=0&amp;showinfo=0" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen class="imageshadow"></iframe>
  55. The work area has a single current activity. The tab for this activity
  56. is marked with a colored top border (blue by default).
  57. .. _tabs:
  58. Tabs and Single-Document Mode
  59. ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
  60. The Tabs panel in the left sidebar lists the open documents or
  61. activities in the main area:
  62. .. image:: images/interface_tabs.png
  63. :align: center
  64. :class: imageshadow
  65. The same information is also available in the Tabs menu:
  66. .. image:: images/interface_tabs_menu.png
  67. :align: center
  68. :class: imageshadow
  69. It is often useful to focus on a single document or activity without
  70. closing other tabs in the main area. Single-Document Mode toggles the
  71. view of the main area to show only a single tab at a time:
  72. .. raw:: html
  73. <iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/DO7NOenMQC0?rel=0&amp;showinfo=0" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen class="imageshadow"></iframe>
  74. When you leave Single-Document Mode, the original layout of the main
  75. area is restored.
  76. Context Menus
  77. ~~~~~~~~~~~~~
  78. Many parts of JupyterLab, such as notebooks, text files, code consoles,
  79. and tabs have context menus that can be accessed by right-clicking on
  80. the element:
  81. .. raw:: html
  82. <iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/y30fs6kg6fc?rel=0&amp;showinfo=0" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen class="imageshadow"></iframe>
  83. The browser’s native context menu can be accessed by holding down
  84. ``Shift`` and right-clicking:
  85. .. raw:: html
  86. <iframe width="560" height="315" src="https://www.youtube-nocookie.com/embed/XPPWW-7WJ40?rel=0&amp;showinfo=0" frameborder="0" allow="autoplay; encrypted-media" allowfullscreen class="imageshadow"></iframe>
  87. .. _shortcuts:
  88. Keyboard Shortcuts
  89. ~~~~~~~~~~~~~~~~~~
  90. As in the classic Notebook, you can navigate the user interface through keyboard shortcuts.
  91. To find these shortcuts, go to the File, select the Settings menu option, then select Keyboard Shortcuts.
  92. With Keyboard Shortcuts in the settings editor, you can see a full list of keyboard shortcuts, and customize them as well.
  93. [screenshot]
  94. You can also navigate JupyterLab using vim, emacs, and Sublime Text key-maps.
  95. Customize your shortcuts with these settings, by selecting Settings, Text Editor Key Map, and selecting your preferred key-map.