<?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: Another Command Window text color hack	</title>
	<atom:link href="https://undocumentedmatlab.com/articles/another-command-window-text-color-hack/feed" rel="self" type="application/rss+xml" />
	<link>https://undocumentedmatlab.com/articles/another-command-window-text-color-hack?utm_source=rss&#038;utm_medium=rss&#038;utm_campaign=another-command-window-text-color-hack</link>
	<description>Professional Matlab consulting, development and training</description>
	<lastBuildDate>Tue, 14 Jun 2016 09:14:47 +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/another-command-window-text-color-hack#comment-380319</link>

		<dc:creator><![CDATA[Yair Altman]]></dc:creator>
		<pubDate>Tue, 14 Jun 2016 09:14:47 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=4358#comment-380319</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-380225&quot;&gt;Andriy&lt;/a&gt;.

@Andriy - When you run Matlab with &lt;code&gt;-desktop&lt;/code&gt;, you see a native (not Java) command window console, and this console does not interpret the \b as a valid control character. \t is much more widely accepted than \b, so this is not surprising. I think it&#039;s also not recognized in Windows DOS consoles. If you want to use a lightweight Matlab console, this naturally has a much more limited feature set.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-380225">Andriy</a>.</p>
<p>@Andriy &#8211; When you run Matlab with <code>-desktop</code>, you see a native (not Java) command window console, and this console does not interpret the \b as a valid control character. \t is much more widely accepted than \b, so this is not surprising. I think it&#8217;s also not recognized in Windows DOS consoles. If you want to use a lightweight Matlab console, this naturally has a much more limited feature set.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Andriy		</title>
		<link>https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-380225</link>

		<dc:creator><![CDATA[Andriy]]></dc:creator>
		<pubDate>Mon, 13 Jun 2016 14:10:01 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=4358#comment-380225</guid>

					<description><![CDATA[Hello Yair,

Perhaps, my comment does not completely matches topic of this post, but it might be interested to those who runs MATLAB with &lt;b&gt;-nodesktop&lt;/b&gt; option. In this case MATLAB handles backspace characters in even more unusual way. Just try to rung the following commands in command prompt:

&lt;pre lang=&quot;matlab&quot;&gt;
for k=0:10, fprintf(&#039;abcd&#039;); fprintf([&#039;12345&#039;,repmat(&#039;\b&#039;,1,k),&#039;67890\n&#039;]); end;
for k=0:10, fprintf(&#039;abcd&#039;); fprintf([&#039;12345&#039;,repmat(&#039;\t&#039;,1,k),&#039;67890\n&#039;]); end;
 
&lt;/pre&gt;

Here (https://i.imgsafe.org/ebccebb279.png) is what I see in &quot;-nodesktop&quot; mode in R2015b.
Tabs are handled properly while back-spaces can not erase text printed by previous fprintf command and produce weird results.

Do you have any ideas how to send &quot;\b&quot; character properly to the command window in &quot;-nodesktop&quot; mode?]]></description>
			<content:encoded><![CDATA[<p>Hello Yair,</p>
<p>Perhaps, my comment does not completely matches topic of this post, but it might be interested to those who runs MATLAB with <b>-nodesktop</b> option. In this case MATLAB handles backspace characters in even more unusual way. Just try to rung the following commands in command prompt:</p>
<pre lang="matlab">
for k=0:10, fprintf('abcd'); fprintf(['12345',repmat('\b',1,k),'67890\n']); end;
for k=0:10, fprintf('abcd'); fprintf(['12345',repmat('\t',1,k),'67890\n']); end;
 
</pre>
<p>Here (<a href="https://i.imgsafe.org/ebccebb279.png" rel="nofollow ugc">https://i.imgsafe.org/ebccebb279.png</a>) is what I see in &#8220;-nodesktop&#8221; mode in R2015b.<br />
Tabs are handled properly while back-spaces can not erase text printed by previous fprintf command and produce weird results.</p>
<p>Do you have any ideas how to send &#8220;\b&#8221; character properly to the command window in &#8220;-nodesktop&#8221; mode?</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Marie Kris		</title>
		<link>https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-301475</link>

		<dc:creator><![CDATA[Marie Kris]]></dc:creator>
		<pubDate>Wed, 04 Dec 2013 02:18:16 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=4358#comment-301475</guid>

					<description><![CDATA[I hope this hard coded hack will work out properly.]]></description>
			<content:encoded><![CDATA[<p>I hope this hard coded hack will work out properly.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Yair Altman		</title>
		<link>https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-294780</link>

		<dc:creator><![CDATA[Yair Altman]]></dc:creator>
		<pubDate>Tue, 12 Nov 2013 17:15:24 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=4358#comment-294780</guid>

					<description><![CDATA[In reply to &lt;a href=&quot;https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-294779&quot;&gt;GeertvdWal&lt;/a&gt;.

Yet another hard-coded hack. Of course all the regular CSS attributes like color or whatever don&#039;t seem to work. Why couldn&#039;t MathWorks stay consistent?! this is really beyond my understanding.]]></description>
			<content:encoded><![CDATA[<p>In reply to <a href="https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-294779">GeertvdWal</a>.</p>
<p>Yet another hard-coded hack. Of course all the regular CSS attributes like color or whatever don&#8217;t seem to work. Why couldn&#8217;t MathWorks stay consistent?! this is really beyond my understanding.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: GeertvdWal		</title>
		<link>https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-294779</link>

		<dc:creator><![CDATA[GeertvdWal]]></dc:creator>
		<pubDate>Tue, 12 Nov 2013 16:57:16 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=4358#comment-294779</guid>

					<description><![CDATA[Hello Yair,

From R2011b and up (to my knowledge at least), MATLAB error messages include a bold hyperlink to relevant documentation. Try for yourself:

&lt;pre lang=&quot;c&quot;&gt; 
&gt;&gt; error
Error using &lt;b&gt;error&lt;/b&gt;
Not enough input arguments.
&lt;/pre&gt;

If MATLAB can do this, so can we! Some mucking about with HTML resulted in the following semi-accidental discovery:

&lt;pre lang=&quot;matlab&quot;&gt; 
fprintf(1,&#039;&lt;a href=&quot;%s&quot; style=&quot;font-weight:bold&quot;&gt;%s&lt;/a&gt;\n&#039;,...
    &#039;matlab:%% do stuff&#039;,...
    &#039;bold blue hyperlink&#039;...
    )
&lt;/pre&gt;

This also combines with the &#039;{\b ... }\b&#039; method for printing orange text, or the directing the output to STDERR method for printing red text. It&#039;s a bit clunky, but it works...

Unfortunately, it seems that this is another case of hard-coded syntax trapping, which means that it doesn&#039;t respond to other HTML tricks. Anyway, have fun with this!

Kind regards,

Geert

PS. thanks a million for this blog; It has helped me out on many occasions! I&#039;m glad I can make this little contribution.]]></description>
			<content:encoded><![CDATA[<p>Hello Yair,</p>
<p>From R2011b and up (to my knowledge at least), MATLAB error messages include a bold hyperlink to relevant documentation. Try for yourself:</p>
<pre lang="c"> 
>> error
Error using <b>error</b>
Not enough input arguments.
</pre>
<p>If MATLAB can do this, so can we! Some mucking about with HTML resulted in the following semi-accidental discovery:</p>
<pre lang="matlab"> 
fprintf(1,'<a href="%s" style="font-weight:bold">%s</a>\n',...
    'matlab:%% do stuff',...
    'bold blue hyperlink'...
    )
</pre>
<p>This also combines with the &#8216;{\b &#8230; }\b&#8217; method for printing orange text, or the directing the output to STDERR method for printing red text. It&#8217;s a bit clunky, but it works&#8230;</p>
<p>Unfortunately, it seems that this is another case of hard-coded syntax trapping, which means that it doesn&#8217;t respond to other HTML tricks. Anyway, have fun with this!</p>
<p>Kind regards,</p>
<p>Geert</p>
<p>PS. thanks a million for this blog; It has helped me out on many occasions! I&#8217;m glad I can make this little contribution.</p>
]]></content:encoded>
		
			</item>
		<item>
		<title>
		By: Chandrakanth		</title>
		<link>https://undocumentedmatlab.com/articles/another-command-window-text-color-hack#comment-293043</link>

		<dc:creator><![CDATA[Chandrakanth]]></dc:creator>
		<pubDate>Thu, 07 Nov 2013 17:19:55 +0000</pubDate>
		<guid isPermaLink="false">http://undocumentedmatlab.com/?p=4358#comment-293043</guid>

					<description><![CDATA[Can we get colours while publishing to pdf/html?]]></description>
			<content:encoded><![CDATA[<p>Can we get colours while publishing to pdf/html?</p>
]]></content:encoded>
		
			</item>
	</channel>
</rss>
