<?xml version="1.0" encoding="UTF-8"?><rss version="2.0"
	xmlns:content="http://purl.org/rss/1.0/modules/content/"
	xmlns:dc="http://purl.org/dc/elements/1.1/"
	xmlns:atom="http://www.w3.org/2005/Atom"
	xmlns:sy="http://purl.org/rss/1.0/modules/syndication/"
	
	>
<channel>
	<title>
	Comments on: Matlab toolstrip – part 3 (basic customization)	</title>
	<atom:link href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization/feed" rel="self" type="application/rss+xml" />
	<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=matlab-toolstrip-part-3-basic-customization</link>
	<description>Professional Matlab consulting, development and training</description>
	<lastBuildDate>Sun, 16 Jun 2019 15:26:19 +0000</lastBuildDate>
	<sy:updatePeriod>
	hourly	</sy:updatePeriod>
	<sy:updateFrequency>
	1	</sy:updateFrequency>
	<generator>https://wordpress.org/?v=6.7.2</generator>
	<item>
		<title>
		By: Yair Altman		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-483100</link>

		<dc:creator><![CDATA[Yair Altman]]></dc:creator>
		<pubDate>Sun, 16 Jun 2019 15:26:19 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-483100</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-473870&quot;&gt;Endri K.&lt;/a&gt;.

