protected override void OnNavigatedTo(NavigationEventArgs e) { if (e.Parameter != null) { meal = (MealViewModel)e.Parameter; editor.Document.SetText(Windows.UI.Text.TextSetOptions.FormatRtf, meal.GetTextRepresentation(meal)); /*editor.Document.SetText(Windows.UI.Text.TextSetOptions.FormatRtf, "0123456789\n0123456789"); editor.Document.Selection.StartPosition = 9; editor.Document.Selection.EndPosition = 12; ITextSelection sel = editor.Document.Selection; if (sel != null) { ITextCharacterFormat charFormatting = sel.CharacterFormat; charFormatting.Bold = FormatEffect.Toggle; //charFormatting.Size = 20; //charFormatting.BackgroundColor = Colors.Red; charFormatting.ForegroundColor = Colors.Red; sel.CharacterFormat = charFormatting; }*/ } }