Files
renderdoc/qrenderdoc/Windows/ShaderViewer.ui
T
William Pearson d150d8f2b7 Use instant popup for shader execute forwards/backwards buttons
There is no action associated with clicking the button itself, only for
the menu associated with it. Using QToolButton::MenuButtonPopup means
that the majority of the button is for the button's own action, and
there is a small arrow next to the button that shows the menu. Since
there's no action, this means that the small menu arrow needs to be
clicked each time instead of the big button, which is annoying.
QToolButton::InstantPopup instead always shows the menu (though it
doesn't have the arrow indicating a menu exists, although this is not
particularly important).

InstantPopup is also already used for the "Insert" button used when
editing a custom shader for the texture viewer. MenuButtonPopup is used
in many other places throughout RenderDoc, but they are all save or
export buttons where there is a meaningful default action.
2023-04-14 19:04:15 +01:00

794 lines
21 KiB
XML

<?xml version="1.0" encoding="UTF-8"?>
<ui version="4.0">
<class>ShaderViewer</class>
<widget class="QFrame" name="ShaderViewer">
<property name="geometry">
<rect>
<x>0</x>
<y>0</y>
<width>963</width>
<height>746</height>
</rect>
</property>
<property name="windowTitle">
<string>Form</string>
</property>
<widget class="ToolWindowManager" name="docking" native="true">
<property name="geometry">
<rect>
<x>80</x>
<y>90</y>
<width>351</width>
<height>301</height>
</rect>
</property>
</widget>
<widget class="RDTreeWidget" name="inputSig">
<property name="geometry">
<rect>
<x>570</x>
<y>160</y>
<width>256</width>
<height>192</height>
</rect>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="editTriggers">
<set>QAbstractItemView::NoEditTriggers</set>
</property>
<property name="showDropIndicator" stdset="0">
<bool>false</bool>
</property>
<property name="dragDropOverwriteMode">
<bool>false</bool>
</property>
<property name="indentation">
<number>0</number>
</property>
<property name="rootIsDecorated">
<bool>false</bool>
</property>
<property name="itemsExpandable">
<bool>false</bool>
</property>
<property name="allColumnsShowFocus">
<bool>true</bool>
</property>
<property name="cornerButtonEnabled" stdset="0">
<bool>false</bool>
</property>
</widget>
<widget class="RDTreeWidget" name="outputSig">
<property name="geometry">
<rect>
<x>590</x>
<y>360</y>
<width>256</width>
<height>192</height>
</rect>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="editTriggers">
<set>QAbstractItemView::NoEditTriggers</set>
</property>
<property name="showDropIndicator" stdset="0">
<bool>false</bool>
</property>
<property name="dragDropOverwriteMode">
<bool>false</bool>
</property>
<property name="indentation">
<number>0</number>
</property>
<property name="rootIsDecorated">
<bool>false</bool>
</property>
<property name="itemsExpandable">
<bool>false</bool>
</property>
<property name="allColumnsShowFocus">
<bool>true</bool>
</property>
<property name="cornerButtonEnabled" stdset="0">
<bool>false</bool>
</property>
</widget>
<widget class="RDTreeWidget" name="constants">
<property name="geometry">
<rect>
<x>20</x>
<y>310</y>
<width>256</width>
<height>192</height>
</rect>
</property>
<property name="contextMenuPolicy">
<enum>Qt::PreventContextMenu</enum>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="allColumnsShowFocus">
<bool>true</bool>
</property>
</widget>
<widget class="QFrame" name="resourcesPanel">
<property name="geometry">
<rect>
<x>20</x>
<y>310</y>
<width>256</width>
<height>192</height>
</rect>
</property>
<property name="contextMenuPolicy">
<enum>Qt::PreventContextMenu</enum>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<layout class="QVBoxLayout" name="verticalLayout">
<property name="spacing">
<number>2</number>
</property>
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="RDTreeWidget" name="accessedResources">
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="allColumnsShowFocus">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QFrame" name="sortGroup">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="contextMenuPolicy">
<enum>Qt::PreventContextMenu</enum>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_6">
<property name="leftMargin">
<number>0</number>
</property>
<property name="topMargin">
<number>0</number>
</property>
<property name="rightMargin">
<number>0</number>
</property>
<property name="bottomMargin">
<number>0</number>
</property>
<item>
<widget class="QToolButton" name="resources_sortByResource">
<property name="toolTip">
<string>Sort accessed resource by shader binding</string>
</property>
<property name="text">
<string>Sort By Resource</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>true</bool>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="resources_sortByStep">
<property name="toolTip">
<string>Sort accessed resource by instruction step</string>
</property>
<property name="text">
<string>Sort By Instruction</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>false</bool>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<spacer name="resources_horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</item>
</layout>
</widget>
<widget class="RDTreeWidget" name="debugVars">
<property name="geometry">
<rect>
<x>310</x>
<y>310</y>
<width>256</width>
<height>192</height>
</rect>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="allColumnsShowFocus">
<bool>true</bool>
</property>
</widget>
<widget class="QFrame" name="toolbar">
<property name="geometry">
<rect>
<x>20</x>
<y>10</y>
<width>1132</width>
<height>28</height>
</rect>
</property>
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>28</height>
</size>
</property>
<property name="frameShape">
<enum>QFrame::Panel</enum>
</property>
<property name="frameShadow">
<enum>QFrame::Raised</enum>
</property>
<layout class="QHBoxLayout" name="horizontalLayout_5">
<property name="spacing">
<number>2</number>
</property>
<property name="leftMargin">
<number>6</number>
</property>
<property name="topMargin">
<number>2</number>
</property>
<property name="rightMargin">
<number>6</number>
</property>
<property name="bottomMargin">
<number>2</number>
</property>
<item>
<widget class="QToolButton" name="findReplace">
<property name="toolTip">
<string>Find &amp; Replace</string>
</property>
<property name="text">
<string>Find</string>
</property>
<property name="icon">
<iconset resource="../Resources/resources.qrc">
<normaloff>:/find.png</normaloff>:/find.png</iconset>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextBesideIcon</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="Line" name="line">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="resetEdits">
<property name="toolTip">
<string>Remove all source edits and restore original shader</string>
</property>
<property name="text">
<string>Reset</string>
</property>
<property name="icon">
<iconset resource="../Resources/resources.qrc">
<normaloff>:/del.png</normaloff>:/del.png</iconset>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextBesideIcon</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="refresh">
<property name="toolTip">
<string>Compile shader &amp; apply changes</string>
</property>
<property name="text">
<string>Apply changes</string>
</property>
<property name="icon">
<iconset resource="../Resources/resources.qrc">
<normaloff>:/arrow_refresh.png</normaloff>:/arrow_refresh.png</iconset>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextBesideIcon</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="unrefresh">
<property name="toolTip">
<string>Use original shader</string>
</property>
<property name="text">
<string>Remove changes</string>
</property>
<property name="icon">
<iconset resource="../Resources/resources.qrc">
<normaloff>:/arrow_undo.png</normaloff>:/arrow_undo.png</iconset>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextBesideIcon</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QLabel" name="editStatusLabel">
<property name="toolTip">
<string>The replay currently has the original shader active</string>
</property>
<property name="text">
<string>Status: Original Shader Active</string>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="snippets">
<property name="toolTip">
<string>Insert built-in snippets</string>
</property>
<property name="text">
<string>Insert...</string>
</property>
<property name="icon">
<iconset resource="../Resources/resources.qrc">
<normaloff>:/plugin_add.png</normaloff>:/plugin_add.png</iconset>
</property>
<property name="popupMode">
<enum>QToolButton::InstantPopup</enum>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextBesideIcon</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="Line" name="editSep">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="execBackwards">
<property name="toolTip">
<string>Run or step backwards in execution</string>
</property>
<property name="text">
<string>Execute backwards...</string>
</property>
<property name="icon">
<iconset resource="../Resources/resources.qrc">
<normaloff>:/control_reverse_blue@2x.png</normaloff>:/control_reverse_blue@2x.png</iconset>
</property>
<property name="popupMode">
<enum>QToolButton::InstantPopup</enum>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextBesideIcon</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="execForwards">
<property name="toolTip">
<string>Run or step forwards in execution</string>
</property>
<property name="text">
<string>Execute forwards...</string>
</property>
<property name="icon">
<iconset resource="../Resources/resources.qrc">
<normaloff>:/control_play_blue.png</normaloff>:/control_play_blue.png</iconset>
</property>
<property name="popupMode">
<enum>QToolButton::InstantPopup</enum>
</property>
<property name="toolButtonStyle">
<enum>Qt::ToolButtonTextBesideIcon</enum>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="Line" name="regFormatSep">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="intView">
<property name="text">
<string>int</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>false</bool>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="floatView">
<property name="text">
<string>float</string>
</property>
<property name="checkable">
<bool>true</bool>
</property>
<property name="checked">
<bool>true</bool>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<widget class="Line" name="debugToggleSep">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
</widget>
</item>
<item>
<widget class="QToolButton" name="debugToggle">
<property name="minimumSize">
<size>
<width>23</width>
<height>22</height>
</size>
</property>
<property name="toolTip">
<string>Change the debugging view</string>
</property>
<property name="text">
<string notr="true">Debug Toggle</string>
</property>
<property name="autoRaise">
<bool>true</bool>
</property>
</widget>
</item>
<item>
<spacer name="horizontalSpacer">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
<widget class="RDTreeWidget" name="watch">
<property name="geometry">
<rect>
<x>520</x>
<y>60</y>
<width>421</width>
<height>131</height>
</rect>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="editTriggers">
<set>QAbstractItemView::AnyKeyPressed|QAbstractItemView::DoubleClicked|QAbstractItemView::EditKeyPressed|QAbstractItemView::SelectedClicked</set>
</property>
<property name="selectionMode">
<enum>QAbstractItemView::SingleSelection</enum>
</property>
<property name="selectionBehavior">
<enum>QAbstractItemView::SelectRows</enum>
</property>
<property name="wordWrap">
<bool>false</bool>
</property>
<attribute name="horizontalHeaderHighlightSections">
<bool>false</bool>
</attribute>
<attribute name="horizontalHeaderStretchLastSection">
<bool>true</bool>
</attribute>
<attribute name="verticalHeaderVisible">
<bool>false</bool>
</attribute>
<column>
<property name="text">
<string>Name</string>
</property>
</column>
<column>
<property name="text">
<string>Register(s)</string>
</property>
</column>
<column>
<property name="text">
<string>Type</string>
</property>
</column>
<column>
<property name="text">
<string>Value</string>
</property>
</column>
</widget>
<widget class="QListWidget" name="callstack">
<property name="geometry">
<rect>
<x>20</x>
<y>80</y>
<width>256</width>
<height>192</height>
</rect>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="selectionMode">
<enum>QAbstractItemView::NoSelection</enum>
</property>
</widget>
<widget class="RDTreeWidget" name="sourceVars">
<property name="geometry">
<rect>
<x>290</x>
<y>90</y>
<width>256</width>
<height>192</height>
</rect>
</property>
<property name="frameShape">
<enum>QFrame::NoFrame</enum>
</property>
<property name="allColumnsShowFocus">
<bool>true</bool>
</property>
</widget>
<widget class="QWidget" name="compilationGroup" native="true">
<property name="geometry">
<rect>
<x>60</x>
<y>560</y>
<width>441</width>
<height>141</height>
</rect>
</property>
<layout class="QGridLayout" name="gridLayout">
<item row="0" column="0">
<widget class="QLabel" name="label">
<property name="text">
<string>Entry Point:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="0" column="1">
<widget class="QLineEdit" name="entryFunc">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
</widget>
</item>
<item row="0" column="2">
<widget class="QLabel" name="label_4">
<property name="text">
<string>Source Type:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="0" column="3">
<widget class="QComboBox" name="encoding">
<property name="minimumSize">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
<property name="insertPolicy">
<enum>QComboBox::NoInsert</enum>
</property>
<property name="sizeAdjustPolicy">
<enum>QComboBox::AdjustToContents</enum>
</property>
</widget>
</item>
<item row="0" column="4">
<spacer name="horizontalSpacer_2">
<property name="orientation">
<enum>Qt::Horizontal</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>40</width>
<height>20</height>
</size>
</property>
</spacer>
</item>
<item row="1" column="0">
<widget class="QLabel" name="label_3">
<property name="text">
<string>Compiler:</string>
</property>
<property name="alignment">
<set>Qt::AlignRight|Qt::AlignTrailing|Qt::AlignVCenter</set>
</property>
</widget>
</item>
<item row="1" column="1">
<widget class="QComboBox" name="compileTool">
<property name="sizePolicy">
<sizepolicy hsizetype="Minimum" vsizetype="Fixed">
<horstretch>0</horstretch>
<verstretch>0</verstretch>
</sizepolicy>
</property>
<property name="minimumSize">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
<property name="insertPolicy">
<enum>QComboBox::NoInsert</enum>
</property>
<property name="sizeAdjustPolicy">
<enum>QComboBox::AdjustToContents</enum>
</property>
</widget>
</item>
<item row="1" column="2" rowspan="2" colspan="3">
<widget class="QTextEdit" name="toolCommandLine">
<property name="minimumSize">
<size>
<width>0</width>
<height>20</height>
</size>
</property>
<property name="acceptRichText">
<bool>false</bool>
</property>
</widget>
</item>
<item row="2" column="1">
<spacer name="verticalSpacer">
<property name="orientation">
<enum>Qt::Vertical</enum>
</property>
<property name="sizeHint" stdset="0">
<size>
<width>20</width>
<height>40</height>
</size>
</property>
</spacer>
</item>
</layout>
</widget>
</widget>
<customwidgets>
<customwidget>
<class>RDTreeWidget</class>
<extends>QTreeView</extends>
<header>Widgets/Extended/RDTreeWidget.h</header>
</customwidget>
<customwidget>
<class>ToolWindowManager</class>
<extends>QWidget</extends>
<header>3rdparty/toolwindowmanager/ToolWindowManager.h</header>
</customwidget>
</customwidgets>
<resources>
<include location="../Resources/resources.qrc"/>
</resources>
<connections/>
</ui>