forked from qt-creator/qt-creator
Doc: Describe changes in the diff editor
- Describe the context menu commands in the diff editor when used with Git - Make the description of colors less specific, because they depend on the theme - Use "chunk" consistently instead of "hunk" - Update the screenshot Change-Id: I6c9ec4eee8ff80f171558c930e5e448ac493f927 Reviewed-by: Jarek Kobus <jaroslaw.kobus@qt.io>
This commit is contained in:
Binary file not shown.
Before Width: | Height: | Size: 35 KiB After Width: | Height: | Size: 21 KiB |
@@ -1,6 +1,6 @@
|
||||
/****************************************************************************
|
||||
**
|
||||
** Copyright (C) 2018 The Qt Company Ltd.
|
||||
** Copyright (C) 2020 The Qt Company Ltd.
|
||||
** Contact: https://www.qt.io/licensing/
|
||||
**
|
||||
** This file is part of the Qt Creator documentation.
|
||||
@@ -80,11 +80,11 @@
|
||||
|
||||
\image creator-diff-editor.png "Diff editor output in the Edit mode"
|
||||
|
||||
The changes are displayed in the \uicontrol Edit mode. Color coding is used
|
||||
to mark changed lines. By default, light red indicates lines that contain
|
||||
removed text (painted a darker red) in the left pane and light green
|
||||
indicates lines that contain added text (painted a darker green) in the
|
||||
right pane.
|
||||
The changes are displayed in the \uicontrol Edit mode. Color coding is
|
||||
used to mark changed lines. By default, red indicates lines that contain
|
||||
removed text (painted another shade of red) in the left pane and green
|
||||
indicates lines that contain added text (painted another shade of green)
|
||||
in the right pane.
|
||||
|
||||
To revert the changes, right-click added text and then select
|
||||
\uicontrol {Revert Chunk} in the context menu. To apply the changes, select
|
||||
|
@@ -151,7 +151,8 @@
|
||||
instead, select the \uicontrol {Switch to Text Diff Editor} (1) option from
|
||||
the toolbar. In the inline
|
||||
diff view, you can use context menu commands to apply, revert, stage, and
|
||||
unstage hunks, as well as send them to a code pasting service.
|
||||
unstage chunks or selected lines, as well as send chunks to a code pasting
|
||||
service.
|
||||
|
||||
\section2 Viewing Versioning History and Change Details
|
||||
|
||||
|
@@ -89,7 +89,8 @@
|
||||
by default. To use the unified diff view instead, select the
|
||||
\uicontrol {Switch to Unified Diff Editor} (1) option from the toolbar.
|
||||
In both views, you can use context menu commands to apply, revert, stage,
|
||||
and unstage hunks, as well as send them to a code pasting service.
|
||||
and unstage chunks or selected lines, as well as send chunks to a code
|
||||
pasting service.
|
||||
|
||||
\section2 Viewing Git Log
|
||||
|
||||
@@ -186,11 +187,18 @@
|
||||
When you have finished filling out the commit page information, click on
|
||||
\uicontrol Commit to start committing.
|
||||
|
||||
The \uicontrol {Diff Selected Files} button brings up a diff view of the
|
||||
files selected in the file list. Since the commit page is just another
|
||||
editor, you can go back to it by closing the diff view. You can also switch
|
||||
to an open diff view by selecting it in the \uicontrol {Open Documents} view
|
||||
in the sidebar.
|
||||
The \uicontrol {Diff Selected Files} button opens a \l{Viewing Git Diff}
|
||||
{diff view} of the files selected in the file list. Select
|
||||
\uicontrol {Stage Chunk} in the context menu to stage a chunk or
|
||||
\uicontrol {Stage Selection} to stage the selected lines.
|
||||
|
||||
To unstage chunks or selected lines, select \uicontrol {Unstage Chunk} or
|
||||
\uicontrol {Unstage Selection} in the context menu. To revert the changes
|
||||
in a chunk, select \uicontrol {Revert Chunk}.
|
||||
|
||||
The commit page is just another editor, and therefore you return to it when
|
||||
you close the diff view. You can also switch to an open diff view by
|
||||
selecting it in the \uicontrol {Open Documents} view in the sidebar.
|
||||
|
||||
\section2 Amending Commits
|
||||
|
||||
|
Reference in New Issue
Block a user