Added memory capacity label to bottom bar in memory inspection pane

This commit is contained in:
Nav
2022-08-23 23:03:50 +01:00
parent e9f6c50f35
commit 7971ad2070
4 changed files with 30 additions and 1 deletions

View File

@@ -333,6 +333,10 @@ QScrollBar::sub-line:vertical {
max-width: 1px;
}
#target-memory-inspection-pane #memory-capacity-label {
color: #8a8a8d;
}
#hex-viewer-container #tool-bar,
#hex-viewer-container #search-bar {
border-bottom: 1px solid #41423f;

View File

@@ -75,6 +75,9 @@ namespace Bloom::Widgets
this->detachPaneButton = this->container->findChild<SvgToolButton*>("detach-pane-btn");
this->attachPaneButton = this->container->findChild<SvgToolButton*>("attach-pane-btn");
auto* memoryCapacityLabel = this->container->findChild<Label*>("memory-capacity-label");
memoryCapacityLabel->setText(QString::number(this->targetMemoryDescriptor.size()) + " Bytes");
this->hexViewerWidget = new HexViewerWidget(
this->targetMemoryDescriptor,
this->settings.hexViewerWidgetSettings,

View File

@@ -12,6 +12,7 @@
#include "src/Targets/TargetState.hpp"
#include "src/Insight/UserInterfaces/InsightWindow/Widgets/PanelWidget.hpp"
#include "src/Insight/UserInterfaces/InsightWindow/Widgets/SvgToolButton.hpp"
#include "src/Insight/UserInterfaces/InsightWindow/Widgets/Label.hpp"
#include "HexViewerWidget/HexViewerWidget.hpp"
#include "MemoryRegionManager/MemoryRegionManagerWindow.hpp"

View File

@@ -288,7 +288,28 @@
</property>
</spacer>
</item>
<!-- Button items here -->
<item>
<widget class="Label" name="memory-capacity-label">
<property name="toolTip">
<string>Memory Capacity</string>
</property>
</widget>
</item>
<item>
<spacer name="horizontal-spacer">
<property name="sizeHint">
<size>
<width>5</width>
</size>
</property>
<property name="sizeType">
<enum>QSizePolicy::Fixed</enum>
</property>
</spacer>
</item>
<item>
<widget class="QFrame" name="separator"/>
</item>
<item>
<spacer name="horizontal-spacer">
<property name="orientation">