Compare commits
15 Commits
| Author | SHA1 | Date | |
|---|---|---|---|
| c4890f31af | |||
| c44245189a | |||
| c7b8e4a30d | |||
| 20fe1a7e30 | |||
| 25931758f7 | |||
| daf57ef22c | |||
| 1d2d727fa2 | |||
| 11bd7107d2 | |||
| 95d33047fa | |||
| 523b896053 | |||
| 9152455227 | |||
| c0fdaca4d0 | |||
| 8312a842c1 | |||
| 07138197cb | |||
| ed78ffc248 |
@@ -8,13 +8,11 @@ set -e # Exit on error
|
||||
|
||||
# Colors for output (only if stdout is a terminal)
|
||||
if [[ -t 1 ]]; then
|
||||
RED='\033[0;31m'
|
||||
GREEN='\033[0;32m'
|
||||
YELLOW='\033[1;33m'
|
||||
BLUE='\033[0;34m'
|
||||
NC='\033[0m' # No Color
|
||||
else
|
||||
RED=''
|
||||
GREEN=''
|
||||
YELLOW=''
|
||||
BLUE=''
|
||||
@@ -56,12 +54,6 @@ if [[ $REPLY =~ ^[Yy]$ ]]; then
|
||||
|
||||
# Remove data files
|
||||
|
||||
# Remove desktop files
|
||||
if [[ -f "$HOME/.local/share/applications/cthulhu-autostart.desktop" ]]; then
|
||||
rm -f "$HOME/.local/share/applications/cthulhu-autostart.desktop"
|
||||
echo " Removed: ~/.local/share/applications/cthulhu-autostart.desktop"
|
||||
fi
|
||||
|
||||
# Remove icons
|
||||
for size in 16x16 22x22 24x24 32x32 48x48 256x256 scalable symbolic; do
|
||||
icon_path="$HOME/.local/share/icons/hicolor/$size/apps"
|
||||
|
||||
@@ -1,11 +0,0 @@
|
||||
[Desktop Entry]
|
||||
Type=Application
|
||||
Name=Cthulhu Screen Reader
|
||||
Exec=cthulhu
|
||||
NoDisplay=true
|
||||
# Desktop-neutral autostart - no GNOME-specific conditions
|
||||
# Users can enable/disable via their desktop environment's accessibility settings
|
||||
# or by adding/removing this file from ~/.config/autostart/
|
||||
X-GNOME-AutoRestart=true
|
||||
Categories=Accessibility;
|
||||
Keywords=screen;reader;accessibility;speech;braille;
|
||||
@@ -1,7 +1,7 @@
|
||||
# Maintainer: Storm Dragon <storm_dragon@stormux.org>
|
||||
|
||||
pkgname=cthulhu
|
||||
pkgver=2026.02.17
|
||||
pkgver=2026.03.02
|
||||
pkgrel=1
|
||||
pkgdesc="Desktop-agnostic screen reader with plugin system, forked from Orca"
|
||||
url="https://git.stormux.org/storm/cthulhu"
|
||||
@@ -84,7 +84,7 @@ makedepends=(
|
||||
)
|
||||
install=cthulhu.install
|
||||
source=(
|
||||
"git+https://git.stormux.org/storm/cthulhu.git"
|
||||
"git+https://git.stormux.org/storm/cthulhu.git#tag=${pkgver}"
|
||||
"cthulhu.install"
|
||||
)
|
||||
b2sums=(
|
||||
@@ -92,11 +92,6 @@ b2sums=(
|
||||
'SKIP'
|
||||
)
|
||||
|
||||
pkgver() {
|
||||
cd cthulhu
|
||||
grep "^version = " src/cthulhu/cthulhuVersion.py | sed 's/version = "\(.*\)"/\1/'
|
||||
}
|
||||
|
||||
build() {
|
||||
cd cthulhu
|
||||
arch-meson _build
|
||||
|
||||
+1
-11
@@ -1,5 +1,5 @@
|
||||
project('cthulhu',
|
||||
version: '2026.02.17-master',
|
||||
version: '2026.03.02-master',
|
||||
meson_version: '>= 1.0.0',
|
||||
)
|
||||
|
||||
@@ -93,16 +93,6 @@ else
|
||||
summary += {'sound support': 'no (missing gstreamer)'}
|
||||
endif
|
||||
|
||||
# Integration with session startup
|
||||
i18n.merge_file(
|
||||
input: 'cthulhu-autostart.desktop.in',
|
||||
output: '@BASENAME@',
|
||||
type: 'desktop',
|
||||
po_dir: meson.project_source_root() / 'po',
|
||||
install: true,
|
||||
install_dir: get_option('sysconfdir') / 'xdg' / 'autostart',
|
||||
)
|
||||
|
||||
# Update icon cache manually (desktop-neutral) - optional, ignore failures
|
||||
gtk_update_icon_cache = find_program('gtk4-update-icon-cache', required: false)
|
||||
if gtk_update_icon_cache.found()
|
||||
|
||||
@@ -1,6 +1,5 @@
|
||||
# List of source files containing translatable strings.
|
||||
# Please keep this file sorted alphabetically.
|
||||
cthulhu-autostart.desktop.in
|
||||
src/cthulhu/braille_rolenames.py
|
||||
src/cthulhu/brltablenames.py
|
||||
src/cthulhu/chnames.py
|
||||
|
||||
@@ -13,11 +13,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-DamnedLies-Scope: partial\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr ""
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Poedit 1.6.10\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lector de pantalla Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "lector de pantalla; fabla; braille;"
|
||||
|
||||
@@ -24,11 +24,9 @@ msgstr ""
|
||||
"&& n%100<=10 ? 3 : n%100>=11 && n%100<=99 ? 4 : 5;\n"
|
||||
"X-Poedit-Language: Arabic\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "قارئ الشاشة Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "شاشة;قارئ;إمكانية الوصول;كلام;برايل;"
|
||||
|
||||
|
||||
@@ -19,11 +19,9 @@ msgstr ""
|
||||
"X-Poedit-Language: Asturian\n"
|
||||
"X-Poedit-SourceCharset: utf-8\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Llector de pantalla d'Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -17,11 +17,9 @@ msgstr ""
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
"X-Project-Style: gnome\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Чытач з экрана Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "чытач з экрана;экран;голас;маўленне;Брайль;"
|
||||
|
||||
@@ -23,11 +23,9 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu — екранен четец"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "екран;четец;достъпност;говор;брайл;"
|
||||
|
||||
|
||||
@@ -21,12 +21,10 @@ msgstr ""
|
||||
"X-Generator: KBabel 1.9.1\n"
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "অর্কা স্ক্রীন রিডার / বিবর্ধন"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,12 +18,10 @@ msgstr ""
|
||||
"X-Generator: KBabel 1.9.1\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu'র বৈশিষ্ট্য"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -15,11 +15,9 @@ msgstr ""
|
||||
"X-Launchpad-Export-Date: 2015-02-05 06:46+0000\n"
|
||||
"X-Generator: Poedit 1.7.4\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu čitač ekrana"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "čitač ekrana;govor;brailleovo pismo;"
|
||||
|
||||
|
||||
@@ -27,11 +27,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lector de pantalla Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "pantalla;lector;accessibilitat;veu;braille;"
|
||||
|
||||
|
||||
@@ -27,11 +27,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
"X-Generator: Poedit 1.8.11\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lector de pantalla Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "lector de pantalla;pronunciació;braille;"
|
||||
|
||||
|
||||
@@ -19,12 +19,10 @@ msgstr ""
|
||||
"X-Launchpad-Export-Date: 2020-05-04 21:32+0000\n"
|
||||
"X-Generator: Poedit 2.3\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "خوێنەری پەردەی ئۆرکا"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -24,11 +24,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=3; plural=(n==1) ? 0 : (n>=2 && n<=4) ? 1 : 2;\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Čtečka obrazovky Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "obrazovka;čtečka;přístupnost;řeč;braille;"
|
||||
|
||||
|
||||
@@ -17,12 +17,10 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=4; plural= (n==1) ? 0 : (n==2) ? 1 : (n != 8 && n != "
|
||||
"11) ? 2 : 3;\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Hoffterau Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -32,11 +32,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Poedit 3.0.1\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Skærmlæseren Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "skærm;læser;tilgængelighed;tale;braille;"
|
||||
|
||||
|
||||
@@ -37,11 +37,9 @@ msgstr ""
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
"X-Project-Style: gnome\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu-Bildschirmleser"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "bildschirm;leser;barrierefreiheit;sprache;braille;"
|
||||
|
||||
|
||||
@@ -20,12 +20,10 @@ msgstr ""
|
||||
"X-Poedit-SourceCharset: utf-8\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n!=1)\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "ཨོར་ཀ་གསལ་གཞི་ལྷག་བྱེད་/ཆེ་ཤེལ་"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -28,11 +28,9 @@ msgstr ""
|
||||
"X-Generator: Poedit 2.3\n"
|
||||
"X-Project-Style: gnome\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Αναγνώστης οθόνης Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "οθόνη;αναγνώστης;προσβασιμότητα;ομιλία;μπράιγ;"
|
||||
|
||||
|
||||
@@ -17,11 +17,9 @@ msgstr ""
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr ""
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -21,11 +21,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Gtranslator 45.3\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu Screen Reader"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "screen reader;speech;braille;"
|
||||
|
||||
|
||||
@@ -21,11 +21,9 @@ msgstr ""
|
||||
"X-Generator: Poedit 3.2.2\n"
|
||||
"X-Project-Style: gnome\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Ekranlegilo Orko"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "ekranlegilo;parolo;brajlo;"
|
||||
|
||||
@@ -28,11 +28,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
|
||||
"X-Generator: Gtranslator 45.alpha0\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lector de pantalla Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "lector;pantalla;accesibilidad;voz;braille;"
|
||||
|
||||
|
||||
@@ -20,12 +20,10 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu ekraanilugeja ja luup"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu pantaila-irakurlea"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "pantaila;irakurlea;irisgarritasuna;mintzamena;braillea;"
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 3.4\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "صفحهخوان اورکا"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -27,11 +27,9 @@ msgstr ""
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
"X-Poedit-Bookmarks: 814,-1,-1,-1,-1,-1,-1,-1,-1,-1\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu-näytönlukija"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "näyttö;lukija;saavutettavuus;puhe;pistekirjoitus;"
|
||||
|
||||
|
||||
@@ -31,11 +31,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lecteur d’écran Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "lecteur;écran;accessibilité;parole;braille;"
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Poedit 2.0.3\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr ""
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,12 +18,10 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=5; plural=n==1 ? 0 : (n%10==1 || n%10==2) ? 1 : "
|
||||
"(n%10>=3 && n%10<= 6) ? 2 : ((n%10>=7 && n%10<=9) || n==10) ? 3 : 4;\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Léitheoir Scáileáin agus Formhéadaitheoir Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -34,11 +34,9 @@ msgstr ""
|
||||
"X-DL-Domain: po\n"
|
||||
"X-DL-State: Translating\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lector da pantalla Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "pantalla;lector;accesibilidade;fala;braille;"
|
||||
|
||||
|
||||
@@ -33,12 +33,10 @@ msgstr ""
|
||||
"\n"
|
||||
"\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu સ્ક્રીન વાંચક અને વિસ્તૃતકારક"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -14,11 +14,9 @@ msgstr ""
|
||||
"2 : 3);\n"
|
||||
"X-Generator: Poedit 3.4.1\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "מקריא המסך Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "מסך;קורא;נגישות;דיבור;ברייל;"
|
||||
|
||||
|
||||
@@ -22,11 +22,9 @@ msgstr ""
|
||||
"\n"
|
||||
"X-Generator: Lokalize 1.5\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu स्क्रीन वाचक"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "स्क्रीन रीडर;भाषण;ब्रेल;"
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"X-Launchpad-Export-Date: 2016-09-15 12:40+0000\n"
|
||||
"X-Generator: Poedit 1.6.10\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu čitač zaslona"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "čitač zaslona;govor;brajica;"
|
||||
|
||||
|
||||
@@ -22,11 +22,9 @@ msgstr ""
|
||||
"X-Generator: Poedit 2.3\n"
|
||||
|
||||
# Megjegyzés: Mivel mindenhol régóta Gáborral egyeztetve az Cthulhu nevet magyarosan Orkaként írjuk a fordításban, így a fordítást megváltoztattam Orka képernyőolvasóra az Cthulhu képernyőolvasó helyett.
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Orka képernyőolvasó"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "képernyő;olvasó;akadálymentesítés;beszéd;braille;"
|
||||
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Pembaca Layar Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "layar;pembaca;aksesibilitas;ucapan;braille;"
|
||||
|
||||
|
||||
@@ -17,11 +17,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=n != 1;\n"
|
||||
"X-Generator: Lokalize 1.5\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu skjálestur"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -39,11 +39,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1)\n"
|
||||
"X-Generator: Gtranslator 42.0\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lettore schermo Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "lettore;schermo;accessibilità;voce;braille;"
|
||||
|
||||
|
||||
@@ -25,11 +25,9 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu スクリーンリーダー"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "スクリーン;リーダー;アクセシビリティ;音声;点字;"
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu - ეკრანის მკითხველი"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "ეკრანი;მკითხველი;ხელმისაწვდომობა;მეტყველება;ბრაილი;"
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n > 1);\n"
|
||||
"X-Generator: Poedit 3.0\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr ""
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu экраннан оқитын қолданбасы"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,12 +18,10 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: KBabel 1.11.4\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "ಆದ್ಯತೆಗಳು"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -15,11 +15,9 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu 화면 낭독기"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "화면;리더;접근성;음성;점자;"
|
||||
|
||||
|
||||
@@ -25,11 +25,9 @@ msgstr ""
|
||||
"(n%100<10 || n%100>=20) ? 1 : 2);\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu ekrano skaityklė"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "ekrano skaityklė;kalba;brailio raštas;"
|
||||
|
||||
|
||||
@@ -23,11 +23,9 @@ msgstr ""
|
||||
"2);\n"
|
||||
"X-Generator: Lokalize 21.12.3\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu ekrāna lasītājs"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "ekrāna lasītājs;runa;Brails;"
|
||||
|
||||
|
||||
@@ -19,12 +19,10 @@ msgstr ""
|
||||
"\n"
|
||||
"\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu स्क्रीन पाठक / आवर्द्धक"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural= n==1 || n%10==1 ? 0 : 1\n"
|
||||
"X-Generator: KBabel 1.11.4\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu читач на екранот"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -22,12 +22,10 @@ msgstr ""
|
||||
"X-Generator: Poedit 2.0.1\n"
|
||||
"X-Project-Style: gnome\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "സ്ക്രീന് വായന അവസാനിപ്പിക്കാം."
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,12 +18,10 @@ msgstr ""
|
||||
"X-Generator: KBabel 1.9.1\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "वर्धक भिंग"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 2.0.6\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Pembaca skrin Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "skrin;pembaca;kebolehcapaian;pertuturan;braille;"
|
||||
|
||||
|
||||
@@ -19,11 +19,9 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu skjermleser"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "skjerm;leser;tilgjengelighet;tale;blindeskrift;"
|
||||
|
||||
|
||||
@@ -13,11 +13,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Poedit 3.0.1\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "ओर्का दृष्टि वाचक"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "दृष्टि वाचक; वाचन;ब्रेल;"
|
||||
|
||||
|
||||
@@ -31,11 +31,9 @@ msgstr ""
|
||||
"X-Generator: Poedit 3.2.2\n"
|
||||
|
||||
# vergrootglas/loep
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu schermlezer"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "scherm;lezer;toegankelijkheid;spraak;braille;"
|
||||
|
||||
|
||||
@@ -18,12 +18,10 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu skjermlesar og forstørringsglas"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -23,11 +23,9 @@ msgstr ""
|
||||
"X-Launchpad-Export-Date: 2015-05-21 18:05+0000\n"
|
||||
"X-Project-Style: gnome\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Lector d'ecran Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
"lector d'ecran;oral;braille;votz;sintèsi vocala;sintesi vocala;lector "
|
||||
|
||||
@@ -22,12 +22,10 @@ msgstr ""
|
||||
"\n"
|
||||
"\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "ଓର୍କା ସ୍କ୍ରିନ ପାଠକ /ଛୋଟକୁ ବଡ ଦେଖଉଥିବା ଉପକରଣ "
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -24,11 +24,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Poedit-Bookmarks: 589,-1,-1,-1,-1,-1,-1,-1,-1,-1\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "ਓਰਕਾ ਸਕਰੀਨ ਰੀਡਰ"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -24,11 +24,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 "
|
||||
"|| n%100>=20) ? 1 : 2);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Czytnik ekranowy Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "czytnik;ekran;dostępność;mowa;braille;"
|
||||
|
||||
|
||||
@@ -28,11 +28,9 @@ msgstr ""
|
||||
"X-Source-Language: C\n"
|
||||
"X-Project-Style: gnome\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Leitor de ecrã Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "leitor;ecrã;acessibilidade;voz;braille;"
|
||||
|
||||
|
||||
@@ -49,11 +49,9 @@ msgstr ""
|
||||
"X-DL-Domain: po\n"
|
||||
"X-DL-State: Translating\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Leitor de tela Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "leitor;tela;acessibilidade;voz;braille;"
|
||||
|
||||
|
||||
@@ -24,11 +24,9 @@ msgstr ""
|
||||
"X-Project-Style: gnome\n"
|
||||
"X-Poedit-SourceCharset: UTF-8\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cititorul de ecran Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "ecran;cititor;accesibilitate;vorbire;braille;"
|
||||
|
||||
|
||||
@@ -22,11 +22,9 @@ msgstr ""
|
||||
"n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Экранный диктор Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "экран;чтец;доступность;речь;брайль;"
|
||||
|
||||
|
||||
@@ -24,11 +24,9 @@ msgstr ""
|
||||
"Content-Type: text/plain; charset=UTF-8\n"
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr ""
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: KBabel 1.11.4\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr ""
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -19,11 +19,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=3; plural=(n==1) ? 1 : (n>=2 && n<=4) ? 2 : 0;\n"
|
||||
"X-Generator: Gtranslator 2.91.7\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Ukončí čítačku obrazovky"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -22,11 +22,9 @@ msgstr ""
|
||||
"X-Poedit-SourceCharset: utf-8\n"
|
||||
"X-Generator: Poedit 3.0.1\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Zaslonski bralnik Orka"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "govor;zaslonski bralnik;Braillova pisava;brajica;povečevalnik"
|
||||
|
||||
|
||||
@@ -17,12 +17,10 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
#, fuzzy
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Ekrani Zmadhues (Lupë)"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -21,11 +21,9 @@ msgstr ""
|
||||
"X-Project-Style: gnome\n"
|
||||
"X-Generator: Poedit 3.1.1\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Читач екрана Орка"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "читач екрана;говор;брајева азбука;"
|
||||
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"X-Project-Style: gnome\n"
|
||||
"X-Generator: Poedit 2.0.3\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Čitač ekrana Orka"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "čitač ekrana;govor;brajeva azbuka;"
|
||||
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu skärmläsare"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "skärm;läsare;tillgänglighet;tal;punktskrift;"
|
||||
|
||||
|
||||
@@ -24,11 +24,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n!=1);\\n\n"
|
||||
"\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "ஆர்கா திரை படிப்பி "
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "திரைபடிப்பான்;பேசுதல்;ப்ரெய்ல்;"
|
||||
|
||||
@@ -23,11 +23,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n!=1);\n"
|
||||
"X-Generator: KBabel 1.11.4\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "ఓర్కా తెరచదువరి"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr ""
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
|
||||
"X-Generator: Poedit 1.6.3\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Хонандаи экрани Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "хонандаи экран;нутқ;брайл;"
|
||||
|
||||
@@ -19,11 +19,9 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "โปรแกรมอ่านหน้าจอ Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "หน้าจอ;อ่าน;การเข้าถึง;เสียงพูด;อักษรเบรลล์;"
|
||||
|
||||
|
||||
@@ -27,11 +27,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 3.4\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu Ekran Okuyucu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "ekran;okuyucu;erişilebilirlik;konuşma;braille;"
|
||||
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"Content-Transfer-Encoding: 8bit\n"
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu ئېكران ئوقۇغۇ"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "screen reader;speech;braille;ئېكران ئوقۇغۇچ;تاۋۇش;ئەمالار ئېلىپبەسى;"
|
||||
|
||||
@@ -26,11 +26,9 @@ msgstr ""
|
||||
"n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2;\n"
|
||||
"X-Generator: Lokalize 20.12.0\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Інструмент читання з екрана «Cthulhu»"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "екран;читач;доступність;мовлення;брайль;"
|
||||
|
||||
|
||||
@@ -18,11 +18,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: LocFactoryEditor 1.8\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Trình đọc màn hình Cthulhu"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "màn hình;đọc;trợ năng;giọng nói;chữ nổi;"
|
||||
|
||||
|
||||
@@ -29,11 +29,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 3.3.2\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu 屏幕阅读器"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "屏幕;阅读器;无障碍;语音;盲文;"
|
||||
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 1.6.5\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu 螢幕閱讀器"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
#, fuzzy
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "screen reader;speech;braille;螢幕閱讀器;語音;點字;"
|
||||
|
||||
@@ -20,11 +20,9 @@ msgstr ""
|
||||
"Plural-Forms: nplurals=1; plural=0;\n"
|
||||
"X-Generator: Poedit 1.8.12\n"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:3
|
||||
msgid "Cthulhu Screen Reader"
|
||||
msgstr "Cthulhu 螢幕閱讀器"
|
||||
|
||||
#: cthulhu-autostart.desktop.in:11
|
||||
msgid "screen;reader;accessibility;speech;braille;"
|
||||
msgstr "螢幕;閱讀器;無障礙;語音;點字;"
|
||||
|
||||
|
||||
@@ -85,12 +85,16 @@ class Backend:
|
||||
with open(fileName, 'w', encoding='utf-8') as settingsFile:
|
||||
settingsFile.write(dumps(prefsDoc))
|
||||
|
||||
def _updateTable(self, targetTable, newValues):
|
||||
def _updateTable(self, targetTable, newValues, preserveMissingKeys=None):
|
||||
if not isinstance(newValues, dict):
|
||||
return
|
||||
|
||||
preserveMissingKeys = set(preserveMissingKeys or [])
|
||||
|
||||
for key in list(targetTable.keys()):
|
||||
if key not in newValues:
|
||||
if key in preserveMissingKeys:
|
||||
continue
|
||||
del targetTable[key]
|
||||
continue
|
||||
newValue = newValues[key]
|
||||
@@ -173,7 +177,12 @@ class Backend:
|
||||
profiles[profile] = {}
|
||||
profileTable = profiles[profile]
|
||||
|
||||
self._updateTable(profileTable, general)
|
||||
# Keep plugin persistence keys when callers provide partial updates.
|
||||
self._updateTable(
|
||||
profileTable,
|
||||
general,
|
||||
preserveMissingKeys={"activePlugins", "pluginSources"},
|
||||
)
|
||||
self._writeDocument(self.settingsFile, prefsDoc)
|
||||
|
||||
def _getSettings(self):
|
||||
@@ -213,12 +222,33 @@ class Backend:
|
||||
|
||||
return settingsDict
|
||||
|
||||
def _hasLikelyCustomEchoVoice(self, echoVoice, defaultVoice):
|
||||
"""Return True when echoVoice appears intentionally customized."""
|
||||
|
||||
if not echoVoice:
|
||||
return False
|
||||
|
||||
echoEstablished = bool(echoVoice.get('established', False))
|
||||
if not defaultVoice:
|
||||
return echoEstablished or bool(echoVoice.get(acss.ACSS.FAMILY))
|
||||
|
||||
for key in [acss.ACSS.RATE, acss.ACSS.AVERAGE_PITCH, acss.ACSS.GAIN, acss.ACSS.FAMILY]:
|
||||
echoValue = echoVoice.get(key)
|
||||
defaultValue = defaultVoice.get(key)
|
||||
if echoValue is not None and echoValue != defaultValue:
|
||||
return True
|
||||
|
||||
return echoEstablished and bool(echoVoice.get(acss.ACSS.FAMILY))
|
||||
|
||||
def getGeneral(self, profile=None):
|
||||
""" Get general settings from default settings and
|
||||
override with profile values. """
|
||||
self._getSettings()
|
||||
generalSettings = self.general.copy()
|
||||
generalSettings = self._migrateSettings(generalSettings)
|
||||
# Plugin state is profile-scoped; ignore legacy/global values.
|
||||
generalSettings.pop('activePlugins', None)
|
||||
generalSettings.pop('pluginSources', None)
|
||||
defaultProfile = generalSettings.get('startingProfile',
|
||||
['Default', 'default'])
|
||||
if profile is None:
|
||||
@@ -229,8 +259,24 @@ class Backend:
|
||||
if key == 'voices':
|
||||
for voiceType, voiceDef in value.items():
|
||||
value[voiceType] = acss.ACSS(voiceDef)
|
||||
if key == 'echoVoice' and isinstance(value, dict):
|
||||
value = acss.ACSS(value)
|
||||
if key not in ['startingProfile', 'activeProfile']:
|
||||
generalSettings[key] = value
|
||||
|
||||
# Backward compatibility: recover custom echo behavior when legacy
|
||||
# profiles have echoVoice but are missing custom-echo toggle keys.
|
||||
if 'useCustomEchoVoice' not in profileSettings:
|
||||
voices = generalSettings.get('voices') or {}
|
||||
defaultVoice = voices.get(settings.DEFAULT_VOICE)
|
||||
echoVoice = generalSettings.get('echoVoice')
|
||||
if self._hasLikelyCustomEchoVoice(echoVoice, defaultVoice):
|
||||
generalSettings['useCustomEchoVoice'] = True
|
||||
if 'useCustomEchoForKey' not in profileSettings:
|
||||
generalSettings['useCustomEchoForKey'] = True
|
||||
if 'useCustomEchoForCharacter' not in profileSettings:
|
||||
generalSettings['useCustomEchoForCharacter'] = True
|
||||
|
||||
try:
|
||||
generalSettings['activeProfile'] = profileSettings['profile']
|
||||
except KeyError:
|
||||
|
||||
@@ -136,6 +136,24 @@
|
||||
<property name="step_increment">0.10000000149</property>
|
||||
<property name="page_increment">1</property>
|
||||
</object>
|
||||
<object class="GtkAdjustment" id="echoPitchAdjustment">
|
||||
<property name="upper">10</property>
|
||||
<property name="value">5</property>
|
||||
<property name="step_increment">0.10000000149</property>
|
||||
<property name="page_increment">1</property>
|
||||
</object>
|
||||
<object class="GtkAdjustment" id="echoRateAdjustment">
|
||||
<property name="upper">100</property>
|
||||
<property name="value">50</property>
|
||||
<property name="step_increment">1</property>
|
||||
<property name="page_increment">10</property>
|
||||
</object>
|
||||
<object class="GtkAdjustment" id="echoVolumeAdjustment">
|
||||
<property name="upper">10</property>
|
||||
<property name="value">10</property>
|
||||
<property name="step_increment">0.10000000149</property>
|
||||
<property name="page_increment">1</property>
|
||||
</object>
|
||||
<object class="GtkDialog" id="cthulhuSetupWindow">
|
||||
<property name="can_focus">False</property>
|
||||
<property name="title" translatable="yes">Cthulhu Preferences</property>
|
||||
@@ -3037,6 +3055,295 @@
|
||||
<property name="top_attach">1</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkFrame" id="echoVoiceFrame">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label_xalign">0</property>
|
||||
<property name="shadow_type">none</property>
|
||||
<child>
|
||||
<object class="GtkAlignment" id="echoVoiceAlignment">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="left_padding">12</property>
|
||||
<child>
|
||||
<object class="GtkGrid" id="echoVoiceGrid">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="row_spacing">10</property>
|
||||
<property name="column_spacing">8</property>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="useCustomEchoVoiceCheckButton">
|
||||
<property name="label" translatable="yes">Use c_ustom echo voice settings</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="useCustomEchoVoiceToggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">0</property>
|
||||
<property name="width">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="useCustomEchoSpeechServerCheckButton">
|
||||
<property name="label" translatable="yes">Use custom _speech-dispatcher module for echo</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="useCustomEchoSpeechServerToggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">1</property>
|
||||
<property name="width">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="echoSpeechServersLabel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="xalign">1</property>
|
||||
<property name="label" translatable="yes">Echo _module:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">echoSpeechServers</property>
|
||||
<accessibility>
|
||||
<relation type="label-for" target="echoSpeechServers"/>
|
||||
</accessibility>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkComboBox" id="echoSpeechServers">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<signal name="changed" handler="echoSpeechServersChanged" swapped="no"/>
|
||||
<accessibility>
|
||||
<relation type="labelled-by" target="echoSpeechServersLabel"/>
|
||||
</accessibility>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="echoSpeechFamiliesLabel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="xalign">1</property>
|
||||
<property name="label" translatable="yes">Echo _voice:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">echoSpeechFamilies</property>
|
||||
<accessibility>
|
||||
<relation type="label-for" target="echoSpeechFamilies"/>
|
||||
</accessibility>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkComboBox" id="echoSpeechFamilies">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<signal name="changed" handler="echoSpeechFamiliesChanged" swapped="no"/>
|
||||
<accessibility>
|
||||
<relation type="labelled-by" target="echoSpeechFamiliesLabel"/>
|
||||
</accessibility>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="echoRateLabel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="xalign">1</property>
|
||||
<property name="label" translatable="yes">Echo ra_te:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">echoRateScale</property>
|
||||
<accessibility>
|
||||
<relation type="label-for" target="echoRateScale"/>
|
||||
</accessibility>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">4</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkScale" id="echoRateScale">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="adjustment">echoRateAdjustment</property>
|
||||
<property name="round_digits">0</property>
|
||||
<property name="digits">0</property>
|
||||
<property name="value_pos">right</property>
|
||||
<signal name="value-changed" handler="echoRateValueChanged" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">4</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="echoPitchLabel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="xalign">1</property>
|
||||
<property name="label" translatable="yes">Echo pi_tch:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">echoPitchScale</property>
|
||||
<accessibility>
|
||||
<relation type="label-for" target="echoPitchScale"/>
|
||||
</accessibility>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">5</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkScale" id="echoPitchScale">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="adjustment">echoPitchAdjustment</property>
|
||||
<property name="round_digits">1</property>
|
||||
<property name="value_pos">right</property>
|
||||
<signal name="value-changed" handler="echoPitchValueChanged" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">5</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkLabel" id="echoVolumeLabel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="xalign">1</property>
|
||||
<property name="label" translatable="yes">Echo vo_lume:</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="mnemonic_widget">echoVolumeScale</property>
|
||||
<accessibility>
|
||||
<relation type="label-for" target="echoVolumeScale"/>
|
||||
</accessibility>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">6</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkScale" id="echoVolumeScale">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="adjustment">echoVolumeAdjustment</property>
|
||||
<property name="round_digits">1</property>
|
||||
<property name="value_pos">right</property>
|
||||
<signal name="value-changed" handler="echoVolumeValueChanged" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">1</property>
|
||||
<property name="top_attach">6</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="useCustomEchoForKeyCheckButton">
|
||||
<property name="label" translatable="yes">Use custom voice for _key echo</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="checkButtonToggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">7</property>
|
||||
<property name="width">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="useCustomEchoForCharacterCheckButton">
|
||||
<property name="label" translatable="yes">Use custom voice for _character echo</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="checkButtonToggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">8</property>
|
||||
<property name="width">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="useCustomEchoForWordCheckButton">
|
||||
<property name="label" translatable="yes">Use custom voice for _word echo</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="checkButtonToggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">9</property>
|
||||
<property name="width">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="useCustomEchoForSentenceCheckButton">
|
||||
<property name="label" translatable="yes">Use custom voice for _sentence echo</property>
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">True</property>
|
||||
<property name="receives_default">False</property>
|
||||
<property name="use_underline">True</property>
|
||||
<property name="draw_indicator">True</property>
|
||||
<signal name="toggled" handler="checkButtonToggled" swapped="no"/>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">10</property>
|
||||
<property name="width">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
</child>
|
||||
<child type="label">
|
||||
<object class="GtkLabel" id="echoVoiceLabel">
|
||||
<property name="visible">True</property>
|
||||
<property name="can_focus">False</property>
|
||||
<property name="label" translatable="yes">Echo Voice</property>
|
||||
<attributes>
|
||||
<attribute name="weight" value="bold"/>
|
||||
</attributes>
|
||||
</object>
|
||||
</child>
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">2</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
<object class="GtkCheckButton" id="enableEchoByCharacterCheckButton">
|
||||
<property name="label" translatable="yes" comments="Translators: When this option is enabled, inserted text of length 1 is spoken.">Enable echo by cha_racter</property>
|
||||
@@ -3049,7 +3356,7 @@
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">2</property>
|
||||
<property name="top_attach">3</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
@@ -3064,7 +3371,7 @@
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">3</property>
|
||||
<property name="top_attach">4</property>
|
||||
</packing>
|
||||
</child>
|
||||
<child>
|
||||
@@ -3079,7 +3386,7 @@
|
||||
</object>
|
||||
<packing>
|
||||
<property name="left_attach">0</property>
|
||||
<property name="top_attach">4</property>
|
||||
<property name="top_attach">5</property>
|
||||
</packing>
|
||||
</child>
|
||||
</object>
|
||||
|
||||
@@ -23,5 +23,5 @@
|
||||
# Forked from Orca screen reader.
|
||||
# Cthulhu project: https://git.stormux.org/storm/cthulhu
|
||||
|
||||
version = "2026.02.17"
|
||||
version = "2026.03.02"
|
||||
codeName = "master"
|
||||
|
||||
@@ -38,6 +38,9 @@ gi.require_version("Gtk", "3.0")
|
||||
from gi.repository import Atspi
|
||||
|
||||
import os
|
||||
import json
|
||||
import subprocess
|
||||
import sys
|
||||
import threading
|
||||
from gi.repository import Gdk
|
||||
from gi.repository import GLib
|
||||
@@ -173,6 +176,16 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
self.speechSystemsChoice = None
|
||||
self.speechSystemsChoices = None
|
||||
self.speechSystemsModel = None
|
||||
self.echoVoice = None
|
||||
self.echoSpeechFamiliesChoice = None
|
||||
self.echoSpeechFamiliesChoices = None
|
||||
self.echoSpeechFamiliesModel = None
|
||||
self.echoSpeechServersChoice = None
|
||||
self.echoSpeechServersChoices = None
|
||||
self.echoSpeechServersModel = None
|
||||
self.initializingEchoSpeech = False
|
||||
self._echoVoiceFetchToken = 0
|
||||
self._updatingEchoSpeechFamilies = False
|
||||
self.systemVoice = None
|
||||
self.uppercaseVoice = None
|
||||
self.window = None
|
||||
@@ -183,6 +196,7 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
self.soundThemeCombo = None
|
||||
self.roleSoundPresentationCombo = None
|
||||
self._isInitialSetup = False
|
||||
self._updatingSpeechFamilies = False
|
||||
self.selectedFamilyChoices = {}
|
||||
self.selectedLanguageChoices = {}
|
||||
self.profilesCombo = None
|
||||
@@ -385,7 +399,12 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
self._initComboBox(self.get_widget("speechLanguages"))
|
||||
self.speechFamiliesModel = \
|
||||
self._initComboBox(self.get_widget("speechFamilies"))
|
||||
self.echoSpeechServersModel = \
|
||||
self._initComboBox(self.get_widget("echoSpeechServers"))
|
||||
self.echoSpeechFamiliesModel = \
|
||||
self._initComboBox(self.get_widget("echoSpeechFamilies"))
|
||||
self._initSpeechState()
|
||||
self._initEchoSpeechState()
|
||||
|
||||
# TODO - JD: Will this ever be the case??
|
||||
self._isInitialSetup = \
|
||||
@@ -1271,7 +1290,7 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
for familyChoice in self.speechFamiliesChoices:
|
||||
name = familyChoice[speechserver.VoiceFamily.NAME]
|
||||
if name == familyName:
|
||||
self.get_widget("speechFamilies").set_active(i)
|
||||
self._setSpeechFamiliesActive(i)
|
||||
self.speechFamiliesChoice = self.speechFamiliesChoices[i]
|
||||
familySet = True
|
||||
break
|
||||
@@ -1295,13 +1314,22 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
if not familySet:
|
||||
tokens = ["PREFERENCES DIALOG: Could not find speech family match for", familyName]
|
||||
debug.printTokens(debug.LEVEL_INFO, tokens, True)
|
||||
self.get_widget("speechFamilies").set_active(0)
|
||||
self._setSpeechFamiliesActive(0)
|
||||
self.speechFamiliesChoice = self.speechFamiliesChoices[0]
|
||||
|
||||
if familySet:
|
||||
self.selectedFamilyChoices[self.speechServersChoice,
|
||||
self.speechLanguagesChoice] = i
|
||||
|
||||
def _setSpeechFamiliesActive(self, index):
|
||||
"""Sets speechFamilies active index while suppressing preview chatter."""
|
||||
|
||||
self._updatingSpeechFamilies = True
|
||||
try:
|
||||
self.get_widget("speechFamilies").set_active(index)
|
||||
finally:
|
||||
self._updatingSpeechFamilies = False
|
||||
|
||||
def _setupFamilies(self):
|
||||
"""Gets the list of voice variants for the current speech server and
|
||||
current language.
|
||||
@@ -1353,7 +1381,7 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
selectedIndex = self.selectedFamilyChoices[self.speechServersChoice,
|
||||
self.speechLanguagesChoice]
|
||||
|
||||
self.get_widget("speechFamilies").set_active(selectedIndex)
|
||||
self._setSpeechFamiliesActive(selectedIndex)
|
||||
|
||||
def _setSpeechLanguagesChoice(self, languageName):
|
||||
"""Sets the active item in the languages ("Language:") combo box
|
||||
@@ -1661,6 +1689,261 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
self._setupSpeechSystems(factories)
|
||||
self.initializingSpeech = False
|
||||
|
||||
def _getSpeechDispatcherFactory(self):
|
||||
"""Returns the Speech Dispatcher factory if available."""
|
||||
|
||||
factories = cthulhu.cthulhuApp.settingsManager.getSpeechServerFactories()
|
||||
for factory in factories:
|
||||
try:
|
||||
if factory.SpeechServer.getFactoryName() == guilabels.SPEECH_DISPATCHER:
|
||||
return factory
|
||||
except Exception:
|
||||
debug.printException(debug.LEVEL_FINEST)
|
||||
|
||||
return None
|
||||
|
||||
def _setEchoVoiceFamily(self, family):
|
||||
"""Sets echo voice family from the selected server family object."""
|
||||
|
||||
if not family:
|
||||
return
|
||||
|
||||
name = family.get(speechserver.VoiceFamily.NAME)
|
||||
language = family.get(speechserver.VoiceFamily.LANG)
|
||||
dialect = family.get(speechserver.VoiceFamily.DIALECT)
|
||||
variant = family.get(speechserver.VoiceFamily.VARIANT)
|
||||
self.echoVoice[acss.ACSS.FAMILY] = {
|
||||
speechserver.VoiceFamily.NAME: name,
|
||||
speechserver.VoiceFamily.LANG: language,
|
||||
speechserver.VoiceFamily.DIALECT: dialect,
|
||||
speechserver.VoiceFamily.VARIANT: variant,
|
||||
}
|
||||
self.echoVoice['established'] = True
|
||||
|
||||
def _populateEchoSpeechFamilies(self, families):
|
||||
"""Populate the echo family combobox from the provided families list."""
|
||||
|
||||
combobox = self.get_widget("echoSpeechFamilies")
|
||||
combobox.set_model(None)
|
||||
self.echoSpeechFamiliesModel.clear()
|
||||
self.echoSpeechFamiliesChoices = list(families or [])
|
||||
self.echoSpeechFamiliesChoice = None
|
||||
|
||||
selectedIndex = 0
|
||||
selectedMatchFound = False
|
||||
selectedFamily = self.echoVoice.get(acss.ACSS.FAMILY)
|
||||
selectedName = selectedLanguage = selectedDialect = selectedVariant = None
|
||||
if selectedFamily:
|
||||
selectedName = selectedFamily.get(speechserver.VoiceFamily.NAME)
|
||||
selectedLanguage = selectedFamily.get(speechserver.VoiceFamily.LANG)
|
||||
selectedDialect = selectedFamily.get(speechserver.VoiceFamily.DIALECT)
|
||||
selectedVariant = selectedFamily.get(speechserver.VoiceFamily.VARIANT)
|
||||
|
||||
for i, family in enumerate(self.echoSpeechFamiliesChoices):
|
||||
name = family.get(speechserver.VoiceFamily.NAME) or ""
|
||||
language = family.get(speechserver.VoiceFamily.LANG) or ""
|
||||
dialect = family.get(speechserver.VoiceFamily.DIALECT) or ""
|
||||
variant = family.get(speechserver.VoiceFamily.VARIANT)
|
||||
display = name
|
||||
locale = language
|
||||
if dialect:
|
||||
locale = f"{language}-{dialect}" if language else dialect
|
||||
if locale:
|
||||
display = f"{name} ({locale})"
|
||||
self.echoSpeechFamiliesModel.append((i, display))
|
||||
if selectedName == name and selectedLanguage == language \
|
||||
and selectedDialect == dialect and selectedVariant == variant:
|
||||
selectedIndex = i
|
||||
selectedMatchFound = True
|
||||
|
||||
combobox.set_model(self.echoSpeechFamiliesModel)
|
||||
if self.echoSpeechFamiliesChoices:
|
||||
self._updatingEchoSpeechFamilies = True
|
||||
try:
|
||||
combobox.set_active(selectedIndex)
|
||||
finally:
|
||||
self._updatingEchoSpeechFamilies = False
|
||||
self.echoSpeechFamiliesChoice = self.echoSpeechFamiliesChoices[selectedIndex]
|
||||
|
||||
def _fetchEchoSpeechFamiliesWorker(self, serverInfo, requestToken):
|
||||
"""Fetch module-specific voices in a subprocess and apply asynchronously."""
|
||||
|
||||
queryScript = """
|
||||
import json
|
||||
import sys
|
||||
from cthulhu import speechdispatcherfactory
|
||||
from cthulhu import speechserver
|
||||
|
||||
serverInfo = json.loads(sys.argv[1])
|
||||
if isinstance(serverInfo, list):
|
||||
serverInfo = tuple(serverInfo)
|
||||
|
||||
server = speechdispatcherfactory.SpeechServer.getSpeechServer(serverInfo)
|
||||
families = server.getVoiceFamilies() if server else []
|
||||
|
||||
result = []
|
||||
for family in families:
|
||||
result.append({
|
||||
"name": family.get(speechserver.VoiceFamily.NAME),
|
||||
"lang": family.get(speechserver.VoiceFamily.LANG),
|
||||
"dialect": family.get(speechserver.VoiceFamily.DIALECT),
|
||||
"variant": family.get(speechserver.VoiceFamily.VARIANT),
|
||||
})
|
||||
|
||||
print(json.dumps(result))
|
||||
"""
|
||||
|
||||
familyDefs = None
|
||||
try:
|
||||
completed = subprocess.run(
|
||||
[sys.executable, "-c", queryScript, json.dumps(serverInfo)],
|
||||
capture_output=True,
|
||||
text=True,
|
||||
timeout=4.0,
|
||||
check=False,
|
||||
)
|
||||
if completed.returncode == 0 and completed.stdout.strip():
|
||||
familyDefs = json.loads(completed.stdout.strip())
|
||||
else:
|
||||
tokens = [
|
||||
"PREFERENCES DIALOG: Echo voice fetch failed for",
|
||||
serverInfo,
|
||||
"rc=",
|
||||
completed.returncode,
|
||||
]
|
||||
debug.printTokens(debug.LEVEL_WARNING, tokens, True)
|
||||
except subprocess.TimeoutExpired:
|
||||
tokens = ["PREFERENCES DIALOG: Echo voice fetch timed out for", serverInfo]
|
||||
debug.printTokens(debug.LEVEL_WARNING, tokens, True)
|
||||
except Exception:
|
||||
debug.printException(debug.LEVEL_WARNING)
|
||||
|
||||
GLib.idle_add(self._applyFetchedEchoSpeechFamilies, requestToken, familyDefs)
|
||||
|
||||
def _applyFetchedEchoSpeechFamilies(self, requestToken, familyDefs):
|
||||
"""Apply fetched echo families if this is still the active request."""
|
||||
|
||||
if requestToken != self._echoVoiceFetchToken:
|
||||
return False
|
||||
|
||||
if not isinstance(familyDefs, list):
|
||||
return False
|
||||
|
||||
families = []
|
||||
for familyDef in familyDefs:
|
||||
if not isinstance(familyDef, dict):
|
||||
continue
|
||||
families.append(
|
||||
speechserver.VoiceFamily({
|
||||
speechserver.VoiceFamily.NAME: familyDef.get("name"),
|
||||
speechserver.VoiceFamily.LANG: familyDef.get("lang"),
|
||||
speechserver.VoiceFamily.DIALECT: familyDef.get("dialect"),
|
||||
speechserver.VoiceFamily.VARIANT: familyDef.get("variant"),
|
||||
})
|
||||
)
|
||||
|
||||
if not families:
|
||||
return False
|
||||
|
||||
self._populateEchoSpeechFamilies(families)
|
||||
return False
|
||||
|
||||
def _setupEchoSpeechFamilies(self):
|
||||
"""Populate echo voice family list for the current echo server."""
|
||||
self._echoVoiceFetchToken += 1
|
||||
requestToken = self._echoVoiceFetchToken
|
||||
useCustomModule = self.get_widget("useCustomEchoSpeechServerCheckButton").get_active()
|
||||
fallbackFamilies = list(self.speechFamiliesChoices or [])
|
||||
self._populateEchoSpeechFamilies(fallbackFamilies)
|
||||
|
||||
if useCustomModule and self.echoSpeechServersChoice:
|
||||
serverInfo = self.echoSpeechServersChoice.getInfo()
|
||||
thread = threading.Thread(
|
||||
target=self._fetchEchoSpeechFamiliesWorker,
|
||||
args=(serverInfo, requestToken),
|
||||
daemon=True,
|
||||
)
|
||||
thread.start()
|
||||
|
||||
def _setEchoSpeechServersChoice(self, serverInfo):
|
||||
"""Set the active echo module based on stored server info."""
|
||||
|
||||
if not self.echoSpeechServersChoices:
|
||||
self.echoSpeechServersChoice = None
|
||||
self._setupEchoSpeechFamilies()
|
||||
return
|
||||
|
||||
valueSet = False
|
||||
for i, server in enumerate(self.echoSpeechServersChoices):
|
||||
info = server.getInfo()
|
||||
if serverInfo and info == serverInfo:
|
||||
self.get_widget("echoSpeechServers").set_active(i)
|
||||
self.echoSpeechServersChoice = server
|
||||
valueSet = True
|
||||
break
|
||||
|
||||
if not valueSet:
|
||||
self.get_widget("echoSpeechServers").set_active(0)
|
||||
self.echoSpeechServersChoice = self.echoSpeechServersChoices[0]
|
||||
|
||||
self._setupEchoSpeechFamilies()
|
||||
|
||||
def _setupEchoSpeechServers(self):
|
||||
"""Populate available speech-dispatcher modules for echo."""
|
||||
|
||||
combobox = self.get_widget("echoSpeechServers")
|
||||
combobox.set_model(None)
|
||||
self.echoSpeechServersModel.clear()
|
||||
self.echoSpeechServersChoices = []
|
||||
self.echoSpeechServersChoice = None
|
||||
|
||||
if not self.prefsDict.get('enableSpeech', True):
|
||||
combobox.set_model(self.echoSpeechServersModel)
|
||||
self._setupEchoSpeechFamilies()
|
||||
return
|
||||
|
||||
factory = self._getSpeechDispatcherFactory()
|
||||
if factory is None:
|
||||
combobox.set_model(self.echoSpeechServersModel)
|
||||
self._setupEchoSpeechFamilies()
|
||||
return
|
||||
|
||||
try:
|
||||
self.echoSpeechServersChoices = factory.SpeechServer.getSpeechServers()
|
||||
except Exception:
|
||||
debug.printException(debug.LEVEL_WARNING)
|
||||
self.echoSpeechServersChoices = []
|
||||
|
||||
for i, server in enumerate(self.echoSpeechServersChoices):
|
||||
name = server.getInfo()[0]
|
||||
self.echoSpeechServersModel.append((i, name))
|
||||
|
||||
combobox.set_model(self.echoSpeechServersModel)
|
||||
self._setEchoSpeechServersChoice(self.prefsDict.get("echoSpeechServerInfo"))
|
||||
|
||||
def _initEchoSpeechState(self):
|
||||
"""Initialize echo voice controls and choices."""
|
||||
|
||||
self.echoVoice = acss.ACSS(
|
||||
self.prefsDict.get("echoVoice", settings.echoVoice) or {})
|
||||
|
||||
baseVoice = self.defaultVoice or acss.ACSS(
|
||||
self.prefsDict.get("voices", {}).get(settings.DEFAULT_VOICE, {}))
|
||||
|
||||
rate = self.echoVoice.get(acss.ACSS.RATE, baseVoice.get(acss.ACSS.RATE, 50.0))
|
||||
pitch = self.echoVoice.get(acss.ACSS.AVERAGE_PITCH, baseVoice.get(acss.ACSS.AVERAGE_PITCH, 5.0))
|
||||
volume = self.echoVoice.get(acss.ACSS.GAIN, baseVoice.get(acss.ACSS.GAIN, 10.0))
|
||||
|
||||
self.get_widget("echoRateScale").set_value(rate)
|
||||
self.get_widget("echoPitchScale").set_value(pitch)
|
||||
self.get_widget("echoVolumeScale").set_value(volume)
|
||||
|
||||
self.initializingEchoSpeech = True
|
||||
self._setupEchoSpeechServers()
|
||||
self.initializingEchoSpeech = False
|
||||
|
||||
self._setEchoVoiceItems()
|
||||
|
||||
def _setSpokenTextAttributes(self, view, setAttributes,
|
||||
state, moveToTop=False):
|
||||
"""Given a set of spoken text attributes, update the model used by the
|
||||
@@ -2394,6 +2677,19 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
prefs["enableEchoByWord"])
|
||||
self.get_widget("enableEchoBySentenceCheckButton").set_active( \
|
||||
prefs["enableEchoBySentence"])
|
||||
self.get_widget("useCustomEchoVoiceCheckButton").set_active(
|
||||
prefs.get("useCustomEchoVoice", settings.useCustomEchoVoice))
|
||||
self.get_widget("useCustomEchoSpeechServerCheckButton").set_active(
|
||||
prefs.get("useCustomEchoSpeechServer", settings.useCustomEchoSpeechServer))
|
||||
self.get_widget("useCustomEchoForKeyCheckButton").set_active(
|
||||
prefs.get("useCustomEchoForKey", settings.useCustomEchoForKey))
|
||||
self.get_widget("useCustomEchoForCharacterCheckButton").set_active(
|
||||
prefs.get("useCustomEchoForCharacter", settings.useCustomEchoForCharacter))
|
||||
self.get_widget("useCustomEchoForWordCheckButton").set_active(
|
||||
prefs.get("useCustomEchoForWord", settings.useCustomEchoForWord))
|
||||
self.get_widget("useCustomEchoForSentenceCheckButton").set_active(
|
||||
prefs.get("useCustomEchoForSentence", settings.useCustomEchoForSentence))
|
||||
self._setEchoVoiceItems()
|
||||
|
||||
# Text attributes pane.
|
||||
#
|
||||
@@ -2553,22 +2849,20 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
self._updateAIControlsState(enabled)
|
||||
|
||||
def _updateAIControlsState(self, enabled):
|
||||
"""Enable or disable AI controls based on AI enabled state."""
|
||||
self.aiProviderCombo.set_sensitive(enabled)
|
||||
self.aiApiKeyEntry.set_sensitive(enabled)
|
||||
self.aiOllamaModelEntry.set_sensitive(enabled)
|
||||
self.aiOllamaEndpointEntry.set_sensitive(enabled)
|
||||
self.aiConfirmationCheckButton.set_sensitive(enabled)
|
||||
self.aiScreenshotQualityCombo.set_sensitive(enabled)
|
||||
"""Refresh AI controls while keeping configuration fields editable."""
|
||||
_ = enabled # kept for signal/call compatibility
|
||||
# Keep settings editable even when AI assistant is disabled so users
|
||||
# can configure providers/keys before enabling it.
|
||||
self.aiProviderCombo.set_sensitive(True)
|
||||
self.aiConfirmationCheckButton.set_sensitive(True)
|
||||
self.aiScreenshotQualityCombo.set_sensitive(True)
|
||||
try:
|
||||
self.get_widget("aiGetClaudeKeyButton").set_sensitive(enabled)
|
||||
self.get_widget("aiGetClaudeKeyButton").set_sensitive(True)
|
||||
except:
|
||||
pass # Button might not exist in older UI files
|
||||
|
||||
# Update provider-specific controls if AI is enabled
|
||||
if enabled:
|
||||
current_provider = self.prefsDict.get("aiProvider", settings.aiProvider)
|
||||
self._updateProviderControls(current_provider)
|
||||
|
||||
current_provider = self.prefsDict.get("aiProvider", settings.aiProvider)
|
||||
self._updateProviderControls(current_provider)
|
||||
|
||||
def _initIndentationState(self):
|
||||
"""Initialize Indentation widgets with current settings."""
|
||||
@@ -2898,22 +3192,91 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
self.get_widget("enableNavigationKeysCheckButton").set_sensitive(enable)
|
||||
self.get_widget("enableDiacriticalKeysCheckButton").set_sensitive( \
|
||||
enable)
|
||||
self._setEchoVoiceItems()
|
||||
|
||||
def _presentMessage(self, text, interrupt=False):
|
||||
def _setEchoVoiceItems(self):
|
||||
"""[In]sensitize echo voice controls based on current state."""
|
||||
|
||||
useCustomVoice = self.get_widget("useCustomEchoVoiceCheckButton").get_active()
|
||||
useCustomModule = self.get_widget("useCustomEchoSpeechServerCheckButton").get_active()
|
||||
keyEchoEnabled = self.get_widget("keyEchoCheckButton").get_active()
|
||||
charEchoEnabled = self.get_widget("enableEchoByCharacterCheckButton").get_active()
|
||||
wordEchoEnabled = self.get_widget("enableEchoByWordCheckButton").get_active()
|
||||
sentenceEchoEnabled = self.get_widget("enableEchoBySentenceCheckButton").get_active()
|
||||
speechEnabled = self.get_widget("speechSupportCheckButton").get_active()
|
||||
|
||||
speechSystemIsDispatcher = False
|
||||
if self.speechSystemsChoice:
|
||||
try:
|
||||
speechSystemIsDispatcher = \
|
||||
self.speechSystemsChoice.SpeechServer.getFactoryName() == guilabels.SPEECH_DISPATCHER
|
||||
except Exception:
|
||||
speechSystemIsDispatcher = False
|
||||
|
||||
voiceControlsEnabled = useCustomVoice and speechEnabled
|
||||
moduleOverrideAvailable = voiceControlsEnabled and speechSystemIsDispatcher
|
||||
moduleControlsEnabled = moduleOverrideAvailable and useCustomModule
|
||||
|
||||
self.get_widget("useCustomEchoSpeechServerCheckButton").set_sensitive(moduleOverrideAvailable)
|
||||
self.get_widget("echoSpeechServers").set_sensitive(moduleControlsEnabled)
|
||||
self.get_widget("echoSpeechFamilies").set_sensitive(voiceControlsEnabled)
|
||||
|
||||
self.get_widget("echoRateScale").set_sensitive(useCustomVoice)
|
||||
self.get_widget("echoPitchScale").set_sensitive(useCustomVoice)
|
||||
self.get_widget("echoVolumeScale").set_sensitive(useCustomVoice)
|
||||
|
||||
self.get_widget("useCustomEchoForKeyCheckButton").set_sensitive(useCustomVoice and keyEchoEnabled)
|
||||
self.get_widget("useCustomEchoForCharacterCheckButton").set_sensitive(
|
||||
useCustomVoice and charEchoEnabled)
|
||||
self.get_widget("useCustomEchoForWordCheckButton").set_sensitive(useCustomVoice and wordEchoEnabled)
|
||||
self.get_widget("useCustomEchoForSentenceCheckButton").set_sensitive(
|
||||
useCustomVoice and sentenceEchoEnabled)
|
||||
|
||||
def _presentMessage(self, text, interrupt=False, voice=None):
|
||||
"""If the text field is not None, presents the given text, optionally
|
||||
interrupting anything currently being spoken.
|
||||
|
||||
Arguments:
|
||||
- text: the text to present
|
||||
- interrupt: if True, interrupt any speech currently being spoken
|
||||
- voice: the voice to use; if None, use the default system voice
|
||||
"""
|
||||
|
||||
self.script.speakMessage(text, interrupt=interrupt)
|
||||
self.script.speakMessage(text, voice=voice, interrupt=interrupt)
|
||||
try:
|
||||
self.script.displayBrailleMessage(text, flashTime=-1)
|
||||
except Exception:
|
||||
pass
|
||||
|
||||
def _previewVoiceSelection(self, voiceType, name):
|
||||
"""Present a short preview in the currently selected voice."""
|
||||
|
||||
if not name:
|
||||
return
|
||||
|
||||
voice = self._getACSSForVoiceType(voiceType)
|
||||
if not voice:
|
||||
return
|
||||
|
||||
previewVoice = acss.ACSS(voice)
|
||||
if self.speechSystemsChoice \
|
||||
and self.speechSystemsChoice.SpeechServer.getFactoryName() == guilabels.SPEECH_DISPATCHER:
|
||||
previewMessage = messages.SPEECH_VOICE_VALUE % name
|
||||
else:
|
||||
previewMessage = messages.SPEECH_VOICE_VALUE_GENERIC % name
|
||||
|
||||
# Speak through the currently-selected preferences speech server so
|
||||
# preview uses the chosen module/voice, not the globally-active one.
|
||||
server = self.speechServersChoice
|
||||
if server and hasattr(server, "speak"):
|
||||
try:
|
||||
server.speak(previewMessage, previewVoice, interrupt=True)
|
||||
return
|
||||
except Exception:
|
||||
debug.printException(debug.LEVEL_WARNING)
|
||||
|
||||
self._presentMessage(previewMessage, interrupt=True, voice=previewVoice)
|
||||
|
||||
def _createNode(self, appName):
|
||||
"""Create a new root node in the TreeStore model with the name of the
|
||||
application.
|
||||
@@ -3194,6 +3557,8 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
enable = widget.get_active()
|
||||
self.prefsDict["enableSpeech"] = enable
|
||||
self.get_widget("speechOptionsGrid").set_sensitive(enable)
|
||||
self._setupEchoSpeechServers()
|
||||
self._setEchoVoiceItems()
|
||||
|
||||
def onlySpeakDisplayedTextToggled(self, widget):
|
||||
"""Signal handler for the "toggled" signal for the GtkCheckButton
|
||||
@@ -3225,6 +3590,8 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
selectedIndex = widget.get_active()
|
||||
self.speechSystemsChoice = self.speechSystemsChoices[selectedIndex]
|
||||
self._setupSpeechServers()
|
||||
self._setupEchoSpeechServers()
|
||||
self._setEchoVoiceItems()
|
||||
|
||||
def speechServersChanged(self, widget):
|
||||
"""Signal handler for the "changed" signal for the speechServers
|
||||
@@ -3257,6 +3624,7 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
pass
|
||||
|
||||
self._setupVoices()
|
||||
self._setEchoVoiceItems()
|
||||
|
||||
def speechLanguagesChanged(self, widget):
|
||||
"""Signal handler for the "value_changed" signal for the languages
|
||||
@@ -3316,6 +3684,8 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
variant = family[speechserver.VoiceFamily.VARIANT]
|
||||
voiceType = self.get_widget("voiceTypesCombo").get_active()
|
||||
self._setFamilyNameForVoiceType(voiceType, name, language, dialect, variant)
|
||||
if not self._updatingSpeechFamilies:
|
||||
self._previewVoiceSelection(voiceType, name)
|
||||
except Exception:
|
||||
debug.printException(debug.LEVEL_SEVERE)
|
||||
|
||||
@@ -3393,6 +3763,75 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
voices.get(settings.DEFAULT_VOICE, {})[acss.ACSS.GAIN] = volume
|
||||
cthulhu.cthulhuApp.settingsManager.setSetting('voices', voices)
|
||||
|
||||
def useCustomEchoVoiceToggled(self, widget):
|
||||
"""Signal handler for enabling/disabling custom echo voice settings."""
|
||||
|
||||
self.prefsDict["useCustomEchoVoice"] = widget.get_active()
|
||||
self._setEchoVoiceItems()
|
||||
self._setupEchoSpeechFamilies()
|
||||
|
||||
def useCustomEchoSpeechServerToggled(self, widget):
|
||||
"""Signal handler for enabling/disabling custom echo module override."""
|
||||
|
||||
self.prefsDict["useCustomEchoSpeechServer"] = widget.get_active()
|
||||
self._setEchoVoiceItems()
|
||||
self._setupEchoSpeechFamilies()
|
||||
|
||||
def echoSpeechServersChanged(self, widget):
|
||||
"""Signal handler for selecting the echo speech-dispatcher module."""
|
||||
|
||||
if self.initializingEchoSpeech:
|
||||
return
|
||||
|
||||
selectedIndex = widget.get_active()
|
||||
if selectedIndex < 0:
|
||||
self.echoSpeechServersChoice = None
|
||||
self.prefsDict["echoSpeechServerInfo"] = None
|
||||
self._setupEchoSpeechFamilies()
|
||||
return
|
||||
|
||||
self.echoSpeechServersChoice = self.echoSpeechServersChoices[selectedIndex]
|
||||
self.prefsDict["echoSpeechServerInfo"] = self.echoSpeechServersChoice.getInfo()
|
||||
self._setupEchoSpeechFamilies()
|
||||
|
||||
def echoSpeechFamiliesChanged(self, widget):
|
||||
"""Signal handler for selecting the echo voice family."""
|
||||
|
||||
if self.initializingEchoSpeech or self._updatingEchoSpeechFamilies:
|
||||
return
|
||||
|
||||
selectedIndex = widget.get_active()
|
||||
if selectedIndex < 0:
|
||||
self.echoSpeechFamiliesChoice = None
|
||||
return
|
||||
|
||||
self.echoSpeechFamiliesChoice = self.echoSpeechFamiliesChoices[selectedIndex]
|
||||
self._setEchoVoiceFamily(self.echoSpeechFamiliesChoice)
|
||||
|
||||
def echoRateValueChanged(self, widget):
|
||||
"""Signal handler for changing custom echo rate."""
|
||||
|
||||
if self.echoVoice is None:
|
||||
self.echoVoice = acss.ACSS({})
|
||||
self.echoVoice[acss.ACSS.RATE] = widget.get_value()
|
||||
self.echoVoice['established'] = True
|
||||
|
||||
def echoPitchValueChanged(self, widget):
|
||||
"""Signal handler for changing custom echo pitch."""
|
||||
|
||||
if self.echoVoice is None:
|
||||
self.echoVoice = acss.ACSS({})
|
||||
self.echoVoice[acss.ACSS.AVERAGE_PITCH] = widget.get_value()
|
||||
self.echoVoice['established'] = True
|
||||
|
||||
def echoVolumeValueChanged(self, widget):
|
||||
"""Signal handler for changing custom echo volume."""
|
||||
|
||||
if self.echoVoice is None:
|
||||
self.echoVoice = acss.ACSS({})
|
||||
self.echoVoice[acss.ACSS.GAIN] = widget.get_value()
|
||||
self.echoVoice['established'] = True
|
||||
|
||||
def checkButtonToggled(self, widget):
|
||||
"""Signal handler for "toggled" signal for basic GtkCheckButton
|
||||
widgets. The user has altered the state of the checkbox.
|
||||
@@ -3410,6 +3849,15 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
# strip "CheckButton" from the end.
|
||||
settingName = settingName[:-11]
|
||||
self.prefsDict[settingName] = widget.get_active()
|
||||
if settingName in [
|
||||
"enableEchoByCharacter",
|
||||
"enableEchoByWord",
|
||||
"enableEchoBySentence",
|
||||
"useCustomEchoForKey",
|
||||
"useCustomEchoForCharacter",
|
||||
"useCustomEchoForWord",
|
||||
"useCustomEchoForSentence"]:
|
||||
self._setEchoVoiceItems()
|
||||
|
||||
def keyEchoChecked(self, widget):
|
||||
"""Signal handler for the "toggled" signal for the
|
||||
@@ -4212,6 +4660,35 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
settings.SYSTEM_VOICE: acss.ACSS(self.systemVoice),
|
||||
}
|
||||
|
||||
self.prefsDict["useCustomEchoVoice"] = \
|
||||
self.get_widget("useCustomEchoVoiceCheckButton").get_active()
|
||||
self.prefsDict["useCustomEchoSpeechServer"] = \
|
||||
self.get_widget("useCustomEchoSpeechServerCheckButton").get_active()
|
||||
self.prefsDict["useCustomEchoForKey"] = \
|
||||
self.get_widget("useCustomEchoForKeyCheckButton").get_active()
|
||||
self.prefsDict["useCustomEchoForCharacter"] = \
|
||||
self.get_widget("useCustomEchoForCharacterCheckButton").get_active()
|
||||
self.prefsDict["useCustomEchoForWord"] = \
|
||||
self.get_widget("useCustomEchoForWordCheckButton").get_active()
|
||||
self.prefsDict["useCustomEchoForSentence"] = \
|
||||
self.get_widget("useCustomEchoForSentenceCheckButton").get_active()
|
||||
|
||||
if self.echoVoice is None:
|
||||
self.echoVoice = acss.ACSS({})
|
||||
|
||||
# Persist slider values directly so saving does not depend on
|
||||
# value-changed signal timing.
|
||||
self.echoVoice[acss.ACSS.RATE] = self.get_widget("echoRateScale").get_value()
|
||||
self.echoVoice[acss.ACSS.AVERAGE_PITCH] = self.get_widget("echoPitchScale").get_value()
|
||||
self.echoVoice[acss.ACSS.GAIN] = self.get_widget("echoVolumeScale").get_value()
|
||||
self.echoVoice['established'] = True
|
||||
self.prefsDict["echoVoice"] = acss.ACSS(self.echoVoice)
|
||||
|
||||
if self.echoSpeechServersChoice:
|
||||
self.prefsDict["echoSpeechServerInfo"] = self.echoSpeechServersChoice.getInfo()
|
||||
else:
|
||||
self.prefsDict["echoSpeechServerInfo"] = None
|
||||
|
||||
def applyButtonClicked(self, widget):
|
||||
"""Signal handler for the "clicked" signal for the applyButton
|
||||
GtkButton widget. The user has clicked the Apply button.
|
||||
@@ -4244,6 +4721,7 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
self._refresh_dynamic_plugin_tabs()
|
||||
braille.checkBrailleSetting()
|
||||
self._initSpeechState()
|
||||
self._initEchoSpeechState()
|
||||
self._populateKeyBindings()
|
||||
self.__initProfileCombo()
|
||||
|
||||
@@ -4506,6 +4984,7 @@ class CthulhuSetupGUI(cthulhu_gtkbuilder.GtkBuilderWrapper):
|
||||
braille.checkBrailleSetting()
|
||||
|
||||
self._initSpeechState()
|
||||
self._initEchoSpeechState()
|
||||
|
||||
self._populateKeyBindings()
|
||||
|
||||
|
||||
@@ -276,7 +276,9 @@ class LiveRegionManager:
|
||||
utts = message['labels'] + message['content']
|
||||
|
||||
if self.monitoring:
|
||||
self._script.presentMessage(utts)
|
||||
# Live region content is user-generated text, not system messages.
|
||||
# Use resetStyles=False to preserve the user's punctuation settings.
|
||||
self._script.presentMessage(utts, resetStyles=False)
|
||||
else:
|
||||
msg = "INFO: Not presenting message because monitoring is off"
|
||||
debug.printMessage(debug.LEVEL_INFO, msg, True)
|
||||
|
||||
@@ -325,7 +325,6 @@ class AIAssistant(Plugin):
|
||||
if not self._prefs_widgets:
|
||||
return
|
||||
|
||||
enabled = self._prefs_widgets["enable_check"].get_active()
|
||||
provider_values = self._prefs_widgets.get("provider_values", [])
|
||||
provider_index = self._prefs_widgets["provider_combo"].get_active()
|
||||
provider = provider_values[provider_index] if 0 <= provider_index < len(provider_values) else settings.aiProvider
|
||||
@@ -333,12 +332,14 @@ class AIAssistant(Plugin):
|
||||
is_gemini = provider == settings.AI_PROVIDER_GEMINI
|
||||
is_ollama = provider == settings.AI_PROVIDER_OLLAMA
|
||||
|
||||
self._prefs_widgets["provider_combo"].set_sensitive(enabled)
|
||||
self._prefs_widgets["api_key_entry"].set_sensitive(enabled and is_gemini)
|
||||
self._prefs_widgets["ollama_model_entry"].set_sensitive(enabled and is_ollama)
|
||||
self._prefs_widgets["ollama_endpoint_entry"].set_sensitive(enabled and is_ollama)
|
||||
self._prefs_widgets["confirmation_check"].set_sensitive(enabled)
|
||||
self._prefs_widgets["quality_combo"].set_sensitive(enabled)
|
||||
# Keep preferences editable even when the feature is disabled so users
|
||||
# can prepare configuration before turning AI assistant on.
|
||||
self._prefs_widgets["provider_combo"].set_sensitive(True)
|
||||
self._prefs_widgets["api_key_entry"].set_sensitive(is_gemini)
|
||||
self._prefs_widgets["ollama_model_entry"].set_sensitive(is_ollama)
|
||||
self._prefs_widgets["ollama_endpoint_entry"].set_sensitive(is_ollama)
|
||||
self._prefs_widgets["confirmation_check"].set_sensitive(True)
|
||||
self._prefs_widgets["quality_combo"].set_sensitive(True)
|
||||
|
||||
def refresh_settings(self):
|
||||
"""Refresh plugin settings and reinitialize provider. Called when settings change."""
|
||||
|
||||
@@ -21,10 +21,8 @@ from gi.repository import Gtk, Gdk, Pango
|
||||
from cthulhu.plugin import Plugin, cthulhu_hookimpl
|
||||
from cthulhu import cthulhu
|
||||
from cthulhu import debug
|
||||
from cthulhu import settings_manager
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
_settingsManager = None # Removed - use cthulhu.cthulhuApp.settingsManager
|
||||
|
||||
|
||||
class PluginManager(Plugin):
|
||||
@@ -473,25 +471,11 @@ class PluginManager(Plugin):
|
||||
current_general['activePlugins'] = active_plugins
|
||||
|
||||
cthulhu.cthulhuApp.settingsManager.profile = profile_name
|
||||
cthulhu.cthulhuApp.settingsManager._setProfileGeneral(current_general)
|
||||
|
||||
pronunciations = cthulhu.cthulhuApp.settingsManager.getPronunciations(profile_name) or {}
|
||||
keybindings = cthulhu.cthulhuApp.settingsManager.getKeybindings(profile_name) or {}
|
||||
|
||||
backend = cthulhu.cthulhuApp.settingsManager._backend
|
||||
if backend:
|
||||
backend.saveProfileSettings(
|
||||
profile_name,
|
||||
cthulhu.cthulhuApp.settingsManager.profileGeneral,
|
||||
pronunciations,
|
||||
keybindings
|
||||
)
|
||||
debug.printMessage(debug.LEVEL_INFO, f"PluginManager: Settings saved to backend (profile {profile_name})", True)
|
||||
else:
|
||||
debug.printMessage(debug.LEVEL_INFO, "PluginManager: No backend available for saving", True)
|
||||
cthulhu.cthulhuApp.settingsManager.saveProfileSettings(current_general)
|
||||
debug.printMessage(debug.LEVEL_INFO, f"PluginManager: Settings saved via settings manager (profile {profile_name})", True)
|
||||
|
||||
except Exception as save_error:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"PluginManager: Error saving via backend: {save_error}", True)
|
||||
debug.printMessage(debug.LEVEL_INFO, f"PluginManager: Error saving plugin state: {save_error}", True)
|
||||
|
||||
debug.printMessage(debug.LEVEL_INFO, f"PluginManager: Updated active plugins: {active_plugins}", True)
|
||||
|
||||
|
||||
@@ -1,9 +1,8 @@
|
||||
name = Speech History
|
||||
version = 1.0.0
|
||||
description = Shows a searchable history of the last 50 unique utterances spoken by Cthulhu
|
||||
version = 1.2.0
|
||||
description = Shows speech history and a live floating monitor of spoken text from Cthulhu
|
||||
authors = Stormux
|
||||
website = https://git.stormux.org/storm/cthulhu
|
||||
copyright = Copyright 2025 Stormux
|
||||
builtin = false
|
||||
hidden = false
|
||||
|
||||
|
||||
@@ -7,39 +7,47 @@
|
||||
# License as published by the Free Software Foundation; either
|
||||
# version 2.1 of the License, or (at your option) any later version.
|
||||
|
||||
"""Speech History plugin for Cthulhu."""
|
||||
"""Speech history and speech monitor plugin for Cthulhu."""
|
||||
|
||||
import logging
|
||||
|
||||
import gi
|
||||
gi.require_version("Gtk", "3.0")
|
||||
from gi.repository import Gtk, Gdk
|
||||
from gi.repository import Gtk, Gdk, GLib
|
||||
|
||||
from cthulhu.plugin import Plugin, cthulhu_hookimpl
|
||||
from cthulhu import debug
|
||||
from cthulhu import speech
|
||||
from cthulhu import speech_history
|
||||
|
||||
logger = logging.getLogger(__name__)
|
||||
|
||||
|
||||
class SpeechHistory(Plugin):
|
||||
"""Plugin that displays a window containing recent spoken output."""
|
||||
"""Plugin that provides speech history and a live speech monitor."""
|
||||
|
||||
def __init__(self, *args, **kwargs):
|
||||
super().__init__(*args, **kwargs)
|
||||
self._activated = False
|
||||
self._kbOpenWindow = None
|
||||
self._kbToggleMonitor = None
|
||||
|
||||
# Speech history window state
|
||||
self._window = None
|
||||
self._filterEntry = None
|
||||
self._filterText = ""
|
||||
self._listStore = None
|
||||
self._filterModel = None
|
||||
self._treeView = None
|
||||
|
||||
self._capturePaused = False
|
||||
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Plugin initialized", True)
|
||||
# Live monitor window state
|
||||
self._monitorWindow = None
|
||||
self._monitorTextView = None
|
||||
self._monitorTextBuffer = None
|
||||
self._monitorEndMark = None
|
||||
self._monitorLineCount = 0
|
||||
self._monitorMaxLines = 500
|
||||
|
||||
@cthulhu_hookimpl
|
||||
def activate(self, plugin=None):
|
||||
@@ -47,17 +55,13 @@ class SpeechHistory(Plugin):
|
||||
return
|
||||
|
||||
if self._activated:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Already activated, skipping", True)
|
||||
return True
|
||||
|
||||
try:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Activating plugin", True)
|
||||
self._register_keybinding()
|
||||
self._register_keybindings()
|
||||
self._activated = True
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Activated successfully", True)
|
||||
return True
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR during activate: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error activating SpeechHistory plugin")
|
||||
return False
|
||||
|
||||
@@ -67,46 +71,208 @@ class SpeechHistory(Plugin):
|
||||
return
|
||||
|
||||
try:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Deactivating plugin", True)
|
||||
self._close_window()
|
||||
self._disable_monitor()
|
||||
self._kbOpenWindow = None
|
||||
self._kbToggleMonitor = None
|
||||
self._activated = False
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Deactivated successfully", True)
|
||||
return True
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR during deactivate: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error deactivating SpeechHistory plugin")
|
||||
return False
|
||||
|
||||
def _register_keybinding(self):
|
||||
try:
|
||||
if not self.app:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: No app reference; cannot register keybinding", True)
|
||||
return
|
||||
def _register_keybindings(self):
|
||||
if not self.app:
|
||||
debug.printMessage(
|
||||
debug.LEVEL_INFO,
|
||||
"SpeechHistory: No app reference; cannot register keybindings",
|
||||
True,
|
||||
)
|
||||
return
|
||||
|
||||
gestureString = "kb:cthulhu+control+h"
|
||||
description = "Open speech history"
|
||||
historyGesture = "kb:cthulhu+control+h"
|
||||
historyDescription = "Open speech history"
|
||||
self._kbOpenWindow = self.registerGestureByString(
|
||||
self._open_window,
|
||||
historyDescription,
|
||||
historyGesture,
|
||||
)
|
||||
|
||||
self._kbOpenWindow = self.registerGestureByString(
|
||||
self._open_window,
|
||||
description,
|
||||
gestureString,
|
||||
monitorGesture = "kb:cthulhu+shift+d"
|
||||
monitorDescription = "Toggle speech monitor"
|
||||
self._kbToggleMonitor = self.registerGestureByString(
|
||||
self._toggle_monitor,
|
||||
monitorDescription,
|
||||
monitorGesture,
|
||||
)
|
||||
|
||||
if not self._kbOpenWindow:
|
||||
debug.printMessage(
|
||||
debug.LEVEL_INFO,
|
||||
f"SpeechHistory: Failed to register keybinding {historyGesture}",
|
||||
True,
|
||||
)
|
||||
|
||||
if self._kbOpenWindow:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: Registered keybinding {gestureString}", True)
|
||||
else:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: Failed to register keybinding {gestureString}", True)
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR registering keybinding: {e}", True)
|
||||
logger.exception("Error registering keybinding for SpeechHistory")
|
||||
if not self._kbToggleMonitor:
|
||||
debug.printMessage(
|
||||
debug.LEVEL_INFO,
|
||||
f"SpeechHistory: Failed to register keybinding {monitorGesture}",
|
||||
True,
|
||||
)
|
||||
|
||||
# Live monitor methods
|
||||
|
||||
def _toggle_monitor(self, script=None, inputEvent=None):
|
||||
try:
|
||||
if self._monitorWindow is not None:
|
||||
self._disable_monitor()
|
||||
self._present_message("Speech monitor disabled.")
|
||||
return True
|
||||
|
||||
self._enable_monitor()
|
||||
self._present_message("Speech monitor enabled.")
|
||||
return True
|
||||
except Exception:
|
||||
logger.exception("Error toggling speech monitor")
|
||||
self._disable_monitor()
|
||||
self._present_message("Error toggling speech monitor.")
|
||||
return False
|
||||
|
||||
def _enable_monitor(self):
|
||||
if self._monitorWindow is not None:
|
||||
self._monitorWindow.show_all()
|
||||
return
|
||||
|
||||
self._create_monitor_window()
|
||||
speech.set_monitor_callbacks(writeText=self._on_spoken_text)
|
||||
self._monitorWindow.show_all()
|
||||
|
||||
def _disable_monitor(self):
|
||||
speech.set_monitor_callbacks(writeText=None)
|
||||
|
||||
if self._monitorWindow is not None:
|
||||
self._monitorWindow.destroy()
|
||||
|
||||
def _create_monitor_window(self):
|
||||
self._monitorWindow = Gtk.Window(title="Speech Monitor - Cthulhu")
|
||||
self._monitorWindow.set_default_size(900, 320)
|
||||
self._monitorWindow.set_modal(False)
|
||||
self._monitorWindow.set_border_width(8)
|
||||
self._monitorWindow.set_keep_above(True)
|
||||
self._monitorWindow.set_accept_focus(False)
|
||||
self._monitorWindow.set_focus_on_map(False)
|
||||
self._monitorWindow.set_skip_taskbar_hint(True)
|
||||
self._monitorWindow.set_skip_pager_hint(True)
|
||||
self._monitorWindow.set_type_hint(Gdk.WindowTypeHint.UTILITY)
|
||||
|
||||
self._monitorWindow.connect("destroy", self._on_monitor_window_destroy)
|
||||
self._monitorWindow.connect("key-press-event", self._on_monitor_window_key_press)
|
||||
|
||||
mainBox = Gtk.Box(orientation=Gtk.Orientation.VERTICAL, spacing=8)
|
||||
|
||||
scrolledWindow = Gtk.ScrolledWindow()
|
||||
scrolledWindow.set_policy(Gtk.PolicyType.AUTOMATIC, Gtk.PolicyType.AUTOMATIC)
|
||||
|
||||
self._monitorTextView = Gtk.TextView()
|
||||
self._monitorTextView.set_editable(False)
|
||||
self._monitorTextView.set_cursor_visible(False)
|
||||
self._monitorTextView.set_can_focus(False)
|
||||
self._monitorTextView.set_wrap_mode(Gtk.WrapMode.WORD_CHAR)
|
||||
self._monitorTextView.set_accepts_tab(False)
|
||||
self._monitorTextView.set_left_margin(6)
|
||||
self._monitorTextView.set_right_margin(6)
|
||||
self._monitorTextView.set_top_margin(6)
|
||||
self._monitorTextView.set_bottom_margin(6)
|
||||
|
||||
textAccessible = self._monitorTextView.get_accessible()
|
||||
if textAccessible:
|
||||
textAccessible.set_name("Speech monitor output")
|
||||
|
||||
self._monitorTextBuffer = self._monitorTextView.get_buffer()
|
||||
self._monitorEndMark = self._monitorTextBuffer.create_mark(
|
||||
"monitorEnd",
|
||||
self._monitorTextBuffer.get_end_iter(),
|
||||
False,
|
||||
)
|
||||
self._monitorLineCount = 0
|
||||
|
||||
scrolledWindow.add(self._monitorTextView)
|
||||
mainBox.pack_start(scrolledWindow, True, True, 0)
|
||||
|
||||
buttonRow = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=8)
|
||||
buttonRow.set_halign(Gtk.Align.END)
|
||||
|
||||
clearButton = Gtk.Button(label="Clear")
|
||||
closeButton = Gtk.Button(label="Close")
|
||||
clearButton.connect("clicked", self._on_monitor_clear_clicked)
|
||||
closeButton.connect("clicked", self._on_monitor_close_clicked)
|
||||
|
||||
buttonRow.pack_start(clearButton, False, False, 0)
|
||||
buttonRow.pack_start(closeButton, False, False, 0)
|
||||
mainBox.pack_start(buttonRow, False, False, 0)
|
||||
|
||||
self._monitorWindow.add(mainBox)
|
||||
|
||||
def _on_monitor_close_clicked(self, button):
|
||||
self._disable_monitor()
|
||||
|
||||
def _on_monitor_clear_clicked(self, button):
|
||||
if self._monitorTextBuffer is None:
|
||||
return
|
||||
|
||||
self._monitorTextBuffer.set_text("")
|
||||
self._monitorLineCount = 0
|
||||
|
||||
def _on_monitor_window_destroy(self, widget):
|
||||
speech.set_monitor_callbacks(writeText=None)
|
||||
|
||||
self._monitorWindow = None
|
||||
self._monitorTextView = None
|
||||
self._monitorTextBuffer = None
|
||||
self._monitorEndMark = None
|
||||
self._monitorLineCount = 0
|
||||
|
||||
def _on_monitor_window_key_press(self, widget, event):
|
||||
if event.keyval == Gdk.KEY_Escape:
|
||||
self._disable_monitor()
|
||||
return True
|
||||
|
||||
return False
|
||||
|
||||
def _on_spoken_text(self, text):
|
||||
if not text or not isinstance(text, str):
|
||||
return
|
||||
|
||||
GLib.idle_add(self._append_text_on_main_thread, text)
|
||||
|
||||
def _append_text_on_main_thread(self, text):
|
||||
if self._monitorTextBuffer is None:
|
||||
return False
|
||||
|
||||
self._monitorTextBuffer.insert(self._monitorTextBuffer.get_end_iter(), f"{text}\n")
|
||||
self._monitorLineCount += 1
|
||||
|
||||
if self._monitorLineCount > self._monitorMaxLines:
|
||||
excess = self._monitorLineCount - self._monitorMaxLines
|
||||
startIter = self._monitorTextBuffer.get_start_iter()
|
||||
cutIter = self._monitorTextBuffer.get_iter_at_line(excess)
|
||||
self._monitorTextBuffer.delete(startIter, cutIter)
|
||||
self._monitorLineCount = self._monitorMaxLines
|
||||
|
||||
if self._monitorEndMark is not None and self._monitorTextView is not None:
|
||||
self._monitorTextBuffer.move_mark(
|
||||
self._monitorEndMark,
|
||||
self._monitorTextBuffer.get_end_iter(),
|
||||
)
|
||||
self._monitorTextView.scroll_mark_onscreen(self._monitorEndMark)
|
||||
|
||||
return False
|
||||
|
||||
# Speech history methods
|
||||
|
||||
def _open_window(self, script=None, inputEvent=None):
|
||||
try:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Open window requested", True)
|
||||
|
||||
if self._window:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Window already open; presenting", True)
|
||||
self._window.present()
|
||||
return True
|
||||
|
||||
@@ -120,10 +286,8 @@ class SpeechHistory(Plugin):
|
||||
elif self._filterEntry:
|
||||
self._filterEntry.grab_focus()
|
||||
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Window shown", True)
|
||||
return True
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR opening window: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error opening SpeechHistory window")
|
||||
self._resume_capture()
|
||||
return False
|
||||
@@ -141,7 +305,6 @@ class SpeechHistory(Plugin):
|
||||
|
||||
self._filterText = ""
|
||||
|
||||
# Filter row
|
||||
filterRow = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
|
||||
filterLabel = Gtk.Label(label="_Filter:")
|
||||
filterLabel.set_use_underline(True)
|
||||
@@ -156,7 +319,6 @@ class SpeechHistory(Plugin):
|
||||
filterRow.pack_start(self._filterEntry, True, True, 0)
|
||||
mainBox.pack_start(filterRow, False, False, 0)
|
||||
|
||||
# List
|
||||
self._listStore = Gtk.ListStore(str)
|
||||
self._filterModel = self._listStore.filter_new()
|
||||
self._filterModel.set_visible_func(self._filter_visible_func)
|
||||
@@ -169,7 +331,7 @@ class SpeechHistory(Plugin):
|
||||
|
||||
textRenderer = Gtk.CellRendererText()
|
||||
textRenderer.set_property("wrap-width", 640)
|
||||
textRenderer.set_property("wrap-mode", 2) # Pango.WrapMode.WORD_CHAR
|
||||
textRenderer.set_property("wrap-mode", 2)
|
||||
textColumn = Gtk.TreeViewColumn("Spoken Text", textRenderer, text=0)
|
||||
textColumn.set_resizable(True)
|
||||
textColumn.set_expand(True)
|
||||
@@ -180,7 +342,6 @@ class SpeechHistory(Plugin):
|
||||
scrolled.add(self._treeView)
|
||||
mainBox.pack_start(scrolled, True, True, 0)
|
||||
|
||||
# Buttons
|
||||
buttonRow = Gtk.Box(orientation=Gtk.Orientation.HORIZONTAL, spacing=10)
|
||||
buttonRow.set_halign(Gtk.Align.END)
|
||||
|
||||
@@ -201,16 +362,12 @@ class SpeechHistory(Plugin):
|
||||
|
||||
self._refresh_list(selectFirst=True)
|
||||
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Window created", True)
|
||||
|
||||
def _on_filter_changed(self, entry):
|
||||
try:
|
||||
self._filterText = entry.get_text() or ""
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: Filter changed '{self._filterText}'", True)
|
||||
if self._filterModel:
|
||||
self._filterModel.refilter()
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR filtering: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error updating speech history filter")
|
||||
|
||||
def _filter_visible_func(self, model, treeIter, data=None):
|
||||
@@ -221,8 +378,7 @@ class SpeechHistory(Plugin):
|
||||
|
||||
spokenText = model[treeIter][0] or ""
|
||||
return spokenText.lower().startswith(filterText)
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR in filter func: {e}", True)
|
||||
except Exception:
|
||||
return True
|
||||
|
||||
def _refresh_list(self, selectFirst=False):
|
||||
@@ -230,31 +386,19 @@ class SpeechHistory(Plugin):
|
||||
if not self._listStore:
|
||||
return
|
||||
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Refreshing list", True)
|
||||
self._listStore.clear()
|
||||
|
||||
items = speech_history.get_items()
|
||||
debug.printMessage(
|
||||
debug.LEVEL_INFO,
|
||||
f"SpeechHistory: Retrieved {len(items)} items (paused={speech_history.is_capture_paused()})",
|
||||
True,
|
||||
)
|
||||
for item in items:
|
||||
self._listStore.append([item])
|
||||
|
||||
if self._filterModel:
|
||||
self._filterModel.refilter()
|
||||
debug.printMessage(
|
||||
debug.LEVEL_INFO,
|
||||
f"SpeechHistory: Filtered items visible={len(self._filterModel)} filter='{self._filterText}'",
|
||||
True,
|
||||
)
|
||||
|
||||
if selectFirst and self._treeView and len(self._filterModel) > 0:
|
||||
selection = self._treeView.get_selection()
|
||||
selection.select_path(Gtk.TreePath.new_first())
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR refreshing list: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error refreshing speech history list")
|
||||
|
||||
def _get_selected_text(self):
|
||||
@@ -268,8 +412,7 @@ class SpeechHistory(Plugin):
|
||||
return None
|
||||
|
||||
return model[treeIter][0]
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR getting selection: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error getting selected speech history item")
|
||||
return None
|
||||
|
||||
@@ -284,11 +427,8 @@ class SpeechHistory(Plugin):
|
||||
clipboard.set_text(selectedText, -1)
|
||||
clipboard.store()
|
||||
|
||||
preview = selectedText[:60] + ("..." if len(selectedText) > 60 else "")
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: Copied to clipboard '{preview}'", True)
|
||||
self._present_message("Copied to clipboard.")
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR copying: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error copying speech history item to clipboard")
|
||||
self._present_message("Error copying to clipboard.")
|
||||
|
||||
@@ -300,33 +440,27 @@ class SpeechHistory(Plugin):
|
||||
return
|
||||
|
||||
removed = speech_history.remove(selectedText)
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: Remove requested removed={removed}", True)
|
||||
if removed:
|
||||
self._refresh_list(selectFirst=True)
|
||||
self._present_message("Removed from history.")
|
||||
else:
|
||||
self._present_message("Item not found in history.")
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR removing: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error removing speech history item")
|
||||
self._present_message("Error removing item from history.")
|
||||
|
||||
def _on_close_clicked(self, button):
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Close button clicked", True)
|
||||
self._close_window()
|
||||
|
||||
def _close_window(self):
|
||||
try:
|
||||
if self._window:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Closing window", True)
|
||||
self._window.destroy()
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR closing window: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error closing SpeechHistory window")
|
||||
self._resume_capture()
|
||||
|
||||
def _on_window_destroy(self, widget):
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Window destroyed", True)
|
||||
self._window = None
|
||||
self._filterEntry = None
|
||||
self._listStore = None
|
||||
@@ -338,14 +472,12 @@ class SpeechHistory(Plugin):
|
||||
def _on_window_key_press(self, widget, event):
|
||||
try:
|
||||
if event.keyval == Gdk.KEY_Escape:
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Escape pressed; closing window", True)
|
||||
self._close_window()
|
||||
return True
|
||||
|
||||
if not self._filterEntry or self._filterEntry.is_focus():
|
||||
return False
|
||||
|
||||
# If user starts typing anywhere, move focus to filter and update it.
|
||||
if event.keyval == Gdk.KEY_BackSpace:
|
||||
currentText = self._filterEntry.get_text() or ""
|
||||
if currentText:
|
||||
@@ -376,8 +508,7 @@ class SpeechHistory(Plugin):
|
||||
self._filterEntry.set_text(currentText + charTyped)
|
||||
self._filterEntry.set_position(-1)
|
||||
return True
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR in key handler: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error handling key press in SpeechHistory window")
|
||||
return False
|
||||
|
||||
@@ -385,7 +516,6 @@ class SpeechHistory(Plugin):
|
||||
if self._capturePaused:
|
||||
return
|
||||
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Pausing capture while window is open", True)
|
||||
speech_history.pause_capture(reason="SpeechHistory window open")
|
||||
self._capturePaused = True
|
||||
|
||||
@@ -393,7 +523,6 @@ class SpeechHistory(Plugin):
|
||||
if not self._capturePaused:
|
||||
return
|
||||
|
||||
debug.printMessage(debug.LEVEL_INFO, "SpeechHistory: Resuming capture (window closed)", True)
|
||||
speech_history.resume_capture(reason="SpeechHistory window closed")
|
||||
self._capturePaused = False
|
||||
|
||||
@@ -408,6 +537,5 @@ class SpeechHistory(Plugin):
|
||||
state.activeScript.presentMessage(message, resetStyles=False)
|
||||
else:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: {message}", True)
|
||||
except Exception as e:
|
||||
debug.printMessage(debug.LEVEL_INFO, f"SpeechHistory: ERROR presenting message: {e}", True)
|
||||
except Exception:
|
||||
logger.exception("Error presenting message from SpeechHistory")
|
||||
|
||||
@@ -5122,6 +5122,9 @@ class Utilities:
|
||||
if not event.type.startswith("object:text-changed:insert"):
|
||||
return False
|
||||
|
||||
if not cthulhu.cthulhuApp.settingsManager.getSetting("enableKeyEcho"):
|
||||
return False
|
||||
|
||||
if AXUtilities.is_focusable(event.source) \
|
||||
and not AXUtilities.is_focused(event.source) \
|
||||
and event.source != cthulhu_state.locusOfFocus:
|
||||
|
||||
@@ -44,6 +44,7 @@ from gi.repository import Gdk
|
||||
import re
|
||||
import time
|
||||
|
||||
import cthulhu.acss as acss
|
||||
import cthulhu.braille as braille
|
||||
import cthulhu.cmdnames as cmdnames
|
||||
import cthulhu.dbus_service as dbus_service
|
||||
@@ -1473,7 +1474,9 @@ class Script(script.Script):
|
||||
"""Callback for object:announcement events."""
|
||||
|
||||
if isinstance(event.any_data, str):
|
||||
self.presentMessage(event.any_data)
|
||||
# AT-SPI announcements contain application content, not system messages.
|
||||
# Use resetStyles=False to preserve the user's punctuation settings.
|
||||
self.presentMessage(event.any_data, resetStyles=False)
|
||||
|
||||
def onNameChanged(self, event):
|
||||
"""Callback for object:property-change:accessible-name events."""
|
||||
@@ -1816,6 +1819,9 @@ class Script(script.Script):
|
||||
if len(string) != 1:
|
||||
return
|
||||
|
||||
if not cthulhu.cthulhuApp.settingsManager.getSetting('enableKeyEcho'):
|
||||
return
|
||||
|
||||
if cthulhu.cthulhuApp.settingsManager.getSetting('enableEchoBySentence') \
|
||||
and self.echoPreviousSentence(event.source):
|
||||
return
|
||||
@@ -1965,6 +1971,15 @@ class Script(script.Script):
|
||||
debug.printMessage(debug.LEVEL_INFO, msg, True)
|
||||
return
|
||||
|
||||
# Some toolkits emit transient window:deactivate/window:activate pairs
|
||||
# while the same window remains active. Treat those as noise so we do
|
||||
# not clear state and force a full script/settings reactivation.
|
||||
AXObject.clear_cache(event.source)
|
||||
if AXUtilities.is_active(event.source):
|
||||
msg = "DEFAULT: Ignoring event. Source window still active."
|
||||
debug.printMessage(debug.LEVEL_INFO, msg, True)
|
||||
return
|
||||
|
||||
if self.flatReviewPresenter.is_active():
|
||||
self.flatReviewPresenter.quit()
|
||||
|
||||
@@ -2217,9 +2232,12 @@ class Script(script.Script):
|
||||
sentence = self.utilities.substring(obj, sentenceStartOffset + 1,
|
||||
sentenceEndOffset + 1)
|
||||
|
||||
voice = self.speechGenerator.voice(obj=obj, string=sentence)
|
||||
sentence = self.utilities.adjustForRepeats(sentence)
|
||||
self.speakMessage(sentence, voice)
|
||||
if self._shouldUseCustomEchoVoice("sentence"):
|
||||
speech.speakEchoText(sentence, self._getCustomEchoVoice())
|
||||
else:
|
||||
voice = self.speechGenerator.voice(obj=obj, string=sentence)
|
||||
self.speakMessage(sentence, voice)
|
||||
return True
|
||||
|
||||
def echoPreviousWord(self, obj, offset=None):
|
||||
@@ -2286,9 +2304,12 @@ class Script(script.Script):
|
||||
word = self.utilities.\
|
||||
substring(obj, wordStartOffset + 1, wordEndOffset + 1)
|
||||
|
||||
voice = self.speechGenerator.voice(obj=obj, string=word)
|
||||
word = self.utilities.adjustForRepeats(word)
|
||||
self.speakMessage(word, voice)
|
||||
if self._shouldUseCustomEchoVoice("word"):
|
||||
speech.speakEchoText(word, self._getCustomEchoVoice())
|
||||
else:
|
||||
voice = self.speechGenerator.voice(obj=obj, string=word)
|
||||
self.speakMessage(word, voice)
|
||||
return True
|
||||
|
||||
def sayCharacter(self, obj):
|
||||
@@ -2890,6 +2911,9 @@ class Script(script.Script):
|
||||
if not event.shouldEcho or event.isCthulhuModified():
|
||||
return False
|
||||
|
||||
if not cthulhu.cthulhuApp.settingsManager.getSetting('enableKeyEcho'):
|
||||
return False
|
||||
|
||||
role = AXObject.get_role(cthulhu_state.locusOfFocus)
|
||||
if role in [Atspi.Role.DIALOG, Atspi.Role.FRAME, Atspi.Role.WINDOW]:
|
||||
focusedObject = AXUtilities.get_focused_object(cthulhu_state.activeWindow)
|
||||
@@ -3330,6 +3354,47 @@ class Script(script.Script):
|
||||
# #
|
||||
########################################################################
|
||||
|
||||
def _shouldUseCustomEchoVoice(self, echoType):
|
||||
"""Returns True if custom echo settings should be used for the given type."""
|
||||
|
||||
settingForType = {
|
||||
"key": "useCustomEchoForKey",
|
||||
"character": "useCustomEchoForCharacter",
|
||||
"word": "useCustomEchoForWord",
|
||||
"sentence": "useCustomEchoForSentence",
|
||||
}
|
||||
|
||||
settingName = settingForType.get(echoType)
|
||||
if not settingName:
|
||||
return False
|
||||
|
||||
settingsManager = cthulhu.cthulhuApp.settingsManager
|
||||
if not settingsManager.getSetting("enableKeyEcho"):
|
||||
return False
|
||||
|
||||
if not settingsManager.getSetting("useCustomEchoVoice"):
|
||||
return False
|
||||
|
||||
return settingsManager.getSetting(settingName)
|
||||
|
||||
def _getCustomEchoVoice(self):
|
||||
"""Returns the effective ACSS voice for custom echo output."""
|
||||
|
||||
settingsManager = cthulhu.cthulhuApp.settingsManager
|
||||
voices = settingsManager.getSetting("voices") or {}
|
||||
defaultVoice = acss.ACSS(voices.get(settings.DEFAULT_VOICE, {}))
|
||||
|
||||
echoVoice = settingsManager.getSetting("echoVoice")
|
||||
if not echoVoice:
|
||||
return defaultVoice
|
||||
|
||||
try:
|
||||
defaultVoice.update(acss.ACSS(echoVoice))
|
||||
except Exception:
|
||||
debug.printException(debug.LEVEL_INFO)
|
||||
|
||||
return defaultVoice
|
||||
|
||||
def speakKeyEvent(self, event):
|
||||
"""Method to speak a keyboard event. Scripts should use this method
|
||||
rather than calling speech.speakKeyEvent directly."""
|
||||
@@ -3338,6 +3403,10 @@ class Script(script.Script):
|
||||
if event.is_printable_key():
|
||||
string = event.event_string
|
||||
|
||||
if self._shouldUseCustomEchoVoice("key"):
|
||||
speech.speakEchoKeyEvent(event, self._getCustomEchoVoice())
|
||||
return
|
||||
|
||||
voice = self.speechGenerator.voice(string=string)
|
||||
speech.speakKeyEvent(event, voice)
|
||||
|
||||
@@ -3345,6 +3414,10 @@ class Script(script.Script):
|
||||
"""Method to speak a single character. Scripts should use this
|
||||
method rather than calling speech.speakCharacter directly."""
|
||||
|
||||
if self._shouldUseCustomEchoVoice("character"):
|
||||
speech.speakEchoCharacter(character, self._getCustomEchoVoice())
|
||||
return
|
||||
|
||||
voice = self.speechGenerator.voice(string=character)
|
||||
speech.speakCharacter(character, voice)
|
||||
|
||||
|
||||
@@ -1648,9 +1648,21 @@ class Script(default.Script):
|
||||
elif self.utilities.isContentEditableWithEmbeddedObjects(newFocus) \
|
||||
and (self._lastCommandWasCaretNav or self._lastCommandWasStructNav) \
|
||||
and not (AXUtilities.is_table_cell(newFocus) and AXObject.get_name(newFocus)):
|
||||
tokens = ["WEB: New focus", newFocus, "content editable. Generating line."]
|
||||
debug.printTokens(debug.LEVEL_INFO, tokens, True)
|
||||
contents = self.utilities.getLineContentsAtOffset(newFocus, caretOffset)
|
||||
# Check if we're entering the content editable from outside (e.g. down arrow
|
||||
# from a message list into a message entry). In that case, generate full object
|
||||
# speech (with label and role) rather than just line contents.
|
||||
enteredFromOutside = oldFocus is not None \
|
||||
and oldFocus != newFocus \
|
||||
and not AXObject.find_ancestor(oldFocus, lambda x: x == newFocus)
|
||||
if enteredFromOutside:
|
||||
tokens = ["WEB: New focus", newFocus,
|
||||
"content editable entered from outside. Generating speech."]
|
||||
debug.printTokens(debug.LEVEL_INFO, tokens, True)
|
||||
args['priorObj'] = oldFocus
|
||||
else:
|
||||
tokens = ["WEB: New focus", newFocus, "content editable. Generating line."]
|
||||
debug.printTokens(debug.LEVEL_INFO, tokens, True)
|
||||
contents = self.utilities.getLineContentsAtOffset(newFocus, caretOffset)
|
||||
elif self.utilities.isAnchor(newFocus):
|
||||
tokens = ["WEB: New focus", newFocus, "is anchor. Generating line."]
|
||||
debug.printTokens(debug.LEVEL_INFO, tokens, True)
|
||||
|
||||
Some files were not shown because too many files have changed in this diff Show More
Reference in New Issue
Block a user