本文整理汇总了C#中System.Windows.Forms.HelpProvider.SetShowHelp方法的典型用法代码示例。如果您正苦于以下问题:C# HelpProvider.SetShowHelp方法的具体用法?C# HelpProvider.SetShowHelp怎么用?C# HelpProvider.SetShowHelp使用的例子?那么, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类System.Windows.Forms.HelpProvider
的用法示例。
在下文中一共展示了HelpProvider.SetShowHelp方法的15个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的C#代码示例。
示例1: LabelViewer
public LabelViewer()
{
InitializeComponent();
source_path = "";
archive_path = "";
/* Setting up refresh timer to enable and disable the buttons. */
global_timer = new Timer();
global_timer.Interval = 500;
global_timer.Tick += new EventHandler(refresh_label_viewer);
global_timer.Start();
/* Populating the file_extensions and adding it to the checklist */
file_extensions.Add("Zebra Labels: .zpl");
file_extensions.Add("Intermec Labels: .ipl");
file_extensions.Add("Sato Labels: .lbl");
file_extensions.Add("Datamax Labels: .dpl");
int counter = 0;
while (counter < file_extensions.Count)
{
extensionsList.Items.Add(file_extensions.ElementAt(counter));
counter++;
}
extensionsList.CheckOnClick = false;
helpProvider1 = new HelpProvider();
helpProvider1.SetShowHelp(directoryText, true);
helpProvider1.SetHelpString(directoryText, "Enter the path to the source directory.");
helpProvider1.SetShowHelp(archiveText, true);
helpProvider1.SetHelpString(archiveText, "Enter the path to the archive directory.");
helpProvider1.SetShowHelp(revertButton, true);
helpProvider1.SetHelpString(revertButton, "Moves ALL the files from the archive to source directory.");
helpProvider1.SetShowHelp(searchButton, true);
helpProvider1.SetHelpString(searchButton, "Starts the polling process on the source directory.");
helpProvider1.SetShowHelp(InstructionsButton, true);
helpProvider1.SetHelpString(InstructionsButton, "Follow these set of instructions.");
helpProvider1.SetShowHelp(ExitButton, true);
helpProvider1.SetHelpString(ExitButton, "Exit (Esc)");
helpProvider1.HelpNamespace = "help.chm";
helpProvider1.SetHelpNavigator(directoryText, HelpNavigator.TableOfContents);
}
示例2: DictionaryConfigMgrDlg
private string m_helpTopicId = "khtpDictConfigManager"; // use as default?
#endregion Fields
#region Constructors
/// ------------------------------------------------------------------------------------
/// <summary>
/// Initializes a new instance of the <see cref="T:DictionaryConfigMgrDlg"/> class.
/// </summary>
/// ------------------------------------------------------------------------------------
public DictionaryConfigMgrDlg(Mediator mediator, string objType, List<XmlNode> configViews, XmlNode current)
{
InitializeComponent();
m_mediator = mediator;
m_presenter = new DictionaryConfigManager(this, configViews, current);
m_objType = objType;
// Make a help topic ID
m_helpTopicId = generateChooserHelpTopicID(m_objType);
m_helpProvider = new HelpProvider { HelpNamespace = m_mediator.HelpTopicProvider.HelpFile };
m_helpProvider.SetHelpKeyword(this, m_mediator.HelpTopicProvider.GetHelpString(m_helpTopicId));
m_helpProvider.SetHelpNavigator(this, HelpNavigator.Topic);
m_helpProvider.SetShowHelp(this, true);
}
示例3: SetupDialog
protected string m_helpTopic = ""; // Default help topic ID
public void SetupDialog(HomographConfiguration hc, FdoCache cache, FwStyleSheet stylesheet, IApp app,
IHelpTopicProvider helpTopicProvider)
{
SetHelpTopic("khtpConfigureHomograph"); // Default help topic ID
m_helpProvider = new HelpProvider();
m_helpProvider.SetHelpNavigator(this, HelpNavigator.Topic);
m_helpProvider.SetShowHelp(this, true);
m_cache = cache;
m_stylesheet = stylesheet;
m_app = app;
m_helpTopicProvider = helpTopicProvider;
if (m_helpTopicProvider != null)
{
m_helpProvider.HelpNamespace = m_helpTopicProvider.HelpFile;
SetHelpButtonEnabled();
}
if (hc.ShowHomographNumber(HomographConfiguration.HeadwordVariant.Main))
{
m_radioHide.Checked = false;
m_radioBefore.Checked = hc.HomographNumberBefore;
m_radioAfter.Checked = !hc.HomographNumberBefore;
m_chkShowSenseNumInDict.Checked = hc.ShowSenseNumberRef;
m_chkShowSenseNumInReversal.Checked = hc.ShowSenseNumberReversal;
}
else
{
m_radioHide.Checked = true;
m_radioBefore.Checked = false;
m_radioAfter.Checked = false;
m_chkShowSenseNumInDict.Checked = false;
m_chkShowSenseNumInReversal.Checked = false;
}
m_chkShowHomographNumInDict.Checked =
hc.ShowHomographNumber(HomographConfiguration.HeadwordVariant.DictionaryCrossRef);
m_chkShowHomographNumInReversal.Checked =
hc.ShowHomographNumber(HomographConfiguration.HeadwordVariant.ReversalCrossRef);
EnableControls();
}
示例4: GetProvider
protected override IRawElementProviderSimple GetProvider ()
{
SWF.HelpProvider swfHelpProvider = new SWF.HelpProvider ();
SWF.Button swfButton = new SWF.Button ();
swfButton.Location = new SD.Point (3, 3);
swfButton.Size = new SD.Size (272, 72);
swfButton.Text = "With help";
SWF.Button swfButtonNoHelp = new SWF.Button ();
swfButtonNoHelp.Location = new SD.Point (3, 30);
swfButtonNoHelp.Size = new SD.Size (272, 72);
swfButtonNoHelp.Text = "No help";
//We have to use an event to fake the user click
swfButton.Click += new System.EventHandler (OnControlClicked);
swfHelpProvider.SetShowHelp (swfButton, true);
swfHelpProvider.SetHelpString (swfButton, "I'm showing a button tooltip.");
Form.Controls.Add (swfButton);
Form.Controls.Add (swfButtonNoHelp);
//Testing ToolTipOpenedEvent
bridge.ResetEventLists ();
swfButton.PerformClick (); //Clicking the button will fake the event!
StructureChangedEventTuple eventTuple
= bridge.GetStructureChangedEventAt (0, StructureChangeType.ChildAdded);
return eventTuple.provider as IRawElementProviderSimple;
}
示例5: InitializeComponent
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.Windows.Forms.Button btnHelp;
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(AddCnvtrDlg));
System.Windows.Forms.Button btnClose;
System.Windows.Forms.HelpProvider helpProvider1;
this.label1 = new System.Windows.Forms.Label();
this.m_addCnvtrTabCtrl = new System.Windows.Forms.TabControl();
this.propertiesTab = new System.Windows.Forms.TabPage();
this.m_cnvtrPropertiesCtrl = new SIL.FieldWorks.FwCoreDlgs.CnvtrPropertiesCtrl();
this.testTab = new System.Windows.Forms.TabPage();
this.m_converterTest = new SIL.FieldWorks.FwCoreDlgs.ConverterTest();
this.advancedTab = new System.Windows.Forms.TabPage();
this.m_advancedEncProps = new SIL.FieldWorks.FwCoreDlgs.AdvancedEncProps();
this.availableCnvtrsListBox = new System.Windows.Forms.ListBox();
this.btnAdd = new System.Windows.Forms.Button();
this.btnCopy = new System.Windows.Forms.Button();
this.btnDelete = new System.Windows.Forms.Button();
btnHelp = new System.Windows.Forms.Button();
btnClose = new System.Windows.Forms.Button();
helpProvider1 = new System.Windows.Forms.HelpProvider();
this.m_addCnvtrTabCtrl.SuspendLayout();
this.propertiesTab.SuspendLayout();
this.testTab.SuspendLayout();
this.advancedTab.SuspendLayout();
this.SuspendLayout();
//
// btnHelp
//
resources.ApplyResources(btnHelp, "btnHelp");
btnHelp.Name = "btnHelp";
helpProvider1.SetShowHelp(btnHelp, ((bool)(resources.GetObject("btnHelp.ShowHelp"))));
btnHelp.Click += new System.EventHandler(this.btnHelp_Click);
//
// btnClose
//
resources.ApplyResources(btnClose, "btnClose");
helpProvider1.SetHelpString(btnClose, resources.GetString("btnClose.HelpString"));
btnClose.Name = "btnClose";
helpProvider1.SetShowHelp(btnClose, ((bool)(resources.GetObject("btnClose.ShowHelp"))));
btnClose.Click += new System.EventHandler(this.btnClose_Click);
//
// label1
//
resources.ApplyResources(this.label1, "label1");
this.label1.Name = "label1";
helpProvider1.SetShowHelp(this.label1, ((bool)(resources.GetObject("label1.ShowHelp"))));
//
// m_addCnvtrTabCtrl
//
resources.ApplyResources(this.m_addCnvtrTabCtrl, "m_addCnvtrTabCtrl");
this.m_addCnvtrTabCtrl.Controls.Add(this.propertiesTab);
this.m_addCnvtrTabCtrl.Name = "m_addCnvtrTabCtrl";
this.m_addCnvtrTabCtrl.SelectedIndex = 0;
helpProvider1.SetShowHelp(this.m_addCnvtrTabCtrl, ((bool)(resources.GetObject("m_addCnvtrTabCtrl.ShowHelp"))));
this.m_addCnvtrTabCtrl.SelectedIndexChanged += new System.EventHandler(this.AddCnvtrTabCtrl_SelectedIndexChanged);
//
// propertiesTab
//
this.propertiesTab.Controls.Add(this.m_cnvtrPropertiesCtrl);
resources.ApplyResources(this.propertiesTab, "propertiesTab");
this.propertiesTab.Name = "propertiesTab";
helpProvider1.SetShowHelp(this.propertiesTab, ((bool)(resources.GetObject("propertiesTab.ShowHelp"))));
this.propertiesTab.Tag = "ktagProperties";
this.propertiesTab.UseVisualStyleBackColor = true;
//
// m_cnvtrPropertiesCtrl
//
this.m_cnvtrPropertiesCtrl.BackColor = System.Drawing.Color.Transparent;
this.m_cnvtrPropertiesCtrl.ConverterChanged = true;
resources.ApplyResources(this.m_cnvtrPropertiesCtrl, "m_cnvtrPropertiesCtrl");
this.m_cnvtrPropertiesCtrl.Name = "m_cnvtrPropertiesCtrl";
this.m_cnvtrPropertiesCtrl.OnlyUnicode = false;
helpProvider1.SetShowHelp(this.m_cnvtrPropertiesCtrl, ((bool)(resources.GetObject("m_cnvtrPropertiesCtrl.ShowHelp"))));
//
// testTab
//
this.testTab.Controls.Add(this.m_converterTest);
resources.ApplyResources(this.testTab, "testTab");
this.testTab.Name = "testTab";
helpProvider1.SetShowHelp(this.testTab, ((bool)(resources.GetObject("testTab.ShowHelp"))));
this.testTab.Tag = "ktagTest";
this.testTab.UseVisualStyleBackColor = true;
//
// m_converterTest
//
resources.ApplyResources(this.m_converterTest, "m_converterTest");
this.m_converterTest.Name = "m_converterTest";
helpProvider1.SetShowHelp(this.m_converterTest, ((bool)(resources.GetObject("m_converterTest.ShowHelp"))));
//
// advancedTab
//
this.advancedTab.Controls.Add(this.m_advancedEncProps);
resources.ApplyResources(this.advancedTab, "advancedTab");
this.advancedTab.Name = "advancedTab";
helpProvider1.SetShowHelp(this.advancedTab, ((bool)(resources.GetObject("advancedTab.ShowHelp"))));
//.........这里部分代码省略.........
示例6: InitializeComponent
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
System.Windows.Forms.ColumnHeader columnHeader1;
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(AdvancedEncProps));
System.Windows.Forms.ColumnHeader columnHeader2;
System.Windows.Forms.HelpProvider helpProvider1;
this.lvConverterInfo = new System.Windows.Forms.ListView();
columnHeader1 = new System.Windows.Forms.ColumnHeader();
columnHeader2 = new System.Windows.Forms.ColumnHeader();
helpProvider1 = new HelpProvider();
this.SuspendLayout();
//
// lvConverterInfo
//
this.lvConverterInfo.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
columnHeader1,
columnHeader2});
resources.ApplyResources(this.lvConverterInfo, "lvConverterInfo");
this.lvConverterInfo.FullRowSelect = true;
helpProvider1.SetHelpString(this.lvConverterInfo, resources.GetString("lvConverterInfo.HelpString"));
this.lvConverterInfo.MultiSelect = false;
this.lvConverterInfo.Name = "lvConverterInfo";
helpProvider1.SetShowHelp(this.lvConverterInfo, ((bool)(resources.GetObject("lvConverterInfo.ShowHelp"))));
this.lvConverterInfo.UseCompatibleStateImageBehavior = false;
this.lvConverterInfo.View = System.Windows.Forms.View.Details;
//
// columnHeader1
//
resources.ApplyResources(columnHeader1, "columnHeader1");
//
// columnHeader2
//
resources.ApplyResources(columnHeader2, "columnHeader2");
//
// AdvancedEncProps
//
this.Controls.Add(this.lvConverterInfo);
this.Name = "AdvancedEncProps";
helpProvider1.SetShowHelp(this, ((bool)(resources.GetObject("$this.ShowHelp"))));
resources.ApplyResources(this, "$this");
this.ResumeLayout(false);
}
示例7: BaseGoDlg
/// <summary>
/// Constructor.
/// </summary>
public BaseGoDlg()
{
//
// Required for Windows Form Designer support
//
InitializeComponent();
AccessibleName = GetType().Name;
m_helpProvider = new HelpProvider();
m_helpProvider.SetHelpNavigator(this, HelpNavigator.Topic);
m_helpProvider.SetShowHelp(this, true);
m_vernHvos = new HashSet<int>();
m_analHvos = new HashSet<int>();
// NB: Don't set this here, because the fake writing system factory
// will cause an assert down in VwPropertyStore.
//m_tbForm.Text = "";
m_tbForm.TextChanged += m_tbForm_TextChanged;
m_tbForm.KeyDown += m_tbForm_KeyDown;
// Now position the searching animation just above the list
m_searchAnimation = new SearchingAnimation();
m_searchAnimation.Top = m_matchingObjectsBrowser.Top - m_searchAnimation.Height - 5;
m_searchAnimation.Left = m_matchingObjectsBrowser.Right - m_searchAnimation.Width - 10;
// The standard localization code doesn't work, so set these explicitly.
m_btnClose.Text = LexTextControls.ksCancel;
m_btnHelp.Text = LexTextControls.ks_Help_;
m_btnInsert.Text = LexTextControls.ks_Create_;
m_wsLabel.Text = LexTextControls.ks_WritingSystem_;
m_objectsLabel.Text = LexTextControls.ksLexicalEntries;
m_oldSearchKey = string.Empty;
}
示例8: InitializeComponent
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.Windows.Forms.Button selectFileButton;
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(ConverterTest));
System.Windows.Forms.Label label2;
System.Windows.Forms.Label label3;
System.Windows.Forms.HelpProvider helpProvider1;
this.outputFontCombo = new SIL.FieldWorks.Common.Controls.FwOverrideComboBox();
this.convertButton = new System.Windows.Forms.Button();
this.OutputPanel = new System.Windows.Forms.Panel();
this.saveFileButton = new System.Windows.Forms.Button();
this.txtInputFile = new System.Windows.Forms.TextBox();
this.toolTipInputFile = new System.Windows.Forms.ToolTip(this.components);
selectFileButton = new System.Windows.Forms.Button();
label2 = new System.Windows.Forms.Label();
label3 = new System.Windows.Forms.Label();
helpProvider1 = new HelpProvider();
this.SuspendLayout();
//
// selectFileButton
//
helpProvider1.SetHelpString(selectFileButton, resources.GetString("selectFileButton.HelpString"));
resources.ApplyResources(selectFileButton, "selectFileButton");
selectFileButton.Name = "selectFileButton";
helpProvider1.SetShowHelp(selectFileButton, ((bool)(resources.GetObject("selectFileButton.ShowHelp"))));
selectFileButton.Click += new System.EventHandler(this.selectFileButton_Click);
//
// label2
//
resources.ApplyResources(label2, "label2");
helpProvider1.SetHelpString(label2, resources.GetString("label2.HelpString"));
label2.Name = "label2";
helpProvider1.SetShowHelp(label2, ((bool)(resources.GetObject("label2.ShowHelp"))));
//
// outputFontCombo
//
resources.ApplyResources(this.outputFontCombo, "outputFontCombo");
this.outputFontCombo.DropDownStyle = System.Windows.Forms.ComboBoxStyle.DropDownList;
helpProvider1.SetHelpString(this.outputFontCombo, resources.GetString("outputFontCombo.HelpString"));
this.outputFontCombo.Name = "outputFontCombo";
helpProvider1.SetShowHelp(this.outputFontCombo, ((bool)(resources.GetObject("outputFontCombo.ShowHelp"))));
this.outputFontCombo.SelectedIndexChanged += new System.EventHandler(this.outputFontCombo_SelectedIndexChanged);
//
// convertButton
//
resources.ApplyResources(this.convertButton, "convertButton");
helpProvider1.SetHelpString(this.convertButton, resources.GetString("convertButton.HelpString"));
this.convertButton.Name = "convertButton";
helpProvider1.SetShowHelp(this.convertButton, ((bool)(resources.GetObject("convertButton.ShowHelp"))));
this.convertButton.Click += new System.EventHandler(this.convertButton_Click);
//
// label3
//
resources.ApplyResources(label3, "label3");
label3.Name = "label3";
helpProvider1.SetShowHelp(label3, ((bool)(resources.GetObject("label3.ShowHelp"))));
//
// OutputPanel
//
resources.ApplyResources(this.OutputPanel, "OutputPanel");
this.OutputPanel.BackColor = System.Drawing.SystemColors.Control;
this.OutputPanel.BorderStyle = System.Windows.Forms.BorderStyle.Fixed3D;
helpProvider1.SetHelpString(this.OutputPanel, resources.GetString("OutputPanel.HelpString"));
this.OutputPanel.Name = "OutputPanel";
helpProvider1.SetShowHelp(this.OutputPanel, ((bool)(resources.GetObject("OutputPanel.ShowHelp"))));
//
// saveFileButton
//
resources.ApplyResources(this.saveFileButton, "saveFileButton");
helpProvider1.SetHelpString(this.saveFileButton, resources.GetString("saveFileButton.HelpString"));
this.saveFileButton.Name = "saveFileButton";
helpProvider1.SetShowHelp(this.saveFileButton, ((bool)(resources.GetObject("saveFileButton.ShowHelp"))));
this.saveFileButton.Click += new System.EventHandler(this.saveFileButton_Click);
//
// txtInputFile
//
resources.ApplyResources(this.txtInputFile, "txtInputFile");
this.txtInputFile.BackColor = System.Drawing.SystemColors.Window;
this.txtInputFile.Cursor = System.Windows.Forms.Cursors.Arrow;
this.txtInputFile.Name = "txtInputFile";
this.txtInputFile.ReadOnly = true;
helpProvider1.SetShowHelp(this.txtInputFile, ((bool)(resources.GetObject("txtInputFile.ShowHelp"))));
this.txtInputFile.TabStop = false;
//
// ConverterTest
//
this.Controls.Add(this.txtInputFile);
this.Controls.Add(this.convertButton);
this.Controls.Add(this.saveFileButton);
this.Controls.Add(this.OutputPanel);
this.Controls.Add(label3);
this.Controls.Add(label2);
this.Controls.Add(this.outputFontCombo);
this.Controls.Add(selectFileButton);
this.Name = "ConverterTest";
//.........这里部分代码省略.........
示例9: LexImportWizardCharMarkerDlg
/// <summary>
/// Initializes a new instance of the <see cref="LexImportWizardCharMarkerDlg"/> class.
/// </summary>
/// <param name="helpTopicProvider">The help topic provider.</param>
/// <param name="app">The app.</param>
/// <param name="stylesheet">The stylesheet.</param>
public LexImportWizardCharMarkerDlg(IHelpTopicProvider helpTopicProvider, IApp app, IVwStylesheet stylesheet) : this()
{
m_helpTopicProvider = helpTopicProvider;
m_app = app;
m_stylesheet = stylesheet;
helpProvider = new HelpProvider();
helpProvider.HelpNamespace = m_helpTopicProvider.HelpFile;
helpProvider.SetHelpNavigator(this, HelpNavigator.Topic);
helpProvider.SetHelpKeyword(this, m_helpTopicProvider.GetHelpString(s_helpTopic));
helpProvider.SetShowHelp(this, true);
}
示例10: InitializeHelpProvider
/// <summary>
/// Initializes the help provider for the Help... button.
/// N.B. This method requires a mediator to function
/// </summary>
private void InitializeHelpProvider()
{
m_helpProvider = new HelpProvider { HelpNamespace = m_mediator.HelpTopicProvider.HelpFile };
m_helpProvider.SetHelpKeyword(this, m_mediator.HelpTopicProvider.GetHelpString(s_helpTopic));
m_helpProvider.SetHelpNavigator(this, HelpNavigator.Topic);
m_helpProvider.SetShowHelp(this, true);
}
示例11: InitializeComponent
/// -----------------------------------------------------------------------------------
/// <summary>
/// Required method for Designer support - do not modify
/// the contents of this method with the code editor.
/// </summary>
/// -----------------------------------------------------------------------------------
private void InitializeComponent()
{
this.components = new System.ComponentModel.Container();
System.Windows.Forms.Label lblLookup;
System.ComponentModel.ComponentResourceManager resources = new System.ComponentModel.ComponentResourceManager(typeof(LanguageSetup));
System.Windows.Forms.Label lblFindPattern;
System.Windows.Forms.ColumnHeader hdrLanguageName;
System.Windows.Forms.ColumnHeader hdrCountry;
System.Windows.Forms.ColumnHeader hdrEthnologueCode;
System.Windows.Forms.GroupBox grpCurrentLang;
System.Windows.Forms.Label lblCurrentEthCode;
System.Windows.Forms.Label lblCurrentLangName;
System.Windows.Forms.Label lblOtherNames;
System.Windows.Forms.Label lblInstructions1;
System.Windows.Forms.Label lblInstructions2;
System.Windows.Forms.HelpProvider helpProvider1;
this.txtFindPattern = new System.Windows.Forms.TextBox();
this.btnFind = new System.Windows.Forms.Button();
this.lvFindResult = new System.Windows.Forms.ListView();
this.lblCurrentEthCodeValue = new System.Windows.Forms.Label();
this.txtCurrentLangName = new System.Windows.Forms.TextBox();
this.lblOtherNamesList = new System.Windows.Forms.Label();
this.toolTip1 = new System.Windows.Forms.ToolTip(this.components);
this.cboLookup = new SIL.FieldWorks.Common.Controls.FwOverrideComboBox();
lblLookup = new System.Windows.Forms.Label();
lblFindPattern = new System.Windows.Forms.Label();
hdrLanguageName = new System.Windows.Forms.ColumnHeader();
hdrCountry = new System.Windows.Forms.ColumnHeader();
hdrEthnologueCode = new System.Windows.Forms.ColumnHeader();
grpCurrentLang = new System.Windows.Forms.GroupBox();
lblCurrentEthCode = new System.Windows.Forms.Label();
lblCurrentLangName = new System.Windows.Forms.Label();
lblOtherNames = new System.Windows.Forms.Label();
lblInstructions1 = new System.Windows.Forms.Label();
lblInstructions2 = new System.Windows.Forms.Label();
helpProvider1 = new System.Windows.Forms.HelpProvider();
grpCurrentLang.SuspendLayout();
this.SuspendLayout();
//
// lblLookup
//
resources.ApplyResources(lblLookup, "lblLookup");
lblLookup.Name = "lblLookup";
helpProvider1.SetShowHelp(lblLookup, ((bool)(resources.GetObject("lblLookup.ShowHelp"))));
//
// txtFindPattern
//
this.txtFindPattern.AcceptsReturn = true;
resources.ApplyResources(this.txtFindPattern, "txtFindPattern");
helpProvider1.SetHelpString(this.txtFindPattern, resources.GetString("txtFindPattern.HelpString"));
this.txtFindPattern.Name = "txtFindPattern";
helpProvider1.SetShowHelp(this.txtFindPattern, ((bool)(resources.GetObject("txtFindPattern.ShowHelp"))));
this.txtFindPattern.Enter += new System.EventHandler(this.txtFindPattern_Enter);
this.txtFindPattern.Leave += new System.EventHandler(this.txtFindPattern_Leave);
this.txtFindPattern.KeyPress += new System.Windows.Forms.KeyPressEventHandler(this.txtFindPattern_KeyPress);
this.txtFindPattern.TextChanged += new System.EventHandler(this.txtFindPattern_TextChanged);
//
// btnFind
//
resources.ApplyResources(this.btnFind, "btnFind");
helpProvider1.SetHelpString(this.btnFind, resources.GetString("btnFind.HelpString"));
this.btnFind.Name = "btnFind";
helpProvider1.SetShowHelp(this.btnFind, ((bool)(resources.GetObject("btnFind.ShowHelp"))));
this.btnFind.Click += new System.EventHandler(this.btnFind_Click);
//
// lblFindPattern
//
resources.ApplyResources(lblFindPattern, "lblFindPattern");
lblFindPattern.Name = "lblFindPattern";
helpProvider1.SetShowHelp(lblFindPattern, ((bool)(resources.GetObject("lblFindPattern.ShowHelp"))));
//
// lvFindResult
//
resources.ApplyResources(this.lvFindResult, "lvFindResult");
this.lvFindResult.Columns.AddRange(new System.Windows.Forms.ColumnHeader[] {
hdrLanguageName,
hdrCountry,
hdrEthnologueCode});
this.lvFindResult.FullRowSelect = true;
helpProvider1.SetHelpString(this.lvFindResult, resources.GetString("lvFindResult.HelpString"));
this.lvFindResult.HideSelection = false;
this.lvFindResult.MultiSelect = false;
this.lvFindResult.Name = "lvFindResult";
helpProvider1.SetShowHelp(this.lvFindResult, ((bool)(resources.GetObject("lvFindResult.ShowHelp"))));
this.lvFindResult.UseCompatibleStateImageBehavior = false;
this.lvFindResult.View = System.Windows.Forms.View.Details;
this.lvFindResult.Enter += new System.EventHandler(this.lvFindResult_Enter);
this.lvFindResult.SelectedIndexChanged += new System.EventHandler(this.lvFindResult_SelectedIndexChanged);
this.lvFindResult.ColumnClick += new System.Windows.Forms.ColumnClickEventHandler(this.lvFindResult_ColumnClick);
//
// hdrLanguageName
//
resources.ApplyResources(hdrLanguageName, "hdrLanguageName");
//
//.........这里部分代码省略.........
示例12: InitializeComponents
// This method is used in the forms designer.
// Change this method on you own risk
void InitializeComponents()
{
//
// Set up generated class MainForm
//
this.SuspendLayout();
this.Name = "MainForm";
this.Text = "This is my form";
this.Size = new Size(600, 400);
//implement a help provider for this form.
hlp = new HelpProvider();
list = new ListBox();
list.Size = new Size(520,145);
list.Location = new Point(1,1);
list.MultiColumn = true;
list.DrawMode = DrawMode.OwnerDrawFixed;
list.MouseDown += new MouseEventHandler(this.OnMouseDown);
list.DoubleClick += new EventHandler(this.OnDblClick);
list.DrawItem += new DrawItemEventHandler(this.OnDrawItem);
//set the helpstring for the list and enable the dispalying of help when
//the listbox has focus and user presses F1.
hlp.SetHelpString(list,"Shows files and folders in the current folder");
hlp.SetShowHelp(list,true);
prev = new Button();
prev.Text = "Back";
prev.Size = new Size(50,30);
prev.Location = new Point(530,60);
prev.Click += new EventHandler(this.OnPrevClicked);
//set the helpstring for the button and enable the dispalying of help when
//the Back button has focus and user presses F1.
hlp.SetHelpString(prev,"Click to go to parent folder");
hlp.SetShowHelp(prev,true);
fileLabel = new Label();
fileLabel.Size = new Size(590,40);
fileLabel.Location = new Point(1,147);
rich = new RichTextBox();
rich.Size = new Size(590,180);
rich.Location = new Point(1,190);
rich.AllowDrop = true;
rich.DragEnter +=new DragEventHandler(this.OnDragEnter);
rich.DragDrop += new DragEventHandler(this.OnDragDrop);
//set the helpstring for the text box and enable the dispalying of help when
//the rich textbox has focus and user presses F1.
hlp.SetHelpString(rich,"Shows contents of file dropped");
hlp.SetShowHelp(rich,true);
this.ResumeLayout(false);
Controls.Add(list);
Controls.Add(prev);
Controls.Add(fileLabel);
Controls.Add(rich);
}
示例13: txtKullaniciAdi_MouseClick
private void txtKullaniciAdi_MouseClick(object sender, MouseEventArgs e)
{
HelpProvider helper = new HelpProvider();
helper.SetShowHelp(this.txtKullaniciAdi, true);
helper.SetHelpString(this.txtKullaniciAdi, "Help text");
}
开发者ID:recepbostanci,项目名称:An-Automation-About-Sacrifaces-Commercial-Occupations,代码行数:8,代码来源:FrmLogin.cs
示例14: HelpSetup
/// <summary>
/// setup help messages
/// </summary>
void HelpSetup()
{
nshredHelp = new HelpProvider();
nshredHelp.SetShowHelp(tbPath, true);
nshredHelp.SetHelpString(tbPath, rm.GetString("enter_file_name"));
nshredHelp.SetShowHelp(cmdSelect, true);
nshredHelp.SetHelpString(cmdSelect, rm.GetString("open_file_select"));
nshredHelp.SetShowHelp(optFile, true);
nshredHelp.SetHelpString(optFile, rm.GetString("use_shred_file"));
nshredHelp.SetShowHelp(optFolder, true);
nshredHelp.SetHelpString(optFolder, rm.GetString("use_shred_files"));
nshredHelp.SetShowHelp(chkCloseInstance, true);
nshredHelp.SetHelpString(chkCloseInstance, rm.GetString("terminate_running"));
nshredHelp.SetShowHelp(chkSubfolders, true);
nshredHelp.SetHelpString(chkSubfolders, rm.GetString("delete_files_parent"));
nshredHelp.SetShowHelp(cmdShred, true);
nshredHelp.SetHelpString(cmdShred, rm.GetString("begin_shredding"));
}
示例15: BasicPropertiesTest
public void BasicPropertiesTest ()
{
SWF.HelpProvider swfHelpProvider = new SWF.HelpProvider ();
SWF.Button swfButton = new SWF.Button ();
swfButton.Location = new SD.Point (3, 3);
swfButton.Size = new SD.Size (272, 72);
swfButton.Text = "With help";
SWF.Button swfButtonNoHelp = new SWF.Button ();
swfButtonNoHelp.Location = new SD.Point (3, 30);
swfButtonNoHelp.Size = new SD.Size (272, 72);
swfButtonNoHelp.Text = "No help";
//We have to use an event to fake the user click
swfButton.Click += new System.EventHandler (OnControlClicked);
swfHelpProvider.SetShowHelp (swfButton, true);
swfHelpProvider.SetHelpString (swfButton, "I'm showing a button tooltip.");
Form.Controls.Add (swfButton);
Form.Controls.Add (swfButtonNoHelp);
//Testing ToolTipOpenedEvent
bridge.ResetEventLists ();
swfButton.PerformClick (); //Clicking the button will fake the event!
StructureChangedEventTuple eventTuple
= bridge.GetStructureChangedEventAt (0, StructureChangeType.ChildAdded);
Assert.IsNotNull (eventTuple, "GetAutomationEventAt (0)");
//We have the HelpProvider!
IRawElementProviderFragment helpProvider = eventTuple.provider as IRawElementProviderFragment;
Assert.IsNotNull (helpProvider, "helpProvider is null");
TestProperty (helpProvider,
AutomationElementIdentifiers.IsControlElementProperty,
true);
TestProperty (helpProvider,
AutomationElementIdentifiers.IsContentElementProperty,
false);
TestProperty (helpProvider,
AutomationElementIdentifiers.HelpTextProperty,
null);
TestProperty (helpProvider,
AutomationElementIdentifiers.LocalizedControlTypeProperty,
"tool tip");
TestProperty (helpProvider,
AutomationElementIdentifiers.ControlTypeProperty,
ControlType.ToolTip.Id);
TestProperty (helpProvider,
AutomationElementIdentifiers.LabeledByProperty,
null);
TestProperty (helpProvider,
AutomationElementIdentifiers.NameProperty,
swfHelpProvider.GetHelpString (swfButton));
TestProperty (helpProvider,
AutomationElementIdentifiers.IsKeyboardFocusableProperty,
false);
TestProperty (helpProvider,
AutomationElementIdentifiers.ClickablePointProperty,
null);
// TODO: How to allow it?
// bridge.ResetEventLists ();
//
// swfButtonNoHelp.PerformClick (); //Clicking this button will close the tooltip
//
// Assert.AreEqual (1,
// bridge.GetAutomationEventCount (InvokePatternIdentifiers.InvokedEvent),
// "AutomationElementIdentifiers.InvokedEvent");
//
// Assert.IsNotNull (bridge.GetStructureChangedEventAt (0, StructureChangeType.ChildRemoved),
// "AutomationElementIdentifiers.ChildRemoved");
}