<?xml version="1.0" encoding="UTF-8" ?>
<?xml-stylesheet type="text/xsl" href="http://community.sharpdevelop.net/utility/FeedStylesheets/rss.xsl" media="screen"?><rss version="2.0" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:slash="http://purl.org/rss/1.0/modules/slash/" xmlns:wfw="http://wellformedweb.org/CommentAPI/"><channel><title>SharpDevelop Community</title><link>http://community.sharpdevelop.net/blogs/</link><description>Get your problems solved!</description><dc:language>en-US</dc:language><generator>CommunityServer 2007.1 SP2 (Build: 31113.47)</generator><item><title>Usage Data Collector: The Signup Message</title><link>http://community.sharpdevelop.net/blogs/christophwille/archive/2010/03/18/usage-data-collector-the-signup-message.aspx</link><pubDate>Thu, 18 Mar 2010 12:55:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:30062</guid><dc:creator>ChristophWille</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;This is the start of a series of blog posts describing the Usage Data Collector that is built into SharpDevelop 4.0. UDC as it is called for short is intended to help us better understand what features are being used, how developers found out about the feature (menu, toolbar, context menu, et cetera), how much time they spent using the feature, and if there were any issues (exceptions). The intention is to find out which features need to be surfaced differently so more people use them, which the popular features are (and thus should be given a higher priority) and a lot more.&lt;/p&gt;
&lt;p&gt;Before diving into the topic of this blog post, one important piece of architecture information: UDC is not tied to SharpDevelop. We developed it to be reuseable in your applications. Including (a yet to be developed) analysis Web frontend. That&amp;#39;s also why we intend to give you a good background on what we collect, how we collect it, how it is transferred - so you have a good understanding whether it is suitable for your userbase.&lt;/p&gt;
&lt;p&gt;On its new start page, SharpDevelop 4.0 asks you to participate in the customer experience improvement program:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/christophwille/images/30061/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;If a user wants to participate and clicks the &amp;quot;Save&amp;quot; button, we do send the initial usage data message - for two reasons: first, depending on firewall settings, the user might need to allow SharpDevelop to communicate with the Internet. Doing it right now and there allows the user to see why SharpDevelop wants Internet access. Secondly, we gather Session &amp;quot;0&amp;quot; - information about the version of SharpDevelop, and on top of what platform it is running.&lt;/p&gt;
&lt;p&gt;
In terms of actual data, this is a sample UDC signup message (line 1 has been truncated for xmlns elements):&lt;/p&gt;
&lt;div class="code0"&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt; 1:  &lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;UsageDataMessage &lt;/span&gt;&lt;span class="code5"&gt;...&lt;/span&gt;&lt;span class="code6"&gt;&lt;/span&gt;&lt;span class="code4"&gt;&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt; 2:  &lt;/span&gt;  &lt;span class="code4"&gt;&amp;lt;Sessions&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt; 3:  &lt;/span&gt;    &lt;span class="code4"&gt;&amp;lt;UsageDataSession&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt; 4:  &lt;/span&gt;      &lt;span class="code4"&gt;&amp;lt;EndTime &lt;/span&gt;&lt;span class="code5"&gt;i:nil&lt;/span&gt;&lt;span class="code6"&gt;=&amp;quot;true&amp;quot; &lt;/span&gt;&lt;span class="code4"&gt;/&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt; 5:  &lt;/span&gt;      &lt;span class="code4"&gt;&amp;lt;EnvironmentProperties&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt; 6:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt; 7:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;platform&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt; 8:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;Win32NT&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt; 9:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;10:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;11:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;osVersion&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;12:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code8"&gt;5.1.2600.196608&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;13:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;14:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;15:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;processorCount&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;16:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code8"&gt;1&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;17:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;18:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;19:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;dotnetRuntime&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;20:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code8"&gt;4.0.30128.1&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;21:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;22:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;23:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;appVersion&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;24:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code8"&gt;4.0.0.5623&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;25:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;26:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;27:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;language&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;28:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;es&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;29:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;30:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;31:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;culture&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;32:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;es-ES&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;33:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;34:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;35:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;userAddInCount&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;36:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code8"&gt;0&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;37:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;38:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;39:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Name&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;architecture&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Name&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;40:  &lt;/span&gt;          &lt;span class="code4"&gt;&amp;lt;Value&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;x86&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/Value&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;41:  &lt;/span&gt;        &lt;span class="code4"&gt;&amp;lt;/UsageDataEnvironmentProperty&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;42:  &lt;/span&gt;      &lt;span class="code4"&gt;&amp;lt;/EnvironmentProperties&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;43:  &lt;/span&gt;      &lt;span class="code4"&gt;&amp;lt;Exceptions /&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;44:  &lt;/span&gt;      &lt;span class="code4"&gt;&amp;lt;FeatureUses /&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;45:  &lt;/span&gt;      &lt;span class="code4"&gt;&amp;lt;SessionID&amp;gt;&lt;/span&gt;&lt;span class="code8"&gt;0&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/SessionID&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;46:  &lt;/span&gt;      &lt;span class="code4"&gt;&amp;lt;StartTime&amp;gt;&lt;/span&gt;&lt;span class="code8"&gt;2010&lt;/span&gt;&lt;span class="code7"&gt;-03-18T12:01:38.5625Z&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/StartTime&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;47:  &lt;/span&gt;    &lt;span class="code4"&gt;&amp;lt;/UsageDataSession&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;48:  &lt;/span&gt;  &lt;span class="code4"&gt;&amp;lt;/Sessions&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code1"&gt;&lt;span class="code3"&gt;49:  &lt;/span&gt;  &lt;span class="code4"&gt;&amp;lt;UserID&amp;gt;&lt;/span&gt;&lt;span class="code7"&gt;cb02e999-4e80-45d2-9773-ed3d80b3937f&lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/UserID&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;pre class="code2"&gt;&lt;span class="code3"&gt;50:  &lt;/span&gt;&lt;span class="code4"&gt;&amp;lt;/UsageDataMessage&amp;gt;&lt;/span&gt;&lt;/pre&gt;
&lt;/div&gt;
&lt;p&gt;
Please note line #49: each client machine creates a GUID for itself. This GUID is used to map all sessions to a single user - so we can tell whether a single developer is using a feature heavily compared to say a hundred developers using the very same feature lightly.&lt;/p&gt;
&lt;p&gt;As you can see, the initial message is very small. Once data is being gathered, the messages do increase in size, and contain more information (feature use, exceptions). We will look into those message in future blog posts, as well as how those messages are processed and analyzed.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=30062" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/christophwille/archive/tags/UDC/default.aspx">UDC</category><category domain="http://community.sharpdevelop.net/blogs/christophwille/archive/tags/Usage+Data+Collector/default.aspx">Usage Data Collector</category></item><item><title>Compiling Python Packages with IronPython</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2010/03/16/CompilingPythonPackagesWithIronPython.aspx</link><pubDate>Tue, 16 Mar 2010 21:03:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:30022</guid><dc:creator>MattWard</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;Here is a walkthrough on how to compile Python packages and 
    modules, such as those provided by the 
    &lt;a href="http://docs.python.org/library/"&gt;Python Standard 
    Library&lt;/a&gt;, so you can distribute your IronPython application as a 
    set of standalone assemblies. If you just want to use the Python 
    Standard Library without compiling parts of it into your 
    application then you can add the path to the standard library as 
    described in a previous post on 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2009/03/01/UsingPythonStandardLibrary.aspx"&gt;using the Python Standard Library&lt;/a&gt;.&lt;/p&gt;
&lt;h2&gt;Prerequisites&lt;/h2&gt;
&lt;p&gt;You will need to have SharpDevelop 3.2 and Python 2.6 installed 
    on your machine. These can be downloaded from the following 
    locations.&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="http://www.sharpdevelop.net/OpenSource/SD/Download/#SharpDevelop30"&gt;SharpDevelop 3.2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.python.org/download/releases/2.6.4/"&gt;Python 2.6&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Python Modules Included with IronPython&lt;/h2&gt;
&lt;p&gt;Before you start compiling a Python module or package into your 
    application you should check whether it is already included with 
    IronPython or whether you can use the .NET framework instead. A lot 
    of the &lt;a href="http://docs.python.org/library/"&gt;Python Standard 
    Library&lt;/a&gt; modules are already included with IronPython. You can 
    see which ones by using 
    &lt;a href="http://www.red-gate.com/products/reflector/"&gt;Reflector&lt;/a&gt; 
    to look at IronPython.dll and IronPython.Modules.dll. Open these 
    assemblies in Reflector, right click and select Disassemble. In the 
    screenshot below the modules that are included with IronPython are 
    defined by the PythonModule attribute.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/mattward/images/original/IronPythonModulesInReflector.aspx" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;Alternatively you can use the 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/Python/IronPythonModulesReader.zip"&gt;IronPython Modules Reader application&lt;/a&gt; to list all the 
    available modules in IronPython.&lt;/p&gt;
&lt;p&gt;If you need to use one of the modules provided by IronPython 
    then add a reference to IronPython and IronPython.Modules in your 
    project and then import the module in the normal way:&lt;/p&gt;
&lt;pre&gt;import cmath&lt;/pre&gt;
&lt;h2&gt;Compiling a Python Module&lt;/h2&gt;
&lt;p&gt;Now we will look at writing a simple IronPython application that 
    reads in a zip file using the zipfile module from the Python 
    standard library. Our application will read the names of all the 
    files in the zip file and display them in the console window. The 
    code is shown below.&lt;/p&gt;
&lt;pre&gt;import zipfile &lt;br /&gt; &lt;br /&gt;file = zipfile.ZipFile(&amp;quot;test.zip&amp;quot;, &amp;quot;r&amp;quot;) &lt;br /&gt; &lt;br /&gt;for name in file.namelist(): &lt;br /&gt;    print name&lt;br /&gt;&lt;/pre&gt;
&lt;p&gt;Now if you create a python console project with SharpDevelop, 
    copy the code above into the Program.py file, compile and run the 
    program you will get an error saying &amp;quot;No module called 
    zipfile&amp;quot;. To fix this problem you can add the zipfile.py file 
    from the Python standard library directly into your project. Simply 
    right click your project, select Add Existing Item and browse to 
    the zipfile in the python libs folder (e.g. C:\Python26\lib). If 
    you compile your program again and run it you will get an error 
    about a different module. The zipfile module depends on 13 other 
    modules from the standard library. With a bit of trial and error 
    you can work out which modules are needed. After adding these 
    dependent modules to your project you will have a set of assemblies 
    that do not require the Python Standard library to be installed.&lt;/p&gt;
&lt;p&gt;The full code for the zip file reader application can be 
    downloaded from the 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/Python/ZipFileReader.zip"&gt;Zip File Reader&lt;/a&gt; link at the end of this post.&lt;/p&gt;
&lt;h2&gt;Compiling a Python Package&lt;/h2&gt;
&lt;p&gt;A Python module consists of a single file (e.g. zipfile.py). A 
    Python package is a set of files inside a subdirectory. Compiling a 
    package into your application cannot be done simply by including 
    the files directly in your project. Instead you must compile the 
    package files into a separate class library assembly. As an example 
    we will look at using the json package. We will create a simple 
    application that creates a json string from a dictionary. The code 
    is shown below.&lt;/p&gt;
&lt;pre&gt;import json &lt;br /&gt; &lt;br /&gt;address = {} &lt;br /&gt;address[&amp;quot;street&amp;quot;] = &amp;quot;24 22nd Street&amp;quot; &lt;br /&gt;address[&amp;quot;city&amp;quot;] = &amp;quot;New York&amp;quot; &lt;br /&gt;address[&amp;quot;state&amp;quot;] = &amp;quot;NY&amp;quot; &lt;br /&gt;address[&amp;quot;postCode&amp;quot;] = &amp;quot;10021&amp;quot; &lt;br /&gt; &lt;br /&gt;person = {} &lt;br /&gt;person[&amp;quot;firstName&amp;quot;] = &amp;quot;John&amp;quot; &lt;br /&gt;person[&amp;quot;lastName&amp;quot;] = &amp;quot;Smith&amp;quot; &lt;br /&gt;person[&amp;quot;age&amp;quot;] = 20 &lt;br /&gt;person[&amp;quot;address&amp;quot;] = address &lt;br /&gt; &lt;br /&gt;print json.dumps(person)&lt;/pre&gt;
&lt;p&gt;Now to use the json package from our application we need to 
    create a python class library project. Then we need to add all the 
    files from the json package into this project and compile it. 
    Finally in our Json Writer project we need to add a reference to 
    this class library. The screenshot below shows the contents of the 
    two projects.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Json package in class library" src="http://community.sharpdevelop.net/photos/mattward/images/original/JsonPackageInPythonClassLibraryProject.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Now this is not quite enough since the json package depends on 
    several modules in the standard library. So now we add these to the 
    json class library project. After adding these modules the json 
    class library project should then contain the files as shown in the 
    screenshot below.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Json class library with dependencies" src="http://community.sharpdevelop.net/photos/mattward/images/original/JsonPackageWithDependenciesInPythonClassLibraryProject.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;You should now be able to compile and run your Json Writer 
    application. The Json Writer application can now be distributed as 
    a set of assemblies without needing the Python Standard Library to 
    be installed.&lt;/p&gt;
&lt;p&gt;The full code for the Json Writer application can be downloaded 
    from the 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/Python/JsonWriter.zip"&gt;Json Writer&lt;/a&gt; link at the end of this post.&lt;/p&gt;
&lt;p&gt;Finally here is a link to the 
    &lt;a href="http://wiki.python.org/moin/PythonSoftwareFoundationLicenseFaq"&gt;license FAQ for Python and Python Standard Library&lt;/a&gt; that should 
    be checked before you include the standard library in your 
    application.&lt;/p&gt;
