/// <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; }
/// <summary> /// Constructor. /// </summary> public InsertEntryDlg() { // // Required for Windows Form Designer support // InitializeComponent(); AccessibleName = GetType().Name; // Figure out where to locate the dlg. using (var regKey = SettingsKey) { object obj = regKey.GetValue("InsertX"); if (obj != null) { var x = (int)obj; var y = (int)regKey.GetValue("InsertY"); var width = (int)regKey.GetValue("InsertWidth", Width); var height = (int)regKey.GetValue("InsertHeight", Height); var rect = new Rectangle(x, y, width, height); ScreenUtils.EnsureVisibleRect(ref rect); DesktopBounds = rect; StartPosition = FormStartPosition.Manual; } } m_helpProvider = new HelpProvider(); m_helpProvider.SetHelpNavigator(this, HelpNavigator.Topic); m_updateTextMonitor = new SimpleMonitor(); m_searchAnimation = new SearchingAnimation(); AdjustWidthForLinkLabelGroupBox(); }