Overview
Comment: | [lo] dictionary options: update |
---|---|
Downloads: | Tarball | ZIP archive | SQL archive |
Timelines: | family | ancestors | descendants | both | lo | multid |
Files: | files | file ages | folders |
SHA3-256: |
5c5ea1fd5b63b4a6393de9ad8490d029 |
User & Date: | olr on 2018-02-28 16:28:09 |
Other Links: | branch diff | manifest | tags |
Context
2018-02-28
| ||
17:24 | [lo] lexicon editor: prevent deleting unexistant rows check-in: b156d2110e user: olr tags: lo, multid | |
16:28 | [lo] dictionary options: update check-in: 5c5ea1fd5b user: olr tags: lo, multid | |
16:27 | [lo] lexicon editor: update check-in: 00fe4c5157 user: olr tags: lo, multid | |
Changes
Modified gc_lang/fr/oxt/DictOptions/DictOptions.py from [afd6778ebd] to [3451cecc0b].
︙ | ︙ | |||
39 40 41 42 43 44 45 | dUI = do_strings.getUI(sLang) self.xSettingNode = helpers.getConfigSetting("/org.openoffice.Lightproof_grammalecte/Other/", True) # dialog self.xDialog = self.xSvMgr.createInstanceWithContext('com.sun.star.awt.UnoControlDialogModel', self.ctx) self.xDialog.Width = 200 | | | 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 | dUI = do_strings.getUI(sLang) self.xSettingNode = helpers.getConfigSetting("/org.openoffice.Lightproof_grammalecte/Other/", True) # dialog self.xDialog = self.xSvMgr.createInstanceWithContext('com.sun.star.awt.UnoControlDialogModel', self.ctx) self.xDialog.Width = 200 self.xDialog.Height = 210 self.xDialog.Title = dUI.get('title', "#title#") xWindowSize = helpers.getWindowSize() self.xDialog.PositionX = int((xWindowSize.Width / 2) - (self.xDialog.Width / 2)) self.xDialog.PositionY = int((xWindowSize.Height / 2) - (self.xDialog.Height / 2)) # fonts xFDTitle = uno.createUnoStruct("com.sun.star.awt.FontDescriptor") |
︙ | ︙ | |||
79 80 81 82 83 84 85 | self.xGraphspellSugg = self._addWidget('activate_spell_sugg', 'CheckBox', nX, nY2+15, nWidth, nHeight, Label = dUI.get('activate_spell_sugg', "#err")) self._addWidget('activate_spell_sugg_descr', 'FixedText', nX, nY2+25, nWidth, nHeight*4, Label = dUI.get('activate_spell_sugg_descr', "#err"), MultiLine = True) # Personal dictionary section self._addWidget("personal_section", 'FixedLine', nX, nY3, nWidth, nHeight, Label = dUI.get("personal_section", "#err"), FontDescriptor = xFDTitle) self.xPersonalDic = self._addWidget('activate_personal', 'CheckBox', nX, nY3+15, nWidth, nHeight, Label = dUI.get('activate_personal', "#err")) self._addWidget('activate_personnal_descr', 'FixedText', nX, nY3+25, nWidth, nHeight*3, Label = dUI.get('activate_personal_descr', "#err"), MultiLine = True) | < < < < | | < < < < < < < < < < < < | 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 | self.xGraphspellSugg = self._addWidget('activate_spell_sugg', 'CheckBox', nX, nY2+15, nWidth, nHeight, Label = dUI.get('activate_spell_sugg', "#err")) self._addWidget('activate_spell_sugg_descr', 'FixedText', nX, nY2+25, nWidth, nHeight*4, Label = dUI.get('activate_spell_sugg_descr', "#err"), MultiLine = True) # Personal dictionary section self._addWidget("personal_section", 'FixedLine', nX, nY3, nWidth, nHeight, Label = dUI.get("personal_section", "#err"), FontDescriptor = xFDTitle) self.xPersonalDic = self._addWidget('activate_personal', 'CheckBox', nX, nY3+15, nWidth, nHeight, Label = dUI.get('activate_personal', "#err")) self._addWidget('activate_personnal_descr', 'FixedText', nX, nY3+25, nWidth, nHeight*3, Label = dUI.get('activate_personal_descr', "#err"), MultiLine = True) # Button self._addWidget('apply_button', 'Button', self.xDialog.Width-115, self.xDialog.Height-25, 50, 14, Label = dUI.get('apply_button', "#err"), FontDescriptor = xFDTitle, TextColor = 0x005500) self._addWidget('cancel_button', 'Button', self.xDialog.Width-60, self.xDialog.Height-25, 50, 14, Label = dUI.get('cancel_button', "#err"), FontDescriptor = xFDTitle, TextColor = 0x550000) self._loadOptions() # container self.xContainer = self.xSvMgr.createInstanceWithContext('com.sun.star.awt.UnoControlDialog', self.ctx) self.xContainer.setModel(self.xDialog) self.xContainer.getControl('apply_button').addActionListener(self) self.xContainer.getControl('apply_button').setActionCommand('Apply') self.xContainer.getControl('cancel_button').addActionListener(self) self.xContainer.getControl('cancel_button').setActionCommand('Cancel') self.xContainer.setVisible(False) toolkit = self.xSvMgr.createInstanceWithContext('com.sun.star.awt.ExtToolkit', self.ctx) self.xContainer.createPeer(toolkit, None) self.xContainer.execute() # XActionListener def actionPerformed (self, xActionEvent): try: if xActionEvent.ActionCommand == 'Apply': xChild = self.xSettingNode.getByName("o_fr") xChild.setPropertyValue("use_graphspell", self.xGraphspell.State) xChild.setPropertyValue("use_graphspell_sugg", self.xGraphspellSugg.State) #xChild.setPropertyValue("extended_dic", self.xExtendedDic.State) xChild.setPropertyValue("use_personal_dic", self.xPersonalDic.State) self.xSettingNode.commitChanges() else: pass self.xContainer.endExecute() except: traceback.print_exc() # XJobExecutor |
︙ | ︙ |
Modified gc_lang/fr/oxt/DictOptions/do_strings.py from [a801f3d0f2] to [894505c8e0].
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 | def getUI (sLang): if sLang in dStrings: return dStrings[sLang] return dStrings["fr"] dStrings = { "fr": { "title": "Grammalecte · Options des dictionnaires", "spelling_section": "Correcteur orthographique", "activate_main": "Activer le correcteur orthographique de Grammalecte", "activate_main_descr": "Supplante le correcteur orthographique inclus dans LibreOffice (Hunspell).", "personal_section": "Dictionnaire personnel", "activate_personal": "Utiliser", "activate_personal_descr": "Le dictionnaire personnel est une commodité pour ajouter le vocabulaire qui vous est utile. Il ne supplante pas le dictionnaire commun ; il ne fait qu’ajouter de nouveaux mots.", | > > > > < < < < < < < > > > > < < < < < < < | 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 | def getUI (sLang): if sLang in dStrings: return dStrings[sLang] return dStrings["fr"] dStrings = { "fr": { "title": "Grammalecte · Options des dictionnaires", "spelling_section": "Correcteur orthographique", "activate_main": "Activer le correcteur orthographique de Grammalecte", "activate_main_descr": "Supplante le correcteur orthographique inclus dans LibreOffice (Hunspell).", "suggestion_section": "Moteur de suggestion orthographique", "activate_spell_sugg": "Activer le moteur de suggestion de Grammalecte", "activate_spell_sugg_descr": "Désactivée, cette option remplace la suggestion orthographique de Grammalecte par celle fournie par LibreOffice (Hunspell). Les mots inclus dans le dictionnaire personnalisé ne seront plus inclus aux suggestions.", "personal_section": "Dictionnaire personnel", "activate_personal": "Utiliser", "activate_personal_descr": "Le dictionnaire personnel est une commodité pour ajouter le vocabulaire qui vous est utile. Il ne supplante pas le dictionnaire commun ; il ne fait qu’ajouter de nouveaux mots.", "apply_button": "Appliquer", "cancel_button": "Annuler", }, "en": { "title": "Grammalecte · Options for dictionaries", "spelling_section": "Spell checker", "activate_main": "Activate the spell checker from Grammalecte", "activate_main_descr": "Overrides the spell checker included in LibreOffice (Hunspell)", "suggestion_section": "Spell suggestion engine", "activate_spell_sugg": "Activate the suggestion engine of Grammalecte", "activate_spell_sugg_descr": "Disactivated, this option replace the spell suggestion engine of Grammalecte by the one of LibreOffice (Hunspell). Words included in the personal dictionary won’t be included among suggestions.", "personal_section": "Personal dictionary", "activate_personal": "Use", "activate_personal_descr": "The personal dictionary is a commodity to add the vocabulary you want. It doesn’t override the common dictionary ; it only adds new words.", "apply_button": "Apply", "cancel_button": "Cancel", }, } |