&lt;h2&gt;Downloads&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;&lt;a href="http://www.sharpdevelop.net/OpenSource/SD/Download/#SharpDevelop30"&gt;SharpDevelop 3.2&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.python.org/download/releases/2.6.4/"&gt;Python 2.6&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.red-gate.com/products/reflector/"&gt;Reflector&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/Python/IronPythonModulesReader.zip"&gt;IronPython Modules Reader&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/Python/ZipFileReader.zip"&gt;Zip File Reader&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/Python/JsonWriter.zip"&gt;Json Writer&lt;/a&gt;&lt;/li&gt;
&lt;/ul&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=30022" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Python/default.aspx">Python</category></item><item><title>IronRuby 1.0 RC3</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2010/03/13/IronRuby1RC3.aspx</link><pubDate>Sat, 13 Mar 2010 15:47:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29959</guid><dc:creator>MattWard</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;The latest releases of 
    &lt;a href="http://build.sharpdevelop.net/buildartefacts/"&gt;
    SharpDevelop 3.2 and 4.0&lt;/a&gt; (versions 5611 and above) now include 
    &lt;a href="http://ironruby.codeplex.com/"&gt;IronRuby 1.0 RC3&lt;/a&gt; which 
    was released yesterday. &lt;/p&gt;
&lt;p&gt;The IronRuby console (ir.exe) command line option to use Ruby 
    1.9 mode has changed in this release from &lt;b&gt;-19&lt;/b&gt; to &lt;b&gt;-1.9&lt;/b&gt; 
    so if you have an IronRuby project (.rbproj) created with a 
    previous version of SharpDevelop you will need to change the 
    command line used when debugging your application. To do this from 
    the &lt;b&gt;Project&lt;/b&gt; menu select &lt;b&gt;Project Options&lt;/b&gt; and then 
    update the &lt;b&gt;Start Options Command Line&lt;/b&gt;, for example:&lt;/p&gt;
&lt;pre&gt;-1.9 -D Program.rb&lt;/pre&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29959" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronRuby/default.aspx">IronRuby</category></item><item><title>IronPython and IronRuby versions in SharpDevelop</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2010/03/03/IronPythonIronRubyVersionsInSharpDevelop.aspx</link><pubDate>Wed, 03 Mar 2010 18:40:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29864</guid><dc:creator>MattWard</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;
&lt;table class="article "&gt;

&lt;tr&gt;
&lt;th&gt;SharpDevelop&lt;/th&gt;&lt;th&gt;IronPython&lt;/th&gt;&lt;th&gt;IronRuby&lt;/th&gt;
&lt;/tr&gt;


&lt;tr&gt;
&lt;td&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2007/10/21/IronPythonIntegrationInSharpDevelop22.aspx"&gt;SharpDevelop 2.2.1&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;IronPython 1.1*&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;a href="http://sourceforge.net/projects/sharpdevelop/files/SharpDevelop%203.x/3.0/SharpDevelop_3.0.0.3800_Setup.msi/download"&gt;SharpDevelop 3.0&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;IronPython 2.0&lt;/td&gt;
&lt;td&gt;n/a&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;a href="http://sourceforge.net/projects/sharpdevelop/files/SharpDevelop%203.x/3.1/SharpDevelop_3.1.0.4977_Setup.msi/download"&gt;SharpDevelop 3.1&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;IronPython 2.0.2&lt;/td&gt;
&lt;td&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2009/10/04/IronRubyIntegrationInSharpDevelop31.aspx"&gt;IronRuby 0.9.1*&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;a href="http://sourceforge.net/projects/sharpdevelop/files/SharpDevelop%203.x/3.1/SharpDevelop_3.1.1.5327_Setup.msi/download"&gt;SharpDevelop 3.1.1&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;IronPython 2.6&lt;/td&gt;
&lt;td&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2009/10/04/IronRubyIntegrationInSharpDevelop31.aspx"&gt;IronRuby 0.9.1*&lt;/a&gt;&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;a href="http://build.sharpdevelop.net/buildartefacts/"&gt;
          SharpDevelop 3.2&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;IronPython 2.6.1 RC1&lt;/td&gt;
&lt;td&gt;IronRuby 1.0 RC3&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;&lt;a href="http://build.sharpdevelop.net/buildartefacts/"&gt;
          SharpDevelop 4.0 (.NET 4.0 RC1)&lt;/a&gt;&lt;/td&gt;
&lt;td&gt;IronPython 2.6.1 RC1 (.NET 4.0 RC1)&lt;/td&gt;
&lt;td&gt;IronRuby 1.0 RC3 (.NET 4.0 RC1)&lt;/td&gt;
&lt;/tr&gt;

&lt;/table&gt;
&lt;/p&gt;
&lt;p&gt;* - Available as a separate addin not shipped with 
    SharpDevelop.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29864" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronPython/default.aspx">IronPython</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronRuby/default.aspx">IronRuby</category></item><item><title>Debugging an ASP.NET Application with SharpDevelop</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2010/02/28/DebuggingAspNetAppWithSharpDevelop.aspx</link><pubDate>Sun, 28 Feb 2010 18:53:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29829</guid><dc:creator>MattWard</dc:creator><slash:comments>2</slash:comments><description>&lt;p&gt;This tutorial shows you how to debug an ASP.NET application with 
    SharpDevelop.&lt;/p&gt;
&lt;p&gt;Before we begin it should be noted that SharpDevelop does not 
    have great ASP.NET support. There is no web forms designer, no 
    intellisense for ASP.NET pages (.aspx) and no support for the new 
    style ASP.NET Web Site projects introduced in Visual Studio 2005. 
    You can however create an ASP.NET Web Application project or an 
    ASP.NET Web Service in SharpDevelop. If you are looking for a 
    better ASP.NET experience then you should use 
    &lt;a href="http://www.microsoft.com/express/Web/"&gt;Microsoft Visual 
    Web Developer&lt;/a&gt;. However if still want to use SharpDevelop then 
    here is how to debug your ASP.NET application.&lt;/p&gt;
&lt;h2&gt;Creating an ASP.NET Application&lt;/h2&gt;
&lt;p&gt;First let us create an ASP.NET Web Application. From the 
    &lt;b&gt;File&lt;/b&gt; menu select &lt;b&gt;New&lt;/b&gt;, then &lt;b&gt;Solution&lt;/b&gt;, to open 
    up the &lt;b&gt;New Project&lt;/b&gt; dialog.&lt;/p&gt;
&lt;p&gt;&lt;img alt="ASP.NET project in New Project dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/NewAspNetWebPageProjectTemplate.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;On the left hand side of this dialog select &lt;b&gt;ASP.NET&lt;/b&gt; 
    category underneath the &lt;b&gt;C#&lt;/b&gt; category. On the right hand side 
    select the &lt;b&gt;ASP.NET web page project&lt;/b&gt; icon. Give project a 
    name and choose where you want the project created and click the 
    &lt;b&gt;Create&lt;/b&gt; button. SharpDevelop will then create a basic ASP.NET 
    Web Application project.&lt;/p&gt;
&lt;h2&gt;Download Cassini&lt;/h2&gt;
&lt;p&gt;In order to be able to debug the ASP.NET application we will be 
    using Cassini. Cassini is a lightweight open source web server. It 
    was originally released as a 
    &lt;a href="http://www.asp.net/Downloads/archived/cassini/"&gt;sample by 
    Microsoft&lt;/a&gt;. Dmitry Robsman then 
    &lt;a href="http://blogs.msdn.com/dmitryr/archive/2008/10/03/cassini-for-framework-3-5.aspx"&gt;updated the sample to run under .NET 3.5&lt;/a&gt;. After that different 
    versions based on Dmitry&amp;#39;s original work were released on 
    codeplex. Any of these versions of Cassini, in the list below, will 
    work with SharpDevelop. The version of Cassini provided by Dmitry 
    requires you to compile the source code. The other versions do not. 
    The Cassini Developer&amp;#39;s edition has slightly different command 
    line options compared to the rest so it will not be covered in the 
    following discussion. We will use Cassini++ for the rest of this 
    tutorial. &lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href="http://cassinipp.codeplex.com/"&gt;Cassini++&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;Dmitry Robsman - 
      &lt;a href="http://blogs.msdn.com/dmitryr/archive/2008/10/03/cassini-for-framework-3-5.aspx"&gt;Cassini v3.5&lt;/a&gt; or 
      &lt;a href="http://blogs.msdn.com/dmitryr/archive/2009/04/23/cassini-support-for-friendly-urls-routing.aspx"&gt;Cassini v3.5.0.2&lt;/a&gt; with friendly url/routing support.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://cassinidev.codeplex.com/"&gt;Cassini 3.5 
      Developers Edition&lt;/a&gt;&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;Download Cassini++ from the link provided and extract the files 
    to a directory on the same machine that you are running 
    SharpDevelop on.&lt;/p&gt;
&lt;h2&gt;Debugging an ASP.NET Application&lt;/h2&gt;
&lt;p&gt;First let us set a breakpoint in our application. Find the 
    &lt;b&gt;Default.aspx.cs&lt;/b&gt; file in your project and open it in the text 
    editor. Locate the Page_Load method and set a breakpoint inside 
    this method on the Response.Write line.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Breakpoint set in SharpDevelop" src="http://community.sharpdevelop.net/photos/mattward/images/original/AspNetPageLoadBreakpoint.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Now you need to configure the project to run Cassini when you 
    debug your application. From the &lt;b&gt;Project&lt;/b&gt; menu select 
    &lt;b&gt;Project Options&lt;/b&gt;. In the options dialog select the 
    &lt;b&gt;Debug&lt;/b&gt; tab. Set the &lt;b&gt;Start Action&lt;/b&gt; to &lt;b&gt;Start external 
    program&lt;/b&gt; and enter the path to the Cassini executable. In the 
    &lt;b&gt;Start Options&lt;/b&gt; enter the command line that will be passed to 
    Cassini. The Cassini command line is of the form:&lt;/p&gt;
&lt;pre&gt;&amp;lt;physical-path&amp;gt; &amp;lt;port&amp;gt; &amp;lt;virtual-path&amp;gt;&lt;/pre&gt;
&lt;p&gt;In the screenshot below you can see an example command line 
    passed to Cassini. In this case Cassini will listen for requests on 
    port 8080, the virtual path will be set to &amp;quot;/&amp;quot; and the 
    physical path to your project is specified by a using SharpDevelop 
    property &lt;b&gt;${ProjectDir}&lt;/b&gt; which will be replaced when you start 
    debugging. You can put the full path to your project directory here 
    instead of using the ProjectDir property.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Project options dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/AspNetProjectOptionsToRunCassini.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Save the changes you made to the project options. Then select 
    &lt;b&gt;Run&lt;/b&gt; from the &lt;b&gt;Debug&lt;/b&gt; menu. Cassini should then start. 
    &lt;/p&gt;
&lt;p&gt;&lt;img alt="Cassini Running" src="http://community.sharpdevelop.net/photos/mattward/images/original/CassiniPlusPlusWindow.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Click the &lt;a href="http://localhost:8080/"&gt;
    http://localhost:8080/&lt;/a&gt; hyperlink at the bottom of the Cassini 
    window to visit your application&amp;#39;s web page in the default 
    browser. When the page is loaded in the browser the breakpoint in 
    Page_Load should then be hit and you can start debugging.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Page_Load breakpoint hit" src="http://community.sharpdevelop.net/photos/mattward/images/original/StoppedAtAspNetPageLoadBreakpoint.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Attach to Process&lt;/h2&gt;
&lt;p&gt;As an alternative to configuring SharpDevelop to start Cassini 
    every time you debug your ASP.NET application you can leave Cassini 
    running and attach to its process when you need to. &lt;/p&gt;
&lt;p&gt;First on your desktop create a shortcut to Cassini and specify 
    the appropriate Cassini command line as explained earlier. Note 
    that the ${ProjectDir} property cannot be used here so instead you 
    will need to put the full path to your project. Start Cassini by 
    double clicking the shortcut and use a browser to display your web 
    page. Now in SharpDevelop select &lt;b&gt;Attach to Process&lt;/b&gt; from the 
    &lt;b&gt;Debug&lt;/b&gt; menu. Select the Cassini process and click the 
    &lt;b&gt;Attach&lt;/b&gt; button. &lt;/p&gt;
&lt;p&gt;&lt;img alt="Attaching to the Cassini process" src="http://community.sharpdevelop.net/photos/mattward/images/original/AttachToCassiniProcess.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Now when you press &lt;b&gt;Ctrl+F5&lt;/b&gt; in the browser showing your 
    web page to refresh the page the breakpoint in the Page_Load method 
    should be hit and you can start debugging.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29829" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/ASPNet/default.aspx">ASPNet</category></item><item><title>SharpDevelop and the Google Summer of Code 2010</title><link>http://community.sharpdevelop.net/blogs/dsrbecky/archive/2010/02/20/gsoc2010.aspx</link><pubDate>Sat, 20 Feb 2010 16:32:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29724</guid><dc:creator>DavidSrbecky</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;&lt;a href="http://code.google.com/soc/"&gt;Google Summer of Code 2010&lt;/a&gt; has been officially announced and &lt;a href="http://www.icsharpcode.net/OpenSource/SD/" target="_blank"&gt;SharpDevelop&lt;/a&gt; intends to participate again.&lt;/p&gt;
