本文整理汇总了C#中Gtk.Widget.ShowAll方法的典型用法代码示例。如果您正苦于以下问题:C# Gtk.Widget.ShowAll方法的具体用法?C# Gtk.Widget.ShowAll怎么用?C# Gtk.Widget.ShowAll使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类Gtk.Widget
的用法示例。
在下文中一共展示了Gtk.Widget.ShowAll方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: SearchSource
public SearchSource()
: base(name, name, 190, "internet-archive-search")
{
IA.Search.UserAgent = Banshee.Web.Browser.UserAgent;
IA.Search.TimeoutMs = 12*1000;
search = new IA.Search () { NumResults = 100 };
Properties.SetStringList ("Icon.Name", "search", "gtk-search");
Properties.SetString ("ActiveSourceUIResource", "SearchSourceActiveUI.xml");
Properties.SetString ("GtkActionPath", "/IaSearchSourcePopup");
if (header_widget == null) {
header_widget = new HeaderFilters (this);
header_widget.ShowAll ();
Properties.Set<Gtk.Widget> ("Nereid.SourceContents.HeaderWidget", header_widget);
}
Properties.Set<Banshee.Sources.Gui.ISourceContents> ("Nereid.SourceContents", new Banshee.Sources.Gui.LazyLoadSourceContents<SearchView> (this));
}
示例2: SourceEditor
//.........这里部分代码省略.........
//editor.Document.
editor.Document.SyntaxMode = mode;
//modified = true;
editor.Document.LineChanged += delegate(object sender, LineEventArgs e) {
OnBookmarkUpdate();
OnModifiedChanged(true);
};
editor.Caret.PositionChanged+= delegate(object sender, DocumentLocationEventArgs e) {
OnWriteToStatusbar(String.Format(statusFormat,editor.Caret.Location.Line+1,editor.Caret.Location.Column,editor.Caret.Offset));
};
FileAttributes fa = File.GetAttributes(filePath);
if ((fa & FileAttributes.ReadOnly) == FileAttributes.ReadOnly) {
onlyRead = true;
//editor.Document.ReadOnly= true;
}
try {
using (StreamReader file = new StreamReader(filePath)) {
editor.Document.Text = file.ReadToEnd();
file.Close();
file.Dispose();
}
} catch (Exception ex) {
MessageDialogs ms = new MessageDialogs(MessageDialogs.DialogButtonType.Ok, MainClass.Languages.Translate("file_cannot_open", filePath), ex.Message, Gtk.MessageType.Error,null);
ms.ShowDialog();
return;
}
//Console.WriteLine(editor.Document.Text.Replace("\r","^").Replace("\n","$"));
(control as Gtk.ScrolledWindow).Add(editor);
control.ShowAll();
fileName = filePath;
fileSeting = MainClass.Workspace.WorkspaceUserSetting.FilesSetting.Find(x=> x.FileName == fileName);
if(fileSeting == null)
fileSeting = new FileSetting( fileName );
editor.TextViewMargin.ButtonPressed += OnTextMarginButtonPress;
editor.IconMargin.ButtonPressed += OnIconMarginButtonPress;
//editor.KeyPressEvent += OnKeyPressEvent;
editor.KeyReleaseEvent += OnKeyReleaseEvent;
editor.ButtonPressEvent += OnButtonPressEvent;
bookmarkActions = new IdeBookmarkActions(editor,fileSeting);
breakpointActions = new IdeBreakpointActions(editor);
autoCompleteActions = new IdeAutocompleteAction(editor, editor);
editAction = new IdeEditAction(editor);
Gtk.Action act = new Gtk.Action("sourceeditor_togglebookmark", "");
act.Activated += bookmarkActions.ToggleBookmark;
editorAction.Add(act);
Gtk.Action act2 = new Gtk.Action("sourceeditor_clearbookmark", "");
act2.Activated += bookmarkActions.ClearBookmarks;
editorAction.Add(act2);
Gtk.Action act3 = new Gtk.Action("sourceeditor_nextbookmark", "");
act3.Activated += bookmarkActions.NextBookmark;
editorAction.Add(act3);
Gtk.Action act4 = new Gtk.Action("sourceeditor_prevbookmark", "");
act4.Activated += bookmarkActions.PreviousBookmark;