<?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: A multi-purpose NegateConverter for WPF/Silverlight</title>
	<atom:link href="http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/feed/" rel="self" type="application/rss+xml" />
	<link>http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/</link>
	<description>I should be sleeping.</description>
	<lastBuildDate>Sun, 04 Dec 2011 05:16:09 +0000</lastBuildDate>
	<sy:updatePeriod>hourly</sy:updatePeriod>
	<sy:updateFrequency>1</sy:updateFrequency>
	<generator>http://wordpress.org/?v=3.2.1</generator>
	<item>
		<title>By: Ziev</title>
		<link>http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/comment-page-1/#comment-5196</link>
		<dc:creator>Ziev</dc:creator>
		<pubDate>Thu, 27 Jan 2011 08:08:52 +0000</pubDate>
		<guid isPermaLink="false">http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/#comment-5196</guid>
		<description>&lt;p&gt;Hi Josh,&lt;/p&gt;

&lt;p&gt;It might sound like a silly question, but since I&#039;d like to use your NegateConverter source code as-is in my (commercial) application, is there any license agreement I must follow to do so?&lt;/p&gt;

&lt;p&gt;If there is, can you point there so that I can copy-paste it to my documentation? 
If not, please confirm so...&lt;/p&gt;

&lt;p&gt;Thanks a lot for your helpful contributions to all of us,
Ziev&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Hi Josh,</p>

<p>It might sound like a silly question, but since I&#8217;d like to use your NegateConverter source code as-is in my (commercial) application, is there any license agreement I must follow to do so?</p>

<p>If there is, can you point there so that I can copy-paste it to my documentation? 
If not, please confirm so&#8230;</p>

<p>Thanks a lot for your helpful contributions to all of us,
Ziev</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Windows Client Developer Roundup for 6/28/2010 - Pete Brown's 10rem.net</title>
		<link>http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/comment-page-1/#comment-1862</link>
		<dc:creator>Windows Client Developer Roundup for 6/28/2010 - Pete Brown's 10rem.net</dc:creator>
		<pubDate>Mon, 28 Jun 2010 07:04:21 +0000</pubDate>
		<guid isPermaLink="false">http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/#comment-1862</guid>
		<description>&lt;p&gt;[...] A multi-purpose NegateConverter for WPF/Silverlight (Josh Einstein) [...]&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>[...] A multi-purpose NegateConverter for WPF/Silverlight (Josh Einstein) [...]</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Josh Einstein</title>
		<link>http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/comment-page-1/#comment-1833</link>
		<dc:creator>Josh Einstein</dc:creator>
		<pubDate>Thu, 24 Jun 2010 18:58:20 +0000</pubDate>
		<guid isPermaLink="false">http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/#comment-1833</guid>
		<description>&lt;p&gt;Great tip, Inferis. I was going to respond similarly because I am going to post next about my SwitchConverter class that does just that. The tricky part about that one is making it generic enough to support conversion from string to targetType without hard coding too many common conversions (such as Boolean to Visibility).&lt;/p&gt;

&lt;p&gt;Update: Nice! I just realized that if just pass the strings back from the converter, the binding system will take care of converting them to the target type. In other words &lt;BoolConverter True=&quot;Green&quot; False=&quot;Red&quot; /&gt; will get converted to SolidColorBrush automatically.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Great tip, Inferis. I was going to respond similarly because I am going to post next about my SwitchConverter class that does just that. The tricky part about that one is making it generic enough to support conversion from string to targetType without hard coding too many common conversions (such as Boolean to Visibility).</p>

<p>Update: Nice! I just realized that if just pass the strings back from the converter, the binding system will take care of converting them to the target type. In other words &lt;BoolConverter True=&#8221;Green&#8221; False=&#8221;Red&#8221; /&gt; will get converted to SolidColorBrush automatically.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Inferis</title>
		<link>http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/comment-page-1/#comment-1825</link>
		<dc:creator>Inferis</dc:creator>
		<pubDate>Wed, 23 Jun 2010 18:21:27 +0000</pubDate>
		<guid isPermaLink="false">http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/#comment-1825</guid>
		<description>&lt;p&gt;Handy converter. Thanks.&lt;/p&gt;

&lt;p&gt;@mpg: it&#039;s not that hard: just write one, give it 2 properties: OnTrue and OnFalse (which can be of a specific type, for instance Visibility, but also just a generic Object so that you can have a bool2something converter).&lt;/p&gt;

&lt;p&gt;When you convert, you just do: (bool)value ? OnTrue : OnFalse&lt;/p&gt;

&lt;p&gt;In XAML, that becomes:&lt;/p&gt;

&lt;p&gt;or&lt;/p&gt;

&lt;p&gt;Don&#039;t forget to give them meaningful defaults, so that you can omit them for common scenarios.&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Handy converter. Thanks.</p>

<p>@mpg: it&#8217;s not that hard: just write one, give it 2 properties: OnTrue and OnFalse (which can be of a specific type, for instance Visibility, but also just a generic Object so that you can have a bool2something converter).</p>

<p>When you convert, you just do: (bool)value ? OnTrue : OnFalse</p>

<p>In XAML, that becomes:</p>

<p>or</p>

<p>Don&#8217;t forget to give them meaningful defaults, so that you can omit them for common scenarios.</p>]]></content:encoded>
	</item>
	<item>
		<title>By: mpg</title>
		<link>http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/comment-page-1/#comment-1822</link>
		<dc:creator>mpg</dc:creator>
		<pubDate>Wed, 23 Jun 2010 14:29:37 +0000</pubDate>
		<guid isPermaLink="false">http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/#comment-1822</guid>
		<description>&lt;p&gt;Here&#039;s what I don&#039;t get, though -- and maybe I&#039;m just missing something really fundamental somewhere...&lt;/p&gt;

&lt;p&gt;I find myself sometimes having to do things like &quot;set Visibility to Visible on Control A if P&quot;, which entails often making a &quot;BoolToVisible&quot; converter.  But then somewhere else I have to do &quot;set Visibility to Visible on Control B if not P&quot; -- for which I wind up writing another, almost but not quite identical, &quot;inverseBoolToVisible&quot; converter.&lt;/p&gt;

&lt;p&gt;Is there a way to avoid writing the extra converter?&lt;/p&gt;

&lt;p&gt;-mpg&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Here&#8217;s what I don&#8217;t get, though &#8212; and maybe I&#8217;m just missing something really fundamental somewhere&#8230;</p>

<p>I find myself sometimes having to do things like &#8220;set Visibility to Visible on Control A if P&#8221;, which entails often making a &#8220;BoolToVisible&#8221; converter.  But then somewhere else I have to do &#8220;set Visibility to Visible on Control B if not P&#8221; &#8212; for which I wind up writing another, almost but not quite identical, &#8220;inverseBoolToVisible&#8221; converter.</p>

<p>Is there a way to avoid writing the extra converter?</p>

<p>-mpg</p>]]></content:encoded>
	</item>
	<item>
		<title>By: Noor</title>
		<link>http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/comment-page-1/#comment-1821</link>
		<dc:creator>Noor</dc:creator>
		<pubDate>Wed, 23 Jun 2010 08:15:20 +0000</pubDate>
		<guid isPermaLink="false">http://josheinstein.com/blog/index.php/2010/06/a-multi-purpose-negateconverter-for-wpfsilverlight/#comment-1821</guid>
		<description>&lt;p&gt;Great piece of information! Thanks for sharing the code&lt;/p&gt;
</description>
		<content:encoded><![CDATA[<p>Great piece of information! Thanks for sharing the code</p>]]></content:encoded>
	</item>
</channel>
</rss>