&lt;p&gt;Google Summer of Code is an opportunity for students to earn &lt;b&gt;5000 USD&lt;/b&gt; over the summer by working on an open-source project.&lt;/p&gt;
&lt;p&gt;We
have created a list of ideas, but you can work on anything
you want as long as it is related to SharpDevelop.&amp;nbsp; You can find the
list of ideas and any further information on the &lt;a href="http://wiki.sharpdevelop.net/gsoc.ashx"&gt;SharpDevelop wiki page for the Google Summer of Code&lt;/a&gt;.&amp;nbsp; The application deadline is 19:00 UTC on April 9th.&amp;nbsp; In the meantime, you can start coding and talking to us on the &lt;a href="http://community.sharpdevelop.net/forums/"&gt;forums&lt;/a&gt;, via &lt;a href="mailto:gsoc@icsharpcode.net"&gt;email&lt;/a&gt; or on the &lt;a target="_blank"&gt;IRC&lt;/a&gt; (#SharpDevelop at irc.freenode.net).&lt;/p&gt;
&lt;p&gt;Please spread the word and tell your friends about the Summer of Code as well. &lt;/p&gt;
&lt;p&gt;If you have any project ideas for the students, feel free to mention them in the comments below the post.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29724" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/dsrbecky/archive/tags/Mono/default.aspx">Mono</category><category domain="http://community.sharpdevelop.net/blogs/dsrbecky/archive/tags/GSoC/default.aspx">GSoC</category></item><item><title>Code Converter Site Upgraded to SharpDevelop 3.2 RC1</title><link>http://community.sharpdevelop.net/blogs/christophwille/archive/2010/02/14/code-converter-site-upgraded-to-sharpdevelop-3-2-rc1.aspx</link><pubDate>Sun, 14 Feb 2010 15:38:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29639</guid><dc:creator>ChristophWille</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;With the release of RC1, the &lt;a href="http://codeconverter.sharpdevelop.net/"&gt;code converter site&lt;/a&gt; has been upgraded too (from NRefactory 3.2.0.5362 to 3.2.0.5506). Relevant checkins:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://fisheye2.atlassian.com/changelog/sharpdevelop/?cs=5432"&gt;http://fisheye2.atlassian.com/changelog/sharpdevelop/?cs=5432&lt;/a&gt;&lt;br /&gt;&lt;a href="http://fisheye2.atlassian.com/changelog/sharpdevelop/?cs=5448"&gt;http://fisheye2.atlassian.com/changelog/sharpdevelop/?cs=5448&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Supported languages (via Web interface as well as Web Service): C#, VB.NET, Boo, IronPython, IronRuby.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29639" width="1" height="1"&gt;</description></item><item><title>Progress in SharpDevelop 4.0</title><link>http://community.sharpdevelop.net/blogs/danielgrunwald/archive/2010/02/12/progress-in-sharpdevelop.aspx</link><pubDate>Fri, 12 Feb 2010 18:59:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29627</guid><dc:creator>DanielGrunwald</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;SharpDevelop execute many tasks that require progress reporting. Most also can be cancelled by the user.&lt;/p&gt;
&lt;p&gt;Examples are:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Loading a solution (parsing files for code completion and class browser)&lt;/li&gt;
&lt;li&gt;Building&lt;/li&gt;
&lt;li&gt;Searching&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;In SharpDevelop 4.0.0.5483, I&amp;#39;ve rewritten the IProgressMonitor interface used for these operations. The main difference in comparison with the old interface is that it is now possible to create nested progress monitors, allowing the composition of large progress-reporting operations from many smaller operations. Also, creating nested progress monitors now allows to safely report progress from parallel computations. Every thread can create its own nested progress monitor for reporting its progress.&lt;/p&gt;
&lt;p&gt;Now what happens with these progress reports? They will be collected by the &lt;b&gt;ProgressCollector&lt;/b&gt; class. The ProgressCollector takes care of summing up the progress from all nested progress monitors. It also handles the multi-threading issues. The output of a ProgressCollector is a simple set of properties describing the current progress of the operation, plus a &amp;quot;PropertyChanged&amp;quot; event which will be fired only on the GUI thread. This allows using WPF data binding to display the total progress in a progress bar.&lt;/p&gt;
&lt;p&gt;Another difference is that the cancellation support has been simplified by making use of the &lt;a href="http://blogs.msdn.com/pfxteam/archive/2009/05/22/9635790.aspx"&gt;.NET 4 cancellation framework&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The above changes don&amp;#39;t have any visible effect for the end-user. However, while working on this, I had an idea: similar to the progress bar in Windows Explorer in Vista and Windows 7, the progress bar should turn red when there are errors. This gives immediate visual feedback that the build failed, making it a lot less likely that you miss the error messages in the &amp;quot;Errors&amp;quot; pad and wonder why your binary didn&amp;#39;t change.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;img src="http://community.sharpdevelop.net/photos/danielgrunwald/images/29628/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;A related change in SharpDevelop 4.0.0.5490 is that the progress is now shown on the Windows 7 task bar:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/danielgrunwald/images/29629/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;So the progress of long-running builds is always visible; even if you minimize SharpDevelop and do something else while the compiler is working.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29627" width="1" height="1"&gt;</description></item><item><title>Shaving 30% Off Setup Size (+Upgrading to SHFB 1.8.0.3)</title><link>http://community.sharpdevelop.net/blogs/christophwille/archive/2010/02/12/shaving-30-off-setup-size-upgrading-to-shfb-1-8-0-3.aspx</link><pubDate>Fri, 12 Feb 2010 17:52:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29626</guid><dc:creator>ChristophWille</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;This blog post announces two major changes for SharpDevelop 3.2: a setup size reduction from 21.1MB down to 14.6MB (a clean 30% less than before), and an upgrade of Sandcastle Help File Builder support to version 1.8.0.3.&lt;/p&gt;
&lt;p&gt;So how did we shrink the setup? Let&amp;#39;s look at some sizes first:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/christophwille/images/29622/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;Revision 5493 is before the upgrade of SHFB support (happened in 5499), and 5500 is the latest setup build - with additional tweaks. So what are the tweaks? &lt;/p&gt;
&lt;p&gt;Basically, we had a look at feature usage. Like &amp;quot;How many people actually know that we are shipping the WiX *.chm documentation with SharpDevelop?&amp;quot; or &amp;quot;How many people actually generate documentation chm files from XML comments?&amp;quot;. Turns out that the answer is &amp;quot;not too many&amp;quot;.&lt;/p&gt;
&lt;p&gt;The delta of 5499 to 5500 shows the effect of the WiX help documentation. And 5493 to 5499 the delta of the old release of &lt;a href="http://shfb.codeplex.com/"&gt;SHFB&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Which brings me to the upgraded functionality: we had a 1.7 release in the box, and 1.8.0.3 uses a different project file format. We had to upgrade that for &amp;quot;Build documentation...&amp;quot; (project context menu) to work properly with the new release.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/christophwille/images/29623/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;If you don&amp;#39;t have &lt;a href="http://shfb.codeplex.com/"&gt;SHFB&lt;/a&gt; on your computer (which is now the default after installing SharpDevelop), you will see the following dialog:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/christophwille/images/29624/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;This dialog is now standardized (we haven&amp;#39;t installed &lt;a href="http://tortoisesvn.net/"&gt;TortoiseSVN&lt;/a&gt; in the past either). Simply follow the link, install the latest version, and you are good to go (even without restarting SharpDevelop, we perform the &amp;quot;SHFB installed?&amp;quot; check on the fly):&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/christophwille/images/29625/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;Note that we produce a valid .shfbproj file with a reference to the project you just had open.&lt;/p&gt;
&lt;p&gt;So why are we shipping some stuff in the box and some not? That mostly depends on how deeply integrated a feature is in the IDE (well, after all that is short for integrated development environment). We have to have control over certain tools and the version being used. In some cases we can leave it up to the user to install it if needed, like F# support, Subversion support, FxCop or StyleCop support, or now documentation generation.&lt;/p&gt;
&lt;p&gt;Lean &amp;amp; mean is the new green.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29626" width="1" height="1"&gt;</description></item><item><title>F# Interactive - SharpDevelop 3.2 vs SharpDevelop 4.0</title><link>http://community.sharpdevelop.net/blogs/christophwille/archive/2010/02/12/f-interactive-sharpdevelop-3-2-vs-sharpdevelop-4-0.aspx</link><pubDate>Fri, 12 Feb 2010 15:38:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29620</guid><dc:creator>ChristophWille</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;SharpDevelop wraps F# Interactive (fsi.exe) in a pad of its own. For SharpDevelop 3.2, it looks like this:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/christophwille/images/29618/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;You type the code you want to evaluate in a single-line textbox on top of the fsi.exe output. &lt;/p&gt;
&lt;p&gt;With revision 5498 (part of SharpDevelop 4.0), &lt;a href="http://community.sharpdevelop.net/blogs/danielgrunwald/default.aspx"&gt;Daniel&lt;/a&gt; reused &lt;a href="http://community.sharpdevelop.net/blogs/siegfried_pammer/default.aspx"&gt;Siegfried&lt;/a&gt;&amp;#39;s approach for the debugger console to make F# Interactive a lot more compelling:&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/photos/christophwille/images/29619/original.aspx" border="0" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;You type right inside REPL. Way more useful!&lt;/p&gt;
&lt;p&gt;Boot note: In revision 5494, we ported the F# backend binding from F# (yes, the F# binding was written in F#) to C#. The main reason was that requiring F# - which is not part of the basic .NET installation - caused us problems (again) with the automated build.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29620" width="1" height="1"&gt;</description></item><item><title>Getting Started With SDR</title><link>http://community.sharpdevelop.net/blogs/sharpdevelopreports/archive/2010/01/13/getting-started-with-sdr.aspx</link><pubDate>Wed, 13 Jan 2010 14:19:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29284</guid><dc:creator>Peter Forstmeier</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;For those of you that haven&amp;#39;t followed the development of SDR in the past, a quick introduction on how to get started.&lt;/p&gt;
&lt;p&gt;There is a Wiki dedicated to SDR: &lt;a href="http://sharpdevelopreports.net/"&gt;http://sharpdevelopreports.net/&lt;/a&gt;&amp;nbsp;(please note that it hasn&amp;#39;t been updated yet for the fact that SDR is now back in the fold with SharpDevelop)&lt;/p&gt;
&lt;p&gt;It contains a &lt;a href="http://sharpdevelopreports.net/FeatureTour.ashx" class="null"&gt;feature tour&lt;/a&gt; (with screenshots) to give you an idea how to get up and running quickly. I&amp;#39;d also recommend reading the &lt;a href="http://community.sharpdevelop.net/blogs/sharpdevelopreports/archive/2009/10/05/what-s-new-in-sharpdevelop-reports-3-beta.aspx" class="null"&gt;what&amp;#39;s new blog post from the SDR beta&lt;/a&gt;, as it contains information on the newly added functionality (such as expression support).&lt;/p&gt;
&lt;p&gt;Speaking of support: there is a &lt;a href="http://community.sharpdevelop.net/forums/44.aspx" class="null"&gt;dedicated forum for SDR&lt;/a&gt; on our community site, please let me know about problems, ideas, fixes et al there!&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29284" width="1" height="1"&gt;</description></item><item><title>SharpDevelop Reports Re-Integrated Into SharpDevelop</title><link>http://community.sharpdevelop.net/blogs/sharpdevelopreports/archive/2010/01/05/sharpdevelop-reports-re-integrated-into-sharpdevelop.aspx</link><pubDate>Tue, 05 Jan 2010 22:18:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29283</guid><dc:creator>Peter Forstmeier</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;As of today, SharpDevelop Reports (SDR) is once again an integral part of SharpDevelop!&lt;/p&gt;
&lt;p&gt;It will be shipped with SharpDevelop 3.2 (~spring 2010), but it is already available on the &lt;a href="http://build.sharpdevelop.net/BuildArtefacts/" class="null"&gt;build server&lt;/a&gt; as part of the SharpDevelop integration builds. Please note that the standalone designer build is no longer available on the build server.&lt;/p&gt;
&lt;p&gt;Sample reports can be found in the source download of SharpDevelop in the folder Samples\SharpDevelopReports.&lt;/p&gt;
&lt;p&gt;Upcoming changes before the CTP of SharpDevelop 3.2: iTextSharp will be updated to version 5.0, and we no longer include the source code for it in the repository (only as a zip in the vendor directory, which is not part of the source download).&lt;/p&gt;
&lt;p&gt;Next tasks: more samples, more documentation, bug fixing.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29283" width="1" height="1"&gt;</description></item><item><title>IronRuby Integration Update</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/12/30/IronRubyIntegrationUpdate.aspx</link><pubDate>Wed, 30 Dec 2009 14:24:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:29142</guid><dc:creator>MattWard</dc:creator><slash:comments>1</slash:comments><description>&lt;p&gt;Support for IronRuby in SharpDevelop has moved on since the 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2009/10/04/IronRubyIntegrationInSharpDevelop31.aspx"&gt;last alpha release of the IronRuby addin&lt;/a&gt;. This addin now ships 
    with SharpDevelop 3.2 which is available to download from the 
    &lt;a href="http://build.sharpdevelop.net/buildartefacts/"&gt;build 
    server&lt;/a&gt;. The main new features are support for IronRuby 1.0 RC 1 
    and the ability to debug IronRuby applications.&lt;/p&gt;
&lt;h2&gt;New Features&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Windows Forms designer support now complete&lt;/li&gt;
&lt;li&gt;Converting entire C# and VB.NET projects to IronRuby.&lt;/li&gt;
&lt;li&gt;Debugger support for IronRuby applications.&lt;/li&gt;
&lt;li&gt;Smart indenting for IronRuby code.&lt;/li&gt;
&lt;li&gt;IronRuby 1.0 RC 1 support.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Currently there is no support for IronRuby code completion.&lt;/p&gt;
&lt;p&gt;Now we will take a look at some of the new features in more 
    depth.&lt;/p&gt;
&lt;h2&gt;Running an IronRuby Application&lt;/h2&gt;
&lt;p&gt;After you create an IronRuby application you can run it 
    immediately without having to edit the project options as you did 
    previously. The project templates have been updated so that 
    everything is ready to go straight away. Simply select &lt;b&gt;Run&lt;/b&gt; 
    from the &lt;b&gt;Debug&lt;/b&gt; menu to run your application with the 
    IronRuby console.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Debug run menu option" src="http://community.sharpdevelop.net/photos/mattward/images/original/DebugRunMenuOption.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Debugging an IronRuby Application&lt;/h2&gt;
&lt;p&gt;In order to get the debugger to work well when debugging an 
    IronRuby application you should change the debugger options. To 
    open the debugger options select &lt;b&gt;Options&lt;/b&gt; from the 
    &lt;b&gt;Tools&lt;/b&gt; menu, then select the &lt;b&gt;Debugging&lt;/b&gt; category. Only 
    the &amp;#39;Just My Code&amp;#39; feature should be selected and 
    everything else should be unselected, as shown in the screenshot 
    below.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Debugger options when debugging an IronRuby application" src="http://community.sharpdevelop.net/photos/mattward/images/original/IronRubyDebuggerOptions.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;You can set your breakpoints in the normal way either by 
    clicking in the left hand margin of the text editor or by selecting 
    &lt;b&gt;Toggle Breakpoint&lt;/b&gt; from the &lt;b&gt;Debug&lt;/b&gt; menu.&lt;/p&gt;
&lt;p&gt;Selecting &lt;b&gt;Run&lt;/b&gt; from the &lt;b&gt;Debug&lt;/b&gt; menu will run your 
    IronRuby application under the debugger. Alternatively you can 
    select &lt;b&gt;Run&lt;/b&gt; from the &lt;b&gt;Ruby&lt;/b&gt; menu which will run the code 
    currently active text editor window. Selecting either of these will 
    run the IronRuby console in debug mode with SharpDevelop&amp;#39;s 
    debugger.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Breakpoint hit in IronRuby application" src="http://community.sharpdevelop.net/photos/mattward/images/original/DebuggingIronRubyCode.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Converting a C# or VB.NET Project to IronRuby&lt;/h2&gt;
&lt;p&gt;To convert a VB.NET or C# project to IronRuby open the project 
    and then select &lt;b&gt;Convert from C# to Ruby&lt;/b&gt; or &lt;b&gt;Convert from 
    VB.NET to Ruby&lt;/b&gt; from the &lt;b&gt;Project&lt;/b&gt; menu.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Convert project to Ruby menu item" src="http://community.sharpdevelop.net/photos/mattward/images/original/ConvertProjectToRubyMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Extra Ruby Libraries&lt;/h2&gt;
&lt;p&gt;The 
    &lt;a href="http://ironruby.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=35312#DownloadId=93832"&gt;IronRuby 1.0 RC 1 download&lt;/a&gt; from 
    &lt;a href="http://ironruby.codeplex.com"&gt;codeplex&lt;/a&gt; includes extra 
    Ruby libraries that are not shipping with SharpDevelop. If you want 
    to use these libraries then download the IronRuby zip file and copy 
    the &lt;b&gt;lib&lt;/b&gt; folder to the IronRuby addin folder:&lt;/p&gt;
&lt;p&gt;C:\Program 
    Files\SharpDevelop\3.0\AddIns\AddIns\BackendBindings\RubyBinding&lt;/p&gt;
&lt;p&gt;The IronRuby console (ir.exe) is configured to look in the 
    &lt;b&gt;lib&lt;/b&gt; subfolder by information in the ir.exe.config file:&lt;/p&gt;
&lt;pre&gt;&amp;lt;options&amp;gt; &lt;br /&gt;   &amp;lt;set language=&amp;#39;Ruby&amp;#39; option=&amp;#39;LibraryPaths&amp;#39; value=&amp;#39;lib\IronRuby;lib\Ruby\site_ruby\1.8;lib\Ruby\site_ruby;lib\Ruby\1.8&amp;#39;/&amp;gt; &lt;br /&gt;&amp;lt;/options&amp;gt;&lt;/pre&gt;
&lt;p&gt;If you want to put these Ruby libraries somewhere else then the 
    ir.exe.config file should be modified.&lt;/p&gt;
&lt;h2&gt;IronRuby Downloads&lt;/h2&gt;
&lt;p&gt;&lt;a href="http://ironruby.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=35312#DownloadId=93832"&gt;IronRuby 1.0 RC 1 from Codeplex&lt;/a&gt;&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=29142" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Ruby/default.aspx">Ruby</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronRuby/default.aspx">IronRuby</category></item><item><title>What’s New in SharpDevelop Reports 3 Beta</title><link>http://community.sharpdevelop.net/blogs/sharpdevelopreports/archive/2009/10/05/what-s-new-in-sharpdevelop-reports-3-beta.aspx</link><pubDate>Mon, 05 Oct 2009 16:19:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:28174</guid><dc:creator>Peter Forstmeier</dc:creator><slash:comments>1</slash:comments><description>&lt;p&gt;&lt;strong&gt;Features:&lt;/strong&gt;&lt;/p&gt;
&lt;p&gt;&lt;strong&gt;&lt;/strong&gt;&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;The Designer is using the infrastructure from Windows.Forms.Designer&lt;/li&gt;
&lt;li&gt;Run Expressions inside a Report; based on the work of&amp;nbsp; &lt;a href="http://irony.codeplex.com/" class="null"&gt;Irony&lt;/a&gt; and &lt;a href="http://simpleexpressioneval.codeplex.com/" class="null"&gt;Simpleexpressionevaluator&lt;/a&gt;&lt;/li&gt;
&lt;li&gt;UnitTests for many&amp;nbsp; (increasing number) of Classes &lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;The Designer in Action:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_5.jpg"&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_1.jpg"&gt;&lt;img src="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_1.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;TextEditor, useful to enter some text and/or expressions:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_2.jpg"&gt;&lt;img src="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_2.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="text-decoration:underline;"&gt;&lt;span style="color:#0066cc;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="color:#0066cc;"&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;&lt;span style="text-decoration:underline;"&gt;&lt;span style="color:#0066cc;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;span style="text-decoration:underline;"&gt;&lt;span style="color:#0066cc;"&gt;&lt;/span&gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;A very simple report in List layout with PageNumber in the PageFooter section and Aggregate function count() in ReportFooter:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_3.jpg"&gt;&lt;img src="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_3.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;Some more functions:&lt;br /&gt;Line 1 (middle):&amp;nbsp;&amp;nbsp;&amp;nbsp;nothing to evaluate &amp;ndash; (right) concat two fields&lt;br /&gt;Line2 (middle and right):&amp;nbsp; Userfunctions&lt;br /&gt;Line 3 (middle and right) :&amp;nbsp;Globalfunctions&lt;br /&gt;Line 4 :&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; show parameters inside report, useful for queries&lt;br /&gt;Line 5:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; simple calculation&lt;br /&gt;Line 6:&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; etc, some more functions&lt;/p&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_4.jpg"&gt;&lt;img src="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_4.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;The Result:&lt;/p&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_5.jpg"&gt;&lt;img src="http://community.sharpdevelop.net/blogs/sharpdevelopreports/Designer_5.jpg" border="0" alt="" /&gt;&lt;/a&gt;&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=28174" width="1" height="1"&gt;</description></item><item><title>IronRuby Integration in SharpDevelop 3.1</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/10/04/IronRubyIntegrationInSharpDevelop31.aspx</link><pubDate>Sun, 04 Oct 2009 12:32:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:28157</guid><dc:creator>MattWard</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;Support for 
    &lt;a href="http://ironruby.codeplex.com/Release/ProjectReleases.aspx?ReleaseId=30916"&gt;IronRuby 0.9.1&lt;/a&gt; is now available for 
    &lt;a href="http://sourceforge.net/projects/sharpdevelop/files/SharpDevelop%203.x/3.1/SharpDevelop_3.1.0.4977_Setup.msi/download"&gt;SharpDevelop 3.1&lt;/a&gt;. The IronRuby addin is an early alpha preview 
    release/proof of concept and is not an official part of 
    SharpDevelop 3.1 so it is available as a separate download at the 
    end of this post.&lt;/p&gt;
&lt;h2&gt;Features&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;Code folding&lt;/li&gt;
&lt;li&gt;Syntax highlighting&lt;/li&gt;
&lt;li&gt;File and project templates for Console and Windows Forms 
      applications&lt;/li&gt;
&lt;li&gt;IronRuby Console window&lt;/li&gt;
&lt;li&gt;Windows Forms designer (limited)&lt;/li&gt;
&lt;li&gt;C# and VB.NET code conversion to Ruby (limited)&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;Please note that the forms designer and code conversion need a 
    lot more work.&lt;/p&gt;
&lt;h2&gt;Creating a Windows Application&lt;/h2&gt;
&lt;p&gt;Open up the new project dialog by selecting &lt;b&gt;New&lt;/b&gt; then 
    &lt;b&gt;Solution&lt;/b&gt; from the &lt;b&gt;File&lt;/b&gt; menu. Selecting the Ruby 
    category will show two project templates. One will create a Windows 
    console application and the other will create a Windows Forms 
    application.&lt;/p&gt;
&lt;p&gt;&lt;img alt="New IronRuby Project Dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/NewRubyProjectDialog.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;To run your application ensure the Program.rb file is in the 
    active text editor window then select &lt;b&gt;Run&lt;/b&gt; from the 
    &lt;b&gt;Ruby&lt;/b&gt; menu. This will run your code with the IronRuby console 
    (ir.exe). Alternatively you can run the application by selecting 
    &lt;b&gt;Run&lt;/b&gt; from the &lt;b&gt;Debug&lt;/b&gt; menu but you will first need to 
    configure the project options. Select &lt;b&gt;Project Options&lt;/b&gt; from 
    the &lt;b&gt;Project&lt;/b&gt; menu to open up the Debug project options.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Debug project options dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/RubyDebugProjectOptions.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;You will need to add &lt;b&gt;${ProjectDir}&lt;/b&gt; to the command line 
    arguments and working directory as shown above. The &lt;b&gt;-19&lt;/b&gt; 
    command line argument is used to enable Ruby 1.9 support otherwise 
    the IronRuby console will not be able to load any UTF-8 source code 
    files.&lt;/p&gt;
&lt;p&gt;Currently you cannot debug your code even if the -D command line 
    argument is specified.&lt;/p&gt;
&lt;p&gt;If you are running a windows app and nothing seems to happen 
    then open a command line window and run it from there. This way you 
    should see any errors reported from the IronRuby console.&lt;/p&gt;
&lt;h2&gt;Designing Windows Forms&lt;/h2&gt;
&lt;p&gt;The Windows Forms designer is still in its early stages so 
    please be warned that it may break the form&amp;#39;s code or worse. 
    The designer code generation is a lot more complete than the 
    designer loader so the designer will most likely fail to load all 
    controls into the designer.&lt;/p&gt;
&lt;p&gt;The designer can be opened in the usual way by opening the form 
    in the text editor and selecting the Design tab at the bottom of 
    the text editor. Once open in the designer you can add controls to 
    the form in the usual way from the Tools window. In the screenshot 
    below a label, text box and a button have been added.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Main form designed in designer" src="http://community.sharpdevelop.net/photos/mattward/images/original/RubyMainFormInDesigner.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Click the Source tab to view the generated code in the 
    InitializeComponents method. Make sure you do this before trying to 
    save the code.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Generated form code" src="http://community.sharpdevelop.net/photos/mattward/images/original/RubyMainFormGeneratedCode.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;IronRuby Console&lt;/h2&gt;
&lt;p&gt;To open the IronRuby Console window select &lt;b&gt;Tools&lt;/b&gt;, &lt;b&gt;Ruby 
    Console&lt;/b&gt; from the &lt;b&gt;View&lt;/b&gt; menu.&lt;/p&gt;
&lt;p&gt;&lt;img alt="View IronRuby Console menu item" src="http://community.sharpdevelop.net/photos/mattward/images/original/ViewIronRubyConsoleMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;When you type Ruby code into the IronRuby Console you will get 
    code completion when you press the &amp;#39;.&amp;#39; character.&lt;/p&gt;
&lt;p&gt;&lt;img alt="IronRuby Console code completion" src="http://community.sharpdevelop.net/photos/mattward/images/original/IronRubyConsoleCodeCompletion.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Code Folding&lt;/h2&gt;
&lt;p&gt;Code folding allows you to collapse regions of a class.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Folded ruby code" src="http://community.sharpdevelop.net/photos/mattward/images/original/RubyClassFolded.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Code Conversion&lt;/h2&gt;
&lt;p&gt;To convert VB.NET or C# to Ruby open the file you want to 
    convert and then select &lt;b&gt;Convert code to Ruby&lt;/b&gt; from the 
    &lt;b&gt;Tools&lt;/b&gt; menu.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Convert code to Ruby menu item" src="http://community.sharpdevelop.net/photos/mattward/images/original/ConvertCodeToRubyMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;The code conversion is limited to classes so it will not convert 
    an arbitary piece of code that is not inside a class. A C# class 
    being converted to Ruby is shown below.&lt;/p&gt;
&lt;p&gt;&lt;img alt="C# code before converting to Ruby" src="http://community.sharpdevelop.net/photos/mattward/images/original/CSharpCodeBeforeConversionToRuby.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="Converted Ruby code" src="http://community.sharpdevelop.net/photos/mattward/images/original/ConvertedCSharpClassAsRuby.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;The code conversion is still at an early stage of development so 
    it will fail on complicated classes.&lt;/p&gt;
&lt;h2&gt;Class View&lt;/h2&gt;
&lt;p&gt;Classes in the open solution will be displayed in the Class 
    browser (Select &lt;b&gt;Classes&lt;/b&gt; from the &lt;b&gt;View&lt;/b&gt; menu).&lt;/p&gt;
&lt;p&gt;&lt;img alt="Ruby class in Classes window" src="http://community.sharpdevelop.net/photos/mattward/images/original/RubyClassInClassWindow.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;From there you can double click a class or method and the text 
    editor will display the corresponding code.&lt;/p&gt;
&lt;h2&gt;Installing the IronRuby AddIn&lt;/h2&gt;
&lt;ol&gt;
&lt;li&gt;Rename the 
      &lt;a href="http://community.sharpdevelop.net/blogs/mattward/Ruby/IronRubyAddIn-0.1.zip"&gt;IronRubyAddIn-0.1.zip&lt;/a&gt; file to 
      &lt;b&gt;IronRubyAddIn-0.1.sdaddin&lt;/b&gt;.&lt;/li&gt;
&lt;li&gt;
        From the 
        &lt;b&gt;Tools&lt;/b&gt;
         menu select 
        &lt;b&gt;AddIn Manager&lt;/b&gt;
         .
&lt;p&gt;&lt;img alt="Tools AddIn Manager menu item" src="http://community.sharpdevelop.net/photos/mattward/images/original/ToolsAddInManagerMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
        Click the 
        &lt;b&gt;Install AddIn&lt;/b&gt;
         button.
&lt;p&gt;&lt;img alt="AddIn Manager dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/AddInManagerDialog.aspx" /&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;
        In the Open File Dialog browse to the 
        &lt;b&gt;IronRubyAddIn-0.1.sdaddin&lt;/b&gt;
         file and click the 
        &lt;b&gt;Open&lt;/b&gt;
         button.
&lt;p&gt;&lt;img alt="AddIn installed confirmation dialog." src="http://community.sharpdevelop.net/photos/mattward/images/original/IronRubyAddInInstalledDialog.aspx" /&gt;&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;Click the &lt;b&gt;Close&lt;/b&gt; button.&lt;/li&gt;
&lt;li&gt;Restart SharpDevelop.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Ruby Links&lt;/h2&gt;
&lt;p&gt;Some of the Ruby tutorials and links used whilst creating the 
    IronRuby addin.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;a href="http://www.ruby-lang.org/en/documentation/"&gt;Ruby 
      documentation&lt;/a&gt;.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.sapphiresteel.com/The-Book-Of-Ruby"&gt;Book 
      of Ruby&lt;/a&gt; by Huw Collingbourne.&lt;/li&gt;
&lt;li&gt;&lt;a href="http://www.codeplex.com/IronRuby"&gt;IronRuby 
      homepage&lt;/a&gt;.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Downloads&lt;/h2&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/Ruby/IronRubyAddIn-0.1.zip"&gt;IronRubyAddIn0.1.zip&lt;/a&gt;&lt;/p&gt;
&lt;p&gt;&lt;a href="http://community.sharpdevelop.net/blogs/mattward/Ruby/IronRubyAddIn-0.1-src.zip"&gt;IronRubyAddIn0.1-src.zip&lt;/a&gt;&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=28157" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Ruby/default.aspx">Ruby</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronRuby/default.aspx">IronRuby</category></item><item><title>IronPython Auto-Indent</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/09/30/IronPythonAutoIndent.aspx</link><pubDate>Wed, 30 Sep 2009 15:36:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:28113</guid><dc:creator>MattWard</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;Python auto-indentation has now been added to 
    &lt;a href="http://build.sharpdevelop.net/BuildArtefacts/"&gt;
    SharpDevelop 3.1 in revision 5007&lt;/a&gt;. The latest SharpDevelop 
    builds can be downloaded from the 
    &lt;a href="http://build.sharpdevelop.net/BuildArtefacts/"&gt;build 
    server&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;The indentation will be increased after a line ending with the 
    colon character, such as a method declaration. After typing in a 
    pass or return statement the indentation will be decreased on the 
    following line.&lt;/p&gt;
&lt;p&gt;&lt;img alt="IronPython auto-indentation" src="http://community.sharpdevelop.net/photos/mattward/images/original/IronPythonSmartIndent.aspx" /&gt;&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=28113" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Python/default.aspx">Python</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronPython/default.aspx">IronPython</category></item><item><title>IronPython Form Resources</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/09/28/IronPythonFormResources.aspx</link><pubDate>Mon, 28 Sep 2009 15:39:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:28083</guid><dc:creator>MattWard</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;Getting an IronPython WinForm to display an icon or image can be 
    done in different ways. Here we will take a look at the following 
    ways to add a background image to the main form of an IronPython 
    WinForms application.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;Using the SharpDevelop forms designer.&lt;/li&gt;
&lt;li&gt;Loading an image embedded as a resource in a separate 
      assembly.&lt;/li&gt;
&lt;li&gt;Loading an image from disk.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Using the SharpDevelop Forms Designer&lt;/h2&gt;
&lt;p&gt;The SharpDevelop forms designer can be used to add resources to 
    a form in the same way for other languages such as C# or VB.NET. It 
    supports adding local form resources but not project resources 
    currently.&lt;/p&gt;
&lt;p&gt;After 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2009/05/12/IronPython2FormsDesigner.aspx"&gt;creating a new IronPython Windows Application&lt;/a&gt;, open the 
    MainForm in the designer. In the Properties window select the 
    BackgroundImage property of the MainForm and click the browse 
    button.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Form&amp;#39;s BackgroundImage property in Properties window" src="http://community.sharpdevelop.net/photos/mattward/images/original/MainFormBackgroundImageProperty.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Select Local Resource then click the Import button to browse to 
    the image file you are going to use.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Local resource selected in resource dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/SelectLocalResourceDialog.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Click OK to close the dialog. The background image should then 
    be displayed in the form. If you select Run from the Debug menu 
    your application will be compiled and the main form should be 
    displayed with your image.&lt;/p&gt;
&lt;p&gt;Now let us take a look at the code generated for the form.&lt;/p&gt;
&lt;pre&gt;import System.Drawing &lt;br /&gt;import System.Windows.Forms &lt;br /&gt; &lt;br /&gt;from System.Drawing import * &lt;br /&gt;from System.Windows.Forms import * &lt;br /&gt; &lt;br /&gt;class MainForm(Form): &lt;br /&gt; def __init__(self): &lt;br /&gt;  self.InitializeComponent() &lt;br /&gt;  &lt;br /&gt; def InitializeComponent(self): &lt;br /&gt;  resources = System.Resources.ResourceManager(&amp;quot;PythonWinApp.MainForm&amp;quot;, System.Reflection.Assembly.GetEntryAssembly()) &lt;br /&gt;  self.SuspendLayout() &lt;br /&gt;  #  &lt;br /&gt;  # MainForm &lt;br /&gt;  #  &lt;br /&gt;  self.BackgroundImage = resources.GetObject(&amp;quot;$this.BackgroundImage&amp;quot;) &lt;br /&gt;  self.ClientSize = System.Drawing.Size(284, 264) &lt;br /&gt;  self.Name = &amp;quot;MainForm&amp;quot; &lt;br /&gt;  self.ResumeLayout(False)&lt;/pre&gt;
&lt;p&gt;The generated code for the InitializeComponent method is nearly 
    the same as the code generated by the forms designer when adding a 
    resource to a C# form. The generated C# code is shown below.&lt;/p&gt;
&lt;pre&gt;  private void InitializeComponent() &lt;br /&gt;  { &lt;br /&gt;   System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(MainForm)); &lt;br /&gt;   this.SuspendLayout(); &lt;br /&gt;   //  &lt;br /&gt;   // MainForm &lt;br /&gt;   //  &lt;br /&gt;   this.AutoScaleDimensions = new System.Drawing.SizeF(6F, 13F); &lt;br /&gt;   this.AutoScaleMode = System.Windows.Forms.AutoScaleMode.Font; &lt;br /&gt;   this.BackgroundImage = ((System.Drawing.Image)(resources.GetObject(&amp;quot;$this.BackgroundImage&amp;quot;))); &lt;br /&gt;   this.ClientSize = new System.Drawing.Size(284, 264); &lt;br /&gt;   this.Name = &amp;quot;MainForm&amp;quot;; &lt;br /&gt;   this.Text = &amp;quot;WinApp&amp;quot;; &lt;br /&gt;   this.ResumeLayout(false); &lt;br /&gt;  } &lt;/pre&gt;
&lt;p&gt;The C# form uses the ComponentResourceManager class and 
    typeof(MainForm) to get access to the embedded resource. The 
    IronPython form uses the ResourceManager class instead. If we try 
    to use a ComponentResourceManager in the IronPython application by 
    replacing the resources line with:&lt;/p&gt;
&lt;pre&gt;resources = System.ComponentModel.ComponentResourceManager(clr.GetClrType(MainForm))&lt;/pre&gt;
&lt;p&gt;The application will throw an NotSupportedException when it is 
    run with an error message saying that &amp;quot;The invoked member is 
    not supported in a dynamic assembly.&amp;quot;. The line of code that 
    actually causes this error is the resources.GetObject() line. So we 
    cannot read a resource from a dynamic assembly, but even if we 
    could the resources are not actually embedded in the assembly that 
    contains the code for the MainForm. When the IronPython application 
    is compiled two files are generated an executable and a dll. The 
    dll is generated using IronPython&amp;#39;s ClrModule.CompileModules 
    which is used to compile all the IronPython code into an assembly. 
    The exe is generated using several Reflection.Emit calls and its 
    only task is to call PythonOps.InitializeModule passing the 
    filename of the generated dll. If you look at the exe using 
    Reflector you can see a PythonMain class with a Main method similar 
    to that shown below.&lt;/p&gt;
&lt;pre&gt;[STAThread] &lt;br /&gt;public static int Main() &lt;br /&gt;{ &lt;br /&gt;    string[] references = new string[] { &amp;quot;IronPython, Version=2.0.0.0, Culture=neutral, PublicKeyToken=31bf3856ad364e35&amp;quot;, &lt;br /&gt;        &amp;quot;mscorlib, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&amp;quot;, &lt;br /&gt;        &amp;quot;System.Data, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&amp;quot;, &lt;br /&gt;        &amp;quot;System, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&amp;quot;, &amp;quot;System.Drawing, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b03f5f7f11d50a3a&amp;quot;, &lt;br /&gt;        &amp;quot;System.Windows.Forms, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&amp;quot;, &lt;br /&gt;        &amp;quot;System.Xml, Version=2.0.0.0, Culture=neutral, PublicKeyToken=b77a5c561934e089&amp;quot; }; &lt;br /&gt;    return PythonOps.InitializeModule(Assembly.LoadFile(Path.GetFullPath(&amp;quot;PythonWinApp.dll&amp;quot;)), &amp;quot;Program&amp;quot;, references); &lt;br /&gt;} &lt;/pre&gt;
&lt;p&gt;With Reflector you can also see that the form resources are 
    embedded into the executable and not the dll. So this means our 
    form code needs to load the resources from the executable. This is 
    done in the generated form designer code by passing the entry 
    assembly, which will be the executable containing the resources, to 
    the ResourceManager as shown below.&lt;/p&gt;
&lt;pre&gt;resources = System.Resources.ResourceManager(&amp;quot;PythonWinApp.MainForm&amp;quot;, System.Reflection.Assembly.GetEntryAssembly())&lt;/pre&gt;
&lt;p&gt;The above code will not work if you try to run your application 
    with the IronPython Console (ipy.exe) since the entry assembly will 
    actually be ipy.exe. The following sections will look at using form 
    resources that can be used when running your code with ipy.exe.&lt;/p&gt;
&lt;h2&gt;Loading an Image from an Assembly&lt;/h2&gt;
&lt;p&gt;Here we will have two projects, one with the IronPython form and 
    one with the image resource. In the resource project you have a 
    choice of whether you are going to put your image inside a resource 
    file (.resx) or simply add it to the project and set its Build 
    Action to EmbeddedResource. For now let us add the image to a 
    resource file. Add a new resource file and then open it into the 
    editor. Add your image to the resource file by right clicking and 
    selecting Add files...&lt;/p&gt;
&lt;p&gt;&lt;img alt="Add files to resx menu item" src="http://community.sharpdevelop.net/photos/mattward/images/original/AddFilesToResourcesContextMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Finally compile your resource assembly.&lt;/p&gt;
&lt;p&gt;From your IronPython WinForms project you can load the image 
    from this resource assembly with code similar to the following:&lt;/p&gt;
&lt;pre&gt;class MainForm(Form): &lt;br /&gt; def __init__(self): &lt;br /&gt;  self.InitializeComponent() &lt;br /&gt;  fileName = System.IO.Path.GetFullPath(&amp;quot;Resources\\ResourceLibrary.dll&amp;quot;) &lt;br /&gt;  assembly = System.Reflection.Assembly.LoadFile(fileName) &lt;br /&gt;  resources = System.Resources.ResourceManager(&amp;quot;ResourceLibrary.Resources&amp;quot;, assembly) &lt;br /&gt;  self.BackgroundImage = resources.GetObject(&amp;quot;SharpDevelop&amp;quot;) &lt;br /&gt;  &lt;br /&gt; def InitializeComponent(self): &lt;br /&gt;  pass&lt;/pre&gt;
&lt;p&gt;The code loads the resource assembly (ResourceLibrary.dll) by 
    assuming it is in the Resources subfolder off the current working 
    directory. The name of the embedded resource and the loaded 
    assembly are then passed to the ResourceManager. Finally the 
    SharpDevelop image is read from the resource manager via the 
    GetObject method. This code will work with both ipy.exe and when 
    the application is compiled but it uses the current working 
    directory is used to determine the location of the resource 
    assembly. An improvement is to use a path relative to the 
    MainForm.py file itself.&lt;/p&gt;
&lt;pre&gt;class MainForm(Form): &lt;br /&gt; def __init__(self): &lt;br /&gt;  self.InitializeComponent() &lt;br /&gt;  directoryName = System.IO.Path.GetDirectoryName(__file__) &lt;br /&gt;  fileName = System.IO.Path.Combine(directoryName, &amp;quot;Resources\ResourceLibrary.dll&amp;quot;) &lt;br /&gt;  assembly = System.Reflection.Assembly.LoadFile(fileName) &lt;br /&gt;  resources = System.Resources.ResourceManager(&amp;quot;ResourceLibrary.Resources&amp;quot;, assembly) &lt;br /&gt;  self.BackgroundImage = resources.GetObject(&amp;quot;SharpDevelop&amp;quot;) &lt;br /&gt;  &lt;br /&gt; def InitializeComponent(self): &lt;br /&gt;  pass&lt;/pre&gt;
&lt;p&gt;With this modified code we get the full filename including its 
    path to the MainForm.py file by using the __file__ constant. Then 
    we can get the full path to the resource assembly relative to the 
    MainForm.py file. This code will work with ipy.exe but not if the 
    application is compiled. With the compiled application the __file__ 
    constant returns the name of the file without its extension and 
    without any path information.&lt;/p&gt;
&lt;h2&gt;Loading an Image from Disk&lt;/h2&gt;
&lt;p&gt;Here we assume the image (SharpDevelop.png) is in a Resources 
    subfolder relative to the MainForm.py file.&lt;/p&gt;
&lt;pre&gt;class MainForm(Form): &lt;br /&gt; def __init__(self): &lt;br /&gt;  self.InitializeComponent() &lt;br /&gt;  directoryName = System.IO.Path.GetDirectoryName(__file__) &lt;br /&gt;  fileName = System.IO.Path.Combine(directoryName, &amp;quot;Resources\\SharpDevelop.png&amp;quot;) &lt;br /&gt;  self.BackgroundImage = System.Drawing.Bitmap(fileName) &lt;br /&gt;  &lt;br /&gt; def InitializeComponent(self): &lt;br /&gt;  pass&lt;/pre&gt;
&lt;p&gt;Here the code simply determines the full path to the image and 
    then loads it into a Bitmap. The Bitmap is then used to set the 
    form&amp;#39;s background image. Again this code will work with 
    ipy.exe but not if the application is compiled.&lt;/p&gt;
&lt;p&gt;Example code for all the ways of using resources in IronPython 
    can be found in the 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/Python/IronPythonFormResourceExamples.zip"&gt;
    IronPythonFormResourceExamples.zip&lt;/a&gt; file.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=28083" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Python/default.aspx">Python</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronPython/default.aspx">IronPython</category></item><item><title>New debugger features implemented during #d^3</title><link>http://community.sharpdevelop.net/blogs/martinkonicek/archive/2009/09/10/new-debugger-features-implemented-during-d-3.aspx</link><pubDate>Thu, 10 Sep 2009 00:46:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:27881</guid><dc:creator>martinkonicek</dc:creator><slash:comments>1</slash:comments><description>&lt;p&gt;During &lt;a target="_self" title="#d^3" href="http://laputa.sharpdevelop.net/SharpDevelopDeveloperDays2009.aspx"&gt;SharpDevelop developer days 2009&lt;/a&gt; we implemented new debugger features to appear in SharpDevelop 4:&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Debugger tooltips for IEnumerable&lt;br /&gt;&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;img alt="Debugger tooltips for IEnumerable" src="http://community.sharpdevelop.net/blogs/martinkonicek/images/IEnumerableTooltips.png" height="462" width="604" /&gt;&lt;/p&gt;
&lt;p&gt;The individual items of IEnumerable can be expanded normally.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Text visualizer&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;There is a new visualizer chooser in debugger tooltips.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Choose visualizer from debugger tooltips" src="http://community.sharpdevelop.net/blogs/martinkonicek/images/VisPicker.png" height="108" width="409" /&gt;&lt;/p&gt;
&lt;p&gt;For string values, Text and XML visualizers are available. Choosing &amp;quot;Text visualizer&amp;quot; shows a window:&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;img alt="Text visualizer" src="http://community.sharpdevelop.net/blogs/martinkonicek/images/TextVisualizer.png" height="334" width="575" /&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;XML visualizer&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;XML visualizer uses AvalonEdit to display syntax-highlighted xml. Folding (= node expanding/collapsing) and auto indentation will be implemented.&lt;/p&gt;
&lt;p&gt;&lt;img alt="XML visualizer" src="http://community.sharpdevelop.net/blogs/martinkonicek/images/XmlVisualizer.png" height="372" width="609" /&gt;&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=27881" width="1" height="1"&gt;</description></item><item><title>Profiling Unit Tests Made Easy</title><link>http://community.sharpdevelop.net/blogs/siegfried_pammer/archive/2009/09/02/profiling-unit-tests-made-easy.aspx</link><pubDate>Wed, 02 Sep 2009 14:20:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:27766</guid><dc:creator>siegi44</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;Although we had basic support for profiling unit tests in the &lt;a href="http://community.sharpdevelop.net/forums/p/9832/27232.aspx#27232"&gt;RC1 of SharpDevelop 3&lt;/a&gt;, it was very hard to use. The reason for this was that the profiler simply attached itself to the NUnit console runner used by SharpDevelop and recorded all calls, even the initialization of NUnit. This produced a large overhead of data.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/blogs/siegfried_pammer/profiler/post3/blogpost1.png" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;In SharpDevelop 3.1 rev. 4863 I changed the data processor a bit. The profiler now displays all unit tests as root nodes in the &amp;quot;Overview&amp;quot; tab and all NUnit initialization calls are removed from the data.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/blogs/siegfried_pammer/profiler/post3/blogpost2.png" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;As you can see, it is much easier find the information you need. This also works with multiple tests selected.&lt;/p&gt;
&lt;p&gt;Another feature I thought it could be useful for profiling in general is &amp;quot;Find references&amp;quot;. Simply right-click on a node in the tree view and select &amp;quot;Find references&amp;quot; from the context menu.&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/blogs/siegfried_pammer/profiler/post3/blogpost3.png" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img src="http://community.sharpdevelop.net/blogs/siegfried_pammer/profiler/post3/blogpost4.png" alt="" /&gt;&lt;/p&gt;
&lt;p&gt;I hope you like the changes and find it useful. If you have any questions or suggestions, please post them here.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=27766" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/siegfried_pammer/archive/tags/Profiler/default.aspx">Profiler</category></item><item><title>API Changes explained: Language Bindings and Project Bindings</title><link>http://community.sharpdevelop.net/blogs/siegfried_pammer/archive/2009/07/25/api-changes-explained-language-bindings-and-project-bindings.aspx</link><pubDate>Sat, 25 Jul 2009 12:20:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:27199</guid><dc:creator>siegi44</dc:creator><slash:comments>2</slash:comments><description>&lt;p style="font-size:9pt;"&gt;&lt;b&gt;Important note:&lt;/b&gt; The changes discussed in this post apply only to SharpDevelop 4.0.0.4537 and later revisions.&lt;/p&gt;
&lt;h2&gt;Why?&lt;/h2&gt;
&lt;p&gt;As you might have noticed, I am one of the &lt;a href="http://community.sharpdevelop.net/blogs/dsrbecky/archive/2009/04/24/accepted-gsoc-students.aspx"&gt;accepted Google Summer of Code 2009 students&lt;/a&gt;. While working on my project, the XAML binding, I had the idea of implementing an Outline Pad for XAML. After a short discussion with my mentor, we decided to add a general solution for implementing this functionality for C#, VB .NET, Boo, Windows Forms Designer and the (upcoming) WPF Designer too.&lt;/p&gt;
&lt;p&gt;For instance, normal backend bindings like the C#, VB .NET and Boo binding could display a tree of the current document structure with namespaces, classes, member variables, methods properties, etc. This would allow  fast physical restructuring of a file. With XAML you could easily move a part of the XAML tree to another location. Same would go for the Windows Forms and WPF Designer.&lt;/p&gt;
&lt;p&gt;So each language binding or display binding should be able to tell the outline pad what content it should display to the user. The existing &lt;i&gt;ILanguageBinding &lt;/i&gt;only represented a language from the point of view of the project system, there was no support for things like &lt;i&gt;code completion, formatting or highlighting.&lt;/i&gt; So I changed the name of the existing &lt;i&gt;ILanguageBinding &lt;/i&gt;to &amp;quot;IProjectBinding&amp;quot;.&lt;/p&gt;
&lt;h2&gt;The New Language Binding API&lt;/h2&gt;
&lt;p&gt;The new ILanguageBinding is not project-based, but file- or, to be more specific, ITextEditor-based. What does this mean? It simply means, that &lt;b&gt;every &lt;/b&gt;ITextEditor instance (that is, every file opened by the default text editor in SharpDevelop), gets its own ILanguageBinding instance. Furthermore, if you use the split-view functionality present in SharpDevelop, &lt;b&gt;both views get their own ILanguageBinding&lt;/b&gt; instance too. Please keep that in mind, when implementing your own language bindings.&lt;/p&gt;
&lt;p&gt;So let&amp;#39;s move on the practical part: In fact, the &amp;quot;API&amp;quot; only consists of one interface, plus wrappers for the SharpDevelop addin system, to make it easy for backend binding addins to provide their own language-specific implementation. We will discuss its structure first:&lt;/p&gt;
&lt;p&gt;&lt;b&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt;&amp;nbsp;&lt;/b&gt;&lt;span style="color:#ff0000;"&gt;interface&lt;/span&gt;&amp;nbsp;ILanguageBinding&lt;br /&gt;{&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;IFormattingStrategy FormattingStrategy {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#8b4513;"&gt;get&lt;/span&gt;;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;LanguageProperties Properties {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#8b4513;"&gt;get&lt;/span&gt;;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#ff0000;"&gt;void&lt;/span&gt;&amp;nbsp;&lt;b&gt;&lt;span style="color:#191970;"&gt;Attach&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;ITextEditor editor);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#ff0000;"&gt;void&lt;/span&gt;&amp;nbsp;&lt;b&gt;&lt;span style="color:#191970;"&gt;Detach&lt;/span&gt;&lt;/b&gt;();&lt;br /&gt;}
&lt;/p&gt;
&lt;p&gt;It is not very complex, but there are a few things to keep in mind:&lt;/p&gt;
&lt;p&gt;&lt;b&gt;&lt;span style="color:#191970;"&gt;Attach&lt;/span&gt;&lt;/b&gt; is called only once on every ILanguageBinding instance (before any other method calls).&lt;/p&gt;
&lt;p&gt;SharpDevelop will never Detach() and re-Attach() a language binding; instead, it will detach the old binding and attach a new instance. A new instance is created in the following situations:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;an ITextEditor is created by SharpDevelop,&lt;/li&gt;
&lt;li&gt;the filename, of the file being edited, has changed&lt;/li&gt;
&lt;li&gt;or the user switches to split-view mode.&lt;br /&gt;&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You can attach additional functionality like a custom highlighter or an IOutlineContentHost, to provide content displayed in the Outline pad, as mentioned at the beginning.&lt;/p&gt;
&lt;p&gt;If you override Attach, you should also override &lt;b&gt;&lt;span style="color:#191970;"&gt;Detach&lt;/span&gt;&lt;/b&gt;. It is called only once in the life-cycle of an ILanguageBinding instance:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;&lt;b&gt;when &lt;/b&gt;an ITextEditor is closed (disposed by SharpDevelop),&lt;/li&gt;
&lt;li&gt;&lt;b&gt;before &lt;/b&gt;a new language binding is attached, after the filename, of the file being edited, has changed. (So SharpDevelop disposes the old one before creating a new one.)&lt;/li&gt;
&lt;li&gt;&lt;b&gt;after &lt;/b&gt;switching from split-view to normal view mode, to dispose the second view, as it is not needed anymore.&lt;/li&gt;
&lt;/ul&gt;
&lt;p&gt;You should detach (and dispose) all services and additional functionality, added by your language binding, from the ITextEditor at this point.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;FormattingStrategy &lt;/b&gt;should return an instance of the IFormattingStrategy implementation for your language binding.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Properties &lt;/b&gt;should return a reference to the LanguageProperties implementation for your language binding.&lt;/p&gt;
&lt;h3&gt;Example: XamlLanguageBinding&lt;/h3&gt;
&lt;p&gt;I pasted the Attach and Detach method from the XamlLanguageBinding as a small example. Please note that adding custom syntax highlighting (in this case: XamlColorizer) and additional services, like IOutlineContentHost, requires a reference to the TextView of the AvalonEdit.TextEditor class. So this part can only be implemented for specific text editor controls.&lt;/p&gt;
&lt;p&gt;
&lt;b&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt;&amp;nbsp;&lt;/b&gt;&lt;span style="color:#a52a2a;"&gt;override&lt;/span&gt;&amp;nbsp;&lt;span style="color:#ff0000;"&gt;void&lt;/span&gt;&amp;nbsp;&lt;b&gt;&lt;span style="color:#191970;"&gt;Attach&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;ITextEditor editor)&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;b&gt;&lt;span style="color:#000000;"&gt;base&lt;/span&gt;&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;span style="color:#191970;"&gt;Attach&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;editor);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// try to access the ICSharpCode.AvalonEdit.Rendering.TextView&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// of this ITextEditor&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;b&gt;&lt;span style="color:#000000;"&gt;this&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;.&lt;/span&gt;textView = editor&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;b&gt;&lt;span style="color:#191970;"&gt;GetService&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;&lt;b&gt;&lt;span style="color:#008b8b;"&gt;typeof&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;TextView))&amp;nbsp;&lt;b&gt;&lt;span style="color:#008b8b;"&gt;as&lt;/span&gt;&amp;nbsp;&lt;/b&gt;TextView;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// if editor is not an AvalonEdit.TextEditor&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// GetService returns null&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#0000ff;"&gt;if&lt;/span&gt;&amp;nbsp;(textView !=&amp;nbsp;&lt;b&gt;&lt;span style="color:#000000;"&gt;null&lt;/span&gt;&lt;/b&gt;) {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;colorizer =&lt;b&gt;&amp;nbsp;&lt;span style="color:#008b8b;"&gt;new&lt;/span&gt;&amp;nbsp;&lt;span style="color:#191970;"&gt;XamlColorizer&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;editor, textView);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// attach the colorizer&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;textView&lt;span style="color:#006400;"&gt;.&lt;/span&gt;LineTransformers&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;b&gt;&lt;span style="color:#191970;"&gt;Add&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;colorizer);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// add the XamlOutlineContentHost, which manages the tree view&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;textView&lt;span style="color:#006400;"&gt;.&lt;/span&gt;Services&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;b&gt;&lt;span style="color:#191970;"&gt;AddService&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;&lt;b&gt;&lt;span style="color:#008b8b;"&gt;typeof&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;IOutlineContentHost),&amp;nbsp;&lt;b&gt;&lt;span style="color:#008b8b;"&gt;new&lt;/span&gt;&amp;nbsp;&lt;span style="color:#191970;"&gt;XamlOutlineContentHost&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;editor));&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;br /&gt;
}&lt;br /&gt;
&lt;br /&gt;
&lt;b&gt;&lt;span style="color:#0000ff;"&gt;public&lt;/span&gt;&amp;nbsp;&lt;/b&gt;&lt;span style="color:#a52a2a;"&gt;override&lt;/span&gt;&amp;nbsp;&lt;span style="color:#ff0000;"&gt;void&lt;/span&gt;&amp;nbsp;&lt;b&gt;&lt;span style="color:#191970;"&gt;Detach&lt;/span&gt;&lt;/b&gt;()&lt;br /&gt;
{&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;b&gt;&lt;span style="color:#000000;"&gt;base&lt;/span&gt;&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;span style="color:#191970;"&gt;Detach&lt;/span&gt;&lt;/b&gt;();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// if we added something before&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#0000ff;"&gt;if&lt;/span&gt;&amp;nbsp;(textView !=&amp;nbsp;&lt;span style="color:#000000;"&gt;null&lt;/span&gt;&amp;nbsp;&amp;amp;&amp;amp; colorizer !=&amp;nbsp;&lt;b&gt;&lt;span style="color:#000000;"&gt;null&lt;/span&gt;&lt;/b&gt;) {&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#008000;"&gt;// remove and dispose everything we added&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;textView&lt;span style="color:#006400;"&gt;.&lt;/span&gt;LineTransformers&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;b&gt;&lt;span style="color:#191970;"&gt;Remove&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;colorizer);&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;textView&lt;span style="color:#006400;"&gt;.&lt;/span&gt;Services&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;b&gt;&lt;span style="color:#191970;"&gt;RemoveService&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;&lt;b&gt;&lt;span style="color:#008b8b;"&gt;typeof&lt;/span&gt;&lt;/b&gt;&lt;span style="color:#006400;"&gt;(&lt;/span&gt;IOutlineContentHost));&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;colorizer&lt;span style="color:#006400;"&gt;.&lt;/span&gt;&lt;b&gt;&lt;span style="color:#191970;"&gt;Dispose&lt;/span&gt;&lt;/b&gt;();&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;}&lt;br /&gt;
}

&lt;/p&gt;
&lt;h2&gt;Nice, But How Do I Register My Language Binding With SharpDevelop?&lt;/h2&gt;
&lt;p&gt;Similar to all other parts of SharpDevelop, just add it to the addin path /SharpDevelop/Workbench/LanguageBindings like this:&lt;/p&gt;
&lt;p&gt;
&lt;span style="color:#8b008b;"&gt;&amp;lt;Path&amp;nbsp;&lt;span style="color:#ff0000;font-weight:normal;font-style:normal;"&gt;name&lt;/span&gt;=&lt;span style="color:#0000ff;font-weight:normal;font-style:normal;"&gt;&amp;quot;/SharpDevelop/Workbench/LanguageBindings&amp;quot;&lt;/span&gt;&amp;gt;&lt;/span&gt;&lt;br /&gt;
&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#8b008b;"&gt;&amp;lt;LanguageBinding&lt;/span&gt;&lt;br /&gt;
&lt;span style="color:#8b008b;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#ff0000;font-weight:normal;font-style:normal;"&gt;id&lt;/span&gt;=&lt;span style="color:#0000ff;font-weight:normal;font-style:normal;"&gt;&amp;quot;XAML&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="color:#8b008b;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#ff0000;font-weight:normal;font-style:normal;"&gt;class&lt;/span&gt;=&lt;span style="color:#0000ff;font-weight:normal;font-style:normal;"&gt;&amp;quot;ICSharpCode.XamlBinding.XamlLanguageBinding&amp;quot;&lt;/span&gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="color:#8b008b;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&lt;span style="color:#ff0000;font-weight:normal;font-style:normal;"&gt;extensions&lt;/span&gt;=&lt;span style="color:#0000ff;font-weight:normal;font-style:normal;"&gt;&amp;quot;.xaml&amp;quot;&lt;/span&gt;&amp;nbsp;/&amp;gt;&lt;/span&gt;&lt;br /&gt;
&lt;span style="color:#8b008b;"&gt;&amp;lt;/Path&amp;gt;&lt;/span&gt;&lt;/p&gt;
&lt;p&gt;short explanation:&lt;/p&gt;
&lt;p&gt;&lt;b&gt;id:&lt;/b&gt; The name of the LanguageBinding, must be unique, preferably the same as your project binding or code completion binding.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;class: &lt;/b&gt;The fully-qualified name of your language binding class.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;extensions: &lt;/b&gt;A semicolon-separated list of file extensions, that are handled by your language binding. Please note that multiple LanguageBindings can handle a file extension. But only the first non-null FormattingStrategy is used or only the first non-null LanguageProperties instance is used. You can control the order of the language bindings using the &lt;i&gt;insertbefore &lt;/i&gt;and &lt;i&gt;insertafter &lt;/i&gt;attributes.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Important:&lt;/b&gt; In the past you were able to register a formatting strategy by adding it to /AddIns/DefaultTextEditor/Formatter/, this was removed. Now the IFormattingStrategy gets set by overriding the FormattingStrategy property in the Language Binding implementation.&lt;/p&gt;
&lt;h3&gt;How To Access The Features From AddIns?&lt;/h3&gt;
&lt;p&gt;When dealing with text displayed inside a SharpDevelop text editor, the easiest way to do this is to use the ITextEditor interface. The active language binding can be accessed by using ITextEditor.Language property.&lt;/p&gt;
&lt;h3&gt;Project Bindings&lt;/h3&gt;
&lt;p&gt;I have not done any changes to the project binding API, except renaming everything. Project bindings are responsible for project management (reading project files, compilation management, etc.). XAML does not need its own project format (there is no .xamlproj ;-)), so I cannot provide an example and explain it to you, please take a look at existing project bindings such as &lt;i&gt;CSharpProjectBinding&lt;/i&gt;, &lt;i&gt;VBNetProjectBinding &lt;/i&gt;or &lt;i&gt;BooProjectBinding&lt;/i&gt;.&lt;/p&gt;
&lt;h3&gt;Conclusion&lt;/h3&gt;
&lt;p&gt;I think the language bindings make it easier to extend ITextEditor with language specific features and also allow other AddIns to access  these features. In my next post I will explain my work on the XAML binding more in detail and guide you through the features I implemented.&lt;/p&gt;
&lt;p&gt;If you have any questions concerning language bindings and these changes, please feel free to ask.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=27199" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/siegfried_pammer/archive/tags/XAML/default.aspx">XAML</category><category domain="http://community.sharpdevelop.net/blogs/siegfried_pammer/archive/tags/GSoC+2009/default.aspx">GSoC 2009</category><category domain="http://community.sharpdevelop.net/blogs/siegfried_pammer/archive/tags/Language+Bindings/default.aspx">Language Bindings</category></item><item><title>Debugger visualizers - a Google summer of code project</title><link>http://community.sharpdevelop.net/blogs/martinkonicek/archive/2009/06/29/first-post.aspx</link><pubDate>Mon, 29 Jun 2009 13:24:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:26945</guid><dc:creator>martinkonicek</dc:creator><slash:comments>1</slash:comments><description>&lt;p&gt;Hi,&lt;/p&gt;
&lt;p&gt;my name is Martin Konicek and starting this summer, I will be trying to make your debugging experience in SharpDevelop even better. This blog will be about my project for &lt;a href="http://socghop.appspot.com/org/home/google/gsoc2009/sharpdevelop"&gt;Google summer of code 2009&lt;/a&gt; - &lt;b&gt;Debugger visualizers&lt;/b&gt;. The exciting part is that I&amp;#39;ll be working on features that are not present in &lt;i&gt;any&lt;/i&gt; IDE today.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Motivation&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;The idea is to introduce new ways to let you observe the state of the program during debugging. For me, by far the most used debugger feature are the tooltips. The problem with tooltips is they never show you the data structure &amp;quot;as a whole&amp;quot;. Here we have two objects having a reference to each other:&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;img alt="Tooltips are not perfect" src="http://community.sharpdevelop.net/blogs/martinkonicek/images/tooltipProblem.png" width="518" height="459" /&gt;&lt;/p&gt;
&lt;p&gt;As we can see, the tooltips can be expanded forever, even if we have only two objects forming a loop - there is no easy was to tell this information just from the tooltips. Long ago, I was thinking how gain more &lt;i&gt;insight&lt;/i&gt; - what about displaying the objects in memory and references between them as an &lt;b&gt;oriented graph&lt;/b&gt;, updating live when stepping in the debugger? I wrote it as a hobby project, which gave me important lessons how not to do that.&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Object graph visualizer&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;I found out that SharpDevelop team had similar idea for Google summer of code, great! I applied, researched and wrote a prototype, which I sent to David Srbecky, the author of SharpDevelop debugger and my mentor. The prototype looked like this:&lt;/p&gt;
&lt;p&gt;&lt;img alt="Object graph visualizer prototype" src="http://community.sharpdevelop.net/blogs/martinkonicek/images/objectGraphPrototypeSmall.png" width="600" height="398" /&gt;&lt;/p&gt;
&lt;p&gt;&amp;nbsp;&lt;/p&gt;
&lt;p&gt;In the picture, the visualizer (right) shows all objects that can be reached from variable &lt;i&gt;&amp;quot;a&amp;quot;&lt;/i&gt; in the program being debugged (left).&lt;/p&gt;
&lt;p&gt;There is one more visualizer that is totally missing in today&amp;#39;s
IDEs in my opinion, and will be implemented. More about that next time.&lt;/p&gt;
&lt;p&gt;&lt;b&gt;Bio&lt;/b&gt;&lt;/p&gt;
&lt;p&gt;I&amp;#39;m 23, from the Czech Republic, currently studying CS at Charles University in the beautiful city of Prague. I think .NET is great, I have used it as my primary platform for a couple of years now. I&amp;#39;m teaching basics of programming to freshmen at our university - I recommend this to everyone, it&amp;#39;s a great experience. I have a personal programming blog &lt;a href="http://coding-time.blogspot.com"&gt;here&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;Stay tuned for updates..&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=26945" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/martinkonicek/archive/tags/gsoc/default.aspx">gsoc</category></item><item><title>Debugging IronPython Code in SharpDevelop</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/05/30/DebuggingIronPythonCode.aspx</link><pubDate>Sat, 30 May 2009 12:40:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:26587</guid><dc:creator>MattWard</dc:creator><slash:comments>2</slash:comments><description>&lt;p&gt;With &lt;a href="http://build.sharpdevelop.net/BuildArtefacts/"&gt;
    SharpDevelop 3.1&lt;/a&gt; you can now debug IronPython code with the 
    IronPython Interpreter (ipy.exe).&lt;/p&gt;
