Index: Tomboy/Addins/ExportToHtml/ExportToHtmlNoteAddin.cs
===================================================================
--- Tomboy/Addins/ExportToHtml/ExportToHtmlNoteAddin.cs	(revision 2293)
+++ Tomboy/Addins/ExportToHtml/ExportToHtmlNoteAddin.cs	(working copy)
@@ -2,6 +2,7 @@
 using System;
 using System.IO;
 using System.Reflection;
+using System.Text;
 using System.Xml;
 using System.Xml.XPath;
 using System.Xml.Xsl;
@@ -14,20 +15,20 @@
 	public class ExportToHtmlNoteAddin : NoteAddin
 	{
 		const string stylesheet_name = "ExportToHtml.xsl";
-		static XslTransform xsl;
+		static XslCompiledTransform xsl;
 
 		Gtk.ImageMenuItem item;
 
-		static XslTransform NoteXsl
+		static XslCompiledTransform NoteXsl
 		{
 			get {
 				if (xsl == null) {
 					Assembly asm = Assembly.GetExecutingAssembly ();
 					string asm_dir = System.IO.Path.GetDirectoryName (asm.Location);
 					string stylesheet_file = Path.Combine (asm_dir, stylesheet_name);
+
+					xsl = new XslCompiledTransform();
 		
-					xsl = new XslTransform ();
-		
 					if (File.Exists (stylesheet_file)) {
 						Logger.Log ("ExportToHTML: Using user-custom {0} file.",
 						            stylesheet_name);
@@ -171,12 +172,11 @@
 			// NOTE: Don't use the XmlDocument version, which strips
 			// whitespace between elements for some reason.  Also,
 			// XPathDocument is faster.
-			StringWriter s_writer = new StringWriter ();
-			NoteArchiver.Write (s_writer, note.Data);
-			StringReader reader = new StringReader (s_writer.ToString ());
-			s_writer.Close ();
-			XPathDocument doc = new XPathDocument (reader);
-			reader.Close ();
+			MemoryStream x_stream = new MemoryStream ();
+			StreamWriter s_writer = new StreamWriter (x_stream);			
+			NoteArchiver.Write (s_writer, note.Data);			
+			x_stream.Position = 0;
+			XmlTextReader reader = new XmlTextReader (x_stream);						
 
 			XsltArgumentList args = new XsltArgumentList ();
 			args.AddParam ("export-linked", "", export_linked);
@@ -184,7 +184,7 @@
 			args.AddParam ("root-note", "", note.Title);
 			args.AddExtensionObject ("http://beatniksoftware.com/tomboy",
 				new TransformExtension ());
-
+			
 			if ((bool) Preferences.Get (Preferences.ENABLE_CUSTOM_FONT)) {
 				string font_face = (string) Preferences.Get (Preferences.CUSTOM_FONT_FACE);
 				Pango.FontDescription font_desc =
@@ -193,9 +193,16 @@
 
 				args.AddParam ("font", "", font);
 			}
-
+			
 			NoteNameResolver resolver = new NoteNameResolver (note.Manager, note);
-			NoteXsl.Transform (doc, args, writer, resolver);
+			using (XmlTextWriter x_writer = new XmlTextWriter (writer))
+			{
+				XsltSettings.Default.EnableDocumentFunction = true;
+				NoteXsl.Transform (reader, args, x_writer, resolver);
+			}
+			s_writer.Close();
+			reader.Close ();
+			x_stream.Close ();
 		}
 	}
 
Index: Tomboy/Note.cs
===================================================================
--- Tomboy/Note.cs	(revision 2293)
+++ Tomboy/Note.cs	(working copy)
@@ -770,7 +770,7 @@
 			}
 			set {
 				if (buffer != null) {
-					buffer.SetText("");
+					buffer.Text = "";
 					NoteBufferArchiver.Deserialize (buffer, value);
 				} else
 					data.Text = value;
@@ -880,7 +880,7 @@
 			}
 			set {
 				if (buffer != null)
-					buffer.SetText (value);
+					buffer.Text = value;
 				else
 					Logger.Log ("Setting text content for closed notes not supported");
 			}
Index: Tomboy/Synchronization/SyncDialog.cs
===================================================================
--- Tomboy/Synchronization/SyncDialog.cs	(revision 2293)
+++ Tomboy/Synchronization/SyncDialog.cs	(working copy)
@@ -70,8 +70,6 @@
 
 			progressBar = new Gtk.ProgressBar ();
 			progressBar.Orientation = Gtk.ProgressBarOrientation.LeftToRight;
-			progressBar.BarStyle = ProgressBarStyle.Continuous;
-			progressBar.ActivityBlocks = 30;
 			progressBar.Show ();
 			outerVBox.PackStart (progressBar, false, false, 0);
 
Index: Tomboy/WrapBox.cs
===================================================================
--- Tomboy/WrapBox.cs	(revision 2293)
+++ Tomboy/WrapBox.cs	(working copy)
@@ -111,7 +111,7 @@
 
 				if (anchor.Widgets.Length == 0) {
 					TextIter start = tv.Buffer.GetIterAtChildAnchor (anchor);
-					TextIter end = start.Copy ();
+					TextIter end = start;
 					end.ForwardChar ();
 					tv.Buffer.Delete (ref start, ref end);
 				}
