void scaledbox_Shown(object sender, Toolbox.Object.AboutToBeShownEventArgs args) { var scale_dbox = (Toolbox.ScaleDialogue)sender; // Scale dialogue is a shared toolbox object, so check that this is the // intended target of the event. if (this.Equals(scale_dbox.GetAncestor <TextDocument>())) { scale_dbox.Value = (int)Scale; } }
void fontdbox_Show(object sender, Toolbox.Object.AboutToBeShownEventArgs args) { var font_dbox = (Toolbox.FontDialogue)sender; // Font dialogue is a shared toolbox object, so check that this is the // intended target of the event. if (this.Equals(font_dbox.GetAncestor <TextDocument>())) { font_dbox.Font = FontID; font_dbox.Height = FontHeight; font_dbox.AspectRatio = FontAspectRatio; } }
void fileinfo_Show(object sender, Toolbox.Object.AboutToBeShownEventArgs args) { var file_info_dbox = (Toolbox.FileInfoDialogue)sender; // The FileInfo dialogue is a shared toolbox object, so check that this is the // intended target of the event. if (this.Equals(file_info_dbox.GetAncestor <TextDocument>())) { file_info_dbox.Date = OS.DateTime.Now; file_info_dbox.FileSize = Text.Length; file_info_dbox.Modified = false; file_info_dbox.FileType = 0xfff; file_info_dbox.FileName = (FileName != null) ? FileName : "<Untitled>"; } }
void quitdbox_Show(object sender, Toolbox.Object.AboutToBeShownEventArgs e) { Reporter.WriteLine("Quit Dialogue about to be shown, show type = {0}", e.ShowSpec.Type); Reporter.WriteLine(""); }