&lt;p&gt;Before you start make sure the debugger is set to use the 
    &lt;b&gt;Just My Code&lt;/b&gt; feature. From the Tools menu select Options and 
    then click the Debugging category.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Debugger options for debugging IronPython code" src="http://community.sharpdevelop.net/photos/mattward/images/original/DebuggingOptionsWhenDebuggingIronPythonCode.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Ensure that the &lt;b&gt;Just My Code&lt;/b&gt; feature is checked and that 
    the &lt;b&gt;Step over code without symbols&lt;/b&gt; is not checked. If the 
    Step over code without symbols option is selected then stepping 
    will not work properly and lines of code will be skipped over.&lt;/p&gt;
&lt;p&gt;There are two ways to debug your code. You can use the Python 
    menu or modify the project options. We will look at both of these 
    alternatives. First open your IronPython project into SharpDevelop. 
    Open your main file and make sure it is the active text editor 
    window. Set a breakpoint somewhere in your code. Then from the 
    Python menu select Run.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Python menu option to run with debugger" src="http://community.sharpdevelop.net/photos/mattward/images/original/PythonRunWithDebuggerMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;This will start ipy.exe which will run your code and the 
    debugger should stop the execution at the breakpoint.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Debugging IronPython code" src="http://community.sharpdevelop.net/photos/mattward/images/original/DebuggingIronPythonCode.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;From this point you can do the usual debugging activities such 
    as stepping through your code, viewing the callstack, adding items 
    to the watch window, etc.&lt;/p&gt;