Unfortunately, docking figures into ToolGroups is for some unknown reason (apparently deliberately) prevented by the Matlab Compiler. I am not aware of any workaround for this, at the moment.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-473870">Endri K.</a>.</p>
<p>Unfortunately, docking figures into ToolGroups is for some unknown reason (apparently deliberately) prevented by the Matlab Compiler. I am not aware of any workaround for this, at the moment.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Endri K.		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-473870</link>

		<dc:creator><![CDATA[Endri K.]]></dc:creator>
		<pubDate>Tue, 09 Apr 2019 21:36:24 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-473870</guid>

					<description><![CDATA[Hi Yair,

Thank you for all your great posts. They&#039;re all extremely helpful. Could you please help me with an issue I&#039;m facing? I&#039;ve built an application with a ToolGroup and when using the Matlab Application Compiler, in the compiled standalone version, I cannot get hToolGroup.addFigure to dock a new figure in the existing ToolGroup window. I have tried a number of approaches and have been unsuccessful. For this application I am currently using Matlab 2017b.

Thank you,
Endri]]></description>
			<content:encoded><![CDATA[<p>Hi Yair,</p>
<p>Thank you for all your great posts. They&#8217;re all extremely helpful. Could you please help me with an issue I&#8217;m facing? I&#8217;ve built an application with a ToolGroup and when using the Matlab Application Compiler, in the compiled standalone version, I cannot get hToolGroup.addFigure to dock a new figure in the existing ToolGroup window. I have tried a number of approaches and have been unsuccessful. For this application I am currently using Matlab 2017b.</p>
<p>Thank you,<br />
Endri</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Yair Altman		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-470505</link>

		<dc:creator><![CDATA[Yair Altman]]></dc:creator>
		<pubDate>Tue, 26 Mar 2019 22:14:41 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-470505</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-470500&quot;&gt;Arash Marashian&lt;/a&gt;.

@Arash - the &quot;handles&quot; that you refer to is a simple Matlab struct that contains the GUI handles in separate fields. You can easily create it in your code by assigning each created GUI object (tab, section, column, button etc.) a separate field in the struct, and in the end saving this struct somewhere. You cannot use &lt;i&gt;&lt;b&gt;guidata&lt;/b&gt;&lt;/i&gt; or &lt;i&gt;&lt;b&gt;guihandles&lt;/b&gt;&lt;/i&gt; because they only work with figures (not apps), but you can store the handles struct elsewhere e.g. in a global variable, or attached to one of the figures that you dock into your app.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-470500">Arash Marashian</a>.</p>
<p>@Arash &#8211; the &#8220;handles&#8221; that you refer to is a simple Matlab struct that contains the GUI handles in separate fields. You can easily create it in your code by assigning each created GUI object (tab, section, column, button etc.) a separate field in the struct, and in the end saving this struct somewhere. You cannot use <i><b>guidata</b></i> or <i><b>guihandles</b></i> because they only work with figures (not apps), but you can store the handles struct elsewhere e.g. in a global variable, or attached to one of the figures that you dock into your app.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Arash Marashian		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-470500</link>

		<dc:creator><![CDATA[Arash Marashian]]></dc:creator>
		<pubDate>Tue, 26 Mar 2019 22:04:06 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-470500</guid>

					<description><![CDATA[Hi, I have a question, can I use something like &quot;handles&quot;, that we have in GUI?]]></description>
			<content:encoded><![CDATA[<p>Hi, I have a question, can I use something like &#8220;handles&#8221;, that we have in GUI?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Chen Wang		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457531</link>

		<dc:creator><![CDATA[Chen Wang]]></dc:creator>
		<pubDate>Wed, 16 Jan 2019 08:57:05 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-457531</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457512&quot;&gt;Collin Pecora&lt;/a&gt;.

Thx so much, Collin.
This works :D]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457512">Collin Pecora</a>.</p>
<p>Thx so much, Collin.<br />
This works 😀</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Collin Pecora		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457512</link>

		<dc:creator><![CDATA[Collin Pecora]]></dc:creator>
		<pubDate>Wed, 16 Jan 2019 00:50:29 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-457512</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457472&quot;&gt;Chen Wang&lt;/a&gt;.

Chen

I don&#039;t believe the R2016b version has any methods to set position 

You can do it through the desktop:
&lt;pre lang=&quot;matlab&quot;&gt;
jDesktop = com.mathworks.mlservices.MatlabDesktopServices.getDesktop;
jPos = com.mathworks.widgets.desk.DTLocation.createExternal(uint16(100), uint16(200), uint16(300), uint16(400));
jDesktop.setGroupLocation(&#039;A Test&#039;, jPos);
&lt;/pre&gt;

Collin]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457472">Chen Wang</a>.</p>
<p>Chen</p>
<p>I don&#8217;t believe the R2016b version has any methods to set position </p>
<p>You can do it through the desktop:</p>
<pre lang="matlab">
jDesktop = com.mathworks.mlservices.MatlabDesktopServices.getDesktop;
jPos = com.mathworks.widgets.desk.DTLocation.createExternal(uint16(100), uint16(200), uint16(300), uint16(400));
jDesktop.setGroupLocation('A Test', jPos);
</pre>
<p>Collin</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Chen Wang		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457472</link>

		<dc:creator><![CDATA[Chen Wang]]></dc:creator>
		<pubDate>Tue, 15 Jan 2019 15:12:24 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-457472</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457453&quot;&gt;Yair Altman&lt;/a&gt;.

Thx a lot.
i think, it is probably impossible in 16b to set an opening size. i haven&#039;t found any available function :( 
but this is not that bad, in 16b the most new futures of toolgroup still work and till now they are enough for me. 

Thx u again for ur post :)]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457453">Yair Altman</a>.</p>
<p>Thx a lot.<br />
i think, it is probably impossible in 16b to set an opening size. i haven&#8217;t found any available function 🙁<br />
but this is not that bad, in 16b the most new futures of toolgroup still work and till now they are enough for me. </p>
<p>Thx u again for ur post 🙂</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Yair Altman		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457453</link>

		<dc:creator><![CDATA[Yair Altman]]></dc:creator>
		<pubDate>Tue, 15 Jan 2019 08:30:57 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-457453</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457451&quot;&gt;Chen Wang&lt;/a&gt;.

@Chen - 16b is a relatively old release (19a is 5 releases ahead). It is quite possible that the &lt;i&gt;setPosition&lt;/i&gt; method was added in one of these later releases. I have not investigated this but it&#039;s possible that there may have been an alternative method in 16b (e.g. &lt;i&gt;setLocation&lt;/i&gt; or whatever). You can run &lt;code&gt;methodview(hTG)&lt;/code&gt; to check the possibilities, or upgrade to a later Matlab release.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457451">Chen Wang</a>.</p>
<p>@Chen &#8211; 16b is a relatively old release (19a is 5 releases ahead). It is quite possible that the <i>setPosition</i> method was added in one of these later releases. I have not investigated this but it&#8217;s possible that there may have been an alternative method in 16b (e.g. <i>setLocation</i> or whatever). You can run <code>methodview(hTG)</code> to check the possibilities, or upgrade to a later Matlab release.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Chen Wang		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457451</link>

		<dc:creator><![CDATA[Chen Wang]]></dc:creator>
		<pubDate>Tue, 15 Jan 2019 07:59:43 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-457451</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457416&quot;&gt;Yair Altman&lt;/a&gt;.

Hi Yair, 
thx for your answer :)
i have tried with your suggestion:
&lt;pre lang=&#039;matlab&#039;&gt;
hTG = matlab.ui.internal.desktop.ToolGroup(&#039;A Test&#039;);
hTG.open();
hTG.disableDataBrowser();
jTG = hTG.Peer;
jPos = com.mathworks.widgets.desk.DTLocation.createExternal(uint16(100), uint16(200), uint16(300), uint16(400));
jTG.setPosition(jPos);
&lt;/pre&gt;

but i got error:
&lt;pre lang=&#039;matlab&#039;&gt;
Undefined function or variable &#039;setPosition&#039;.
&lt;/pre&gt;

PS: i&#039;m using Matlab 2016b.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457416">Yair Altman</a>.</p>
<p>Hi Yair,<br />
thx for your answer 🙂<br />
i have tried with your suggestion:</p>
<pre lang='matlab'>
hTG = matlab.ui.internal.desktop.ToolGroup('A Test');
hTG.open();
hTG.disableDataBrowser();
jTG = hTG.Peer;
jPos = com.mathworks.widgets.desk.DTLocation.createExternal(uint16(100), uint16(200), uint16(300), uint16(400));
jTG.setPosition(jPos);
</pre>
<p>but i got error:</p>
<pre lang='matlab'>
Undefined function or variable 'setPosition'.
</pre>
<p>PS: i&#8217;m using Matlab 2016b.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Yair Altman		</title>
		<link>https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457416</link>

		<dc:creator><![CDATA[Yair Altman]]></dc:creator>
		<pubDate>Mon, 14 Jan 2019 15:43:14 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=8077#comment-457416</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457415&quot;&gt;chen wang&lt;/a&gt;.

@Chen - I will discuss positioning and layout in a future post, but for now you can adapt the following script. Note that the positioning uses Java-based coordinates, which is (0,0) at the &lt;b&gt;top-left&lt;/b&gt; corner of the screen, and &lt;b&gt;increases downward and to the right&lt;/b&gt;, and the position is for the tool-group&#039;s &lt;b&gt;top-left&lt;/b&gt; corner. So, position (100,200,800,600) means a 800x600 window whose top-left corner is 100 pixels to the right, and 200 pixels below, the screen&#039;s top-left corner.

&lt;pre lang=&quot;matlab&quot;&gt;
% Alternative #1:
hToolGroup = matlab.ui.internal.desktop.ToolGroup();
hToolGroup.setPosition(100, 200, 800, 600);  % x,y,width,height

% Alternative #2:
jToolGroup = hToolGroup.Peer;
jPosition = com.mathworks.widgets.desk.DTLocation.createExternal(uint16(100),uint16(200),uint16(800),uint16(600));
jToolGroup.setPosition(jPosition);
&lt;/pre&gt;]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/matlab-toolstrip-part-3-basic-customization#comment-457415">chen wang</a>.</p>
<p>@Chen &#8211; I will discuss positioning and layout in a future post, but for now you can adapt the following script. Note that the positioning uses Java-based coordinates, which is (0,0) at the <b>top-left</b> corner of the screen, and <b>increases downward and to the right</b>, and the position is for the tool-group&#8217;s <b>top-left</b> corner. So, position (100,200,800,600) means a 800&#215;600 window whose top-left corner is 100 pixels to the right, and 200 pixels below, the screen&#8217;s top-left corner.</p>
<pre lang="matlab">
% Alternative #1:
hToolGroup = matlab.ui.internal.desktop.ToolGroup();
hToolGroup.setPosition(100, 200, 800, 600);  % x,y,width,height

% Alternative #2:
jToolGroup = hToolGroup.Peer;
jPosition = com.mathworks.widgets.desk.DTLocation.createExternal(uint16(100),uint16(200),uint16(800),uint16(600));
jToolGroup.setPosition(jPosition);
</pre>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
