Commits

riaan  committed 1a9f55b

Added 'Find in index' to Designer window

  • Participants
  • Parent commits ef66792
  • Branches Boa_0-4-0_pre

Comments (0)

Files changed (1)

File Views/Designer.py

  wxID_SHOWINSP, wxID_SHOWEDTR, wxID_CTRLHELP, wxID_EDITALIGN, wxID_EDITSIZE,
  wxID_EDITRECREATE, wxID_EDITSNAPGRID, wxID_EDITRELAYOUT, wxID_EDITRELAYOUTSEL,
  wxID_EDITRELAYOUTDESGN, wxID_EDITCREATEORDER, wxID_EDITFITINSIDESIZER,
- wxID_EDITFITSIZER,
-] = Utils.wxNewIds(18)
+ wxID_FINDININDEX, wxID_EDITFITSIZER,
+] = Utils.wxNewIds(19)
 
 [wxID_EDITMOVELEFT, wxID_EDITMOVERIGHT, wxID_EDITMOVEUP, wxID_EDITMOVEDOWN,
  wxID_EDITWIDTHINC, wxID_EDITWIDTHDEC, wxID_EDITHEIGHTINC, wxID_EDITHEIGHTDEC,
         self.menu.Append(wxID_EDITALIGN, 'Align...')
         self.menu.Append(wxID_EDITSIZE, 'Size...')
         self.menu.AppendSeparator()
+        Utils.appendMenuItem(self.menu, wxID_FINDININDEX,
+              'Find in index...', Preferences.keyDefs['HelpFind'], '',
+              'Pops up a text input for starting a search of the help indexes')
+        self.menu.AppendSeparator()
         self.menu.Append(wxID_EDITCREATEORDER, 'Creation/Tab order...')
 
         EVT_CLOSE(self, self.OnCloseWindow)
         EVT_MENU(self, wxID_EDITRELAYOUTDESGN, self.OnRelayoutDesigner)
         EVT_MENU(self, wxID_EDITSNAPGRID, self.OnSnapToGrid)
         EVT_MENU(self, wxID_EDITCREATEORDER, self.OnCreationOrder)
+        EVT_MENU(self, wxID_FINDININDEX, self.OnFindInIndex)
         EVT_MENU(self, wxID_EDITFITSIZER, self.OnFitSizer)
         #EVT_MENU(self, wxID_EDITFITINSIDESIZER, self.OnFitInsideSizer)
         
                           ('SelectRight', wxID_EDITSELECTRIGHT),
                           ('SelectUp', wxID_EDITSELECTUP),
                           ('SelectDown', wxID_EDITSELECTDOWN),
+                          
+                          ('HelpFind', wxID_FINDININDEX),
                         ):
             tpe, key, code = Preferences.keyDefs[name]
             accLst.append((tpe, key, wId))
                 selName = ''
             self.showCreationOrderDlg(selName)
 
+    def OnFindInIndex(self, event):
+        self.model.editor.OnHelpFindIndex(event)
+
 #---Inspector session-----------------------------------------------------------
     def doPost(self, inspector):
         self.saveOnClose = true