&lt;p&gt;If you want to use a different ipy.exe then this can be 
    specified in the Python Options dialog (Tools menu | Options).&lt;/p&gt;
&lt;p&gt;&lt;img alt="Python options dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/PythonToolsOptionsDialog.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;To enable debugging when you press F5 or select the Debug Run 
    menu option you can modify the project options. From the Projects 
    menu select Project Options and then open the Debug tab. Here you 
    should change the Start Action to &lt;b&gt;Start external program&lt;/b&gt; and 
    use the browse button to locate ipy.exe. In the Start Options add 
    the following command line arguments, changing the name of your 
    main file as required.&lt;/p&gt;
&lt;pre&gt;-D ${ProjectDir}\Program.py&lt;/pre&gt;
&lt;p&gt;Once these changes are saved you can then press F5 and ipy.exe 
    will be run under the debugger instead of running the compiled 
    executable.3&lt;/p&gt;
&lt;h2&gt;Issues&lt;/h2&gt;
&lt;ul&gt;
&lt;li&gt;No support for debugging the executable produced by the 
      IronPython compiler since it does not produce debug symbols (i.e. 
      .pdb files).&lt;/li&gt;
&lt;li&gt;
        When using ipy.exe you need to add references to .NET 
        assemblies explicitly in your code except for System which is 
        included by default. For example:
