forked from qt-creator/qt-creator
Doc: Describe new language client settings and features
Change-Id: I9d3e9e094b6256f202e6b7fea559d06f94c9d5be Reviewed-by: David Schulz <david.schulz@qt.io>
This commit is contained in:
Binary file not shown.
Before Width: | Height: | Size: 15 KiB After Width: | Height: | Size: 11 KiB |
@@ -1,6 +1,6 @@
|
|||||||
/****************************************************************************
|
/****************************************************************************
|
||||||
**
|
**
|
||||||
** Copyright (C) 2018 The Qt Company Ltd.
|
** Copyright (C) 2019 The Qt Company Ltd.
|
||||||
** Contact: https://www.qt.io/licensing/
|
** Contact: https://www.qt.io/licensing/
|
||||||
**
|
**
|
||||||
** This file is part of the Qt Creator documentation.
|
** This file is part of the Qt Creator documentation.
|
||||||
@@ -99,7 +99,7 @@
|
|||||||
\section1 Using Locator Filters
|
\section1 Using Locator Filters
|
||||||
|
|
||||||
The locator enables you to browse not only files, but any items defined by
|
The locator enables you to browse not only files, but any items defined by
|
||||||
\b{locator filters}. By default, the locator contains filters for:
|
\b{locator filters}. The filters that are available depend on the file type:
|
||||||
|
|
||||||
\list
|
\list
|
||||||
|
|
||||||
@@ -114,11 +114,11 @@
|
|||||||
\li Locating bookmarks (\c {b}).
|
\li Locating bookmarks (\c {b}).
|
||||||
For more information, see \l{Using Bookmarks}.
|
For more information, see \l{Using Bookmarks}.
|
||||||
|
|
||||||
\li Locating class (\c {c}), enum, and function (m) definitions in your
|
\li Locating class (\c {c}), enum, and function (\c {m}) definitions in
|
||||||
project or anywhere referenced from your project (\c {:})
|
your project or anywhere referenced from your project (\c {:})
|
||||||
\endif
|
\endif
|
||||||
|
|
||||||
\li Locating QML methods (m)
|
\li Locating QML methods (\c {m})
|
||||||
|
|
||||||
\li Locating symbols in the current document (\c {.})
|
\li Locating symbols in the current document (\c {.})
|
||||||
|
|
||||||
|
@@ -39,8 +39,9 @@
|
|||||||
\list
|
\list
|
||||||
\li \l{Completing Code}{Code completion}
|
\li \l{Completing Code}{Code completion}
|
||||||
\li Highlighting the symbol under cursor
|
\li Highlighting the symbol under cursor
|
||||||
\li \l{Moving to Symbol Definition or Declaration}
|
\li Navigating in the code by using the \l{Searching with the Locator}
|
||||||
{Moving to the symbol definition}
|
{locator} or \l{Moving to Symbol Definition or Declaration}
|
||||||
|
{moving to the symbol definition}
|
||||||
\li Inspecting code by viewing the document
|
\li Inspecting code by viewing the document
|
||||||
\l{Viewing Defined Types and Symbols}{outline}
|
\l{Viewing Defined Types and Symbols}{outline}
|
||||||
\li \l{Finding Symbols}{Finding references to symbols}
|
\li \l{Finding Symbols}{Finding references to symbols}
|
||||||
@@ -53,6 +54,8 @@
|
|||||||
However, the experimental client does not support language servers that
|
However, the experimental client does not support language servers that
|
||||||
require special handling.
|
require special handling.
|
||||||
|
|
||||||
|
\section1 Adding MIME Types for Language Servers
|
||||||
|
|
||||||
\QC uses the \l{https://www.iana.org/assignments/media-types/media-types.xhtml}
|
\QC uses the \l{https://www.iana.org/assignments/media-types/media-types.xhtml}
|
||||||
{MIME type} of the file to determine which language server to request
|
{MIME type} of the file to determine which language server to request
|
||||||
information from when you open a file for editing. Add new MIME types or
|
information from when you open a file for editing. Add new MIME types or
|
||||||
@@ -62,16 +65,12 @@
|
|||||||
only sent to the languge server if they are known to be handled by it. For
|
only sent to the languge server if they are known to be handled by it. For
|
||||||
more information about how \QC uses MIME types, see \l {Editing MIME Types}.
|
more information about how \QC uses MIME types, see \l {Editing MIME Types}.
|
||||||
|
|
||||||
The experimental language service client has been mostly tested with Python.
|
\section1 Specifying Settings for Language Clients
|
||||||
If problems arise when you try some other language, please select
|
|
||||||
\uicontrol Help > \uicontrol {Report Bug} to report them in the Qt Bug
|
|
||||||
Tracker. The reports should include \QC console output with the environment
|
|
||||||
variable \c {QT_LOGGING_RULES=qtc.languageclient.*=true} set.
|
|
||||||
|
|
||||||
To use a language server:
|
To use a language server:
|
||||||
|
|
||||||
\list 1
|
\list 1
|
||||||
\li Enable the language server client by selecting \uicontrol Help >
|
\li Enable the language client by selecting \uicontrol Help >
|
||||||
\uicontrol {About Plugins} > \uicontrol {Other Languages} >
|
\uicontrol {About Plugins} > \uicontrol {Other Languages} >
|
||||||
\uicontrol {Language Client} (or \uicontrol {Qt Creator} >
|
\uicontrol {Language Client} (or \uicontrol {Qt Creator} >
|
||||||
\uicontrol {About Plugins} > \uicontrol {Other Languages} >
|
\uicontrol {About Plugins} > \uicontrol {Other Languages} >
|
||||||
@@ -86,15 +85,48 @@
|
|||||||
language server.
|
language server.
|
||||||
\li Select \uicontrol Add to add language servers.
|
\li Select \uicontrol Add to add language servers.
|
||||||
\li In the \uicontrol Name field, enter a name for the language server.
|
\li In the \uicontrol Name field, enter a name for the language server.
|
||||||
|
Select the \inlineimage replace.png
|
||||||
|
(\uicontrol {Variables}) button to use a variable for the server
|
||||||
|
name. For more information, see \l{Using Qt Creator Variables}.
|
||||||
\li In the \uicontrol {Language} field, select
|
\li In the \uicontrol {Language} field, select
|
||||||
\uicontrol {Set MIME Types} to select the MIME types of the files to
|
\uicontrol {Set MIME Types} to select the MIME types of the files to
|
||||||
send to the language server. In the field below, you can enter file
|
send to the language server. In the field below, you can enter file
|
||||||
patterns to extend the MIME types, separated by semicolons.
|
patterns to extend the MIME types, separated by semicolons.
|
||||||
|
\li In the \uicontrol {Startup behavior} field, select whether the
|
||||||
|
language server is started when \QC starts or when a project or file
|
||||||
|
with a matching MIME type is opened. The
|
||||||
|
\uicontrol {General Messages} \l{Viewing Output}{output pane}
|
||||||
|
displays information about the connection to the language server.
|
||||||
|
\li In the \uicontrol Capabilities field, you can see the features
|
||||||
|
that are supported by the language server. Only some of them are
|
||||||
|
implemented by \QC.
|
||||||
\li In the \uicontrol Executable field, enter the path to the language
|
\li In the \uicontrol Executable field, enter the path to the language
|
||||||
server executable.
|
server executable.
|
||||||
\li In the \uicontrol Arguments field, enter any required command line
|
\li In the \uicontrol Arguments field, enter any required command line
|
||||||
|
arguments. Select \uicontrol Variables to use variables as
|
||||||
arguments.
|
arguments.
|
||||||
\endlist
|
\endlist
|
||||||
|
|
||||||
To remove language servers from the list, select \uicontrol Delete.
|
To remove language servers from the list, select \uicontrol Delete.
|
||||||
|
|
||||||
|
\section1 Supported Locator Filters
|
||||||
|
|
||||||
|
The locator enables you to browse not only files, but any items defined by
|
||||||
|
\e {locator filters}. The language client plugin supports the following
|
||||||
|
locator filters:
|
||||||
|
|
||||||
|
\list
|
||||||
|
\li Locating symbols in the current project (\c {:})
|
||||||
|
\li Locating symbols in the current document (\c {.})
|
||||||
|
\li Locating class (\c {c}), enum, and function (\c {m})
|
||||||
|
definitions in your project
|
||||||
|
\endlist
|
||||||
|
|
||||||
|
\section1 Reporting Issues
|
||||||
|
|
||||||
|
The experimental language service client has been mostly tested with Python.
|
||||||
|
If problems arise when you try it or some other language, please select
|
||||||
|
\uicontrol Help > \uicontrol {Report Bug} to report them in the Qt Bug
|
||||||
|
Tracker. The reports should include \QC console output with the environment
|
||||||
|
variable \c {QT_LOGGING_RULES=qtc.languageclient.*=true} set.
|
||||||
*/
|
*/
|
||||||
|
Reference in New Issue
Block a user