eric7/Preferences/ConfigurationDialog.py

branch
eric7
changeset 8885
b0bbe8bda1f2
parent 8881
54e42bc2437a
child 8888
e374ffbc1484
equal deleted inserted replaced
8884:74a7c9c7d424 8885:b0bbe8bda1f2
67 """ 67 """
68 DEFAULTMODE = 0 68 DEFAULTMODE = 0
69 TRAYSTARTERMODE = 1 69 TRAYSTARTERMODE = 1
70 HEXEDITORMODE = 2 70 HEXEDITORMODE = 2
71 WEBBROWSERMODE = 3 71 WEBBROWSERMODE = 3
72 EDITORMODE = 4
72 73
73 74
74 class ConfigurationWidget(QWidget): 75 class ConfigurationWidget(QWidget):
75 """ 76 """
76 Class implementing a dialog for the configuration of eric. 77 Class implementing a dialog for the configuration of eric.
379 380
380 self.configItems.update( 381 self.configItems.update(
381 ericApp().getObject("PluginManager").getPluginConfigData()) 382 ericApp().getObject("PluginManager").getPluginConfigData())
382 383
383 # TODO: add mode for Mini Editor (?) 384 # TODO: add mode for Mini Editor (?)
385 elif displayMode == ConfigurationMode.EDITORMODE:
386 self.configItems = {
387 # key : [display string, pixmap name, dialog module name or
388 # page creation function, parent key,
389 # reference to configuration page (must always be last)]
390 # The dialog module must have the module function 'create' to
391 # create the configuration page. This must have the method
392 # 'save' to save the settings.
393 "iconsPage":
394 [self.tr("Icons"), "preferences-icons",
395 "IconsPage", None, None],
396 "interfacePage":
397 [self.tr("Interface"), "preferences-interface",
398 "InterfaceLightPage", None, None],
399 "printerPage":
400 [self.tr("Printer"), "preferences-printer",
401 "PrinterPage", None, None],
402
403 "0editorPage":
404 [self.tr("Editor"), "preferences-editor",
405 None, None, None],
406 "editorGeneralPage":
407 [self.tr("General"), "preferences-general",
408 "EditorGeneralPage", "0editorPage", None],
409 "editorFilePage":
410 [self.tr("Filehandling"),
411 "preferences-filehandling",
412 "EditorFilePage", "0editorPage", None],
413 "editorSearchPage":
414 [self.tr("Searching"), "preferences-search",
415 "EditorSearchPage", "0editorPage", None],
416 "editorSpellCheckingPage":
417 [self.tr("Spell checking"),
418 "preferences-spellchecking",
419 "EditorSpellCheckingPage", "0editorPage", None],
420 "editorStylesPage":
421 [self.tr("Style"), "preferences-styles",
422 "EditorStylesPage", "0editorPage", None],
423 "editorTypingPage":
424 [self.tr("Typing"), "preferences-typing",
425 "EditorTypingPage", "0editorPage", None],
426
427 "1editorLexerPage":
428 [self.tr("Highlighters"),
429 "preferences-highlighting-styles",
430 None, "0editorPage", None],
431 "editorHighlightersPage":
432 [self.tr("Filetype Associations"),
433 "preferences-highlighter-association",
434 "EditorHighlightersPage", "1editorLexerPage", None],
435 "editorHighlightingStylesPage":
436 [self.tr("Styles"),
437 "preferences-highlighting-styles",
438 "EditorHighlightingStylesPage", "1editorLexerPage", None],
439 "editorKeywordsPage":
440 [self.tr("Keywords"), "preferences-keywords",
441 "EditorKeywordsPage", "1editorLexerPage", None],
442 "editorPropertiesPage":
443 [self.tr("Properties"), "preferences-properties",
444 "EditorPropertiesPage", "1editorLexerPage", None],
445 }
384 446
385 elif displayMode == ConfigurationMode.WEBBROWSERMODE: 447 elif displayMode == ConfigurationMode.WEBBROWSERMODE:
386 self.configItems = { 448 self.configItems = {
387 # key : [display string, pixmap name, dialog module name or 449 # key : [display string, pixmap name, dialog module name or
388 # page creation function, parent key, 450 # page creation function, parent key,
389 # reference to configuration page (must always be last)] 451 # reference to configuration page (must always be last)]
390 # The dialog module must have the module function 'create' to 452 # The dialog module must have the module function 'create' to
391 # create the configuration page. This must have the method 453 # create the configuration page. This must have the method
392 # 'save' to save the settings. 454 # 'save' to save the settings.
455 "iconsPage":
456 [self.tr("Icons"), "preferences-icons",
457 "IconsPage", None, None],
393 "interfacePage": 458 "interfacePage":
394 [self.tr("Interface"), "preferences-interface", 459 [self.tr("Interface"), "preferences-interface",
395 "InterfaceLightPage", None, None], 460 "InterfaceLightPage", None, None],
396 "networkPage": 461 "networkPage":
397 [self.tr("Network"), "preferences-network", 462 [self.tr("Network"), "preferences-network",
444 # page creation function, parent key, 509 # page creation function, parent key,
445 # reference to configuration page (must always be last)] 510 # reference to configuration page (must always be last)]
446 # The dialog module must have the module function 'create' to 511 # The dialog module must have the module function 'create' to
447 # create the configuration page. This must have the method 512 # create the configuration page. This must have the method
448 # 'save' to save the settings. 513 # 'save' to save the settings.
514 "iconsPage":
515 [self.tr("Icons"), "preferences-icons",
516 "IconsPage", None, None],
449 "interfacePage": 517 "interfacePage":
450 [self.tr("Interface"), "preferences-interface", 518 [self.tr("Interface"), "preferences-interface",
451 "InterfaceLightPage", None, None], 519 "InterfaceLightPage", None, None],
452 "hexEditorPage": 520 "hexEditorPage":
453 [self.tr("Hex Editor"), "hexEditor", 521 [self.tr("Hex Editor"), "hexEditor",
461 # page creation function, parent key, 529 # page creation function, parent key,
462 # reference to configuration page (must always be last)] 530 # reference to configuration page (must always be last)]
463 # The dialog module must have the module function 'create' to 531 # The dialog module must have the module function 'create' to
464 # create the configuration page. This must have the method 532 # create the configuration page. This must have the method
465 # 'save' to save the settings. 533 # 'save' to save the settings.
534 "iconsPage":
535 [self.tr("Icons"), "preferences-icons",
536 "IconsPage", None, None],
466 "interfacePage": 537 "interfacePage":
467 [self.tr("Interface"), "preferences-interface", 538 [self.tr("Interface"), "preferences-interface",
468 "InterfaceLightPage", None, None], 539 "InterfaceLightPage", None, None],
469 } 540 }
470 541

eric ide

mercurial