&lt;pre&gt;import clr &lt;br /&gt;clr.AddReference(&amp;quot;System.Windows.Forms&amp;quot;) &lt;br /&gt;&lt;/pre&gt;
&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Thanks&lt;/h2&gt;
&lt;p&gt;Thanks to 
    &lt;a href="http://community.sharpdevelop.net/blogs/dsrbecky/"&gt;David 
    Srbecky&lt;/a&gt;, SharpDevelop&amp;#39;s debugger expert and maintainer, 
    for reviewing the code changes I wanted to make to the debugger and 
    making sure nothing was broken. Adding support for debugging 
    IronPython was straightforward and required 10-15 lines of new code 
    thanks to the code already written by David.&lt;/p&gt;
&lt;p&gt;Thanks also to &lt;a href="http://devhawk.net/"&gt;Harry Pierson&lt;/a&gt; 
    (IronPython Program Manager at Microsoft) who has written a great 
    set of blog posts on 
    &lt;a href="http://devhawk.net/CategoryView,category,Debugger.aspx"&gt;
    creating an IronPython debugger in IronPython&lt;/a&gt; which gave me the 
    reason why SharpDevelop&amp;#39;s debugger was not working when 
    debugging IronPython code.&lt;/p&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=26587" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Python/default.aspx">Python</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronPython/default.aspx">IronPython</category></item><item><title>IronPython 2.0 Forms Designer</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/05/12/IronPython2FormsDesigner.aspx</link><pubDate>Tue, 12 May 2009 19:50:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:26404</guid><dc:creator>MattWard</dc:creator><slash:comments>0</slash:comments><description>&lt;p&gt;Support for designing Windows Forms in IronPython is now 
    available in SharpDevelop 3.1. The 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2007/10/21/IronPythonIntegrationInSharpDevelop22.aspx"&gt;
    original IronPython forms designer&lt;/a&gt; was removed when 
    SharpDevelop 3.0 began supporting 
    &lt;a href="http://www.codeplex.com/IronPython"&gt;IronPython 2.0&lt;/a&gt; 
    which had removed support for generating IronPython code from 
    &lt;a href="http://msdn.microsoft.com/en-us/library/y2k85ax6.aspx"&gt;
    Microsoft&amp;#39;s CodeDOM&lt;/a&gt;. The forms designer has now been 
    re-implemented to use the IronPython 
    &lt;a href="http://en.wikipedia.org/wiki/Abstract_syntax_tree"&gt;
    abstract syntax tree&lt;/a&gt; (AST) and no longer relies on the 
    CodeDOM.  &lt;/p&gt;
