Created
May 22, 2011 20:57
-
-
Save curtismitchell/985887 to your computer and use it in GitHub Desktop.
Boo/WPF application that loads external xaml
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import System | |
import System.Windows from PresentationFramework | |
import System.Windows.Markup from PresentationFramework | |
import System.IO | |
class XamlWindow(Window): | |
def constructor(name): | |
load_xaml(name) | |
def load_xaml(name): | |
xaml_file = File.OpenRead(Path.GetFullPath(name)) | |
self.Content = XamlReader.Load(xaml_file) | |
Application().Run(XamlWindow("mainui.xaml")) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment