I am not claiming that it is origonal since it was cribbed from someone elses site.
However this version is not broken and does have a build script.
The following is wpdemo.boo:
namespace Boo.WinFx
import System
import System.Windows
import System.Windows.Controls
import System.Windows.Navigation
[STAThread]
def Main():
# create a window host
win = NavigationWindow()
# create a textblock
para = TextBlock(Text:”Hello World!!!”, FontSize:36)
para.VerticalAlignment = VerticalAlignment.Center
para.HorizontalAlignment =HorizontalAlignment.Center
# create a button
button = Button(Content:”Click Me”, Height:30, Width:100)
# display the textblock when the button is clicked
button.Click += { win.Navigate(para) }
# display the button first
win.Navigate(button)
# create an application host
app = Application()
# show the window
win.Show()
# fire the application
app.Run()
The following is default.build:
<?xml version=”1.0″ ?>
<project name=”wpfdemo” default=”build”>
<property name=”boo.dir” value=”C:/boo/bin” />
<target name=”build” depends=”wpfdemo” />
<target name=”wpfdemo”>
<loadtasks assembly=”${boo.dir}/Boo.NAnt.Tasks.dll” />
<booc output=”wpfdemo.exe” target=”winexe”>
<references>
<include name=”C:/Program Files/Reference Assemblies/Microsoft/Framework/v3.0/*.dll” />
</references>
<sources>
<include name=”wpfdemo.boo” />
</sources>
</booc>
</target>
</project>