The truly free, open-source, local-first, cross-platform CapCut replacement. Scriptable through a JSON-RPC API & MCP.
Rust ffmpegfree-video-editormodel-context-protocolnon-linear-editoroffline-firstopen-source-video-editorself-hostedvideo-editingvideo-editing-automationvideo-editing-softwarevideo-editing-toolsvideo-editorvoice-cloningyoutube-automationyoutube-shorts
feat(voices): Import voice on the Voices shelf - a recording of your own kept as a voice, with a name, a picture and a description (#518)
Jareer13e67ea2a8d3
diff --git a/src/crates/concat/locales/ar.json b/src/crates/concat/locales/ar.jsonindex 2e99bec1..6189d928 100644--- a/src/crates/concat/locales/ar.json+++ b/src/crates/concat/locales/ar.json@@ -905,9 +905,17 @@"voiceover.title": "التعليق الصوتي","voiceover.tryAgain": "إعادة المحاولة","voices.builtIn": "الأصوات المدمجة",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "انقر على صوت لتكتب به في تحويل النص إلى كلام.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "نزّل نموذج صوت من الإعدادات › الكلام لتسمع الأصوات المدمجة.","voices.noneSavedYet": "لا توجد أصوات خاصة بك بعد. في تحويل النص إلى كلام، فعّل استخدام صوت من عينة، واختر تسجيلًا واحفظه باسم. يبقى على هذا الجهاز.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "أُزيل الصوت {0}","voices.saved": "حُفظ الصوت {0}. ستجده في قائمة الأصوات في كل مشروع.","voices.styleChipmunk": "سنجاب",diff --git a/src/crates/concat/locales/az.json b/src/crates/concat/locales/az.jsonindex db3c7baa..787a0c1a 100644--- a/src/crates/concat/locales/az.json+++ b/src/crates/concat/locales/az.json@@ -905,9 +905,17 @@"voiceover.title": "Səsləndirmə","voiceover.tryAgain": "Yenidən cəhd et","voices.builtIn": "Daxili səslər",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Mətndən nitqə bölməsində həmin səslə yazmaq üçün bir səsə klikləyin.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Daxili səsləri eşitmək üçün Parametrlər › Nitq bölməsindən bir səs modeli yükləyin.","voices.noneSavedYet": "Hələ öz səsiniz yoxdur. Mətndən nitqə bölməsində Nümunə səsdən istifadə et seçimini yandırın, bir yazı seçin və onu adla yadda saxlayın. O, bu cihazda qalır.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "{0} səsi silindi","voices.saved": "{0} səsi yadda saxlanıldı. O, hər layihənin səs siyahısındadır.","voices.styleChipmunk": "Sincab",diff --git a/src/crates/concat/locales/bn.json b/src/crates/concat/locales/bn.jsonindex a9060f90..94730e3a 100644--- a/src/crates/concat/locales/bn.json+++ b/src/crates/concat/locales/bn.json@@ -905,9 +905,17 @@"voiceover.title": "ভয়েসওভার","voiceover.tryAgain": "আবার চেষ্টা করুন","voices.builtIn": "বিল্ট-ইন কণ্ঠ",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "টেক্সট থেকে স্পিচে কোনো কণ্ঠ দিয়ে লিখতে সেটিতে ক্লিক করুন।",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "বিল্ট-ইন কণ্ঠ শুনতে সেটিংস › স্পিচ থেকে একটি ভয়েস মডেল ডাউনলোড করুন।","voices.noneSavedYet": "এখনও আপনার নিজের কোনো কণ্ঠ নেই। টেক্সট থেকে স্পিচে স্যাম্পল কণ্ঠ ব্যবহার চালু করুন, একটি রেকর্ডিং বেছে নিয়ে নাম দিয়ে সংরক্ষণ করুন। এটি এই ডিভাইসেই থাকে।",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "কণ্ঠ {0} সরানো হয়েছে","voices.saved": "কণ্ঠ {0} সংরক্ষিত হয়েছে। প্রতিটি প্রজেক্টের কণ্ঠ তালিকায় এটি থাকবে।","voices.styleChipmunk": "চিপমাঙ্ক",diff --git a/src/crates/concat/locales/de.json b/src/crates/concat/locales/de.jsonindex 4f210f71..0870d059 100644--- a/src/crates/concat/locales/de.json+++ b/src/crates/concat/locales/de.json@@ -905,9 +905,17 @@"voiceover.title": "Voiceover","voiceover.tryAgain": "Erneut versuchen","voices.builtIn": "Eingebaute Stimmen",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Klicke auf eine Stimme, um mit ihr in Text zu Sprache zu schreiben.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Lade unter Einstellungen › Sprache ein Stimmmodell herunter, um die eingebauten Stimmen zu hören.","voices.noneSavedYet": "Noch keine eigenen Stimmen. Schalte in Text zu Sprache die Beispielstimme ein, wähle eine Aufnahme und speichere sie unter einem Namen. Sie bleibt auf diesem Gerät.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Die Stimme {0} wurde entfernt","voices.saved": "Die Stimme {0} wurde gespeichert. Sie steht in jedem Projekt in der Stimmenliste.","voices.styleChipmunk": "Streifenhörnchen",diff --git a/src/crates/concat/locales/en.json b/src/crates/concat/locales/en.jsonindex 7cc761ff..fc3e5931 100644--- a/src/crates/concat/locales/en.json+++ b/src/crates/concat/locales/en.json@@ -905,9 +905,17 @@"voiceover.title": "Voiceover","voiceover.tryAgain": "Try again","voices.builtIn": "Built-in voices",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Click a voice to write with it in Text to speech.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Download a voice model in Settings › Speech to hear the built-in voices.","voices.noneSavedYet": "No voices of your own yet. In Text to speech, turn on Use sample voice, pick a recording and save it with a name. It stays on this device.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Removed the voice {0}","voices.saved": "Saved the voice {0}. It is in the voice list of every project.","voices.styleChipmunk": "Chipmunk",diff --git a/src/crates/concat/locales/es.json b/src/crates/concat/locales/es.jsonindex 9b84d33d..90da910f 100644--- a/src/crates/concat/locales/es.json+++ b/src/crates/concat/locales/es.json@@ -905,9 +905,17 @@"voiceover.title": "Voz en off","voiceover.tryAgain": "Reintentar","voices.builtIn": "Voces integradas",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Haz clic en una voz para escribir con ella en Texto a voz.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Descarga un modelo de voz en Ajustes › Voz para oír las voces integradas.","voices.noneSavedYet": "Todavía no tienes voces propias. En Texto a voz, activa Usar voz de muestra, elige una grabación y guárdala con un nombre. Se queda en este dispositivo.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Se quitó la voz {0}","voices.saved": "Se guardó la voz {0}. Está en la lista de voces de todos los proyectos.","voices.styleChipmunk": "Ardilla",diff --git a/src/crates/concat/locales/fa.json b/src/crates/concat/locales/fa.jsonindex 988d0259..53bb8e6d 100644--- a/src/crates/concat/locales/fa.json+++ b/src/crates/concat/locales/fa.json@@ -905,9 +905,17 @@"voiceover.title": "صداگذاری","voiceover.tryAgain": "تلاش دوباره","voices.builtIn": "صداهای داخلی",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "روی یک صدا کلیک کنید تا در تبدیل متن به گفتار با آن بنویسید.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "برای شنیدن صداهای داخلی، یک مدل صدا را از تنظیمات › گفتار دانلود کنید.","voices.noneSavedYet": "هنوز صدایی از خودتان ندارید. در تبدیل متن به گفتار، استفاده از صدای نمونه را روشن کنید، یک ضبط را انتخاب کنید و با یک نام ذخیرهاش کنید. روی همین دستگاه میماند.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "صدای {0} حذف شد","voices.saved": "صدای {0} ذخیره شد. در فهرست صداهای هر پروژه هست.","voices.styleChipmunk": "سنجاب",diff --git a/src/crates/concat/locales/fr.json b/src/crates/concat/locales/fr.jsonindex 3bf71b76..2f206992 100644--- a/src/crates/concat/locales/fr.json+++ b/src/crates/concat/locales/fr.json@@ -905,9 +905,17 @@"voiceover.title": "Voix off","voiceover.tryAgain": "Réessayer","voices.builtIn": "Voix intégrées",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Cliquez sur une voix pour écrire avec elle dans Synthèse vocale.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Téléchargez un modèle de voix dans Réglages › Parole pour entendre les voix intégrées.","voices.noneSavedYet": "Pas encore de voix à vous. Dans Synthèse vocale, activez Utiliser une voix d’exemple, choisissez un enregistrement et enregistrez-le sous un nom. Il reste sur cet appareil.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "La voix {0} a été supprimée","voices.saved": "La voix {0} est enregistrée. Elle figure dans la liste des voix de chaque projet.","voices.styleChipmunk": "Tamia",diff --git a/src/crates/concat/locales/he.json b/src/crates/concat/locales/he.jsonindex 20dacf26..ebf50685 100644--- a/src/crates/concat/locales/he.json+++ b/src/crates/concat/locales/he.json@@ -905,9 +905,17 @@"voiceover.title": "קריינות","voiceover.tryAgain": "ניסיון חוזר","voices.builtIn": "קולות מובנים",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "לחצו על קול כדי לכתוב איתו בהקראת טקסט.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "הורידו מודל קול בהגדרות › דיבור כדי לשמוע את הקולות המובנים.","voices.noneSavedYet": "עדיין אין קולות משלכם. בהקראת טקסט, הפעילו שימוש בקול מדגימה, בחרו הקלטה ושמרו אותה בשם. היא נשארת במכשיר הזה.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "הקול {0} הוסר","voices.saved": "הקול {0} נשמר. הוא מופיע ברשימת הקולות בכל פרויקט.","voices.styleChipmunk": "סנאי",diff --git a/src/crates/concat/locales/hi.json b/src/crates/concat/locales/hi.jsonindex 5dde091a..cdcff676 100644--- a/src/crates/concat/locales/hi.json+++ b/src/crates/concat/locales/hi.json@@ -905,9 +905,17 @@"voiceover.title": "वॉइसओवर","voiceover.tryAgain": "दोबारा कोशिश करें","voices.builtIn": "बिल्ट-इन आवाज़ें",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "टेक्स्ट से वाणी में किसी आवाज़ से लिखने के लिए उस पर क्लिक करें।",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "बिल्ट-इन आवाज़ें सुनने के लिए सेटिंग्स › स्पीच में कोई वॉइस मॉडल डाउनलोड करें।","voices.noneSavedYet": "अभी आपकी कोई अपनी आवाज़ नहीं है। टेक्स्ट से वाणी में सैंपल आवाज़ का उपयोग चालू करें, कोई रिकॉर्डिंग चुनें और उसे नाम देकर सहेजें। वह इसी डिवाइस पर रहती है।",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "आवाज़ {0} हटाई गई","voices.saved": "आवाज़ {0} सहेजी गई। यह हर प्रोजेक्ट की आवाज़ सूची में है।","voices.styleChipmunk": "गिलहरी",diff --git a/src/crates/concat/locales/hr.json b/src/crates/concat/locales/hr.jsonindex 05b39348..c1d71472 100644--- a/src/crates/concat/locales/hr.json+++ b/src/crates/concat/locales/hr.json@@ -905,9 +905,17 @@"voiceover.title": "Snimanje glasa","voiceover.tryAgain": "Pokušaj ponovno","voices.builtIn": "Ugrađeni glasovi",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Kliknite glas da biste njime pisali u Tekstu u govor.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Preuzmite glasovni model u Postavke › Govor da biste čuli ugrađene glasove.","voices.noneSavedYet": "Još nemate vlastitih glasova. U Tekstu u govor uključite Koristi glas iz uzorka, odaberite snimku i spremite je pod imenom. Ostaje na ovom uređaju.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Glas {0} je uklonjen","voices.saved": "Glas {0} je spremljen. Nalazi se na popisu glasova u svakom projektu.","voices.styleChipmunk": "Vjeverica",diff --git a/src/crates/concat/locales/id.json b/src/crates/concat/locales/id.jsonindex a4dfd8bb..399d2643 100644--- a/src/crates/concat/locales/id.json+++ b/src/crates/concat/locales/id.json@@ -905,9 +905,17 @@"voiceover.title": "Sulih suara","voiceover.tryAgain": "Coba lagi","voices.builtIn": "Suara bawaan",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Klik suara untuk menulis dengannya di Teks ke ucapan.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Unduh model suara di Pengaturan › Ucapan untuk mendengar suara bawaan.","voices.noneSavedYet": "Belum ada suara milikmu. Di Teks ke ucapan, aktifkan Gunakan suara sampel, pilih rekaman, lalu simpan dengan nama. Suara itu tetap di perangkat ini.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Suara {0} dihapus","voices.saved": "Suara {0} disimpan. Suara itu ada di daftar suara setiap proyek.","voices.styleChipmunk": "Tupai",diff --git a/src/crates/concat/locales/it.json b/src/crates/concat/locales/it.jsonindex 192b457d..f3365487 100644--- a/src/crates/concat/locales/it.json+++ b/src/crates/concat/locales/it.json@@ -905,9 +905,17 @@"voiceover.title": "Voce fuori campo","voiceover.tryAgain": "Riprova","voices.builtIn": "Voci integrate",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Fai clic su una voce per scrivere con lei in Sintesi vocale.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Scarica un modello vocale in Impostazioni › Voce per ascoltare le voci integrate.","voices.noneSavedYet": "Nessuna voce tua per ora. In Sintesi vocale, attiva Usa voce campione, scegli una registrazione e salvala con un nome. Resta su questo dispositivo.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Voce {0} rimossa","voices.saved": "Voce {0} salvata. È nell’elenco delle voci di ogni progetto.","voices.styleChipmunk": "Scoiattolo",diff --git a/src/crates/concat/locales/ja.json b/src/crates/concat/locales/ja.jsonindex 46ae060a..1c7ddfbd 100644--- a/src/crates/concat/locales/ja.json+++ b/src/crates/concat/locales/ja.json@@ -905,9 +905,17 @@"voiceover.title": "ナレーション","voiceover.tryAgain": "再試行","voices.builtIn": "内蔵ボイス",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "ボイスをクリックすると、読み上げでその声を使えます。",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "内蔵ボイスを聞くには、設定 › 音声 で音声モデルをダウンロードしてください。","voices.noneSavedYet": "自分のボイスはまだありません。読み上げで「サンプルの声を使う」をオンにし、録音を選んで名前を付けて保存してください。この端末にだけ保存されます。",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "ボイス {0} を削除しました","voices.saved": "ボイス {0} を保存しました。どのプロジェクトのボイス一覧にも表示されます。","voices.styleChipmunk": "シマリス",diff --git a/src/crates/concat/locales/ko.json b/src/crates/concat/locales/ko.jsonindex 0f153da5..666d02f0 100644--- a/src/crates/concat/locales/ko.json+++ b/src/crates/concat/locales/ko.json@@ -905,9 +905,17 @@"voiceover.title": "내레이션","voiceover.tryAgain": "다시 시도","voices.builtIn": "기본 목소리",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "목소리를 클릭하면 텍스트 음성 변환에서 그 목소리로 씁니다.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "기본 목소리를 들으려면 설정 › 음성에서 음성 모델을 내려받으세요.","voices.noneSavedYet": "아직 내 목소리가 없습니다. 텍스트 음성 변환에서 샘플 목소리 사용을 켜고 녹음을 골라 이름을 붙여 저장하세요. 이 기기에만 저장됩니다.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "목소리 {0}을(를) 제거했습니다","voices.saved": "목소리 {0}을(를) 저장했습니다. 모든 프로젝트의 목소리 목록에 있습니다.","voices.styleChipmunk": "다람쥐",diff --git a/src/crates/concat/locales/nl.json b/src/crates/concat/locales/nl.jsonindex d0a1ae40..28789011 100644--- a/src/crates/concat/locales/nl.json+++ b/src/crates/concat/locales/nl.json@@ -905,9 +905,17 @@"voiceover.title": "Voice-over","voiceover.tryAgain": "Opnieuw proberen","voices.builtIn": "Ingebouwde stemmen",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Klik op een stem om ermee te schrijven in Tekst naar spraak.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Download een stemmodel in Instellingen › Spraak om de ingebouwde stemmen te horen.","voices.noneSavedYet": "Nog geen eigen stemmen. Zet in Tekst naar spraak Voorbeeldstem gebruiken aan, kies een opname en bewaar die met een naam. Hij blijft op dit apparaat.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Stem {0} verwijderd","voices.saved": "Stem {0} bewaard. Hij staat in de stemmenlijst van elk project.","voices.styleChipmunk": "Eekhoorn",diff --git a/src/crates/concat/locales/pl.json b/src/crates/concat/locales/pl.jsonindex a6ef3988..d0f03140 100644--- a/src/crates/concat/locales/pl.json+++ b/src/crates/concat/locales/pl.json@@ -905,9 +905,17 @@"voiceover.title": "Nagranie lektora","voiceover.tryAgain": "Spróbuj ponownie","voices.builtIn": "Wbudowane głosy",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Kliknij głos, aby pisać nim w Zamianie tekstu na mowę.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Pobierz model głosu w Ustawienia › Mowa, aby usłyszeć wbudowane głosy.","voices.noneSavedYet": "Nie masz jeszcze własnych głosów. W Zamianie tekstu na mowę włącz Użyj głosu z próbki, wybierz nagranie i zapisz je pod nazwą. Zostaje na tym urządzeniu.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Usunięto głos {0}","voices.saved": "Zapisano głos {0}. Jest na liście głosów w każdym projekcie.","voices.styleChipmunk": "Wiewiórka",diff --git a/src/crates/concat/locales/pt-BR.json b/src/crates/concat/locales/pt-BR.jsonindex 1f62c4e0..27fa6724 100644--- a/src/crates/concat/locales/pt-BR.json+++ b/src/crates/concat/locales/pt-BR.json@@ -905,9 +905,17 @@"voiceover.title": "Narração","voiceover.tryAgain": "Tentar de novo","voices.builtIn": "Vozes integradas",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Clique em uma voz para escrever com ela em Texto para fala.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Baixe um modelo de voz em Configurações › Fala para ouvir as vozes integradas.","voices.noneSavedYet": "Ainda não há vozes suas. Em Texto para fala, ative Usar voz de amostra, escolha uma gravação e salve-a com um nome. Ela fica neste dispositivo.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "A voz {0} foi removida","voices.saved": "A voz {0} foi salva. Ela está na lista de vozes de todos os projetos.","voices.styleChipmunk": "Esquilo",diff --git a/src/crates/concat/locales/ru.json b/src/crates/concat/locales/ru.jsonindex 29cbeb35..821e70c1 100644--- a/src/crates/concat/locales/ru.json+++ b/src/crates/concat/locales/ru.json@@ -905,9 +905,17 @@"voiceover.title": "Закадровый голос","voiceover.tryAgain": "Повторить","voices.builtIn": "Встроенные голоса",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Нажмите на голос, чтобы писать им в «Озвучке текста».",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Скачайте голосовую модель в «Настройки › Речь», чтобы услышать встроенные голоса.","voices.noneSavedYet": "Своих голосов пока нет. В «Озвучке текста» включите «Голос из образца», выберите запись и сохраните её под именем. Голос останется на этом устройстве.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Голос «{0}» удалён","voices.saved": "Голос «{0}» сохранён. Он есть в списке голосов любого проекта.","voices.styleChipmunk": "Бурундук",diff --git a/src/crates/concat/locales/th.json b/src/crates/concat/locales/th.jsonindex cca1bdaf..5e8cae11 100644--- a/src/crates/concat/locales/th.json+++ b/src/crates/concat/locales/th.json@@ -905,9 +905,17 @@"voiceover.title": "เสียงพากย์","voiceover.tryAgain": "ลองอีกครั้ง","voices.builtIn": "เสียงพูดในตัว",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "คลิกเสียงพูดเพื่อเขียนด้วยเสียงนั้นใน แปลงข้อความเป็นเสียง",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "ดาวน์โหลดโมเดลเสียงพูดใน การตั้งค่า › เสียงพูด เพื่อฟังเสียงพูดในตัว","voices.noneSavedYet": "ยังไม่มีเสียงพูดของคุณเอง ในแปลงข้อความเป็นเสียง เปิดใช้เสียงจากตัวอย่าง เลือกการบันทึก แล้วบันทึกพร้อมตั้งชื่อ เสียงนั้นจะอยู่บนอุปกรณ์นี้",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "นำเสียงพูด {0} ออกแล้ว","voices.saved": "บันทึกเสียงพูด {0} แล้ว เสียงนี้อยู่ในรายการเสียงพูดของทุกโปรเจกต์","voices.styleChipmunk": "ชิปมังก์",diff --git a/src/crates/concat/locales/tr.json b/src/crates/concat/locales/tr.jsonindex 3a41e678..9d1048d0 100644--- a/src/crates/concat/locales/tr.json+++ b/src/crates/concat/locales/tr.json@@ -905,9 +905,17 @@"voiceover.title": "Seslendirme","voiceover.tryAgain": "Yeniden dene","voices.builtIn": "Yerleşik sesler",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Metinden konuşmada bir sesle yazmak için o sese tıklayın.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Yerleşik sesleri duymak için Ayarlar › Konuşma’dan bir ses modeli indirin.","voices.noneSavedYet": "Henüz kendi sesiniz yok. Metinden konuşmada Örnek sesi kullan’ı açın, bir kayıt seçin ve bir adla kaydedin. Bu cihazda kalır.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "{0} sesi kaldırıldı","voices.saved": "{0} sesi kaydedildi. Her projenin ses listesinde yer alıyor.","voices.styleChipmunk": "Sincap",diff --git a/src/crates/concat/locales/uk.json b/src/crates/concat/locales/uk.jsonindex 5d0e45c1..804dfbca 100644--- a/src/crates/concat/locales/uk.json+++ b/src/crates/concat/locales/uk.json@@ -905,9 +905,17 @@"voiceover.title": "Озвучення","voiceover.tryAgain": "Спробувати ще раз","voices.builtIn": "Вбудовані голоси",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Натисніть на голос, щоб писати ним в «Озвученні тексту».",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Завантажте голосову модель у «Налаштування › Мовлення», щоб почути вбудовані голоси.","voices.noneSavedYet": "Власних голосів поки немає. В «Озвученні тексту» увімкніть «Голос зі зразка», виберіть запис і збережіть його з назвою. Голос залишиться на цьому пристрої.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Голос «{0}» вилучено","voices.saved": "Голос «{0}» збережено. Він є у списку голосів кожного проєкту.","voices.styleChipmunk": "Бурундук",diff --git a/src/crates/concat/locales/ur.json b/src/crates/concat/locales/ur.jsonindex 8dc3f840..b2127f38 100644--- a/src/crates/concat/locales/ur.json+++ b/src/crates/concat/locales/ur.json@@ -905,9 +905,17 @@"voiceover.title": "وائس اوور","voiceover.tryAgain": "دوبارہ کوشش کریں","voices.builtIn": "بلٹ اِن صوتیں",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "متن سے آواز میں کسی صوت سے لکھنے کے لیے اس پر کلک کریں۔",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "بلٹ اِن صوتیں سننے کے لیے ترتیبات › تقریر سے کوئی وائس ماڈل ڈاؤن لوڈ کریں۔","voices.noneSavedYet": "ابھی آپ کی اپنی کوئی صوت نہیں۔ متن سے آواز میں نمونے کی آواز استعمال کریں آن کریں، کوئی ریکارڈنگ چنیں اور نام کے ساتھ محفوظ کریں۔ یہ اسی ڈیوائس پر رہتی ہے۔",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "صوت {0} ہٹا دی گئی","voices.saved": "صوت {0} محفوظ ہو گئی۔ یہ ہر پروجیکٹ کی صوتوں کی فہرست میں ہے۔","voices.styleChipmunk": "گلہری",diff --git a/src/crates/concat/locales/vi.json b/src/crates/concat/locales/vi.jsonindex 8bbc6c2f..e58848a7 100644--- a/src/crates/concat/locales/vi.json+++ b/src/crates/concat/locales/vi.json@@ -905,9 +905,17 @@"voiceover.title": "Lời thuyết minh","voiceover.tryAgain": "Thử lại","voices.builtIn": "Giọng có sẵn",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "Nhấp vào một giọng để viết bằng giọng đó trong Chuyển văn bản thành giọng nói.",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "Tải một mô hình giọng nói trong Cài đặt › Giọng nói để nghe các giọng có sẵn.","voices.noneSavedYet": "Bạn chưa có giọng riêng nào. Trong Chuyển văn bản thành giọng nói, bật Dùng giọng mẫu, chọn một bản ghi và lưu với một cái tên. Giọng đó ở lại trên thiết bị này.",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "Đã xóa giọng {0}","voices.saved": "Đã lưu giọng {0}. Giọng này có trong danh sách giọng của mọi dự án.","voices.styleChipmunk": "Sóc chuột",diff --git a/src/crates/concat/locales/zh-Hans.json b/src/crates/concat/locales/zh-Hans.jsonindex e47f5675..86f9e76e 100644--- a/src/crates/concat/locales/zh-Hans.json+++ b/src/crates/concat/locales/zh-Hans.json@@ -905,9 +905,17 @@"voiceover.title": "旁白","voiceover.tryAgain": "重试","voices.builtIn": "内置嗓音",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "点击一个嗓音,即可在文字转语音中用它来写。",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "在“设置 › 语音”中下载一个语音模型,即可听到内置嗓音。","voices.noneSavedYet": "还没有你自己的嗓音。在文字转语音中打开“使用样本嗓音”,选一段录音并命名保存。它只保存在这台设备上。",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "已移除嗓音 {0}","voices.saved": "已保存嗓音 {0}。它会出现在每个项目的嗓音列表中。","voices.styleChipmunk": "花栗鼠",diff --git a/src/crates/concat/locales/zh-TW.json b/src/crates/concat/locales/zh-TW.jsonindex 393c8138..5c5c056f 100644--- a/src/crates/concat/locales/zh-TW.json+++ b/src/crates/concat/locales/zh-TW.json@@ -905,9 +905,17 @@"voiceover.title": "旁白","voiceover.tryAgain": "重試","voices.builtIn": "內建嗓音",+ "voices.description": "Description",+ "voices.descriptionPlaceholder": "Optional · a line about this voice","voices.hint": "點選一個嗓音,即可在文字轉語音中用它來寫。",+ "voices.importVoice": "Import voice",+ "voices.keptHint": "The 12 seconds from here are kept as the voice, on this device. Nothing is uploaded.",+ "voices.listening": "Listening for where the voice is…",+ "voices.newVoice": "New voice","voices.noModel": "在「設定 › 語音」中下載一個語音模型,即可聽到內建嗓音。","voices.noneSavedYet": "還沒有你自己的嗓音。在文字轉語音中開啟「使用樣本嗓音」,選一段錄音並命名儲存。它只保存在這台裝置上。",+ "voices.picture": "Picture",+ "voices.recordings": "Recordings","voices.removed": "已移除嗓音 {0}","voices.saved": "已儲存嗓音 {0}。它會出現在每個專案的嗓音列表中。","voices.styleChipmunk": "花栗鼠",diff --git a/src/crates/concat/src/lib.rs b/src/crates/concat/src/lib.rsindex 08713082..ca8711da 100644--- a/src/crates/concat/src/lib.rs+++ b/src/crates/concat/src/lib.rs@@ -1484,7 +1484,57 @@ fn start(project: Option<std::path::PathBuf>, smoke: bool) -> Result<(), slint::sounds.on_voice_remove(on_window!(|state, id: SharedString| {state.forget_voice(id.as_str());}));+ // Import voice: a recording from the system's picker, sound or+ // video, and the New voice sheet on the first one picked.+ sounds.on_voice_import(|| {+ host::pick_files_then(+ i18n::t("voices.importVoice"),+ Some((+ i18n::t("voices.recordings"),+ &concat_host::voices::RECORDING_EXTENSIONS,+ )),+ |studio, _, _, paths| {+ if let Some(path) = paths.into_iter().next() {+ studio.handle(Msg::Speech(SpeechMsg::ImportVoice(path)));+ }+ },+ );+ });}+ // The New voice sheet: the recording's name, a line about it, where+ // in it the voice is kept from, a picture through the same picker as+ // Text to speech's, and the save.+ app.on_new_voice_closed(on_window!(|state| {+ state.handle(Msg::Speech(SpeechMsg::NewVoiceClose));+ }));+ app.on_new_voice_name_edited(on_window!(|state, name: SharedString| {+ state.handle(Msg::Speech(SpeechMsg::NewVoiceNameEdited(name.to_string())));+ }));+ app.on_new_voice_description_edited(on_window!(|state, text: SharedString| {+ state.handle(Msg::Speech(SpeechMsg::NewVoiceDescriptionEdited(+ text.to_string(),+ )));+ }));+ app.on_new_voice_start_changed(on_window!(|state, seconds: f32| {+ state.handle(Msg::Speech(SpeechMsg::NewVoiceStartChanged(seconds)));+ }));+ app.on_new_voice_pick_picture(|| {+ host::pick_files_then(+ i18n::t("speech.picture"),+ Some((+ i18n::t("speech.picture"),+ &concat_host::voices::PICTURE_EXTENSIONS,+ )),+ |studio, _, _, paths| {+ if let Some(path) = paths.into_iter().next() {+ studio.handle(Msg::Speech(SpeechMsg::NewVoicePicturePicked(path)));+ }+ },+ );+ });+ app.on_new_voice_save(on_window!(|state| {+ state.handle(Msg::Speech(SpeechMsg::NewVoiceSave));+ }));// Text to speech keeps the sample it reads in as a voice of the// user's own, with a name and a picture.app.on_speech_save_name_edited(on_window!(|state, name: SharedString| {diff --git a/src/crates/concat/src/panes/speech.rs b/src/crates/concat/src/panes/speech.rsindex bc0c4c9e..3d2ffdd1 100644--- a/src/crates/concat/src/panes/speech.rs+++ b/src/crates/concat/src/panes/speech.rs@@ -24,7 +24,7 @@ use std::path::PathBuf;use std::sync::Arc;use concat_host::media::{self, MediaSummary};-use concat_host::voices::{self, SavedVoice};+use concat_host::voices::{self, Heard, SavedVoice};use concat_project::Command;use concat_project::commands::ClipPatch;use concat_project::model::{AppliedFilter, ClipKind, MediaItem, MediaOrigin};@@ -42,7 +42,7 @@ use crate::panes::captions::CHARS_PER_SECOND;use crate::panes::pace::{Pace, Stage, Timings};use crate::panes::settings::installed;use crate::studio::Studio;-use crate::ui::SpeechSheetData;+use crate::ui::{NewVoiceData, SpeechSheetData};/// The default Kokoro speaker: `af_heart`.const DEFAULT_VOICE: i32 = 3;@@ -136,6 +136,24 @@ pub enum SpeechMsg {VoiceSaved(Box<Result<SavedVoice, String>>),/// A saved voice deleted, by its id.ForgetVoice(String),+ /// A recording picked by the Voices shelf's Import voice: the New+ /// voice sheet on it.+ ImportVoice(PathBuf),+ /// The listen's worker is done: what it heard in that recording.+ VoiceHeard(PathBuf, Box<Result<Heard, String>>),+ /// The New voice sheet's name, its description, and the seconds into+ /// the recording its sample starts at.+ NewVoiceNameEdited(String),+ NewVoiceDescriptionEdited(String),+ NewVoiceStartChanged(f32),+ /// A picture for the new voice, from the system's picker.+ NewVoicePicturePicked(PathBuf),+ /// Keep the new voice.+ NewVoiceSave,+ /// That save's worker is done.+ NewVoiceSaved(Box<Result<SavedVoice, String>>),+ /// The New voice sheet put away without a save.+ NewVoiceClose,/// The style taken off: the speech lands plain.ClearStyle,Close,@@ -164,6 +182,31 @@ pub enum SpeechMsg {Finished(Box<Result<MediaSummary, String>>),}+/// The Voices shelf's New voice sheet: a recording from the system's+/// files, to be kept as a voice under a name, with a picture and a line+/// about it when given them (#518). It opens on the file's name and, once+/// the recording has been listened to, on the stretch of it most given to+/// speech; see `voices::listen`.+#[derive(Default)]+pub struct NewVoice {+ pub open: bool,+ /// The recording picked.+ source: PathBuf,+ name: String,+ description: String,+ picture: Option<PathBuf>,+ /// The recording's length, once it has been listened to; zero before.+ duration: f64,+ /// Seconds into the recording the kept sample starts at, and where+ /// listening to it put the start.+ start: f64,+ found: f64,+ /// The recording being listened to: the start is not known yet.+ listening: bool,+ /// A save running.+ saving: bool,+}+/// The speech sheet's state.#[derive(Default)]pub struct SpeechPane {@@ -220,6 +263,9 @@ pub struct SpeechPane {pub save_picture: Option<PathBuf>,/// A save running.pub saving: bool,+ /// The Voices shelf's New voice sheet, which keeps a voice of its own+ /// beside this sheet's.+ pub new_voice: NewVoice,/// Each saved voice's picture, read once, by its id: the rows are/// published on every frame of playback.pictures: std::cell::RefCell<std::collections::HashMap<String, slint::Image>>,@@ -263,6 +309,7 @@ impl SpeechPane {speakers: std::mem::take(&mut self.speakers),timings: std::mem::take(&mut self.timings),saved: std::mem::take(&mut self.saved),+ new_voice: std::mem::take(&mut self.new_voice),pictures: std::mem::take(&mut self.pictures),..SpeechPane::default()};@@ -315,6 +362,68 @@ impl SpeechPane {Err(error) => studio.notify(&error, true),}}+ SpeechMsg::ImportVoice(source) => self.import_voice(source),+ SpeechMsg::VoiceHeard(source, heard) => {+ // An answer about a recording the sheet has since let go+ // of is not the sheet's.+ let sheet = &mut self.new_voice;+ if !sheet.open || sheet.source != source {+ return;+ }+ sheet.listening = false;+ match *heard {+ Ok(heard) => {+ sheet.duration = heard.duration;+ sheet.start = heard.start;+ sheet.found = heard.start;+ }+ // Nothing to keep a voice from: the sheet goes, and+ // the notice says why.+ Err(error) => {+ self.new_voice = NewVoice::default();+ studio.notify(&error, true);+ }+ }+ }+ SpeechMsg::NewVoiceNameEdited(name) => self.new_voice.name = name,+ SpeechMsg::NewVoiceDescriptionEdited(text) => self.new_voice.description = text,+ SpeechMsg::NewVoiceStartChanged(seconds) => {+ let sheet = &mut self.new_voice;+ // Held short of the end, as the speech sheet's start is,+ // so there is always a second of sound left to keep.+ sheet.start = if seconds.is_finite() {+ f64::from(seconds).clamp(0.0, (sheet.duration - 1.0).max(0.0))+ } else {+ sheet.found+ }+ }+ SpeechMsg::NewVoicePicturePicked(path) => self.new_voice.picture = Some(path),+ SpeechMsg::NewVoiceSave => self.save_new_voice(studio),+ SpeechMsg::NewVoiceSaved(result) => {+ self.new_voice.saving = false;+ match *result {+ Ok(voice) => {+ self.new_voice = NewVoice::default();+ // The new voice lands at the head of the list, so+ // the one this sheet reads in is found again by+ // its id rather than kept by its row.+ let chosen = self+ .saved_voice+ .and_then(|row| self.saved.get(row))+ .map(|held| held.id.clone());+ self.reload_saved(studio);+ self.saved_voice =+ chosen.and_then(|id| self.saved.iter().position(|held| held.id == id));+ studio.notify(&tf("voices.saved", &[&voice.name]), false);+ }+ Err(error) => studio.notify(&error, true),+ }+ }+ SpeechMsg::NewVoiceClose => {+ if !self.new_voice.saving {+ self.new_voice = NewVoice::default();+ }+ }SpeechMsg::ClearStyle => self.style = None,SpeechMsg::Close => self.open = false,SpeechMsg::TextEdited(text) => self.text = text,@@ -1027,6 +1136,94 @@ impl SpeechPane {},);}++ /// The New voice sheet on a recording just picked: named for its file,+ /// and listened to on a worker for where its voice is, the start held+ /// until that is known. A save under way keeps the sheet it is saving.+ fn import_voice(&mut self, source: PathBuf) {+ if self.new_voice.saving {+ return;+ }+ let name = source+ .file_stem()+ .map(|stem| stem.to_string_lossy().into_owned())+ .unwrap_or_default();+ self.new_voice = NewVoice {+ open: true,+ source: source.clone(),+ name,+ listening: true,+ ..NewVoice::default()+ };+ crate::host::spawn(+ move || {+ let heard = voices::listen(&source);+ (source, heard)+ },+ |studio, _, _, (source, heard)| {+ studio.handle(Msg::Speech(SpeechMsg::VoiceHeard(source, Box::new(heard))));+ },+ );+ }++ /// Keeps the New voice sheet's recording as a voice, on a worker: the+ /// few seconds from where the sheet's start is, under its name, with+ /// its picture and its description.+ fn save_new_voice(&mut self, studio: &Studio) {+ let sheet = &mut self.new_voice;+ let name = sheet.name.trim().to_owned();+ if name.is_empty() || sheet.listening || sheet.saving {+ return;+ }+ let dir = voices::dir_in(&studio.host.dirs);+ let source = sheet.source.clone();+ let start = sheet.start;+ let picture = sheet.picture.clone();+ let description = sheet.description.clone();+ sheet.saving = true;+ crate::host::spawn(+ move || {+ voices::save(+ &dir,+ &name,+ &source,+ start,+ picture.as_deref(),+ Some(&description),+ )+ },+ |studio, _, _, result| {+ studio.handle(Msg::Speech(SpeechMsg::NewVoiceSaved(Box::new(result))));+ },+ );+ }++ /// The New voice sheet as Slint shows it.+ pub fn new_voice_data(&self) -> NewVoiceData {+ let sheet = &self.new_voice;+ let file_name = |path: &std::path::Path| {+ path.file_name()+ .map(|name| name.to_string_lossy().into_owned())+ .unwrap_or_default()+ };+ NewVoiceData {+ open: sheet.open,+ source: file_name(&sheet.source).into(),+ name: sheet.name.as_str().into(),+ description: sheet.description.as_str().into(),+ picture: sheet+ .picture+ .as_deref()+ .map(file_name)+ .unwrap_or_default()+ .into(),+ duration: sheet.duration as f32,+ start: sheet.start as f32,+ found: sheet.found as f32,+ listening: sheet.listening,+ saving: sheet.saving,+ }+ }}impl SpeechPane {diff --git a/src/crates/concat/src/studio.rs b/src/crates/concat/src/studio.rsindex ed7c631a..e714b7a7 100644--- a/src/crates/concat/src/studio.rs+++ b/src/crates/concat/src/studio.rs@@ -9346,15 +9346,16 @@ impl Studio {}/// Whether a sheet covers the editor - Export, Settings, the project- /// sheet, a relink or a question - so the editor's keys are not its- /// own. The tool cards are not sheets: the timeline is worked beside- /// them.+ /// sheet, a relink, a question or the Voices shelf's New voice - so+ /// the editor's keys are not its own. The tool cards are not sheets:+ /// the timeline is worked beside them.pub fn sheet_open(&self) -> bool {self.export.open|| self.settings.open|| self.project_sheet.open|| self.relink.open|| self.confirm.is_some()+ || self.speech.new_voice.open}// ── notices ──@@ -11685,6 +11686,7 @@ impl Studio {self.speech.sample_detail_rows(self),);app.set_speech(self.speech.data(self));+ app.set_new_voice(self.speech.new_voice_data());// The Audio page.sync(&models.sounds_mine, self.sounds.mine());sync(&models.sounds_concat, self.sounds.concat_rows());diff --git a/src/crates/concat/ui/app.slint b/src/crates/concat/ui/app.slintindex 56af8268..ccf82ed7 100644--- a/src/crates/concat/ui/app.slint+++ b/src/crates/concat/ui/app.slint@@ -52,6 +52,7 @@ import {import { ConfirmData, ConfirmDialog } from "dialogs/confirm.slint";import { CaptionsDialog, CaptionsSheetData } from "dialogs/captions.slint";import { SpeechDialog, SpeechSheetData } from "dialogs/speech.slint";+import { NewVoiceData, NewVoiceDialog } from "dialogs/new-voice.slint";import { AvatarData } from "primitives/avatar.slint";import { VoiceoverData, VoiceoverPanel } from "dialogs/voiceover.slint";import { DockDivider, DockSide, SeatBox } from "dock.slint";@@ -177,6 +178,7 @@ export {SoundCardData,Sounds,VoiceCardData,+ NewVoiceData,}export component App inherits Window {title: "Concat";@@ -230,7 +232,7 @@ export component App inherits Window {}property <bool> sheet-open: root.export.open || root.settings.open|| root.project-sheet.open || root.captions.open || root.speech.open- || root.start.composing;+ || root.start.composing || root.new-voice.open;changed sheet-open => {if (!root.sheet-open) {keys.focus();@@ -465,6 +467,16 @@ export component App inherits Window {callback speech-save-voice();callback speech-clear-style();+ /// The Voices shelf's New voice sheet: a recording picked to be kept+ /// as a voice; see NewVoiceDialog.+ in property <NewVoiceData> new-voice;+ callback new-voice-closed();+ callback new-voice-name-edited(name: string);+ callback new-voice-description-edited(text: string);+ callback new-voice-start-changed(seconds: float);+ callback new-voice-pick-picture();+ callback new-voice-save();+/// The voiceover panel; see VoiceoverPanel. Its meter and clock come/// on the Editor global, from a timer.in property <VoiceoverData> voiceover;@@ -625,6 +637,10 @@ export component App inherits Window {if (event.text == Key.Escape || event.text == Key.Back) {if (root.confirm.open) { root.confirm-dismissed(); return accept; }if (root.relink.open) { root.relink-dismiss(); return accept; }+ if (root.new-voice.open) {+ if (!root.new-voice.saving) { root.new-voice-closed(); }+ return accept;+ }if (root.project-sheet.open) { root.project-closed(); return accept; }if (root.settings.open) { root.settings-closed(); return accept; }if (root.export.open) {@@ -1047,6 +1063,28 @@ export component App inherits Window {apply => { root.project-apply(); }}+ // Over the Audio page it was opened from, and over the tool cards,+ // which may be open beside the page on a desk.+ NewVoiceDialog {+ fill: root.sheets-fill;+ inset-top: root.safe-area-insets.top;+ inset-bottom: root.safe-area-insets.bottom;+ inset-left: root.safe-area-insets.left;+ inset-right: root.safe-area-insets.right;+ x: 0;+ y: 0;+ width: root.width;+ height: root.height;+ data: root.new-voice;++ closed => { root.new-voice-closed(); }+ name-edited(name) => { root.new-voice-name-edited(name); }+ description-edited(text) => { root.new-voice-description-edited(text); }+ start-changed(seconds) => { root.new-voice-start-changed(seconds); }+ pick-picture => { root.new-voice-pick-picture(); }+ save => { root.new-voice-save(); }+ }+RelinkDialog {fill: root.sheets-fill;inset-top: root.safe-area-insets.top;diff --git a/src/crates/concat/ui/dialogs/new-voice.slint b/src/crates/concat/ui/dialogs/new-voice.slintnew file mode 100644index 00000000..9e627c0e--- /dev/null+++ b/src/crates/concat/ui/dialogs/new-voice.slint@@ -0,0 +1,173 @@+// SPDX-License-Identifier: AGPL-3.0-or-later+// SPDX-FileCopyrightText: 2026 Jareer Abdullah and Concat contributors++import { I18n } from "../i18n.slint";+import { Theme } from "../theme/theme.slint";+import { Glyph } from "../icons.slint";+import { Button, DialogRow, DialogSection, Field, Modal } from "../primitives/modal.slint";+import { Rail } from "../inspector/controls.slint";+import { Fmt } from "../util.slint";++// New voice: what the Voices shelf's Import voice opens on the recording+// picked (#518).+//+// A recording from anywhere - a voice memo, an interview, a video's+// soundtrack - kept as a voice of the user's own, the way Text to speech+// keeps the sample it reads in: the few seconds a model listens to, under+// a name, with a picture and a line about it when they are given. The+// name starts as the file's. Where the seconds come from starts where+// Rust heard the most speech in the recording, since one that opens on+// silence or a jingle would otherwise be kept as that; the rail moves it,+// and a double-click puts it back. On a phone it is a sheet.++export struct NewVoiceData {+ open: bool,+ /// The recording's file name.+ source: string,+ name: string,+ /// The line under the voice's name on the shelf, or empty.+ description: string,+ /// The picture's file name, or empty for none.+ picture: string,+ /// The recording's length in seconds, once it has been listened to.+ duration: float,+ /// Seconds in where the kept sample starts, and where listening to+ /// the recording put it.+ start: float,+ found: float,+ /// The recording is being listened to for where its voice is.+ listening: bool,+ /// The save running.+ saving: bool,+}++export component NewVoiceDialog inherits Modal {+ in property <NewVoiceData> data;++ callback name-edited(name: string);+ callback description-edited(text: string);+ callback start-changed(seconds: float);+ callback pick-picture();+ callback save();++ open: root.data.open;+ title: I18n.t("voices.newVoice");+ glyph: Glyph.mic;+ surface-width: 460px;+ dismissable: !root.data.saving;++ // The rail's own copy, seeded the way the speech sheet's are: a Rail+ // writes to the property it is bound to, which drops the binding, so+ // it is reseeded from the data whenever that changes.+ property <float> start-v;+ changed data => { root.start-v = root.data.start; }+ init => { root.start-v = root.data.start; }++ VerticalLayout {+ DialogSection {+ first: true;+ title: I18n.t("speech.voice");++ DialogRow {+ label: I18n.t("common.name");+ Field {+ value: root.data.name;+ placeholder: I18n.t("speech.voiceName");+ edited(text) => { root.name-edited(text); }+ }+ }++ // One line under the name on the shelf, so it is capped where+ // `voices::DESCRIPTION_CHARS` caps it.+ DialogRow {+ label: I18n.t("voices.description");+ Field {+ value: root.data.description;+ placeholder: I18n.t("voices.descriptionPlaceholder");+ max-length: 140;+ edited(text) => { root.description-edited(text); }+ }+ }++ // Without one the voice wears its initial in its colour, as+ // the built-in voices do.+ DialogRow {+ label: I18n.t("voices.picture");+ Button {+ label: root.data.picture != "" ? root.data.picture : I18n.t("speech.picture");+ glyph: Glyph.image;+ ghost: true;+ clicked => { root.pick-picture(); }+ }+ }+ }++ // Where in the recording the kept seconds come from: held while+ // the recording is being listened to, then at what was heard.+ DialogSection {+ title: I18n.t("speech.sample");++ Text {+ text: root.data.source;+ color: Theme.fg-dim;+ font-family: Theme.font-technical;+ font-size: Theme.fs-sm;+ overflow: elide;+ }++ DialogRow {+ label: I18n.t("speech.voiceFrom");+ Rail {+ value <=> root.start-v;+ minimum: 0;+ maximum: Math.max(0, root.data.duration - 1);+ step: 0.5;+ default-value: root.data.found;+ enabled: !root.data.listening;+ changed(v) => { root.start-changed(v); }+ }+ Text {+ width: 52px;+ text: I18n.t1("speech.sIn", "\{Fmt.round-to(root.start-v, 1)}");+ color: Theme.fg-muted;+ font-family: Theme.font-technical;+ font-size: Theme.fs-sm;+ vertical-alignment: center;+ horizontal-alignment: right;+ }+ }++ Text {+ text: root.data.listening ? I18n.t("voices.listening") : I18n.t("voices.keptHint");+ color: Theme.fg-dim;+ font-size: Theme.fs-sm;+ wrap: word-wrap;+ }+ }++ Rectangle {+ height: 1px;+ background: Theme.line;+ }++ HorizontalLayout {+ padding: 14px;+ spacing: 8px;+ alignment: end;++ Button {+ label: I18n.t("common.cancel");+ enabled: !root.data.saving;+ clicked => { root.closed(); }+ }++ Button {+ primary: true;+ glyph: Glyph.check;+ label: I18n.t("speech.save");+ enabled: root.data.name != "" && !root.data.listening && !root.data.saving;+ clicked => { root.save(); }+ }+ }+ }+}diff --git a/src/crates/concat/ui/phone/editor.slint b/src/crates/concat/ui/phone/editor.slintindex d4a91a88..9e3c1fcf 100644--- a/src/crates/concat/ui/phone/editor.slint+++ b/src/crates/concat/ui/phone/editor.slint@@ -1178,6 +1178,20 @@ export component PhoneEditor inherits Rectangle {styles: root.audio-shelf == 2;touch-sized: true;opened => { root.hide(); }++ // A recording from the phone's files kept as a voice. The+ // sheet stays up under the New voice sheet, so the voice+ // is there to see once it is saved.+ if root.audio-shelf == 1: VerticalLayout {+ padding-top: 6px;+ padding-bottom: 8px;+ SheetButton {+ glyph: Glyph.import;+ primary: true;+ label: I18n.t("voices.importVoice");+ clicked => { Sounds.voice-import(); }+ }+ }}if root.audio-shelf == 0: SheetButton {diff --git a/src/crates/concat/ui/primitives/modal.slint b/src/crates/concat/ui/primitives/modal.slintindex 562cc2cf..4eb17bf6 100644--- a/src/crates/concat/ui/primitives/modal.slint+++ b/src/crates/concat/ui/primitives/modal.slint@@ -695,6 +695,10 @@ export component Field inherits Rectangle {/// one control with a square seam between them.in property <length> radius-left: Theme.r;in property <length> radius-right: Theme.r;+ /// The most characters it takes, or zero for no limit. A keystroke or+ /// a paste that would run past it is refused whole, and what was there+ /// stays: the expression language has no way to cut a string to fit.+ in property <int> max-length;callback edited(text: string);@@ -726,8 +730,12 @@ export component Field inherits Rectangle {// goes deaf to the model. This is seeded instead, and never while the// field has focus, so a republish mid-sentence cannot yank the caret.property <string> draft;+ /// The draft as it last stood within `max-length`: what a keystroke+ /// past it is undone to.+ property <string> kept;function seed() {root.draft = root.value;+ root.kept = root.value;}init => { root.seed(); }changed value => {@@ -781,7 +789,14 @@ export component Field inherits Rectangle {}}- edited => { root.edited(self.text); }+ edited => {+ if (root.max-length > 0 && self.text.character-count > root.max-length) {+ root.draft = root.kept;+ } else {+ root.kept = self.text;+ root.edited(self.text);+ }+ }}}diff --git a/src/crates/concat/ui/workspace/audio-page.slint b/src/crates/concat/ui/workspace/audio-page.slintindex 4dbe4cca..fbf88ccc 100644--- a/src/crates/concat/ui/workspace/audio-page.slint+++ b/src/crates/concat/ui/workspace/audio-page.slint@@ -63,6 +63,9 @@ export global Sounds {callback voice-open(id: string);/// A saved voice deleted.callback voice-remove(id: string);+ /// The Import voice button: the system's picker, for a recording to+ /// keep as a voice, and then the New voice sheet on it.+ callback voice-import();/// The Mine shelf: the user's own sounds, newest first.in property <[SoundCardData]> mine;@@ -356,6 +359,12 @@ component ShelfHeading inherits Text {// The Voices shelf: the user's own voices, then the built-in ones, or the// styles. Opening one is a click; on a phone the sheet goes down with it.+//+// The children go at the head of the user's own, under its heading: the+// Import voice button, which is each shell's own - the desk's dashed drop+// zone, the phone's button the width of its sheet - as Import sounds is.+// `@children` cannot sit inside a conditional, so a caller shows its+// button only while the shelf is the voices.export component VoiceList inherits VerticalLayout {/// The Styles shelf rather than the voices.in property <bool> styles;@@ -365,6 +374,7 @@ export component VoiceList inherits VerticalLayout {spacing: 2px;if !root.styles: ShelfHeading { text: I18n.t("voices.yours"); }+ @childrenif !root.styles && Sounds.voices-saved.length == 0: Text {text: I18n.t("voices.noneSavedYet");color: Theme.fg-dim;diff --git a/src/crates/concat/ui/workspace/media-pane.slint b/src/crates/concat/ui/workspace/media-pane.slintindex c684bdb4..ef62cee2 100644--- a/src/crates/concat/ui/workspace/media-pane.slint+++ b/src/crates/concat/ui/workspace/media-pane.slint@@ -2581,6 +2581,17 @@ export component MediaPane inherits Rectangle {}VoiceList {styles: root.audio-category == 11;++ // A recording of the user's own kept as a voice,+ // brought in as Mine brings in a sound.+ if root.audio-category == 10: VerticalLayout {+ padding-top: 4px;+ padding-bottom: 6px;+ ImportButton {+ label: I18n.t("voices.importVoice");+ clicked => { Sounds.voice-import(); }+ }+ }}}