Add support for finding and opening any event script

This commit is contained in:
BigBahss
2020-12-04 09:29:38 -05:00
parent afc0c0c501
commit 7a4de9f3d9
11 changed files with 86 additions and 20 deletions

View File

@@ -76,7 +76,7 @@
<item row="6" column="0" colspan="2">
<widget class="QLabel" name="label_TextEditorGotoLineHelp">
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;This is the command that will be executed when clicking the &lt;span style=&quot; font-weight:600;&quot;&gt;Open Map Scripts&lt;/span&gt; button&lt;span style=&quot; font-weight:600;&quot;&gt;. %F&lt;/span&gt; will be substituted with the scripts file path and &lt;span style=&quot; font-weight:600;&quot;&gt;%L&lt;/span&gt; will be substituted with the line number of the script for the currently selected event. &lt;span style=&quot; font-weight:600;&quot;&gt;%F &lt;/span&gt;&lt;span style=&quot; font-style:italic;&quot;&gt;must&lt;/span&gt; be specified if &lt;span style=&quot; font-weight:600;&quot;&gt;%L&lt;/span&gt; is specified. If &lt;span style=&quot; font-weight:600;&quot;&gt;%F&lt;/span&gt; is &lt;span style=&quot; font-style:italic;&quot;&gt;not&lt;/span&gt; specified then the scripts file path will be appended to the end of the command.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt;When this command is set a button will appear next to the &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600; font-style:italic;&quot;&gt;Script&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; combo-box in the &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600; font-style:italic;&quot;&gt;Events&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; tab which executes this command.&lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600;&quot;&gt; %F&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; will be substituted with the file path of the script and &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600;&quot;&gt;%L&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; will be substituted with the line number of the script in that file. &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600;&quot;&gt;%F &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-style:italic;&quot;&gt;must&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; be given if &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600;&quot;&gt;%L&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; is given. If &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600;&quot;&gt;%F&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; is &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-style:italic;&quot;&gt;not&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; given then the script's file path will be added to the end of the command. If the script can't be found then the current map's scripts file is opened.&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
@@ -109,7 +109,7 @@
<item row="1" column="0" colspan="2">
<widget class="QLabel" name="label_TextEditorOpenFolderHelp">
<property name="text">
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;This is the command that will be executed when clicking &lt;span style=&quot; font-weight:600;&quot;&gt;Open Project in Text Editor&lt;/span&gt; in the &lt;span style=&quot; font-weight:600;&quot;&gt;Tools&lt;/span&gt; menu. &lt;span style=&quot; font-weight:600;&quot;&gt;%D&lt;/span&gt; will be substituted with the current project's root directory. If &lt;span style=&quot; font-weight:600;&quot;&gt;%D&lt;/span&gt; is &lt;span style=&quot; font-style:italic;&quot;&gt;not&lt;/span&gt; specified then the project directory will be appended to the end of the command.&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
<string>&lt;html&gt;&lt;head/&gt;&lt;body&gt;&lt;p&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt;This is the command that is executed when clicking &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600; font-style:italic;&quot;&gt;Open Project in Text Editor&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; in the &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600; font-style:italic;&quot;&gt;Tools&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; menu. &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600;&quot;&gt;%D&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; will be substituted with the project's root directory. If &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-weight:600;&quot;&gt;%D&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; is &lt;/span&gt;&lt;span style=&quot; font-size:11pt; font-style:italic;&quot;&gt;not&lt;/span&gt;&lt;span style=&quot; font-size:11pt;&quot;&gt; specified then the project directory will be added to the end of the command.&lt;/span&gt;&lt;/p&gt;&lt;/body&gt;&lt;/html&gt;</string>
</property>
<property name="alignment">
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>