&lt;h2&gt;Creating a Windows Application&lt;/h2&gt;
&lt;p&gt;To create a Windows Application open up the new project dialog 
    by selecting &lt;b&gt;New&lt;/b&gt; then &lt;b&gt;Solution&lt;/b&gt; from the &lt;b&gt;File&lt;/b&gt; 
    menu. Select the Python category to show the available project 
    templates. Select the Windows Application project template, enter a 
    name and location and click the Create button.&lt;/p&gt;
&lt;p&gt;&lt;img alt="New Python Project Dialog" src="http://community.sharpdevelop.net/photos/mattward/images/original/NewPythonWinFormsProject.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Designing Windows Forms&lt;/h2&gt;
&lt;p&gt;The Windows Forms designer is not yet complete so be warned that 
    it could generate form code that will no longer compile.&lt;/p&gt;
&lt;p&gt;The designer can be opened by opening a form in the text editor 
    and selecting the Design tab at the bottom of the editor.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Python main form before opening the designer" src="http://community.sharpdevelop.net/photos/mattward/images/original/PythonMainFormBeforeOpeningInDesigner.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Once open in the designer you can add controls to the form by 
    dragging the controls from the Tools window. In the screenshot 
    below a label, text box and a button have been added.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Main form designed in designer" src="http://community.sharpdevelop.net/photos/mattward/images/original/PythonMainFormInDesigner.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Click the Source tab at the bottom of the editor to view the 
    generated code in the InitializeComponents method.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Generated form code" src="http://community.sharpdevelop.net/photos/mattward/images/original/PythonMainFormGeneratedCode.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Limitations&lt;/h2&gt;
&lt;p&gt;The IronPython forms designer is not yet complete and the 
    following are some of the known limitations.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;No support for project or local form resources.&lt;/li&gt;
&lt;li&gt;No support for icons.&lt;/li&gt;
&lt;li&gt;Incomplete support for ToolStripItems and menu strips.&lt;/li&gt;
&lt;li&gt;Incomplete support for ListViewItems.&lt;/li&gt;
&lt;li&gt;No support for TreeViewItems.&lt;/li&gt;
&lt;li&gt;Incomplete support for non-visual components (e.g. 
      Timers).&lt;/li&gt;
&lt;li&gt;Controls needed to be fully namespace qualified.&lt;/li&gt;
&lt;/ol&gt;
&lt;h2&gt;Forms Designer Internals&lt;/h2&gt;
&lt;p&gt;For those interested in how the forms designer actually works at 
    a high level we will now look at what the IronPython forms designer 
    does when loading and then generating code for a form. &lt;/p&gt;
&lt;p&gt;To show the form in the designer the following steps are 
    executed.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;The form&amp;#39;s code is parsed and an IronPython AST 
      (PythonAst object) is created.&lt;/li&gt;
&lt;li&gt;The AST is then visited and each control is added to the 
      forms designer and the control&amp;#39;s properties are set.&lt;/li&gt;
&lt;li&gt;The form&amp;#39;s properties are set in the designer and the 
      form is displayed.&lt;/li&gt;
&lt;/ol&gt;
&lt;p&gt;To generate the code after the form has been designed the 
    following steps are executed.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;The form is obtained from the forms designer.&lt;/li&gt;
&lt;li&gt;Each of the child components of the form have their 
      properties checked to see if they need to be serialized. This can 
      be done by getting all the 
      &lt;a href="http://msdn.microsoft.com/en-us/library/system.componentmodel.typedescriptor.getproperties.aspx"&gt;
      property descriptors&lt;/a&gt; and then checking the 
      &lt;a href="http://msdn.microsoft.com/en-us/library/system.componentmodel.propertydescriptor.shouldserializevalue.aspx"&gt;
      ShouldSerializeValue&lt;/a&gt; method. If they do need to be serialized 
      then code is generated for them and added to a StringBuilder.&lt;/li&gt;
&lt;li&gt;After all the child components are added the code for the 
      form is generated.&lt;/li&gt;
&lt;li&gt;Finally the generated code is inserted into the text editor 
      inside the InitializeComponent method, replacing any existing 
      code.&lt;/li&gt;
&lt;/ol&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=26404" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Python/default.aspx">Python</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronPython/default.aspx">IronPython</category></item><item><title>Converting C# and VB.NET Code to IronPython</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/05/11/ConvertingCSharpVBNetCodeToIronPython.aspx</link><pubDate>Mon, 11 May 2009 19:07:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:26394</guid><dc:creator>MattWard</dc:creator><slash:comments>2</slash:comments><description>&lt;p&gt;SharpDevelop 3.1 now supports converting C# and VB.NET code to 
    IronPython. It can convert a single file or an entire project. The 
    code to convert between these languages is still under development 
    and has some limitations. &lt;/p&gt;
&lt;h2&gt;Converting an Individual File&lt;/h2&gt;
&lt;p&gt;To convert a C# or VB.NET file, open it in SharpDevelop&amp;#39;s 
    text editor, then from &lt;b&gt;Tools&lt;/b&gt; menu select &lt;b&gt;Convert code to 
    Python&lt;/b&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Convert code to Python menu option." src="http://community.sharpdevelop.net/photos/mattward/images/original/ConvertCodeToPythonMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;The code conversion is limited to converting classes so it will 
    not convert an arbitary piece of code that is not inside a 
    class.&lt;/p&gt;
&lt;p&gt;&lt;img alt="C# code before conversion." src="http://community.sharpdevelop.net/photos/mattward/images/original/CSharpCodeBeforeConversionToPython.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;&lt;img alt="C# code after conversion to Python" src="http://community.sharpdevelop.net/photos/mattward/images/original/ConvertedCSharpClassAsPython.aspx" /&gt;&lt;/p&gt;
&lt;h2&gt;Converting a Project&lt;/h2&gt;
&lt;p&gt;To convert a C# or VB.NET project, open it in SharpDevelop, then 
    from the &lt;b&gt;Project&lt;/b&gt; menu select &lt;b&gt;Convert From C# to 
    Python&lt;/b&gt;.&lt;/p&gt;
&lt;p&gt;&lt;img alt="Convert from C# project to Python project menu option." src="http://community.sharpdevelop.net/photos/mattward/images/original/ProjectConvertFromCSharpToPythonMenuItem.aspx" /&gt;&lt;/p&gt;
&lt;p&gt;Once converted the project will most likely not compile straight 
    away due to limitations in the implementation. At the time of 
    writing converting a project has the following limitations:&lt;/p&gt;
&lt;ul&gt;
&lt;li&gt;Project&amp;#39;s Main File is not set.&lt;/li&gt;
&lt;li&gt;No code generated to call the project&amp;#39;s Main entry 
      method.&lt;/li&gt;
&lt;li&gt;Namespace imports do include all the used classes.&lt;/li&gt;
&lt;/ul&gt;
&lt;h2&gt;Code Conversion Internals&lt;/h2&gt;
&lt;p&gt;Converting code to IronPython was originally supported in 
    &lt;a href="http://community.sharpdevelop.net/blogs/mattward/archive/2007/10/21/IronPythonIntegrationInSharpDevelop22.aspx"&gt;
    SharpDevelop 2.2&lt;/a&gt; and was based on converting code to a 
    &lt;a href="http://msdn.microsoft.com/en-us/library/y2k85ax6.aspx"&gt;
    Microsoft CodeDOM&lt;/a&gt; and then getting IronPython 1.0 to generate 
    the Python code. In IronPython 2.0 this CodeDOM support was removed 
    so the code conversion feature was removed from SharpDevelop 3.0 
    since that was using IronPython 2.0. In SharpDevelop 3.1 the code 
    conversion has been rewritten to no longer use the CodeDOM support. 
    It now works by executing the following simple steps:&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;The C# or VB.NET code is parsed using SharpDevelop&amp;#39;s 
      parsing library 
      &lt;a href="http://laputa.sharpdevelop.net/NRefactoryTutorialVideo.aspx"&gt;
      NRefactory&lt;/a&gt; and an 
      &lt;a href="http://en.wikipedia.org/wiki/Abstract_syntax_tree"&gt;
      abstract syntax tree (AST)&lt;/a&gt; is generated.&lt;/li&gt;
&lt;li&gt;A &lt;a href="http://en.wikipedia.org/wiki/Visitor_pattern"&gt;
      visitor&lt;/a&gt; class then walks this AST and generates Python code 
      which is added to a StringBuilder.&lt;/li&gt;
&lt;li&gt;Once the visit is complete the generated Python code is then 
      displayed or saved to disk.&lt;/li&gt;
&lt;/ol&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=26394" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/Python/default.aspx">Python</category><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/IronPython/default.aspx">IronPython</category></item><item><title>NUnit 2.5 Support</title><link>http://community.sharpdevelop.net/blogs/mattward/archive/2009/05/10/NUnit25Support.aspx</link><pubDate>Sun, 10 May 2009 16:46:00 GMT</pubDate><guid isPermaLink="false">1b90d1c1-04e6-45b0-b51d-b665527d49b9:26381</guid><dc:creator>MattWard</dc:creator><slash:comments>2</slash:comments><description>&lt;p&gt;SharpDevelop 3.1 now supports &lt;a href="http://nunit.org"&gt;NUnit 
    2.5&lt;/a&gt;.&lt;/p&gt;
&lt;p&gt;A summary of which NUnit version is supported by SharpDevelop is 
    shown in the table below.&lt;/p&gt;
&lt;table class="article "&gt;

&lt;tr&gt;
&lt;td&gt;SharpDevelop 3.1&lt;/td&gt;
&lt;td&gt;NUnit 2.5&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;SharpDevelop 3.0&lt;/td&gt;
&lt;td&gt;NUnit 2.4.8&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;SharpDevelop 2.2.1&lt;/td&gt;
&lt;td&gt;NUnit 2.4.7&lt;/td&gt;
&lt;/tr&gt;
&lt;tr&gt;
&lt;td&gt;SharpDevelop 1.1&lt;/td&gt;
&lt;td&gt;NUnit 2.2&lt;/td&gt;
&lt;/tr&gt;

&lt;/table&gt;
&lt;h2&gt;NUnit 2.5 Changes&lt;/h2&gt;
&lt;p&gt;NUnit 2.5 has changed quite substantially compared with the 
    previous 2.4.8 release, as outlined in the 
    &lt;a href="http://nunit.com/index.php?p=releaseNotes&amp;amp;r=2.5"&gt;NUnit 
    2.5 release notes&lt;/a&gt;. The problems that we had when migrating 
    SharpDevelop&amp;#39;s unit tests to NUnit 2.5 were as follows.&lt;/p&gt;
&lt;ol&gt;
&lt;li&gt;&lt;b&gt;Assert.IsInstanceOfType has been replaced by 
        Assert.IsInstanceOf.&lt;/b&gt;
&lt;p&gt;Your code will still compile and work if 
        Assert.IsInstanceOfType is used but you will get compiler 
        warnings.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;b&gt;NUnit.Framework.SyntaxHelpers namespace no longer exists.&lt;/b&gt;
&lt;p&gt;All classes that were in this namespace have been moved to 
        the NUnit.Framework namespace.&lt;/p&gt;
&lt;/li&gt;
&lt;li&gt;&lt;b&gt;The Has.Count constraint no longer takes an integer 
        parameter.&lt;/b&gt;
&lt;p&gt;To fix this problem replace code such as:&lt;/p&gt;
&lt;pre&gt;Assert.That(classesCollection, Has.Count(1));&lt;/pre&gt;
&lt;p&gt;With the following:&lt;/p&gt;
&lt;pre&gt;Assert.That(classesCollection.Has.Count.EqualTo(1));&lt;/pre&gt;
&lt;/li&gt;
&lt;li&gt;&lt;b&gt;Overriding a [TestFixtureSetUp] method in a derived class 
        using the new keyword no longer works.&lt;/b&gt;
&lt;p&gt;Some of the SharpDevelop unit tests were overriding an 
        abstract base test class [TestFixtureSetUp] method in a derived 
        class by using the new keyword, as shown below.&lt;/p&gt;
&lt;p&gt;Base class:&lt;/p&gt;
&lt;pre&gt;[TestFixtureSetUp] &lt;br /&gt;public void SetUpFixture()  &lt;br /&gt;{ &lt;br /&gt;    // Setup code. &lt;br /&gt;}&lt;/pre&gt;
&lt;p&gt;Derived class:&lt;/p&gt;
&lt;pre&gt;[TestFixtureSetUp] &lt;br /&gt;public new void SetUpFixture()  &lt;br /&gt;{     &lt;br /&gt;    // Extra setup code. &lt;br /&gt;    base.SetUpFixture(); &lt;br /&gt;}&lt;/pre&gt;
&lt;p&gt;In NUnit 2.4.8 the SetUpFixture method in the derived class 
        would be called when running the tests allowing it to execute 
        some extra setup steps. In NUnit 2.5 the base class 
        SetUpFixture method is called instead and the derived class 
        method is never called. To resolve the problem we changed the 
        base class so it used a virtual method and allowed the derived 
        class to override this to execute its extra setup steps.&lt;/p&gt;
&lt;p&gt;Base class:&lt;/p&gt;
&lt;pre&gt;[TestFixtureSetUp] &lt;br /&gt;public void SetUpFixture()  &lt;br /&gt;{ &lt;br /&gt;    BeforeSetUpFixture(); &lt;br /&gt;    // Setup code. &lt;br /&gt;} &lt;br /&gt; &lt;br /&gt;public virtual void BeforeSetUpFixture() &lt;br /&gt;{ &lt;br /&gt;}&lt;/pre&gt;
&lt;p&gt;Derived class:&lt;/p&gt;
&lt;pre&gt;public override void BeforeSetUpFixture() &lt;br /&gt;{ &lt;br /&gt;     // Extra setup code. &lt;br /&gt;}&lt;/pre&gt;
&lt;/li&gt;
&lt;/ol&gt;&lt;img src="http://community.sharpdevelop.net/aggbug.aspx?PostID=26381" width="1" height="1"&gt;</description><category domain="http://community.sharpdevelop.net/blogs/mattward/archive/tags/UnitTests/default.aspx">UnitTests</category></item></channel></rss>