|
| 1 | +--- |
| 2 | +title: "Comparison Pane" |
| 3 | +url: /refguide/comparison-pane/ |
| 4 | +weight: 25 |
| 5 | +description: "Describes the Comparison Pane in Mendix Studio Pro for comparing a revision to the current state of a version-controlled app." |
| 6 | +--- |
| 7 | + |
| 8 | +## Introduction |
| 9 | + |
| 10 | +The **Comparison** pane shows the differences between a selected historical revision and your current working state in a version-controlled app. This pane displays three levels of detail: which documents have changed, which elements within those documents have been altered, and which property values now differ. |
| 11 | + |
| 12 | +This feature requires a version-controlled app. For apps without version control, the **Comparison** pane is disabled. |
| 13 | + |
| 14 | +{{% alert color="warning" %}} |
| 15 | +You can only compare a selected historical revision to your current working state. It is not possible to compare two past revisions to each other. |
| 16 | +{{% /alert %}} |
| 17 | + |
| 18 | +This feature is similar to the [Changes pane](/refguide/changes-pane/), but while the **Changes** pane shows your local modifications since your last commit, the **Comparison** pane shows differences between any historical revision and your current state. |
| 19 | + |
| 20 | +For more information on comparing scenarios, refer to [Comparing Revisions](/refguide/comparing-revisions/). |
| 21 | + |
| 22 | +## Accessing the Comparison Pane and Version Compatibility |
| 23 | + |
| 24 | +To compare a revision to your current state, do the following: |
| 25 | + |
| 26 | +1. Open the **History** dialog by clicking **View** > **History**. |
| 27 | +2. Right-click a revision from the list. |
| 28 | +3. Select **Compare to current state**. |
| 29 | + |
| 30 | +The **Comparison** pane opens and shows all differences between the selected revision and your current working state, including any uncommitted changes. |
| 31 | + |
| 32 | +{{< figure src="/attachments/refguide/modeling/menus/view-menu/comparison-pane/history-right-click-menu.png" alt="Compare to current state option in History pane right-click menu" class="no-border" >}} |
| 33 | + |
| 34 | +{{% alert color="warning" %}} |
| 35 | +When comparing revisions created in older versions of Studio Pro, the models are automatically converted to the current Studio Pro version format. Due to this automatic conversion, the displayed older revision may not be 100% identical to the original model. This is a normal part of the version upgrade process and does not affect your actual stored revisions. |
| 36 | +{{% /alert %}} |
| 37 | + |
| 38 | +## Comparison Pane Overview |
| 39 | + |
| 40 | +The **Comparison** pane shows information at three levels: |
| 41 | + |
| 42 | +* **Level 1** – a list of all documents that differ between the two revisions |
| 43 | +* **Level 2** – all elements within a selected document that have changed |
| 44 | +* **Level 3** – the specific property values that differ for a selected element |
| 45 | + |
| 46 | +Navigate between levels by double-clicking a row or clicking **Go to**. Press <kbd>Backspace</kbd> or click **Back** to return to the previous level. |
| 47 | + |
| 48 | +### Unversioned App State |
| 49 | + |
| 50 | +If your app does not have version control enabled, all buttons in the **Comparison** pane are disabled and a message indicates that version control is required. |
| 51 | + |
| 52 | +### Level 1: Document List |
| 53 | + |
| 54 | +Level 1 displays all documents that differ between the selected revision and your current state. |
| 55 | + |
| 56 | +{{< figure src="/attachments/refguide/modeling/menus/view-menu/comparison-pane/comparison-pane-level1.png" alt="Comparison Pane Level 1 showing document list" class="no-border" >}} |
| 57 | + |
| 58 | +#### Task Bar |
| 59 | + |
| 60 | +The task bar contains the following buttons: |
| 61 | + |
| 62 | +| Button | Action | When Enabled | |
| 63 | +|--------|--------|--------------| |
| 64 | +| **Back** | Returns to the previous level | Always disabled at Level 1 (to prevent layout shift) | |
| 65 | +| **Go to** | Opens the selected document and navigates to Level 2 or 3 | Enabled when a document is selected | |
| 66 | +| **Stop comparison** | Closes the comparison and returns to the blank state | Always enabled during an active comparison | |
| 67 | + |
| 68 | +#### Context Menu |
| 69 | + |
| 70 | +Right-click any cell in the grid to access the **Copy** option, which copies the cell value to your clipboard. |
| 71 | + |
| 72 | +#### Grid Columns |
| 73 | + |
| 74 | +The document list grid contains the following columns: |
| 75 | + |
| 76 | +| Column | Description | Elements It Shows | |
| 77 | +|--------|-------------|---------------| |
| 78 | +| **Status** | The type of change | An icon and label indicating whether the document was **Added**, **Modified**, or **Deleted** | |
| 79 | +| **Item** | The document name | The name of the changed document (for example, a page, a microflow, or a domain model) | |
| 80 | +| **Module** | The module location | The module that contains the document | |
| 81 | + |
| 82 | +#### Status Types |
| 83 | + |
| 84 | +The **Status** column shows one of the following types: |
| 85 | + |
| 86 | +| Status | Icon | Meaning | When It Appears | |
| 87 | +|--------|------|---------|-----------------| |
| 88 | +| **Added** | Green circle | A new document was created | The document exists in the current state but not in the selected revision | |
| 89 | +| **Modified** | Yellow circle | Changes were made to an existing document | The document exists in both revisions but has differences | |
| 90 | +| **Deleted** | Red circle with minus | A document was removed | The document existed in the selected revision but not in the current state | |
| 91 | + |
| 92 | +## Level 2 and 3: Element and Property Differences |
| 93 | + |
| 94 | +Double-click a document in Level 1 to navigate to Level 2 and Level 3, which appear side by side. Level 2 shows changed elements, and Level 3 shows the property differences for the selected element. |
| 95 | + |
| 96 | +{{< figure src="/attachments/refguide/modeling/menus/view-menu/comparison-pane/comparison-pane-level2-3.png" alt="Comparison Pane Level 2 and Level 3 showing element and property differences" class="no-border" >}} |
| 97 | + |
| 98 | +### Task Bar |
| 99 | + |
| 100 | +The task bar at Level 2 and 3 contains the following buttons: |
| 101 | + |
| 102 | +| Button | Action | When Enabled | |
| 103 | +|--------|--------|--------------| |
| 104 | +| **Back** | Returns to Level 1 | Always enabled | |
| 105 | +| **Go to** | Focuses on the selected element in the document | Enabled when an element is selected; remains active even for deleted elements to support cross-tab navigation | |
| 106 | +| **Expand all** | Expands all collapsed property tree rows in Level 3 | Always enabled when viewing Level 3 | |
| 107 | +| **Collapse all** | Collapses all expanded property tree rows in Level 3 | Always enabled when viewing Level 3 | |
| 108 | +| **Stop comparison** | Closes the comparison and returns to the blank state | Always enabled during an active comparison | |
| 109 | + |
| 110 | +### Context Menu |
| 111 | + |
| 112 | +Right-click any cell in either the Level 2 or Level 3 grid to access the **Copy** option. |
| 113 | + |
| 114 | +### Level 2 Grid |
| 115 | + |
| 116 | +The Level 2 grid shows all changed elements within the selected document: |
| 117 | + |
| 118 | +| Column | Description | What It Shows | |
| 119 | +|--------|-------------|---------------| |
| 120 | +| **Status** | The type of change | An icon and label indicating whether the element was added, modified, or deleted | |
| 121 | +| **Item** | The element name | The name of the changed element (for example, a widget, entity, or activity) | |
| 122 | + |
| 123 | +Hover over any cell to see the full value in a tooltip. |
| 124 | + |
| 125 | +### Level 3 Grid |
| 126 | + |
| 127 | +The Level 3 grid shows the property-level differences for the element selected in Level 2: |
| 128 | + |
| 129 | +| Column | Description | What It Shows | |
| 130 | +|--------|-------------|---------------| |
| 131 | +| **Property** | The property name | The name of the property that changed, shown as a tree structure | |
| 132 | +| **Older** | The value in the selected revision | The property value as it was in the historical revision | |
| 133 | +| **Newer** | The value in the current state | The property value as it is in your current working state | |
| 134 | + |
| 135 | +Property paths are consolidated into a tree view. Grey rows represent intermediate path levels that do not have a direct value. The row order reflects the top-to-bottom, left-to-right order that the corresponding components appear in their dialog boxes. |
| 136 | + |
| 137 | +## Opening Documents |
| 138 | + |
| 139 | +When you click **Go to** or double-click a document entry in Level 1, the document opens as it currently exists in your app. If the document no longer exists in your current state, Level 2 and 3 is shown but nothing opens in the editor. |
| 140 | + |
| 141 | +{{% alert color="info" %}} |
| 142 | +In future releases, both versions of the document will be opened side by side for visual comparison. For now, only the current version opens. |
| 143 | +{{% /alert %}} |
| 144 | + |
| 145 | +## Refresh Behavior |
| 146 | + |
| 147 | +When you are comparing a revision to your current state and save changes to your app, a **Refresh** button appears in the **Comparison** pane. Click **Refresh** to update the comparison with your latest saved changes. |
| 148 | + |
| 149 | +## Stopping a Comparison |
| 150 | + |
| 151 | +Click **Stop comparison** to close the comparison. This action closes the **Comparison** pane and returns it to a blank state. Any documents that were opened as part of the comparison remain open in the editor. |
| 152 | + |
| 153 | +In the blank state, the **Comparison** pane displays a message with a link to start a new comparison. The **Go to** and **Stop comparison** buttons are disabled until a new comparison is started. |
| 154 | + |
| 155 | +## Read More |
| 156 | + |
| 157 | +* [History](/refguide/history-dialog/) |
| 158 | +* [Changes Pane](/refguide/changes-pane/) |
| 159 | +* [Comparing Revisions](/refguide/comparing-revisions/) |
| 160 | +* [Version Control](/refguide/version-control/) |
0 commit comments