diff --git a/data/locale/ar.ts b/data/locale/ar.ts index b52a6d8dcdc..9906aea9548 100644 --- a/data/locale/ar.ts +++ b/data/locale/ar.ts @@ -397,7 +397,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! من فضلك افتح نمط أتمتة من قائمة أداة ضبط. @@ -405,12 +405,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -501,7 +501,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip محرر الأتمتة - لا نمط @@ -512,68 +512,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor افتح في محرر الأتمتة - + Clear واضح - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -619,7 +619,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9567,44 +9567,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps أضف خطوات - + Remove steps أزل خطوات - + Clone Steps استنسخ الخطوات @@ -9865,7 +9865,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9879,7 +9879,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9899,7 +9899,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9949,13 +9949,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10072,48 +10072,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12022,69 +12022,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample اعكس العينة - + Set clip color - + Use track color @@ -13320,103 +13320,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/bs.ts b/data/locale/bs.ts index 1f449567b76..f8f54c72298 100644 --- a/data/locale/bs.ts +++ b/data/locale/bs.ts @@ -410,7 +410,7 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditor - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -428,7 +428,7 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -438,7 +438,7 @@ If you're interested in translating LMMS in another language or want to imp - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -588,7 +588,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -598,73 +598,73 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + double-click to open this pattern in automation editor - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -740,7 +740,7 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView Open in Beat+Bassline-Editor @@ -6571,44 +6571,44 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator - PatternView + MidiClipView - + use mouse wheel to set velocity of a step - + double-click to open in Piano Roll - + Open in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps @@ -6834,7 +6834,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -6848,7 +6848,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -6863,7 +6863,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -7008,7 +7008,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator - Piano-Roll - no pattern + Piano-Roll - no clip @@ -7385,7 +7385,7 @@ Reason: "%2" - SampleTCOView + SampleClipView double-click to select sample @@ -8335,7 +8335,7 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip Mute @@ -8343,7 +8343,7 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObjectView + ClipView Current position diff --git a/data/locale/ca.ts b/data/locale/ca.ts index 92c5d0521c2..be8c6b16b44 100644 --- a/data/locale/ca.ts +++ b/data/locale/ca.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name Restaura nom - + Change name Canvia nom - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name Restaura nom - + Change name Canvia nom @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll Obre al rotlle de piano - + Set as ghost in piano-roll - + Clear all notes Esborra totes les notes - + Reset name Restaura nom - + Change name Canvia nom - + Add steps Afegeix passos - + Remove steps Elimina passos - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Per favor, obre un patró picant-lo dos cops! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Rotlle de Piano - sense patró - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Inverteix mostra - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute Silenci - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/cs.ts b/data/locale/cs.ts index fe526a1c6b4..5105efbb1c2 100644 --- a/data/locale/cs.ts +++ b/data/locale/cs.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Otevřete prosím automatizační záznam pomocí kontextové nabídky ovládání! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Přehrát/Pozastavit přehrávání aktuálního záznamu (mezerník) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Zastavit přehrávání aktuálního záznamu (mezerník) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip Editor automatizace – žádný záznam @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. Model je již k tomuto záznamu připojen. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Ovládací prvek táhni při stisknutém <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Otevřít v Editoru automatizace - + Clear Vyčistit - + Reset name Obnovit výchozí jméno - + Change name Změnit jméno - + Set/clear record Zapnout/Vypnout záznam - + Flip Vertically (Visible) Převrátit vertikálně (viditelné) - + Flip Horizontally (Visible) Převrátit horizontálně (viditelné) - + %1 Connections %1 Připojení - + Disconnect "%1" Odpojit "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Model je již k tomuto záznamu připojen. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Otevřít v editoru bicích/basů - + Reset name Resetovat jméno - + Change name Změnit jméno @@ -9570,44 +9570,44 @@ Navštivte prosím stránku s dokumentací k LMMS na adrese http://lmms.sf.net/w - PatternView + MidiClipView - + Open in piano-roll Otevřít v Piano rollu - + Set as ghost in piano-roll - + Clear all notes Vymazat všechny noty - + Reset name Resetovat jméno - + Change name Změnit jméno - + Add steps Přidat kroky - + Remove steps Odstranit kroky - + Clone Steps Klonovat kroky @@ -9868,7 +9868,7 @@ Navštivte prosím stránku s dokumentací k LMMS na adrese http://lmms.sf.net/w - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Otevřete prosím záznam poklepáním! @@ -9882,7 +9882,7 @@ Navštivte prosím stránku s dokumentací k LMMS na adrese http://lmms.sf.net/w PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Přehrát/Pozastavit přehrávání aktuálního záznamu (mezerník) @@ -9902,7 +9902,7 @@ Navštivte prosím stránku s dokumentací k LMMS na adrese http://lmms.sf.net/w - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Zastavit přehrávání aktuálního záznamu (mezerník) @@ -9952,13 +9952,13 @@ Navštivte prosím stránku s dokumentací k LMMS na adrese http://lmms.sf.net/w - Import pattern + Import clip - Export pattern + Export clip @@ -10075,48 +10075,48 @@ Navštivte prosím stránku s dokumentací k LMMS na adrese http://lmms.sf.net/w - Piano-Roll - no pattern + Piano-Roll - no clip Piano roll – žádný záznam - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12027,69 +12027,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample Poklepejte pro výběr samplu - + Delete (middle mousebutton) Smazat (prostřední tlačítko myši) - + Delete selection (middle mousebutton) - + Cut Vyjmout - + Cut selection - + Copy Kopírovat - + Copy selection - + Paste Vložit - + Mute/unmute (<%1> + middle click) Ztlumit/Odtlumit (<%1> + prostřední tlačítko) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Přehrávat pozpátku - + Set clip color - + Use track color @@ -13329,103 +13329,103 @@ Přesvědčte se prosím, že máte právo ke čtení tohoto souboru a příslu - TrackContentObject + Clip - + Mute Ztlumit - TrackContentObjectView + ClipView - + Current position Aktuální pozice - + Current length Aktuální délka - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 do %5:%6) - + Press <%1> and drag to make a copy. K vytvoření kopie stiskněte <%1> a táhněte myší. - + Press <%1> for free resizing. Stiskněte <%1> pro volnou změnu velikosti. - + Hint Rada - + Delete (middle mousebutton) Smazat (prostřední tlačítko myši) - + Delete selection (middle mousebutton) - + Cut Vyjmout - + Cut selection - + Merge Selection - + Copy Kopírovat - + Copy selection - + Paste Vložit - + Mute/unmute (<%1> + middle click) Ztlumit/Odtlumit (<%1> + prostřední tlačítko) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/de.ts b/data/locale/de.ts index 0c6883b56d4..e920beed0da 100644 --- a/data/locale/de.ts +++ b/data/locale/de.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Bitte öffnen Sie einen Automation-Pattern mit Hilfe des Kontextmenüs eines Steuerelements! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Aktuelles Pattern abspielen/pausieren (Leertaste) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Abspielen des aktuellen Patterns stoppen (Leertaste) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip Automation-Editor - Kein Pattern @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. Model ist bereits mit diesem Pattern verbunden. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Ein Steuerelement mit <Strg> hier her ziehen - AutomationPatternView + AutomationClipView - + Open in Automation editor Im Automation-Editor öffnen - + Clear Zurücksetzen - + Reset name Name zurücksetzen - + Change name Name ändern - + Set/clear record Aufnahme setzen/löschen - + Flip Vertically (Visible) Vertikal spiegeln (Sichtbar) - + Flip Horizontally (Visible) Horizontal spiegeln (Sichtbar) - + %1 Connections %1 Verbindungen - + Disconnect "%1" »%1« trennen - - Model is already connected to this pattern. + + Model is already connected to this clip. Model ist bereits mit diesem Pattern verbunden. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Im Beat+Bassline-Editor öffnen - + Reset name Name zurücksetzen - + Change name Name ändern @@ -9569,44 +9569,44 @@ Sie haben keine Standard-Soundfont im Einstellungsdialog (Bearbeiten->Einstel - PatternView + MidiClipView - + Open in piano-roll Im Piano-Roll öffnen - + Set as ghost in piano-roll - + Clear all notes Alle Noten löschen - + Reset name Name zurücksetzen - + Change name Name ändern - + Add steps Schritte hinzufügen - + Remove steps Schritte entfernen - + Clone Steps Schritte Klonen @@ -9867,7 +9867,7 @@ Sie haben keine Standard-Soundfont im Einstellungsdialog (Bearbeiten->Einstel - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Bitte öffnen Sie einen Pattern, indem Sie ihn doppelklicken! @@ -9881,7 +9881,7 @@ Sie haben keine Standard-Soundfont im Einstellungsdialog (Bearbeiten->Einstel PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Aktuelles Pattern abspielen/pausieren (Leertaste) @@ -9901,7 +9901,7 @@ Sie haben keine Standard-Soundfont im Einstellungsdialog (Bearbeiten->Einstel - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Abspielen des aktuellen Patterns stoppen (Leertaste) @@ -9951,13 +9951,13 @@ Sie haben keine Standard-Soundfont im Einstellungsdialog (Bearbeiten->Einstel - Import pattern + Import clip - Export pattern + Export clip @@ -10074,48 +10074,48 @@ Sie haben keine Standard-Soundfont im Einstellungsdialog (Bearbeiten->Einstel - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12026,69 +12026,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Löschen (mittlere Maustaste) - + Delete selection (middle mousebutton) - + Cut Ausschneiden - + Cut selection - + Copy Kopieren - + Copy selection - + Paste Einfügen - + Mute/unmute (<%1> + middle click) Stumm/Laut schalten (<Strg> + Mittelklick) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Sample umkehren - + Set clip color - + Use track color @@ -13327,103 +13327,103 @@ Bitte stellen Sie sicher, dass Sie Leserechte auf diese Datei sowie das Verzeich - TrackContentObject + Clip - + Mute Stumm - TrackContentObjectView + ClipView - + Current position Aktuelle Position - + Current length Aktuelle Länge - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. <%1> drücken und ziehen, um eine Kopie zu erstellen. - + Press <%1> for free resizing. Drücken Sie <%1> für freie Größenänderung. - + Hint Tipp - + Delete (middle mousebutton) Löschen (mittlere Maustaste) - + Delete selection (middle mousebutton) - + Cut Ausschneiden - + Cut selection - + Merge Selection - + Copy Kopieren - + Copy selection - + Paste Einfügen - + Mute/unmute (<%1> + middle click) Stumm/Laut schalten (<Strg> + Mittelklick) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/el.ts b/data/locale/el.ts index 6d26e42df3f..79724dc26c6 100644 --- a/data/locale/el.ts +++ b/data/locale/el.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name Αλλαξε όνομα - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name Αλλαξε όνομα @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name Αλλαξε όνομα - + Add steps - + Remove steps - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut Αποκοπή - + Cut selection - + Copy Αντιγραφή - + Copy selection - + Paste Επικόλληση - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute Σίγαση - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint Ιχνος - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut Αποκοπή - + Cut selection - + Merge Selection - + Copy Αντιγραφή - + Copy selection - + Paste Επικόλληση - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/en.ts b/data/locale/en.ts index 2af0216ae63..4a77d8db9ce 100644 --- a/data/locale/en.ts +++ b/data/locale/en.ts @@ -398,7 +398,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -406,12 +406,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -502,7 +502,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -513,68 +513,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -620,7 +620,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -650,19 +650,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9568,44 +9568,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9866,7 +9866,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9880,7 +9880,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9900,7 +9900,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9950,13 +9950,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10073,48 +10073,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12023,69 +12023,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13321,103 +13321,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/eo.ts b/data/locale/eo.ts index 4b1d735a277..61fcbd54be0 100644 --- a/data/locale/eo.ts +++ b/data/locale/eo.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut Eltondi - + Cut selection - + Copy Kopii - + Copy selection - + Paste Alglui - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut Eltondi - + Cut selection - + Merge Selection - + Copy Kopii - + Copy selection - + Paste Alglui - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/es.ts b/data/locale/es.ts index 530e6507eee..753c4c35cee 100644 --- a/data/locale/es.ts +++ b/data/locale/es.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! ¡Por favor abre un patrón de automatización con el menú contextual de un control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Reproducir/Pausar el patrón actual (Espacio) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Detener la reproducción del patrón actual (Espacio) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip Editor de Automatización - no hay patrón @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. El modelo ya está conectado a este patrón. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Arrastre un control mientras presiona <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Abrir en el editor de Automatización - + Clear Limpiar - + Reset name Restaurar nombre - + Change name Cambiar nombre - + Set/clear record Activar/Desactivar grabación - + Flip Vertically (Visible) Voltear verticalmente (Visible) - + Flip Horizontally (Visible) Voltear horizontalmente (Visible) - + %1 Connections %1 Conexiones - + Disconnect "%1" Desconectar "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. El modelo ya está conectado a este patrón. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Abrir en Editor de Ritmo+Bajo - + Reset name Restaurar nombre - + Change name Cambiar nombre @@ -9569,44 +9569,44 @@ Por favor visita http://lmms.sf.net/wiki para obtener documentación acerca de L - PatternView + MidiClipView - + Open in piano-roll Abrir en piano-roll - + Set as ghost in piano-roll - + Clear all notes Borrar todas las notas - + Reset name Restaurar nombre - + Change name Cambiar nombre - + Add steps Agregar pasos - + Remove steps Quitar pasos - + Clone Steps Clonar Pasos @@ -9867,7 +9867,7 @@ Por favor visita http://lmms.sf.net/wiki para obtener documentación acerca de L - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! ¡Por favor abre el patrón haciendo doble click sobre él! @@ -9881,7 +9881,7 @@ Por favor visita http://lmms.sf.net/wiki para obtener documentación acerca de L PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Reproducir/Pausar el patrón actual (Espacio) @@ -9901,7 +9901,7 @@ Por favor visita http://lmms.sf.net/wiki para obtener documentación acerca de L - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Detener la reproducción del patrón actual (Espacio) @@ -9951,13 +9951,13 @@ Por favor visita http://lmms.sf.net/wiki para obtener documentación acerca de L - Import pattern + Import clip - Export pattern + Export clip @@ -10074,48 +10074,48 @@ Por favor visita http://lmms.sf.net/wiki para obtener documentación acerca de L - Piano-Roll - no pattern + Piano-Roll - no clip Piano-Roll - sin patrón - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12026,69 +12026,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample Haga doble clic para abrir la muestra. - + Delete (middle mousebutton) Borrar (click del medio ) - + Delete selection (middle mousebutton) - + Cut Cortar - + Cut selection - + Copy Copiar - + Copy selection - + Paste Pegar - + Mute/unmute (<%1> + middle click) Silenciar/Escuchar (<%1> + click del medio) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Reproducir la muestra en reversa - + Set clip color - + Use track color @@ -13328,103 +13328,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute Silencio - TrackContentObjectView + ClipView - + Current position Posición actual - + Current length Duración actual - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 a %5:%6) - + Press <%1> and drag to make a copy. Presiona <%1> y arrastra para crear una copia. - + Press <%1> for free resizing. Presiona <%1> para redimensionar libremente. - + Hint Pista - + Delete (middle mousebutton) Borrar (click del medio ) - + Delete selection (middle mousebutton) - + Cut Cortar - + Cut selection - + Merge Selection - + Copy Copiar - + Copy selection - + Paste Pegar - + Mute/unmute (<%1> + middle click) Silenciar/Escuchar (<%1> + click del medio) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/eu.ts b/data/locale/eu.ts index 5d7333b99da..022c25322fa 100644 --- a/data/locale/eu.ts +++ b/data/locale/eu.ts @@ -397,7 +397,7 @@ LMMS beste hizkuntza batera itzultzeko interesa baduzu edo lehendik dauden itzul - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Ireki automatizazio-eredu bat kontrol baten laster-menuaren bidez! @@ -405,12 +405,12 @@ LMMS beste hizkuntza batera itzultzeko interesa baduzu edo lehendik dauden itzul AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Erreproduzitu/pausatu uneko eredua (espazioa) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Gelditu uneko ereduaren erreprodukzioa (espazioa) @@ -501,7 +501,7 @@ LMMS beste hizkuntza batera itzultzeko interesa baduzu edo lehendik dauden itzul - Automation Editor - no pattern + Automation Editor - no clip Automatizazio-editorea - patroirik ez @@ -512,68 +512,68 @@ LMMS beste hizkuntza batera itzultzeko interesa baduzu edo lehendik dauden itzul - Model is already connected to this pattern. + Model is already connected to this clip. Eredua dagoeneko konektatuta dago patroi honekin - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Arrastatu kontrol bat <%1> sakatzen ari zaren bitartean - AutomationPatternView + AutomationClipView - + Open in Automation editor Ireki automatizazio-editorean - + Clear Garbitu - + Reset name Berrezarri izena - + Change name Aldatu izena - + Set/clear record Ezarri/garbitu grabazioa - + Flip Vertically (Visible) Irauli bertikalean (ikusgai) - + Flip Horizontally (Visible) Irauli horizontalean (ikusgai) - + %1 Connections %1 konexio - + Disconnect "%1" Deskonektatu "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Eredua dagoeneko konektatuta dago patroi honekin @@ -619,7 +619,7 @@ LMMS beste hizkuntza batera itzultzeko interesa baduzu edo lehendik dauden itzul - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ LMMS beste hizkuntza batera itzultzeko interesa baduzu edo lehendik dauden itzul - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name Berrezarri izena - + Change name Aldatu izena @@ -9847,44 +9847,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name Berrezarri izena - + Change name Aldatu izena - + Add steps Gehitu urratsa - + Remove steps Kendu urratsak - + Clone Steps Klonatu urratsak @@ -10145,7 +10145,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -10159,7 +10159,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Erreproduzitu/pausatu uneko eredua (espazioa) @@ -10179,7 +10179,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Gelditu uneko ereduaren erreprodukzioa (espazioa) @@ -10229,13 +10229,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10352,48 +10352,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12302,69 +12302,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Ezabatu (saguaren erdiko botoia) - + Delete selection (middle mousebutton) - + Cut Moztu - + Cut selection - + Copy Kopiatu - + Copy selection - + Paste Itsatsi - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Alderantzikatu lagina - + Set clip color - + Use track color @@ -13600,103 +13600,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position Uneko posizioa - + Current length Uneko luzera - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) Ezabatu (saguaren erdiko botoia) - + Delete selection (middle mousebutton) - + Cut Moztu - + Cut selection - + Merge Selection - + Copy Kopiatu - + Copy selection - + Paste Itsatsi - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/fa.ts b/data/locale/fa.ts index 3cd59e14a5c..ba975e93311 100644 --- a/data/locale/fa.ts +++ b/data/locale/fa.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut برش - + Cut selection - + Copy کپی - + Copy selection - + Paste چسباندن - + Mute/unmute (<%1> + middle click) Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut برش - + Cut selection - + Merge Selection - + Copy کپی - + Copy selection - + Paste چسباندن - + Mute/unmute (<%1> + middle click) Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/fr.ts b/data/locale/fr.ts index 541b36c263a..667d204eeb7 100644 --- a/data/locale/fr.ts +++ b/data/locale/fr.ts @@ -397,7 +397,7 @@ Si vous souhaitez traduire LMMS dans une autre langue ou améliorer les traducti - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Veuillez ouvrir un motif d'automation avec le menu contextuel d'un contrôle ! @@ -405,12 +405,12 @@ Si vous souhaitez traduire LMMS dans une autre langue ou améliorer les traducti AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Jouer/mettre en pause le motif (barre d'espace) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Arrêter de jouer le motif actuel (barre d'espace) @@ -501,7 +501,7 @@ Si vous souhaitez traduire LMMS dans une autre langue ou améliorer les traducti - Automation Editor - no pattern + Automation Editor - no clip Éditeur d'automation - pas de motif @@ -512,68 +512,68 @@ Si vous souhaitez traduire LMMS dans une autre langue ou améliorer les traducti - Model is already connected to this pattern. + Model is already connected to this clip. Ce modèle est déjà connecté à ce motif. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Déplacer un contrôle en appuyant sur <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Ouvrir dans l'éditeur d'automation - + Clear Effacer - + Reset name Réinitialiser le nom - + Change name Modifier le nom - + Set/clear record Armer/désarmer l'enregistrement - + Flip Vertically (Visible) Tourner verticalement (visible) - + Flip Horizontally (Visible) Tourner horizontalement (visible) - + %1 Connections %1 connexions - + Disconnect "%1" Déconnecter "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Ce modèle est déjà connecté à ce motif. @@ -619,7 +619,7 @@ Si vous souhaitez traduire LMMS dans une autre langue ou améliorer les traducti - Clone beat/bassline pattern + Clone beat/bassline clip Cloner le rythme/la ligne de basse @@ -649,19 +649,19 @@ Si vous souhaitez traduire LMMS dans une autre langue ou améliorer les traducti - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Ouvrir dans l'éditeur de rythmes et de ligne de basse - + Reset name Réinitialiser le nom - + Change name Modifier le nom @@ -9861,44 +9861,44 @@ Veuillez visiter http://lmms.sf.net/wiki pour la documentation de LMMS. - PatternView + MidiClipView - + Open in piano-roll Ouvrir dans le piano virtuel - + Set as ghost in piano-roll - + Clear all notes Effacer toutes les notes - + Reset name Réinitialiser le nom - + Change name Modifier le nom - + Add steps Ajouter des pas - + Remove steps Supprimer des pas - + Clone Steps Cloner les pas @@ -10159,7 +10159,7 @@ Veuillez visiter http://lmms.sf.net/wiki pour la documentation de LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Veuillez ouvrir un motif en double-cliquant dessus ! @@ -10173,7 +10173,7 @@ Veuillez visiter http://lmms.sf.net/wiki pour la documentation de LMMS.PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Jouer/mettre en pause le motif (barre d'espace) @@ -10193,7 +10193,7 @@ Veuillez visiter http://lmms.sf.net/wiki pour la documentation de LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Arrêter de jouer le motif (barre d'espace) @@ -10243,13 +10243,13 @@ Veuillez visiter http://lmms.sf.net/wiki pour la documentation de LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10366,48 +10366,48 @@ Veuillez visiter http://lmms.sf.net/wiki pour la documentation de LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Piano virtuel - pas de motif - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12318,69 +12318,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Supprimer (bouton du milieu de la souris) - + Delete selection (middle mousebutton) - + Cut Couper - + Cut selection - + Copy Copier - + Copy selection - + Paste Coller - + Mute/unmute (<%1> + middle click) Sourdine (ou non) (<%1> + clic-milieu) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Inverser l'échantillon - + Set clip color - + Use track color @@ -13620,103 +13620,103 @@ Veuillez vérifier que vous avez les droits en lecture pour ce fichier et le ré - TrackContentObject + Clip - + Mute Mettre en sourdine - TrackContentObjectView + ClipView - + Current position Position actuelle - + Current length Longueur actuelle - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 vers %5:%6) - + Press <%1> and drag to make a copy. Appuyez sur <%1> et glissez pour faire une copie. - + Press <%1> for free resizing. Appuyez sur <%1> pour un redimensionnement libre. - + Hint Astuce - + Delete (middle mousebutton) Supprimer (bouton du milieu de la souris) - + Delete selection (middle mousebutton) - + Cut Couper - + Cut selection - + Merge Selection - + Copy Copier - + Copy selection - + Paste Coller - + Mute/unmute (<%1> + middle click) Sourdine (ou non) (<%1> + clic-milieu) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/gl.ts b/data/locale/gl.ts index 35178461d70..0efa2ea429a 100644 --- a/data/locale/gl.ts +++ b/data/locale/gl.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Abra un padrón de automatización co menú de contexto dun control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name Restaurar o nome - + Change name Mudar o nome - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name Restaurar o nome - + Change name Mudar o nome @@ -9567,44 +9567,44 @@ Visitehttp://lmms.sf.net/wiki para documentación sobre o LMMS. - PatternView + MidiClipView - + Open in piano-roll Abrir na pianola - + Set as ghost in piano-roll - + Clear all notes Limpar todas as notas - + Reset name Restaurar o nome - + Change name Mudar o nome - + Add steps Engadir pasos - + Remove steps Eliminar pasos - + Clone Steps @@ -9865,7 +9865,7 @@ Visitehttp://lmms.sf.net/wiki para documentación sobre o LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Abra un padrón facendo duplo clic nel! @@ -9879,7 +9879,7 @@ Visitehttp://lmms.sf.net/wiki para documentación sobre o LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9899,7 +9899,7 @@ Visitehttp://lmms.sf.net/wiki para documentación sobre o LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9949,13 +9949,13 @@ Visitehttp://lmms.sf.net/wiki para documentación sobre o LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10072,48 +10072,48 @@ Visitehttp://lmms.sf.net/wiki para documentación sobre o LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12024,69 +12024,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Inverter a mostra - + Set clip color - + Use track color @@ -13322,103 +13322,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint Suxestión - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/he.ts b/data/locale/he.ts index d39946af973..d224c2803c2 100644 --- a/data/locale/he.ts +++ b/data/locale/he.ts @@ -397,7 +397,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -405,12 +405,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -501,7 +501,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -512,68 +512,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear נקה - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -619,7 +619,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9567,44 +9567,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9865,7 +9865,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9879,7 +9879,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9899,7 +9899,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9949,13 +9949,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10072,48 +10072,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12022,69 +12022,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13320,103 +13320,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/hi_IN.ts b/data/locale/hi_IN.ts index 74ca515e20c..d55cd895ee6 100644 --- a/data/locale/hi_IN.ts +++ b/data/locale/hi_IN.ts @@ -398,7 +398,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -406,12 +406,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -502,7 +502,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -513,68 +513,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name नाम रीसेट करें - + Change name नाम बदलें। - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -620,7 +620,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -650,19 +650,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Beat+Bassline Editor में खोलें - + Reset name नाम रीसेट करें - + Change name नाम बदलें। @@ -9568,44 +9568,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name नाम रीसेट करें - + Change name नाम बदलें। - + Add steps - + Remove steps - + Clone Steps @@ -9866,7 +9866,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9880,7 +9880,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9900,7 +9900,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9950,13 +9950,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10073,48 +10073,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12023,69 +12023,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13321,103 +13321,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/hu_HU.ts b/data/locale/hu_HU.ts index 3eaa8d8d1fb..53f6e4d73cd 100644 --- a/data/locale/hu_HU.ts +++ b/data/locale/hu_HU.ts @@ -397,7 +397,7 @@ Ha szeretnél részt venni az LMMS más nyelvekre történő fordításában vag - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Nyiss meg egy automatizációs klipet dupla kattintással! @@ -405,12 +405,12 @@ Ha szeretnél részt venni az LMMS más nyelvekre történő fordításában vag AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Klip lejátszása/megállítása (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Lejátszás leállítása (Space) @@ -501,7 +501,7 @@ Ha szeretnél részt venni az LMMS más nyelvekre történő fordításában vag - Automation Editor - no pattern + Automation Editor - no clip Automatizáció Szerkesztő @@ -512,68 +512,68 @@ Ha szeretnél részt venni az LMMS más nyelvekre történő fordításában vag - Model is already connected to this pattern. + Model is already connected to this clip. Ez a vezérlő már csatlakoztatva van a kliphez. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Húzz ide egy vezérlőt <%1> nyomvatartása mellett - AutomationPatternView + AutomationClipView - + Open in Automation editor Megnyitás az Automatizáció Szerkesztőben - + Clear Tartalom törlése - + Reset name Név visszaállítása - + Change name Átnevezés - + Set/clear record Felvétel be/ki - + Flip Vertically (Visible) Látható terület függőleges tükrözése - + Flip Horizontally (Visible) Látható terület vízszintes tükrözése - + %1 Connections %1 Kapcsolat - + Disconnect "%1" "%1" leválasztása - - Model is already connected to this pattern. + + Model is already connected to this clip. Ez a vezérlő már csatlakoztatva van a kliphez. @@ -619,7 +619,7 @@ Ha szeretnél részt venni az LMMS más nyelvekre történő fordításában vag - Clone beat/bassline pattern + Clone beat/bassline clip Beat/Bassline sáv klónozása @@ -649,19 +649,19 @@ Ha szeretnél részt venni az LMMS más nyelvekre történő fordításában vag - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Megnyitás a Beat+Bassline szerkesztőben - + Reset name Név visszaállítása - + Change name Átnevezés @@ -9575,44 +9575,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll Megnyitás a Piano Rollban - + Set as ghost in piano-roll - + Clear all notes - + Reset name Név visszaállítása - + Change name Átnevezés - + Add steps Lépések hozzáadása - + Remove steps Lépések eltávolítása - + Clone Steps Megduplázás @@ -9873,7 +9873,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Nyiss meg egy kilppet dupla kattintással! @@ -9887,7 +9887,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Klip lejátszása/megállítása (Space) @@ -9907,7 +9907,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Lejátszás leállítása (Space) @@ -9957,13 +9957,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip Pattern importálása - Export pattern + Export clip Pattern exportálása @@ -10080,48 +10080,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Piano Roll - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) XML pattern fájl (*.xpt *.xptz) - Export pattern success + Export clip success Pattern exportálása sikeres - Pattern saved to %1 + Clip saved to %1 Pattern mentve a(z) %1 fájlba. - Import pattern. + Import clip. Pattern importálása - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip Pattern megnyitása - Import pattern success + Import clip success Pattern importálása sikeres - Imported pattern %1! + Imported clip %1! %1 importálva @@ -12033,69 +12033,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample Kattintson duplán hangfájl betöltéséhez - + Delete (middle mousebutton) Törlés (középső egérgomb) - + Delete selection (middle mousebutton) Kijelöltek törlése (középső egérgomb) - + Cut Kivágás - + Cut selection Kijelölés kivágása - + Copy Másolás - + Copy selection Kijelölés másolása - + Paste Beillesztés - + Mute/unmute (<%1> + middle click) Némítás (<%1> + középső egérgomb) - + Mute/unmute selection (<%1> + middle click) Kijelölés némítása (<%1> + középső egérgomb) - + Reverse sample Minta megfordítása - + Set clip color Szín módosítása - + Use track color Sáv színének használata @@ -13332,103 +13332,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute Némítás - TrackContentObjectView + ClipView - + Current position Jelenlegi pozíció - + Current length Jelenlegi hossz - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 - %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint Tipp - + Delete (middle mousebutton) Törlés (középső egérgomb) - + Delete selection (middle mousebutton) Kijelöltek törlése (középső egérgomb) - + Cut Kivágás - + Cut selection Kijelöltek kivágása - + Merge Selection - + Copy Másolás - + Copy selection Kijelölés másolása - + Paste Beillesztés - + Mute/unmute (<%1> + middle click) Némítás (<%1> + középső egérgomb) - + Mute/unmute selection (<%1> + middle click) Kijelölés némítása (<%1> + középső egérgomb) - + Set clip color Szín módosítása - + Use track color Sáv színének használata diff --git a/data/locale/id.ts b/data/locale/id.ts index 418cecdbc45..e65d2fa5321 100644 --- a/data/locale/id.ts +++ b/data/locale/id.ts @@ -397,7 +397,7 @@ Jika Anda tertarik untuk menerjemahkan LMMS dalam bahasa lain atau ingin meningk - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Silakan buka pola otomasi dengan menu konteks kontrol! @@ -405,12 +405,12 @@ Jika Anda tertarik untuk menerjemahkan LMMS dalam bahasa lain atau ingin meningk AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Putar/jeda pola saat ini (Spasi) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Berhenti memutar pola saat ini (Spasi) @@ -501,7 +501,7 @@ Jika Anda tertarik untuk menerjemahkan LMMS dalam bahasa lain atau ingin meningk - Automation Editor - no pattern + Automation Editor - no clip Editor Otomasi - tiada pola @@ -512,68 +512,68 @@ Jika Anda tertarik untuk menerjemahkan LMMS dalam bahasa lain atau ingin meningk - Model is already connected to this pattern. + Model is already connected to this clip. Model sudah terhubung ke pola ini. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Tarik kontrol sambil menekan <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Buka di editor Otomasi - + Clear Bersih - + Reset name Reset nama - + Change name Ganti nama - + Set/clear record Setel/bersihkan catatan - + Flip Vertically (Visible) Balik secara Vertikal (Terlihat) - + Flip Horizontally (Visible) Balik secara Horizontal (Terlihat) - + %1 Connections %1 Koneksi - + Disconnect "%1" Putuskan "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Model sudah terhubung ke pola ini. @@ -619,7 +619,7 @@ Jika Anda tertarik untuk menerjemahkan LMMS dalam bahasa lain atau ingin meningk - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ Jika Anda tertarik untuk menerjemahkan LMMS dalam bahasa lain atau ingin meningk - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Buka di Ketukan/Bassline-Editor - + Reset name Reset nama - + Change name Ganti nama @@ -9574,44 +9574,44 @@ Silakan kunjungi http://lmms.sf.net/wiki untuk dokumentasi LMMS. - PatternView + MidiClipView - + Open in piano-roll Buka di rol-piano - + Set as ghost in piano-roll - + Clear all notes Bersihkan semua not - + Reset name Reset nama - + Change name Ganti nama - + Add steps Tambah langkah - + Remove steps Hapus langkah - + Clone Steps Klon langkah @@ -9872,7 +9872,7 @@ Silakan kunjungi http://lmms.sf.net/wiki untuk dokumentasi LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Buka pola dengan mengklik dua kali di atasnya! @@ -9886,7 +9886,7 @@ Silakan kunjungi http://lmms.sf.net/wiki untuk dokumentasi LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Putar/jeda pola saat ini (Spasi) @@ -9906,7 +9906,7 @@ Silakan kunjungi http://lmms.sf.net/wiki untuk dokumentasi LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Berhenti memutar pola sekarang (Spasi) @@ -9956,13 +9956,13 @@ Silakan kunjungi http://lmms.sf.net/wiki untuk dokumentasi LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10079,48 +10079,48 @@ Silakan kunjungi http://lmms.sf.net/wiki untuk dokumentasi LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Rol-Piano - tiada pola - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12031,69 +12031,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Hapus (tombol tengah mouse) - + Delete selection (middle mousebutton) - + Cut Potong - + Cut selection - + Copy Salin - + Copy selection - + Paste Tempel - + Mute/unmute (<%1> + middle click) Bisukan/suarakan (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Balikan sampel - + Set clip color - + Use track color @@ -13334,103 +13334,103 @@ Pastikan anda memiliki izin baca untuk berkas ini dan direktori yang mengandung - TrackContentObject + Clip - + Mute Bisu - TrackContentObjectView + ClipView - + Current position Posisi saat ini - + Current length Panjang saat ini - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. Tekan <%1> dan seret untuk membuat salinan. - + Press <%1> for free resizing. Tekan <%1> untuk merubah ukuran secara bebas. - + Hint Petunjuk - + Delete (middle mousebutton) Hapus (tombol tengah mouse) - + Delete selection (middle mousebutton) - + Cut Potong - + Cut selection - + Merge Selection - + Copy Salin - + Copy selection - + Paste Tempel - + Mute/unmute (<%1> + middle click) Bisukan/suarakan (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/it.ts b/data/locale/it.ts index 140ec13afeb..b1b6beb7da0 100644 --- a/data/locale/it.ts +++ b/data/locale/it.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! È necessario aprire uno schema di automazione con il menu contestuale di un controllo! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Riproduce/sospende lo schema corrente (Spazio) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Arresta la riproduzione dello schema corrente (Spazio) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip Editor automazione - nessuno schema @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. Modello già collegato a questo schema. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Trascina un controllo tenendo premuto <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Apri nell'editor Automazione - + Clear Libera area - + Reset name Reimposta nome - + Change name Rinomina - + Set/clear record Imposta/cancella registrazione - + Flip Vertically (Visible) Capovolgi verticalmente (visibile) - + Flip Horizontally (Visible) Capovolgi orizzontalmente (visibile) - + %1 Connections %1 connessioni - + Disconnect "%1" Disconnetti "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Modello già collegato a questo schema. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Apri nell'editor Beat+Bassline - + Reset name Reimposta nome - + Change name Rinomina @@ -9582,44 +9582,44 @@ Visitare http://lmms.sf.net/wiki per la documentazione di LMMS. - PatternView + MidiClipView - + Open in piano-roll Apri nel piano-roll - + Set as ghost in piano-roll Imposta come fantasma in piano-roll - + Clear all notes Cancella tutte le note - + Reset name Reimposta il nome - + Change name Cambia nome - + Add steps Aggiungi note - + Remove steps Elimina note - + Clone Steps Clona gli step @@ -9880,7 +9880,7 @@ Visitare http://lmms.sf.net/wiki per la documentazione di LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Aprire un pattern con un doppio-click sul pattern stesso! @@ -9894,7 +9894,7 @@ Visitare http://lmms.sf.net/wiki per la documentazione di LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Riproduci/metti in pausa il beat/bassline selezionato (Spazio) @@ -9914,7 +9914,7 @@ Visitare http://lmms.sf.net/wiki per la documentazione di LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Riproduci/metti in pausa il beat/bassline selezionato (Spazio) @@ -9964,13 +9964,13 @@ Visitare http://lmms.sf.net/wiki per la documentazione di LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10087,48 +10087,48 @@ Visitare http://lmms.sf.net/wiki per la documentazione di LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Piano-Roll - nessun pattern - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12042,69 +12042,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample Fare doppio-click per aprire un campione - + Delete (middle mousebutton) Elimina (tasto centrale del mouse) - + Delete selection (middle mousebutton) - + Cut Taglia - + Cut selection - + Copy Copia - + Copy selection - + Paste Incolla - + Mute/unmute (<%1> + middle click) Attiva/disattiva la modalità muta (<%1> + tasto centrale) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Inverti campione - + Set clip color - + Use track color @@ -13344,103 +13344,103 @@ Assicurarsi di avere i permessi in lettura per il file e per la directory che lo - TrackContentObject + Clip - + Mute Muto - TrackContentObjectView + ClipView - + Current position Posizione attuale - + Current length Lunghezza attuale - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (da %3:%4 a %5:%6) - + Press <%1> and drag to make a copy. Premere <%1>, cliccare e trascinare per copiare. - + Press <%1> for free resizing. Premere <%1> per ridimensionare liberamente. - + Hint Suggerimento - + Delete (middle mousebutton) Elimina (tasto centrale del mouse) - + Delete selection (middle mousebutton) - + Cut Taglia - + Cut selection - + Merge Selection - + Copy Copia - + Copy selection - + Paste Incolla - + Mute/unmute (<%1> + middle click) Attiva/disattiva la modalità muta (<%1> + tasto centrale) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/ja.ts b/data/locale/ja.ts index a77f470d4c2..33a98899385 100644 --- a/data/locale/ja.ts +++ b/data/locale/ja.ts @@ -397,7 +397,7 @@ LMMSを他の言語に翻訳したり、翻訳を改善することに興味が - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! コントロールのコンテキストメニューでオートメーションパターンを開いてください! @@ -405,12 +405,12 @@ LMMSを他の言語に翻訳したり、翻訳を改善することに興味が AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 現在のパターンの再生/一時停止 (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 現在のパターンの再生を停止 (Space) @@ -501,7 +501,7 @@ LMMSを他の言語に翻訳したり、翻訳を改善することに興味が - Automation Editor - no pattern + Automation Editor - no clip オートメーション エディター - パターンなし @@ -512,68 +512,68 @@ LMMSを他の言語に翻訳したり、翻訳を改善することに興味が - Model is already connected to this pattern. + Model is already connected to this clip. モデルは、すでにこのパターンに接続されています。 - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> <%1>を押しながらコントロールをドラッグしてください - AutomationPatternView + AutomationClipView - + Open in Automation editor オートメーション エディターで開く - + Clear クリア - + Reset name 名前をリセット - + Change name 名前を変更 - + Set/clear record 録音をセット/クリア - + Flip Vertically (Visible) 左右反転 - + Flip Horizontally (Visible) 上下反転 - + %1 Connections %1 個の接続 - + Disconnect "%1" "%1" を切断 - - Model is already connected to this pattern. + + Model is already connected to this clip. モデルは、すでにこのパターンに接続されています。 @@ -619,7 +619,7 @@ LMMSを他の言語に翻訳したり、翻訳を改善することに興味が - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ LMMSを他の言語に翻訳したり、翻訳を改善することに興味が - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor ビート+ベースライン エディターで開く - + Reset name 名前をリセット - + Change name 名前を変更 @@ -9570,44 +9570,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll ピアノロールで開く - + Set as ghost in piano-roll - + Clear all notes すべてのノートをクリア - + Reset name 名前をリセット - + Change name 名前を変更 - + Add steps ステップを追加 - + Remove steps ステップを削除 - + Clone Steps ステップを複製 @@ -9868,7 +9868,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! パターン上でダブルクリックして、パターンを開いてください! @@ -9882,7 +9882,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 現在のパターンの再生/一時停止 (Space) @@ -9902,7 +9902,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 現在のパターンの再生を停止 (Space) @@ -9952,13 +9952,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10075,48 +10075,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip ピアノロール - パターン無し - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12026,69 +12026,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample ダブルクリックしてサンプルを開く - + Delete (middle mousebutton) 削除 (マウス中ボタン) - + Delete selection (middle mousebutton) - + Cut 切り取り - + Cut selection - + Copy コピー - + Copy selection - + Paste 貼り付け - + Mute/unmute (<%1> + middle click) ミュート/ミュート解除 (<%1> + 中ボタンクリック) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample サンプルを反転する - + Set clip color - + Use track color @@ -13328,103 +13328,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute ミュート - TrackContentObjectView + ClipView - + Current position 現在位置 - + Current length 現在の長さ - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 から %5:%6) - + Press <%1> and drag to make a copy. コピーするには<%1>を押しながらドラッグしてください。 - + Press <%1> for free resizing. フリーズ解除には<%1>を押してください。 - + Hint ヒント - + Delete (middle mousebutton) 削除 (マウス中ボタン) - + Delete selection (middle mousebutton) - + Cut 切り取り - + Cut selection - + Merge Selection - + Copy コピー - + Copy selection - + Paste 貼り付け - + Mute/unmute (<%1> + middle click) ミュート/ミュート解除 (<%1> + 中ボタンクリック) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/ka.ts b/data/locale/ka.ts index 71de7bf9229..7e1187a2655 100644 --- a/data/locale/ka.ts +++ b/data/locale/ka.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/ko.ts b/data/locale/ko.ts index 4519b040bda..2829c1983af 100644 --- a/data/locale/ko.ts +++ b/data/locale/ko.ts @@ -399,7 +399,7 @@ LMMS를 다른 언어로 번역하고 싶다거나 기존 번역을 개선하고 - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! 컨트롤의 컨텍스트 메뉴에서 오토메이션 패턴을 여시기 바랍니다! @@ -407,12 +407,12 @@ LMMS를 다른 언어로 번역하고 싶다거나 기존 번역을 개선하고 AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 현재 패턴 재생/일시정지 (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 현재 패턴 정지 (Space) @@ -503,7 +503,7 @@ LMMS를 다른 언어로 번역하고 싶다거나 기존 번역을 개선하고 - Automation Editor - no pattern + Automation Editor - no clip 오토메이션 편집기 - 패턴 없음 @@ -514,68 +514,68 @@ LMMS를 다른 언어로 번역하고 싶다거나 기존 번역을 개선하고 - Model is already connected to this pattern. + Model is already connected to this clip. 대상이 이미 패턴에 연결되어 있습니다. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> <%1> 키를 누른 채로 드래그 - AutomationPatternView + AutomationClipView - + Open in Automation editor 오토메이션 편집기에서 열기 - + Clear 지우기 - + Reset name 이름 초기화 - + Change name 이름 바꾸기 - + Set/clear record 녹음 설정/해제 - + Flip Vertically (Visible) 상하 반전 - + Flip Horizontally (Visible) 좌우 반전 - + %1 Connections %1개의 연결 - + Disconnect "%1" "%1" 연결 해제 - - Model is already connected to this pattern. + + Model is already connected to this clip. 대상이 이미 패턴과 연결되어 있습니다. @@ -621,7 +621,7 @@ LMMS를 다른 언어로 번역하고 싶다거나 기존 번역을 개선하고 - Clone beat/bassline pattern + Clone beat/bassline clip @@ -651,19 +651,19 @@ LMMS를 다른 언어로 번역하고 싶다거나 기존 번역을 개선하고 - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor 비트/베이스 라인 편집기에서 열기 - + Reset name 이름 초기화 - + Change name 이름 바꾸기 @@ -9572,44 +9572,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll 피아노-롤에서 열기 - + Set as ghost in piano-roll - + Clear all notes 전체 음표 지우기 - + Reset name 이름 초기화 - + Change name 이름 바꾸기 - + Add steps - + Remove steps - + Clone Steps @@ -9870,7 +9870,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! 더블클릭하여 패턴을 열어주세요! @@ -9884,7 +9884,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 현재 패턴 재생/일시정지 (Space) @@ -9904,7 +9904,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 현재 패턴 정지 (Space) @@ -9954,13 +9954,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10077,48 +10077,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip 피아노-롤 - 패턴 없음 - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12028,69 +12028,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample 더블클릭하여 샘플 열기 - + Delete (middle mousebutton) 삭제(마우스 가운데 버튼) - + Delete selection (middle mousebutton) - + Cut 잘라내기 - + Cut selection - + Copy 복사 - + Copy selection - + Paste 붙여넣기 - + Mute/unmute (<%1> + middle click) 음소거/해제 (<%1> + 마우스 가운데 버튼) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample 샘플 역으로 - + Set clip color - + Use track color @@ -13328,103 +13328,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute 음소거 - TrackContentObjectView + ClipView - + Current position 현재 위치 - + Current length 현재 길이 - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4부터 %5:%6까지) - + Press <%1> and drag to make a copy. <%1> 키를 누른 채 드래그하여 복사합니다. - + Press <%1> for free resizing. <%1> 키를 눌러 크기를 자유롭게 조절할 수 있습니다. - + Hint - + Delete (middle mousebutton) 삭제(마우스 가운데 버튼) - + Delete selection (middle mousebutton) - + Cut 잘라내기 - + Cut selection - + Merge Selection - + Copy 복사 - + Copy selection - + Paste 붙여넣기 - + Mute/unmute (<%1> + middle click) 음소거/해제 (<%1> + 마우스 가운데 버튼) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/ms_MY.ts b/data/locale/ms_MY.ts index 24d0cd8009c..ab477a55daa 100644 --- a/data/locale/ms_MY.ts +++ b/data/locale/ms_MY.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Sample terbalik - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/nb.ts b/data/locale/nb.ts index 9e81210f779..0fd155a4719 100644 --- a/data/locale/nb.ts +++ b/data/locale/nb.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Vennligst åpne en automasjonssekvens med kontekstmenyen til en kontroll! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Spill/pause denne sekvensen (Mellomrom) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Slutt å spille denne sekvensen (Mellomrom) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip Automasjonseditor - intet mønster @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. Modellen er alt koblet til denne sekvensen - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Hold og dra en kontroll mens du trykker <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Åpne i automasjonseditor - + Clear - + Reset name Tilbakestill navn - + Change name Endre navn - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Modellen er alt koblet til denne sekvensen @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name Tilbakestill navn - + Change name Endre navn @@ -9567,44 +9567,44 @@ Vennligst gå til http://lmms.sf.net/wiki for dokumentasjon om LMMS. - PatternView + MidiClipView - + Open in piano-roll Åpne i pianorull - + Set as ghost in piano-roll - + Clear all notes - + Reset name Tilbakestill navn - + Change name Endre navn - + Add steps - + Remove steps - + Clone Steps @@ -9865,7 +9865,7 @@ Vennligst gå til http://lmms.sf.net/wiki for dokumentasjon om LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9879,7 +9879,7 @@ Vennligst gå til http://lmms.sf.net/wiki for dokumentasjon om LMMS.PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Spill/pause denne sekvensen (Mellomrom) @@ -9899,7 +9899,7 @@ Vennligst gå til http://lmms.sf.net/wiki for dokumentasjon om LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Slutt å spille denne sekvensen (Mellomrom) @@ -9949,13 +9949,13 @@ Vennligst gå til http://lmms.sf.net/wiki for dokumentasjon om LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10072,48 +10072,48 @@ Vennligst gå til http://lmms.sf.net/wiki for dokumentasjon om LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12022,69 +12022,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Reverser lydklippet - + Set clip color - + Use track color @@ -13320,103 +13320,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/nl.ts b/data/locale/nl.ts index cc2593c3827..d93dc25b0e2 100644 --- a/data/locale/nl.ts +++ b/data/locale/nl.ts @@ -397,7 +397,7 @@ Als u interesse heeft om LMMS naar een andere taal te vertalen, of als u de best - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Open een automatiseringspatroon met het contextmenu van een control! @@ -405,12 +405,12 @@ Als u interesse heeft om LMMS naar een andere taal te vertalen, of als u de best AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Huidig patroon afspelen/pauzeren (Spatie) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Stoppen met afspelen van huidig patroon (Spatie) @@ -501,7 +501,7 @@ Als u interesse heeft om LMMS naar een andere taal te vertalen, of als u de best - Automation Editor - no pattern + Automation Editor - no clip Automatisering-editor - geen patroon @@ -512,68 +512,68 @@ Als u interesse heeft om LMMS naar een andere taal te vertalen, of als u de best - Model is already connected to this pattern. + Model is already connected to this clip. Model is reeds verbonden met dit patroon. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Sleep een bediening tijdens indrukken van <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Openen in automatisering-editor - + Clear Wissen - + Reset name Naam herstellen - + Change name Naam wijzigen - + Set/clear record Opnemen instellen/wissen - + Flip Vertically (Visible) Verticaal omdraaien (zichtbaar) - + Flip Horizontally (Visible) Horizontaal omdraaien (zichtbaar) - + %1 Connections %1 verbindingen - + Disconnect "%1" Verbinding verbreken met "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Model is reeds verbonden met dit patroon. @@ -619,7 +619,7 @@ Als u interesse heeft om LMMS naar een andere taal te vertalen, of als u de best - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ Als u interesse heeft om LMMS naar een andere taal te vertalen, of als u de best - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor In beat- en baslijn-editor openen - + Reset name Naam herstellen - + Change name Naam wijzigen @@ -9571,44 +9571,44 @@ Bezoek http://lmms.sf.net/wiki voor documentatie over LMMS. - PatternView + MidiClipView - + Open in piano-roll In piano-roll openen - + Set as ghost in piano-roll Als ghost instellen in piano-roll - + Clear all notes Alle noten leegmaken - + Reset name Naam herstellen - + Change name Naam wijzigen - + Add steps Stappen toevoegen - + Remove steps Stappen verwijderen - + Clone Steps Stappen klonen @@ -9869,7 +9869,7 @@ Bezoek http://lmms.sf.net/wiki voor documentatie over LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Open een patroon door erop te dubbelklikken! @@ -9883,7 +9883,7 @@ Bezoek http://lmms.sf.net/wiki voor documentatie over LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Huidig patroon afspelen/pauzeren (Spatie) @@ -9903,7 +9903,7 @@ Bezoek http://lmms.sf.net/wiki voor documentatie over LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Stoppen met afspelen van huidig patroon (Spatie) @@ -9953,13 +9953,13 @@ Bezoek http://lmms.sf.net/wiki voor documentatie over LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10076,48 +10076,48 @@ Bezoek http://lmms.sf.net/wiki voor documentatie over LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Piano-roll - geen patroon - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12028,69 +12028,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample Dubbelklikken om sample te openen - + Delete (middle mousebutton) Verwijderen (middelste muisknop) - + Delete selection (middle mousebutton) - + Cut Knippen - + Cut selection - + Copy Kopiëren - + Copy selection - + Paste Plakken - + Mute/unmute (<%1> + middle click) Dempen/geluid aan (<%1> + middelklik) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Sample omdraaien - + Set clip color - + Use track color @@ -13330,103 +13330,103 @@ Verzeker u ervan dat u leesrechten heeft voor het bestand en zijn bevattende map - TrackContentObject + Clip - + Mute Dempen - TrackContentObjectView + ClipView - + Current position Huidige positie - + Current length Huidige lengte - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 tot %5:%6) - + Press <%1> and drag to make a copy. Op <%1> drukken en slepen om een kopie te maken. - + Press <%1> for free resizing. Op <%1> drukken voor vrije grootte-aanpassing. - + Hint Tip - + Delete (middle mousebutton) Verwijderen (middelste muisknop) - + Delete selection (middle mousebutton) - + Cut Knippen - + Cut selection - + Merge Selection - + Copy Kopiëren - + Copy selection - + Paste Plakken - + Mute/unmute (<%1> + middle click) Dempen/geluid aan (<%1> + middelklik) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/oc.ts b/data/locale/oc.ts index d0146bac5c5..b0841d0e538 100644 --- a/data/locale/oc.ts +++ b/data/locale/oc.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Dobrir dins l'editor de automation - + Clear Escafar - + Reset name - + Change name Modificar lo nom - + Set/clear record - + Flip Vertically (Visible) Virar verticalament (visible) - + Flip Horizontally (Visible) Virar orizontalament (visible) - + %1 Connections %1 Connexions - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name Modificar lo nom @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll Dobrir dins lo piano virtual - + Set as ghost in piano-roll - + Clear all notes Escafar totas las nòtas - + Reset name - + Change name Modificar lo nom - + Add steps - + Remove steps - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Suprimir (boton del mièg de la mirga) - + Delete selection (middle mousebutton) - + Cut Copar - + Cut selection - + Copy Copiar - + Copy selection - + Paste Pegar - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Invertir l'escapolon - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position Posicion actuala - + Current length Longada actuala - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. Premètz <%1> e lisatz per far una còpia. - + Press <%1> for free resizing. Premètz <%1> per un redimensionnement liure. - + Hint Astúcia - + Delete (middle mousebutton) Suprimir (boton del mièg de la mirga) - + Delete selection (middle mousebutton) - + Cut Copar - + Cut selection - + Merge Selection - + Copy Copiar - + Copy selection - + Paste Pegar - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/pl.ts b/data/locale/pl.ts index 26ef65925d3..de980a70033 100644 --- a/data/locale/pl.ts +++ b/data/locale/pl.ts @@ -401,7 +401,7 @@ Radek Słowik - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Otwórz wzorzec automatyki za pomocą menu kontekstowego regulatora! @@ -409,12 +409,12 @@ Radek Słowik AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Odtwórz/wstrzymaj obecny wzorzec (spacja) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Zatrzymaj odtwarzanie obecnego wzorca (spacja) @@ -505,7 +505,7 @@ Radek Słowik - Automation Editor - no pattern + Automation Editor - no clip Edytor automatyki - brak wzorca @@ -516,68 +516,68 @@ Radek Słowik - Model is already connected to this pattern. + Model is already connected to this clip. Model jest już podłączony do tego wzorca. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Przeciągnij trzymając wciśnięty klawisz <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Otwórz w Edytorze Automatyki - + Clear Wyczyść - + Reset name Zresetuj nazwę - + Change name Zmień nazwę - + Set/clear record Ustaw/wyczyść nagranie - + Flip Vertically (Visible) Odwróć w pionie (widoczne) - + Flip Horizontally (Visible) Odwróć w poziomie (widoczne) - + %1 Connections %1 Połączenia - + Disconnect "%1" Rozłącz "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Model jest już podłączony do tego wzorca. @@ -623,7 +623,7 @@ Radek Słowik - Clone beat/bassline pattern + Clone beat/bassline clip Klonuj pattern perkusji/basu @@ -653,19 +653,19 @@ Radek Słowik - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Otwórz w Edytorze Perkusji i Basu - + Reset name Zresetuj nazwę - + Change name Zmień nazwę @@ -9854,44 +9854,44 @@ Odwiedź witrynę http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll Otwórz w Edytorze Pianolowym - + Set as ghost in piano-roll - + Clear all notes Wyczyść wszystkie nuty - + Reset name Zresetuj nazwę - + Change name Zmień nazwę - + Add steps Dodaj kroki - + Remove steps Usuń kroki - + Clone Steps Klonuj kroki @@ -10152,7 +10152,7 @@ Odwiedź witrynę http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Otwórz wzorzec podwójnym kliknięciem! @@ -10166,7 +10166,7 @@ Odwiedź witrynę http://lmms.sf.net/wiki for documentation on LMMS.PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Odtwórz/wstrzymaj obecny wzorzec (spacja) @@ -10186,7 +10186,7 @@ Odwiedź witrynę http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Zatrzymaj odtwarzanie obecnego wzorca (spacja) @@ -10236,13 +10236,13 @@ Odwiedź witrynę http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10359,48 +10359,48 @@ Odwiedź witrynę http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Edytor Pianolowy - brak wzorca - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12313,69 +12313,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Usuń (środkowy przycisk myszy) - + Delete selection (middle mousebutton) Usuń zaznaczone (środkowy przycisk myszy) - + Cut Wytnij - + Cut selection Wytnij zaznaczone - + Copy Kopiuj - + Copy selection Kopiuj zaznaczone - + Paste Wklej - + Mute/unmute (<%1> + middle click) Wycisz/cofnij wyciszenie (<%1> + środkowy przycisk myszy) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Odwróć próbkę - + Set clip color - + Use track color Użyj koloru ścieżki @@ -13615,103 +13615,103 @@ Upewnij się, że masz uprawnienia do odczytu tego pliku i katalogu zawierające - TrackContentObject + Clip - + Mute Wycisz - TrackContentObjectView + ClipView - + Current position Obecne położenie - + Current length Obecna dlugość - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (od %3:%4 do 5:%6) - + Press <%1> and drag to make a copy. Przytrzymaj <%1> i przeciągnij, aby skopiować. - + Press <%1> for free resizing. Przytrzymaj <%1> aby dowolnie zmieniać rozmiar. - + Hint Wskazówka - + Delete (middle mousebutton) Usuń (środkowy przycisk myszy) - + Delete selection (middle mousebutton) Usuń zaznaczone (środkowy przycisk myszy) - + Cut Wytnij - + Cut selection Wytnij zaznaczone - + Merge Selection - + Copy Kopiuj - + Copy selection Kopiuj zaznaczone - + Paste Wklej - + Mute/unmute (<%1> + middle click) Wycisz/cofnij wyciszenie (<%1> + środkowy przycisk myszy) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color Użyj koloru ścieżki diff --git a/data/locale/pt.ts b/data/locale/pt.ts index 77a69094687..ad06701e0da 100644 --- a/data/locale/pt.ts +++ b/data/locale/pt.ts @@ -397,7 +397,7 @@ Se você estiver interessado em traduzir LMMS para outro idioma ou quer melhorar - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Por favor, abra o sequenciador de automação com o menu de contexto do controle! @@ -405,12 +405,12 @@ Se você estiver interessado em traduzir LMMS para outro idioma ou quer melhorar AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Tocar/Parar padrão atual (Espaço) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Parar de tocar a sequência atual (Espaço) @@ -501,7 +501,7 @@ Se você estiver interessado em traduzir LMMS para outro idioma ou quer melhorar - Automation Editor - no pattern + Automation Editor - no clip Editor de Automação - sem padrão @@ -512,68 +512,68 @@ Se você estiver interessado em traduzir LMMS para outro idioma ou quer melhorar - Model is already connected to this pattern. + Model is already connected to this clip. O modelo já está conectado para este padrão. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Arraste o controle enquanto pressiona a tecla <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Abra dentro do Editor de Automação - + Clear Limpar - + Reset name Restaurar nome - + Change name Mudar nome - + Set/clear record Selecionar/limpar gravação - + Flip Vertically (Visible) Virar Verticalmente (Visível) - + Flip Horizontally (Visible) Virar Horizontalmente (Visível) - + %1 Connections %1 Conexões - + Disconnect "%1" Desconectar "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. O modelo já está conectado para este padrão. @@ -619,7 +619,7 @@ Se você estiver interessado em traduzir LMMS para outro idioma ou quer melhorar - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ Se você estiver interessado em traduzir LMMS para outro idioma ou quer melhorar - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Abrir Editor de Bases - + Reset name Restaurar nome - + Change name Mudar nome @@ -9570,44 +9570,44 @@ Por favor visite http://lmms.sf.net/wiki para ter acesso a mais infromações so - PatternView + MidiClipView - + Open in piano-roll Abrir no Editor de Notas MIDI - + Set as ghost in piano-roll - + Clear all notes Limpar todas as notas - + Reset name Restaurar nome - + Change name Mudar nome - + Add steps Adicionar passo - + Remove steps Remover passo - + Clone Steps Clonar Etapas @@ -9868,7 +9868,7 @@ Por favor visite http://lmms.sf.net/wiki para ter acesso a mais infromações so - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Por favor abra um a sequência com um duplo clique sobre ela! @@ -9882,7 +9882,7 @@ Por favor visite http://lmms.sf.net/wiki para ter acesso a mais infromações so PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Tocar/Parar padrão atual (Espaço) @@ -9902,7 +9902,7 @@ Por favor visite http://lmms.sf.net/wiki para ter acesso a mais infromações so - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Parar de tocar a sequência atual (Espaço) @@ -9952,13 +9952,13 @@ Por favor visite http://lmms.sf.net/wiki para ter acesso a mais infromações so - Import pattern + Import clip - Export pattern + Export clip @@ -10075,48 +10075,48 @@ Por favor visite http://lmms.sf.net/wiki para ter acesso a mais infromações so - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12027,69 +12027,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Excluir (botão do meio do mouse) - + Delete selection (middle mousebutton) - + Cut Recortar - + Cut selection - + Copy Copiar - + Copy selection - + Paste Colar - + Mute/unmute (<%1> + middle click) Mudo/Não Mudo (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Amostra reversa - + Set clip color - + Use track color @@ -13328,103 +13328,103 @@ Por favor certifique-se que você tem permissões de leitura para o arquivo e pa - TrackContentObject + Clip - + Mute Mudo - TrackContentObjectView + ClipView - + Current position Posição atual - + Current length - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint Sugestão - + Delete (middle mousebutton) Excluir (botão do meio do mouse) - + Delete selection (middle mousebutton) - + Cut Recortar - + Cut selection - + Merge Selection - + Copy Copiar - + Copy selection - + Paste Colar - + Mute/unmute (<%1> + middle click) Mudo/Não Mudo (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/ro.ts b/data/locale/ro.ts index 98ab9ce66f9..2aeafe9ab98 100644 --- a/data/locale/ro.ts +++ b/data/locale/ro.ts @@ -397,7 +397,7 @@ Dacă sunteți interesat în traducerea LMMS într-o altă limbă sau doriți s - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -405,12 +405,12 @@ Dacă sunteți interesat în traducerea LMMS într-o altă limbă sau doriți s AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -501,7 +501,7 @@ Dacă sunteți interesat în traducerea LMMS într-o altă limbă sau doriți s - Automation Editor - no pattern + Automation Editor - no clip @@ -512,68 +512,68 @@ Dacă sunteți interesat în traducerea LMMS într-o altă limbă sau doriți s - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -619,7 +619,7 @@ Dacă sunteți interesat în traducerea LMMS într-o altă limbă sau doriți s - Clone beat/bassline pattern + Clone beat/bassline clip @@ -649,19 +649,19 @@ Dacă sunteți interesat în traducerea LMMS într-o altă limbă sau doriți s - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9567,44 +9567,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9865,7 +9865,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9879,7 +9879,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9899,7 +9899,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9949,13 +9949,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10072,48 +10072,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12022,69 +12022,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Eșantion invers - + Set clip color - + Use track color @@ -13320,103 +13320,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/ru.ts b/data/locale/ru.ts index 0e340493157..e611c20f29c 100644 --- a/data/locale/ru.ts +++ b/data/locale/ru.ts @@ -409,7 +409,7 @@ Simple88 (2016) - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Откройте редактор автоматизации через контекстное меню регулятора! @@ -417,12 +417,12 @@ Simple88 (2016) AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Игра/пауза текущей мелодии (Пробел) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Остановить воспроизведение текущего паттерна (пробел) @@ -513,7 +513,7 @@ Simple88 (2016) - Automation Editor - no pattern + Automation Editor - no clip Редактор автоматизации — без паттерна @@ -524,68 +524,68 @@ Simple88 (2016) - Model is already connected to this pattern. + Model is already connected to this clip. Модель уже подключена к этому паттерну. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Перетащите элемент управления, удерживая <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Открыть в редакторе автоматизации - + Clear Очистить - + Reset name Сбросить название - + Change name Переименовать - + Set/clear record Установить/очистить запись - + Flip Vertically (Visible) Перевернуть вертикально (Видимое) - + Flip Horizontally (Visible) Перевернуть горизонтально (Видимое) - + %1 Connections Соединения %1 - + Disconnect "%1" Отсоединить «%1» - - Model is already connected to this pattern. + + Model is already connected to this clip. Модель уже подключена к этому паттерну. @@ -631,7 +631,7 @@ Simple88 (2016) - Clone beat/bassline pattern + Clone beat/bassline clip @@ -661,19 +661,19 @@ Simple88 (2016) - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Открыть в Композиторе-Ритм+Баса - + Reset name Сбросить название - + Change name Переименовать @@ -9592,44 +9592,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll Открыть в редакторе нот - + Set as ghost in piano-roll Установить как призрак в пиано-ролл - + Clear all notes Очистить все ноты - + Reset name Сбросить название - + Change name Переименовать - + Add steps Добавить такты - + Remove steps Удалить такты - + Clone Steps Клонировать такты @@ -9890,7 +9890,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Откройте паттерн двойным щелчком! @@ -9904,7 +9904,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Игра/пауза текущей мелодии (пробел) @@ -9924,7 +9924,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Остановить воспроизведение текущей мелодии (пробел) @@ -9974,13 +9974,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10097,48 +10097,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Нотный редактор — нет паттерна - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12052,69 +12052,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample Дважды щелкните, чтобы открыть сэмпл - + Delete (middle mousebutton) Удалить (средняя кнопка мыши) - + Delete selection (middle mousebutton) Удалить выделенное (средняя кнопка мыши) - + Cut Вырезать - + Cut selection Вырезать выделенное - + Copy Копировать - + Copy selection Копировать выделенное - + Paste Вставить - + Mute/unmute (<%1> + middle click) Тихо/громко (<%1> + щелчок средней кнопкой) - + Mute/unmute selection (<%1> + middle click) Отключить или включить звук для выделенного (<%1> + средняя кнопка мыши) - + Reverse sample Перевернуть сэмпл - + Set clip color Установить цвет клипа - + Use track color Использовать цвет дорожки @@ -13355,103 +13355,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute Заглушить - TrackContentObjectView + ClipView - + Current position Текущая позиция - + Current length Текущая длительность - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (от %3:%4 до %5:%6) - + Press <%1> and drag to make a copy. Удерживайте <%1> при перетаскивании, чтобы создать копию. - + Press <%1> for free resizing. Для свободного изменения размера нажмите <%1>. - + Hint Подсказка - + Delete (middle mousebutton) Удалить (средняя кнопка мыши) - + Delete selection (middle mousebutton) Удалить выделенное (средняя кнопка мыши) - + Cut Вырезать - + Cut selection Вырезать выделенное - + Merge Selection - + Copy Копировать - + Copy selection Копировать выделенное - + Paste Вставить - + Mute/unmute (<%1> + middle click) Тихо/громко (<%1> + щелчок средней кнопкой) - + Mute/unmute selection (<%1> + middle click) Отключить или включить звук для выделенного (<%1> + средняя кнопка мыши) - + Set clip color Установить цвет клипа - + Use track color Использовать цвет дорожки diff --git a/data/locale/sl.ts b/data/locale/sl.ts index 4882faf97e9..6c960f20a5f 100644 --- a/data/locale/sl.ts +++ b/data/locale/sl.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor - + Clear - + Reset name - + Change name - + Set/clear record - + Flip Vertically (Visible) - + Flip Horizontally (Visible) - + %1 Connections - + Disconnect "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor - + Reset name - + Change name @@ -9566,44 +9566,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll Odpri v Klavirčrtovju - + Set as ghost in piano-roll - + Clear all notes - + Reset name - + Change name - + Add steps - + Remove steps - + Clone Steps @@ -9864,7 +9864,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -9878,7 +9878,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -9898,7 +9898,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -9948,13 +9948,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10071,48 +10071,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Klavirčrtovje - ni šablone - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12021,69 +12021,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample - + Set clip color - + Use track color @@ -13319,103 +13319,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute Mute - TrackContentObjectView + ClipView - + Current position - + Current length - - + + %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. - + Press <%1> for free resizing. - + Hint - + Delete (middle mousebutton) - + Delete selection (middle mousebutton) - + Cut - + Cut selection - + Merge Selection - + Copy - + Copy selection - + Paste - + Mute/unmute (<%1> + middle click) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/sr.ts b/data/locale/sr.ts index bfbafecd0e6..1208a8a96d5 100644 --- a/data/locale/sr.ts +++ b/data/locale/sr.ts @@ -346,7 +346,7 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditor - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! @@ -361,7 +361,7 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -369,7 +369,7 @@ If you're interested in translating LMMS in another language or want to imp - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -469,7 +469,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip @@ -497,19 +497,19 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. - AutomationPattern + AutomationClip Drag a control while pressing <%1> - AutomationPatternView + AutomationClipView double-click to open this pattern in automation editor @@ -551,7 +551,7 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. @@ -614,7 +614,7 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView Open in Beat+Bassline-Editor @@ -5184,7 +5184,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator - PatternView + MidiClipView Open in piano-roll @@ -5337,7 +5337,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator PianoRoll - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! @@ -5412,7 +5412,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) @@ -5424,7 +5424,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator - Stop playing of current pattern (Space) + Stop playing of current clip (Space) @@ -5540,7 +5540,7 @@ PM means phase modulation: Oscillator 3's phase is modulated by oscillator - Piano-Roll - no pattern + Piano-Roll - no clip @@ -5837,7 +5837,7 @@ Reason: "%2" - SampleTCOView + SampleClipView double-click to select sample @@ -6630,14 +6630,14 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip Mute - TrackContentObjectView + ClipView Current position diff --git a/data/locale/sv.ts b/data/locale/sv.ts index 942553a8639..acf905486cf 100644 --- a/data/locale/sv.ts +++ b/data/locale/sv.ts @@ -397,7 +397,7 @@ Om du är intresserad av att översätta LMMS till ett annat språk eller vill f - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Öppna ett automationsmönster från en kontrollers kontextmeny! @@ -405,12 +405,12 @@ Om du är intresserad av att översätta LMMS till ett annat språk eller vill f AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Spela/pausa aktuellt mönster (Mellanslag) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Sluta spela aktuellt mönster (Mellanslag) @@ -501,7 +501,7 @@ Om du är intresserad av att översätta LMMS till ett annat språk eller vill f - Automation Editor - no pattern + Automation Editor - no clip Redigera Automation - inget automationsmönster @@ -512,68 +512,68 @@ Om du är intresserad av att översätta LMMS till ett annat språk eller vill f - Model is already connected to this pattern. + Model is already connected to this clip. Modellen är redan ansluten till det här mönstret. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Dra en kontroll samtidigt som du håller <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Redigera automationsmönster - + Clear Rensa - + Reset name Nollställ namn - + Change name Byt namn - + Set/clear record Ställ in/rensa inspelning - + Flip Vertically (Visible) Spegla Vertikalt (Synligt) - + Flip Horizontally (Visible) Spegla Horizontellt (Synligt) - + %1 Connections %1 Kopplingar - + Disconnect "%1" Koppla bort "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Modellen är redan ansluten till det här mönstret. @@ -619,7 +619,7 @@ Om du är intresserad av att översätta LMMS till ett annat språk eller vill f - Clone beat/bassline pattern + Clone beat/bassline clip Klona rytm-/basgångsmönster @@ -649,19 +649,19 @@ Om du är intresserad av att översätta LMMS till ett annat språk eller vill f - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Öppna i Takt+Basgång-redigeraren - + Reset name Nollställ namn - + Change name Byt namn @@ -9860,44 +9860,44 @@ Besök https://lmms.io/documentation/ för dokumentation (Engelska). - PatternView + MidiClipView - + Open in piano-roll Öppna i pianorulle - + Set as ghost in piano-roll Ange som spöke i pianorulle - + Clear all notes Rensa alla noter - + Reset name Nollställ namn - + Change name Byt namn - + Add steps Lägg till steg - + Remove steps Ta bort steg - + Clone Steps Klona Steg @@ -10158,7 +10158,7 @@ Besök https://lmms.io/documentation/ för dokumentation (Engelska). - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Dubbelklicka för att öppna ett mönster! @@ -10172,7 +10172,7 @@ Besök https://lmms.io/documentation/ för dokumentation (Engelska).PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Spela/pausa aktuellt mönster (mellanslag) @@ -10192,7 +10192,7 @@ Besök https://lmms.io/documentation/ för dokumentation (Engelska). - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Sluta spela aktuellt mönster (mellanslag) @@ -10242,13 +10242,13 @@ Besök https://lmms.io/documentation/ för dokumentation (Engelska). - Import pattern + Import clip Importera mönster - Export pattern + Export clip Exportera mönster @@ -10365,48 +10365,48 @@ Besök https://lmms.io/documentation/ för dokumentation (Engelska). - Piano-Roll - no pattern + Piano-Roll - no clip Pianorulle - inget mönster - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) XML-mönsterfil (*.xpt *.xptz) - Export pattern success + Export clip success Export av mönster lyckades - Pattern saved to %1 + Clip saved to %1 Mönster sparat till %1 - Import pattern. + Import clip. Importera mönster. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? Du håller på att importera ett mönster, detta kommer att skriva över ditt nuvarande mönster. Vill du fortsätta? - Open pattern + Open clip Öppet mönster - Import pattern success + Import clip success Import av mönster lyckades - Imported pattern %1! + Imported clip %1! Importerat mönstret %1! @@ -12320,69 +12320,69 @@ Du kan inaktivera dessa kontroller för att få en snabbare skanningstid (på eg - SampleTCOView + SampleClipView - + Double-click to open sample Dubbelklicka för att öppna sampel - + Delete (middle mousebutton) Ta bort (musens mitt-knapp) - + Delete selection (middle mousebutton) Ta bort markering (mittenmusknapp) - + Cut Klipp ut - + Cut selection Klipp ut markering - + Copy Kopiera - + Copy selection Kopiera markering - + Paste Klistra in - + Mute/unmute (<%1> + middle click) Tysta/avtysta (<%1> + mittenklick) - + Mute/unmute selection (<%1> + middle click) Tysta/öppna markering (<%1> + mittenklick) - + Reverse sample Spela baklänges - + Set clip color - + Use track color Använd spårfärg @@ -13622,103 +13622,103 @@ Se till att du har läsrättigheter för filen och mappen som innehåller filen - TrackContentObject + Clip - + Mute Tysta - TrackContentObjectView + ClipView - + Current position Aktuell position - + Current length Aktuell längd - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 till %5:%6) - + Press <%1> and drag to make a copy. Håll nere <%1> och dra för att kopiera. - + Press <%1> for free resizing. Tryck på <%1> för att ändra storleken. - + Hint Ledtråd - + Delete (middle mousebutton) Ta bort (musens mitt-knapp) - + Delete selection (middle mousebutton) Ta bort markering (mittenmusknapp) - + Cut Klipp ut - + Cut selection Klipp ut markering - + Merge Selection Sammanfoga merkering - + Copy Kopiera - + Copy selection Kopiera markering - + Paste Klistra in - + Mute/unmute (<%1> + middle click) Tysta/avtysta (<%1> + mittenklick) - + Mute/unmute selection (<%1> + middle click) Tysta/öppna markering (<%1> + mittenklick) - + Set clip color - + Use track color Använd spårfärg diff --git a/data/locale/tr.ts b/data/locale/tr.ts index 601d91deee4..d97cbd95373 100644 --- a/data/locale/tr.ts +++ b/data/locale/tr.ts @@ -397,7 +397,7 @@ LMMS'yi başka bir dilde çevirmekle ilgileniyorsanız veya mevcut çeviril - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Lütfen bir kontrolün içerik menüsü ile bir otomasyon modeli açın! @@ -405,12 +405,12 @@ LMMS'yi başka bir dilde çevirmekle ilgileniyorsanız veya mevcut çeviril AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Seçili bölümü oynat/durdur (Boşluk Tuşu) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Seçili modeli oynatmayı durdur (Boşluk Tuşu) @@ -501,7 +501,7 @@ LMMS'yi başka bir dilde çevirmekle ilgileniyorsanız veya mevcut çeviril - Automation Editor - no pattern + Automation Editor - no clip Ayarkayıt Düzenleyici - oluşturulmuş bölüm yok @@ -512,68 +512,68 @@ LMMS'yi başka bir dilde çevirmekle ilgileniyorsanız veya mevcut çeviril - Model is already connected to this pattern. + Model is already connected to this clip. Model zaten bu desene bağlanmış. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Kontrollerden birini, <%1> tuşuna basılı tutuyorken kıpırdatın - AutomationPatternView + AutomationClipView - + Open in Automation editor Ayarkayıt Düzenleyici'de aç - + Clear Temizle - + Reset name İsmini sıfırla - + Change name İsmini değiştir - + Set/clear record Kayıdı başlat/durdur - + Flip Vertically (Visible) Dikey Yönde Çevir (Görünür) - + Flip Horizontally (Visible) Yatay Yönde Çevir (Görünür) - + %1 Connections %1 Bağlantı - + Disconnect "%1" Şunun bağlantısını kes: "%1" - - Model is already connected to this pattern. + + Model is already connected to this clip. Model zaten bu desene bağlanmış. @@ -619,7 +619,7 @@ LMMS'yi başka bir dilde çevirmekle ilgileniyorsanız veya mevcut çeviril - Clone beat/bassline pattern + Clone beat/bassline clip Klon vuruşu / bas hattı deseni @@ -649,19 +649,19 @@ LMMS'yi başka bir dilde çevirmekle ilgileniyorsanız veya mevcut çeviril - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Beat+Bassline Düzenleyici'de aç - + Reset name İsmini sıfırla - + Change name İsmini değiştir @@ -9862,44 +9862,44 @@ LMMS ile ilgili belgeler için lütfen http://lmms.sf.net/wiki adresini ziyaret - PatternView + MidiClipView - + Open in piano-roll Piyano rulosunda aç - + Set as ghost in piano-roll Piyano rulosunda hayalet olarak ayarla - + Clear all notes Tüm notaları temizle - + Reset name İsmini sıfırla - + Change name İsmini değiştir - + Add steps Uzat - + Remove steps Kısalt - + Clone Steps Klon Adımları @@ -10160,7 +10160,7 @@ LMMS ile ilgili belgeler için lütfen http://lmms.sf.net/wiki adresini ziyaret - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Lütfen üzerine çift tıklayarak bir desen açın! @@ -10174,7 +10174,7 @@ LMMS ile ilgili belgeler için lütfen http://lmms.sf.net/wiki adresini ziyaret PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Seçili bölümü oynat/durdur (Boşluk Tuşu) @@ -10194,7 +10194,7 @@ LMMS ile ilgili belgeler için lütfen http://lmms.sf.net/wiki adresini ziyaret - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Seçili bölümü oynatmayı durdur (Boşluk Tuşu) @@ -10244,13 +10244,13 @@ LMMS ile ilgili belgeler için lütfen http://lmms.sf.net/wiki adresini ziyaret - Import pattern + Import clip Deseni içe aktar - Export pattern + Export clip Deseni dışa aktar @@ -10367,48 +10367,48 @@ LMMS ile ilgili belgeler için lütfen http://lmms.sf.net/wiki adresini ziyaret - Piano-Roll - no pattern + Piano-Roll - no clip Piyano Rulosu - desen yok - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) XML desen dosyası (*.xpt *.xptz) - Export pattern success + Export clip success Deseni dışa aktarma başarılı - Pattern saved to %1 + Clip saved to %1 Desen %1'e kaydedildi - Import pattern. + Import clip. Deseni içe aktar. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? Bir kalıp almak üzeresiniz, bu mevcut kalıbınızın üzerine yazılacaktır. Devam etmek istiyor musun? - Open pattern + Open clip Desen aç - Import pattern success + Import clip success Desen başarılı şekilde içe aktarıldı - Imported pattern %1! + Imported clip %1! %1 deseni içe aktarıldı! @@ -12322,69 +12322,69 @@ Daha hızlı bir tarama süresi elde etmek için bu kontrolleri devre dışı b - SampleTCOView + SampleClipView - + Double-click to open sample Örneği açmak için çift tıklayın - + Delete (middle mousebutton) Sil (orta klik) - + Delete selection (middle mousebutton) Seçimi sil (orta fare düğmesi) - + Cut Kes - + Cut selection Seçimi Kes - + Copy Kopyala - + Copy selection Seçimi Kopyala - + Paste Yapıştır - + Mute/unmute (<%1> + middle click) Sesi kapat/sesi aç (<%1> + orta tıklama) - + Mute/unmute selection (<%1> + middle click) Seçimin sesini kapat/aç (<%1> + orta tıklama) - + Reverse sample Örneği ters çevir - + Set clip color Klip rengini ayarla - + Use track color Parça rengini kullan @@ -13624,103 +13624,103 @@ Lütfen dosyayı ve dosyayı içeren dizini okuma iznine sahip olduğunuzdan emi - TrackContentObject + Clip - + Mute Ses kapatma - TrackContentObjectView + ClipView - + Current position Şu anki pozisyon - + Current length Mevcut uzunluk - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 to %5:%6) - + Press <%1> and drag to make a copy. Bir kopya oluşturmak için <%1> tuşuna basın ve sürükleyin. - + Press <%1> for free resizing. Serbest yeniden boyutlandırma için <%1> seçeneğine basın. - + Hint İpucu - + Delete (middle mousebutton) Sil (orta klik) - + Delete selection (middle mousebutton) Seçimi sil (orta fare düğmesi) - + Cut Kes - + Cut selection Seçimi Kes - + Merge Selection Seçimi Birleştir - + Copy Kopyala - + Copy selection Seçimi Kopyala - + Paste Yapıştır - + Mute/unmute (<%1> + middle click) Sesi kapat/sesi aç (<%1> + orta tıklama) - + Mute/unmute selection (<%1> + middle click) Seçimin sesini kapat/aç (<%1> + orta tıklama) - + Set clip color Klip rengini ayarla - + Use track color Parça rengini kullan diff --git a/data/locale/uk.ts b/data/locale/uk.ts index 0f48f9bcc7b..ff4061f5fe1 100644 --- a/data/locale/uk.ts +++ b/data/locale/uk.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! Відкрийте редатор автоматизації через контекстне меню регулятора! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Гра/Пауза поточної мелодії (Пробіл) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Зупинити програвання поточної мелодії (Пробіл) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip Редактор автоматизації - немає шаблону @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. Модель вже підключена до цього шаблону. - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> Тягніть контроль утримуючи <%1> - AutomationPatternView + AutomationClipView - + Open in Automation editor Відкрити в редакторі автоматизації - + Clear Очистити - + Reset name Скинути назву - + Change name Перейменувати - + Set/clear record Встановити/очистити запис - + Flip Vertically (Visible) Перевернути вертикально (Видиме) - + Flip Horizontally (Visible) Перевернути горизонтально (Видиме) - + %1 Connections З'єднання %1 - + Disconnect "%1" Від'єднати «%1» - - Model is already connected to this pattern. + + Model is already connected to this clip. Модель вже підключена до цього шаблону. @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor Відкрити в редакторі ритму і басу - + Reset name Скинути назву - + Change name Перейменувати @@ -9569,44 +9569,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll Відкрити в редакторі нот - + Set as ghost in piano-roll - + Clear all notes Очистити всі ноти - + Reset name Скинути назву - + Change name Перейменувати - + Add steps Додати такти - + Remove steps Видалити такти - + Clone Steps Клонувати такти @@ -9867,7 +9867,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! Відкрийте шаблон за допомогою подвійного клацання мишею! @@ -9881,7 +9881,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) Гра/Пауза поточної мелодії (Пробіл) @@ -9901,7 +9901,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) Зупинити програвання поточної мелодії (Пробіл) @@ -9951,13 +9951,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10074,48 +10074,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip Нотний редактор - без шаблону - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12026,69 +12026,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) Видалити (середня кнопка мишки) - + Delete selection (middle mousebutton) - + Cut Вирізати - + Cut selection - + Copy Копіювати - + Copy selection - + Paste Вставити - + Mute/unmute (<%1> + middle click) Заглушити/включити (<%1> + середня кнопка миші) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample Перевернути запис - + Set clip color - + Use track color @@ -13328,103 +13328,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute Тиша - TrackContentObjectView + ClipView - + Current position Позиція - + Current length Тривалість - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (від %3:%4 до %5:%6) - + Press <%1> and drag to make a copy. Натисніть <%1> і перетягніть, щоб створити копію. - + Press <%1> for free resizing. Для вільної зміни розміру натисніть <%1>. - + Hint Підказка - + Delete (middle mousebutton) Видалити (середня кнопка мишки) - + Delete selection (middle mousebutton) - + Cut Вирізати - + Cut selection - + Merge Selection - + Copy Копіювати - + Copy selection - + Paste Вставити - + Mute/unmute (<%1> + middle click) Заглушити/включити (<%1> + середня кнопка миші) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/zh_CN.ts b/data/locale/zh_CN.ts index 170ece65e76..d7e5632afe8 100644 --- a/data/locale/zh_CN.ts +++ b/data/locale/zh_CN.ts @@ -405,7 +405,7 @@ Zixing Liu <liushuyu at aosc.xyz> - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! 请使用控制的上下文菜单打开一个自动控制样式! @@ -413,12 +413,12 @@ Zixing Liu <liushuyu at aosc.xyz> AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 播放/暂停当前片段(空格) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 停止当前片段(空格) @@ -509,7 +509,7 @@ Zixing Liu <liushuyu at aosc.xyz> - Automation Editor - no pattern + Automation Editor - no clip 自动控制编辑器 - 没有片段 @@ -520,68 +520,68 @@ Zixing Liu <liushuyu at aosc.xyz> - Model is already connected to this pattern. + Model is already connected to this clip. 模型已连接到此片段。 - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> 按住<%1>拖动控制器 - AutomationPatternView + AutomationClipView - + Open in Automation editor 在自动编辑器(Automation editor)中打开 - + Clear 清除 - + Reset name 重置名称 - + Change name 修改名称 - + Set/clear record 设置/清除录制 - + Flip Vertically (Visible) 垂直翻转 (可见) - + Flip Horizontally (Visible) 水平翻转 (可见) - + %1 Connections %1个连接 - + Disconnect "%1" 断开“%1”的连接 - - Model is already connected to this pattern. + + Model is already connected to this clip. 模型已连接到此片段。 @@ -627,7 +627,7 @@ Zixing Liu <liushuyu at aosc.xyz> - Clone beat/bassline pattern + Clone beat/bassline clip @@ -657,19 +657,19 @@ Zixing Liu <liushuyu at aosc.xyz> - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor 在节拍+Bassline编辑器中打开 - + Reset name 重置名称 - + Change name 修改名称 @@ -9579,44 +9579,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll 在钢琴窗中打开 - + Set as ghost in piano-roll - + Clear all notes 清除所有音符 - + Reset name 重置名称 - + Change name 修改名称 - + Add steps 添加音阶 - + Remove steps 移除音阶 - + Clone Steps 复制音阶 @@ -9877,7 +9877,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! 双击打开片段! @@ -9891,7 +9891,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 播放/暂停当前片段(空格) @@ -9911,7 +9911,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 停止当前片段(空格) @@ -9961,13 +9961,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10084,48 +10084,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip 钢琴窗 - 没有片段 - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12036,69 +12036,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) 删除 (鼠标中键) - + Delete selection (middle mousebutton) - + Cut 剪切 - + Cut selection - + Copy 复制 - + Copy selection - + Paste 粘贴 - + Mute/unmute (<%1> + middle click) 静音/取消静音 (<%1> + 鼠标中键) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample 反转采样 - + Set clip color - + Use track color @@ -13338,103 +13338,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute 静音 - TrackContentObjectView + ClipView - + Current position 当前位置 - + Current length 当前长度 - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 到 %5:%6) - + Press <%1> and drag to make a copy. 按住 <%1> 并拖动以创建副本。 - + Press <%1> for free resizing. 按住 <%1> 自由调整大小。 - + Hint 提示 - + Delete (middle mousebutton) 删除 (鼠标中键) - + Delete selection (middle mousebutton) - + Cut 剪切 - + Cut selection - + Merge Selection - + Copy 复制 - + Copy selection - + Paste 粘贴 - + Mute/unmute (<%1> + middle click) 静音/取消静音 (<%1> + 鼠标中键) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/locale/zh_TW.ts b/data/locale/zh_TW.ts index fa0e21875fa..45c9436c03e 100644 --- a/data/locale/zh_TW.ts +++ b/data/locale/zh_TW.ts @@ -396,7 +396,7 @@ If you're interested in translating LMMS in another language or want to imp - Please open an automation pattern with the context menu of a control! + Please open an automation clip with the context menu of a control! 請透過控制的右鍵選單開啟自動控制模式! @@ -404,12 +404,12 @@ If you're interested in translating LMMS in another language or want to imp AutomationEditorWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 播放/暫停當前片段(空格) - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 停止當前片段(空格) @@ -500,7 +500,7 @@ If you're interested in translating LMMS in another language or want to imp - Automation Editor - no pattern + Automation Editor - no clip 自動控制編輯器 - 沒有片段 @@ -511,68 +511,68 @@ If you're interested in translating LMMS in another language or want to imp - Model is already connected to this pattern. + Model is already connected to this clip. 模型已連接到此片段。 - AutomationPattern + AutomationClip - + Drag a control while pressing <%1> 按住<%1>拖動控制器 - AutomationPatternView + AutomationClipView - + Open in Automation editor 在自動編輯器(Automation editor)中打開 - + Clear 清除 - + Reset name 重置名稱 - + Change name 修改名稱 - + Set/clear record 設置/清除錄製 - + Flip Vertically (Visible) 垂直翻轉 (可見) - + Flip Horizontally (Visible) 水平翻轉 (可見) - + %1 Connections %1個連接 - + Disconnect "%1" 斷開“%1”的連接 - - Model is already connected to this pattern. + + Model is already connected to this clip. 模型已連接到此片段。 @@ -618,7 +618,7 @@ If you're interested in translating LMMS in another language or want to imp - Clone beat/bassline pattern + Clone beat/bassline clip @@ -648,19 +648,19 @@ If you're interested in translating LMMS in another language or want to imp - BBTCOView + BBClipView - + Open in Beat+Bassline-Editor 在節拍+Bassline編輯器中打開 - + Reset name 重置名稱 - + Change name 修改名稱 @@ -9569,44 +9569,44 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - PatternView + MidiClipView - + Open in piano-roll 在鋼琴窗中打開 - + Set as ghost in piano-roll - + Clear all notes 清除所有音符 - + Reset name 重置名稱 - + Change name 修改名稱 - + Add steps 添加音階 - + Remove steps 移除音階 - + Clone Steps @@ -9867,7 +9867,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Please open a pattern by double-clicking on it! + Please open a clip by double-clicking on it! 雙擊打開片段! @@ -9881,7 +9881,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. PianoRollWindow - Play/pause current pattern (Space) + Play/pause current clip (Space) 播放/暫停當前片段(空格) @@ -9901,7 +9901,7 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Stop playing of current pattern (Space) + Stop playing of current clip (Space) 停止當前片段(空格) @@ -9951,13 +9951,13 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Import pattern + Import clip - Export pattern + Export clip @@ -10074,48 +10074,48 @@ Please visit http://lmms.sf.net/wiki for documentation on LMMS. - Piano-Roll - no pattern + Piano-Roll - no clip 鋼琴窗 - 沒有片段 - XML pattern file (*.xpt *.xptz) + XML clip file (*.xpt *.xptz) - Export pattern success + Export clip success - Pattern saved to %1 + Clip saved to %1 - Import pattern. + Import clip. - You are about to import a pattern, this will overwrite your current pattern. Do you want to continue? + You are about to import a clip, this will overwrite your current clip. Do you want to continue? - Open pattern + Open clip - Import pattern success + Import clip success - Imported pattern %1! + Imported clip %1! @@ -12026,69 +12026,69 @@ You can disable these checks to get a faster scanning time (at your own risk). - SampleTCOView + SampleClipView - + Double-click to open sample - + Delete (middle mousebutton) 刪除 (鼠標中鍵) - + Delete selection (middle mousebutton) - + Cut 剪切 - + Cut selection - + Copy 複製 - + Copy selection - + Paste 粘貼 - + Mute/unmute (<%1> + middle click) 靜音/取消靜音 (<%1> + 鼠標中鍵) - + Mute/unmute selection (<%1> + middle click) - + Reverse sample 反轉取樣 - + Set clip color - + Use track color @@ -13328,103 +13328,103 @@ Please make sure you have read-permission to the file and the directory containi - TrackContentObject + Clip - + Mute 靜音 - TrackContentObjectView + ClipView - + Current position 當前位置 - + Current length 當前長度 - - + + %1:%2 (%3:%4 to %5:%6) %1:%2 (%3:%4 到 %5:%6) - + Press <%1> and drag to make a copy. 按住 <%1> 並拖動以創建副本。 - + Press <%1> for free resizing. 按住 <%1> 自由調整大小。 - + Hint 提示 - + Delete (middle mousebutton) 刪除 (鼠標中鍵) - + Delete selection (middle mousebutton) - + Cut 剪切 - + Cut selection - + Merge Selection - + Copy 複製 - + Copy selection - + Paste 粘貼 - + Mute/unmute (<%1> + middle click) 靜音/取消靜音 (<%1> + 鼠標中鍵) - + Mute/unmute selection (<%1> + middle click) - + Set clip color - + Use track color diff --git a/data/themes/classic/pat_rec.png b/data/themes/classic/clip_rec.png similarity index 100% rename from data/themes/classic/pat_rec.png rename to data/themes/classic/clip_rec.png diff --git a/data/themes/classic/clone_bb_track_pattern.png b/data/themes/classic/clone_bb_track_clip.png similarity index 100% rename from data/themes/classic/clone_bb_track_pattern.png rename to data/themes/classic/clone_bb_track_clip.png diff --git a/data/themes/classic/style.css b/data/themes/classic/style.css index 71adbf57657..fc2c28e5fe3 100644 --- a/data/themes/classic/style.css +++ b/data/themes/classic/style.css @@ -663,14 +663,14 @@ TrackContainerView QLabel background: none; } -/* Patterns */ +/* Clips */ -/* common pattern colors */ -TrackContentObjectView { +/* common clip colors */ +ClipView { qproperty-mutedColor: rgb( 128, 128, 128 ); qproperty-mutedBackgroundColor: rgb( 80, 80, 80 ); qproperty-selectedColor: rgb( 0, 125, 255 ); - qproperty-BBPatternBackground: rgb( 80, 80, 80 ); + qproperty-BBClipBackground: rgb( 80, 80, 80 ); qproperty-textColor: rgb( 255, 255, 255 ); qproperty-textBackgroundColor: rgba(0, 0, 0, 75); qproperty-textShadowColor: rgb( 0, 0, 0 ); @@ -682,8 +682,8 @@ TrackContentObjectView { font-size: 11px; } -/* instrument pattern */ -PatternView { +/* MIDI (instrument) clip */ +MidiClipView { background-color: rgb( 119, 199, 216 ); color: rgb( 187, 227, 236 ); @@ -693,20 +693,20 @@ PatternView { qproperty-mutedNoteBorderColor: rgb( 80, 80, 80 ); } -/* sample track pattern */ -SampleTCOView { +/* sample track clip */ +SampleClipView { background-color: rgba(42,51,59,255); color: #FF8F05; } -/* automation pattern */ -AutomationPatternView { +/* automation clip */ +AutomationClipView { background-color: #99afff; color: rgb( 204, 215, 255 ); } -/* bb-pattern */ -BBTCOView { +/* bb-clip */ +BBClipView { background-color: rgb( 128, 182, 175 ); /* default colour for bb-tracks */ } diff --git a/data/themes/default/pat_rec.png b/data/themes/default/clip_rec.png similarity index 100% rename from data/themes/default/pat_rec.png rename to data/themes/default/clip_rec.png diff --git a/data/themes/default/clone_bb_track_pattern.png b/data/themes/default/clone_bb_track_clip.png similarity index 100% rename from data/themes/default/clone_bb_track_pattern.png rename to data/themes/default/clone_bb_track_clip.png diff --git a/data/themes/default/style.css b/data/themes/default/style.css index 7ebced5b75e..87be1242f75 100644 --- a/data/themes/default/style.css +++ b/data/themes/default/style.css @@ -709,14 +709,14 @@ TrackContainerView QLabel background: none; } -/* Patterns */ +/* Clips */ -/* common pattern colors */ -TrackContentObjectView { +/* common clip colors */ +ClipView { qproperty-mutedColor: rgba(255,255,255,100); qproperty-mutedBackgroundColor: #373d48; qproperty-selectedColor: #006B65; - qproperty-BBPatternBackground: #373d48; + qproperty-BBClipBackground: #373d48; qproperty-textColor: #fff; qproperty-textBackgroundColor: rgba(0, 0, 0, 75); qproperty-textShadowColor: rgba(0,0,0,200); @@ -728,8 +728,8 @@ TrackContentObjectView { font-size: 11px; } -/* instrument pattern */ -PatternView { +/* MIDI (instrument) clip */ +MidiClipView { background-color: #21A14F; color: rgba(255,255,255,220); @@ -739,20 +739,20 @@ PatternView { qproperty-mutedNoteBorderColor: rgb(55, 61, 72); } -/* sample track pattern */ -SampleTCOView { +/* sample track clip */ +SampleClipView { background-color: rgba(42,51,59,255); color: #FF8F05; } -/* automation pattern */ -AutomationPatternView { +/* automation clip */ +AutomationClipView { background-color: #663DE1; color: rgba(255,255,255,90); } -/* bb-pattern */ -BBTCOView { +/* bb-clip */ +BBClipView { background-color: #20BDB2; /* default colour for bb-tracks */ } diff --git a/doc/wiki b/doc/wiki index 4feb6c9214d..0fc1e74e110 160000 --- a/doc/wiki +++ b/doc/wiki @@ -1 +1 @@ -Subproject commit 4feb6c9214d6adfab5c9fead5d8935589eea8dba +Subproject commit 0fc1e74e1109d87cf6cacfc46c7975f9b8c93bf5 diff --git a/include/AudioEngine.h b/include/AudioEngine.h index 93770ef728a..51cc05171b7 100644 --- a/include/AudioEngine.h +++ b/include/AudioEngine.h @@ -56,9 +56,6 @@ const int BYTES_PER_SURROUND_FRAME = sizeof( surroundSampleFrame ); const float OUTPUT_SAMPLE_MULTIPLIER = 32767.0f; -#include "PlayHandle.h" - - class AudioEngineWorkerThread; diff --git a/include/AutomationPattern.h b/include/AutomationClip.h similarity index 78% rename from include/AutomationPattern.h rename to include/AutomationClip.h index 61a8af41630..521fc1aac51 100644 --- a/include/AutomationPattern.h +++ b/include/AutomationClip.h @@ -1,6 +1,6 @@ /* - * AutomationPattern.h - declaration of class AutomationPattern, which contains - * all information about an automation pattern + * AutomationClip.h - declaration of class AutomationClip, which contains + * all information about an automation clip * * Copyright (c) 2008-2014 Tobias Doerffel * Copyright (c) 2006-2008 Javier Serrano Polo @@ -24,14 +24,14 @@ * */ -#ifndef AUTOMATION_PATTERN_H -#define AUTOMATION_PATTERN_H +#ifndef AUTOMATION_CLIP_H +#define AUTOMATION_CLIP_H #include #include #include "AutomationNode.h" -#include "TrackContentObject.h" +#include "Clip.h" class AutomationTrack; @@ -39,7 +39,7 @@ class TimePos; -class LMMS_EXPORT AutomationPattern : public TrackContentObject +class LMMS_EXPORT AutomationClip : public Clip { Q_OBJECT public: @@ -55,9 +55,9 @@ class LMMS_EXPORT AutomationPattern : public TrackContentObject using TimemapIterator = timeMap::const_iterator; - AutomationPattern( AutomationTrack * _auto_track ); - AutomationPattern( const AutomationPattern & _pat_to_copy ); - virtual ~AutomationPattern() = default; + AutomationClip( AutomationTrack * _auto_track ); + AutomationClip( const AutomationClip & _clip_to_copy ); + virtual ~AutomationClip() = default; bool addObject( AutomatableModel * _obj, bool _search_dup = true ); @@ -149,15 +149,15 @@ class LMMS_EXPORT AutomationPattern : public TrackContentObject void saveSettings( QDomDocument & _doc, QDomElement & _parent ) override; void loadSettings( const QDomElement & _this ) override; - static const QString classNodeName() { return "automationpattern"; } + static const QString classNodeName() { return "automationclip"; } QString nodeName() const override { return classNodeName(); } - TrackContentObjectView * createView( TrackView * _tv ) override; + ClipView * createView( TrackView * _tv ) override; static bool isAutomated( const AutomatableModel * _m ); - static QVector patternsForModel( const AutomatableModel * _m ); - static AutomationPattern * globalAutomationPattern( AutomatableModel * _m ); + static QVector clipsForModel( const AutomatableModel * _m ); + static AutomationClip * globalAutomationClip( AutomatableModel * _m ); static void resolveAllIDs(); bool isRecording() const { return m_isRecording; } @@ -179,9 +179,9 @@ public slots: void generateTangents(timeMap::iterator it, int numToGenerate); float valueAt( timeMap::const_iterator v, int offset ) const; - // Mutex to make methods involving automation patterns thread safe + // Mutex to make methods involving automation clips thread safe // Mutable so we can lock it from const objects - mutable QMutex m_patternMutex; + mutable QMutex m_clipMutex; AutomationTrack * m_autoTrack; QVector m_idsToResolve; @@ -204,40 +204,40 @@ public slots: static const float DEFAULT_MIN_VALUE; static const float DEFAULT_MAX_VALUE; - friend class AutomationPatternView; + friend class AutomationClipView; friend class AutomationNode; } ; -//Short-hand functions to access node values in an automation pattern; +//Short-hand functions to access node values in an automation clip; // replacement for CPP macros with the same purpose; could be refactored // further in the future. -inline float INVAL(AutomationPattern::TimemapIterator it) +inline float INVAL(AutomationClip::TimemapIterator it) { return it->getInValue(); } -inline float OUTVAL(AutomationPattern::TimemapIterator it) +inline float OUTVAL(AutomationClip::TimemapIterator it) { return it->getOutValue(); } -inline float OFFSET(AutomationPattern::TimemapIterator it) +inline float OFFSET(AutomationClip::TimemapIterator it) { return it->getValueOffset(); } -inline float INTAN(AutomationPattern::TimemapIterator it) +inline float INTAN(AutomationClip::TimemapIterator it) { return it->getInTangent(); } -inline float OUTTAN(AutomationPattern::TimemapIterator it) +inline float OUTTAN(AutomationClip::TimemapIterator it) { return it->getOutTangent(); } -inline int POS(AutomationPattern::TimemapIterator it) +inline int POS(AutomationClip::TimemapIterator it) { return it.key(); } diff --git a/include/AutomationPatternView.h b/include/AutomationClipView.h similarity index 76% rename from include/AutomationPatternView.h rename to include/AutomationClipView.h index 5e7b12977af..61e02889988 100644 --- a/include/AutomationPatternView.h +++ b/include/AutomationClipView.h @@ -1,5 +1,5 @@ /* - * AutomationPatternView.h - declaration of class AutomationPatternView + * AutomationClipView.h - declaration of class AutomationClipView * * Copyright (c) 2008-2010 Tobias Doerffel * @@ -22,28 +22,28 @@ * */ -#ifndef AUTOMATION_PATTERN_VIEW_H -#define AUTOMATION_PATTERN_VIEW_H +#ifndef AUTOMATION_CLIP_VIEW_H +#define AUTOMATION_CLIP_VIEW_H #include -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "Song.h" #include "SongEditor.h" -#include "TrackContentObjectView.h" +#include "ClipView.h" -class AutomationPatternView : public TrackContentObjectView +class AutomationClipView : public ClipView { Q_OBJECT public: - AutomationPatternView( AutomationPattern * _pat, TrackView * _parent ); - virtual ~AutomationPatternView(); + AutomationClipView( AutomationClip * _clip, TrackView * _parent ); + virtual ~AutomationClipView(); public slots: - /// Opens this view's pattern in the global automation editor + /// Opens this view's clip in the global automation editor void openInAutomationEditor(); void update() override; @@ -65,12 +65,12 @@ protected slots: private: - AutomationPattern * m_pat; + AutomationClip * m_clip; QPixmap m_paintPixmap; QStaticText m_staticTextName; - static QPixmap * s_pat_rec; + static QPixmap * s_clip_rec; void scaleTimemapToFit( float oldMin, float oldMax ); } ; diff --git a/include/AutomationEditor.h b/include/AutomationEditor.h index e11600c71f2..4be2756aa7a 100644 --- a/include/AutomationEditor.h +++ b/include/AutomationEditor.h @@ -34,7 +34,7 @@ #include "lmms_basics.h" #include "JournallingObject.h" #include "TimePos.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "ComboBoxModel.h" #include "Knob.h" @@ -61,16 +61,16 @@ class AutomationEditor : public QWidget, public JournallingObject Q_PROPERTY(QColor crossColor MEMBER m_crossColor) Q_PROPERTY(QColor backgroundShade MEMBER m_backgroundShade) public: - void setCurrentPattern(AutomationPattern * new_pattern); + void setCurrentClip(AutomationClip * new_clip); - inline const AutomationPattern * currentPattern() const + inline const AutomationClip * currentClip() const { - return m_pattern; + return m_clip; } - inline bool validPattern() const + inline bool validClip() const { - return m_pattern != nullptr; + return m_clip != nullptr; } void saveSettings(QDomDocument & doc, QDomElement & parent) override; @@ -89,11 +89,11 @@ class AutomationEditor : public QWidget, public JournallingObject public slots: void update(); - void updateAfterPatternChange(); + void updateAfterClipChange(); protected: - typedef AutomationPattern::timeMap timeMap; + typedef AutomationClip::timeMap timeMap; void keyPressEvent(QKeyEvent * ke) override; void leaveEvent(QEvent * e) override; @@ -125,7 +125,7 @@ protected slots: void setEditMode(AutomationEditor::EditModes mode); void setEditMode(int mode); - void setProgressionType(AutomationPattern::ProgressionTypes type); + void setProgressionType(AutomationClip::ProgressionTypes type); void setProgressionType(int type); void setTension(); @@ -134,7 +134,7 @@ protected slots: void zoomingXChanged(); void zoomingYChanged(); - /// Updates the pattern's quantization using the current user selected value. + /// Updates the clip's quantization using the current user selected value. void setQuantization(); private: @@ -178,7 +178,7 @@ protected slots: FloatModel * m_tensionModel; - AutomationPattern * m_pattern; + AutomationClip * m_clip; float m_minLevel; float m_maxLevel; float m_step; @@ -234,7 +234,7 @@ protected slots: signals: - void currentPatternChanged(); + void currentClipChanged(); void positionChanged( const TimePos & ); } ; @@ -251,23 +251,23 @@ class AutomationEditorWindow : public Editor AutomationEditorWindow(); ~AutomationEditorWindow(); - void setCurrentPattern(AutomationPattern* pattern); - const AutomationPattern* currentPattern(); + void setCurrentClip(AutomationClip* clip); + const AutomationClip* currentClip(); void dropEvent( QDropEvent * _de ) override; void dragEnterEvent( QDragEnterEvent * _dee ) override; - void open(AutomationPattern* pattern); + void open(AutomationClip* clip); AutomationEditor* m_editor; QSize sizeHint() const override; public slots: - void clearCurrentPattern(); + void clearCurrentClip(); signals: - void currentPatternChanged(); + void currentClipChanged(); protected: void focusInEvent(QFocusEvent * event) override; diff --git a/include/AutomationNode.h b/include/AutomationNode.h index 0dbb4c649f2..6cd44566238 100644 --- a/include/AutomationNode.h +++ b/include/AutomationNode.h @@ -26,18 +26,18 @@ #ifndef AUTOMATION_NODE_H #define AUTOMATION_NODE_H -class AutomationPattern; +class AutomationClip; -// Note: We use the default copy-assignment on the AutomationPattern constructor. It's +// Note: We use the default copy-assignment on the AutomationClip constructor. It's // fine for now as we don't have dynamic allocated members, but if any are added we should // have an user-defined one to perform a deep-copy. class AutomationNode { public: AutomationNode(); // Dummy constructor for the QMap - AutomationNode(AutomationPattern* pat, float value, int pos); - AutomationNode(AutomationPattern* pat, float inValue, float outValue, int pos); + AutomationNode(AutomationClip* clip, float value, int pos); + AutomationNode(AutomationClip* clip, float inValue, float outValue, int pos); AutomationNode& operator+=(float f) { @@ -123,18 +123,18 @@ class AutomationNode } /** - * @brief Sets the pattern this node belongs to - * @param AutomationPattern* pattern that m_pattern will be + * @brief Sets the clip this node belongs to + * @param AutomationClip* clip that m_clip will be * set to */ - inline void setPattern(AutomationPattern* pat) + inline void setClip(AutomationClip* clip) { - m_pattern = pat; + m_clip = clip; } private: - // Pattern that this node belongs to - AutomationPattern* m_pattern; + // Clip that this node belongs to + AutomationClip* m_clip; // Time position of this node (matches the timeMap key) int m_pos; diff --git a/include/AutomationTrack.h b/include/AutomationTrack.h index ee55c31acd8..dc33f76c3c9 100644 --- a/include/AutomationTrack.h +++ b/include/AutomationTrack.h @@ -38,7 +38,7 @@ class AutomationTrack : public Track virtual ~AutomationTrack() = default; virtual bool play( const TimePos & _start, const fpp_t _frames, - const f_cnt_t _frame_base, int _tco_num = -1 ) override; + const f_cnt_t _frame_base, int _clip_num = -1 ) override; QString nodeName() const override { @@ -46,7 +46,7 @@ class AutomationTrack : public Track } TrackView * createView( TrackContainerView* ) override; - TrackContentObject* createTCO(const TimePos & pos) override; + Clip* createClip(const TimePos & pos) override; virtual void saveTrackSpecificSettings( QDomDocument & _doc, QDomElement & _parent ) override; diff --git a/include/BBTCO.h b/include/BBClip.h similarity index 79% rename from include/BBTCO.h rename to include/BBClip.h index 8a0ba49bd3e..5c62e66ae2f 100644 --- a/include/BBTCO.h +++ b/include/BBClip.h @@ -1,5 +1,5 @@ /* - * BBTCO.h + * BBClip.h * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -23,31 +23,31 @@ */ -#ifndef BB_TCO_H -#define BB_TCO_H +#ifndef BB_CLIP_H +#define BB_CLIP_H -#include "TrackContentObjectView.h" +#include "ClipView.h" -class BBTCO : public TrackContentObject +class BBClip : public Clip { public: - BBTCO( Track * _track ); - virtual ~BBTCO() = default; + BBClip( Track * _track ); + virtual ~BBClip() = default; void saveSettings( QDomDocument & _doc, QDomElement & _parent ) override; void loadSettings( const QDomElement & _this ) override; inline QString nodeName() const override { - return( "bbtco" ); + return( "bbclip" ); } int bbTrackIndex(); - TrackContentObjectView * createView( TrackView * _tv ) override; + ClipView * createView( TrackView * _tv ) override; private: - friend class BBTCOView; + friend class BBClipView; } ; diff --git a/include/BBTCOView.h b/include/BBClipView.h similarity index 84% rename from include/BBTCOView.h rename to include/BBClipView.h index 13c65ba5873..a779ca68066 100644 --- a/include/BBTCOView.h +++ b/include/BBClipView.h @@ -1,5 +1,5 @@ /* - * BBTCOView.h + * BBClipView.h * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -23,20 +23,20 @@ */ -#ifndef BB_TCO_VIEW_H -#define BB_TCO_VIEW_H +#ifndef BB_CLIP_VIEW_H +#define BB_CLIP_VIEW_H -#include "BBTCO.h" +#include "BBClip.h" #include -class BBTCOView : public TrackContentObjectView +class BBClipView : public ClipView { Q_OBJECT public: - BBTCOView( TrackContentObject * _tco, TrackView * _tv ); - virtual ~BBTCOView() = default; + BBClipView( Clip * _clip, TrackView * _tv ); + virtual ~BBClipView() = default; public slots: @@ -55,7 +55,7 @@ protected slots: private: - BBTCO * m_bbTCO; + BBClip * m_bbClip; QPixmap m_paintPixmap; QStaticText m_staticTextName; diff --git a/include/BBEditor.h b/include/BBEditor.h index d02dc198b64..e13097e59b1 100644 --- a/include/BBEditor.h +++ b/include/BBEditor.h @@ -71,7 +71,7 @@ class BBTrackContainerView : public TrackContainerView public: BBTrackContainerView(BBTrackContainer* tc); - bool fixedTCOs() const override + bool fixedClips() const override { return true; } @@ -87,7 +87,7 @@ public slots: void removeSteps(); void addSampleTrack(); void addAutomationTrack(); - void clonePattern(); + void cloneClip(); protected slots: void dropEvent(QDropEvent * de ) override; diff --git a/include/BBTrack.h b/include/BBTrack.h index da578ffc8d1..c07c8a90e22 100644 --- a/include/BBTrack.h +++ b/include/BBTrack.h @@ -30,7 +30,7 @@ #include -#include "BBTCOView.h" +#include "BBClipView.h" #include "Track.h" class TrackLabelButton; @@ -45,9 +45,9 @@ class LMMS_EXPORT BBTrack : public Track virtual ~BBTrack(); virtual bool play( const TimePos & _start, const fpp_t _frames, - const f_cnt_t _frame_base, int _tco_num = -1 ) override; + const f_cnt_t _frame_base, int _clip_num = -1 ) override; TrackView * createView( TrackContainerView* tcv ) override; - TrackContentObject* createTCO(const TimePos & pos) override; + Clip* createClip(const TimePos & pos) override; virtual void saveTrackSpecificSettings( QDomDocument & _doc, QDomElement & _parent ) override; diff --git a/include/BBTrackContainer.h b/include/BBTrackContainer.h index 79bf2e31565..dac67a39d23 100644 --- a/include/BBTrackContainer.h +++ b/include/BBTrackContainer.h @@ -38,7 +38,7 @@ class LMMS_EXPORT BBTrackContainer : public TrackContainer BBTrackContainer(); virtual ~BBTrackContainer(); - virtual bool play(TimePos start, const fpp_t frames, const f_cnt_t frameBase, int tcoNum = -1); + virtual bool play(TimePos start, const fpp_t frames, const f_cnt_t frameBase, int clipNum = -1); void updateAfterTrackAdd() override; @@ -57,11 +57,11 @@ class LMMS_EXPORT BBTrackContainer : public TrackContainer void swapBB(int bb1, int bb2); - void updateBBTrack(TrackContentObject * tco); + void updateBBTrack(Clip * clip); void fixIncorrectPositions(); - void createTCOsForBB(int bb); + void createClipsForBB(int bb); - AutomatedValueMap automatedValuesAt(TimePos time, int tcoNum) const override; + AutomatedValueMap automatedValuesAt(TimePos time, int clipNum) const override; public slots: void play(); diff --git a/include/TrackContentObject.h b/include/Clip.h similarity index 83% rename from include/TrackContentObject.h rename to include/Clip.h index 3945c0ac33b..836e7cc9ce4 100644 --- a/include/TrackContentObject.h +++ b/include/Clip.h @@ -1,5 +1,5 @@ /* - * TrackConteintObject.h - declaration of TrackContentObject class + * TrackConteintObject.h - declaration of Clip class * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -32,20 +32,20 @@ class Track; -class TrackContentObjectView; +class ClipView; class TrackContainer; class TrackView; -class LMMS_EXPORT TrackContentObject : public Model, public JournallingObject +class LMMS_EXPORT Clip : public Model, public JournallingObject { Q_OBJECT MM_OPERATORS mapPropertyFromModel(bool,isMuted,setMuted,m_mutedModel); mapPropertyFromModel(bool,isSolo,setSolo,m_soloModel); public: - TrackContentObject( Track * track ); - virtual ~TrackContentObject(); + Clip( Track * track ); + virtual ~Clip(); inline Track * getTrack() const { @@ -117,7 +117,7 @@ class LMMS_EXPORT TrackContentObject : public Model, public JournallingObject virtual void movePosition( const TimePos & pos ); virtual void changeLength( const TimePos & length ); - virtual TrackContentObjectView * createView( TrackView * tv ) = 0; + virtual ClipView * createView( TrackView * tv ) = 0; inline void selectViewOnCreate( bool select ) { @@ -130,13 +130,13 @@ class LMMS_EXPORT TrackContentObject : public Model, public JournallingObject } /// Returns true if and only if a->startPosition() < b->startPosition() - static bool comparePosition(const TrackContentObject* a, const TrackContentObject* b); + static bool comparePosition(const Clip* a, const Clip* b); TimePos startTimeOffset() const; void setStartTimeOffset( const TimePos &startTimeOffset ); - // Will copy the state of a TCO to another TCO - static void copyStateTo( TrackContentObject *src, TrackContentObject *dst ); + // Will copy the state of a clip to another clip + static void copyStateTo( Clip *src, Clip *dst ); public slots: void toggleMute(); @@ -145,7 +145,7 @@ public slots: signals: void lengthChanged(); void positionChanged(); - void destroyedTCO(); + void destroyedClip(); void colorChanged(); @@ -173,7 +173,7 @@ public slots: QColor m_color; bool m_useCustomClipColor; - friend class TrackContentObjectView; + friend class ClipView; } ; diff --git a/include/TrackContentObjectView.h b/include/ClipView.h similarity index 74% rename from include/TrackContentObjectView.h rename to include/ClipView.h index 5f823eb6f99..d9fb520c8ba 100644 --- a/include/TrackContentObjectView.h +++ b/include/ClipView.h @@ -1,5 +1,5 @@ /* - * TrackContentObjectView.h - declaration of TrackContentObjectView class + * ClipView.h - declaration of ClipView class * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -30,7 +30,7 @@ #include "ModelView.h" #include "Rubberband.h" -#include "TrackContentObject.h" +#include "Clip.h" class QMenu; @@ -38,11 +38,11 @@ class QContextMenuEvent; class DataFile; class TextFloat; -class TrackContentObject; +class Clip; class TrackView; -class TrackContentObjectView : public selectableObject, public ModelView +class ClipView : public selectableObject, public ModelView { Q_OBJECT @@ -53,7 +53,7 @@ class TrackContentObjectView : public selectableObject, public ModelView Q_PROPERTY( QColor textColor READ textColor WRITE setTextColor ) Q_PROPERTY( QColor textBackgroundColor READ textBackgroundColor WRITE setTextBackgroundColor ) Q_PROPERTY( QColor textShadowColor READ textShadowColor WRITE setTextShadowColor ) - Q_PROPERTY( QColor BBPatternBackground READ BBPatternBackground WRITE setBBPatternBackground ) + Q_PROPERTY( QColor BBClipBackground READ BBClipBackground WRITE setBBClipBackground ) Q_PROPERTY( bool gradient READ gradient WRITE setGradient ) // We have to use a QSize here because using QPoint isn't supported. // width -> x, height -> y @@ -61,14 +61,14 @@ class TrackContentObjectView : public selectableObject, public ModelView Q_PROPERTY( QSize mouseHotspotKnife MEMBER m_mouseHotspotKnife ) public: - TrackContentObjectView( TrackContentObject * tco, TrackView * tv ); - virtual ~TrackContentObjectView(); + ClipView( Clip * clip, TrackView * tv ); + virtual ~ClipView(); - bool fixedTCOs(); + bool fixedClips(); - inline TrackContentObject * getTrackContentObject() + inline Clip * getClip() { - return m_tco; + return m_clip; } inline TrackView * getTrackView() @@ -83,7 +83,7 @@ class TrackContentObjectView : public selectableObject, public ModelView QColor textColor() const; QColor textBackgroundColor() const; QColor textShadowColor() const; - QColor BBPatternBackground() const; + QColor BBClipBackground() const; bool gradient() const; void setMutedColor( const QColor & c ); void setMutedBackgroundColor( const QColor & c ); @@ -91,30 +91,30 @@ class TrackContentObjectView : public selectableObject, public ModelView void setTextColor( const QColor & c ); void setTextBackgroundColor( const QColor & c ); void setTextShadowColor( const QColor & c ); - void setBBPatternBackground( const QColor & c ); + void setBBClipBackground( const QColor & c ); void setGradient( const bool & b ); // access needsUpdate member variable bool needsUpdate(); void setNeedsUpdate( bool b ); - // Method to get a QVector of TCOs to be affected by a context menu action - QVector getClickedTCOs(); + // Method to get a QVector of Clips to be affected by a context menu action + QVector getClickedClips(); - // Methods to remove, copy, cut, paste and mute a QVector of TCO views - void copy( QVector tcovs ); - void cut( QVector tcovs ); + // Methods to remove, copy, cut, paste and mute a QVector of Clip views + void copy( QVector clipvs ); + void cut( QVector clipvs ); void paste(); // remove and toggleMute are static because they don't depend - // being called from a particular TCO view, but can be called anywhere as long - // as a valid TCO view list is given, while copy/cut require an instance for + // being called from a particular Clip view, but can be called anywhere as long + // as a valid Clip view list is given, while copy/cut require an instance for // some metadata to be written to the clipboard. - static void remove( QVector tcovs ); - static void toggleMute( QVector tcovs ); - static void mergeTCOs(QVector tcovs); + static void remove( QVector clipvs ); + static void toggleMute( QVector clipvs ); + static void mergeClips(QVector clipvs); // Returns true if selection can be merged and false if not - static bool canMergeSelection(QVector tcovs); + static bool canMergeSelection(QVector clipvs); QColor getColorForDisplay( QColor ); @@ -142,8 +142,8 @@ public slots: }; TrackView * m_trackView; - TimePos m_initialTCOPos; - TimePos m_initialTCOEnd; + TimePos m_initialClipPos; + TimePos m_initialClipEnd; bool m_marker = false; int m_markerPos = 0; @@ -171,7 +171,7 @@ public slots: float pixelsPerBar(); - DataFile createTCODataFiles(const QVector & tcos) const; + DataFile createClipDataFiles(const QVector & clips) const; virtual void paintTextLabel(QString const & text, QPainter & painter); @@ -196,7 +196,7 @@ protected slots: static TextFloat * s_textFloat; - TrackContentObject * m_tco; + Clip * m_clip; Actions m_action; QPoint m_initialMousePos; QPoint m_initialMouseGlobalPos; @@ -211,7 +211,7 @@ protected slots: QColor m_textColor; QColor m_textBackgroundColor; QColor m_textShadowColor; - QColor m_BBPatternBackground; + QColor m_BBClipBackground; bool m_gradient; QSize m_mouseHotspotHand; // QSize must be used because QPoint QSize m_mouseHotspotKnife; // isn't supported by property system @@ -224,17 +224,17 @@ protected slots: { m_initialMousePos = pos; m_initialMouseGlobalPos = mapToGlobal( pos ); - m_initialTCOPos = m_tco->startPosition(); - m_initialTCOEnd = m_initialTCOPos + m_tco->length(); + m_initialClipPos = m_clip->startPosition(); + m_initialClipEnd = m_initialClipPos + m_clip->length(); } void setInitialOffsets(); bool mouseMovedDistance( QMouseEvent * me, int distance ); - TimePos draggedTCOPos( QMouseEvent * me ); + TimePos draggedClipPos( QMouseEvent * me ); int knifeMarkerPos( QMouseEvent * me ); void setColor(const QColor* color); - //! Return true iff TCO could be split. Currently only implemented for samples - virtual bool splitTCO( const TimePos pos ){ return false; }; + //! Return true iff the clip could be split. Currently only implemented for samples + virtual bool splitClip( const TimePos pos ){ return false; }; void updateCursor(QMouseEvent * me); } ; diff --git a/include/Clipboard.h b/include/Clipboard.h index 5aa03d8d842..f78e143211e 100644 --- a/include/Clipboard.h +++ b/include/Clipboard.h @@ -1,5 +1,5 @@ /* - * Clipboard.h - the clipboard for patterns, notes etc. + * Clipboard.h - the clipboard for clips, notes etc. * * Copyright (c) 2004-2009 Tobias Doerffel * diff --git a/include/DataFile.h b/include/DataFile.h index 6a983b3b177..4050b1772d1 100644 --- a/include/DataFile.h +++ b/include/DataFile.h @@ -53,7 +53,7 @@ class LMMS_EXPORT DataFile : public QDomDocument ClipboardData, JournalData, EffectSettings, - NotePattern, + MidiClip, TypeCount } ; typedef Types Type; diff --git a/include/InlineAutomation.h b/include/InlineAutomation.h index 9fd8362ccc6..1ce486fded9 100644 --- a/include/InlineAutomation.h +++ b/include/InlineAutomation.h @@ -26,7 +26,7 @@ #define INLINE_AUTOMATION_H #include "AutomationNode.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "shared_object.h" @@ -36,15 +36,15 @@ class InlineAutomation : public FloatModel, public sharedObject InlineAutomation() : FloatModel(), sharedObject(), - m_autoPattern( nullptr ) + m_autoClip( nullptr ) { } virtual ~InlineAutomation() { - if( m_autoPattern ) + if( m_autoClip ) { - delete m_autoPattern; + delete m_autoClip; } } @@ -52,16 +52,16 @@ class InlineAutomation : public FloatModel, public sharedObject bool hasAutomation() const { - if( m_autoPattern != nullptr && m_autoPattern->getTimeMap().isEmpty() == false ) + if( m_autoClip != nullptr && m_autoClip->getTimeMap().isEmpty() == false ) { // Prevent saving inline automation if there's just one node at the beginning of - // the pattern, which has a InValue equal to the value of model (which is going + // the clip, which has a InValue equal to the value of model (which is going // to be saved anyways) and no offset between the InValue and OutValue - AutomationPattern::timeMap::const_iterator firstNode = - m_autoPattern->getTimeMap().begin(); + AutomationClip::timeMap::const_iterator firstNode = + m_autoClip->getTimeMap().begin(); if (isAtInitValue() - && m_autoPattern->getTimeMap().size() == 1 + && m_autoClip->getTimeMap().size() == 1 && POS(firstNode) == 0 && INVAL(firstNode) == value() && OFFSET(firstNode) == 0) @@ -75,14 +75,14 @@ class InlineAutomation : public FloatModel, public sharedObject return false; } - AutomationPattern * automationPattern() + AutomationClip * automationClip() { - if( m_autoPattern == nullptr ) + if( m_autoClip == nullptr ) { - m_autoPattern = new AutomationPattern( nullptr ); - m_autoPattern->addObject( this ); + m_autoClip = new AutomationClip( nullptr ); + m_autoClip->addObject( this ); } - return m_autoPattern; + return m_autoClip; } void saveSettings( QDomDocument & _doc, QDomElement & _parent ) override; @@ -90,7 +90,7 @@ class InlineAutomation : public FloatModel, public sharedObject private: - AutomationPattern * m_autoPattern; + AutomationClip * m_autoClip; } ; diff --git a/include/InstrumentTrack.h b/include/InstrumentTrack.h index a39b2db6522..252c59603c4 100644 --- a/include/InstrumentTrack.h +++ b/include/InstrumentTrack.h @@ -111,12 +111,12 @@ class LMMS_EXPORT InstrumentTrack : public Track, public MidiEventProcessor // play everything in given frame-range - creates note-play-handles virtual bool play( const TimePos & _start, const fpp_t _frames, - const f_cnt_t _frame_base, int _tco_num = -1 ) override; + const f_cnt_t _frame_base, int _clip_num = -1 ) override; // create new view for me TrackView * createView( TrackContainerView* tcv ) override; - // create new track-content-object = pattern - TrackContentObject* createTCO(const TimePos & pos) override; + // create new track-content-object = clip + Clip* createClip(const TimePos & pos) override; // called by track diff --git a/include/Pattern.h b/include/MidiClip.h similarity index 72% rename from include/Pattern.h rename to include/MidiClip.h index 9d1697a989c..b39e366f509 100644 --- a/include/Pattern.h +++ b/include/MidiClip.h @@ -1,6 +1,6 @@ /* - * Pattern.h - declaration of class Pattern, which contains all information - * about a pattern + * MidiClip.h - declaration of class MidiClip, which contains all information + * about a clip * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -23,32 +23,32 @@ * */ -#ifndef PATTERN_H -#define PATTERN_H +#ifndef MIDI_CLIP_H +#define MIDI_CLIP_H #include #include "Note.h" -#include "PatternView.h" -#include "TrackContentObjectView.h" +#include "MidiClipView.h" +#include "ClipView.h" class InstrumentTrack; -class LMMS_EXPORT Pattern : public TrackContentObject +class LMMS_EXPORT MidiClip : public Clip { Q_OBJECT public: - enum PatternTypes + enum MidiClipTypes { - BeatPattern, - MelodyPattern + BeatClip, + MelodyClip } ; - Pattern( InstrumentTrack* instrumentTrack ); - Pattern( const Pattern& other ); - virtual ~Pattern(); + MidiClip( InstrumentTrack* instrumentTrack ); + MidiClip( const MidiClip& other ); + virtual ~MidiClip(); void init(); @@ -75,22 +75,23 @@ class LMMS_EXPORT Pattern : public TrackContentObject // Split the list of notes on the given position void splitNotes(NoteVector notes, TimePos pos); - // pattern-type stuff - inline PatternTypes type() const + // clip-type stuff + inline MidiClipTypes type() const { - return m_patternType; + return m_clipType; } // next/previous track based on position in the containing track - Pattern * previousPattern() const; - Pattern * nextPattern() const; + MidiClip * previousMidiClip() const; + MidiClip * nextMidiClip() const; // settings-management void saveSettings( QDomDocument & _doc, QDomElement & _parent ) override; void loadSettings( const QDomElement & _this ) override; inline QString nodeName() const override { + //TODO: rename to "midiClip" return "pattern"; } @@ -102,7 +103,7 @@ class LMMS_EXPORT Pattern : public TrackContentObject bool empty(); - TrackContentObjectView * createView( TrackView * _tv ) override; + ClipView * createView( TrackView * _tv ) override; using Model::dataChanged; @@ -121,29 +122,29 @@ protected slots: private: - TimePos beatPatternLength() const; + TimePos beatClipLength() const; - void setType( PatternTypes _new_pattern_type ); + void setType( MidiClipTypes _new_clip_type ); void checkType(); void resizeToFirstTrack(); InstrumentTrack * m_instrumentTrack; - PatternTypes m_patternType; + MidiClipTypes m_clipType; // data-stuff NoteVector m_notes; int m_steps; - Pattern * adjacentPatternByOffset(int offset) const; + MidiClip * adjacentMidiClipByOffset(int offset) const; - friend class PatternView; + friend class MidiClipView; friend class BBTrackContainerView; signals: - void destroyedPattern( Pattern* ); + void destroyedMidiClip( MidiClip* ); } ; diff --git a/include/PatternView.h b/include/MidiClipView.h similarity index 89% rename from include/PatternView.h rename to include/MidiClipView.h index 6c2243e72e6..179486bf08e 100644 --- a/include/PatternView.h +++ b/include/MidiClipView.h @@ -1,5 +1,5 @@ /* - * PatternView.h + * MidiClipView.h * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -22,22 +22,22 @@ * */ -#ifndef PATTERN_VIEW_H -#define PATTERN_VIEW_H +#ifndef MIDI_CLIP_VIEW_H +#define MIDI_CLIP_VIEW_H -#include "Pattern.h" -#include "TrackContentObjectView.h" +#include "MidiClip.h" +#include "ClipView.h" -class Pattern; +class MidiClip; -class PatternView : public TrackContentObjectView +class MidiClipView : public ClipView { Q_OBJECT public: - PatternView( Pattern* pattern, TrackView* parent ); - virtual ~PatternView() = default; + MidiClipView( MidiClip* clip, TrackView* parent ); + virtual ~MidiClipView() = default; Q_PROPERTY(QColor noteFillColor READ getNoteFillColor WRITE setNoteFillColor) Q_PROPERTY(QColor noteBorderColor READ getNoteBorderColor WRITE setNoteBorderColor) @@ -57,7 +57,7 @@ class PatternView : public TrackContentObjectView void setMutedNoteBorderColor(QColor const & color) { m_mutedNoteBorderColor = color; } public slots: - Pattern* getPattern(); + MidiClip* getMidiClip(); void update() override; @@ -83,7 +83,7 @@ protected slots: static QPixmap * s_stepBtnOff; static QPixmap * s_stepBtnOffLight; - Pattern* m_pat; + MidiClip* m_clip; QPixmap m_paintPixmap; QColor m_noteFillColor; @@ -98,4 +98,4 @@ protected slots: - #endif \ No newline at end of file + #endif diff --git a/include/NotePlayHandle.h b/include/NotePlayHandle.h index cc78eec92e7..1ba07b33f93 100644 --- a/include/NotePlayHandle.h +++ b/include/NotePlayHandle.h @@ -55,7 +55,7 @@ class LMMS_EXPORT NotePlayHandle : public PlayHandle, public Note // specifies origin of NotePlayHandle enum Origins { - OriginPattern, /*! playback of a note from a pattern */ + OriginMidiClip, /*! playback of a note from a MIDI clip */ OriginMidiInput, /*! playback of a MIDI note input event */ OriginNoteStacking, /*! created by note stacking instrument function */ OriginArpeggio, /*! created by arpeggio instrument function */ @@ -69,7 +69,7 @@ class LMMS_EXPORT NotePlayHandle : public PlayHandle, public Note const Note& noteToPlay, NotePlayHandle* parent = nullptr, int midiEventChannel = -1, - Origin origin = OriginPattern ); + Origin origin = OriginMidiClip ); virtual ~NotePlayHandle(); void * operator new ( size_t size, void * p ) @@ -249,7 +249,7 @@ class LMMS_EXPORT NotePlayHandle : public PlayHandle, public Note /*! Updates total length (m_frames) depending on a new tempo */ void resize( const bpm_t newTempo ); - /*! Set song-global offset (relative to containing pattern) in order to properly perform the note detuning */ + /*! Set song-global offset (relative to containing MIDI clip) in order to properly perform the note detuning */ void setSongGlobalParentOffset( const TimePos& offset ) { m_songGlobalParentOffset = offset; @@ -346,7 +346,7 @@ class NotePlayHandleManager const Note& noteToPlay, NotePlayHandle* parent = nullptr, int midiEventChannel = -1, - NotePlayHandle::Origin origin = NotePlayHandle::OriginPattern ); + NotePlayHandle::Origin origin = NotePlayHandle::OriginMidiClip ); static void release( NotePlayHandle * nph ); static void extend( int i ); static void free(); diff --git a/include/PianoRoll.h b/include/PianoRoll.h index dd32f7c81fe..a288b9adc9b 100644 --- a/include/PianoRoll.h +++ b/include/PianoRoll.h @@ -51,7 +51,7 @@ class QToolButton; class ComboBox; class NotePlayHandle; -class Pattern; +class MidiClip; class TimeLineWidget; class PianoRoll : public QWidget @@ -110,8 +110,8 @@ class PianoRoll : public QWidget void showVolTextFloat(volume_t vol, const QPoint &pos, int timeout=-1); void showPanTextFloat(panning_t pan, const QPoint &pos, int timeout=-1); - void setCurrentPattern( Pattern* newPattern ); - void setGhostPattern( Pattern* newPattern ); + void setCurrentMidiClip( MidiClip* newMidiClip ); + void setGhostMidiClip( MidiClip* newMidiClip ); void loadGhostNotes( const QDomElement & de ); void loadMarkedSemiTones(const QDomElement & de); @@ -130,14 +130,14 @@ class PianoRoll : public QWidget return m_stepRecorder.isRecording(); } - const Pattern* currentPattern() const + const MidiClip* currentMidiClip() const { - return m_pattern; + return m_midiClip; } - bool hasValidPattern() const + bool hasValidMidiClip() const { - return m_pattern != nullptr; + return m_midiClip != nullptr; } Song::PlayModes desiredPlayModeForAccompany() const; @@ -215,11 +215,11 @@ protected slots: void changeNoteEditMode( int i ); void markSemiTone(int i, bool fromMenu = true); - void hidePattern( Pattern* pattern ); + void hideMidiClip( MidiClip* clip ); void selectRegionFromPixels( int xStart, int xEnd ); - void clearGhostPattern(); + void clearGhostClip(); void glueNotes(); void fitNoteLengths(bool fill); void constrainNoteLengths(bool constrainMax); @@ -228,8 +228,8 @@ protected slots: signals: - void currentPatternChanged(); - void ghostPatternSet(bool); + void currentMidiClipChanged(); + void ghostClipSet(bool); void semiToneMarkerMenuScaleSetEnabled(bool); void semiToneMarkerMenuChordSetEnabled(bool); @@ -349,7 +349,7 @@ protected slots: static const QVector m_zoomLevels; static const QVector m_zoomYLevels; - Pattern* m_pattern; + MidiClip* m_midiClip; NoteVector m_ghostNotes; inline const NoteVector & ghostNotes() const @@ -496,9 +496,9 @@ class PianoRollWindow : public Editor, SerializingObject public: PianoRollWindow(); - const Pattern* currentPattern() const; - void setCurrentPattern( Pattern* pattern ); - void setGhostPattern( Pattern* pattern ); + const MidiClip* currentMidiClip() const; + void setCurrentMidiClip( MidiClip* clip ); + void setGhostMidiClip( MidiClip* clip ); int quantization() const; @@ -528,17 +528,17 @@ class PianoRollWindow : public Editor, SerializingObject bool hasFocus() const; signals: - void currentPatternChanged(); + void currentMidiClipChanged(); private slots: - void updateAfterPatternChange(); - void ghostPatternSet( bool state ); - void exportPattern(); - void importPattern(); + void updateAfterMidiClipChange(); + void ghostClipSet( bool state ); + void exportMidiClip(); + void importMidiClip(); private: - void patternRenamed(); + void clipRenamed(); void focusInEvent(QFocusEvent * event) override; void stopStepRecording(); void updateStepRecordingIcon(); diff --git a/include/SampleTCO.h b/include/SampleClip.h similarity index 81% rename from include/SampleTCO.h rename to include/SampleClip.h index 616dba04432..e1e2a52a055 100644 --- a/include/SampleTCO.h +++ b/include/SampleClip.h @@ -1,5 +1,5 @@ /* - * SampleTCO.h + * SampleClip.h * * Copyright (c) 2005-2014 Tobias Doerffel * @@ -22,24 +22,24 @@ * */ -#ifndef SAMPLE_TCO_H -#define SAMPLE_TCO_H +#ifndef SAMPLE_CLIP_H +#define SAMPLE_CLIP_H #include "SampleBuffer.h" #include "SampleTrack.h" -#include "TrackContentObject.h" +#include "Clip.h" -class SampleTCO : public TrackContentObject +class SampleClip : public Clip { Q_OBJECT mapPropertyFromModel(bool,isRecord,setRecord,m_recordModel); public: - SampleTCO( Track * _track ); - SampleTCO( const SampleTCO& orig ); - virtual ~SampleTCO(); + SampleClip( Track * _track ); + SampleClip( const SampleClip& orig ); + virtual ~SampleClip(); - SampleTCO& operator=( const SampleTCO& that ) = delete; + SampleClip& operator=( const SampleClip& that ) = delete; void changeLength( const TimePos & _length ) override; const QString & sampleFile() const; @@ -48,7 +48,7 @@ class SampleTCO : public TrackContentObject void loadSettings( const QDomElement & _this ) override; inline QString nodeName() const override { - return "sampletco"; + return "sampleclip"; } SampleBuffer* sampleBuffer() @@ -59,7 +59,7 @@ class SampleTCO : public TrackContentObject TimePos sampleLength() const; void setSampleStartFrame( f_cnt_t startFrame ); void setSamplePlayLength( f_cnt_t length ); - TrackContentObjectView * createView( TrackView * _tv ) override; + ClipView * createView( TrackView * _tv ) override; bool isPlaying() const; @@ -71,7 +71,7 @@ public slots: void updateLength(); void toggleRecord(); void playbackPositionChanged(); - void updateTrackTcos(); + void updateTrackClips(); private: @@ -79,7 +79,7 @@ public slots: BoolModel m_recordModel; bool m_isPlaying; - friend class SampleTCOView; + friend class SampleClipView; signals: diff --git a/include/SampleTCOView.h b/include/SampleClipView.h similarity index 79% rename from include/SampleTCOView.h rename to include/SampleClipView.h index 37b77d5306a..045e2822d02 100644 --- a/include/SampleTCOView.h +++ b/include/SampleClipView.h @@ -1,5 +1,5 @@ /* - * SampleTCOView.h + * SampleClipView.h * * Copyright (c) 2005-2014 Tobias Doerffel * @@ -22,21 +22,21 @@ * */ -#ifndef SAMPLE_TCO_VIEW_H -#define SAMPLE_TCO_VIEW_H +#ifndef SAMPLE_CLIP_VIEW_H +#define SAMPLE_CLIP_VIEW_H -#include "SampleTCOView.h" +#include "SampleClipView.h" -#include "SampleTCO.h" -#include "TrackContentObjectView.h" +#include "SampleClip.h" +#include "ClipView.h" -class SampleTCOView : public TrackContentObjectView +class SampleClipView : public ClipView { Q_OBJECT public: - SampleTCOView( SampleTCO * _tco, TrackView * _tv ); - virtual ~SampleTCOView() = default; + SampleClipView( SampleClip * _clip, TrackView * _tv ); + virtual ~SampleClipView() = default; public slots: void updateSample(); @@ -55,9 +55,9 @@ public slots: private: - SampleTCO * m_tco; + SampleClip * m_clip; QPixmap m_paintPixmap; - bool splitTCO( const TimePos pos ) override; + bool splitClip( const TimePos pos ) override; } ; diff --git a/include/SamplePlayHandle.h b/include/SamplePlayHandle.h index 33f5ebe5294..367a9a25a27 100644 --- a/include/SamplePlayHandle.h +++ b/include/SamplePlayHandle.h @@ -31,7 +31,7 @@ #include "PlayHandle.h" class BBTrack; -class SampleTCO; +class SampleClip; class Track; class AudioPort; @@ -41,7 +41,7 @@ class SamplePlayHandle : public PlayHandle public: SamplePlayHandle( SampleBuffer* sampleBuffer , bool ownAudioPort = true ); SamplePlayHandle( const QString& sampleFile ); - SamplePlayHandle( SampleTCO* tco ); + SamplePlayHandle( SampleClip* clip ); virtual ~SamplePlayHandle(); inline bool affinityMatters() const override diff --git a/include/SampleRecordHandle.h b/include/SampleRecordHandle.h index f2a6fd63be4..3921b19765a 100644 --- a/include/SampleRecordHandle.h +++ b/include/SampleRecordHandle.h @@ -34,14 +34,14 @@ class BBTrack; class SampleBuffer; -class SampleTCO; +class SampleClip; class Track; class SampleRecordHandle : public PlayHandle { public: - SampleRecordHandle( SampleTCO* tco ); + SampleRecordHandle( SampleClip* clip ); virtual ~SampleRecordHandle(); void play( sampleFrame * _working_buffer ) override; @@ -64,7 +64,7 @@ class SampleRecordHandle : public PlayHandle Track * m_track; BBTrack * m_bbTrack; - SampleTCO * m_tco; + SampleClip * m_clip; } ; diff --git a/include/SampleTrack.h b/include/SampleTrack.h index 2c71c40d373..54ba9295304 100644 --- a/include/SampleTrack.h +++ b/include/SampleTrack.h @@ -30,7 +30,7 @@ #include "AudioPort.h" #include "FadeButton.h" #include "Mixer.h" -#include "SampleTCO.h" +#include "SampleClip.h" #include "SampleTrackView.h" #include "Track.h" @@ -43,9 +43,9 @@ class SampleTrack : public Track virtual ~SampleTrack(); virtual bool play( const TimePos & _start, const fpp_t _frames, - const f_cnt_t _frame_base, int _tco_num = -1 ) override; + const f_cnt_t _frame_base, int _clip_num = -1 ) override; TrackView * createView( TrackContainerView* tcv ) override; - TrackContentObject* createTCO(const TimePos & pos) override; + Clip* createClip(const TimePos & pos) override; virtual void saveTrackSpecificSettings( QDomDocument & _doc, @@ -82,8 +82,8 @@ class SampleTrack : public Track void playingChanged(); public slots: - void updateTcos(); - void setPlayingTcos( bool isPlaying ); + void updateClips(); + void setPlayingClips( bool isPlaying ); void updateMixerChannel(); private: diff --git a/include/Song.h b/include/Song.h index 9639ce14ebc..94c81642348 100644 --- a/include/Song.h +++ b/include/Song.h @@ -44,7 +44,7 @@ class AutomationTrack; -class Pattern; +class MidiClip; class TimeLineWidget; @@ -66,8 +66,8 @@ class LMMS_EXPORT Song : public TrackContainer Mode_None, Mode_PlaySong, Mode_PlayBB, - Mode_PlayPattern, - Mode_PlayAutomationPattern, + Mode_PlayMidiClip, + Mode_PlayAutomationClip, Mode_Count } ; @@ -276,7 +276,7 @@ class LMMS_EXPORT Song : public TrackContainer bpm_t getTempo(); - AutomationPattern * tempoAutomationPattern() override; + AutomationClip * tempoAutomationClip() override; AutomationTrack * globalAutomationTrack() { @@ -284,7 +284,7 @@ class LMMS_EXPORT Song : public TrackContainer } //TODO: Add Q_DECL_OVERRIDE when Qt4 is dropped - AutomatedValueMap automatedValuesAt(TimePos time, int tcoNum = -1) const override; + AutomatedValueMap automatedValuesAt(TimePos time, int clipNum = -1) const override; // file management void createNewProject(); @@ -325,7 +325,7 @@ class LMMS_EXPORT Song : public TrackContainer return "song"; } - virtual bool fixedTCOs() const + virtual bool fixedClips() const { return false; } @@ -364,7 +364,7 @@ public slots: void record(); void playAndRecord(); void playBB(); - void playPattern( const Pattern * patternToPlay, bool loop = true ); + void playMidiClip( const MidiClip * midiClipToPlay, bool loop = true ); void togglePause(); void stop(); @@ -473,8 +473,8 @@ private slots: PlayPos m_playPos[Mode_Count]; bar_t m_length; - const Pattern* m_patternToPlay; - bool m_loopPattern; + const MidiClip* m_midiClipToPlay; + bool m_loopMidiClip; double m_elapsedMilliSeconds[Mode_Count]; tick_t m_elapsedTicks; diff --git a/include/SongEditor.h b/include/SongEditor.h index 6c5f9eb6e6d..41b732dddc8 100644 --- a/include/SongEditor.h +++ b/include/SongEditor.h @@ -84,7 +84,7 @@ public slots: void updatePosition( const TimePos & t ); void updatePositionLine(); - void selectAllTcos( bool select ); + void selectAllClips( bool select ); protected: void closeEvent( QCloseEvent * ce ) override; diff --git a/include/StepRecorder.h b/include/StepRecorder.h index 13b3577a86c..99b008bd1cf 100644 --- a/include/StepRecorder.h +++ b/include/StepRecorder.h @@ -28,7 +28,7 @@ #include "Note.h" #include "lmms_basics.h" -#include "Pattern.h" +#include "MidiClip.h" class PianoRoll; class StepRecorderWidget; @@ -47,7 +47,7 @@ class StepRecorder : public QObject void noteReleased(const Note & n); bool keyPressEvent(QKeyEvent* ke); bool mousePressEvent(QMouseEvent* ke); - void setCurrentPattern(Pattern* newPattern); + void setCurrentMidiClip(MidiClip* newMidiClip); void setStepsLength(const TimePos& newLength); QVector getCurStepNotes(); @@ -93,7 +93,7 @@ class StepRecorder : public QObject QTimer m_updateReleasedTimer; - Pattern* m_pattern; + MidiClip* m_midiClip; class StepNote { @@ -133,7 +133,7 @@ class StepRecorder : public QObject QElapsedTimer releasedTimer; } ; - QVector m_curStepNotes; // contains the current recorded step notes (i.e. while user still press the notes; before they are applied to the pattern) + QVector m_curStepNotes; // contains the current recorded step notes (i.e. while user still press the notes; before they are applied to the clip) StepNote* findCurStepNote(const int key); diff --git a/include/TimeLineWidget.h b/include/TimeLineWidget.h index c7ac0124c9e..915553c4d98 100644 --- a/include/TimeLineWidget.h +++ b/include/TimeLineWidget.h @@ -235,7 +235,7 @@ public slots: MovePositionMarker, MoveLoopBegin, MoveLoopEnd, - SelectSongTCO, + SelectSongClip, } m_action; int m_moveXOff; diff --git a/include/Track.h b/include/Track.h index 3a537b712eb..9c68808b807 100644 --- a/include/Track.h +++ b/include/Track.h @@ -37,7 +37,7 @@ class TimePos; class TrackContainer; class TrackContainerView; -class TrackContentObject; +class Clip; class TrackView; @@ -60,7 +60,7 @@ class LMMS_EXPORT Track : public Model, public JournallingObject mapPropertyFromModel(bool,isMuted,setMuted,m_mutedModel); mapPropertyFromModel(bool,isSolo,setSolo,m_soloModel); public: - typedef QVector tcoVector; + typedef QVector clipVector; enum TrackTypes { @@ -90,11 +90,11 @@ class LMMS_EXPORT Track : public Model, public JournallingObject } virtual bool play( const TimePos & start, const fpp_t frames, - const f_cnt_t frameBase, int tcoNum = -1 ) = 0; + const f_cnt_t frameBase, int clipNum = -1 ) = 0; virtual TrackView * createView( TrackContainerView * view ) = 0; - virtual TrackContentObject * createTCO( const TimePos & pos ) = 0; + virtual Clip * createClip( const TimePos & pos ) = 0; virtual void saveTrackSpecificSettings( QDomDocument & doc, QDomElement & parent ) = 0; @@ -109,25 +109,25 @@ class LMMS_EXPORT Track : public Model, public JournallingObject m_simpleSerializingMode = true; } - // -- for usage by TrackContentObject only --------------- - TrackContentObject * addTCO( TrackContentObject * tco ); - void removeTCO( TrackContentObject * tco ); + // -- for usage by Clip only --------------- + Clip * addClip( Clip * clip ); + void removeClip( Clip * clip ); // ------------------------------------------------------- - void deleteTCOs(); + void deleteClips(); - int numOfTCOs(); - TrackContentObject * getTCO( int tcoNum ); - int getTCONum(const TrackContentObject* tco ); + int numOfClips(); + Clip * getClip( int clipNum ); + int getClipNum(const Clip* clip ); - const tcoVector & getTCOs() const + const clipVector & getClips() const { - return m_trackContentObjects; + return m_clips; } - void getTCOsInRange( tcoVector & tcoV, const TimePos & start, + void getClipsInRange( clipVector & clipV, const TimePos & start, const TimePos & end ); - void swapPositionOfTCOs( int tcoNum1, int tcoNum2 ); + void swapPositionOfClips( int clipNum1, int clipNum2 ); - void createTCOsForBB( int bb ); + void createClipsForBB( int bb ); void insertBar( const TimePos & pos ); @@ -226,7 +226,7 @@ public slots: bool m_simpleSerializingMode; - tcoVector m_trackContentObjects; + clipVector m_clips; QMutex m_processingLock; @@ -239,7 +239,7 @@ public slots: signals: void destroyedTrack(); void nameChanged(); - void trackContentObjectAdded( TrackContentObject * ); + void clipAdded( Clip * ); void colorChanged(); } ; diff --git a/include/TrackContainer.h b/include/TrackContainer.h index 895d4e6c3df..67cd90f852c 100644 --- a/include/TrackContainer.h +++ b/include/TrackContainer.h @@ -32,7 +32,7 @@ #include "JournallingObject.h" -class AutomationPattern; +class AutomationClip; class InstrumentTrack; class TrackContainerView; @@ -56,7 +56,7 @@ class LMMS_EXPORT TrackContainer : public Model, public JournallingObject void loadSettings( const QDomElement & _this ) override; - virtual AutomationPattern * tempoAutomationPattern() + virtual AutomationClip * tempoAutomationClip() { return nullptr; } @@ -93,13 +93,13 @@ class LMMS_EXPORT TrackContainer : public Model, public JournallingObject return m_TrackContainerType; } - virtual AutomatedValueMap automatedValuesAt(TimePos time, int tcoNum = -1) const; + virtual AutomatedValueMap automatedValuesAt(TimePos time, int clipNum = -1) const; signals: void trackAdded( Track * _track ); protected: - static AutomatedValueMap automatedValuesFromTracks(const TrackList &tracks, TimePos timeStart, int tcoNum = -1); + static AutomatedValueMap automatedValuesFromTracks(const TrackList &tracks, TimePos timeStart, int clipNum = -1); mutable QReadWriteLock m_tracksMutex; diff --git a/include/TrackContainerView.h b/include/TrackContainerView.h index ebc4e42a6ea..f6ad177b920 100644 --- a/include/TrackContainerView.h +++ b/include/TrackContainerView.h @@ -65,7 +65,7 @@ class TrackContainerView : public QWidget, public ModelView, return m_currentPosition; } - virtual bool fixedTCOs() const + virtual bool fixedClips() const { return false; } diff --git a/include/TrackContentWidget.h b/include/TrackContentWidget.h index 37362319b76..d3bf60488f0 100644 --- a/include/TrackContentWidget.h +++ b/include/TrackContentWidget.h @@ -34,7 +34,7 @@ class QMimeData; class Track; -class TrackContentObjectView; +class ClipView; class TrackView; @@ -55,20 +55,20 @@ class TrackContentWidget : public QWidget, public JournallingObject /*! \brief Updates the background tile pixmap. */ void updateBackground(); - void addTCOView( TrackContentObjectView * tcov ); - void removeTCOView( TrackContentObjectView * tcov ); - void removeTCOView( int tcoNum ) + void addClipView( ClipView * clipv ); + void removeClipView( ClipView * clipv ); + void removeClipView( int clipNum ) { - if( tcoNum >= 0 && tcoNum < m_tcoViews.size() ) + if( clipNum >= 0 && clipNum < m_clipViews.size() ) { - removeTCOView( m_tcoViews[tcoNum] ); + removeClipView( m_clipViews[clipNum] ); } } - bool canPasteSelection( TimePos tcoPos, const QDropEvent *de ); - bool canPasteSelection( TimePos tcoPos, const QMimeData *md, bool allowSameBar = false ); - bool pasteSelection( TimePos tcoPos, QDropEvent * de ); - bool pasteSelection( TimePos tcoPos, const QMimeData * md, bool skipSafetyCheck = false ); + bool canPasteSelection( TimePos clipPos, const QDropEvent *de ); + bool canPasteSelection( TimePos clipPos, const QMimeData *md, bool allowSameBar = false ); + bool pasteSelection( TimePos clipPos, QDropEvent * de ); + bool pasteSelection( TimePos clipPos, const QMimeData * md, bool skipSafetyCheck = false ); TimePos endPosition( const TimePos & posStart ); @@ -126,8 +126,8 @@ public slots: TrackView * m_trackView; - typedef QVector tcoViewVector; - tcoViewVector m_tcoViews; + typedef QVector clipViewVector; + clipViewVector m_clipViews; QPixmap m_background; diff --git a/include/TrackOperationsWidget.h b/include/TrackOperationsWidget.h index 20c59e95162..7680aa7b492 100644 --- a/include/TrackOperationsWidget.h +++ b/include/TrackOperationsWidget.h @@ -53,7 +53,7 @@ private slots: void selectTrackColor(); void randomizeTrackColor(); void resetTrackColor(); - void resetTCOColors(); + void resetClipColors(); void toggleRecording(bool on); void recordingOn(); void recordingOff(); diff --git a/include/TrackView.h b/include/TrackView.h index 8383500c9ea..eff5413086b 100644 --- a/include/TrackView.h +++ b/include/TrackView.h @@ -40,7 +40,7 @@ class QMenu; class FadeButton; class Track; class TrackContainerView; -class TrackContentObject; +class Clip; const int DEFAULT_SETTINGS_WIDGET_WIDTH = 224; @@ -50,7 +50,7 @@ const int TRACK_OP_WIDTH = 78; const int DEFAULT_SETTINGS_WIDGET_WIDTH_COMPACT = 96; const int TRACK_OP_WIDTH_COMPACT = 62; -const int TCO_BORDER_WIDTH = 2; +const int CLIP_BORDER_WIDTH = 2; class TrackView : public QWidget, public ModelView, public JournallingObject @@ -163,7 +163,7 @@ public slots: private slots: - void createTCOView( TrackContentObject * tco ); + void createClipView( Clip * clip ); void muteChanged(); } ; diff --git a/plugins/HydrogenImport/HydrogenImport.cpp b/plugins/HydrogenImport/HydrogenImport.cpp index c1f5deeacf0..906c94f0b63 100644 --- a/plugins/HydrogenImport/HydrogenImport.cpp +++ b/plugins/HydrogenImport/HydrogenImport.cpp @@ -13,7 +13,7 @@ #include "Instrument.h" #include "InstrumentTrack.h" #include "Note.h" -#include "Pattern.h" +#include "MidiClip.h" #include "Track.h" #include "BBTrack.h" #include "BBTrackContainer.h" @@ -280,7 +280,7 @@ bool HydrogenImport::readSong() QString instrId = LocalFileMng::readXmlString( noteNode, "instrument", 0,false, false ); int i = pattern_count - 1 + nbb; pattern_id[sName] = pattern_count - 1; - Pattern*p = dynamic_cast( drum_track[instrId]->getTCO( i ) ); + MidiClip*p = dynamic_cast( drum_track[instrId]->getClip( i ) ); Note n; n.setPos( nPosition ); if ( (nPosition + 48) <= nSize ) @@ -301,7 +301,7 @@ bool HydrogenImport::readSong() } patternNode = ( QDomNode ) patternNode.nextSiblingElement( "pattern" ); } - // Pattern sequence + // MidiClip sequence QDomNode patternSequenceNode = songNode.firstChildElement( "patternSequence" ); QDomNode groupNode = patternSequenceNode.firstChildElement( "group" ); int pos = 0; @@ -316,7 +316,7 @@ bool HydrogenImport::readSong() int i = pattern_id[patId]+song_num_tracks; Track *t = ( BBTrack * ) s->tracks().at( i ); - t->createTCO(pos); + t->createClip(pos); if ( pattern_length[patId] > best_length ) { diff --git a/plugins/LadspaEffect/LadspaEffect.cpp b/plugins/LadspaEffect/LadspaEffect.cpp index c571a582763..3989a8b85db 100644 --- a/plugins/LadspaEffect/LadspaEffect.cpp +++ b/plugins/LadspaEffect/LadspaEffect.cpp @@ -36,7 +36,7 @@ #include "LadspaControl.h" #include "LadspaSubPluginFeatures.h" #include "EffectChain.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "ControllerConnection.h" #include "MemoryManager.h" #include "ValueBuffer.h" @@ -122,7 +122,7 @@ void LadspaEffect::changeSampleRate() // the IDs of re-created controls have been saved and now need to be // resolved again - AutomationPattern::resolveAllIDs(); + AutomationClip::resolveAllIDs(); } diff --git a/plugins/MidiExport/MidiExport.cpp b/plugins/MidiExport/MidiExport.cpp index 125ee0b3002..cee588db911 100644 --- a/plugins/MidiExport/MidiExport.cpp +++ b/plugins/MidiExport/MidiExport.cpp @@ -122,7 +122,7 @@ bool MidiExport::tryExport(const TrackContainer::TrackList &tracks, double base_volume = 1.0; int base_time = 0; - MidiNoteVector pat; + MidiNoteVector midiClip; for (QDomNode n = element.firstChild(); !n.isNull(); n = n.nextSibling()) { @@ -138,15 +138,15 @@ bool MidiExport::tryExport(const TrackContainer::TrackList &tracks, base_volume = LocaleHelper::toDouble(it.attribute("volume", "100"))/100.0; } - if (n.nodeName() == "pattern") + if (n.nodeName() == "pattern") //TODO: rename to "midiClip" { base_time = n.toElement().attribute("pos", "0").toInt(); - writePattern(pat, n, base_pitch, base_volume, base_time); + writeMidiClip(midiClip, n, base_pitch, base_volume, base_time); } } - ProcessBBNotes(pat, INT_MAX); - writePatternToTrack(mtrack, pat); + ProcessBBNotes(midiClip, INT_MAX); + writeMidiClipToTrack(mtrack, midiClip); size = mtrack.writeToBuffer(buffer); midiout.writeRawData((char *)buffer, size); } @@ -160,7 +160,7 @@ bool MidiExport::tryExport(const TrackContainer::TrackList &tracks, for (QDomNode n = element.firstChild(); !n.isNull(); n = n.nextSibling()) { - if (n.nodeName() == "bbtco") + if (n.nodeName() == "bbclip") { QDomElement it = n.toElement(); int pos = it.attribute("pos", "0").toInt(); @@ -208,28 +208,28 @@ bool MidiExport::tryExport(const TrackContainer::TrackList &tracks, base_volume = LocaleHelper::toDouble(it.attribute("volume", "100")) / 100.0; } - if (n.nodeName() == "pattern") + if (n.nodeName() == "pattern") //TODO: rename to "midiClip" { std::vector> &plist = *itr; - MidiNoteVector nv, pat; - writePattern(pat, n, base_pitch, base_volume, 0); + MidiNoteVector nv, midiClip; + writeMidiClip(midiClip, n, base_pitch, base_volume, 0); - // workaround for nested BBTCOs + // workaround for nested BBClips int pos = 0; int len = n.toElement().attribute("steps", "1").toInt() * 12; for (auto it = plist.begin(); it != plist.end(); ++it) { while (!st.empty() && st.back().second <= it->first) { - writeBBPattern(pat, nv, len, st.back().first, pos, st.back().second); + writeBBClip(midiClip, nv, len, st.back().first, pos, st.back().second); pos = st.back().second; st.pop_back(); } if (!st.empty() && st.back().second <= it->second) { - writeBBPattern(pat, nv, len, st.back().first, pos, it->first); + writeBBClip(midiClip, nv, len, st.back().first, pos, it->first); pos = it->first; while (!st.empty() && st.back().second <= it->second) { @@ -243,13 +243,13 @@ bool MidiExport::tryExport(const TrackContainer::TrackList &tracks, while (!st.empty()) { - writeBBPattern(pat, nv, len, st.back().first, pos, st.back().second); + writeBBClip(midiClip, nv, len, st.back().first, pos, st.back().second); pos = st.back().second; st.pop_back(); } ProcessBBNotes(nv, pos); - writePatternToTrack(mtrack, nv); + writeMidiClipToTrack(mtrack, nv); ++itr; } } @@ -263,7 +263,7 @@ bool MidiExport::tryExport(const TrackContainer::TrackList &tracks, -void MidiExport::writePattern(MidiNoteVector &pat, QDomNode n, +void MidiExport::writeMidiClip(MidiNoteVector &midiClip, QDomNode n, int base_pitch, double base_volume, int base_time) { // TODO interpret steps="12" muted="0" type="1" name="Piano1" len="2592" @@ -278,13 +278,13 @@ void MidiExport::writePattern(MidiNoteVector &pat, QDomNode n, mnote.volume = qMin(qRound(base_volume * LocaleHelper::toDouble(note.attribute("vol", "100")) * (127.0 / 200.0)), 127); mnote.time = base_time + note.attribute("pos", "0").toInt(); mnote.duration = note.attribute("len", "0").toInt(); - pat.push_back(mnote); + midiClip.push_back(mnote); } } -void MidiExport::writePatternToTrack(MTrack &mtrack, MidiNoteVector &nv) +void MidiExport::writeMidiClipToTrack(MTrack &mtrack, MidiNoteVector &nv) { for (auto it = nv.begin(); it != nv.end(); ++it) { @@ -294,7 +294,7 @@ void MidiExport::writePatternToTrack(MTrack &mtrack, MidiNoteVector &nv) -void MidiExport::writeBBPattern(MidiNoteVector &src, MidiNoteVector &dst, +void MidiExport::writeBBClip(MidiNoteVector &src, MidiNoteVector &dst, int len, int base, int start, int end) { if (start >= end) { return; } diff --git a/plugins/MidiExport/MidiExport.h b/plugins/MidiExport/MidiExport.h index 3c36eeb8f55..2520b97bfbc 100644 --- a/plugins/MidiExport/MidiExport.h +++ b/plugins/MidiExport/MidiExport.h @@ -70,10 +70,10 @@ class MidiExport: public ExportFilter int tempo, int masterPitch, const QString &filename); private: - void writePattern(MidiNoteVector &pat, QDomNode n, + void writeMidiClip(MidiNoteVector &midiClip, QDomNode n, int base_pitch, double base_volume, int base_time); - void writePatternToTrack(MTrack &mtrack, MidiNoteVector &nv); - void writeBBPattern(MidiNoteVector &src, MidiNoteVector &dst, + void writeMidiClipToTrack(MTrack &mtrack, MidiNoteVector &nv); + void writeBBClip(MidiNoteVector &src, MidiNoteVector &dst, int len, int base, int start, int end); void ProcessBBNotes(MidiNoteVector &nv, int cutPos); diff --git a/plugins/MidiImport/MidiImport.cpp b/plugins/MidiImport/MidiImport.cpp index 1429b41d7cb..f63332c0bd6 100644 --- a/plugins/MidiImport/MidiImport.cpp +++ b/plugins/MidiImport/MidiImport.cpp @@ -37,9 +37,9 @@ #include "TrackContainer.h" #include "InstrumentTrack.h" #include "AutomationTrack.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "ConfigManager.h" -#include "Pattern.h" +#include "MidiClip.h" #include "Instrument.h" #include "GuiApplication.h" #include "MainWindow.h" @@ -159,7 +159,7 @@ class smfMidiCC { } AutomationTrack * at; - AutomationPattern * ap; + AutomationClip * ap; TimePos lastPos; smfMidiCC & create( TrackContainer* tc, QString tn ) @@ -192,8 +192,8 @@ class smfMidiCC if( !ap || time > lastPos + DefaultTicksPerBar ) { TimePos pPos = TimePos( time.getBar(), 0 ); - ap = dynamic_cast( - at->createTCO(pPos)); + ap = dynamic_cast( + at->createClip(pPos)); ap->addObject( objModel ); } @@ -221,7 +221,7 @@ class smfMidiChannel { } InstrumentTrack * it; - Pattern* p; + MidiClip* p; Instrument * it_inst; bool isSF2; bool hasNotes; @@ -259,7 +259,7 @@ class smfMidiChannel it->pitchRangeModel()->setInitValue( 2 ); // Create a default pattern - p = dynamic_cast(it->createTCO(0)); + p = dynamic_cast(it->createClip(0)); } return this; } @@ -269,30 +269,30 @@ class smfMidiChannel { if (!p) { - p = dynamic_cast(it->createTCO(0)); + p = dynamic_cast(it->createClip(0)); } p->addNote(n, false); hasNotes = true; } - void splitPatterns() + void splitMidiClips() { - Pattern * newPattern = nullptr; + MidiClip * newMidiClip = nullptr; TimePos lastEnd(0); p->rearrangeAllNotes(); for (auto n : p->notes()) { - if (!newPattern || n->pos() > lastEnd + DefaultTicksPerBar) + if (!newMidiClip || n->pos() > lastEnd + DefaultTicksPerBar) { TimePos pPos = TimePos(n->pos().getBar(), 0); - newPattern = dynamic_cast(it->createTCO(pPos)); + newMidiClip = dynamic_cast(it->createClip(pPos)); } lastEnd = n->pos() + n->length(); Note newNote(*n); - newNote.setPos(n->pos(newPattern->startPosition())); - newPattern->addNote(newNote, false); + newNote.setPos(n->pos(newMidiClip->startPosition())); + newMidiClip->addNote(newNote, false); } delete p; @@ -336,12 +336,12 @@ bool MidiImport::readSMF( TrackContainer* tc ) AutomationTrack * dt = dynamic_cast( Track::create(Track::AutomationTrack, Engine::getSong())); dt->setName(tr("MIDI Time Signature Denominator")); - AutomationPattern * timeSigNumeratorPat = - new AutomationPattern(nt); + AutomationClip * timeSigNumeratorPat = + new AutomationClip(nt); timeSigNumeratorPat->setDisplayName(tr("Numerator")); timeSigNumeratorPat->addObject(&timeSigMM.numeratorModel()); - AutomationPattern * timeSigDenominatorPat = - new AutomationPattern(dt); + AutomationClip * timeSigDenominatorPat = + new AutomationClip(dt); timeSigDenominatorPat->setDisplayName(tr("Denominator")); timeSigDenominatorPat->addObject(&timeSigMM.denominatorModel()); @@ -364,7 +364,7 @@ bool MidiImport::readSMF( TrackContainer* tc ) pd.setValue( 2 ); // Tempo stuff - AutomationPattern * tap = tc->tempoAutomationPattern(); + AutomationClip * tap = tc->tempoAutomationClip(); if( tap ) { tap->clear(); @@ -565,7 +565,7 @@ bool MidiImport::readSMF( TrackContainer* tc ) { if (c.second.hasNotes) { - c.second.splitPatterns(); + c.second.splitMidiClips(); } else if (c.second.it) { diff --git a/plugins/audio_file_processor/audio_file_processor.cpp b/plugins/audio_file_processor/audio_file_processor.cpp index b4f2576fd0d..65d2cd66914 100644 --- a/plugins/audio_file_processor/audio_file_processor.cpp +++ b/plugins/audio_file_processor/audio_file_processor.cpp @@ -577,7 +577,7 @@ void AudioFileProcessorView::dragEnterEvent( QDragEnterEvent * _dee ) { QString txt = _dee->mimeData()->data( mimeType( MimeType::StringPair ) ); - if( txt.section( ':', 0, 0 ) == QString( "tco_%1" ).arg( + if( txt.section( ':', 0, 0 ) == QString( "clip_%1" ).arg( Track::SampleTrack ) ) { _dee->acceptProposedAction(); @@ -630,7 +630,7 @@ void AudioFileProcessorView::dropEvent( QDropEvent * _de ) newWaveView(); return; } - else if( type == QString( "tco_%1" ).arg( Track::SampleTrack ) ) + else if( type == QString( "clip_%1" ).arg( Track::SampleTrack ) ) { DataFile dataFile( value.toUtf8() ); castModel()->setAudioFile( dataFile.content().firstChild().toElement().attribute( "src" ) ); diff --git a/src/core/AudioEngine.cpp b/src/core/AudioEngine.cpp index c439b464e7b..722cd379215 100644 --- a/src/core/AudioEngine.cpp +++ b/src/core/AudioEngine.cpp @@ -463,7 +463,7 @@ void AudioEngine::handleMetronome() Song::PlayModes currentPlayMode = song->playMode(); bool metronomeSupported = - currentPlayMode == Song::Mode_PlayPattern + currentPlayMode == Song::Mode_PlayMidiClip || currentPlayMode == Song::Mode_PlaySong || currentPlayMode == Song::Mode_PlayBB; diff --git a/src/core/AutomatableModel.cpp b/src/core/AutomatableModel.cpp index bd2d478db8a..51733936f94 100644 --- a/src/core/AutomatableModel.cpp +++ b/src/core/AutomatableModel.cpp @@ -27,7 +27,7 @@ #include "lmms_math.h" #include "AudioEngine.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "ControllerConnection.h" #include "LocaleHelper.h" #include "ProjectJournal.h" @@ -87,7 +87,7 @@ AutomatableModel::~AutomatableModel() bool AutomatableModel::isAutomated() const { - return AutomationPattern::isAutomated( this ); + return AutomationClip::isAutomated( this ); } @@ -176,13 +176,13 @@ void AutomatableModel::saveSettings( QDomDocument& doc, QDomElement& element, co void AutomatableModel::loadSettings( const QDomElement& element, const QString& name ) { // compat code - QDomNode node = element.namedItem( AutomationPattern::classNodeName() ); + QDomNode node = element.namedItem( AutomationClip::classNodeName() ); if( node.isElement() ) { node = node.namedItem( name ); if( node.isElement() ) { - AutomationPattern * p = AutomationPattern::globalAutomationPattern( this ); + AutomationClip * p = AutomationClip::globalAutomationClip( this ); p->loadSettings( node.toElement() ); setValue( p->valueAt( 0 ) ); // in older projects we sometimes have odd automations @@ -718,57 +718,57 @@ void AutomatableModel::reset() float AutomatableModel::globalAutomationValueAt( const TimePos& time ) { - // get patterns that connect to this model - QVector patterns = AutomationPattern::patternsForModel( this ); - if( patterns.isEmpty() ) + // get clips that connect to this model + QVector clips = AutomationClip::clipsForModel( this ); + if( clips.isEmpty() ) { - // if no such patterns exist, return current value + // if no such clips exist, return current value return m_value; } else { - // of those patterns: - // find the patterns which overlap with the time position - QVector patternsInRange; - for( QVector::ConstIterator it = patterns.begin(); it != patterns.end(); it++ ) + // of those clips: + // find the clips which overlap with the time position + QVector clipsInRange; + for( QVector::ConstIterator it = clips.begin(); it != clips.end(); it++ ) { int s = ( *it )->startPosition(); int e = ( *it )->endPosition(); - if( s <= time && e >= time ) { patternsInRange += ( *it ); } + if( s <= time && e >= time ) { clipsInRange += ( *it ); } } - AutomationPattern * latestPattern = nullptr; + AutomationClip * latestClip = nullptr; - if( ! patternsInRange.isEmpty() ) + if( ! clipsInRange.isEmpty() ) { - // if there are more than one overlapping patterns, just use the first one because - // multiple pattern behaviour is undefined anyway - latestPattern = patternsInRange[0]; + // if there are more than one overlapping clips, just use the first one because + // multiple clip behaviour is undefined anyway + latestClip = clipsInRange[0]; } else - // if we find no patterns at the exact time, we need to search for the last pattern before time and use that + // if we find no clips at the exact time, we need to search for the last clip before time and use that { int latestPosition = 0; - for( QVector::ConstIterator it = patterns.begin(); it != patterns.end(); it++ ) + for( QVector::ConstIterator it = clips.begin(); it != clips.end(); it++ ) { int e = ( *it )->endPosition(); if( e <= time && e > latestPosition ) { latestPosition = e; - latestPattern = ( *it ); + latestClip = ( *it ); } } } - if( latestPattern ) + if( latestClip ) { // scale/fit the value appropriately and return it - const float value = latestPattern->valueAt( time - latestPattern->startPosition() ); + const float value = latestClip->valueAt( time - latestClip->startPosition() ); const float scaled_value = scaledValue( value ); return fittedValue( scaled_value ); } - // if we still find no pattern, the value at that time is undefined so + // if we still find no clip, the value at that time is undefined so // just return current value as the best we can do else return m_value; } diff --git a/src/core/AutomationPattern.cpp b/src/core/AutomationClip.cpp similarity index 81% rename from src/core/AutomationPattern.cpp rename to src/core/AutomationClip.cpp index 4fd04376374..f132fec40f5 100644 --- a/src/core/AutomationPattern.cpp +++ b/src/core/AutomationClip.cpp @@ -1,5 +1,5 @@ /* - * AutomationPattern.cpp - implementation of class AutomationPattern which + * AutomationClip.cpp - implementation of class AutomationClip which * holds dynamic values * * Copyright (c) 2008-2014 Tobias Doerffel @@ -24,10 +24,10 @@ * */ -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "AutomationNode.h" -#include "AutomationPatternView.h" +#include "AutomationClipView.h" #include "AutomationTrack.h" #include "BBTrackContainer.h" #include "LocaleHelper.h" @@ -36,14 +36,14 @@ #include -int AutomationPattern::s_quantization = 1; -const float AutomationPattern::DEFAULT_MIN_VALUE = 0; -const float AutomationPattern::DEFAULT_MAX_VALUE = 1; +int AutomationClip::s_quantization = 1; +const float AutomationClip::DEFAULT_MIN_VALUE = 0; +const float AutomationClip::DEFAULT_MAX_VALUE = 1; -AutomationPattern::AutomationPattern( AutomationTrack * _auto_track ) : - TrackContentObject( _auto_track ), - m_patternMutex(QMutex::Recursive), +AutomationClip::AutomationClip( AutomationTrack * _auto_track ) : + Clip( _auto_track ), + m_clipMutex(QMutex::Recursive), m_autoTrack( _auto_track ), m_objects(), m_tension( 1.0 ), @@ -73,25 +73,25 @@ AutomationPattern::AutomationPattern( AutomationTrack * _auto_track ) : -AutomationPattern::AutomationPattern( const AutomationPattern & _pat_to_copy ) : - TrackContentObject( _pat_to_copy.m_autoTrack ), - m_patternMutex(QMutex::Recursive), - m_autoTrack( _pat_to_copy.m_autoTrack ), - m_objects( _pat_to_copy.m_objects ), - m_tension( _pat_to_copy.m_tension ), - m_progressionType( _pat_to_copy.m_progressionType ) +AutomationClip::AutomationClip( const AutomationClip & _clip_to_copy ) : + Clip( _clip_to_copy.m_autoTrack ), + m_clipMutex(QMutex::Recursive), + m_autoTrack( _clip_to_copy.m_autoTrack ), + m_objects( _clip_to_copy.m_objects ), + m_tension( _clip_to_copy.m_tension ), + m_progressionType( _clip_to_copy.m_progressionType ) { - // Locks the mutex of the copied AutomationPattern to make sure it + // Locks the mutex of the copied AutomationClip to make sure it // doesn't change while it's being copied - QMutexLocker m(&_pat_to_copy.m_patternMutex); + QMutexLocker m(&_clip_to_copy.m_clipMutex); - for( timeMap::const_iterator it = _pat_to_copy.m_timeMap.begin(); - it != _pat_to_copy.m_timeMap.end(); ++it ) + for( timeMap::const_iterator it = _clip_to_copy.m_timeMap.begin(); + it != _clip_to_copy.m_timeMap.end(); ++it ) { // Copies the automation node (in/out values and in/out tangents) m_timeMap[POS(it)] = it.value(); - // Sets the node's pattern to this one - m_timeMap[POS(it)].setPattern(this); + // Sets the node's clip to this one + m_timeMap[POS(it)].setClip(this); } if (!getTrack()){ return; } switch( getTrack()->trackContainer()->type() ) @@ -108,9 +108,9 @@ AutomationPattern::AutomationPattern( const AutomationPattern & _pat_to_copy ) : } } -bool AutomationPattern::addObject( AutomatableModel * _obj, bool _search_dup ) +bool AutomationClip::addObject( AutomatableModel * _obj, bool _search_dup ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); if( _search_dup && m_objects.contains(_obj) ) { @@ -138,10 +138,10 @@ bool AutomationPattern::addObject( AutomatableModel * _obj, bool _search_dup ) -void AutomationPattern::setProgressionType( +void AutomationClip::setProgressionType( ProgressionTypes _new_progression_type ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); if ( _new_progression_type == DiscreteProgression || _new_progression_type == LinearProgression || @@ -155,9 +155,9 @@ void AutomationPattern::setProgressionType( -void AutomationPattern::setTension( QString _new_tension ) +void AutomationClip::setTension( QString _new_tension ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); bool ok; float nt = LocaleHelper::toFloat(_new_tension, & ok); @@ -171,9 +171,9 @@ void AutomationPattern::setTension( QString _new_tension ) -const AutomatableModel * AutomationPattern::firstObject() const +const AutomatableModel * AutomationClip::firstObject() const { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); AutomatableModel* model; if (!m_objects.isEmpty() && (model = m_objects.first()) != nullptr) @@ -185,9 +185,9 @@ const AutomatableModel * AutomationPattern::firstObject() const return &fm; } -const AutomationPattern::objectVector& AutomationPattern::objects() const +const AutomationClip::objectVector& AutomationClip::objects() const { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); return m_objects; } @@ -195,9 +195,9 @@ const AutomationPattern::objectVector& AutomationPattern::objects() const -TimePos AutomationPattern::timeMapLength() const +TimePos AutomationClip::timeMapLength() const { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); TimePos one_bar = TimePos(1, 0); if (m_timeMap.isEmpty()) { return one_bar; } @@ -205,7 +205,7 @@ TimePos AutomationPattern::timeMapLength() const timeMap::const_iterator it = m_timeMap.end(); tick_t last_tick = static_cast(POS(it - 1)); // if last_tick is 0 (single item at tick 0) - // return length as a whole bar to prevent disappearing TCO + // return length as a whole bar to prevent disappearing Clip if (last_tick == 0) { return one_bar; } return TimePos(last_tick); @@ -214,7 +214,7 @@ TimePos AutomationPattern::timeMapLength() const -void AutomationPattern::updateLength() +void AutomationClip::updateLength() { // Do not resize down in case user manually extended up changeLength(qMax(length(), timeMapLength())); @@ -232,14 +232,14 @@ void AutomationPattern::updateLength() * @param Boolean True to ignore unquantized surrounding nodes (defaults to true) * @return TimePos of the recently added automation node */ -TimePos AutomationPattern::putValue( +TimePos AutomationClip::putValue( const TimePos & time, const float value, const bool quantPos, const bool ignoreSurroundingPoints ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); cleanObjects(); @@ -286,7 +286,7 @@ TimePos AutomationPattern::putValue( * @param Boolean True to ignore unquantized surrounding nodes (defaults to true) * @return TimePos of the recently added automation node */ -TimePos AutomationPattern::putValues( +TimePos AutomationClip::putValues( const TimePos & time, const float inValue, const float outValue, @@ -294,7 +294,7 @@ TimePos AutomationPattern::putValues( const bool ignoreSurroundingPoints ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); cleanObjects(); @@ -331,9 +331,9 @@ TimePos AutomationPattern::putValues( -void AutomationPattern::removeNode(const TimePos & time) +void AutomationClip::removeNode(const TimePos & time) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); cleanObjects(); @@ -358,7 +358,7 @@ void AutomationPattern::removeNode(const TimePos & time) * @param Int first tick of the range * @param Int second tick of the range */ -void AutomationPattern::removeNodes(const int tick0, const int tick1) +void AutomationClip::removeNodes(const int tick0, const int tick1) { if (tick0 == tick1) { @@ -393,7 +393,7 @@ void AutomationPattern::removeNodes(const int tick0, const int tick1) * @param Int first tick of the range * @param Int second tick of the range */ -void AutomationPattern::resetNodes(const int tick0, const int tick1) +void AutomationClip::resetNodes(const int tick0, const int tick1) { if (tick0 == tick1) { @@ -414,9 +414,9 @@ void AutomationPattern::resetNodes(const int tick0, const int tick1) -void AutomationPattern::recordValue(TimePos time, float value) +void AutomationClip::recordValue(TimePos time, float value) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); if( value != m_lastRecordedValue ) { @@ -442,14 +442,14 @@ void AutomationPattern::recordValue(TimePos time, float value) * @param Boolean. True to ignore unquantized surrounding nodes * @return TimePos with current time of the dragged value */ -TimePos AutomationPattern::setDragValue( +TimePos AutomationClip::setDragValue( const TimePos & time, const float value, const bool quantPos, const bool controlKey ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); if (m_dragging == false) { @@ -495,9 +495,9 @@ TimePos AutomationPattern::setDragValue( /** * @brief After the point is dragged, this function is called to apply the change. */ -void AutomationPattern::applyDragValue() +void AutomationClip::applyDragValue() { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); m_dragging = false; } @@ -505,9 +505,9 @@ void AutomationPattern::applyDragValue() -float AutomationPattern::valueAt( const TimePos & _time ) const +float AutomationClip::valueAt( const TimePos & _time ) const { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); if( m_timeMap.isEmpty() ) { @@ -544,9 +544,9 @@ float AutomationPattern::valueAt( const TimePos & _time ) const // This method will get the value at an offset from a node, so we use the outValue of // that node and the inValue of the next node for the calculations. -float AutomationPattern::valueAt( timeMap::const_iterator v, int offset ) const +float AutomationClip::valueAt( timeMap::const_iterator v, int offset ) const { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); // We never use it with offset 0, but doesn't hurt to return a correct // value if we do @@ -591,9 +591,9 @@ float AutomationPattern::valueAt( timeMap::const_iterator v, int offset ) const -float *AutomationPattern::valuesAfter( const TimePos & _time ) const +float *AutomationClip::valuesAfter( const TimePos & _time ) const { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); timeMap::const_iterator v = m_timeMap.lowerBound(_time); if( v == m_timeMap.end() || (v+1) == m_timeMap.end() ) @@ -615,9 +615,9 @@ float *AutomationPattern::valuesAfter( const TimePos & _time ) const -void AutomationPattern::flipY(int min, int max) +void AutomationClip::flipY(int min, int max) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); bool changedTimeMap = false; @@ -645,7 +645,7 @@ void AutomationPattern::flipY(int min, int max) -void AutomationPattern::flipY() +void AutomationClip::flipY() { flipY(getMin(), getMax()); } @@ -653,16 +653,16 @@ void AutomationPattern::flipY() -void AutomationPattern::flipX(int length) +void AutomationClip::flipX(int length) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); timeMap::const_iterator it = m_timeMap.lowerBound(0); if (it == m_timeMap.end()) { return; } // Temporary map where we will store the flipped version - // of our pattern + // of our clip timeMap tempMap; float tempValue = 0; @@ -672,7 +672,7 @@ void AutomationPattern::flipX(int length) float realLength = m_timeMap.lastKey(); // If we have a positive length, we want to flip the area covered by that - // length, even if it goes beyond the pattern. A negative length means that + // length, even if it goes beyond the clip. A negative length means that // we just want to flip the nodes we have if (length >= 0 && length != realLength) { @@ -752,9 +752,9 @@ void AutomationPattern::flipX(int length) -void AutomationPattern::saveSettings( QDomDocument & _doc, QDomElement & _this ) +void AutomationClip::saveSettings( QDomDocument & _doc, QDomElement & _this ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); _this.setAttribute( "pos", startPosition() ); _this.setAttribute( "len", length() ); @@ -794,9 +794,9 @@ void AutomationPattern::saveSettings( QDomDocument & _doc, QDomElement & _this ) -void AutomationPattern::loadSettings( const QDomElement & _this ) +void AutomationClip::loadSettings( const QDomElement & _this ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); clear(); @@ -851,13 +851,13 @@ void AutomationPattern::loadSettings( const QDomElement & _this ) -const QString AutomationPattern::name() const +const QString AutomationClip::name() const { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); - if( !TrackContentObject::name().isEmpty() ) + if( !Clip::name().isEmpty() ) { - return TrackContentObject::name(); + return Clip::name(); } if( !m_objects.isEmpty() && m_objects.first() != nullptr ) { @@ -869,18 +869,18 @@ const QString AutomationPattern::name() const -TrackContentObjectView * AutomationPattern::createView( TrackView * _tv ) +ClipView * AutomationClip::createView( TrackView * _tv ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); - return new AutomationPatternView( this, _tv ); + return new AutomationClipView( this, _tv ); } -bool AutomationPattern::isAutomated( const AutomatableModel * _m ) +bool AutomationClip::isAutomated( const AutomatableModel * _m ) { TrackContainer::TrackList l; l += Engine::getSong()->tracks(); @@ -892,10 +892,10 @@ bool AutomationPattern::isAutomated( const AutomatableModel * _m ) if( ( *it )->type() == Track::AutomationTrack || ( *it )->type() == Track::HiddenAutomationTrack ) { - const Track::tcoVector & v = ( *it )->getTCOs(); - for( Track::tcoVector::ConstIterator j = v.begin(); j != v.end(); ++j ) + const Track::clipVector & v = ( *it )->getClips(); + for( Track::clipVector::ConstIterator j = v.begin(); j != v.end(); ++j ) { - const AutomationPattern * a = dynamic_cast( *j ); + const AutomationClip * a = dynamic_cast( *j ); if( a && a->hasAutomation() ) { for( objectVector::const_iterator k = a->m_objects.begin(); k != a->m_objects.end(); ++k ) @@ -914,12 +914,12 @@ bool AutomationPattern::isAutomated( const AutomatableModel * _m ) /** - * @brief returns a list of all the automation patterns that are connected to a specific model + * @brief returns a list of all the automation clips that are connected to a specific model * @param _m the model we want to look for */ -QVector AutomationPattern::patternsForModel( const AutomatableModel * _m ) +QVector AutomationClip::clipsForModel( const AutomatableModel * _m ) { - QVector patterns; + QVector clips; TrackContainer::TrackList l; l += Engine::getSong()->tracks(); l += Engine::getBBTrackContainer()->tracks(); @@ -932,17 +932,17 @@ QVector AutomationPattern::patternsForModel( const Automata if( ( *it )->type() == Track::AutomationTrack || ( *it )->type() == Track::HiddenAutomationTrack ) { - // get patterns in those tracks.... - const Track::tcoVector & v = ( *it )->getTCOs(); - // go through all the patterns... - for( Track::tcoVector::ConstIterator j = v.begin(); j != v.end(); ++j ) + // get clips in those tracks.... + const Track::clipVector & v = ( *it )->getClips(); + // go through all the clips... + for( Track::clipVector::ConstIterator j = v.begin(); j != v.end(); ++j ) { - AutomationPattern * a = dynamic_cast( *j ); - // check that the pattern has automation + AutomationClip * a = dynamic_cast( *j ); + // check that the clip has automation if( a && a->hasAutomation() ) { - // now check is the pattern is connected to the model we want by going through all the connections - // of the pattern + // now check is the clip is connected to the model we want by going through all the connections + // of the clip bool has_object = false; for( objectVector::const_iterator k = a->m_objects.begin(); k != a->m_objects.end(); ++k ) { @@ -951,25 +951,25 @@ QVector AutomationPattern::patternsForModel( const Automata has_object = true; } } - // if the patterns is connected to the model, add it to the list - if( has_object ) { patterns += a; } + // if the clips is connected to the model, add it to the list + if( has_object ) { clips += a; } } } } } - return patterns; + return clips; } -AutomationPattern * AutomationPattern::globalAutomationPattern( +AutomationClip * AutomationClip::globalAutomationClip( AutomatableModel * _m ) { AutomationTrack * t = Engine::getSong()->globalAutomationTrack(); - Track::tcoVector v = t->getTCOs(); - for( Track::tcoVector::const_iterator j = v.begin(); j != v.end(); ++j ) + Track::clipVector v = t->getClips(); + for( Track::clipVector::const_iterator j = v.begin(); j != v.end(); ++j ) { - AutomationPattern * a = dynamic_cast( *j ); + AutomationClip * a = dynamic_cast( *j ); if( a ) { for( objectVector::const_iterator k = a->m_objects.begin(); @@ -983,7 +983,7 @@ AutomationPattern * AutomationPattern::globalAutomationPattern( } } - AutomationPattern * a = new AutomationPattern( t ); + AutomationClip * a = new AutomationClip( t ); a->addObject( _m, false ); return a; } @@ -991,7 +991,7 @@ AutomationPattern * AutomationPattern::globalAutomationPattern( -void AutomationPattern::resolveAllIDs() +void AutomationClip::resolveAllIDs() { TrackContainer::TrackList l = Engine::getSong()->tracks() + Engine::getBBTrackContainer()->tracks(); @@ -1002,11 +1002,11 @@ void AutomationPattern::resolveAllIDs() if( ( *it )->type() == Track::AutomationTrack || ( *it )->type() == Track::HiddenAutomationTrack ) { - Track::tcoVector v = ( *it )->getTCOs(); - for( Track::tcoVector::iterator j = v.begin(); + Track::clipVector v = ( *it )->getClips(); + for( Track::clipVector::iterator j = v.begin(); j != v.end(); ++j ) { - AutomationPattern * a = dynamic_cast( *j ); + AutomationClip * a = dynamic_cast( *j ); if( a ) { for( QVector::Iterator k = a->m_idsToResolve.begin(); @@ -1050,9 +1050,9 @@ void AutomationPattern::resolveAllIDs() -void AutomationPattern::clear() +void AutomationClip::clear() { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); m_timeMap.clear(); @@ -1062,14 +1062,14 @@ void AutomationPattern::clear() -void AutomationPattern::objectDestroyed( jo_id_t _id ) +void AutomationClip::objectDestroyed( jo_id_t _id ) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); // TODO: distict between temporary removal (e.g. LADSPA controls // when switching samplerate) and real deletions because in the latter // case we had to remove ourselves if we're the global automation - // pattern of the destroyed object + // clip of the destroyed object m_idsToResolve += _id; for( objectVector::Iterator objIt = m_objects.begin(); @@ -1090,9 +1090,9 @@ void AutomationPattern::objectDestroyed( jo_id_t _id ) -void AutomationPattern::cleanObjects() +void AutomationClip::cleanObjects() { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); for( objectVector::iterator it = m_objects.begin(); it != m_objects.end(); ) { @@ -1110,7 +1110,7 @@ void AutomationPattern::cleanObjects() -void AutomationPattern::generateTangents() +void AutomationClip::generateTangents() { generateTangents(m_timeMap.begin(), m_timeMap.size()); } @@ -1122,9 +1122,9 @@ void AutomationPattern::generateTangents() // of the node (in case we have discrete value jumps in the middle of a curve). // If the inValue and outValue of a node are the same, consequently the inTangent and // outTangent values of the node will be the same too. -void AutomationPattern::generateTangents(timeMap::iterator it, int numToGenerate) +void AutomationClip::generateTangents(timeMap::iterator it, int numToGenerate) { - QMutexLocker m(&m_patternMutex); + QMutexLocker m(&m_clipMutex); if( m_timeMap.size() < 2 && numToGenerate > 0 ) { diff --git a/src/core/AutomationNode.cpp b/src/core/AutomationNode.cpp index d289b2f216f..a2906b0d009 100644 --- a/src/core/AutomationNode.cpp +++ b/src/core/AutomationNode.cpp @@ -1,6 +1,6 @@ /* - * AutomationPattern.cpp - Implementation of class AutomationNode which - * holds information on a single automation pattern node + * AutomationClip.cpp - Implementation of class AutomationNode which + * holds information on a single automation clip node * * Copyright (c) 2020 Ian Caio * @@ -24,12 +24,12 @@ */ #include "AutomationNode.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" // Dummy constructor for the QMap AutomationNode::AutomationNode() : - m_pattern(nullptr), + m_clip(nullptr), m_pos(0), m_inValue(0), m_outValue(0), @@ -38,8 +38,8 @@ AutomationNode::AutomationNode() : { } -AutomationNode::AutomationNode(AutomationPattern* pat, float value, int pos) : - m_pattern(pat), +AutomationNode::AutomationNode(AutomationClip* clip, float value, int pos) : + m_clip(clip), m_pos(pos), m_inValue(value), m_outValue(value), @@ -48,8 +48,8 @@ AutomationNode::AutomationNode(AutomationPattern* pat, float value, int pos) : { } -AutomationNode::AutomationNode(AutomationPattern* pat, float inValue, float outValue, int pos) : - m_pattern(pat), +AutomationNode::AutomationNode(AutomationClip* clip, float inValue, float outValue, int pos) : + m_clip(clip), m_pos(pos), m_inValue(inValue), m_outValue(outValue), @@ -67,15 +67,15 @@ void AutomationNode::setInValue(float value) m_inValue = value; // Recalculate the tangents from neighbor nodes - AutomationPattern::timeMap & tm = m_pattern->getTimeMap(); + AutomationClip::timeMap & tm = m_clip->getTimeMap(); // Get an iterator pointing to this node - AutomationPattern::timeMap::iterator it = tm.lowerBound(m_pos); + AutomationClip::timeMap::iterator it = tm.lowerBound(m_pos); // If it's not the first node, get the one immediately behind it if (it != tm.begin()) { --it; } // Generate tangents from the previously, current and next nodes - m_pattern->generateTangents(it, 3); + m_clip->generateTangents(it, 3); } /** @@ -87,15 +87,15 @@ void AutomationNode::setOutValue(float value) m_outValue = value; // Recalculate the tangents from neighbor nodes - AutomationPattern::timeMap & tm = m_pattern->getTimeMap(); + AutomationClip::timeMap & tm = m_clip->getTimeMap(); // Get an iterator pointing to this node - AutomationPattern::timeMap::iterator it = tm.lowerBound(m_pos); + AutomationClip::timeMap::iterator it = tm.lowerBound(m_pos); // If it's not the first node, get the one immediately behind it if (it != tm.begin()) { --it; } // Generate tangents from the previously, current and next nodes - m_pattern->generateTangents(it, 3); + m_clip->generateTangents(it, 3); } /** diff --git a/src/core/BBTCO.cpp b/src/core/BBClip.cpp similarity index 86% rename from src/core/BBTCO.cpp rename to src/core/BBClip.cpp index 5f92c57fbba..8e19cb50f62 100644 --- a/src/core/BBTCO.cpp +++ b/src/core/BBClip.cpp @@ -1,5 +1,5 @@ /* - * BBTCO.cpp - implementation of class bbTCO + * BBClip.cpp - implementation of class bbClip * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -22,7 +22,7 @@ * */ - #include "BBTCO.h" + #include "BBClip.h" #include @@ -31,8 +31,8 @@ #include "Engine.h" -BBTCO::BBTCO( Track * _track ) : - TrackContentObject( _track ) +BBClip::BBClip( Track * _track ) : + Clip( _track ) { bar_t t = Engine::getBBTrackContainer()->lengthOfBB( bbTrackIndex() ); if( t > 0 ) @@ -44,7 +44,7 @@ BBTCO::BBTCO( Track * _track ) : setAutoResize( false ); } -void BBTCO::saveSettings( QDomDocument & doc, QDomElement & element ) +void BBClip::saveSettings( QDomDocument & doc, QDomElement & element ) { element.setAttribute( "name", name() ); if( element.parentNode().nodeName() == "clipboard" ) @@ -66,7 +66,7 @@ void BBTCO::saveSettings( QDomDocument & doc, QDomElement & element ) -void BBTCO::loadSettings( const QDomElement & element ) +void BBClip::loadSettings( const QDomElement & element ) { setName( element.attribute( "name" ) ); if( element.attribute( "pos" ).toInt() >= 0 ) @@ -101,14 +101,14 @@ void BBTCO::loadSettings( const QDomElement & element ) -int BBTCO::bbTrackIndex() +int BBClip::bbTrackIndex() { return dynamic_cast( getTrack() )->index(); } -TrackContentObjectView * BBTCO::createView( TrackView * _tv ) +ClipView * BBClip::createView( TrackView * _tv ) { - return new BBTCOView( this, _tv ); + return new BBClipView( this, _tv ); } \ No newline at end of file diff --git a/src/core/BBTrackContainer.cpp b/src/core/BBTrackContainer.cpp index 15967000afa..152f34a25b4 100644 --- a/src/core/BBTrackContainer.cpp +++ b/src/core/BBTrackContainer.cpp @@ -53,21 +53,21 @@ BBTrackContainer::~BBTrackContainer() -bool BBTrackContainer::play(TimePos start, fpp_t frames, f_cnt_t offset, int tcoNum) +bool BBTrackContainer::play(TimePos start, fpp_t frames, f_cnt_t offset, int clipNum) { bool notePlayed = false; - if (lengthOfBB(tcoNum) <= 0) + if (lengthOfBB(clipNum) <= 0) { return false; } - start = start % (lengthOfBB(tcoNum) * TimePos::ticksPerBar()); + start = start % (lengthOfBB(clipNum) * TimePos::ticksPerBar()); TrackList tl = tracks(); for (Track * t : tl) { - if (t->play(start, frames, offset, tcoNum)) + if (t->play(start, frames, offset, clipNum)) { notePlayed = true; } @@ -97,10 +97,10 @@ bar_t BBTrackContainer::lengthOfBB(int bb) const const TrackList & tl = tracks(); for (Track * t : tl) { - // Don't create TCOs here if they don't exist - if (bb < t->numOfTCOs()) + // Don't create Clips here if they don't exist + if (bb < t->numOfClips()) { - maxLength = qMax(maxLength, t->getTCO(bb)->length()); + maxLength = qMax(maxLength, t->getClip(bb)->length()); } } @@ -123,7 +123,7 @@ void BBTrackContainer::removeBB(int bb) TrackList tl = tracks(); for (Track * t : tl) { - delete t->getTCO(bb); + delete t->getClip(bb); t->removeBar(bb * DefaultTicksPerBar); } if (bb <= currentBB()) @@ -140,7 +140,7 @@ void BBTrackContainer::swapBB(int bb1, int bb2) TrackList tl = tracks(); for (Track * t : tl) { - t->swapPositionOfTCOs(bb1, bb2); + t->swapPositionOfClips(bb1, bb2); } updateComboBox(); } @@ -148,9 +148,9 @@ void BBTrackContainer::swapBB(int bb1, int bb2) -void BBTrackContainer::updateBBTrack(TrackContentObject * tco) +void BBTrackContainer::updateBBTrack(Clip * clip) { - BBTrack * t = BBTrack::findBBTrack(tco->startPosition() / DefaultTicksPerBar); + BBTrack * t = BBTrack::findBBTrack(clip->startPosition() / DefaultTicksPerBar); if (t != nullptr) { t->dataChanged(); @@ -167,7 +167,7 @@ void BBTrackContainer::fixIncorrectPositions() { for (int i = 0; i < numOfBBs(); ++i) { - t->getTCO(i)->movePosition(TimePos(i, 0)); + t->getClip(i)->movePosition(TimePos(i, 0)); } } } @@ -231,27 +231,27 @@ void BBTrackContainer::currentBBChanged() -void BBTrackContainer::createTCOsForBB(int bb) +void BBTrackContainer::createClipsForBB(int bb) { TrackList tl = tracks(); for (Track * t : tl) { - t->createTCOsForBB(bb); + t->createClipsForBB(bb); } } -AutomatedValueMap BBTrackContainer::automatedValuesAt(TimePos time, int tcoNum) const +AutomatedValueMap BBTrackContainer::automatedValuesAt(TimePos time, int clipNum) const { - Q_ASSERT(tcoNum >= 0); + Q_ASSERT(clipNum >= 0); Q_ASSERT(time.getTicks() >= 0); - auto lengthBars = lengthOfBB(tcoNum); + auto lengthBars = lengthOfBB(clipNum); auto lengthTicks = lengthBars * TimePos::ticksPerBar(); if (time > lengthTicks) { time = lengthTicks; } - return TrackContainer::automatedValuesAt(time + (TimePos::ticksPerBar() * tcoNum), tcoNum); + return TrackContainer::automatedValuesAt(time + (TimePos::ticksPerBar() * clipNum), clipNum); } diff --git a/src/core/CMakeLists.txt b/src/core/CMakeLists.txt index c67f7220e21..79890e112d8 100644 --- a/src/core/CMakeLists.txt +++ b/src/core/CMakeLists.txt @@ -5,11 +5,11 @@ set(LMMS_SRCS core/AudioEngineProfiler.cpp core/AudioEngineWorkerThread.cpp core/AutomatableModel.cpp - core/AutomationPattern.cpp + core/AutomationClip.cpp core/AutomationNode.cpp core/BandLimitedWave.cpp core/base64.cpp - core/BBTCO.cpp + core/BBClip.cpp core/BBTrackContainer.cpp core/BufferManager.cpp core/Clipboard.cpp @@ -66,9 +66,9 @@ set(LMMS_SRCS core/RenderManager.cpp core/RingBuffer.cpp core/SampleBuffer.cpp + core/SampleClip.cpp core/SamplePlayHandle.cpp core/SampleRecordHandle.cpp - core/SampleTCO.cpp core/Scale.cpp core/SerializingObject.cpp core/Song.cpp @@ -77,7 +77,7 @@ set(LMMS_SRCS core/ToolPlugin.cpp core/Track.cpp core/TrackContainer.cpp - core/TrackContentObject.cpp + core/Clip.cpp core/ValueBuffer.cpp core/VstSyncController.cpp core/StepRecorder.cpp diff --git a/src/core/TrackContentObject.cpp b/src/core/Clip.cpp similarity index 60% rename from src/core/TrackContentObject.cpp rename to src/core/Clip.cpp index 0b2a1fa3fee..f247b967e64 100644 --- a/src/core/TrackContentObject.cpp +++ b/src/core/Clip.cpp @@ -1,5 +1,5 @@ /* - * TrackContentObject.cpp - implementation of TrackContentObject class + * Clip.cpp - implementation of Clip class * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -22,24 +22,24 @@ * */ -#include "TrackContentObject.h" +#include "Clip.h" #include #include "AutomationEditor.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "Engine.h" #include "GuiApplication.h" #include "Song.h" -/*! \brief Create a new TrackContentObject +/*! \brief Create a new Clip * - * Creates a new track content object for the given track. + * Creates a new clip for the given track. * * \param _track The track that will contain the new object */ -TrackContentObject::TrackContentObject( Track * track ) : +Clip::Clip( Track * track ) : Model( track ), m_track( track ), m_startPosition(), @@ -51,7 +51,7 @@ TrackContentObject::TrackContentObject( Track * track ) : { if( getTrack() ) { - getTrack()->addTCO( this ); + getTrack()->addClip( this ); } setJournalling( false ); movePosition( 0 ); @@ -62,32 +62,32 @@ TrackContentObject::TrackContentObject( Track * track ) : -/*! \brief Destroy a TrackContentObject +/*! \brief Destroy a Clip * - * Destroys the given track content object. + * Destroys the given clip. * */ -TrackContentObject::~TrackContentObject() +Clip::~Clip() { - emit destroyedTCO(); + emit destroyedClip(); if( getTrack() ) { - getTrack()->removeTCO( this ); + getTrack()->removeClip( this ); } } -/*! \brief Move this TrackContentObject's position in time +/*! \brief Move this Clip's position in time * - * If the track content object has moved, update its position. We + * If the clip has moved, update its position. We * also add a journal entry for undo and update the display. * - * \param _pos The new position of the track content object. + * \param _pos The new position of the clip. */ -void TrackContentObject::movePosition( const TimePos & pos ) +void Clip::movePosition( const TimePos & pos ) { TimePos newPos = qMax(0, pos.getTicks()); if (m_startPosition != newPos) @@ -103,14 +103,14 @@ void TrackContentObject::movePosition( const TimePos & pos ) -/*! \brief Change the length of this TrackContentObject +/*! \brief Change the length of this Clip * - * If the track content object's length has changed, update it. We + * If the clip's length has changed, update it. We * also add a journal entry for undo and update the display. * - * \param _length The new length of the track content object. + * \param _length The new length of the clip. */ -void TrackContentObject::changeLength( const TimePos & length ) +void Clip::changeLength( const TimePos & length ) { m_length = length; Engine::getSong()->updateLength(); @@ -120,7 +120,7 @@ void TrackContentObject::changeLength( const TimePos & length ) -bool TrackContentObject::comparePosition(const TrackContentObject *a, const TrackContentObject *b) +bool Clip::comparePosition(const Clip *a, const Clip *b) { return a->startPosition() < b->startPosition(); } @@ -128,11 +128,11 @@ bool TrackContentObject::comparePosition(const TrackContentObject *a, const Trac -/*! \brief Copies the state of a TrackContentObject to another TrackContentObject +/*! \brief Copies the state of a Clip to another Clip * - * This method copies the state of a TCO to another TCO + * This method copies the state of a Clip to another Clip */ -void TrackContentObject::copyStateTo( TrackContentObject *src, TrackContentObject *dst ) +void Clip::copyStateTo( Clip *src, Clip *dst ) { // If the node names match we copy the state if( src->nodeName() == dst->nodeName() ){ @@ -144,23 +144,23 @@ void TrackContentObject::copyStateTo( TrackContentObject *src, TrackContentObjec dst->restoreState( parent.firstChild().toElement() ); dst->movePosition( pos ); - AutomationPattern::resolveAllIDs(); - GuiApplication::instance()->automationEditor()->m_editor->updateAfterPatternChange(); + AutomationClip::resolveAllIDs(); + GuiApplication::instance()->automationEditor()->m_editor->updateAfterClipChange(); } } -/*! \brief Mutes this TrackContentObject +/*! \brief Mutes this Clip * - * Restore the previous state of this track content object. This will - * restore the position or the length of the track content object + * Restore the previous state of this clip. This will + * restore the position or the length of the clip * depending on what was changed. * * \param _je The journal entry to undo */ -void TrackContentObject::toggleMute() +void Clip::toggleMute() { m_mutedModel.setValue( !m_mutedModel.value() ); emit dataChanged(); @@ -169,7 +169,7 @@ void TrackContentObject::toggleMute() -TimePos TrackContentObject::startTimeOffset() const +TimePos Clip::startTimeOffset() const { return m_startTimeOffset; } @@ -177,14 +177,14 @@ TimePos TrackContentObject::startTimeOffset() const -void TrackContentObject::setStartTimeOffset( const TimePos &startTimeOffset ) +void Clip::setStartTimeOffset( const TimePos &startTimeOffset ) { m_startTimeOffset = startTimeOffset; } -void TrackContentObject::useCustomClipColor( bool b ) +void Clip::useCustomClipColor( bool b ) { if (b == m_useCustomClipColor) { return; } m_useCustomClipColor = b; @@ -192,7 +192,7 @@ void TrackContentObject::useCustomClipColor( bool b ) } -bool TrackContentObject::hasColor() +bool Clip::hasColor() { return usesCustomClipColor() || getTrack()->useColor(); } diff --git a/src/core/Clipboard.cpp b/src/core/Clipboard.cpp index 9b7cf2e775c..7da493c5581 100644 --- a/src/core/Clipboard.cpp +++ b/src/core/Clipboard.cpp @@ -1,5 +1,5 @@ /* - * Clipboard.cpp - the clipboard for patterns, notes etc. + * Clipboard.cpp - the clipboard for clips, notes etc. * * Copyright (c) 2004-2009 Tobias Doerffel * diff --git a/src/core/DataFile.cpp b/src/core/DataFile.cpp index 3b8cdac24ab..9e2f397168d 100644 --- a/src/core/DataFile.cpp +++ b/src/core/DataFile.cpp @@ -54,7 +54,7 @@ static void findIds(const QDomElement& elem, QList& idList); // QMap with the DOM elements that access file resources const DataFile::ResourcesMap DataFile::ELEMENTS_WITH_RESOURCES = { -{ "sampletco", {"src"} }, +{ "sampleclip", {"src"} }, { "audiofileprocessor", {"src"} }, }; @@ -95,7 +95,7 @@ DataFile::typeDescStruct { DataFile::ClipboardData, "clipboard-data" }, { DataFile::JournalData, "journaldata" }, { DataFile::EffectSettings, "effectsettings" }, - { DataFile::NotePattern, "pattern" } + { DataFile::MidiClip, "pattern" } } ; @@ -200,7 +200,7 @@ bool DataFile::validate( QString extension ) return true; } break; - case Type::NotePattern: + case Type::MidiClip: if (extension == "xpt" || extension == "xptz") { return true; @@ -915,7 +915,7 @@ void DataFile::upgrade_0_4_0_20080409() { // Upgrade to version 0.4.0-20080409 from some version greater than or equal to 0.4.0-20080129 QStringList s; - s << "note" << "pattern" << "bbtco" << "sampletco" << "time"; + s << "note" << "pattern" << "bbclip" << "sampleclip" << "time"; for( QStringList::iterator it = s.begin(); it < s.end(); ++it ) { QDomNodeList list = elementsByTagName( *it ); @@ -1625,7 +1625,7 @@ void DataFile::upgrade_noHiddenClipNames() QDomNodeList instClips = track.elementsByTagName("pattern"); QDomNodeList autoClips = track.elementsByTagName("automationpattern"); - QDomNodeList bbClips = track.elementsByTagName("bbtco"); + QDomNodeList bbClips = track.elementsByTagName("bbclip"); clearDefaultNames(instClips, trackName); clearDefaultNames(autoClips, trackName); diff --git a/src/core/InlineAutomation.cpp b/src/core/InlineAutomation.cpp index 4ee596dbcca..7df6a2d75e8 100644 --- a/src/core/InlineAutomation.cpp +++ b/src/core/InlineAutomation.cpp @@ -33,9 +33,9 @@ void InlineAutomation::saveSettings( QDomDocument & _doc, if( hasAutomation() ) { QDomElement ap = _doc.createElement( - AutomationPattern::classNodeName() ); + AutomationClip::classNodeName() ); QDomElement v = _doc.createElement( nodeName() ); - automationPattern()->saveSettings( _doc, v ); + automationClip()->saveSettings( _doc, v ); ap.appendChild( v ); _parent.appendChild( ap ); } @@ -46,13 +46,13 @@ void InlineAutomation::saveSettings( QDomDocument & _doc, void InlineAutomation::loadSettings( const QDomElement & _this ) { - QDomNode node = _this.namedItem( AutomationPattern::classNodeName() ); + QDomNode node = _this.namedItem( AutomationClip::classNodeName() ); if( node.isElement() ) { node = node.namedItem( nodeName() ); if( node.isElement() ) { - automationPattern()->loadSettings( + automationClip()->loadSettings( node.toElement() ); } } diff --git a/src/core/MeterModel.cpp b/src/core/MeterModel.cpp index 30db26d9b71..7bf61958dcb 100644 --- a/src/core/MeterModel.cpp +++ b/src/core/MeterModel.cpp @@ -24,7 +24,7 @@ #include "MeterModel.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" MeterModel::MeterModel( ::Model * _parent ) : @@ -53,8 +53,8 @@ void MeterModel::reset() m_numeratorModel.setValue( 4 ); m_denominatorModel.setValue( 4 ); - AutomationPattern::globalAutomationPattern( &m_numeratorModel )->clear(); - AutomationPattern::globalAutomationPattern( &m_denominatorModel )->clear(); + AutomationClip::globalAutomationClip( &m_numeratorModel )->clear(); + AutomationClip::globalAutomationClip( &m_denominatorModel )->clear(); } diff --git a/src/core/Note.cpp b/src/core/Note.cpp index 16c36b1bc2e..f43a8b9715d 100644 --- a/src/core/Note.cpp +++ b/src/core/Note.cpp @@ -211,9 +211,9 @@ void Note::createDetuning() if( m_detuning == nullptr ) { m_detuning = new DetuningHelper; - (void) m_detuning->automationPattern(); + (void) m_detuning->automationClip(); m_detuning->setRange( -MaxDetuning, MaxDetuning, 0.5f ); - m_detuning->automationPattern()->setProgressionType( AutomationPattern::LinearProgression ); + m_detuning->automationClip()->setProgressionType( AutomationClip::LinearProgression ); } } diff --git a/src/core/NotePlayHandle.cpp b/src/core/NotePlayHandle.cpp index f1a26dd7f0f..45b9013afd8 100644 --- a/src/core/NotePlayHandle.cpp +++ b/src/core/NotePlayHandle.cpp @@ -35,7 +35,7 @@ #include "Song.h" NotePlayHandle::BaseDetuning::BaseDetuning( DetuningHelper *detuning ) : - m_value( detuning ? detuning->automationPattern()->valueAt( 0 ) : 0 ) + m_value( detuning ? detuning->automationClip()->valueAt( 0 ) : 0 ) { } @@ -559,7 +559,7 @@ void NotePlayHandle::processTimePos( const TimePos& time ) { if( detuning() && time >= songGlobalParentOffset()+pos() ) { - const float v = detuning()->automationPattern()->valueAt( time - songGlobalParentOffset() - pos() ); + const float v = detuning()->automationClip()->valueAt( time - songGlobalParentOffset() - pos() ); if( !typeInfo::isEqual( v, m_baseDetuning->value() ) ) { m_baseDetuning->setValue( v ); diff --git a/src/core/SampleTCO.cpp b/src/core/SampleClip.cpp similarity index 79% rename from src/core/SampleTCO.cpp rename to src/core/SampleClip.cpp index 6fcf8a126ba..d848c6b57f1 100644 --- a/src/core/SampleTCO.cpp +++ b/src/core/SampleClip.cpp @@ -1,5 +1,5 @@ /* - * SampleTCO.cpp + * SampleClip.cpp * * Copyright (c) 2005-2014 Tobias Doerffel * @@ -22,15 +22,15 @@ * */ -#include "SampleTCO.h" +#include "SampleClip.h" #include -#include "SampleTCOView.h" +#include "SampleClipView.h" #include "TimeLineWidget.h" -SampleTCO::SampleTCO( Track * _track ) : - TrackContentObject( _track ), +SampleClip::SampleClip( Track * _track ) : + Clip( _track ), m_sampleBuffer( new SampleBuffer ), m_isPlaying( false ) { @@ -39,7 +39,7 @@ SampleTCO::SampleTCO( Track * _track ) : restoreJournallingState(); // we need to receive bpm-change-events, because then we have to - // change length of this TCO + // change length of this Clip connect( Engine::getSong(), SIGNAL( tempoChanged( bpm_t ) ), this, SLOT( updateLength() ), Qt::DirectConnection ); connect( Engine::getSong(), SIGNAL( timeSignatureChanged( int,int ) ), @@ -57,13 +57,13 @@ SampleTCO::SampleTCO( Track * _track ) : //care about loops connect( Engine::getSong(), SIGNAL( updateSampleTracks() ), this, SLOT( playbackPositionChanged() ), Qt::DirectConnection ); - //care about mute TCOs + //care about mute Clips connect( this, SIGNAL( dataChanged() ), this, SLOT( playbackPositionChanged() ) ); //care about mute track connect( getTrack()->getMutedModel(), SIGNAL( dataChanged() ), this, SLOT( playbackPositionChanged() ), Qt::DirectConnection ); - //care about TCO position - connect( this, SIGNAL( positionChanged() ), this, SLOT( updateTrackTcos() ) ); + //care about Clip position + connect( this, SIGNAL( positionChanged() ), this, SLOT( updateTrackClips() ) ); switch( getTrack()->trackContainer()->type() ) { @@ -77,13 +77,13 @@ SampleTCO::SampleTCO( Track * _track ) : setAutoResize( false ); break; } - updateTrackTcos(); + updateTrackClips(); } -SampleTCO::SampleTCO(const SampleTCO& orig) : - SampleTCO(orig.getTrack()) +SampleClip::SampleClip(const SampleClip& orig) : + SampleClip(orig.getTrack()) { - // TODO: This creates a new SampleBuffer for the new TCO, eating up memory + // TODO: This creates a new SampleBuffer for the new Clip, eating up memory // & eventually causing performance issues. Letting tracks share buffers // when they're identical would fix this, but isn't possible right now. *m_sampleBuffer = *orig.m_sampleBuffer; @@ -93,12 +93,12 @@ SampleTCO::SampleTCO(const SampleTCO& orig) : -SampleTCO::~SampleTCO() +SampleClip::~SampleClip() { SampleTrack * sampletrack = dynamic_cast( getTrack() ); if ( sampletrack ) { - sampletrack->updateTcos(); + sampletrack->updateClips(); } Engine::audioEngine()->requestChangeInModel(); sharedObject::unref( m_sampleBuffer ); @@ -108,22 +108,22 @@ SampleTCO::~SampleTCO() -void SampleTCO::changeLength( const TimePos & _length ) +void SampleClip::changeLength( const TimePos & _length ) { - TrackContentObject::changeLength( qMax( static_cast( _length ), 1 ) ); + Clip::changeLength( qMax( static_cast( _length ), 1 ) ); } -const QString & SampleTCO::sampleFile() const +const QString & SampleClip::sampleFile() const { return m_sampleBuffer->audioFile(); } -void SampleTCO::setSampleBuffer( SampleBuffer* sb ) +void SampleClip::setSampleBuffer( SampleBuffer* sb ) { Engine::audioEngine()->requestChangeInModel(); sharedObject::unref( m_sampleBuffer ); @@ -136,11 +136,11 @@ void SampleTCO::setSampleBuffer( SampleBuffer* sb ) -void SampleTCO::setSampleFile( const QString & _sf ) +void SampleClip::setSampleFile( const QString & _sf ) { int length; if ( _sf.isEmpty() ) - { //When creating an empty sample pattern make it a bar long + { //When creating an empty sample clip make it a bar long float nom = Engine::getSong()->getTimeSigModel().getNumerator(); float den = Engine::getSong()->getTimeSigModel().getDenominator(); length = DefaultTicksPerBar * ( nom / den ); @@ -161,7 +161,7 @@ void SampleTCO::setSampleFile( const QString & _sf ) -void SampleTCO::toggleRecord() +void SampleClip::toggleRecord() { m_recordModel.setValue( !m_recordModel.value() ); emit dataChanged(); @@ -170,29 +170,29 @@ void SampleTCO::toggleRecord() -void SampleTCO::playbackPositionChanged() +void SampleClip::playbackPositionChanged() { Engine::audioEngine()->removePlayHandlesOfTypes( getTrack(), PlayHandle::TypeSamplePlayHandle ); SampleTrack * st = dynamic_cast( getTrack() ); - st->setPlayingTcos( false ); + st->setPlayingClips( false ); } -void SampleTCO::updateTrackTcos() +void SampleClip::updateTrackClips() { SampleTrack * sampletrack = dynamic_cast( getTrack() ); if( sampletrack) { - sampletrack->updateTcos(); + sampletrack->updateClips(); } } -bool SampleTCO::isPlaying() const +bool SampleClip::isPlaying() const { return m_isPlaying; } @@ -200,7 +200,7 @@ bool SampleTCO::isPlaying() const -void SampleTCO::setIsPlaying(bool isPlaying) +void SampleClip::setIsPlaying(bool isPlaying) { m_isPlaying = isPlaying; } @@ -208,7 +208,7 @@ void SampleTCO::setIsPlaying(bool isPlaying) -void SampleTCO::updateLength() +void SampleClip::updateLength() { emit sampleChanged(); } @@ -216,7 +216,7 @@ void SampleTCO::updateLength() -TimePos SampleTCO::sampleLength() const +TimePos SampleClip::sampleLength() const { return (int)( m_sampleBuffer->frames() / Engine::framesPerTick() ); } @@ -224,7 +224,7 @@ TimePos SampleTCO::sampleLength() const -void SampleTCO::setSampleStartFrame(f_cnt_t startFrame) +void SampleClip::setSampleStartFrame(f_cnt_t startFrame) { m_sampleBuffer->setStartFrame( startFrame ); } @@ -232,7 +232,7 @@ void SampleTCO::setSampleStartFrame(f_cnt_t startFrame) -void SampleTCO::setSamplePlayLength(f_cnt_t length) +void SampleClip::setSamplePlayLength(f_cnt_t length) { m_sampleBuffer->setEndFrame( length ); } @@ -240,7 +240,7 @@ void SampleTCO::setSamplePlayLength(f_cnt_t length) -void SampleTCO::saveSettings( QDomDocument & _doc, QDomElement & _this ) +void SampleClip::saveSettings( QDomDocument & _doc, QDomElement & _this ) { if( _this.parentNode().nodeName() == "clipboard" ) { @@ -275,7 +275,7 @@ void SampleTCO::saveSettings( QDomDocument & _doc, QDomElement & _this ) -void SampleTCO::loadSettings( const QDomElement & _this ) +void SampleClip::loadSettings( const QDomElement & _this ) { if( _this.attribute( "pos" ).toInt() >= 0 ) { @@ -307,14 +307,14 @@ void SampleTCO::loadSettings( const QDomElement & _this ) if(_this.hasAttribute("reversed")) { m_sampleBuffer->setReversed(true); - emit wasReversed(); // tell SampleTCOView to update the view + emit wasReversed(); // tell SampleClipView to update the view } } -TrackContentObjectView * SampleTCO::createView( TrackView * _tv ) +ClipView * SampleClip::createView( TrackView * _tv ) { - return new SampleTCOView( this, _tv ); + return new SampleClipView( this, _tv ); } \ No newline at end of file diff --git a/src/core/SamplePlayHandle.cpp b/src/core/SamplePlayHandle.cpp index 3c38a858fb1..a904e3d3442 100644 --- a/src/core/SamplePlayHandle.cpp +++ b/src/core/SamplePlayHandle.cpp @@ -29,7 +29,7 @@ #include "Engine.h" #include "InstrumentTrack.h" #include "lmms_constants.h" -#include "SampleTCO.h" +#include "SampleClip.h" @@ -62,11 +62,11 @@ SamplePlayHandle::SamplePlayHandle( const QString& sampleFile ) : -SamplePlayHandle::SamplePlayHandle( SampleTCO* tco ) : - SamplePlayHandle( tco->sampleBuffer() , false) +SamplePlayHandle::SamplePlayHandle( SampleClip* clip ) : + SamplePlayHandle( clip->sampleBuffer() , false) { - m_track = tco->getTrack(); - setAudioPort( ( (SampleTrack *)tco->getTrack() )->audioPort() ); + m_track = clip->getTrack(); + setAudioPort( ( (SampleTrack *)clip->getTrack() )->audioPort() ); } diff --git a/src/core/SampleRecordHandle.cpp b/src/core/SampleRecordHandle.cpp index a86d19b79cf..ba1d0b0163e 100644 --- a/src/core/SampleRecordHandle.cpp +++ b/src/core/SampleRecordHandle.cpp @@ -33,13 +33,13 @@ #include "debug.h" -SampleRecordHandle::SampleRecordHandle( SampleTCO* tco ) : +SampleRecordHandle::SampleRecordHandle( SampleClip* clip ) : PlayHandle( TypeSamplePlayHandle ), m_framesRecorded( 0 ), - m_minLength( tco->length() ), - m_track( tco->getTrack() ), + m_minLength( clip->length() ), + m_track( clip->getTrack() ), m_bbTrack( nullptr ), - m_tco( tco ) + m_clip( clip ) { } @@ -52,7 +52,7 @@ SampleRecordHandle::~SampleRecordHandle() { SampleBuffer* sb; createSampleBuffer( &sb ); - m_tco->setSampleBuffer( sb ); + m_clip->setSampleBuffer( sb ); } while( !m_buffers.empty() ) @@ -60,7 +60,7 @@ SampleRecordHandle::~SampleRecordHandle() delete[] m_buffers.front().first; m_buffers.erase( m_buffers.begin() ); } - m_tco->setRecord( false ); + m_clip->setRecord( false ); } @@ -76,7 +76,7 @@ void SampleRecordHandle::play( sampleFrame * /*_working_buffer*/ ) TimePos len = (tick_t)( m_framesRecorded / Engine::framesPerTick() ); if( len > m_minLength ) { -// m_tco->changeLength( len ); +// m_clip->changeLength( len ); m_minLength = len; } } diff --git a/src/core/Song.cpp b/src/core/Song.cpp index 6b9d1f70dd0..0d48f718b2b 100644 --- a/src/core/Song.cpp +++ b/src/core/Song.cpp @@ -50,7 +50,7 @@ #include "ExportFilter.h" #include "InstrumentTrack.h" #include "NotePlayHandle.h" -#include "Pattern.h" +#include "MidiClip.h" #include "PianoRoll.h" #include "ProjectJournal.h" #include "ProjectNotes.h" @@ -89,8 +89,8 @@ Song::Song() : m_isCancelled( false ), m_playMode( Mode_None ), m_length( 0 ), - m_patternToPlay( nullptr ), - m_loopPattern( false ), + m_midiClipToPlay( nullptr ), + m_loopMidiClip( false ), m_elapsedTicks( 0 ), m_elapsedBars( 0 ), m_loopRenderCount(1), @@ -227,11 +227,11 @@ void Song::processNextBuffer() } break; - case Mode_PlayPattern: - if (m_patternToPlay) + case Mode_PlayMidiClip: + if (m_midiClipToPlay) { - clipNum = m_patternToPlay->getTrack()->getTCONum(m_patternToPlay); - trackList.push_back(m_patternToPlay->getTrack()); + clipNum = m_midiClipToPlay->getTrack()->getClipNum(m_midiClipToPlay); + trackList.push_back(m_midiClipToPlay->getTrack()); } break; @@ -288,15 +288,15 @@ void Song::processNextBuffer() frameOffsetInTick -= elapsedTicks * framesPerTick; getPlayPos().setCurrentFrame(frameOffsetInTick); - // If we are playing a BB track, or a pattern with no loop enabled, + // If we are playing a BB track, or a MIDI clip with no loop enabled, // loop back to the beginning when we reach the end if (m_playMode == Mode_PlayBB) { enforceLoop(TimePos{0}, TimePos{Engine::getBBTrackContainer()->lengthOfCurrentBB(), 0}); } - else if (m_playMode == Mode_PlayPattern && m_loopPattern && !loopEnabled) + else if (m_playMode == Mode_PlayMidiClip && m_loopMidiClip && !loopEnabled) { - enforceLoop(TimePos{0}, m_patternToPlay->length()); + enforceLoop(TimePos{0}, m_midiClipToPlay->length()); } // Handle loop points, and inform VST plugins of the loop status @@ -362,7 +362,7 @@ void Song::processAutomations(const TrackList &tracklist, TimePos timeStart, fpp QSet recordedModels; TrackContainer* container = this; - int tcoNum = -1; + int clipNum = -1; switch (m_playMode) { @@ -375,28 +375,28 @@ void Song::processAutomations(const TrackList &tracklist, TimePos timeStart, fpp auto bbTrack = dynamic_cast(tracklist.at(0)); auto bbContainer = Engine::getBBTrackContainer(); container = bbContainer; - tcoNum = bbTrack->index(); + clipNum = bbTrack->index(); } break; default: return; } - values = container->automatedValuesAt(timeStart, tcoNum); + values = container->automatedValuesAt(timeStart, clipNum); TrackList tracks = container->tracks(); - Track::tcoVector tcos; + Track::clipVector clips; for (Track* track : tracks) { if (track->type() == Track::AutomationTrack) { - track->getTCOsInRange(tcos, 0, timeStart); + track->getClipsInRange(clips, 0, timeStart); } } // Process recording - for (TrackContentObject* tco : tcos) + for (Clip* clip : clips) { - auto p = dynamic_cast(tco); + auto p = dynamic_cast(clip); TimePos relTime = timeStart - p->startPosition(); if (p->isRecording() && relTime >= 0 && relTime < p->length()) { @@ -407,7 +407,7 @@ void Song::processAutomations(const TrackList &tracklist, TimePos timeStart, fpp } } - // Checks if an automated model stopped being automated by automation patterns + // Checks if an automated model stopped being automated by automation clip // so we can move the control back to any connected controller again for (auto it = m_oldAutomatedValues.begin(); it != m_oldAutomatedValues.end(); it++) { @@ -539,19 +539,19 @@ void Song::playBB() -void Song::playPattern( const Pattern* patternToPlay, bool loop ) +void Song::playMidiClip( const MidiClip* midiClipToPlay, bool loop ) { if( isStopped() == false ) { stop(); } - m_patternToPlay = patternToPlay; - m_loopPattern = loop; + m_midiClipToPlay = midiClipToPlay; + m_loopMidiClip = loop; - if( m_patternToPlay != nullptr ) + if( m_midiClipToPlay != nullptr ) { - m_playMode = Mode_PlayPattern; + m_playMode = Mode_PlayMidiClip; m_playing = true; m_paused = false; } @@ -835,15 +835,15 @@ bpm_t Song::getTempo() -AutomationPattern * Song::tempoAutomationPattern() +AutomationClip * Song::tempoAutomationClip() { - return AutomationPattern::globalAutomationPattern( &m_tempoModel ); + return AutomationClip::globalAutomationClip( &m_tempoModel ); } -AutomatedValueMap Song::automatedValuesAt(TimePos time, int tcoNum) const +AutomatedValueMap Song::automatedValuesAt(TimePos time, int clipNum) const { - return TrackContainer::automatedValuesFromTracks(TrackList{m_globalAutomationTrack} << tracks(), time, tcoNum); + return TrackContainer::automatedValuesFromTracks(TrackList{m_globalAutomationTrack} << tracks(), time, clipNum); } @@ -886,7 +886,7 @@ void Song::clearProject() if( getGUI() != nullptr && getGUI()->automationEditor() ) { - getGUI()->automationEditor()->setCurrentPattern( nullptr ); + getGUI()->automationEditor()->setCurrentClip( nullptr ); } if( getGUI() != nullptr && getGUI()->pianoRoll() ) @@ -902,10 +902,10 @@ void Song::clearProject() // Clear the m_oldAutomatedValues AutomatedValueMap m_oldAutomatedValues.clear(); - AutomationPattern::globalAutomationPattern( &m_tempoModel )->clear(); - AutomationPattern::globalAutomationPattern( &m_masterVolumeModel )-> + AutomationClip::globalAutomationClip( &m_tempoModel )->clear(); + AutomationClip::globalAutomationClip( &m_masterVolumeModel )-> clear(); - AutomationPattern::globalAutomationPattern( &m_masterPitchModel )-> + AutomationClip::globalAutomationClip( &m_masterPitchModel )-> clear(); Engine::audioEngine()->doneChangeInModel(); @@ -1169,7 +1169,7 @@ void Song::loadProject( const QString & fileName ) node = node.nextSibling(); } - // quirk for fixing projects with broken positions of TCOs inside + // quirk for fixing projects with broken positions of Clips inside // BB-tracks Engine::getBBTrackContainer()->fixIncorrectPositions(); @@ -1183,7 +1183,7 @@ void Song::loadProject( const QString & fileName ) m_controllers.end()); // resolve all IDs so that autoModels are automated - AutomationPattern::resolveAllIDs(); + AutomationClip::resolveAllIDs(); Engine::audioEngine()->doneChangeInModel(); diff --git a/src/core/StepRecorder.cpp b/src/core/StepRecorder.cpp index bd117f5493c..96b93320f90 100644 --- a/src/core/StepRecorder.cpp +++ b/src/core/StepRecorder.cpp @@ -33,7 +33,7 @@ const int REMOVE_RELEASED_NOTE_TIME_THRESHOLD_MS = 70; StepRecorder::StepRecorder(PianoRoll& pianoRoll, StepRecorderWidget& stepRecorderWidget): m_pianoRoll(pianoRoll), m_stepRecorderWidget(stepRecorderWidget), - m_pattern(nullptr) + m_midiClip(nullptr) { m_stepRecorderWidget.hide(); } @@ -109,7 +109,7 @@ void StepRecorder::noteReleased(const Note & n) m_updateReleasedTimer.start(REMOVE_RELEASED_NOTE_TIME_THRESHOLD_MS); } - //check if all note are released, apply notes to pattern(or dimiss if length is zero) and prepare to record next step + //check if all note are released, apply notes to clips (or dimiss if length is zero) and prepare to record next step if(allCurStepNotesReleased()) { if(m_curStepLength > 0) @@ -226,16 +226,16 @@ void StepRecorder::stepBackwards() void StepRecorder::applyStep() { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); for (const StepNote* stepNote : m_curStepNotes) { - m_pattern->addNote(stepNote->m_note, false); + m_midiClip->addNote(stepNote->m_note, false); } - m_pattern->rearrangeAllNotes(); - m_pattern->updateLength(); - m_pattern->dataChanged(); + m_midiClip->rearrangeAllNotes(); + m_midiClip->updateLength(); + m_midiClip->dataChanged(); Engine::getSong()->setModified(); prepareNewStep(); @@ -267,14 +267,14 @@ void StepRecorder::prepareNewStep() updateWidget(); } -void StepRecorder::setCurrentPattern( Pattern* newPattern ) +void StepRecorder::setCurrentMidiClip( MidiClip* newMidiClip ) { - if(m_pattern != nullptr && m_pattern != newPattern) + if(m_midiClip != nullptr && m_midiClip != newMidiClip) { dismissStep(); } - m_pattern = newPattern; + m_midiClip = newMidiClip; } void StepRecorder::removeNotesReleasedForTooLong() diff --git a/src/core/Track.cpp b/src/core/Track.cpp index a79a79c652c..800662256b4 100644 --- a/src/core/Track.cpp +++ b/src/core/Track.cpp @@ -31,7 +31,7 @@ #include -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "AutomationTrack.h" #include "BBTrack.h" #include "BBTrackContainer.h" @@ -60,7 +60,7 @@ Track::Track( TrackTypes type, TrackContainer * tc ) : m_mutedModel( false, this, tr( "Mute" ) ), /*!< For controlling track muting */ m_soloModel( false, this, tr( "Solo" ) ), /*!< For controlling track soloing */ m_simpleSerializingMode( false ), - m_trackContentObjects(), /*!< The track content objects (segments) */ + m_clips(), /*!< The clips (segments) */ m_color( 0, 0, 0 ), m_hasColor( false ) { @@ -76,7 +76,7 @@ Track::Track( TrackTypes type, TrackContainer * tc ) : * If the track container is a Beat+Bassline container, step through * its list of tracks and remove us. * - * Then delete the TrackContentObject's contents, remove this track from + * Then delete the Clip's contents, remove this track from * the track container. * * Finally step through this track's automation and forget all of them. @@ -86,9 +86,9 @@ Track::~Track() lock(); emit destroyedTrack(); - while( !m_trackContentObjects.isEmpty() ) + while( !m_clips.isEmpty() ) { - delete m_trackContentObjects.last(); + delete m_clips.last(); } m_trackContainer->removeTrack( this ); @@ -124,7 +124,7 @@ Track * Track::create( TrackTypes tt, TrackContainer * tc ) if( tc == Engine::getBBTrackContainer() && t ) { - t->createTCOsForBB( Engine::getBBTrackContainer()->numOfBBs() + t->createClipsForBB( Engine::getBBTrackContainer()->numOfBBs() - 1 ); } @@ -173,7 +173,7 @@ Track* Track::clone() saveState(doc, parent); Track* t = create(parent.firstChild().toElement(), m_trackContainer); - AutomationPattern::resolveAllIDs(); + AutomationClip::resolveAllIDs(); return t; } @@ -185,7 +185,7 @@ Track* Track::clone() /*! \brief Save this track's settings to file * * We save the track type and its muted state and solo state, then append the track- - * specific settings. Then we iterate through the trackContentObjects + * specific settings. Then we iterate through the clips * and save all their states in turn. * * \param doc The QDomDocument to use to save @@ -228,9 +228,9 @@ void Track::saveSettings( QDomDocument & doc, QDomElement & element ) return; } - // now save settings of all TCO's - for( tcoVector::const_iterator it = m_trackContentObjects.begin(); - it != m_trackContentObjects.end(); ++it ) + // now save settings of all Clip's + for( clipVector::const_iterator it = m_clips.begin(); + it != m_clips.end(); ++it ) { ( *it )->saveState( doc, element ); } @@ -242,10 +242,10 @@ void Track::saveSettings( QDomDocument & doc, QDomElement & element ) /*! \brief Load the settings from a file * * We load the track's type and muted state and solo state, then clear out our - * current TrackContentObject. + * current Clip. * * Then we step through the QDomElement's children and load the - * track-specific settings and trackContentObjects states from it + * track-specific settings and clip states from it * one at a time. * * \param element the QDomElement to load track settings from @@ -294,10 +294,10 @@ void Track::loadSettings( const QDomElement & element ) return; } - while( !m_trackContentObjects.empty() ) + while( !m_clips.empty() ) { - delete m_trackContentObjects.front(); -// m_trackContentObjects.erase( m_trackContentObjects.begin() ); + delete m_clips.front(); +// m_clips.erase( m_clips.begin() ); } QDomNode node = element.firstChild(); @@ -313,9 +313,9 @@ void Track::loadSettings( const QDomElement & element ) && node.nodeName() != "solo" && !node.toElement().attribute( "metadata" ).toInt() ) { - TrackContentObject * tco = createTCO( + Clip * clip = createClip( TimePos( 0 ) ); - tco->restoreState( node.toElement() ); + clip->restoreState( node.toElement() ); } } node = node.nextSibling(); @@ -331,34 +331,32 @@ void Track::loadSettings( const QDomElement & element ) -/*! \brief Add another TrackContentObject into this track +/*! \brief Add another Clip into this track * - * \param tco The TrackContentObject to attach to this track. + * \param clip The Clip to attach to this track. */ -TrackContentObject * Track::addTCO( TrackContentObject * tco ) +Clip * Track::addClip( Clip * clip ) { - m_trackContentObjects.push_back( tco ); + m_clips.push_back( clip ); - emit trackContentObjectAdded( tco ); + emit clipAdded( clip ); - return tco; // just for convenience + return clip; // just for convenience } -/*! \brief Remove a given TrackContentObject from this track +/*! \brief Remove a given Clip from this track * - * \param tco The TrackContentObject to remove from this track. + * \param clip The Clip to remove from this track. */ -void Track::removeTCO( TrackContentObject * tco ) +void Track::removeClip( Clip * clip ) { - tcoVector::iterator it = std::find( m_trackContentObjects.begin(), - m_trackContentObjects.end(), - tco ); - if( it != m_trackContentObjects.end() ) + clipVector::iterator it = std::find( m_clips.begin(), m_clips.end(), clip ); + if( it != m_clips.end() ) { - m_trackContentObjects.erase( it ); + m_clips.erase( it ); if( Engine::getSong() ) { Engine::getSong()->updateLength(); @@ -368,105 +366,103 @@ void Track::removeTCO( TrackContentObject * tco ) } -/*! \brief Remove all TCOs from this track */ -void Track::deleteTCOs() +/*! \brief Remove all Clips from this track */ +void Track::deleteClips() { - while( ! m_trackContentObjects.isEmpty() ) + while( ! m_clips.isEmpty() ) { - delete m_trackContentObjects.first(); + delete m_clips.first(); } } -/*! \brief Return the number of trackContentObjects we contain +/*! \brief Return the number of clips we contain * - * \return the number of trackContentObjects we currently contain. + * \return the number of clips we currently contain. */ -int Track::numOfTCOs() +int Track::numOfClips() { - return m_trackContentObjects.size(); + return m_clips.size(); } -/*! \brief Get a TrackContentObject by number +/*! \brief Get a Clip by number * - * If the TCO number is less than our TCO array size then fetch that + * If the Clip number is less than our Clip array size then fetch that * numbered object from the array. Otherwise we warn the user that - * we've somehow requested a TCO that is too large, and create a new - * TCO for them. - * \param tcoNum The number of the TrackContentObject to fetch. - * \return the given TrackContentObject or a new one if out of range. - * \todo reject TCO numbers less than zero. - * \todo if we create a TCO here, should we somehow attach it to the + * we've somehow requested a Clip that is too large, and create a new + * Clip for them. + * \param clipNum The number of the Clip to fetch. + * \return the given Clip or a new one if out of range. + * \todo reject Clip numbers less than zero. + * \todo if we create a Clip here, should we somehow attach it to the * track? */ -TrackContentObject * Track::getTCO( int tcoNum ) +Clip * Track::getClip( int clipNum ) { - if( tcoNum < m_trackContentObjects.size() ) + if( clipNum < m_clips.size() ) { - return m_trackContentObjects[tcoNum]; + return m_clips[clipNum]; } - printf( "called Track::getTCO( %d ), " - "but TCO %d doesn't exist\n", tcoNum, tcoNum ); - return createTCO( tcoNum * TimePos::ticksPerBar() ); + printf( "called Track::getClip( %d ), " + "but Clip %d doesn't exist\n", clipNum, clipNum ); + return createClip( clipNum * TimePos::ticksPerBar() ); } -/*! \brief Determine the given TrackContentObject's number in our array. +/*! \brief Determine the given Clip's number in our array. * - * \param tco The TrackContentObject to search for. + * \param clip The Clip to search for. * \return its number in our array. */ -int Track::getTCONum( const TrackContentObject * tco ) +int Track::getClipNum( const Clip * clip ) { -// for( int i = 0; i < getTrackContentWidget()->numOfTCOs(); ++i ) - tcoVector::iterator it = std::find( m_trackContentObjects.begin(), - m_trackContentObjects.end(), - tco ); - if( it != m_trackContentObjects.end() ) +// for( int i = 0; i < getTrackContentWidget()->numOfClips(); ++i ) + clipVector::iterator it = std::find( m_clips.begin(), m_clips.end(), clip ); + if( it != m_clips.end() ) { -/* if( getTCO( i ) == _tco ) +/* if( getClip( i ) == _clip ) { return i; }*/ - return it - m_trackContentObjects.begin(); + return it - m_clips.begin(); } - qWarning( "Track::getTCONum(...) -> _tco not found!\n" ); + qWarning( "Track::getClipNum(...) -> _clip not found!\n" ); return 0; } -/*! \brief Retrieve a list of trackContentObjects that fall within a period. +/*! \brief Retrieve a list of clips that fall within a period. * - * Here we're interested in a range of trackContentObjects that intersect + * Here we're interested in a range of clips that intersect * the given time period. * - * We return the TCOs we find in order by time, earliest TCOs first. + * We return the Clips we find in order by time, earliest Clips first. * - * \param tcoV The list to contain the found trackContentObjects. + * \param clipV The list to contain the found clips. * \param start The MIDI start time of the range. * \param end The MIDI endi time of the range. */ -void Track::getTCOsInRange( tcoVector & tcoV, const TimePos & start, +void Track::getClipsInRange( clipVector & clipV, const TimePos & start, const TimePos & end ) { - for( TrackContentObject* tco : m_trackContentObjects ) + for( Clip* clip : m_clips ) { - int s = tco->startPosition(); - int e = tco->endPosition(); + int s = clip->startPosition(); + int e = clip->endPosition(); if( ( s <= end ) && ( e >= start ) ) { - // TCO is within given range - // Insert sorted by TCO's position - tcoV.insert(std::upper_bound(tcoV.begin(), tcoV.end(), tco, TrackContentObject::comparePosition), - tco); + // Clip is within given range + // Insert sorted by Clip's position + clipV.insert(std::upper_bound(clipV.begin(), clipV.end(), clip, Clip::comparePosition), + clip); } } } @@ -474,55 +470,53 @@ void Track::getTCOsInRange( tcoVector & tcoV, const TimePos & start, -/*! \brief Swap the position of two trackContentObjects. +/*! \brief Swap the position of two clips. * - * First, we arrange to swap the positions of the two TCOs in the - * trackContentObjects list. Then we swap their start times as well. + * First, we arrange to swap the positions of the two Clips in the + * clips list. Then we swap their start times as well. * - * \param tcoNum1 The first TrackContentObject to swap. - * \param tcoNum2 The second TrackContentObject to swap. + * \param clipNum1 The first Clip to swap. + * \param clipNum2 The second Clip to swap. */ -void Track::swapPositionOfTCOs( int tcoNum1, int tcoNum2 ) +void Track::swapPositionOfClips( int clipNum1, int clipNum2 ) { - qSwap( m_trackContentObjects[tcoNum1], - m_trackContentObjects[tcoNum2] ); + qSwap( m_clips[clipNum1], m_clips[clipNum2] ); - const TimePos pos = m_trackContentObjects[tcoNum1]->startPosition(); + const TimePos pos = m_clips[clipNum1]->startPosition(); - m_trackContentObjects[tcoNum1]->movePosition( - m_trackContentObjects[tcoNum2]->startPosition() ); - m_trackContentObjects[tcoNum2]->movePosition( pos ); + m_clips[clipNum1]->movePosition( m_clips[clipNum2]->startPosition() ); + m_clips[clipNum2]->movePosition( pos ); } -void Track::createTCOsForBB( int bb ) +void Track::createClipsForBB( int bb ) { - while( numOfTCOs() < bb + 1 ) + while( numOfClips() < bb + 1 ) { - TimePos position = TimePos( numOfTCOs(), 0 ); - TrackContentObject * tco = createTCO( position ); - tco->changeLength( TimePos( 1, 0 ) ); + TimePos position = TimePos( numOfClips(), 0 ); + Clip * clip = createClip( position ); + clip->changeLength( TimePos( 1, 0 ) ); } } -/*! \brief Move all the trackContentObjects after a certain time later by one bar. +/*! \brief Move all the clips after a certain time later by one bar. * * \param pos The time at which we want to insert the bar. * \todo if we stepped through this list last to first, and the list was - * in ascending order by TCO time, once we hit a TCO that was earlier + * in ascending order by Clip time, once we hit a Clip that was earlier * than the insert time, we could fall out of the loop early. */ void Track::insertBar( const TimePos & pos ) { - // we'll increase the position of every TCO, positioned behind pos, by + // we'll increase the position of every Clip, positioned behind pos, by // one bar - for( tcoVector::iterator it = m_trackContentObjects.begin(); - it != m_trackContentObjects.end(); ++it ) + for( clipVector::iterator it = m_clips.begin(); + it != m_clips.end(); ++it ) { if( ( *it )->startPosition() >= pos ) { @@ -535,16 +529,15 @@ void Track::insertBar( const TimePos & pos ) -/*! \brief Move all the trackContentObjects after a certain time earlier by one bar. +/*! \brief Move all the clips after a certain time earlier by one bar. * * \param pos The time at which we want to remove the bar. */ void Track::removeBar( const TimePos & pos ) { - // we'll decrease the position of every TCO, positioned behind pos, by + // we'll decrease the position of every Clip, positioned behind pos, by // one bar - for( tcoVector::iterator it = m_trackContentObjects.begin(); - it != m_trackContentObjects.end(); ++it ) + for( clipVector::iterator it = m_clips.begin(); it != m_clips.end(); ++it ) { if( ( *it )->startPosition() >= pos ) { @@ -558,7 +551,7 @@ void Track::removeBar( const TimePos & pos ) /*! \brief Return the length of the entire track in bars * - * We step through our list of TCOs and determine their end position, + * We step through our list of Clips and determine their end position, * keeping track of the latest time found in ticks. Then we return * that in bars by dividing by the number of ticks per bar. */ @@ -566,8 +559,7 @@ bar_t Track::length() const { // find last end-position tick_t last = 0; - for( tcoVector::const_iterator it = m_trackContentObjects.begin(); - it != m_trackContentObjects.end(); ++it ) + for( clipVector::const_iterator it = m_clips.begin(); it != m_clips.end(); ++it ) { if( Engine::getSong()->isExporting() && ( *it )->isMuted() ) diff --git a/src/core/TrackContainer.cpp b/src/core/TrackContainer.cpp index 3995981c6ba..881e76d9ffd 100644 --- a/src/core/TrackContainer.cpp +++ b/src/core/TrackContainer.cpp @@ -29,7 +29,7 @@ #include #include -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "AutomationTrack.h" #include "BBTrack.h" #include "BBTrackContainer.h" @@ -238,7 +238,7 @@ bool TrackContainer::isEmpty() const for( TrackList::const_iterator it = m_tracks.begin(); it != m_tracks.end(); ++it ) { - if( !( *it )->getTCOs().isEmpty() ) + if( !( *it )->getClips().isEmpty() ) { return false; } @@ -248,15 +248,15 @@ bool TrackContainer::isEmpty() const -AutomatedValueMap TrackContainer::automatedValuesAt(TimePos time, int tcoNum) const +AutomatedValueMap TrackContainer::automatedValuesAt(TimePos time, int clipNum) const { - return automatedValuesFromTracks(tracks(), time, tcoNum); + return automatedValuesFromTracks(tracks(), time, clipNum); } -AutomatedValueMap TrackContainer::automatedValuesFromTracks(const TrackList &tracks, TimePos time, int tcoNum) +AutomatedValueMap TrackContainer::automatedValuesFromTracks(const TrackList &tracks, TimePos time, int clipNum) { - Track::tcoVector tcos; + Track::clipVector clips; for (Track* track: tracks) { @@ -269,11 +269,11 @@ AutomatedValueMap TrackContainer::automatedValuesFromTracks(const TrackList &tra case Track::AutomationTrack: case Track::HiddenAutomationTrack: case Track::BBTrack: - if (tcoNum < 0) { - track->getTCOsInRange(tcos, 0, time); + if (clipNum < 0) { + track->getClipsInRange(clips, 0, time); } else { - Q_ASSERT(track->numOfTCOs() > tcoNum); - tcos << track->getTCO(tcoNum); + Q_ASSERT(track->numOfClips() > clipNum); + clips << track->getClip(clipNum); } default: break; @@ -282,15 +282,15 @@ AutomatedValueMap TrackContainer::automatedValuesFromTracks(const TrackList &tra AutomatedValueMap valueMap; - Q_ASSERT(std::is_sorted(tcos.begin(), tcos.end(), TrackContentObject::comparePosition)); + Q_ASSERT(std::is_sorted(clips.begin(), clips.end(), Clip::comparePosition)); - for(TrackContentObject* tco : tcos) + for(Clip* clip : clips) { - if (tco->isMuted() || tco->startPosition() > time) { + if (clip->isMuted() || clip->startPosition() > time) { continue; } - if (auto* p = dynamic_cast(tco)) + if (auto* p = dynamic_cast(clip)) { if (! p->hasAutomation()) { continue; @@ -306,13 +306,13 @@ AutomatedValueMap TrackContainer::automatedValuesFromTracks(const TrackList &tra valueMap[model] = value; } } - else if (auto* bb = dynamic_cast(tco)) + else if (auto* bb = dynamic_cast(clip)) { auto bbIndex = dynamic_cast(bb->getTrack())->index(); auto bbContainer = Engine::getBBTrackContainer(); - TimePos bbTime = time - tco->startPosition(); - bbTime = std::min(bbTime, tco->length()); + TimePos bbTime = time - clip->startPosition(); + bbTime = std::min(bbTime, clip->length()); bbTime = bbTime % (bbContainer->lengthOfBB(bbIndex) * TimePos::ticksPerBar()); auto bbValues = bbContainer->automatedValuesAt(bbTime, bbIndex); diff --git a/src/gui/AutomatableModelView.cpp b/src/gui/AutomatableModelView.cpp index 6427134dc4d..ba89d043cb6 100644 --- a/src/gui/AutomatableModelView.cpp +++ b/src/gui/AutomatableModelView.cpp @@ -27,7 +27,7 @@ #include #include "AutomatableModelView.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "ControllerConnectionDialog.h" #include "ControllerConnection.h" #include "embed.h" @@ -261,7 +261,7 @@ void AutomatableModelViewSlots::removeConnection() void AutomatableModelViewSlots::editSongGlobalAutomation() { getGUI()->automationEditor()->open( - AutomationPattern::globalAutomationPattern(m_amv->modelUntyped()) + AutomationClip::globalAutomationClip(m_amv->modelUntyped()) ); } @@ -269,7 +269,7 @@ void AutomatableModelViewSlots::editSongGlobalAutomation() void AutomatableModelViewSlots::removeSongGlobalAutomation() { - delete AutomationPattern::globalAutomationPattern( m_amv->modelUntyped() ); + delete AutomationClip::globalAutomationClip( m_amv->modelUntyped() ); } diff --git a/src/gui/AutomationPatternView.cpp b/src/gui/AutomationClipView.cpp similarity index 65% rename from src/gui/AutomationPatternView.cpp rename to src/gui/AutomationClipView.cpp index b40c91dc08c..47fa2e04663 100644 --- a/src/gui/AutomationPatternView.cpp +++ b/src/gui/AutomationClipView.cpp @@ -1,5 +1,5 @@ /* - * AutomationPatternView.cpp - implementation of view for AutomationPattern + * AutomationClipView.cpp - implementation of view for AutomationClip * * Copyright (c) 2008-2010 Tobias Doerffel * @@ -21,7 +21,7 @@ * Boston, MA 02110-1301 USA. * */ -#include "AutomationPatternView.h" +#include "AutomationClipView.h" #include #include @@ -41,26 +41,26 @@ #include "Engine.h" -QPixmap * AutomationPatternView::s_pat_rec = nullptr; +QPixmap * AutomationClipView::s_clip_rec = nullptr; -AutomationPatternView::AutomationPatternView( AutomationPattern * _pattern, +AutomationClipView::AutomationClipView( AutomationClip * _clip, TrackView * _parent ) : - TrackContentObjectView( _pattern, _parent ), - m_pat( _pattern ), + ClipView( _clip, _parent ), + m_clip( _clip ), m_paintPixmap() { - connect( m_pat, SIGNAL( dataChanged() ), + connect( m_clip, SIGNAL( dataChanged() ), this, SLOT( update() ) ); - connect( getGUI()->automationEditor(), SIGNAL( currentPatternChanged() ), + connect( getGUI()->automationEditor(), SIGNAL( currentClipChanged() ), this, SLOT( update() ) ); setAttribute( Qt::WA_OpaquePaintEvent, true ); - ToolTip::add(this, m_pat->name()); + ToolTip::add(this, m_clip->name()); setStyle( QApplication::style() ); - if( s_pat_rec == nullptr ) { s_pat_rec = new QPixmap( embed::getIconPixmap( - "pat_rec" ) ); } + if( s_clip_rec == nullptr ) { s_clip_rec = new QPixmap( embed::getIconPixmap( + "clip_rec" ) ); } update(); } @@ -68,71 +68,71 @@ AutomationPatternView::AutomationPatternView( AutomationPattern * _pattern, -AutomationPatternView::~AutomationPatternView() +AutomationClipView::~AutomationClipView() { } -void AutomationPatternView::openInAutomationEditor() +void AutomationClipView::openInAutomationEditor() { if(getGUI() != nullptr) - getGUI()->automationEditor()->open(m_pat); + getGUI()->automationEditor()->open(m_clip); } -void AutomationPatternView::update() +void AutomationClipView::update() { - ToolTip::add(this, m_pat->name()); + ToolTip::add(this, m_clip->name()); - TrackContentObjectView::update(); + ClipView::update(); } -void AutomationPatternView::resetName() +void AutomationClipView::resetName() { - m_pat->setName( QString() ); + m_clip->setName( QString() ); } -void AutomationPatternView::changeName() +void AutomationClipView::changeName() { - QString s = m_pat->name(); + QString s = m_clip->name(); RenameDialog rename_dlg( s ); rename_dlg.exec(); - m_pat->setName( s ); + m_clip->setName( s ); update(); } -void AutomationPatternView::disconnectObject( QAction * _a ) +void AutomationClipView::disconnectObject( QAction * _a ) { JournallingObject * j = Engine::projectJournal()-> journallingObject( _a->data().toInt() ); if( j && dynamic_cast( j ) ) { - float oldMin = m_pat->getMin(); - float oldMax = m_pat->getMax(); + float oldMin = m_clip->getMin(); + float oldMax = m_clip->getMax(); - m_pat->m_objects.erase( std::find( m_pat->m_objects.begin(), - m_pat->m_objects.end(), + m_clip->m_objects.erase( std::find( m_clip->m_objects.begin(), + m_clip->m_objects.end(), dynamic_cast( j ) ) ); update(); //If automation editor is opened, update its display after disconnection if( getGUI()->automationEditor() ) { - getGUI()->automationEditor()->m_editor->updateAfterPatternChange(); + getGUI()->automationEditor()->m_editor->updateAfterClipChange(); } - //if there is no more connection connected to the AutomationPattern - if( m_pat->m_objects.size() == 0 ) + //if there is no more connection connected to the AutomationClip + if( m_clip->m_objects.size() == 0 ) { //scale the points to fit the new min. and max. value this->scaleTimemapToFit( oldMin, oldMax ); @@ -141,34 +141,34 @@ void AutomationPatternView::disconnectObject( QAction * _a ) } -void AutomationPatternView::toggleRecording() +void AutomationClipView::toggleRecording() { - m_pat->setRecording( ! m_pat->isRecording() ); + m_clip->setRecording( ! m_clip->isRecording() ); update(); } -void AutomationPatternView::flipY() +void AutomationClipView::flipY() { - m_pat->flipY( m_pat->getMin(), m_pat->getMax() ); + m_clip->flipY( m_clip->getMin(), m_clip->getMax() ); update(); } -void AutomationPatternView::flipX() +void AutomationClipView::flipX() { - m_pat->flipX( m_pat->length() ); + m_clip->flipX( m_clip->length() ); update(); } -void AutomationPatternView::constructContextMenu( QMenu * _cm ) +void AutomationClipView::constructContextMenu( QMenu * _cm ) { QAction * a = new QAction( embed::getIconPixmap( "automation" ), tr( "Open in Automation editor" ), _cm ); @@ -179,7 +179,7 @@ void AutomationPatternView::constructContextMenu( QMenu * _cm ) _cm->addSeparator(); _cm->addAction( embed::getIconPixmap( "edit_erase" ), - tr( "Clear" ), m_pat, SLOT( clear() ) ); + tr( "Clear" ), m_clip, SLOT( clear() ) ); _cm->addSeparator(); _cm->addAction( embed::getIconPixmap( "reload" ), tr( "Reset name" ), @@ -196,14 +196,14 @@ void AutomationPatternView::constructContextMenu( QMenu * _cm ) _cm->addAction( embed::getIconPixmap( "flip_x" ), tr( "Flip Horizontally (Visible)" ), this, SLOT( flipX() ) ); - if( !m_pat->m_objects.isEmpty() ) + if( !m_clip->m_objects.isEmpty() ) { _cm->addSeparator(); QMenu * m = new QMenu( tr( "%1 Connections" ). - arg( m_pat->m_objects.count() ), _cm ); - for( AutomationPattern::objectVector::iterator it = - m_pat->m_objects.begin(); - it != m_pat->m_objects.end(); ++it ) + arg( m_clip->m_objects.count() ), _cm ); + for( AutomationClip::objectVector::iterator it = + m_clip->m_objects.begin(); + it != m_clip->m_objects.end(); ++it ) { if( *it ) { @@ -222,7 +222,7 @@ void AutomationPatternView::constructContextMenu( QMenu * _cm ) -void AutomationPatternView::mouseDoubleClickEvent( QMouseEvent * me ) +void AutomationClipView::mouseDoubleClickEvent( QMouseEvent * me ) { if(me->button() != Qt::LeftButton) { @@ -235,7 +235,7 @@ void AutomationPatternView::mouseDoubleClickEvent( QMouseEvent * me ) -void AutomationPatternView::paintEvent( QPaintEvent * ) +void AutomationClipView::paintEvent( QPaintEvent * ) { QPainter painter( this ); @@ -256,13 +256,13 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) QLinearGradient lingrad( 0, 0, 0, height() ); QColor c = getColorForDisplay( painter.background().color() ); - bool muted = m_pat->getTrack()->isMuted() || m_pat->isMuted(); - bool current = getGUI()->automationEditor()->currentPattern() == m_pat; + bool muted = m_clip->getTrack()->isMuted() || m_clip->isMuted(); + bool current = getGUI()->automationEditor()->currentClip() == m_clip; lingrad.setColorAt( 1, c.darker( 300 ) ); lingrad.setColorAt( 0, c ); - // paint a black rectangle under the pattern to prevent glitches with transparent backgrounds + // paint a black rectangle under the clip to prevent glitches with transparent backgrounds p.fillRect( rect(), QColor( 0, 0, 0 ) ); if( gradient() ) @@ -275,19 +275,19 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) } // pixels per bar - const float ppb = fixedTCOs() ? - ( parentWidget()->width() - 2 * TCO_BORDER_WIDTH ) - / (float) m_pat->timeMapLength().getBar() : + const float ppb = fixedClips() ? + ( parentWidget()->width() - 2 * CLIP_BORDER_WIDTH ) + / (float) m_clip->timeMapLength().getBar() : pixelsPerBar(); - const float min = m_pat->firstObject()->minValue(); - const float max = m_pat->firstObject()->maxValue(); + const float min = m_clip->firstObject()->minValue(); + const float max = m_clip->firstObject()->maxValue(); const float y_scale = max - min; - const float h = ( height() - 2 * TCO_BORDER_WIDTH ) / y_scale; + const float h = ( height() - 2 * CLIP_BORDER_WIDTH ) / y_scale; const float ppTick = ppb / TimePos::ticksPerBar(); - p.translate( 0.0f, max * height() / y_scale - TCO_BORDER_WIDTH ); + p.translate( 0.0f, max * height() / y_scale - CLIP_BORDER_WIDTH ); p.scale( 1.0f, -h ); QLinearGradient lin2grad( 0, min, 0, max ); @@ -300,15 +300,15 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) lin2grad.setColorAt( 0, col.darker( 150 ) ); p.setRenderHints( QPainter::Antialiasing, true ); - for( AutomationPattern::timeMap::const_iterator it = - m_pat->getTimeMap().begin(); - it != m_pat->getTimeMap().end(); ++it ) + for( AutomationClip::timeMap::const_iterator it = + m_clip->getTimeMap().begin(); + it != m_clip->getTimeMap().end(); ++it ) { - if( it+1 == m_pat->getTimeMap().end() ) + if( it+1 == m_clip->getTimeMap().end() ) { const float x1 = POS(it) * ppTick; - const float x2 = (float)( width() - TCO_BORDER_WIDTH ); - if( x1 > ( width() - TCO_BORDER_WIDTH ) ) break; + const float x2 = (float)( width() - CLIP_BORDER_WIDTH ); + if( x1 > ( width() - CLIP_BORDER_WIDTH ) ) break; // We are drawing the space after the last node, so we use the outValue if( gradient() ) { @@ -321,7 +321,7 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) break; } - float *values = m_pat->valuesAfter(POS(it)); + float *values = m_clip->valuesAfter(POS(it)); // We are creating a path to draw a polygon representing the values between two // nodes. When we have two nodes with discrete progression, we will basically have @@ -330,7 +330,7 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) // the value of the end of the shape between the two nodes will be the inValue of // the next node. float nextValue; - if( m_pat->progressionType() == AutomationPattern::DiscreteProgression ) + if( m_clip->progressionType() == AutomationClip::DiscreteProgression ) { nextValue = OUTVAL(it); } @@ -347,7 +347,7 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) for (int i = POS(it) + 1; i < POS(it + 1); i++) { x = i * ppTick; - if( x > ( width() - TCO_BORDER_WIDTH ) ) break; + if( x > ( width() - CLIP_BORDER_WIDTH ) ) break; float value = values[i - POS(it)]; path.lineTo( QPointF( x, value ) ); @@ -374,39 +374,39 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) const int lineSize = 3; p.setPen( c.darker( 300 ) ); - for (bar_t b = 1; b < width() - TCO_BORDER_WIDTH; ++b) + for (bar_t b = 1; b < width() - CLIP_BORDER_WIDTH; ++b) { - const int bx = TCO_BORDER_WIDTH + static_cast(ppb * b) - 2; + const int bx = CLIP_BORDER_WIDTH + static_cast(ppb * b) - 2; //top line - p.drawLine(bx, TCO_BORDER_WIDTH, bx, TCO_BORDER_WIDTH + lineSize); + p.drawLine(bx, CLIP_BORDER_WIDTH, bx, CLIP_BORDER_WIDTH + lineSize); //bottom line - p.drawLine(bx, rect().bottom() - (lineSize + TCO_BORDER_WIDTH), bx, rect().bottom() - TCO_BORDER_WIDTH); + p.drawLine(bx, rect().bottom() - (lineSize + CLIP_BORDER_WIDTH), bx, rect().bottom() - CLIP_BORDER_WIDTH); } // recording icon for when recording automation - if( m_pat->isRecording() ) + if( m_clip->isRecording() ) { - p.drawPixmap( 1, rect().bottom() - s_pat_rec->height(), *s_pat_rec ); + p.drawPixmap( 1, rect().bottom() - s_clip_rec->height(), *s_clip_rec ); } - // pattern name - paintTextLabel(m_pat->name(), p); + // clip name + paintTextLabel(m_clip->name(), p); // inner border p.setPen( c.lighter( current ? 160 : 130 ) ); - p.drawRect( 1, 1, rect().right() - TCO_BORDER_WIDTH, - rect().bottom() - TCO_BORDER_WIDTH ); + p.drawRect( 1, 1, rect().right() - CLIP_BORDER_WIDTH, + rect().bottom() - CLIP_BORDER_WIDTH ); // outer border p.setPen( current? c.lighter( 130 ) : c.darker( 300 ) ); p.drawRect( 0, 0, rect().right(), rect().bottom() ); - // draw the 'muted' pixmap only if the pattern was manualy muted - if( m_pat->isMuted() ) + // draw the 'muted' pixmap only if the clip was manualy muted + if( m_clip->isMuted() ) { - const int spacing = TCO_BORDER_WIDTH; + const int spacing = CLIP_BORDER_WIDTH; const int size = 14; p.drawPixmap( spacing, height() - ( size + spacing ), embed::getIconPixmap( "muted", size, size ) ); @@ -420,19 +420,19 @@ void AutomationPatternView::paintEvent( QPaintEvent * ) -void AutomationPatternView::dragEnterEvent( QDragEnterEvent * _dee ) +void AutomationClipView::dragEnterEvent( QDragEnterEvent * _dee ) { StringPairDrag::processDragEnterEvent( _dee, "automatable_model" ); if( !_dee->isAccepted() ) { - TrackContentObjectView::dragEnterEvent( _dee ); + ClipView::dragEnterEvent( _dee ); } } -void AutomationPatternView::dropEvent( QDropEvent * _de ) +void AutomationClipView::dropEvent( QDropEvent * _de ) { QString type = StringPairDrag::decodeKey( _de ); QString val = StringPairDrag::decodeValue( _de ); @@ -443,12 +443,12 @@ void AutomationPatternView::dropEvent( QDropEvent * _de ) journallingObject( val.toInt() ) ); if( mod != nullptr ) { - bool added = m_pat->addObject( mod ); + bool added = m_clip->addObject( mod ); if ( !added ) { TextFloat::displayMessage( mod->displayName(), tr( "Model is already connected " - "to this pattern." ), + "to this clip." ), embed::getIconPixmap( "automation" ), 2000 ); } @@ -456,14 +456,14 @@ void AutomationPatternView::dropEvent( QDropEvent * _de ) update(); if( getGUI()->automationEditor() && - getGUI()->automationEditor()->currentPattern() == m_pat ) + getGUI()->automationEditor()->currentClip() == m_clip ) { - getGUI()->automationEditor()->setCurrentPattern( m_pat ); + getGUI()->automationEditor()->setCurrentClip( m_clip ); } } else { - TrackContentObjectView::dropEvent( _de ); + ClipView::dropEvent( _de ); } } @@ -473,10 +473,10 @@ void AutomationPatternView::dropEvent( QDropEvent * _de ) /** * @brief Preserves the auto points over different scale */ -void AutomationPatternView::scaleTimemapToFit( float oldMin, float oldMax ) +void AutomationClipView::scaleTimemapToFit( float oldMin, float oldMax ) { - float newMin = m_pat->getMin(); - float newMax = m_pat->getMax(); + float newMin = m_clip->getMin(); + float newMax = m_clip->getMax(); if( oldMin == newMin && oldMax == newMax ) { @@ -487,8 +487,8 @@ void AutomationPatternView::scaleTimemapToFit( float oldMin, float oldMax ) // only the inValue is being considered and the outValue is being reset to the inValue (so discrete jumps // are discarded). Possibly later we will want discrete jumps to be maintained so we will need to upgrade // the logic to account for them. - for( AutomationPattern::timeMap::iterator it = m_pat->m_timeMap.begin(); - it != m_pat->m_timeMap.end(); ++it ) + for( AutomationClip::timeMap::iterator it = m_clip->m_timeMap.begin(); + it != m_clip->m_timeMap.end(); ++it ) { // If the values are out of the previous range, fix them so they are // between oldMin and oldMax. @@ -506,5 +506,5 @@ void AutomationPatternView::scaleTimemapToFit( float oldMin, float oldMax ) it.value().setOutValue(INVAL(it)); } - m_pat->generateTangents(); + m_clip->generateTangents(); } diff --git a/src/gui/AutomationTrackView.cpp b/src/gui/AutomationTrackView.cpp index 9242c081a68..152d1140185 100644 --- a/src/gui/AutomationTrackView.cpp +++ b/src/gui/AutomationTrackView.cpp @@ -25,7 +25,7 @@ #include "AutomationTrackView.h" - #include "AutomationPattern.h" + #include "AutomationClip.h" #include "embed.h" #include "Engine.h" #include "ProjectJournal.h" @@ -78,9 +78,9 @@ void AutomationTrackView::dropEvent( QDropEvent * _de ) pos.setTicks( 0 ); } - TrackContentObject * tco = getTrack()->createTCO( pos ); - AutomationPattern * pat = dynamic_cast( tco ); - pat->addObject( mod ); + Clip * clip = getTrack()->createClip( pos ); + AutomationClip * autoClip = dynamic_cast( clip ); + autoClip->addObject( mod ); } } diff --git a/src/gui/BBTCOView.cpp b/src/gui/BBClipView.cpp similarity index 68% rename from src/gui/BBTCOView.cpp rename to src/gui/BBClipView.cpp index f15206460c0..d0e832526c4 100644 --- a/src/gui/BBTCOView.cpp +++ b/src/gui/BBClipView.cpp @@ -1,5 +1,5 @@ /* - * BBTCOView.cpp + * BBClipView.cpp * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -22,7 +22,7 @@ * */ -#include "BBTCOView.h" +#include "BBClipView.h" #include #include @@ -36,18 +36,18 @@ #include "Song.h" #include "ToolTip.h" -BBTCOView::BBTCOView( TrackContentObject * _tco, TrackView * _tv ) : - TrackContentObjectView( _tco, _tv ), - m_bbTCO( dynamic_cast( _tco ) ), +BBClipView::BBClipView( Clip * _clip, TrackView * _tv ) : + ClipView( _clip, _tv ), + m_bbClip( dynamic_cast( _clip ) ), m_paintPixmap() { - connect( _tco->getTrack(), SIGNAL( dataChanged() ), + connect( _clip->getTrack(), SIGNAL( dataChanged() ), this, SLOT( update() ) ); setStyle( QApplication::style() ); } -void BBTCOView::constructContextMenu( QMenu * _cm ) +void BBClipView::constructContextMenu( QMenu * _cm ) { QAction * a = new QAction( embed::getIconPixmap( "bb_track" ), tr( "Open in Beat+Bassline-Editor" ), @@ -67,7 +67,7 @@ void BBTCOView::constructContextMenu( QMenu * _cm ) -void BBTCOView::mouseDoubleClickEvent( QMouseEvent * ) +void BBClipView::mouseDoubleClickEvent( QMouseEvent * ) { openInBBEditor(); } @@ -75,7 +75,7 @@ void BBTCOView::mouseDoubleClickEvent( QMouseEvent * ) -void BBTCOView::paintEvent( QPaintEvent * ) +void BBClipView::paintEvent( QPaintEvent * ) { QPainter painter( this ); @@ -100,7 +100,7 @@ void BBTCOView::paintEvent( QPaintEvent * ) lingrad.setColorAt( 0, c.lighter( 130 ) ); lingrad.setColorAt( 1, c.lighter( 70 ) ); - // paint a black rectangle under the pattern to prevent glitches with transparent backgrounds + // paint a black rectangle under the clip to prevent glitches with transparent backgrounds p.fillRect( rect(), QColor( 0, 0, 0 ) ); if( gradient() ) @@ -116,35 +116,35 @@ void BBTCOView::paintEvent( QPaintEvent * ) const int lineSize = 3; p.setPen( c.darker( 200 ) ); - bar_t t = Engine::getBBTrackContainer()->lengthOfBB( m_bbTCO->bbTrackIndex() ); - if( m_bbTCO->length() > TimePos::ticksPerBar() && t > 0 ) + bar_t t = Engine::getBBTrackContainer()->lengthOfBB( m_bbClip->bbTrackIndex() ); + if( m_bbClip->length() > TimePos::ticksPerBar() && t > 0 ) { for( int x = static_cast( t * pixelsPerBar() ); x < width() - 2; x += static_cast( t * pixelsPerBar() ) ) { - p.drawLine( x, TCO_BORDER_WIDTH, x, TCO_BORDER_WIDTH + lineSize ); - p.drawLine( x, rect().bottom() - ( TCO_BORDER_WIDTH + lineSize ), - x, rect().bottom() - TCO_BORDER_WIDTH ); + p.drawLine( x, CLIP_BORDER_WIDTH, x, CLIP_BORDER_WIDTH + lineSize ); + p.drawLine( x, rect().bottom() - ( CLIP_BORDER_WIDTH + lineSize ), + x, rect().bottom() - CLIP_BORDER_WIDTH ); } } - // pattern name - paintTextLabel(m_bbTCO->name(), p); + // clip name + paintTextLabel(m_bbClip->name(), p); // inner border p.setPen( c.lighter( 130 ) ); - p.drawRect( 1, 1, rect().right() - TCO_BORDER_WIDTH, - rect().bottom() - TCO_BORDER_WIDTH ); + p.drawRect( 1, 1, rect().right() - CLIP_BORDER_WIDTH, + rect().bottom() - CLIP_BORDER_WIDTH ); // outer border p.setPen( c.darker( 300 ) ); p.drawRect( 0, 0, rect().right(), rect().bottom() ); - // draw the 'muted' pixmap only if the pattern was manualy muted - if( m_bbTCO->isMuted() ) + // draw the 'muted' pixmap only if the clip was manualy muted + if( m_bbClip->isMuted() ) { - const int spacing = TCO_BORDER_WIDTH; + const int spacing = CLIP_BORDER_WIDTH; const int size = 14; p.drawPixmap( spacing, height() - ( size + spacing ), embed::getIconPixmap( "muted", size, size ) ); @@ -158,9 +158,9 @@ void BBTCOView::paintEvent( QPaintEvent * ) -void BBTCOView::openInBBEditor() +void BBClipView::openInBBEditor() { - Engine::getBBTrackContainer()->setCurrentBB( m_bbTCO->bbTrackIndex() ); + Engine::getBBTrackContainer()->setCurrentBB( m_bbClip->bbTrackIndex() ); getGUI()->mainWindow()->toggleBBEditorWin( true ); } @@ -168,24 +168,24 @@ void BBTCOView::openInBBEditor() -void BBTCOView::resetName() { m_bbTCO->setName(""); } +void BBClipView::resetName() { m_bbClip->setName(""); } -void BBTCOView::changeName() +void BBClipView::changeName() { - QString s = m_bbTCO->name(); + QString s = m_bbClip->name(); RenameDialog rename_dlg( s ); rename_dlg.exec(); - m_bbTCO->setName( s ); + m_bbClip->setName( s ); } -void BBTCOView::update() +void BBClipView::update() { - ToolTip::add(this, m_bbTCO->name()); + ToolTip::add(this, m_bbClip->name()); - TrackContentObjectView::update(); + ClipView::update(); } \ No newline at end of file diff --git a/src/gui/CMakeLists.txt b/src/gui/CMakeLists.txt index 24c59e5fb52..757eb1c9c1a 100644 --- a/src/gui/CMakeLists.txt +++ b/src/gui/CMakeLists.txt @@ -5,11 +5,11 @@ SET(LMMS_SRCS gui/AudioAlsaSetupWidget.cpp gui/AudioDeviceSetupWidget.cpp gui/AutomatableModelView.cpp - gui/AutomationPatternView.cpp + gui/AutomationClipView.cpp gui/AutomationTrackView.cpp gui/ControllerConnectionDialog.cpp gui/ControllerDialog.cpp - gui/BBTCOView.cpp + gui/BBClipView.cpp gui/BBTrackView.cpp gui/EffectControlDialog.cpp gui/EffectSelectDialog.cpp @@ -28,14 +28,14 @@ SET(LMMS_SRCS gui/MainApplication.cpp gui/MainWindow.cpp gui/MidiCCRackView.cpp + gui/MidiClipView.cpp gui/MidiSetupWidget.cpp gui/ModelView.cpp - gui/PatternView.cpp gui/PeakControllerDialog.cpp gui/PianoView.cpp gui/PluginBrowser.cpp gui/RowTableView.cpp - gui/SampleTCOView.cpp + gui/SampleClipView.cpp gui/SampleTrackView.cpp gui/SampleTrackWindow.cpp gui/SetupDialog.cpp @@ -44,7 +44,7 @@ SET(LMMS_SRCS gui/TimeLineWidget.cpp gui/ToolPluginView.cpp gui/TrackContainerView.cpp - gui/TrackContentObjectView.cpp + gui/ClipView.cpp gui/TrackView.cpp gui/dialogs/FileDialog.cpp diff --git a/src/gui/TrackContentObjectView.cpp b/src/gui/ClipView.cpp similarity index 58% rename from src/gui/TrackContentObjectView.cpp rename to src/gui/ClipView.cpp index 6fcb500ef8a..a5397035f54 100644 --- a/src/gui/TrackContentObjectView.cpp +++ b/src/gui/ClipView.cpp @@ -1,5 +1,5 @@ /* - * TrackContentObjectView.cpp - implementation of TrackContentObjectView class + * ClipView.cpp - implementation of ClipView class * * Copyright (c) 2004-2014 Tobias Doerffel * @@ -22,7 +22,7 @@ * */ -#include "TrackContentObjectView.h" +#include "ClipView.h" #include @@ -30,7 +30,7 @@ #include #include -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "Clipboard.h" #include "ColorChooser.h" #include "ComboBoxModel.h" @@ -40,8 +40,8 @@ #include "GuiApplication.h" #include "InstrumentTrack.h" #include "InstrumentTrackView.h" +#include "MidiClip.h" #include "Note.h" -#include "Pattern.h" #include "SampleTrack.h" #include "Song.h" #include "SongEditor.h" @@ -63,25 +63,24 @@ const int RESIZE_GRIP_WIDTH = 4; * beside the cursor as you move or resize elements of a track about. * This pointer keeps track of it, as you only ever need one at a time. */ -TextFloat * TrackContentObjectView::s_textFloat = nullptr; +TextFloat * ClipView::s_textFloat = nullptr; -/*! \brief Create a new trackContentObjectView +/*! \brief Create a new ClipView * - * Creates a new track content object view for the given - * track content object in the given track view. + * Creates a new clip view for the given clip in the given track view. * - * \param _tco The track content object to be displayed + * \param _clip The clip to be displayed * \param _tv The track view that will contain the new object */ -TrackContentObjectView::TrackContentObjectView( TrackContentObject * tco, +ClipView::ClipView( Clip * clip, TrackView * tv ) : selectableObject( tv->getTrackContentWidget() ), ModelView( nullptr, this ), m_trackView( tv ), - m_initialTCOPos( TimePos(0) ), - m_initialTCOEnd( TimePos(0) ), - m_tco( tco ), + m_initialClipPos( TimePos(0) ), + m_initialClipEnd( TimePos(0) ), + m_clip( clip ), m_action( NoAction ), m_initialMousePos( QPoint( 0, 0 ) ), m_initialMouseGlobalPos( QPoint( 0, 0 ) ), @@ -92,7 +91,7 @@ TrackContentObjectView::TrackContentObjectView( TrackContentObject * tco, m_selectedColor( 0, 0, 0 ), m_textColor( 0, 0, 0 ), m_textShadowColor( 0, 0, 0 ), - m_BBPatternBackground( 0, 0, 0 ), + m_BBClipBackground( 0, 0, 0 ), m_gradient( true ), m_mouseHotspotHand( 0, 0 ), m_mouseHotspotKnife( 0, 0 ), @@ -118,22 +117,22 @@ TrackContentObjectView::TrackContentObjectView( TrackContentObject * tco, setAcceptDrops( true ); setMouseTracking( true ); - connect( m_tco, SIGNAL( lengthChanged() ), + connect( m_clip, SIGNAL( lengthChanged() ), this, SLOT( updateLength() ) ); connect( getGUI()->songEditor()->m_editor->zoomingModel(), SIGNAL( dataChanged() ), this, SLOT( updateLength() ) ); - connect( m_tco, SIGNAL( positionChanged() ), + connect( m_clip, SIGNAL( positionChanged() ), this, SLOT( updatePosition() ) ); - connect( m_tco, SIGNAL( destroyedTCO() ), this, SLOT( close() ) ); - setModel( m_tco ); - connect(m_tco, SIGNAL(colorChanged()), this, SLOT(update())); + connect( m_clip, SIGNAL( destroyedClip() ), this, SLOT( close() ) ); + setModel( m_clip ); + connect(m_clip, SIGNAL(colorChanged()), this, SLOT(update())); connect(m_trackView->getTrack(), &Track::colorChanged, this, [this] { - // redraw if TCO uses track color - if (!m_tco->usesCustomClipColor()) { update(); } + // redraw if clip uses track color + if (!m_clip->usesCustomClipColor()) { update(); } }); - m_trackView->getTrackContentWidget()->addTCOView( this ); + m_trackView->getTrackContentWidget()->addClipView( this ); updateLength(); updatePosition(); } @@ -141,12 +140,12 @@ TrackContentObjectView::TrackContentObjectView( TrackContentObject * tco, -/*! \brief Destroy a trackContentObjectView +/*! \brief Destroy a ClipView * - * Destroys the given track content object view. + * Destroys the given ClipView. * */ -TrackContentObjectView::~TrackContentObjectView() +ClipView::~ClipView() { delete m_hint; // we have to give our track-container the focus because otherwise the @@ -157,14 +156,14 @@ TrackContentObjectView::~TrackContentObjectView() } -/*! \brief Update a TrackContentObjectView +/*! \brief Update a ClipView * - * TCO's get drawn only when needed, - * and when a TCO is updated, + * Clip's get drawn only when needed, + * and when a Clip is updated, * it needs to be redrawn. * */ -void TrackContentObjectView::update() +void ClipView::update() { if( !m_cursorSetYet ) { @@ -174,7 +173,7 @@ void TrackContentObjectView::update() m_cursorSetYet = true; } - if( fixedTCOs() ) + if( fixedClips() ) { updateLength(); } @@ -184,136 +183,135 @@ void TrackContentObjectView::update() -/*! \brief Does this trackContentObjectView have a fixed TCO? +/*! \brief Does this ClipView have a fixed Clip? * * Returns whether the containing trackView has fixed - * TCOs. + * Clips. * - * \todo What the hell is a TCO here - track content object? And in - * what circumstance are they fixed? + * \todo In what circumstance are they fixed? */ -bool TrackContentObjectView::fixedTCOs() +bool ClipView::fixedClips() { - return m_trackView->trackContainerView()->fixedTCOs(); + return m_trackView->trackContainerView()->fixedClips(); } -// qproperty access functions, to be inherited & used by TCOviews +// qproperty access functions, to be inherited & used by Clipviews //! \brief CSS theming qproperty access method -QColor TrackContentObjectView::mutedColor() const +QColor ClipView::mutedColor() const { return m_mutedColor; } -QColor TrackContentObjectView::mutedBackgroundColor() const +QColor ClipView::mutedBackgroundColor() const { return m_mutedBackgroundColor; } -QColor TrackContentObjectView::selectedColor() const +QColor ClipView::selectedColor() const { return m_selectedColor; } -QColor TrackContentObjectView::textColor() const +QColor ClipView::textColor() const { return m_textColor; } -QColor TrackContentObjectView::textBackgroundColor() const +QColor ClipView::textBackgroundColor() const { return m_textBackgroundColor; } -QColor TrackContentObjectView::textShadowColor() const +QColor ClipView::textShadowColor() const { return m_textShadowColor; } -QColor TrackContentObjectView::BBPatternBackground() const -{ return m_BBPatternBackground; } +QColor ClipView::BBClipBackground() const +{ return m_BBClipBackground; } -bool TrackContentObjectView::gradient() const +bool ClipView::gradient() const { return m_gradient; } //! \brief CSS theming qproperty access method -void TrackContentObjectView::setMutedColor( const QColor & c ) +void ClipView::setMutedColor( const QColor & c ) { m_mutedColor = QColor( c ); } -void TrackContentObjectView::setMutedBackgroundColor( const QColor & c ) +void ClipView::setMutedBackgroundColor( const QColor & c ) { m_mutedBackgroundColor = QColor( c ); } -void TrackContentObjectView::setSelectedColor( const QColor & c ) +void ClipView::setSelectedColor( const QColor & c ) { m_selectedColor = QColor( c ); } -void TrackContentObjectView::setTextColor( const QColor & c ) +void ClipView::setTextColor( const QColor & c ) { m_textColor = QColor( c ); } -void TrackContentObjectView::setTextBackgroundColor( const QColor & c ) +void ClipView::setTextBackgroundColor( const QColor & c ) { m_textBackgroundColor = c; } -void TrackContentObjectView::setTextShadowColor( const QColor & c ) +void ClipView::setTextShadowColor( const QColor & c ) { m_textShadowColor = QColor( c ); } -void TrackContentObjectView::setBBPatternBackground( const QColor & c ) -{ m_BBPatternBackground = QColor( c ); } +void ClipView::setBBClipBackground( const QColor & c ) +{ m_BBClipBackground = QColor( c ); } -void TrackContentObjectView::setGradient( const bool & b ) +void ClipView::setGradient( const bool & b ) { m_gradient = b; } // access needsUpdate member variable -bool TrackContentObjectView::needsUpdate() +bool ClipView::needsUpdate() { return m_needsUpdate; } -void TrackContentObjectView::setNeedsUpdate( bool b ) +void ClipView::setNeedsUpdate( bool b ) { m_needsUpdate = b; } -/*! \brief Close a trackContentObjectView +/*! \brief Close a ClipView * - * Closes a track content object view by asking the track + * Closes a ClipView by asking the track * view to remove us and then asking the QWidget to close us. * * \return Boolean state of whether the QWidget was able to close. */ -bool TrackContentObjectView::close() +bool ClipView::close() { - m_trackView->getTrackContentWidget()->removeTCOView( this ); + m_trackView->getTrackContentWidget()->removeClipView( this ); return QWidget::close(); } -/*! \brief Removes a trackContentObjectView from its track view. +/*! \brief Removes a ClipView from its track view. * * Like the close() method, this asks the track view to remove this - * track content object view. However, the track content object is + * ClipView. However, the clip is * scheduled for later deletion rather than closed immediately. * */ -void TrackContentObjectView::remove() +void ClipView::remove() { m_trackView->getTrack()->addJournalCheckPoint(); // delete ourself close(); - m_tco->deleteLater(); + m_clip->deleteLater(); } -/*! \brief Updates a trackContentObjectView's length +/*! \brief Updates a ClipView's length * - * If this track content object view has a fixed TCO, then we must + * If this ClipView has a fixed Clip, then we must * keep the width of our parent. Otherwise, calculate our width from - * the track content object's length in pixels adding in the border. + * the clip's length in pixels adding in the border. * */ -void TrackContentObjectView::updateLength() +void ClipView::updateLength() { - if( fixedTCOs() ) + if( fixedClips() ) { setFixedWidth( parentWidget()->width() ); } else { setFixedWidth( - static_cast( m_tco->length() * pixelsPerBar() / + static_cast( m_clip->length() * pixelsPerBar() / TimePos::ticksPerBar() ) + 1 /*+ - TCO_BORDER_WIDTH * 2-1*/ ); + CLIP_BORDER_WIDTH * 2-1*/ ); } m_trackView->trackContainerView()->update(); } @@ -321,17 +319,17 @@ void TrackContentObjectView::updateLength() -/*! \brief Updates a trackContentObjectView's position. +/*! \brief Updates a ClipView's position. * * Ask our track view to change our position. Then make sure that the * track view is updated in case this position has changed the track * view's length. * */ -void TrackContentObjectView::updatePosition() +void ClipView::updatePosition() { m_trackView->getTrackContentWidget()->changePosition(); - // moving a TCO can result in change of song-length etc., + // moving a Clip can result in change of song-length etc., // therefore we update the track-container m_trackView->trackContainerView()->update(); } @@ -339,17 +337,17 @@ void TrackContentObjectView::updatePosition() -void TrackContentObjectView::selectColor() +void ClipView::selectColor() { // Get a color from the user - QColor new_color = ColorChooser( this ).withPalette( ColorChooser::Palette::Track )->getColor( m_tco->color() ); + QColor new_color = ColorChooser( this ).withPalette( ColorChooser::Palette::Track )->getColor( m_clip->color() ); if (new_color.isValid()) { setColor(&new_color); } } -void TrackContentObjectView::randomizeColor() +void ClipView::randomizeColor() { setColor(&ColorChooser::getPalette(ColorChooser::Palette::Mixer)[rand() % 48]); } @@ -357,7 +355,7 @@ void TrackContentObjectView::randomizeColor() -void TrackContentObjectView::resetColor() +void ClipView::resetColor() { setColor(nullptr); } @@ -365,28 +363,28 @@ void TrackContentObjectView::resetColor() -/*! \brief Change color of all selected TCOs +/*! \brief Change color of all selected clips * * \param color The new QColor. Pass nullptr to use the Track's color. */ -void TrackContentObjectView::setColor(const QColor* color) +void ClipView::setColor(const QColor* color) { std::set journaledTracks; - auto selectedTCOs = getClickedTCOs(); - for (auto tcov: selectedTCOs) + auto selectedClips = getClickedClips(); + for (auto clipv: selectedClips) { - auto tco = tcov->getTrackContentObject(); - auto track = tco->getTrack(); + auto clip = clipv->getClip(); + auto track = clip->getTrack(); - // TODO journal whole Song or group of TCOs instead of one journal entry for each track + // TODO journal whole Song or group of clips instead of one journal entry for each track - // If only one TCO changed, store that in the journal - if (selectedTCOs.length() == 1) + // If only one clip changed, store that in the journal + if (selectedClips.length() == 1) { - tco->addJournalCheckPoint(); + clip->addJournalCheckPoint(); } - // If multiple TCOs changed, store whole Track in the journal + // If multiple clips changed, store whole Track in the journal // Check if track has been journaled already by trying to add it to the set else if (journaledTracks.insert(track).second) { @@ -395,14 +393,14 @@ void TrackContentObjectView::setColor(const QColor* color) if (color) { - tco->useCustomClipColor(true); - tco->setColor(*color); + clip->useCustomClipColor(true); + clip->setColor(*color); } else { - tco->useCustomClipColor(false); + clip->useCustomClipColor(false); } - tcov->update(); + clipv->update(); } Engine::getSong()->setModified(); @@ -412,7 +410,7 @@ void TrackContentObjectView::setColor(const QColor* color) -/*! \brief Change the trackContentObjectView's display when something +/*! \brief Change the ClipView's display when something * being dragged enters it. * * We need to notify Qt to change our display if something being @@ -420,41 +418,41 @@ void TrackContentObjectView::setColor(const QColor* color) * * \param dee The QDragEnterEvent to watch. */ -void TrackContentObjectView::dragEnterEvent( QDragEnterEvent * dee ) +void ClipView::dragEnterEvent( QDragEnterEvent * dee ) { TrackContentWidget * tcw = getTrackView()->getTrackContentWidget(); - TimePos tcoPos = TimePos( m_tco->startPosition() ); + TimePos clipPos = TimePos( m_clip->startPosition() ); - if( tcw->canPasteSelection( tcoPos, dee ) == false ) + if( tcw->canPasteSelection( clipPos, dee ) == false ) { dee->ignore(); } else { - StringPairDrag::processDragEnterEvent( dee, "tco_" + - QString::number( m_tco->getTrack()->type() ) ); + StringPairDrag::processDragEnterEvent( dee, "clip_" + + QString::number( m_clip->getTrack()->type() ) ); } } -/*! \brief Handle something being dropped on this trackContentObjectView. +/*! \brief Handle something being dropped on this ClipObjectView. * - * When something has been dropped on this trackContentObjectView, and - * it's a track content object, then use an instance of our dataFile reader - * to take the xml of the track content object and turn it into something + * When something has been dropped on this ClipView, and + * it's a clip, then use an instance of our dataFile reader + * to take the xml of the clip and turn it into something * we can write over our current state. * * \param de The QDropEvent to handle. */ -void TrackContentObjectView::dropEvent( QDropEvent * de ) +void ClipView::dropEvent( QDropEvent * de ) { QString type = StringPairDrag::decodeKey( de ); QString value = StringPairDrag::decodeValue( de ); // Track must be the same type to paste into - if( type != ( "tco_" + QString::number( m_tco->getTrack()->type() ) ) ) + if( type != ( "clip_" + QString::number( m_clip->getTrack()->type() ) ) ) { return; } @@ -463,30 +461,30 @@ void TrackContentObjectView::dropEvent( QDropEvent * de ) if( m_trackView->trackContainerView()->allowRubberband() == true ) { TrackContentWidget * tcw = getTrackView()->getTrackContentWidget(); - TimePos tcoPos = TimePos( m_tco->startPosition() ); + TimePos clipPos = TimePos( m_clip->startPosition() ); - if( tcw->pasteSelection( tcoPos, de ) == true ) + if( tcw->pasteSelection( clipPos, de ) == true ) { de->accept(); } return; } - // Don't allow pasting a tco into itself. + // Don't allow pasting a clip into itself. QObject* qwSource = de->source(); if( qwSource != nullptr && - dynamic_cast( qwSource ) == this ) + dynamic_cast( qwSource ) == this ) { return; } - // Copy state into existing tco + // Copy state into existing clip DataFile dataFile( value.toUtf8() ); - TimePos pos = m_tco->startPosition(); - QDomElement tcos = dataFile.content().firstChildElement( "tcos" ); - m_tco->restoreState( tcos.firstChildElement().firstChildElement() ); - m_tco->movePosition( pos ); - AutomationPattern::resolveAllIDs(); + TimePos pos = m_clip->startPosition(); + QDomElement clips = dataFile.content().firstChildElement( "tcos" ); //TODO: rename "tcos" to "clips" + m_clip->restoreState( clips.firstChildElement().firstChildElement() ); + m_clip->movePosition( pos ); + AutomationClip::resolveAllIDs(); de->accept(); } @@ -497,18 +495,18 @@ void TrackContentObjectView::dropEvent( QDropEvent * de ) * * @param me The QMouseEvent that is triggering the cursor change */ -void TrackContentObjectView::updateCursor(QMouseEvent * me) +void ClipView::updateCursor(QMouseEvent * me) { - SampleTCO * sTco = dynamic_cast(m_tco); + SampleClip * sClip = dynamic_cast(m_clip); // If we are at the edges, use the resize cursor - if ((me->x() > width() - RESIZE_GRIP_WIDTH && !me->buttons() && !m_tco->getAutoResize()) - || (me->x() < RESIZE_GRIP_WIDTH && !me->buttons() && sTco && !m_tco->getAutoResize())) + if ((me->x() > width() - RESIZE_GRIP_WIDTH && !me->buttons() && !m_clip->getAutoResize()) + || (me->x() < RESIZE_GRIP_WIDTH && !me->buttons() && sClip && !m_clip->getAutoResize())) { setCursor(Qt::SizeHorCursor); } // If we are in the middle on knife mode, use the knife cursor - else if (sTco && m_trackView->trackContainerView()->knifeMode()) + else if (sClip && m_trackView->trackContainerView()->knifeMode()) { setCursor(m_cursorKnife); } @@ -519,39 +517,39 @@ void TrackContentObjectView::updateCursor(QMouseEvent * me) -/*! \brief Create a DataFile suitable for copying multiple trackContentObjects. +/*! \brief Create a DataFile suitable for copying multiple clips. * - * trackContentObjects in the vector are written to the "tcos" node in the - * DataFile. The trackContentObjectView's initial mouse position is written + * Clips in the vector are written to the "clips" node in the + * DataFile. The ClipView's initial mouse position is written * to the "initialMouseX" node in the DataFile. When dropped on a track, - * this is used to create copies of the TCOs. + * this is used to create copies of the Clips. * - * \param tcos The trackContectObjects to save in a DataFile + * \param clips The trackContectObjects to save in a DataFile */ -DataFile TrackContentObjectView::createTCODataFiles( - const QVector & tcoViews) const +DataFile ClipView::createClipDataFiles( + const QVector & clipViews) const { Track * t = m_trackView->getTrack(); TrackContainer * tc = t->trackContainer(); DataFile dataFile( DataFile::DragNDropData ); - QDomElement tcoParent = dataFile.createElement( "tcos" ); + QDomElement clipParent = dataFile.createElement( "tcos" ); //TODO: rename to "clips" - typedef QVector tcoViewVector; - for( tcoViewVector::const_iterator it = tcoViews.begin(); - it != tcoViews.end(); ++it ) + typedef QVector clipViewVector; + for( clipViewVector::const_iterator it = clipViews.begin(); + it != clipViews.end(); ++it ) { - // Insert into the dom under the "tcos" element - Track* tcoTrack = ( *it )->m_trackView->getTrack(); - int trackIndex = tc->tracks().indexOf( tcoTrack ); - QDomElement tcoElement = dataFile.createElement( "tco" ); - tcoElement.setAttribute( "trackIndex", trackIndex ); - tcoElement.setAttribute( "trackType", tcoTrack->type() ); - tcoElement.setAttribute( "trackName", tcoTrack->name() ); - ( *it )->m_tco->saveState( dataFile, tcoElement ); - tcoParent.appendChild( tcoElement ); + // Insert into the dom under the "tcos" element (TODO: rename element to "clips") + Track* clipTrack = ( *it )->m_trackView->getTrack(); + int trackIndex = tc->tracks().indexOf( clipTrack ); + QDomElement clipElement = dataFile.createElement( "tco" ); //TODO: rename to "clip" + clipElement.setAttribute( "trackIndex", trackIndex ); + clipElement.setAttribute( "trackType", clipTrack->type() ); + clipElement.setAttribute( "trackName", clipTrack->name() ); + ( *it )->m_clip->saveState( dataFile, clipElement ); + clipParent.appendChild( clipElement ); } - dataFile.content().appendChild( tcoParent ); + dataFile.content().appendChild( clipParent ); // Add extra metadata needed for calculations later int initialTrackIndex = tc->tracks().indexOf( t ); @@ -564,15 +562,15 @@ DataFile TrackContentObjectView::createTCODataFiles( // initialTrackIndex is the index of the track that was touched metadata.setAttribute( "initialTrackIndex", initialTrackIndex ); metadata.setAttribute( "trackContainerId", tc->id() ); - // grabbedTCOPos is the pos of the bar containing the TCO we grabbed - metadata.setAttribute( "grabbedTCOPos", m_tco->startPosition() ); + // grabbedClipPos is the pos of the bar containing the Clip we grabbed + metadata.setAttribute( "grabbedClipPos", m_clip->startPosition() ); dataFile.content().appendChild( metadata ); return dataFile; } -void TrackContentObjectView::paintTextLabel(QString const & text, QPainter & painter) +void ClipView::paintTextLabel(QString const & text, QPainter & painter) { if (text.trimmed() == "") { @@ -585,29 +583,29 @@ void TrackContentObjectView::paintTextLabel(QString const & text, QPainter & pai labelFont.setHintingPreference( QFont::PreferFullHinting ); painter.setFont( labelFont ); - const int textTop = TCO_BORDER_WIDTH + 1; - const int textLeft = TCO_BORDER_WIDTH + 3; + const int textTop = CLIP_BORDER_WIDTH + 1; + const int textLeft = CLIP_BORDER_WIDTH + 3; QFontMetrics fontMetrics(labelFont); - QString elidedPatternName = fontMetrics.elidedText(text, Qt::ElideMiddle, width() - 2 * textLeft); + QString elidedClipName = fontMetrics.elidedText(text, Qt::ElideMiddle, width() - 2 * textLeft); - if (elidedPatternName.length() < 2) + if (elidedClipName.length() < 2) { - elidedPatternName = text.trimmed(); + elidedClipName = text.trimmed(); } painter.fillRect(QRect(0, 0, width(), fontMetrics.height() + 2 * textTop), textBackgroundColor()); int const finalTextTop = textTop + fontMetrics.ascent(); painter.setPen(textShadowColor()); - painter.drawText( textLeft + 1, finalTextTop + 1, elidedPatternName ); + painter.drawText( textLeft + 1, finalTextTop + 1, elidedClipName ); painter.setPen( textColor() ); - painter.drawText( textLeft, finalTextTop, elidedPatternName ); + painter.drawText( textLeft, finalTextTop, elidedClipName ); } -/*! \brief Handle a mouse press on this trackContentObjectView. +/*! \brief Handle a mouse press on this ClipView. * - * Handles the various ways in which a trackContentObjectView can be + * Handles the various ways in which a ClipView can be * used with a click of a mouse button. * * * If our container supports rubber band selection then handle @@ -615,27 +613,27 @@ void TrackContentObjectView::paintTextLabel(QString const & text, QPainter & pai * * or if shift-left button, add this object to the selection * * or if ctrl-left button, start a drag-copy event * * or if just plain left button, resize if we're resizeable - * * or if ctrl-middle button, mute the track content object - * * or if middle button, maybe delete the track content object. + * * or if ctrl-middle button, mute the clip + * * or if middle button, maybe delete the clip. * * \param me The QMouseEvent to handle. */ -void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) +void ClipView::mousePressEvent( QMouseEvent * me ) { // Right now, active is only used on right/mid clicks actions, so we use a ternary operator - // to avoid the overhead of calling getClickedTCOs when it's not used + // to avoid the overhead of calling getClickedClips when it's not used auto active = me->button() == Qt::LeftButton - ? QVector() - : getClickedTCOs(); + ? QVector() + : getClickedClips(); setInitialPos( me->pos() ); setInitialOffsets(); - if( !fixedTCOs() && me->button() == Qt::LeftButton ) + if( !fixedClips() && me->button() == Qt::LeftButton ) { - SampleTCO * sTco = dynamic_cast( m_tco ); + SampleClip * sClip = dynamic_cast( m_clip ); const bool knifeMode = m_trackView->trackContainerView()->knifeMode(); - if ( me->modifiers() & Qt::ControlModifier && !(sTco && knifeMode) ) + if ( me->modifiers() & Qt::ControlModifier && !(sClip && knifeMode) ) { if( isSelected() ) { @@ -654,20 +652,20 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) } else { - getGUI()->songEditor()->m_editor->selectAllTcos( false ); - m_tco->addJournalCheckPoint(); + getGUI()->songEditor()->m_editor->selectAllClips( false ); + m_clip->addJournalCheckPoint(); // Move, Resize and ResizeLeft - // Split action doesn't disable TCO journalling + // Split action doesn't disable Clip journalling if (m_action == Move || m_action == Resize || m_action == ResizeLeft) { - m_tco->setJournalling(false); + m_clip->setJournalling(false); } setInitialPos( me->pos() ); setInitialOffsets(); - if( m_tco->getAutoResize() ) + if( m_clip->getAutoResize() ) { // Always move clips that can't be manually resized m_action = Move; setCursor( Qt::SizeAllCursor ); @@ -677,12 +675,12 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) m_action = Resize; setCursor( Qt::SizeHorCursor ); } - else if( me->x() < RESIZE_GRIP_WIDTH && sTco ) + else if( me->x() < RESIZE_GRIP_WIDTH && sClip ) { m_action = ResizeLeft; setCursor( Qt::SizeHorCursor ); } - else if( sTco && knifeMode ) + else if( sClip && knifeMode ) { m_action = Split; setCursor( m_cursorKnife ); @@ -700,26 +698,26 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) { s_textFloat->setTitle( tr( "Current position" ) ); s_textFloat->setText( QString( "%1:%2" ). - arg( m_tco->startPosition().getBar() + 1 ). - arg( m_tco->startPosition().getTicks() % + arg( m_clip->startPosition().getBar() + 1 ). + arg( m_clip->startPosition().getTicks() % TimePos::ticksPerBar() ) ); } else if( m_action == Resize || m_action == ResizeLeft ) { s_textFloat->setTitle( tr( "Current length" ) ); s_textFloat->setText( tr( "%1:%2 (%3:%4 to %5:%6)" ). - arg( m_tco->length().getBar() ). - arg( m_tco->length().getTicks() % + arg( m_clip->length().getBar() ). + arg( m_clip->length().getTicks() % TimePos::ticksPerBar() ). - arg( m_tco->startPosition().getBar() + 1 ). - arg( m_tco->startPosition().getTicks() % + arg( m_clip->startPosition().getBar() + 1 ). + arg( m_clip->startPosition().getTicks() % TimePos::ticksPerBar() ). - arg( m_tco->endPosition().getBar() + 1 ). - arg( m_tco->endPosition().getTicks() % + arg( m_clip->endPosition().getBar() + 1 ). + arg( m_clip->endPosition().getTicks() % TimePos::ticksPerBar() ) ); } // s_textFloat->reparent( this ); - // setup text-float as if TCO was already moved/resized + // setup text-float as if Clip was already moved/resized s_textFloat->moveGlobal( this, QPoint( width() + 2, height() + 2) ); if ( m_action != Split) { s_textFloat->show(); } } @@ -738,15 +736,15 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) { toggleMute( active ); } - else if( me->modifiers() & Qt::ShiftModifier && !fixedTCOs() ) + else if( me->modifiers() & Qt::ShiftModifier && !fixedClips() ) { remove( active ); } if (m_action == Split) { m_action = NoAction; - SampleTCO * sTco = dynamic_cast( m_tco ); - if (sTco) + SampleClip * sClip = dynamic_cast( m_clip ); + if (sClip) { setMarkerEnabled( false ); update(); @@ -759,7 +757,7 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) { toggleMute( active ); } - else if( !fixedTCOs() ) + else if( !fixedClips() ) { remove( active ); } @@ -769,9 +767,9 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) -/*! \brief Handle a mouse movement (drag) on this trackContentObjectView. +/*! \brief Handle a mouse movement (drag) on this ClipView. * - * Handles the various ways in which a trackContentObjectView can be + * Handles the various ways in which a ClipView can be * used with a mouse drag. * * * If in move mode, move ourselves in the track, @@ -782,47 +780,47 @@ void TrackContentObjectView::mousePressEvent( QMouseEvent * me ) * \param me The QMouseEvent to handle. * \todo what does the final else case do here? */ -void TrackContentObjectView::mouseMoveEvent( QMouseEvent * me ) +void ClipView::mouseMoveEvent( QMouseEvent * me ) { if( m_action == CopySelection || m_action == ToggleSelected ) { if( mouseMovedDistance( me, 2 ) == true ) { - QVector tcoViews; + QVector clipViews; if( m_action == CopySelection ) { - // Collect all selected TCOs + // Collect all selected Clips QVector so = m_trackView->trackContainerView()->selectedObjects(); for( auto it = so.begin(); it != so.end(); ++it ) { - TrackContentObjectView * tcov = - dynamic_cast( *it ); - if( tcov != nullptr ) + ClipView * clipv = + dynamic_cast( *it ); + if( clipv != nullptr ) { - tcoViews.push_back( tcov ); + clipViews.push_back( clipv ); } } } else { - getGUI()->songEditor()->m_editor->selectAllTcos( false ); - tcoViews.push_back( this ); + getGUI()->songEditor()->m_editor->selectAllClips( false ); + clipViews.push_back( this ); } // Clear the action here because mouseReleaseEvent will not get // triggered once we go into drag. m_action = NoAction; - // Write the TCOs to the DataFile for copying - DataFile dataFile = createTCODataFiles( tcoViews ); + // Write the Clips to the DataFile for copying + DataFile dataFile = createClipDataFiles( clipViews ); // TODO -- thumbnail for all selected QPixmap thumbnail = grab().scaled( 128, 128, Qt::KeepAspectRatio, Qt::SmoothTransformation ); - new StringPairDrag( QString( "tco_%1" ).arg( - m_tco->getTrack()->type() ), + new StringPairDrag( QString( "clip_%1" ).arg( + m_clip->getTrack()->type() ), dataFile.toString(), thumbnail, this ); } } @@ -836,10 +834,10 @@ void TrackContentObjectView::mouseMoveEvent( QMouseEvent * me ) const float ppb = m_trackView->trackContainerView()->pixelsPerBar(); if( m_action == Move ) { - TimePos newPos = draggedTCOPos( me ); + TimePos newPos = draggedClipPos( me ); - m_tco->movePosition(newPos); - newPos = m_tco->startPosition(); // Get the real position the TCO was dragged to for the label + m_clip->movePosition(newPos); + newPos = m_clip->startPosition(); // Get the real position the Clip was dragged to for the label m_trackView->getTrackContentWidget()->changePosition(); s_textFloat->setText( QString( "%1:%2" ). arg( newPos.getBar() + 1 ). @@ -849,32 +847,32 @@ void TrackContentObjectView::mouseMoveEvent( QMouseEvent * me ) } else if( m_action == MoveSelection ) { - // 1: Find the position we want to move the grabbed TCO to - TimePos newPos = draggedTCOPos( me ); + // 1: Find the position we want to move the grabbed Clip to + TimePos newPos = draggedClipPos( me ); - // 2: Handle moving the other selected TCOs the same distance + // 2: Handle moving the other selected Clips the same distance QVector so = m_trackView->trackContainerView()->selectedObjects(); - QVector tcos; // List of selected clips + QVector clips; // List of selected clips int leftmost = 0; // Leftmost clip's offset from grabbed clip - // Populate tcos, find leftmost + // Populate clips, find leftmost for( QVector::iterator it = so.begin(); it != so.end(); ++it ) { - TrackContentObjectView * tcov = - dynamic_cast( *it ); - if( tcov == nullptr ) { continue; } - tcos.push_back( tcov->m_tco ); + ClipView* clipv = + dynamic_cast( *it ); + if( clipv == nullptr ) { continue; } + clips.push_back( clipv->m_clip ); int index = std::distance( so.begin(), it ); leftmost = std::min(leftmost, m_initialOffsets[index].getTicks()); } // Make sure the leftmost clip doesn't get moved to a negative position if ( newPos.getTicks() + leftmost < 0 ) { newPos = -leftmost; } - for( QVector::iterator it = tcos.begin(); - it != tcos.end(); ++it ) + for( QVector::iterator it = clips.begin(); + it != clips.end(); ++it ) { - int index = std::distance( tcos.begin(), it ); + int index = std::distance( clips.begin(), it ); ( *it )->movePosition( newPos + m_initialOffsets[index] ); } } @@ -895,30 +893,30 @@ void TrackContentObjectView::mouseMoveEvent( QMouseEvent * me ) // even if the user switches to snapping later setInitialPos( m_initialMousePos ); // Don't resize to less than 1 tick - m_tco->changeLength( qMax( 1, l ) ); + m_clip->changeLength( qMax( 1, l ) ); } else if ( me->modifiers() & Qt::ShiftModifier ) { // If shift is held, quantize clip's end position - TimePos end = TimePos( m_initialTCOPos + l ).quantize( snapSize ); + TimePos end = TimePos( m_initialClipPos + l ).quantize( snapSize ); // The end position has to be after the clip's start - TimePos min = m_initialTCOPos.quantize( snapSize ); - if ( min <= m_initialTCOPos ) min += snapLength; - m_tco->changeLength( qMax(min - m_initialTCOPos, end - m_initialTCOPos) ); + TimePos min = m_initialClipPos.quantize( snapSize ); + if ( min <= m_initialClipPos ) min += snapLength; + m_clip->changeLength( qMax(min - m_initialClipPos, end - m_initialClipPos) ); } else { // Otherwise, resize in fixed increments - TimePos initialLength = m_initialTCOEnd - m_initialTCOPos; + TimePos initialLength = m_initialClipEnd - m_initialClipPos; TimePos offset = TimePos( l - initialLength ).quantize( snapSize ); // Don't resize to less than 1 tick TimePos min = TimePos( initialLength % snapLength ); if (min < 1) min += snapLength; - m_tco->changeLength( qMax( min, initialLength + offset) ); + m_clip->changeLength( qMax( min, initialLength + offset) ); } } else { - SampleTCO * sTco = dynamic_cast( m_tco ); - if( sTco ) + SampleClip * sClip = dynamic_cast( m_clip ); + if( sClip ) { const int x = mapToParent( me->pos() ).x() - m_initialMousePos.x(); @@ -931,50 +929,50 @@ void TrackContentObjectView::mouseMoveEvent( QMouseEvent * me ) // even if the user switches to snapping later setInitialPos( m_initialMousePos ); //Don't resize to less than 1 tick - t = qMin( m_initialTCOEnd - 1, t); + t = qMin( m_initialClipEnd - 1, t); } else if( me->modifiers() & Qt::ShiftModifier ) { // If shift is held, quantize clip's start position // Don't let the start position move past the end position - TimePos max = m_initialTCOEnd.quantize( snapSize ); - if ( max >= m_initialTCOEnd ) max -= snapLength; + TimePos max = m_initialClipEnd.quantize( snapSize ); + if ( max >= m_initialClipEnd ) max -= snapLength; t = qMin( max, t.quantize( snapSize ) ); } else { // Otherwise, resize in fixed increments // Don't resize to less than 1 tick - TimePos initialLength = m_initialTCOEnd - m_initialTCOPos; + TimePos initialLength = m_initialClipEnd - m_initialClipPos; TimePos minLength = TimePos( initialLength % snapLength ); if (minLength < 1) minLength += snapLength; - TimePos offset = TimePos(t - m_initialTCOPos).quantize( snapSize ); - t = qMin( m_initialTCOEnd - minLength, m_initialTCOPos + offset ); + TimePos offset = TimePos(t - m_initialClipPos).quantize( snapSize ); + t = qMin( m_initialClipEnd - minLength, m_initialClipPos + offset ); } - TimePos oldPos = m_tco->startPosition(); - if( m_tco->length() + ( oldPos - t ) >= 1 ) + TimePos oldPos = m_clip->startPosition(); + if( m_clip->length() + ( oldPos - t ) >= 1 ) { - m_tco->movePosition( t ); - m_tco->changeLength( m_tco->length() + ( oldPos - t ) ); - sTco->setStartTimeOffset( sTco->startTimeOffset() + ( oldPos - t ) ); + m_clip->movePosition( t ); + m_clip->changeLength( m_clip->length() + ( oldPos - t ) ); + sClip->setStartTimeOffset( sClip->startTimeOffset() + ( oldPos - t ) ); } } } s_textFloat->setText( tr( "%1:%2 (%3:%4 to %5:%6)" ). - arg( m_tco->length().getBar() ). - arg( m_tco->length().getTicks() % + arg( m_clip->length().getBar() ). + arg( m_clip->length().getTicks() % TimePos::ticksPerBar() ). - arg( m_tco->startPosition().getBar() + 1 ). - arg( m_tco->startPosition().getTicks() % + arg( m_clip->startPosition().getBar() + 1 ). + arg( m_clip->startPosition().getTicks() % TimePos::ticksPerBar() ). - arg( m_tco->endPosition().getBar() + 1 ). - arg( m_tco->endPosition().getTicks() % + arg( m_clip->endPosition().getBar() + 1 ). + arg( m_clip->endPosition().getTicks() % TimePos::ticksPerBar() ) ); s_textFloat->moveGlobal( this, QPoint( width() + 2, height() + 2) ); } else if( m_action == Split ) { - SampleTCO * sTco = dynamic_cast( m_tco ); - if (sTco) { + SampleClip * sClip = dynamic_cast( m_clip ); + if (sClip) { setCursor( m_cursorKnife ); setMarkerPos( knifeMarkerPos( me ) ); } @@ -987,14 +985,14 @@ void TrackContentObjectView::mouseMoveEvent( QMouseEvent * me ) -/*! \brief Handle a mouse release on this trackContentObjectView. +/*! \brief Handle a mouse release on this ClipView. * * If we're in move or resize mode, journal the change as appropriate. * Then tidy up. * * \param me The QMouseEvent to handle. */ -void TrackContentObjectView::mouseReleaseEvent( QMouseEvent * me ) +void ClipView::mouseReleaseEvent( QMouseEvent * me ) { // If the CopySelection was chosen as the action due to mouse movement, // it will have been cleared. At this point Toggle is the desired action. @@ -1007,14 +1005,14 @@ void TrackContentObjectView::mouseReleaseEvent( QMouseEvent * me ) } else if( m_action == Move || m_action == Resize || m_action == ResizeLeft ) { - // TODO: Fix m_tco->setJournalling() consistency - m_tco->setJournalling( true ); + // TODO: Fix m_clip->setJournalling() consistency + m_clip->setJournalling( true ); } else if( m_action == Split ) { const float ppb = m_trackView->trackContainerView()->pixelsPerBar(); const TimePos relPos = me->pos().x() * TimePos::ticksPerBar() / ppb; - splitTCO(unquantizedModHeld(me) ? + splitClip(unquantizedModHeld(me) ? relPos : quantizeSplitPos(relPos, me->modifiers() & Qt::ShiftModifier) ); @@ -1031,20 +1029,20 @@ void TrackContentObjectView::mouseReleaseEvent( QMouseEvent * me ) -/*! \brief Set up the context menu for this trackContentObjectView. +/*! \brief Set up the context menu for this ClipView. * * Set up the various context menu events that can apply to a - * track content object view. + * ClipView. * * \param cme The QContextMenuEvent to add the actions to. */ -void TrackContentObjectView::contextMenuEvent( QContextMenuEvent * cme ) +void ClipView::contextMenuEvent( QContextMenuEvent * cme ) { - QVector selectedTCOs = getClickedTCOs(); + QVector selectedClips = getClickedClips(); - // Depending on whether we right-clicked a selection or an individual TCO we will have + // Depending on whether we right-clicked a selection or an individual Clip we will have // different labels for the actions. - bool individualTCO = selectedTCOs.size() <= 1; + bool individualClip = selectedClips.size() <= 1; if( cme->modifiers() ) { @@ -1053,11 +1051,11 @@ void TrackContentObjectView::contextMenuEvent( QContextMenuEvent * cme ) QMenu contextMenu( this ); - if( fixedTCOs() == false ) + if( fixedClips() == false ) { contextMenu.addAction( embed::getIconPixmap( "cancel" ), - individualTCO + individualClip ? tr("Delete (middle mousebutton)") : tr("Delete selection (middle mousebutton)"), [this](){ contextMenuAction( Remove ); } ); @@ -1066,12 +1064,12 @@ void TrackContentObjectView::contextMenuEvent( QContextMenuEvent * cme ) contextMenu.addAction( embed::getIconPixmap( "edit_cut" ), - individualTCO + individualClip ? tr("Cut") : tr("Cut selection"), [this](){ contextMenuAction( Cut ); } ); - if (canMergeSelection(selectedTCOs)) + if (canMergeSelection(selectedClips)) { contextMenu.addAction( embed::getIconPixmap("edit_merge"), @@ -1083,7 +1081,7 @@ void TrackContentObjectView::contextMenuEvent( QContextMenuEvent * cme ) contextMenu.addAction( embed::getIconPixmap( "edit_copy" ), - individualTCO + individualClip ? tr("Copy") : tr("Copy selection"), [this](){ contextMenuAction( Copy ); } ); @@ -1097,7 +1095,7 @@ void TrackContentObjectView::contextMenuEvent( QContextMenuEvent * cme ) contextMenu.addAction( embed::getIconPixmap( "muted" ), - (individualTCO + (individualClip ? tr("Mute/unmute (<%1> + middle click)") : tr("Mute/unmute selection (<%1> + middle click)")).arg(UI_CTRL_KEY), [this](){ contextMenuAction( Mute ); } ); @@ -1116,10 +1114,10 @@ void TrackContentObjectView::contextMenuEvent( QContextMenuEvent * cme ) contextMenu.exec( QCursor::pos() ); } -// This method processes the actions from the context menu of the TCO View. -void TrackContentObjectView::contextMenuAction( ContextMenuAction action ) +// This method processes the actions from the context menu of the Clip View. +void ClipView::contextMenuAction( ContextMenuAction action ) { - QVector active = getClickedTCOs(); + QVector active = getClickedClips(); // active will be later used for the remove, copy, cut or toggleMute methods switch( action ) @@ -1140,116 +1138,116 @@ void TrackContentObjectView::contextMenuAction( ContextMenuAction action ) toggleMute( active ); break; case Merge: - mergeTCOs(active); + mergeClips(active); break; } } -QVector TrackContentObjectView::getClickedTCOs() +QVector ClipView::getClickedClips() { // Get a list of selected selectableObjects QVector sos = getGUI()->songEditor()->m_editor->selectedObjects(); - // Convert to a list of selected TCOVs - QVector selection; + // Convert to a list of selected ClipVs + QVector selection; selection.reserve( sos.size() ); for( auto so: sos ) { - TrackContentObjectView *tcov = dynamic_cast ( so ); - if( tcov != nullptr ) + ClipView *clipv = dynamic_cast ( so ); + if( clipv != nullptr ) { - selection.append( tcov ); + selection.append( clipv ); } } // If we clicked part of the selection, affect all selected clips. Otherwise affect the clip we clicked return selection.contains(this) ? selection - : QVector( 1, this ); + : QVector( 1, this ); } -void TrackContentObjectView::remove( QVector tcovs ) +void ClipView::remove( QVector clipvs ) { - for( auto tcov: tcovs ) + for( auto clipv: clipvs ) { // No need to check if it's nullptr because we check when building the QVector - tcov->remove(); + clipv->remove(); } } -void TrackContentObjectView::copy( QVector tcovs ) +void ClipView::copy( QVector clipvs ) { // For copyStringPair() using namespace Clipboard; - // Write the TCOs to a DataFile for copying - DataFile dataFile = createTCODataFiles( tcovs ); + // Write the Clips to a DataFile for copying + DataFile dataFile = createClipDataFiles( clipvs ); - // Copy the TCO type as a key and the TCO data file to the clipboard - copyStringPair( QString( "tco_%1" ).arg( m_tco->getTrack()->type() ), + // Copy the Clip type as a key and the Clip data file to the clipboard + copyStringPair( QString( "clip_%1" ).arg( m_clip->getTrack()->type() ), dataFile.toString() ); } -void TrackContentObjectView::cut( QVector tcovs ) +void ClipView::cut( QVector clipvs ) { - // Copy the selected TCOs - copy( tcovs ); + // Copy the selected Clips + copy( clipvs ); - // Now that the TCOs are copied we can delete them, since we are cutting - remove( tcovs ); + // Now that the Clips are copied we can delete them, since we are cutting + remove( clipvs ); } -void TrackContentObjectView::paste() +void ClipView::paste() { // For getMimeData() using namespace Clipboard; // If possible, paste the selection on the TimePos of the selected Track and remove it - TimePos tcoPos = TimePos( m_tco->startPosition() ); + TimePos clipPos = TimePos( m_clip->startPosition() ); TrackContentWidget *tcw = getTrackView()->getTrackContentWidget(); - if( tcw->pasteSelection( tcoPos, getMimeData() ) ) + if( tcw->pasteSelection( clipPos, getMimeData() ) ) { - // If we succeed on the paste we delete the TCO we pasted on + // If we succeed on the paste we delete the Clip we pasted on remove(); } } -void TrackContentObjectView::toggleMute( QVector tcovs ) +void ClipView::toggleMute( QVector clipvs ) { - for( auto tcov: tcovs ) + for( auto clipv: clipvs ) { - // No need to check for nullptr because we check while building the tcovs QVector - tcov->getTrackContentObject()->toggleMute(); + // No need to check for nullptr because we check while building the clipvs QVector + clipv->getClip()->toggleMute(); } } -bool TrackContentObjectView::canMergeSelection(QVector tcovs) +bool ClipView::canMergeSelection(QVector clipvs) { - // Can't merge a single TCO - if (tcovs.size() < 2) { return false; } + // Can't merge a single Clip + if (clipvs.size() < 2) { return false; } - // We check if the owner of the first TCO is an Instrument Track - bool isInstrumentTrack = dynamic_cast(tcovs.at(0)->getTrackView()); + // We check if the owner of the first Clip is an Instrument Track + bool isInstrumentTrack = dynamic_cast(clipvs.at(0)->getTrackView()); - // Then we create a set with all the TCOs owners + // Then we create a set with all the Clips owners std::set ownerTracks; - for (auto tcov: tcovs) { ownerTracks.insert(tcov->getTrackView()); } + for (auto clipv: clipvs) { ownerTracks.insert(clipv->getTrackView()); } // Can merge if there's only one owner track and it's an Instrument Track return isInstrumentTrack && ownerTracks.size() == 1; } -void TrackContentObjectView::mergeTCOs(QVector tcovs) +void ClipView::mergeClips(QVector clipvs) { - // Get the track that we are merging TCOs in + // Get the track that we are merging Clips in InstrumentTrack* track = - dynamic_cast(tcovs.at(0)->getTrackView()->getTrack()); + dynamic_cast(clipvs.at(0)->getTrackView()->getTrack()); if (!track) { - qWarning("Warning: Couldn't retrieve InstrumentTrack in mergeTCOs()"); + qWarning("Warning: Couldn't retrieve InstrumentTrack in mergeClips()"); return; } @@ -1257,62 +1255,62 @@ void TrackContentObjectView::mergeTCOs(QVector tcovs) track->addJournalCheckPoint(); track->saveJournallingState(false); - // Find the earliest position of all the selected TCOVs - const auto earliestTCOV = std::min_element(tcovs.constBegin(), tcovs.constEnd(), - [](TrackContentObjectView* a, TrackContentObjectView* b) + // Find the earliest position of all the selected ClipVs + const auto earliestClipV = std::min_element(clipvs.constBegin(), clipvs.constEnd(), + [](ClipView* a, ClipView* b) { - return a->getTrackContentObject()->startPosition() < - b->getTrackContentObject()->startPosition(); + return a->getClip()->startPosition() < + b->getClip()->startPosition(); } ); - const TimePos earliestPos = (*earliestTCOV)->getTrackContentObject()->startPosition(); + const TimePos earliestPos = (*earliestClipV)->getClip()->startPosition(); - // Create a pattern where all notes will be added - Pattern* newPattern = dynamic_cast(track->createTCO(earliestPos)); - if (!newPattern) + // Create a clip where all notes will be added + MidiClip* newMidiClip = dynamic_cast(track->createClip(earliestPos)); + if (!newMidiClip) { - qWarning("Warning: Failed to convert TCO to Pattern on mergeTCOs"); + qWarning("Warning: Failed to convert Clip to MidiClip on mergeClips"); return; } - newPattern->saveJournallingState(false); + newMidiClip->saveJournallingState(false); - // Add the notes and remove the TCOs that are being merged - for (auto tcov: tcovs) + // Add the notes and remove the Clips that are being merged + for (auto clipv: clipvs) { - // Convert TCOV to PatternView - PatternView* pView = dynamic_cast(tcov); + // Convert ClipV to MidiClipView + MidiClipView* mcView = dynamic_cast(clipv); - if (!pView) + if (!mcView) { - qWarning("Warning: Non-pattern TCO on InstrumentTrack"); + qWarning("Warning: Non-MidiClip Clip on InstrumentTrack"); continue; } - NoteVector currentTCONotes = pView->getPattern()->notes(); - TimePos pViewPos = pView->getPattern()->startPosition(); + NoteVector currentClipNotes = mcView->getMidiClip()->notes(); + TimePos mcViewPos = mcView->getMidiClip()->startPosition(); - for (Note* note: currentTCONotes) + for (Note* note: currentClipNotes) { - Note* newNote = newPattern->addNote(*note, false); + Note* newNote = newMidiClip->addNote(*note, false); TimePos originalNotePos = newNote->pos(); - newNote->setPos(originalNotePos + (pViewPos - earliestPos)); + newNote->setPos(originalNotePos + (mcViewPos - earliestPos)); } // We disable the journalling system before removing, so the // removal doesn't get added to the undo/redo history - tcov->getTrackContentObject()->saveJournallingState(false); - // No need to check for nullptr because we check while building the tcovs QVector - tcov->remove(); + clipv->getClip()->saveJournallingState(false); + // No need to check for nullptr because we check while building the clipvs QVector + clipv->remove(); } - // Update length since we might have moved notes beyond the end of the pattern length - newPattern->updateLength(); + // Update length since we might have moved notes beyond the end of the MidiClip length + newMidiClip->updateLength(); // Rearrange notes because we might have moved them - newPattern->rearrangeAllNotes(); + newMidiClip->rearrangeAllNotes(); // Restore journalling states now that the operation is finished - newPattern->restoreJournallingState(); + newMidiClip->restoreJournallingState(); track->restoreJournallingState(); // Update song Engine::getSong()->setModified(); @@ -1322,31 +1320,31 @@ void TrackContentObjectView::mergeTCOs(QVector tcovs) -/*! \brief How many pixels a bar takes for this trackContentObjectView. +/*! \brief How many pixels a bar takes for this ClipView. * * \return the number of pixels per bar. */ -float TrackContentObjectView::pixelsPerBar() +float ClipView::pixelsPerBar() { return m_trackView->trackContainerView()->pixelsPerBar(); } /*! \brief Save the offsets between all selected tracks and a clicked track */ -void TrackContentObjectView::setInitialOffsets() +void ClipView::setInitialOffsets() { QVector so = m_trackView->trackContainerView()->selectedObjects(); QVector offsets; for( QVector::iterator it = so.begin(); it != so.end(); ++it ) { - TrackContentObjectView * tcov = - dynamic_cast( *it ); - if( tcov == nullptr ) + ClipView * clipv = + dynamic_cast( *it ); + if( clipv == nullptr ) { continue; } - offsets.push_back( tcov->m_tco->startPosition() - m_initialTCOPos ); + offsets.push_back( clipv->m_clip->startPosition() - m_initialClipPos ); } m_initialOffsets = offsets; @@ -1360,7 +1358,7 @@ void TrackContentObjectView::setInitialOffsets() * \param _me The QMouseEvent. * \param distance The threshold distance that the mouse has moved to return true. */ -bool TrackContentObjectView::mouseMovedDistance( QMouseEvent * me, int distance ) +bool ClipView::mouseMovedDistance( QMouseEvent * me, int distance ) { QPoint dPos = mapToGlobal( me->pos() ) - m_initialMouseGlobalPos; const int pixelsMoved = dPos.manhattanLength(); @@ -1370,7 +1368,7 @@ bool TrackContentObjectView::mouseMovedDistance( QMouseEvent * me, int distance -bool TrackContentObjectView::unquantizedModHeld( QMouseEvent * me ) +bool ClipView::unquantizedModHeld( QMouseEvent * me ) { return me->modifiers() & Qt::ControlModifier || me->modifiers() & Qt::AltModifier; } @@ -1378,19 +1376,19 @@ bool TrackContentObjectView::unquantizedModHeld( QMouseEvent * me ) -/*! \brief Calculate the new position of a dragged TCO from a mouse event +/*! \brief Calculate the new position of a dragged Clip from a mouse event * * * \param me The QMouseEvent */ -TimePos TrackContentObjectView::draggedTCOPos( QMouseEvent * me ) +TimePos ClipView::draggedClipPos( QMouseEvent * me ) { //Pixels per bar const float ppb = m_trackView->trackContainerView()->pixelsPerBar(); // The pixel distance that the mouse has moved const int mouseOff = mapToGlobal(me->pos()).x() - m_initialMouseGlobalPos.x(); - TimePos newPos = m_initialTCOPos + mouseOff * TimePos::ticksPerBar() / ppb; - TimePos offset = newPos - m_initialTCOPos; + TimePos newPos = m_initialClipPos + mouseOff * TimePos::ticksPerBar() / ppb; + TimePos offset = newPos - m_initialClipPos; // If the user is holding alt, or pressed ctrl after beginning the drag, don't quantize if ( me->button() != Qt::NoButton || unquantizedModHeld(me) ) { // We want to preserve this adjusted offset, even if the user switches to snapping @@ -1401,22 +1399,23 @@ TimePos TrackContentObjectView::draggedTCOPos( QMouseEvent * me ) // or end position, whichever is closest to the actual position TimePos startQ = newPos.quantize( getGUI()->songEditor()->m_editor->getSnapSize() ); // Find start position that gives snapped clip end position - TimePos endQ = ( newPos + m_tco->length() ); + TimePos endQ = ( newPos + m_clip->length() ); endQ = endQ.quantize( getGUI()->songEditor()->m_editor->getSnapSize() ); - endQ = endQ - m_tco->length(); + endQ = endQ - m_clip->length(); + // Select the position closest to actual position if ( abs(newPos - startQ) < abs(newPos - endQ) ) newPos = startQ; else newPos = endQ; } else { // Otherwise, quantize moved distance (preserves user offsets) - newPos = m_initialTCOPos + offset.quantize( getGUI()->songEditor()->m_editor->getSnapSize() ); + newPos = m_initialClipPos + offset.quantize( getGUI()->songEditor()->m_editor->getSnapSize() ); } return newPos; } -int TrackContentObjectView::knifeMarkerPos( QMouseEvent * me ) +int ClipView::knifeMarkerPos( QMouseEvent * me ) { //Position relative to start of clip const int markerPos = me->pos().x(); @@ -1438,64 +1437,64 @@ int TrackContentObjectView::knifeMarkerPos( QMouseEvent * me ) -TimePos TrackContentObjectView::quantizeSplitPos( TimePos midiPos, bool shiftMode ) +TimePos ClipView::quantizeSplitPos( TimePos midiPos, bool shiftMode ) { const float snapSize = getGUI()->songEditor()->m_editor->getSnapSize(); if ( shiftMode ) { //If shift is held we quantize the length of the new left clip... const TimePos leftPos = midiPos.quantize( snapSize ); //...or right clip... - const TimePos rightOff = m_tco->length() - midiPos; - const TimePos rightPos = m_tco->length() - rightOff.quantize( snapSize ); + const TimePos rightOff = m_clip->length() - midiPos; + const TimePos rightPos = m_clip->length() - rightOff.quantize( snapSize ); //...whichever gives a position closer to the cursor if ( abs(leftPos - midiPos) < abs(rightPos - midiPos) ) { return leftPos; } else { return rightPos; } } else { - return TimePos(midiPos + m_initialTCOPos).quantize( snapSize ) - m_initialTCOPos; + return TimePos(midiPos + m_initialClipPos).quantize( snapSize ) - m_initialClipPos; } } -// Return the color that the TCO's background should be -QColor TrackContentObjectView::getColorForDisplay( QColor defaultColor ) +// Return the color that the Clip's background should be +QColor ClipView::getColorForDisplay( QColor defaultColor ) { - // Get the pure TCO color - auto tcoColor = m_tco->hasColor() - ? m_tco->usesCustomClipColor() - ? m_tco->color() - : m_tco->getTrack()->color() + // Get the pure Clip color + auto clipColor = m_clip->hasColor() + ? m_clip->usesCustomClipColor() + ? m_clip->color() + : m_clip->getTrack()->color() : defaultColor; // Set variables QColor c, mutedCustomColor; - bool muted = m_tco->getTrack()->isMuted() || m_tco->isMuted(); - mutedCustomColor = tcoColor; + bool muted = m_clip->getTrack()->isMuted() || m_clip->isMuted(); + mutedCustomColor = clipColor; mutedCustomColor.setHsv( mutedCustomColor.hsvHue(), mutedCustomColor.hsvSaturation() / 4, mutedCustomColor.value() ); // Change the pure color by state: selected, muted, colored, normal if( isSelected() ) { - c = m_tco->hasColor() + c = m_clip->hasColor() ? ( muted ? mutedCustomColor.darker( 350 ) - : tcoColor.darker( 150 ) ) + : clipColor.darker( 150 ) ) : selectedColor(); } else { if( muted ) { - c = m_tco->hasColor() + c = m_clip->hasColor() ? mutedCustomColor.darker( 250 ) : mutedBackgroundColor(); } else { - c = tcoColor; + c = clipColor; } } diff --git a/src/gui/FileBrowser.cpp b/src/gui/FileBrowser.cpp index fb61deada23..4a37aac9183 100644 --- a/src/gui/FileBrowser.cpp +++ b/src/gui/FileBrowser.cpp @@ -859,7 +859,7 @@ bool FileBrowserTreeWidget::openInNewSampleTrack(FileItem* item) // Add the sample clip to the track Engine::audioEngine()->requestChangeInModel(); - SampleTCO* clip = static_cast(sampleTrack->createTCO(0)); + SampleClip* clip = static_cast(sampleTrack->createClip(0)); clip->setSampleFile(item->fullName()); Engine::audioEngine()->doneChangeInModel(); return true; diff --git a/src/gui/LmmsStyle.cpp b/src/gui/LmmsStyle.cpp index bc0115f49bf..5d1b299458f 100644 --- a/src/gui/LmmsStyle.cpp +++ b/src/gui/LmmsStyle.cpp @@ -45,11 +45,11 @@ QLinearGradient getGradient( const QColor & _col, const QRectF & _rect ) qreal saturation = _col.saturationF(); QColor c = _col; - c.setHsvF( hue, 0.42 * saturation, 0.98 * value ); // TODO: pattern: 1.08 + c.setHsvF( hue, 0.42 * saturation, 0.98 * value ); // TODO: MIDI clip: 1.08 g.setColorAt( 0, c ); - c.setHsvF( hue, 0.58 * saturation, 0.95 * value ); // TODO: pattern: 1.05 + c.setHsvF( hue, 0.58 * saturation, 0.95 * value ); // TODO: MIDI clip: 1.05 g.setColorAt( 0.25, c ); - c.setHsvF( hue, 0.70 * saturation, 0.93 * value ); // TODO: pattern: 1.03 + c.setHsvF( hue, 0.70 * saturation, 0.93 * value ); // TODO: MIDI clip: 1.03 g.setColorAt( 0.5, c ); c.setHsvF( hue, 0.95 * saturation, 0.9 * value ); diff --git a/src/gui/MainWindow.cpp b/src/gui/MainWindow.cpp index 21fad65aa6f..f3ac68aae61 100644 --- a/src/gui/MainWindow.cpp +++ b/src/gui/MainWindow.cpp @@ -1131,6 +1131,8 @@ void MainWindow::toggleMicrotunerWin() } + + void MainWindow::updateViewMenu() { m_viewMenu->clear(); @@ -1288,7 +1290,7 @@ void MainWindow::updatePlayPauseIcons() getGUI()->songEditor()->setPauseIcon( true ); break; - case Song::Mode_PlayAutomationPattern: + case Song::Mode_PlayAutomationClip: getGUI()->automationEditor()->setPauseIcon( true ); break; @@ -1296,7 +1298,7 @@ void MainWindow::updatePlayPauseIcons() getGUI()->getBBEditor()->setPauseIcon( true ); break; - case Song::Mode_PlayPattern: + case Song::Mode_PlayMidiClip: getGUI()->pianoRoll()->setPauseIcon( true ); break; diff --git a/src/gui/PatternView.cpp b/src/gui/MidiClipView.cpp similarity index 69% rename from src/gui/PatternView.cpp rename to src/gui/MidiClipView.cpp index 34c947283bb..913c8df67b2 100644 --- a/src/gui/PatternView.cpp +++ b/src/gui/MidiClipView.cpp @@ -1,5 +1,5 @@ /* - * Pattern.cpp - implementation of class pattern which holds notes + * MidiClipView.cpp - implementation of class MidiClipView which displays notes * * Copyright (c) 2004-2014 Tobias Doerffel * Copyright (c) 2005-2007 Danny McRae @@ -23,7 +23,7 @@ * */ -#include "PatternView.h" +#include "MidiClipView.h" #include #include @@ -35,9 +35,9 @@ #include "PianoRoll.h" #include "RenameDialog.h" -PatternView::PatternView( Pattern* pattern, TrackView* parent ) : - TrackContentObjectView( pattern, parent ), - m_pat( pattern ), +MidiClipView::MidiClipView( MidiClip* clip, TrackView* parent ) : + ClipView( clip, parent ), + m_clip( clip ), m_paintPixmap(), m_noteFillColor(255, 255, 255, 220), m_noteBorderColor(255, 255, 255, 220), @@ -45,7 +45,7 @@ PatternView::PatternView( Pattern* pattern, TrackView* parent ) : m_mutedNoteBorderColor(100, 100, 100, 220), m_legacySEBB(ConfigManager::inst()->value("ui","legacysebb","0").toInt()) { - connect( getGUI()->pianoRoll(), SIGNAL( currentPatternChanged() ), + connect( getGUI()->pianoRoll(), SIGNAL( currentMidiClipChanged() ), this, SLOT( update() ) ); if( s_stepBtnOn0 == nullptr ) @@ -80,27 +80,27 @@ PatternView::PatternView( Pattern* pattern, TrackView* parent ) : -Pattern* PatternView::getPattern() +MidiClip* MidiClipView::getMidiClip() { - return m_pat; + return m_clip; } -void PatternView::update() +void MidiClipView::update() { - ToolTip::add(this, m_pat->name()); + ToolTip::add(this, m_clip->name()); - TrackContentObjectView::update(); + ClipView::update(); } -void PatternView::openInPianoRoll() +void MidiClipView::openInPianoRoll() { - getGUI()->pianoRoll()->setCurrentPattern( m_pat ); + getGUI()->pianoRoll()->setCurrentMidiClip( m_clip ); getGUI()->pianoRoll()->parentWidget()->show(); getGUI()->pianoRoll()->show(); getGUI()->pianoRoll()->setFocus(); @@ -110,9 +110,9 @@ void PatternView::openInPianoRoll() -void PatternView::setGhostInPianoRoll() +void MidiClipView::setGhostInPianoRoll() { - getGUI()->pianoRoll()->setGhostPattern( m_pat ); + getGUI()->pianoRoll()->setGhostMidiClip( m_clip ); getGUI()->pianoRoll()->parentWidget()->show(); getGUI()->pianoRoll()->show(); getGUI()->pianoRoll()->setFocus(); @@ -121,23 +121,23 @@ void PatternView::setGhostInPianoRoll() -void PatternView::resetName() { m_pat->setName(""); } +void MidiClipView::resetName() { m_clip->setName(""); } -void PatternView::changeName() +void MidiClipView::changeName() { - QString s = m_pat->name(); + QString s = m_clip->name(); RenameDialog rename_dlg( s ); rename_dlg.exec(); - m_pat->setName( s ); + m_clip->setName( s ); } -void PatternView::constructContextMenu( QMenu * _cm ) +void MidiClipView::constructContextMenu( QMenu * _cm ) { QAction * a = new QAction( embed::getIconPixmap( "piano" ), tr( "Open in piano-roll" ), _cm ); @@ -147,7 +147,7 @@ void PatternView::constructContextMenu( QMenu * _cm ) QAction * b = new QAction( embed::getIconPixmap( "ghost_note" ), tr( "Set as ghost in piano-roll" ), _cm ); - if( m_pat->empty() ) { b->setEnabled( false ); } + if( m_clip->empty() ) { b->setEnabled( false ); } _cm->insertAction( _cm->actions()[1], b ); connect( b, SIGNAL( triggered( bool ) ), this, SLOT( setGhostInPianoRoll() ) ); @@ -155,7 +155,7 @@ void PatternView::constructContextMenu( QMenu * _cm ) _cm->addSeparator(); _cm->addAction( embed::getIconPixmap( "edit_erase" ), - tr( "Clear all notes" ), m_pat, SLOT( clear() ) ); + tr( "Clear all notes" ), m_clip, SLOT( clear() ) ); _cm->addSeparator(); _cm->addAction( embed::getIconPixmap( "reload" ), tr( "Reset name" ), @@ -164,27 +164,27 @@ void PatternView::constructContextMenu( QMenu * _cm ) tr( "Change name" ), this, SLOT( changeName() ) ); - if ( m_pat->type() == Pattern::BeatPattern ) + if ( m_clip->type() == MidiClip::BeatClip ) { _cm->addSeparator(); _cm->addAction( embed::getIconPixmap( "step_btn_add" ), - tr( "Add steps" ), m_pat, SLOT( addSteps() ) ); + tr( "Add steps" ), m_clip, SLOT( addSteps() ) ); _cm->addAction( embed::getIconPixmap( "step_btn_remove" ), - tr( "Remove steps" ), m_pat, SLOT( removeSteps() ) ); + tr( "Remove steps" ), m_clip, SLOT( removeSteps() ) ); _cm->addAction( embed::getIconPixmap( "step_btn_duplicate" ), - tr( "Clone Steps" ), m_pat, SLOT( cloneSteps() ) ); + tr( "Clone Steps" ), m_clip, SLOT( cloneSteps() ) ); } } -void PatternView::mousePressEvent( QMouseEvent * _me ) +void MidiClipView::mousePressEvent( QMouseEvent * _me ) { - bool displayBB = fixedTCOs() || (pixelsPerBar() >= 96 && m_legacySEBB); + bool displayBB = fixedClips() || (pixelsPerBar() >= 96 && m_legacySEBB); if( _me->button() == Qt::LeftButton && - m_pat->m_patternType == Pattern::BeatPattern && + m_clip->m_clipType == MidiClip::BeatClip && displayBB && _me->y() > height() - s_stepBtnOff->height() ) // when mouse button is pressed in beat/bassline -mode @@ -192,36 +192,36 @@ void PatternView::mousePressEvent( QMouseEvent * _me ) { // get the step number that was clicked on and // do calculations in floats to prevent rounding errors... - float tmp = ( ( float(_me->x()) - TCO_BORDER_WIDTH ) * - float( m_pat -> m_steps ) ) / float(width() - TCO_BORDER_WIDTH*2); + float tmp = ( ( float(_me->x()) - CLIP_BORDER_WIDTH ) * + float( m_clip -> m_steps ) ) / float(width() - CLIP_BORDER_WIDTH*2); int step = int( tmp ); // debugging to ensure we get the correct step... // qDebug( "Step (%f) %d", tmp, step ); - if( step >= m_pat->m_steps ) + if( step >= m_clip->m_steps ) { - qDebug( "Something went wrong in pattern.cpp: step %d doesn't exist in pattern!", step ); + qDebug( "Something went wrong in clip.cpp: step %d doesn't exist in clip!", step ); return; } - Note * n = m_pat->noteAtStep( step ); + Note * n = m_clip->noteAtStep( step ); if( n == nullptr ) { - m_pat->addStepNote( step ); + m_clip->addStepNote( step ); } else // note at step found { - m_pat->addJournalCheckPoint(); - m_pat->setStep( step, false ); + m_clip->addJournalCheckPoint(); + m_clip->setStep( step, false ); } Engine::getSong()->setModified(); update(); - if( getGUI()->pianoRoll()->currentPattern() == m_pat ) + if( getGUI()->pianoRoll()->currentMidiClip() == m_clip ) { getGUI()->pianoRoll()->update(); } @@ -231,18 +231,18 @@ void PatternView::mousePressEvent( QMouseEvent * _me ) // if not in beat/bassline -mode, let parent class handle the event { - TrackContentObjectView::mousePressEvent( _me ); + ClipView::mousePressEvent( _me ); } } -void PatternView::mouseDoubleClickEvent(QMouseEvent *_me) +void MidiClipView::mouseDoubleClickEvent(QMouseEvent *_me) { if( _me->button() != Qt::LeftButton ) { _me->ignore(); return; } - if( m_pat->m_patternType == Pattern::MelodyPattern || !fixedTCOs() ) + if( m_clip->m_clipType == MidiClip::MelodyClip || !fixedClips() ) { openInPianoRoll(); } @@ -251,28 +251,28 @@ void PatternView::mouseDoubleClickEvent(QMouseEvent *_me) -void PatternView::wheelEvent(QWheelEvent * we) +void MidiClipView::wheelEvent(QWheelEvent * we) { - if(m_pat->m_patternType == Pattern::BeatPattern && - (fixedTCOs() || pixelsPerBar() >= 96) && + if(m_clip->m_clipType == MidiClip::BeatClip && + (fixedClips() || pixelsPerBar() >= 96) && position(we).y() > height() - s_stepBtnOff->height()) { // get the step number that was wheeled on and // do calculations in floats to prevent rounding errors... - float tmp = ((float(position(we).x()) - TCO_BORDER_WIDTH) * - float(m_pat -> m_steps)) / float(width() - TCO_BORDER_WIDTH*2); + float tmp = ((float(position(we).x()) - CLIP_BORDER_WIDTH) * + float(m_clip -> m_steps)) / float(width() - CLIP_BORDER_WIDTH*2); int step = int( tmp ); - if( step >= m_pat->m_steps ) + if( step >= m_clip->m_steps ) { return; } - Note * n = m_pat->noteAtStep( step ); + Note * n = m_clip->noteAtStep( step ); if(!n && we->angleDelta().y() > 0) { - n = m_pat->addStepNote( step ); + n = m_clip->addStepNote( step ); n->setVolume( 0 ); } if( n != nullptr ) @@ -290,7 +290,7 @@ void PatternView::wheelEvent(QWheelEvent * we) Engine::getSong()->setModified(); update(); - if( getGUI()->pianoRoll()->currentPattern() == m_pat ) + if( getGUI()->pianoRoll()->currentMidiClip() == m_clip ) { getGUI()->pianoRoll()->update(); } @@ -299,7 +299,7 @@ void PatternView::wheelEvent(QWheelEvent * we) } else { - TrackContentObjectView::wheelEvent(we); + ClipView::wheelEvent(we); } } @@ -309,7 +309,7 @@ static int computeNoteRange(int minKey, int maxKey) return (maxKey - minKey) + 1; } -void PatternView::paintEvent( QPaintEvent * ) +void MidiClipView::paintEvent( QPaintEvent * ) { QPainter painter( this ); @@ -329,14 +329,14 @@ void PatternView::paintEvent( QPaintEvent * ) QPainter p( &m_paintPixmap ); QColor c; - bool const muted = m_pat->getTrack()->isMuted() || m_pat->isMuted(); - bool current = getGUI()->pianoRoll()->currentPattern() == m_pat; - bool beatPattern = m_pat->m_patternType == Pattern::BeatPattern; + bool const muted = m_clip->getTrack()->isMuted() || m_clip->isMuted(); + bool current = getGUI()->pianoRoll()->currentMidiClip() == m_clip; + bool beatClip = m_clip->m_clipType == MidiClip::BeatClip; - if( beatPattern ) + if( beatClip ) { - // Do not paint BBTCOs how we paint pattern TCOs - c = BBPatternBackground(); + // Do not paint BBClips how we paint MidiClips + c = BBClipBackground(); } else { @@ -345,10 +345,10 @@ void PatternView::paintEvent( QPaintEvent * ) // invert the gradient for the background in the B&B editor QLinearGradient lingrad( 0, 0, 0, height() ); - lingrad.setColorAt( beatPattern ? 0 : 1, c.darker( 300 ) ); - lingrad.setColorAt( beatPattern ? 1 : 0, c ); + lingrad.setColorAt( beatClip ? 0 : 1, c.darker( 300 ) ); + lingrad.setColorAt( beatClip ? 1 : 0, c ); - // paint a black rectangle under the pattern to prevent glitches with transparent backgrounds + // paint a black rectangle under the clip to prevent glitches with transparent backgrounds p.fillRect( rect(), QColor( 0, 0, 0 ) ); if( gradient() ) @@ -362,12 +362,12 @@ void PatternView::paintEvent( QPaintEvent * ) // Check whether we will paint a text box and compute its potential height // This is needed so we can paint the notes underneath it. - bool const drawName = !m_pat->name().isEmpty(); - bool const drawTextBox = !beatPattern && drawName; + bool const drawName = !m_clip->name().isEmpty(); + bool const drawTextBox = !beatClip && drawName; - // TODO Warning! This might cause problems if TrackContentObjectView::paintTextLabel changes + // TODO Warning! This might cause problems if ClipView::paintTextLabel changes int textBoxHeight = 0; - const int textTop = TCO_BORDER_WIDTH + 1; + const int textTop = CLIP_BORDER_WIDTH + 1; if (drawTextBox) { QFont labelFont = this->font(); @@ -378,22 +378,22 @@ void PatternView::paintEvent( QPaintEvent * ) } // Compute pixels per bar - const int baseWidth = fixedTCOs() ? parentWidget()->width() - 2 * TCO_BORDER_WIDTH - : width() - TCO_BORDER_WIDTH; - const float pixelsPerBar = baseWidth / (float) m_pat->length().getBar(); + const int baseWidth = fixedClips() ? parentWidget()->width() - 2 * CLIP_BORDER_WIDTH + : width() - CLIP_BORDER_WIDTH; + const float pixelsPerBar = baseWidth / (float) m_clip->length().getBar(); // Length of one bar/beat in the [0,1] x [0,1] coordinate system - const float barLength = 1. / m_pat->length().getBar(); + const float barLength = 1. / m_clip->length().getBar(); const float tickLength = barLength / TimePos::ticksPerBar(); - const int x_base = TCO_BORDER_WIDTH; + const int x_base = CLIP_BORDER_WIDTH; - bool displayBB = fixedTCOs() || (pixelsPerBar >= 96 && m_legacySEBB); - // melody pattern paint event - NoteVector const & noteCollection = m_pat->m_notes; - if( m_pat->m_patternType == Pattern::MelodyPattern && !noteCollection.empty() ) + bool displayBB = fixedClips() || (pixelsPerBar >= 96 && m_legacySEBB); + // melody clip paint event + NoteVector const & noteCollection = m_clip->m_notes; + if( m_clip->m_clipType == MidiClip::MelodyClip && !noteCollection.empty() ) { - // Compute the minimum and maximum key in the pattern + // Compute the minimum and maximum key in the clip // so that we know how much there is to draw. int maxKey = std::numeric_limits::min(); int minKey = std::numeric_limits::max(); @@ -456,7 +456,7 @@ void PatternView::paintEvent( QPaintEvent * ) // set colour based on mute status QColor noteFillColor = muted ? getMutedNoteFillColor() : getNoteFillColor(); QColor noteBorderColor = muted ? getMutedNoteBorderColor() - : ( m_pat->hasColor() ? c.lighter( 200 ) : getNoteBorderColor() ); + : ( m_clip->hasColor() ? c.lighter( 200 ) : getNoteBorderColor() ); bool const drawAsLines = height() < 64; if (drawAsLines) @@ -477,7 +477,7 @@ void PatternView::paintEvent( QPaintEvent * ) float const noteHeight = 1. / adjustedNoteRange; - // scan through all the notes and draw them on the pattern + // scan through all the notes and draw them on the clip for (Note const * currentNote : noteCollection) { // Map to 0, 1, 2, ... @@ -504,18 +504,18 @@ void PatternView::paintEvent( QPaintEvent * ) p.restore(); } - // beat pattern paint event - else if( beatPattern && displayBB ) + // beat clip paint event + else if( beatClip && displayBB ) { QPixmap stepon0; QPixmap stepon200; QPixmap stepoff; QPixmap stepoffl; const int steps = qMax( 1, - m_pat->m_steps ); - const int w = width() - 2 * TCO_BORDER_WIDTH; + m_clip->m_steps ); + const int w = width() - 2 * CLIP_BORDER_WIDTH; - // scale step graphics to fit the beat pattern length + // scale step graphics to fit the beat clip length stepon0 = s_stepBtnOn0->scaled( w / steps, s_stepBtnOn0->height(), Qt::IgnoreAspectRatio, @@ -533,12 +533,12 @@ void PatternView::paintEvent( QPaintEvent * ) Qt::IgnoreAspectRatio, Qt::SmoothTransformation ); - for( int it = 0; it < steps; it++ ) // go through all the steps in the beat pattern + for( int it = 0; it < steps; it++ ) // go through all the steps in the beat clip { - Note * n = m_pat->noteAtStep( it ); + Note * n = m_clip->noteAtStep( it ); // figure out x and y coordinates for step graphic - const int x = TCO_BORDER_WIDTH + static_cast( it * w / steps ); + const int x = CLIP_BORDER_WIDTH + static_cast( it * w / steps ); const int y = height() - s_stepBtnOff->height() - 1; if( n ) @@ -560,7 +560,7 @@ void PatternView::paintEvent( QPaintEvent * ) } } // end for loop - // draw a transparent rectangle over muted patterns + // draw a transparent rectangle over muted clips if ( muted ) { p.setBrush( mutedBackgroundColor() ); @@ -573,39 +573,39 @@ void PatternView::paintEvent( QPaintEvent * ) const int lineSize = 3; p.setPen( c.darker( 200 ) ); - for( bar_t t = 1; t < m_pat->length().getBar(); ++t ) + for( bar_t t = 1; t < m_clip->length().getBar(); ++t ) { p.drawLine( x_base + static_cast( pixelsPerBar * t ) - 1, - TCO_BORDER_WIDTH, x_base + static_cast( - pixelsPerBar * t ) - 1, TCO_BORDER_WIDTH + lineSize ); + CLIP_BORDER_WIDTH, x_base + static_cast( + pixelsPerBar * t ) - 1, CLIP_BORDER_WIDTH + lineSize ); p.drawLine( x_base + static_cast( pixelsPerBar * t ) - 1, - rect().bottom() - ( lineSize + TCO_BORDER_WIDTH ), + rect().bottom() - ( lineSize + CLIP_BORDER_WIDTH ), x_base + static_cast( pixelsPerBar * t ) - 1, - rect().bottom() - TCO_BORDER_WIDTH ); + rect().bottom() - CLIP_BORDER_WIDTH ); } - // pattern name + // clip name if (drawTextBox) { - paintTextLabel(m_pat->name(), p); + paintTextLabel(m_clip->name(), p); } - if( !( fixedTCOs() && beatPattern ) ) + if( !( fixedClips() && beatClip ) ) { // inner border p.setPen( c.lighter( current ? 160 : 130 ) ); - p.drawRect( 1, 1, rect().right() - TCO_BORDER_WIDTH, - rect().bottom() - TCO_BORDER_WIDTH ); + p.drawRect( 1, 1, rect().right() - CLIP_BORDER_WIDTH, + rect().bottom() - CLIP_BORDER_WIDTH ); // outer border p.setPen( current ? c.lighter( 130 ) : c.darker( 300 ) ); p.drawRect( 0, 0, rect().right(), rect().bottom() ); } - // draw the 'muted' pixmap only if the pattern was manually muted - if( m_pat->isMuted() ) + // draw the 'muted' pixmap only if the clip was manually muted + if( m_clip->isMuted() ) { - const int spacing = TCO_BORDER_WIDTH; + const int spacing = CLIP_BORDER_WIDTH; const int size = 14; p.drawPixmap( spacing, height() - ( size + spacing ), embed::getIconPixmap( "muted", size, size ) ); diff --git a/src/gui/SampleTCOView.cpp b/src/gui/SampleClipView.cpp similarity index 57% rename from src/gui/SampleTCOView.cpp rename to src/gui/SampleClipView.cpp index 57ca51893b1..04f3adf5539 100644 --- a/src/gui/SampleTCOView.cpp +++ b/src/gui/SampleClipView.cpp @@ -1,5 +1,5 @@ /* - * SampleTCOView.cpp + * SampleClipView.cpp * * Copyright (c) 2005-2014 Tobias Doerffel * @@ -22,7 +22,7 @@ * */ -#include "SampleTCOView.h" +#include "SampleClipView.h" #include #include @@ -34,43 +34,42 @@ #include "StringPairDrag.h" #include "ToolTip.h" -SampleTCOView::SampleTCOView( SampleTCO * _tco, TrackView * _tv ) : - TrackContentObjectView( _tco, _tv ), - m_tco( _tco ), +SampleClipView::SampleClipView( SampleClip * _clip, TrackView * _tv ) : + ClipView( _clip, _tv ), + m_clip( _clip ), m_paintPixmap() { // update UI and tooltip updateSample(); - // track future changes of SampleTCO - connect(m_tco, SIGNAL(sampleChanged()), this, SLOT(updateSample())); + // track future changes of SampleClip + connect(m_clip, SIGNAL(sampleChanged()), this, SLOT(updateSample())); - connect(m_tco, SIGNAL(wasReversed()), this, SLOT(update())); + connect(m_clip, SIGNAL(wasReversed()), this, SLOT(update())); setStyle( QApplication::style() ); } -void SampleTCOView::updateSample() +void SampleClipView::updateSample() { update(); // set tooltip to filename so that user can see what sample this - // sample-tco contains - ToolTip::add( this, ( m_tco->m_sampleBuffer->audioFile() != "" ) ? - PathUtil::toAbsolute(m_tco->m_sampleBuffer->audioFile()) : + // sample-clip contains + ToolTip::add( this, ( m_clip->m_sampleBuffer->audioFile() != "" ) ? + PathUtil::toAbsolute(m_clip->m_sampleBuffer->audioFile()) : tr( "Double-click to open sample" ) ); } -void SampleTCOView::constructContextMenu(QMenu* cm) +void SampleClipView::constructContextMenu(QMenu* cm) { cm->addSeparator(); - /*contextMenu.addAction( embed::getIconPixmap( "record" ), tr( "Set/clear record" ), - m_tco, SLOT( toggleRecord() ) );*/ + m_clip, SLOT( toggleRecord() ) );*/ cm->addAction( embed::getIconPixmap("flip_x"), @@ -85,12 +84,12 @@ void SampleTCOView::constructContextMenu(QMenu* cm) -void SampleTCOView::dragEnterEvent( QDragEnterEvent * _dee ) +void SampleClipView::dragEnterEvent( QDragEnterEvent * _dee ) { if( StringPairDrag::processDragEnterEvent( _dee, "samplefile,sampledata" ) == false ) { - TrackContentObjectView::dragEnterEvent( _dee ); + ClipView::dragEnterEvent( _dee ); } } @@ -99,85 +98,85 @@ void SampleTCOView::dragEnterEvent( QDragEnterEvent * _dee ) -void SampleTCOView::dropEvent( QDropEvent * _de ) +void SampleClipView::dropEvent( QDropEvent * _de ) { if( StringPairDrag::decodeKey( _de ) == "samplefile" ) { - m_tco->setSampleFile( StringPairDrag::decodeValue( _de ) ); + m_clip->setSampleFile( StringPairDrag::decodeValue( _de ) ); _de->accept(); } else if( StringPairDrag::decodeKey( _de ) == "sampledata" ) { - m_tco->m_sampleBuffer->loadFromBase64( + m_clip->m_sampleBuffer->loadFromBase64( StringPairDrag::decodeValue( _de ) ); - m_tco->updateLength(); + m_clip->updateLength(); update(); _de->accept(); Engine::getSong()->setModified(); } else { - TrackContentObjectView::dropEvent( _de ); + ClipView::dropEvent( _de ); } } -void SampleTCOView::mousePressEvent( QMouseEvent * _me ) +void SampleClipView::mousePressEvent( QMouseEvent * _me ) { if( _me->button() == Qt::LeftButton && _me->modifiers() & Qt::ControlModifier && _me->modifiers() & Qt::ShiftModifier ) { - m_tco->toggleRecord(); + m_clip->toggleRecord(); } else { if( _me->button() == Qt::MiddleButton && _me->modifiers() == Qt::ControlModifier ) { - SampleTCO * sTco = dynamic_cast( getTrackContentObject() ); - if( sTco ) + SampleClip * sClip = dynamic_cast( getClip() ); + if( sClip ) { - sTco->updateTrackTcos(); + sClip->updateTrackClips(); } } - TrackContentObjectView::mousePressEvent( _me ); + ClipView::mousePressEvent( _me ); } } -void SampleTCOView::mouseReleaseEvent(QMouseEvent *_me) +void SampleClipView::mouseReleaseEvent(QMouseEvent *_me) { if( _me->button() == Qt::MiddleButton && !_me->modifiers() ) { - SampleTCO * sTco = dynamic_cast( getTrackContentObject() ); - if( sTco ) + SampleClip * sClip = dynamic_cast( getClip() ); + if( sClip ) { - sTco->playbackPositionChanged(); + sClip->playbackPositionChanged(); } } - TrackContentObjectView::mouseReleaseEvent( _me ); + ClipView::mouseReleaseEvent( _me ); } -void SampleTCOView::mouseDoubleClickEvent( QMouseEvent * ) +void SampleClipView::mouseDoubleClickEvent( QMouseEvent * ) { - QString af = m_tco->m_sampleBuffer->openAudioFile(); + QString af = m_clip->m_sampleBuffer->openAudioFile(); if ( af.isEmpty() ) {} //Don't do anything if no file is loaded - else if ( af == m_tco->m_sampleBuffer->audioFile() ) + else if ( af == m_clip->m_sampleBuffer->audioFile() ) { //Instead of reloading the existing file, just reset the size - int length = (int) ( m_tco->m_sampleBuffer->frames() / Engine::framesPerTick() ); - m_tco->changeLength(length); + int length = (int) ( m_clip->m_sampleBuffer->frames() / Engine::framesPerTick() ); + m_clip->changeLength(length); } else { //Otherwise load the new file as ususal - m_tco->setSampleFile( af ); + m_clip->setSampleFile( af ); Engine::getSong()->setModified(); } } @@ -185,7 +184,7 @@ void SampleTCOView::mouseDoubleClickEvent( QMouseEvent * ) -void SampleTCOView::paintEvent( QPaintEvent * pe ) +void SampleClipView::paintEvent( QPaintEvent * pe ) { QPainter painter( this ); @@ -204,7 +203,7 @@ void SampleTCOView::paintEvent( QPaintEvent * pe ) QPainter p( &m_paintPixmap ); - bool muted = m_tco->getTrack()->isMuted() || m_tco->isMuted(); + bool muted = m_clip->getTrack()->isMuted() || m_clip->isMuted(); bool selected = isSelected(); QLinearGradient lingrad(0, 0, 0, height()); @@ -215,7 +214,7 @@ void SampleTCOView::paintEvent( QPaintEvent * pe ) lingrad.setColorAt( 1, c.darker( 300 ) ); lingrad.setColorAt( 0, c ); - // paint a black rectangle under the pattern to prevent glitches with transparent backgrounds + // paint a black rectangle under the clip to prevent glitches with transparent backgrounds p.fillRect( rect(), QColor( 0, 0, 0 ) ); if( gradient() ) @@ -227,13 +226,13 @@ void SampleTCOView::paintEvent( QPaintEvent * pe ) p.fillRect( rect(), c ); } - auto tcoColor = m_tco->hasColor() - ? (m_tco->usesCustomClipColor() - ? m_tco->color() - : m_tco->getTrack()->color()) + auto clipColor = m_clip->hasColor() + ? (m_clip->usesCustomClipColor() + ? m_clip->color() + : m_clip->getTrack()->color()) : painter.pen().brush().color(); - p.setPen(tcoColor); + p.setPen(clipColor); if (muted) { @@ -246,22 +245,22 @@ void SampleTCOView::paintEvent( QPaintEvent * pe ) p.setPen(p.pen().brush().color().darker(150)); } - const int spacing = TCO_BORDER_WIDTH + 1; - const float ppb = fixedTCOs() ? - ( parentWidget()->width() - 2 * TCO_BORDER_WIDTH ) - / (float) m_tco->length().getBar() : + const int spacing = CLIP_BORDER_WIDTH + 1; + const float ppb = fixedClips() ? + ( parentWidget()->width() - 2 * CLIP_BORDER_WIDTH ) + / (float) m_clip->length().getBar() : pixelsPerBar(); float nom = Engine::getSong()->getTimeSigModel().getNumerator(); float den = Engine::getSong()->getTimeSigModel().getDenominator(); float ticksPerBar = DefaultTicksPerBar * nom / den; - float offset = m_tco->startTimeOffset() / ticksPerBar * pixelsPerBar(); + float offset = m_clip->startTimeOffset() / ticksPerBar * pixelsPerBar(); QRect r = QRect( offset, spacing, - qMax( static_cast( m_tco->sampleLength() * ppb / ticksPerBar ), 1 ), rect().bottom() - 2 * spacing ); - m_tco->m_sampleBuffer->visualize( p, r, pe->rect() ); + qMax( static_cast( m_clip->sampleLength() * ppb / ticksPerBar ), 1 ), rect().bottom() - 2 * spacing ); + m_clip->m_sampleBuffer->visualize( p, r, pe->rect() ); - QString name = PathUtil::cleanName(m_tco->m_sampleBuffer->audioFile()); + QString name = PathUtil::cleanName(m_clip->m_sampleBuffer->audioFile()); paintTextLabel(name, p); // disable antialiasing for borders, since its not needed @@ -269,17 +268,17 @@ void SampleTCOView::paintEvent( QPaintEvent * pe ) // inner border p.setPen( c.lighter( 135 ) ); - p.drawRect( 1, 1, rect().right() - TCO_BORDER_WIDTH, - rect().bottom() - TCO_BORDER_WIDTH ); + p.drawRect( 1, 1, rect().right() - CLIP_BORDER_WIDTH, + rect().bottom() - CLIP_BORDER_WIDTH ); // outer border p.setPen( c.darker( 200 ) ); p.drawRect( 0, 0, rect().right(), rect().bottom() ); - // draw the 'muted' pixmap only if the pattern was manualy muted - if( m_tco->isMuted() ) + // draw the 'muted' pixmap only if the clip was manualy muted + if( m_clip->isMuted() ) { - const int spacing = TCO_BORDER_WIDTH; + const int spacing = CLIP_BORDER_WIDTH; const int size = 14; p.drawPixmap( spacing, height() - ( size + spacing ), embed::getIconPixmap( "muted", size, size ) ); @@ -291,7 +290,7 @@ void SampleTCOView::paintEvent( QPaintEvent * pe ) } // recording sample tracks is not possible at the moment - /* if( m_tco->isRecord() ) + /* if( m_clip->isRecord() ) { p.setFont( pointSize<7>( p.font() ) ); @@ -312,9 +311,9 @@ void SampleTCOView::paintEvent( QPaintEvent * pe ) -void SampleTCOView::reverseSample() +void SampleClipView::reverseSample() { - m_tco->sampleBuffer()->setReversed(!m_tco->sampleBuffer()->reversed()); + m_clip->sampleBuffer()->setReversed(!m_clip->sampleBuffer()->reversed()); Engine::getSong()->setModified(); update(); } @@ -322,31 +321,31 @@ void SampleTCOView::reverseSample() -//! Split this TCO. +//! Split this Clip. /*! \param pos the position of the split, relative to the start of the clip */ -bool SampleTCOView::splitTCO( const TimePos pos ) +bool SampleClipView::splitClip( const TimePos pos ) { setMarkerEnabled( false ); - const TimePos splitPos = m_initialTCOPos + pos; + const TimePos splitPos = m_initialClipPos + pos; - //Don't split if we slid off the TCO or if we're on the clip's start/end + //Don't split if we slid off the Clip or if we're on the clip's start/end //Cutting at exactly the start/end position would create a zero length //clip (bad), and a clip the same length as the original one (pointless). - if ( splitPos > m_initialTCOPos && splitPos < m_initialTCOEnd ) + if ( splitPos > m_initialClipPos && splitPos < m_initialClipEnd ) { - m_tco->getTrack()->addJournalCheckPoint(); - m_tco->getTrack()->saveJournallingState( false ); + m_clip->getTrack()->addJournalCheckPoint(); + m_clip->getTrack()->saveJournallingState( false ); - SampleTCO * rightTCO = new SampleTCO ( *m_tco ); + SampleClip * rightClip = new SampleClip ( *m_clip ); - m_tco->changeLength( splitPos - m_initialTCOPos ); + m_clip->changeLength( splitPos - m_initialClipPos ); - rightTCO->movePosition( splitPos ); - rightTCO->changeLength( m_initialTCOEnd - splitPos ); - rightTCO->setStartTimeOffset( m_tco->startTimeOffset() - m_tco->length() ); + rightClip->movePosition( splitPos ); + rightClip->changeLength( m_initialClipEnd - splitPos ); + rightClip->setStartTimeOffset( m_clip->startTimeOffset() - m_clip->length() ); - m_tco->getTrack()->restoreJournallingState(); + m_clip->getTrack()->restoreJournallingState(); return true; } else { return false; } diff --git a/src/gui/SampleTrackView.cpp b/src/gui/SampleTrackView.cpp index 068200a35fe..afa714518b3 100644 --- a/src/gui/SampleTrackView.cpp +++ b/src/gui/SampleTrackView.cpp @@ -193,14 +193,14 @@ void SampleTrackView::dropEvent(QDropEvent *de) ? trackHeadWidth : de->pos().x(); - TimePos tcoPos = trackContainerView()->fixedTCOs() + TimePos clipPos = trackContainerView()->fixedClips() ? TimePos(0) : TimePos(((xPos - trackHeadWidth) / trackContainerView()->pixelsPerBar() * TimePos::ticksPerBar()) + trackContainerView()->currentPosition() ).quantize(1.0); - SampleTCO * sTco = static_cast(getTrack()->createTCO(tcoPos)); - if (sTco) { sTco->setSampleFile(value); } + SampleClip * sClip = static_cast(getTrack()->createClip(clipPos)); + if (sClip) { sClip->setSampleFile(value); } } } diff --git a/src/gui/TimeLineWidget.cpp b/src/gui/TimeLineWidget.cpp index dc6537ab7ec..cf7cbd82646 100644 --- a/src/gui/TimeLineWidget.cpp +++ b/src/gui/TimeLineWidget.cpp @@ -330,7 +330,7 @@ void TimeLineWidget::mousePressEvent( QMouseEvent* event ) } else if( event->button() == Qt::LeftButton && (event->modifiers() & Qt::ShiftModifier) ) { - m_action = SelectSongTCO; + m_action = SelectSongClip; m_initalXSelect = event->x(); } else if( event->button() == Qt::RightButton ) @@ -422,7 +422,7 @@ void TimeLineWidget::mouseMoveEvent( QMouseEvent* event ) update(); break; } - case SelectSongTCO: + case SelectSongClip: emit regionSelectedFromPixels( m_initalXSelect , event->x() ); break; @@ -438,6 +438,6 @@ void TimeLineWidget::mouseReleaseEvent( QMouseEvent* event ) { delete m_hint; m_hint = nullptr; - if ( m_action == SelectSongTCO ) { emit selectionFinished(); } + if ( m_action == SelectSongClip ) { emit selectionFinished(); } m_action = NoAction; } diff --git a/src/gui/TrackView.cpp b/src/gui/TrackView.cpp index 648f1f11a94..ba5c17b7adb 100644 --- a/src/gui/TrackView.cpp +++ b/src/gui/TrackView.cpp @@ -44,7 +44,7 @@ #include "ToolTip.h" #include "Track.h" #include "TrackContainerView.h" -#include "TrackContentObjectView.h" +#include "ClipView.h" /*! \brief Create a new track View. @@ -89,8 +89,8 @@ TrackView::TrackView( Track * track, TrackContainerView * tcv ) : connect( m_track, SIGNAL( destroyedTrack() ), this, SLOT( close() ) ); connect( m_track, - SIGNAL( trackContentObjectAdded( TrackContentObject * ) ), - this, SLOT( createTCOView( TrackContentObject * ) ), + SIGNAL( clipAdded( Clip * ) ), + this, SLOT( createClipView( Clip * ) ), Qt::QueuedConnection ); connect( &m_track->m_mutedModel, SIGNAL( dataChanged() ), @@ -102,12 +102,10 @@ TrackView::TrackView( Track * track, TrackContainerView * tcv ) : connect( &m_track->m_soloModel, SIGNAL( dataChanged() ), m_track, SLOT( toggleSolo() ), Qt::DirectConnection ); - // create views for already existing TCOs - for( Track::tcoVector::iterator it = - m_track->m_trackContentObjects.begin(); - it != m_track->m_trackContentObjects.end(); ++it ) + // create views for already existing clips + for( Track::clipVector::iterator it = m_track->m_clips.begin(); it != m_track->m_clips.end(); ++it ) { - createTCOView( *it ); + createClipView( *it ); } m_trackContainerView->addTrackView( this ); @@ -155,7 +153,7 @@ void TrackView::resizeEvent( QResizeEvent * re ) void TrackView::update() { m_trackContentWidget.update(); - if( !m_trackContainerView->fixedTCOs() ) + if( !m_trackContainerView->fixedClips() ) { m_trackContentWidget.changePosition(); } @@ -418,19 +416,19 @@ void TrackView::paintEvent( QPaintEvent * pe ) -/*! \brief Create a TrackContentObject View in this track View. +/*! \brief Create a Clip View in this track View. * - * \param tco the TrackContentObject to create the view for. + * \param clip the Clip to create the view for. * \todo is this a good description for what this method does? */ -void TrackView::createTCOView( TrackContentObject * tco ) +void TrackView::createClipView( Clip * clip ) { - TrackContentObjectView * tv = tco->createView( this ); - if( tco->getSelectViewOnCreate() == true ) + ClipView * tv = clip->createView( this ); + if( clip->getSelectViewOnCreate() == true ) { tv->setSelected( true ); } - tco->selectViewOnCreate( false ); + clip->selectViewOnCreate( false ); } diff --git a/src/gui/editors/AutomationEditor.cpp b/src/gui/editors/AutomationEditor.cpp index 5bdd92b49f4..ce32d6b25ac 100644 --- a/src/gui/editors/AutomationEditor.cpp +++ b/src/gui/editors/AutomationEditor.cpp @@ -81,7 +81,7 @@ AutomationEditor::AutomationEditor() : m_zoomingXModel(), m_zoomingYModel(), m_quantizeModel(), - m_pattern(nullptr), + m_clip(nullptr), m_minLevel( 0 ), m_maxLevel( 0 ), m_step( 1 ), @@ -109,8 +109,8 @@ AutomationEditor::AutomationEditor() : m_crossColor(0, 0, 0), m_backgroundShade(0, 0, 0) { - connect( this, SIGNAL( currentPatternChanged() ), - this, SLOT( updateAfterPatternChange() ), + connect( this, SIGNAL( currentClipChanged() ), + this, SLOT( updateAfterClipChange() ), Qt::QueuedConnection ); connect( Engine::getSong(), SIGNAL( timeSignatureChanged( int, int ) ), this, SLOT( update() ) ); @@ -146,9 +146,9 @@ AutomationEditor::AutomationEditor() : // add time-line m_timeLine = new TimeLineWidget( VALUES_WIDTH, 0, m_ppb, Engine::getSong()->getPlayPos( - Song::Mode_PlayAutomationPattern ), + Song::Mode_PlayAutomationClip ), m_currentPosition, - Song::Mode_PlayAutomationPattern, this ); + Song::Mode_PlayAutomationClip, this ); connect( this, SIGNAL( positionChanged( const TimePos & ) ), m_timeLine, SLOT( updatePosition( const TimePos & ) ) ); connect( m_timeLine, SIGNAL( positionChanged( const TimePos & ) ), @@ -184,7 +184,7 @@ AutomationEditor::AutomationEditor() : s_toolMove = new QPixmap(embed::getIconPixmap("edit_move")); } - setCurrentPattern(nullptr); + setCurrentClip(nullptr); setMouseTracking( true ); setFocusPolicy( Qt::StrongFocus ); @@ -207,21 +207,21 @@ AutomationEditor::~AutomationEditor() -void AutomationEditor::setCurrentPattern(AutomationPattern * new_pattern ) +void AutomationEditor::setCurrentClip(AutomationClip * new_clip ) { - if (m_pattern) + if (m_clip) { - m_pattern->disconnect(this); + m_clip->disconnect(this); } - m_pattern = new_pattern; + m_clip = new_clip; - if (m_pattern != nullptr) + if (m_clip != nullptr) { - connect(m_pattern, SIGNAL(dataChanged()), this, SLOT(update())); + connect(m_clip, SIGNAL(dataChanged()), this, SLOT(update())); } - emit currentPatternChanged(); + emit currentClipChanged(); } @@ -243,11 +243,11 @@ void AutomationEditor::loadSettings( const QDomElement & dom_parent) -void AutomationEditor::updateAfterPatternChange() +void AutomationEditor::updateAfterClipChange() { m_currentPosition = 0; - if( !validPattern() ) + if( !validClip() ) { m_minLevel = m_maxLevel = m_scrollLevel = 0; m_step = 1; @@ -255,12 +255,12 @@ void AutomationEditor::updateAfterPatternChange() return; } - m_minLevel = m_pattern->firstObject()->minValue(); - m_maxLevel = m_pattern->firstObject()->maxValue(); - m_step = m_pattern->firstObject()->step(); + m_minLevel = m_clip->firstObject()->minValue(); + m_maxLevel = m_clip->firstObject()->maxValue(); + m_step = m_clip->firstObject()->step(); centerTopBottomScroll(); - m_tensionModel->setValue( m_pattern->getTension() ); + m_tensionModel->setValue( m_clip->getTension() ); // resizeEvent() does the rest for us (scrolling, range-checking // of levels and so on...) @@ -277,7 +277,7 @@ void AutomationEditor::update() QWidget::update(); // Note detuning? - if( m_pattern && !m_pattern->getTrack() ) + if( m_clip && !m_clip->getTrack() ) { getGUI()->pianoRoll()->update(); } @@ -344,8 +344,8 @@ void AutomationEditor::leaveEvent(QEvent * e ) void AutomationEditor::drawLine( int x0In, float y0, int x1In, float y1 ) { - int x0 = Note::quantized( x0In, AutomationPattern::quantization() ); - int x1 = Note::quantized( x1In, AutomationPattern::quantization() ); + int x0 = Note::quantized( x0In, AutomationClip::quantization() ); + int x1 = Note::quantized( x1In, AutomationClip::quantization() ); int deltax = qAbs( x1 - x0 ); float deltay = qAbs( y1 - y0 ); int x = x0; @@ -353,22 +353,22 @@ void AutomationEditor::drawLine( int x0In, float y0, int x1In, float y1 ) int xstep; int ystep; - if( deltax < AutomationPattern::quantization() ) + if( deltax < AutomationClip::quantization() ) { return; } - deltax /= AutomationPattern::quantization(); + deltax /= AutomationClip::quantization(); float yscale = deltay / ( deltax ); if( x0 < x1 ) { - xstep = AutomationPattern::quantization(); + xstep = AutomationClip::quantization(); } else { - xstep = -( AutomationPattern::quantization() ); + xstep = -( AutomationClip::quantization() ); } float lineAdjust; @@ -390,8 +390,8 @@ void AutomationEditor::drawLine( int x0In, float y0, int x1In, float y1 ) x += xstep; i += 1; - m_pattern->removeNode(TimePos(x)); - m_pattern->putValue( TimePos( x ), y ); + m_clip->removeNode(TimePos(x)); + m_clip->putValue( TimePos( x ), y ); } } @@ -400,7 +400,7 @@ void AutomationEditor::drawLine( int x0In, float y0, int x1In, float y1 ) bool AutomationEditor::fineTuneValue(timeMap::iterator node, bool editingOutValue) { - if (node == m_pattern->getTimeMap().end()) { return false; } + if (node == m_clip->getTimeMap().end()) { return false; } // Display dialog to edit the value bool ok; @@ -413,8 +413,8 @@ bool AutomationEditor::fineTuneValue(timeMap::iterator node, bool editingOutValu editingOutValue ? OUTVAL(node) : INVAL(node), - m_pattern->firstObject()->minValue(), - m_pattern->firstObject()->maxValue(), + m_clip->firstObject()->minValue(), + m_clip->firstObject()->maxValue(), 3, &ok ); @@ -447,7 +447,7 @@ bool AutomationEditor::fineTuneValue(timeMap::iterator node, bool editingOutValu void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) { - if( !validPattern() ) + if( !validClip() ) { return; } @@ -455,15 +455,15 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) // Some helper lambda functions to avoid repetition of code auto eraseNode = [this](timeMap::iterator node) { - if (node != m_pattern->getTimeMap().end()) + if (node != m_clip->getTimeMap().end()) { - m_pattern->removeNode(POS(node)); + m_clip->removeNode(POS(node)); Engine::getSong()->setModified(); } }; auto resetNode = [this](timeMap::iterator node) { - if (node != m_pattern->getTimeMap().end()) + if (node != m_clip->getTimeMap().end()) { node.value().resetOutValue(); Engine::getSong()->setModified(); @@ -481,8 +481,8 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) // Get tick in which the user clicked int posTicks = (x * TimePos::ticksPerBar() / m_ppb) + m_currentPosition; - // Get the time map of current pattern - timeMap & tm = m_pattern->getTimeMap(); + // Get the time map of current clip + timeMap & tm = m_clip->getTimeMap(); m_mouseDownLeft = (mouseEvent->button() == Qt::LeftButton); m_mouseDownRight = (mouseEvent->button() == Qt::RightButton); @@ -501,7 +501,7 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) { case DRAW: { - m_pattern->addJournalCheckPoint(); + m_clip->addJournalCheckPoint(); if (m_mouseDownLeft) { @@ -522,7 +522,7 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) else // No shift, we are just creating/moving nodes { // Starts actually moving/draging the node - TimePos newTime = m_pattern->setDragValue( + TimePos newTime = m_clip->setDragValue( // The TimePos of either the clicked node or a new one TimePos( clickedNode == tm.end() @@ -573,7 +573,7 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) } case ERASE: { - m_pattern->addJournalCheckPoint(); + m_clip->addJournalCheckPoint(); // On erase mode, left click removes nodes if (m_mouseDownLeft) @@ -602,7 +602,7 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) } case DRAW_OUTVALUES: { - m_pattern->addJournalCheckPoint(); + m_clip->addJournalCheckPoint(); // On this mode, left click sets the outValue if (m_mouseDownLeft) @@ -624,7 +624,7 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) // node and set its outValue TimePos quantizedPos = Note::quantized( TimePos(posTicks), - m_pattern->quantization() + m_clip->quantization() ); clickedNode = tm.find(quantizedPos); @@ -664,7 +664,7 @@ void AutomationEditor::mousePressEvent( QMouseEvent* mouseEvent ) void AutomationEditor::mouseDoubleClickEvent(QMouseEvent * mouseEvent) { - if (!validPattern()) { return; } + if (!validClip()) { return; } // If we double clicked outside the AutomationEditor viewport return if (mouseEvent->y() <= TOP_MARGIN || mouseEvent->x() < VALUES_WIDTH) { return; } @@ -707,7 +707,7 @@ void AutomationEditor::mouseReleaseEvent(QMouseEvent * mouseEvent ) if (m_action == MOVE_VALUE) { // Actually apply the value of the node being dragged - m_pattern->applyDragValue(); + m_clip->applyDragValue(); } QApplication::restoreOverrideCursor(); @@ -723,7 +723,7 @@ void AutomationEditor::mouseReleaseEvent(QMouseEvent * mouseEvent ) void AutomationEditor::mouseMoveEvent(QMouseEvent * mouseEvent ) { - if( !validPattern() ) + if( !validClip() ) { update(); return; @@ -760,7 +760,7 @@ void AutomationEditor::mouseMoveEvent(QMouseEvent * mouseEvent ) m_drawLastLevel = level; // Updates the drag value of the moved node - m_pattern->setDragValue( + m_clip->setDragValue( TimePos(posTicks), level, true, @@ -786,7 +786,7 @@ void AutomationEditor::mouseMoveEvent(QMouseEvent * mouseEvent ) // Removing automation nodes // Removes all values from the last clicked tick up to the current position tick - m_pattern->removeNodes(m_drawLastTick, posTicks); + m_clip->removeNodes(m_drawLastTick, posTicks); Engine::getSong()->setModified(); } @@ -806,7 +806,7 @@ void AutomationEditor::mouseMoveEvent(QMouseEvent * mouseEvent ) // Removing automation nodes // Removes all values from the last clicked tick up to the current position tick - m_pattern->removeNodes(m_drawLastTick, posTicks); + m_clip->removeNodes(m_drawLastTick, posTicks); Engine::getSong()->setModified(); } @@ -818,7 +818,7 @@ void AutomationEditor::mouseMoveEvent(QMouseEvent * mouseEvent ) // Reseting outValues // Resets all values from the last clicked tick up to the current position tick - m_pattern->resetNodes(m_drawLastTick, posTicks); + m_clip->resetNodes(m_drawLastTick, posTicks); Engine::getSong()->setModified(); } @@ -836,7 +836,7 @@ void AutomationEditor::mouseMoveEvent(QMouseEvent * mouseEvent ) if (m_action == MOVE_OUTVALUE) { // We are moving the outValue of the node - timeMap & tm = m_pattern->getTimeMap(); + timeMap & tm = m_clip->getTimeMap(); timeMap::iterator it = tm.find(m_draggedOutValueKey); // Safety check @@ -854,7 +854,7 @@ void AutomationEditor::mouseMoveEvent(QMouseEvent * mouseEvent ) // Reseting outValues // Resets all values from the last clicked tick up to the current position tick - m_pattern->resetNodes(m_drawLastTick, posTicks); + m_clip->resetNodes(m_drawLastTick, posTicks); Engine::getSong()->setModified(); } @@ -894,7 +894,7 @@ inline void AutomationEditor::drawCross( QPainter & p ) tt_pos.ry() -= 51; tt_pos.rx() += 26; - float scaledLevel = m_pattern->firstObject()->scaledValue( level ); + float scaledLevel = m_clip->firstObject()->scaledValue( level ); // Limit the scaled-level tooltip to the grid if( mouse_pos.x() >= 0 && @@ -913,12 +913,12 @@ inline void AutomationEditor::drawAutomationPoint(QPainter & p, timeMap::iterato { int x = xCoordOfTick(POS(it)); int y; - // Below (m_ppb * AutomationPattern::quantization() / 576) is used because: + // Below (m_ppb * AutomationClip::quantization() / 576) is used because: // 1 bar equals to 192/quantization() notes. Hence, to calculate the number of pixels // per note we would have (m_ppb * 1 bar / (192/quantization()) notes per bar), or // (m_ppb * quantization / 192). If we want 1/3 of the number of pixels per note we // get (m_ppb * quantization() / 192*3) or (m_ppb * quantization() / 576) - const int outerRadius = qBound(3, (m_ppb * AutomationPattern::quantization()) / 576, 5); + const int outerRadius = qBound(3, (m_ppb * AutomationClip::quantization()) / 576, 5); // Draw a circle for the outValue y = yCoordOfLevel(OUTVAL(it)); @@ -964,7 +964,7 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) Qt::Alignment text_flags = (Qt::Alignment)( Qt::AlignRight | Qt::AlignVCenter ); - if( validPattern() ) + if( validClip() ) { if( m_y_auto ) { @@ -972,7 +972,7 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) float level[] = { m_minLevel, m_maxLevel }; for( int i = 0; i < 2; ++i ) { - const QString & label = m_pattern->firstObject() + const QString & label = m_clip->firstObject() ->displayValue( level[i] ); p.setPen( QApplication::palette().color( QPalette::Active, QPalette::Shadow ) ); @@ -1000,7 +1000,7 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) } for( ; level <= m_topLevel; level += printable ) { - const QString & label = m_pattern->firstObject() + const QString & label = m_clip->firstObject() ->displayValue( level ); y = yCoordOfLevel( level ); p.setPen( QApplication::palette().color( QPalette::Active, @@ -1023,7 +1023,7 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) // draw vertical raster - if( m_pattern ) + if( m_clip ) { int tick, x, q; int x_line_end = (int)( m_y_auto || m_topLevel < m_maxLevel ? @@ -1033,17 +1033,17 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) if( m_zoomingXModel.value() > 3 ) { // If we're over 100% zoom, we allow all quantization level grids - q = AutomationPattern::quantization(); + q = AutomationClip::quantization(); } - else if( AutomationPattern::quantization() % 3 != 0 ) + else if( AutomationClip::quantization() % 3 != 0 ) { // If we're under 100% zoom, we allow quantization grid up to 1/24 for triplets // to ensure a dense doesn't fill out the background - q = AutomationPattern::quantization() < 8 ? 8 : AutomationPattern::quantization(); + q = AutomationClip::quantization() < 8 ? 8 : AutomationClip::quantization(); } else { // If we're under 100% zoom, we allow quantization grid up to 1/32 for normal notes - q = AutomationPattern::quantization() < 6 ? 6 : AutomationPattern::quantization(); + q = AutomationClip::quantization() < 6 ? 6 : AutomationClip::quantization(); } // 3 independent loops, because quantization might not divide evenly into @@ -1136,11 +1136,11 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) // following code draws all visible values - if( validPattern() ) + if( validClip() ) { //NEEDS Change in CSS //int len_ticks = 4; - timeMap & time_map = m_pattern->getTimeMap(); + timeMap & time_map = m_clip->getTimeMap(); //Don't bother doing/rendering anything if there is no automation points if( time_map.size() > 0 ) @@ -1163,7 +1163,7 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) break; } - float *values = m_pattern->valuesAfter(POS(it)); + float *values = m_clip->valuesAfter(POS(it)); // We are creating a path to draw a polygon representing the values between two // nodes. When we have two nodes with discrete progression, we will basically have @@ -1172,7 +1172,7 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) // the value of the end of the shape between the two nodes will be the inValue of // the next node. float nextValue; - if( m_pattern->progressionType() == AutomationPattern::DiscreteProgression ) + if( m_clip->progressionType() == AutomationClip::DiscreteProgression ) { nextValue = OUTVAL(it); } @@ -1225,12 +1225,12 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) p.drawText( VALUES_WIDTH + 20, TOP_MARGIN + 40, width() - VALUES_WIDTH - 20 - SCROLLBAR_SIZE, grid_height - 40, Qt::TextWordWrap, - tr( "Please open an automation pattern with " + tr( "Please open an automation clip with " "the context menu of a control!" ) ); } // TODO: Get this out of paint event - int l = validPattern() ? (int) m_pattern->length() : 0; + int l = validClip() ? (int) m_clip->length() : 0; // reset scroll-range if( m_leftRightScroll->maximum() != l ) @@ -1239,7 +1239,7 @@ void AutomationEditor::paintEvent(QPaintEvent * pe ) m_leftRightScroll->setPageStep( l ); } - if(validPattern() && GuiApplication::instance()->automationEditor()->m_editor->hasFocus()) + if(validClip() && GuiApplication::instance()->automationEditor()->m_editor->hasFocus()) { drawCross( p ); } @@ -1351,17 +1351,17 @@ void AutomationEditor::centerTopBottomScroll() { // default to the m_scrollLevel position int pos = static_cast(m_scrollLevel); - // If a pattern exists... - if (m_pattern) + // If a clip exists... + if (m_clip) { - // get time map of current pattern - timeMap & time_map = m_pattern->getTimeMap(); + // get time map of current clip + timeMap & time_map = m_clip->getTimeMap(); // If time_map is not empty... if (!time_map.empty()) { // set the position to the inverted value ((max + min) - value) - // If we set just (max - value), we're off by m_pattern's minimum - pos = m_pattern->getMax() + m_pattern->getMin() - static_cast(INVAL(time_map.begin())); + // If we set just (max - value), we're off by m_clip's minimum + pos = m_clip->getMax() + m_clip->getMin() - static_cast(INVAL(time_map.begin())); } } m_topBottomScroll->setValue(pos); @@ -1400,7 +1400,7 @@ void AutomationEditor::resizeEvent(QResizeEvent * re) if( Engine::getSong() ) { - Engine::getSong()->getPlayPos( Song::Mode_PlayAutomationPattern + Engine::getSong()->getPlayPos( Song::Mode_PlayAutomationClip ).m_timeLine->setFixedWidth( width() ); } @@ -1510,8 +1510,8 @@ float AutomationEditor::getLevel(int y ) inline bool AutomationEditor::inBBEditor() { - return( validPattern() && - m_pattern->getTrack()->trackContainer() == Engine::getBBTrackContainer() ); + return( validClip() && + m_clip->getTrack()->trackContainer() == Engine::getBBTrackContainer() ); } @@ -1519,17 +1519,17 @@ inline bool AutomationEditor::inBBEditor() void AutomationEditor::play() { - if( !validPattern() ) + if( !validClip() ) { return; } - if( !m_pattern->getTrack() ) + if( !m_clip->getTrack() ) { - if( Engine::getSong()->playMode() != Song::Mode_PlayPattern ) + if( Engine::getSong()->playMode() != Song::Mode_PlayMidiClip ) { Engine::getSong()->stop(); - Engine::getSong()->playPattern( getGUI()->pianoRoll()->currentPattern() ); + Engine::getSong()->playMidiClip( getGUI()->pianoRoll()->currentMidiClip() ); } else if( Engine::getSong()->isStopped() == false ) { @@ -1537,7 +1537,7 @@ void AutomationEditor::play() } else { - Engine::getSong()->playPattern( getGUI()->pianoRoll()->currentPattern() ); + Engine::getSong()->playMidiClip( getGUI()->pianoRoll()->currentMidiClip() ); } } else if( inBBEditor() ) @@ -1562,11 +1562,11 @@ void AutomationEditor::play() void AutomationEditor::stop() { - if( !validPattern() ) + if( !validClip() ) { return; } - if( m_pattern->getTrack() && inBBEditor() ) + if( m_clip->getTrack() && inBBEditor() ) { Engine::getBBTrackContainer()->stop(); } @@ -1621,12 +1621,12 @@ void AutomationEditor::setEditMode(int mode) -void AutomationEditor::setProgressionType(AutomationPattern::ProgressionTypes type) +void AutomationEditor::setProgressionType(AutomationClip::ProgressionTypes type) { - if (validPattern()) + if (validClip()) { - m_pattern->addJournalCheckPoint(); - m_pattern->setProgressionType(type); + m_clip->addJournalCheckPoint(); + m_clip->setProgressionType(type); Engine::getSong()->setModified(); update(); } @@ -1634,7 +1634,7 @@ void AutomationEditor::setProgressionType(AutomationPattern::ProgressionTypes ty void AutomationEditor::setProgressionType(int type) { - setProgressionType((AutomationPattern::ProgressionTypes) type); + setProgressionType((AutomationClip::ProgressionTypes) type); } @@ -1642,9 +1642,9 @@ void AutomationEditor::setProgressionType(int type) void AutomationEditor::setTension() { - if ( m_pattern ) + if ( m_clip ) { - m_pattern->setTension( QString::number( m_tensionModel->value() ) ); + m_clip->setTension( QString::number( m_tensionModel->value() ) ); update(); } } @@ -1656,7 +1656,7 @@ void AutomationEditor::updatePosition(const TimePos & t ) { if( ( Engine::getSong()->isPlaying() && Engine::getSong()->playMode() == - Song::Mode_PlayAutomationPattern ) || + Song::Mode_PlayAutomationClip ) || m_scrollBack == true ) { const int w = width() - VALUES_WIDTH; @@ -1712,7 +1712,7 @@ void AutomationEditor::zoomingYChanged() void AutomationEditor::setQuantization() { - AutomationPattern::setQuantization(DefaultTicksPerBar / Quantizations[m_quantizeModel.value()]); + AutomationClip::setQuantization(DefaultTicksPerBar / Quantizations[m_quantizeModel.value()]); update(); } @@ -1786,8 +1786,8 @@ AutomationEditor::timeMap::iterator AutomationEditor::getNodeAt(int x, int y, bo // Convert the x position to the position in ticks int posTicks = (x * TimePos::ticksPerBar() / m_ppb) + m_currentPosition; - // Get our pattern timeMap and create a iterator so we can check the nodes - timeMap & tm = m_pattern->getTimeMap(); + // Get our clip timeMap and create a iterator so we can check the nodes + timeMap & tm = m_clip->getTimeMap(); timeMap::iterator it = tm.begin(); // ticksOffset is the number of ticks that match "r" pixels @@ -1832,9 +1832,9 @@ AutomationEditorWindow::AutomationEditorWindow() : // Play/stop buttons - m_playAction->setToolTip(tr( "Play/pause current pattern (Space)" )); + m_playAction->setToolTip(tr( "Play/pause current clip (Space)" )); - m_stopAction->setToolTip(tr("Stop playing of current pattern (Space)")); + m_stopAction->setToolTip(tr("Stop playing of current clip (Space)")); // Edit mode buttons DropToolBar *editActionsToolBar = addDropToolBarToTop(tr("Edit actions")); @@ -1972,62 +1972,62 @@ AutomationEditorWindow::~AutomationEditorWindow() } -void AutomationEditorWindow::setCurrentPattern(AutomationPattern* pattern) +void AutomationEditorWindow::setCurrentClip(AutomationClip* clip) { - // Disconnect our old pattern - if (currentPattern() != nullptr) + // Disconnect our old clip + if (currentClip() != nullptr) { - m_editor->m_pattern->disconnect(this); + m_editor->m_clip->disconnect(this); m_flipXAction->disconnect(); m_flipYAction->disconnect(); } - m_editor->setCurrentPattern(pattern); + m_editor->setCurrentClip(clip); // Set our window's title - if (pattern == nullptr) + if (clip == nullptr) { - setWindowTitle( tr( "Automation Editor - no pattern" ) ); + setWindowTitle( tr( "Automation Editor - no clip" ) ); return; } - setWindowTitle( tr( "Automation Editor - %1" ).arg( m_editor->m_pattern->name() ) ); + setWindowTitle( tr( "Automation Editor - %1" ).arg( m_editor->m_clip->name() ) ); - switch(m_editor->m_pattern->progressionType()) + switch(m_editor->m_clip->progressionType()) { - case AutomationPattern::DiscreteProgression: + case AutomationClip::DiscreteProgression: m_discreteAction->setChecked(true); m_tensionKnob->setEnabled(false); break; - case AutomationPattern::LinearProgression: + case AutomationClip::LinearProgression: m_linearAction->setChecked(true); m_tensionKnob->setEnabled(false); break; - case AutomationPattern::CubicHermiteProgression: + case AutomationClip::CubicHermiteProgression: m_cubicHermiteAction->setChecked(true); m_tensionKnob->setEnabled(true); break; } - // Connect new pattern - if (pattern) + // Connect new clip + if (clip) { - connect(pattern, SIGNAL(dataChanged()), this, SLOT(update())); - connect( pattern, SIGNAL( dataChanged() ), this, SLOT( updateWindowTitle() ) ); - connect(pattern, SIGNAL(destroyed()), this, SLOT(clearCurrentPattern())); + connect(clip, SIGNAL(dataChanged()), this, SLOT(update())); + connect( clip, SIGNAL( dataChanged() ), this, SLOT( updateWindowTitle() ) ); + connect(clip, SIGNAL(destroyed()), this, SLOT(clearCurrentClip())); - connect(m_flipXAction, SIGNAL(triggered()), pattern, SLOT(flipX())); - connect(m_flipYAction, SIGNAL(triggered()), pattern, SLOT(flipY())); + connect(m_flipXAction, SIGNAL(triggered()), clip, SLOT(flipX())); + connect(m_flipYAction, SIGNAL(triggered()), clip, SLOT(flipY())); } - emit currentPatternChanged(); + emit currentClipChanged(); } -const AutomationPattern* AutomationEditorWindow::currentPattern() +const AutomationClip* AutomationEditorWindow::currentClip() { - return m_editor->currentPattern(); + return m_editor->currentClip(); } void AutomationEditorWindow::dropEvent( QDropEvent *_de ) @@ -2041,16 +2041,16 @@ void AutomationEditorWindow::dropEvent( QDropEvent *_de ) journallingObject( val.toInt() ) ); if (mod != nullptr) { - bool added = m_editor->m_pattern->addObject( mod ); + bool added = m_editor->m_clip->addObject( mod ); if ( !added ) { TextFloat::displayMessage( mod->displayName(), tr( "Model is already connected " - "to this pattern." ), + "to this clip." ), embed::getIconPixmap( "automation" ), 2000 ); } - setCurrentPattern( m_editor->m_pattern ); + setCurrentClip( m_editor->m_clip ); } } @@ -2059,15 +2059,15 @@ void AutomationEditorWindow::dropEvent( QDropEvent *_de ) void AutomationEditorWindow::dragEnterEvent( QDragEnterEvent *_dee ) { - if (! m_editor->validPattern() ) { + if (! m_editor->validClip() ) { return; } StringPairDrag::processDragEnterEvent( _dee, "automatable_model" ); } -void AutomationEditorWindow::open(AutomationPattern* pattern) +void AutomationEditorWindow::open(AutomationClip* clip) { - setCurrentPattern(pattern); + setCurrentClip(clip); parentWidget()->show(); show(); setFocus(); @@ -2078,10 +2078,10 @@ QSize AutomationEditorWindow::sizeHint() const return {INITIAL_WIDTH, INITIAL_HEIGHT}; } -void AutomationEditorWindow::clearCurrentPattern() +void AutomationEditorWindow::clearCurrentClip() { - m_editor->m_pattern = nullptr; - setCurrentPattern(nullptr); + m_editor->m_clip = nullptr; + setCurrentClip(nullptr); } void AutomationEditorWindow::focusInEvent(QFocusEvent * event) @@ -2102,11 +2102,11 @@ void AutomationEditorWindow::stop() void AutomationEditorWindow::updateWindowTitle() { - if (m_editor->m_pattern == nullptr) + if (m_editor->m_clip == nullptr) { - setWindowTitle( tr( "Automation Editor - no pattern" ) ); + setWindowTitle( tr( "Automation Editor - no clip" ) ); return; } - setWindowTitle( tr( "Automation Editor - %1" ).arg( m_editor->m_pattern->name() ) ); + setWindowTitle( tr( "Automation Editor - %1" ).arg( m_editor->m_clip->name() ) ); } diff --git a/src/gui/editors/BBEditor.cpp b/src/gui/editors/BBEditor.cpp index 0cb8980281e..361917b5f89 100644 --- a/src/gui/editors/BBEditor.cpp +++ b/src/gui/editors/BBEditor.cpp @@ -37,7 +37,7 @@ #include "Song.h" #include "StringPairDrag.h" -#include "Pattern.h" +#include "MidiClip.h" @@ -59,12 +59,12 @@ BBEditor::BBEditor( BBTrackContainer* tc ) : "compacttrackbuttons" ).toInt() ) { setMinimumWidth( TRACK_OP_WIDTH_COMPACT + DEFAULT_SETTINGS_WIDGET_WIDTH_COMPACT - + 2 * TCO_BORDER_WIDTH + 384 ); + + 2 * CLIP_BORDER_WIDTH + 384 ); } else { setMinimumWidth( TRACK_OP_WIDTH + DEFAULT_SETTINGS_WIDGET_WIDTH - + 2 * TCO_BORDER_WIDTH + 384 ); + + 2 * CLIP_BORDER_WIDTH + 384 ); } @@ -88,8 +88,8 @@ BBEditor::BBEditor( BBTrackContainer* tc ) : trackAndStepActionsToolBar->addAction(embed::getIconPixmap("add_bb_track"), tr("Add beat/bassline"), Engine::getSong(), SLOT(addBBTrack())); - trackAndStepActionsToolBar->addAction(embed::getIconPixmap("clone_bb_track_pattern"), tr("Clone beat/bassline pattern"), - m_trackContainerView, SLOT(clonePattern())); + trackAndStepActionsToolBar->addAction(embed::getIconPixmap("clone_bb_track_clip"), tr("Clone beat/bassline clip"), + m_trackContainerView, SLOT(cloneClip())); trackAndStepActionsToolBar->addAction( embed::getIconPixmap("add_sample_track"), tr("Add sample-track"), m_trackContainerView, @@ -196,7 +196,7 @@ void BBTrackContainerView::removeSteps() { if( ( *it )->type() == Track::InstrumentTrack ) { - Pattern* p = static_cast( ( *it )->getTCO( m_bbtc->currentBB() ) ); + MidiClip* p = static_cast( ( *it )->getClip( m_bbtc->currentBB() ) ); p->removeSteps(); } } @@ -225,7 +225,7 @@ void BBTrackContainerView::removeBBView(int bb) { for( TrackView* view : trackViews() ) { - view->getTrackContentWidget()->removeTCOView( bb ); + view->getTrackContentWidget()->removeClipView( bb ); } } @@ -254,24 +254,24 @@ void BBTrackContainerView::dropEvent(QDropEvent* de) DataFile dataFile( value.toUtf8() ); Track * t = Track::create( dataFile.content().firstChild().toElement(), model() ); - // Ensure BB TCOs exist - bool hasValidBBTCOs = false; - if (t->getTCOs().size() == m_bbtc->numOfBBs()) + // Ensure BB Clips exist + bool hasValidBBClips = false; + if (t->getClips().size() == m_bbtc->numOfBBs()) { - hasValidBBTCOs = true; - for (int i = 0; i < t->getTCOs().size(); ++i) + hasValidBBClips = true; + for (int i = 0; i < t->getClips().size(); ++i) { - if (t->getTCOs()[i]->startPosition() != TimePos(i, 0)) + if (t->getClips()[i]->startPosition() != TimePos(i, 0)) { - hasValidBBTCOs = false; + hasValidBBClips = false; break; } } } - if (!hasValidBBTCOs) + if (!hasValidBBClips) { - t->deleteTCOs(); - t->createTCOsForBB(m_bbtc->numOfBBs() - 1); + t->deleteClips(); + t->createClipsForBB(m_bbtc->numOfBBs() - 1); } m_bbtc->updateAfterTrackAdd(); @@ -304,7 +304,7 @@ void BBTrackContainerView::makeSteps( bool clone ) { if( ( *it )->type() == Track::InstrumentTrack ) { - Pattern* p = static_cast( ( *it )->getTCO( m_bbtc->currentBB() ) ); + MidiClip* p = static_cast( ( *it )->getClip( m_bbtc->currentBB() ) ); if( clone ) { p->cloneSteps(); @@ -316,9 +316,9 @@ void BBTrackContainerView::makeSteps( bool clone ) } } -// Creates a clone of the current BB track with the same pattern, but no TCOs in the song editor +// Creates a clone of the current BB track with the same clip, but no Clips in the song editor // TODO: Avoid repeated code from cloneTrack and clearTrack in TrackOperationsWidget somehow -void BBTrackContainerView::clonePattern() +void BBTrackContainerView::cloneClip() { // Get the current BBTrack id BBTrackContainer *bbtc = static_cast(model()); @@ -332,9 +332,9 @@ void BBTrackContainerView::clonePattern() Track *newTrack = bbt->clone(); bbtc->setCurrentBB( static_cast( newTrack )->index() ); - // Track still have the TCOs which is undesirable in this case, clear the track + // Track still have the clips which is undesirable in this case, clear the track newTrack->lock(); - newTrack->deleteTCOs(); + newTrack->deleteClips(); newTrack->unlock(); } } diff --git a/src/gui/editors/PianoRoll.cpp b/src/gui/editors/PianoRoll.cpp index 20926977bc4..2bd5ad10b3b 100644 --- a/src/gui/editors/PianoRoll.cpp +++ b/src/gui/editors/PianoRoll.cpp @@ -63,7 +63,7 @@ #include "gui_templates.h" #include "InstrumentTrack.h" #include "MainWindow.h" -#include "Pattern.h" +#include "MidiClip.h" #include "PianoView.h" #include "SongEditor.h" #include "StepRecorderWidget.h" @@ -74,7 +74,7 @@ using std::move; -typedef AutomationPattern::timeMap timeMap; +typedef AutomationClip::timeMap timeMap; // some constants... @@ -158,7 +158,7 @@ PianoRoll::PianoRoll() : m_noteLenModel(), m_scaleModel(), m_chordModel(), - m_pattern( nullptr ), + m_midiClip( nullptr ), m_currentPosition(), m_recording( false ), m_currentNote( nullptr ), @@ -292,9 +292,9 @@ PianoRoll::PianoRoll() : // add time-line m_timeLine = new TimeLineWidget(m_whiteKeyWidth, 0, m_ppb, Engine::getSong()->getPlayPos( - Song::Mode_PlayPattern ), + Song::Mode_PlayMidiClip ), m_currentPosition, - Song::Mode_PlayPattern, this ); + Song::Mode_PlayMidiClip, this ); connect( this, SIGNAL( positionChanged( const TimePos & ) ), m_timeLine, SLOT( updatePosition( const TimePos & ) ) ); connect( m_timeLine, SIGNAL( positionChanged( const TimePos & ) ), @@ -461,7 +461,7 @@ void PianoRoll::reset() { m_lastNoteVolume = DefaultVolume; m_lastNotePanning = DefaultPanning; - clearGhostPattern(); + clearGhostClip(); } void PianoRoll::showTextFloat(const QString &text, const QPoint &pos, int timeout) @@ -624,18 +624,18 @@ PianoRoll::~PianoRoll() } -void PianoRoll::setGhostPattern( Pattern* newPattern ) +void PianoRoll::setGhostMidiClip( MidiClip* newMidiClip ) { - // Expects a pointer to a pattern or nullptr. + // Expects a pointer to a MIDI clip or nullptr. m_ghostNotes.clear(); - if( newPattern != nullptr ) + if( newMidiClip != nullptr ) { - for( Note *note : newPattern->notes() ) + for( Note *note : newMidiClip->notes() ) { Note * new_note = new Note( note->length(), note->pos(), note->key() ); m_ghostNotes.push_back( new_note ); } - emit ghostPatternSet( true ); + emit ghostClipSet( true ); } } @@ -654,22 +654,22 @@ void PianoRoll::loadGhostNotes( const QDomElement & de ) m_ghostNotes.push_back( n ); node = node.nextSibling(); } - emit ghostPatternSet( true ); + emit ghostClipSet( true ); } } -void PianoRoll::clearGhostPattern() +void PianoRoll::clearGhostClip() { - setGhostPattern( nullptr ); - emit ghostPatternSet( false ); + setGhostMidiClip( nullptr ); + emit ghostClipSet( false ); update(); } void PianoRoll::glueNotes() { - if (hasValidPattern()) + if (hasValidMidiClip()) { NoteVector selectedNotes = getSelectedNotes(); if (selectedNotes.empty()) @@ -682,7 +682,7 @@ void PianoRoll::glueNotes() } // Make undo possible - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); // Sort notes on key and then pos. std::sort(selectedNotes.begin(), selectedNotes.end(), @@ -726,7 +726,7 @@ void PianoRoll::glueNotes() // Remove old notes for (int i = 0; i < noteToRemove.count(); ++i) { - m_pattern->removeNote(noteToRemove[i]); + m_midiClip->removeNote(noteToRemove[i]); } update(); @@ -735,11 +735,11 @@ void PianoRoll::glueNotes() void PianoRoll::fitNoteLengths(bool fill) { - if (!hasValidPattern()) { return; } - m_pattern->addJournalCheckPoint(); + if (!hasValidMidiClip()) { return; } + m_midiClip->addJournalCheckPoint(); // Reference notes - NoteVector refNotes = m_pattern->notes(); + NoteVector refNotes = m_midiClip->notes(); std::sort(refNotes.begin(), refNotes.end(), Note::lessThan); // Notes to edit @@ -790,13 +790,13 @@ void PianoRoll::fitNoteLengths(bool fill) void PianoRoll::constrainNoteLengths(bool constrainMax) { - if (!hasValidPattern()) { return; } - m_pattern->addJournalCheckPoint(); + if (!hasValidMidiClip()) { return; } + m_midiClip->addJournalCheckPoint(); NoteVector notes = getSelectedNotes(); if (notes.empty()) { - notes = m_pattern->notes(); + notes = m_midiClip->notes(); } TimePos bound = m_lenOfNewNotes; // will be length of last note @@ -840,19 +840,19 @@ void PianoRoll::loadMarkedSemiTones(const QDomElement & de) } -void PianoRoll::setCurrentPattern( Pattern* newPattern ) +void PianoRoll::setCurrentMidiClip( MidiClip* newMidiClip ) { - if( hasValidPattern() ) + if( hasValidMidiClip() ) { - m_pattern->instrumentTrack()->disconnect( this ); - m_pattern->disconnect(this); + m_midiClip->instrumentTrack()->disconnect( this ); + m_midiClip->disconnect(this); } - // force the song-editor to stop playing if it played pattern before + // force the song-editor to stop playing if it played a MIDI clip before if( Engine::getSong()->isPlaying() && - Engine::getSong()->playMode() == Song::Mode_PlayPattern ) + Engine::getSong()->playMode() == Song::Mode_PlayMidiClip ) { - Engine::getSong()->playPattern( nullptr ); + Engine::getSong()->playMidiClip( nullptr ); } if(m_stepRecorder.isRecording()) @@ -861,19 +861,19 @@ void PianoRoll::setCurrentPattern( Pattern* newPattern ) } // set new data - m_pattern = newPattern; + m_midiClip = newMidiClip; m_currentPosition = 0; m_currentNote = nullptr; m_startKey = INITIAL_START_KEY; - m_stepRecorder.setCurrentPattern(newPattern); + m_stepRecorder.setCurrentMidiClip(newMidiClip); - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { //resizeEvent( NULL ); update(); - emit currentPatternChanged(); + emit currentMidiClipChanged(); return; } @@ -882,7 +882,7 @@ void PianoRoll::setCurrentPattern( Pattern* newPattern ) // determine the central key so that we can scroll to it int central_key = 0; int total_notes = 0; - for( const Note *note : m_pattern->notes() ) + for( const Note *note : m_midiClip->notes() ) { if( note->length() > 0 ) { @@ -901,31 +901,31 @@ void PianoRoll::setCurrentPattern( Pattern* newPattern ) // of start-notes and so on...) resizeEvent( nullptr ); - // make sure to always get informed about the pattern being destroyed - connect( m_pattern, SIGNAL( destroyedPattern( Pattern* ) ), this, SLOT( hidePattern( Pattern* ) ) ); + // make sure to always get informed about the MIDI clip being destroyed + connect( m_midiClip, SIGNAL( destroyedMidiClip( MidiClip* ) ), this, SLOT( hideMidiClip( MidiClip* ) ) ); - connect( m_pattern->instrumentTrack(), SIGNAL( midiNoteOn( const Note& ) ), this, SLOT( startRecordNote( const Note& ) ) ); - connect( m_pattern->instrumentTrack(), SIGNAL( midiNoteOff( const Note& ) ), this, SLOT( finishRecordNote( const Note& ) ) ); - connect( m_pattern, SIGNAL(dataChanged()), this, SLOT(update())); - connect( m_pattern->instrumentTrack()->pianoModel(), SIGNAL( dataChanged() ), this, SLOT( update() ) ); + connect( m_midiClip->instrumentTrack(), SIGNAL( midiNoteOn( const Note& ) ), this, SLOT( startRecordNote( const Note& ) ) ); + connect( m_midiClip->instrumentTrack(), SIGNAL( midiNoteOff( const Note& ) ), this, SLOT( finishRecordNote( const Note& ) ) ); + connect( m_midiClip, SIGNAL(dataChanged()), this, SLOT(update())); + connect( m_midiClip->instrumentTrack()->pianoModel(), SIGNAL( dataChanged() ), this, SLOT( update() ) ); - connect(m_pattern->instrumentTrack()->firstKeyModel(), SIGNAL(dataChanged()), this, SLOT(update())); - connect(m_pattern->instrumentTrack()->lastKeyModel(), SIGNAL(dataChanged()), this, SLOT(update())); - connect(m_pattern->instrumentTrack()->microtuner()->keymapModel(), SIGNAL(dataChanged()), this, SLOT(update())); - connect(m_pattern->instrumentTrack()->microtuner()->keyRangeImportModel(), SIGNAL(dataChanged()), + connect(m_midiClip->instrumentTrack()->firstKeyModel(), SIGNAL(dataChanged()), this, SLOT(update())); + connect(m_midiClip->instrumentTrack()->lastKeyModel(), SIGNAL(dataChanged()), this, SLOT(update())); + connect(m_midiClip->instrumentTrack()->microtuner()->keymapModel(), SIGNAL(dataChanged()), this, SLOT(update())); + connect(m_midiClip->instrumentTrack()->microtuner()->keyRangeImportModel(), SIGNAL(dataChanged()), this, SLOT(update())); update(); - emit currentPatternChanged(); + emit currentMidiClipChanged(); } -void PianoRoll::hidePattern( Pattern* pattern ) +void PianoRoll::hideMidiClip( MidiClip* clip ) { - if( m_pattern == pattern ) + if( m_midiClip == clip ) { - setCurrentPattern( nullptr ); + setCurrentMidiClip( nullptr ); } } @@ -1094,7 +1094,7 @@ void PianoRoll::drawDetuningInfo( QPainter & _p, const Note * _n, int _x, int old_x = 0; int old_y = 0; - timeMap & map = _n->detuning()->automationPattern()->getTimeMap(); + timeMap & map = _n->detuning()->automationClip()->getTimeMap(); for (timeMap::const_iterator it = map.begin(); it != map.end(); ++it) { // Current node values @@ -1127,14 +1127,14 @@ void PianoRoll::drawDetuningInfo( QPainter & _p, const Note * _n, int _x, // Now draw the lines representing the actual progression from one // node to the other - switch (_n->detuning()->automationPattern()->progressionType()) + switch (_n->detuning()->automationClip()->progressionType()) { - case AutomationPattern::DiscreteProgression: + case AutomationClip::DiscreteProgression: _p.drawLine(old_x, pre_y, cur_x, pre_y); _p.drawLine(cur_x, pre_y, cur_x, cur_y); break; - case AutomationPattern::CubicHermiteProgression: /* TODO */ - case AutomationPattern::LinearProgression: + case AutomationClip::CubicHermiteProgression: /* TODO */ + case AutomationClip::LinearProgression: _p.drawLine(old_x, pre_y, cur_x, cur_y); break; } @@ -1173,9 +1173,9 @@ void PianoRoll::removeSelection() void PianoRoll::clearSelectedNotes() { - if( m_pattern != nullptr ) + if( m_midiClip != nullptr ) { - for( Note *note : m_pattern->notes() ) + for( Note *note : m_midiClip->notes() ) { note->setSelected( false ); } @@ -1186,21 +1186,21 @@ void PianoRoll::clearSelectedNotes() void PianoRoll::shiftSemiTone(int amount) //Shift notes by amount semitones { - if (!hasValidPattern()) { return; } + if (!hasValidMidiClip()) { return; } auto selectedNotes = getSelectedNotes(); //If no notes are selected, shift all of them, otherwise shift selection - if (selectedNotes.empty()) { return shiftSemiTone(m_pattern->notes(), amount); } + if (selectedNotes.empty()) { return shiftSemiTone(m_midiClip->notes(), amount); } else { return shiftSemiTone(selectedNotes, amount); } } void PianoRoll::shiftSemiTone(NoteVector notes, int amount) { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); for (Note *note : notes) { note->setKey( note->key() + amount ); } - m_pattern->rearrangeAllNotes(); - m_pattern->dataChanged(); + m_midiClip->rearrangeAllNotes(); + m_midiClip->dataChanged(); //We modified the song update(); getGUI()->songEditor()->update(); @@ -1211,32 +1211,32 @@ void PianoRoll::shiftSemiTone(NoteVector notes, int amount) void PianoRoll::shiftPos(int amount) //Shift notes pos by amount { - if (!hasValidPattern()) { return; } + if (!hasValidMidiClip()) { return; } auto selectedNotes = getSelectedNotes(); //If no notes are selected, shift all of them, otherwise shift selection - if (selectedNotes.empty()) { return shiftPos(m_pattern->notes(), amount); } + if (selectedNotes.empty()) { return shiftPos(m_midiClip->notes(), amount); } else { return shiftPos(selectedNotes, amount); } } void PianoRoll::shiftPos(NoteVector notes, int amount) { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); if (notes.isEmpty()) { return; } auto leftMostPos = notes.first()->pos(); - //Limit leftwards shifts to prevent moving left of pattern start + //Limit leftwards shifts to prevent moving left of clip start auto shiftAmount = (leftMostPos > -amount) ? amount : -leftMostPos; if (shiftAmount == 0) { return; } for (Note *note : notes) { note->setPos( note->pos() + shiftAmount ); } - m_pattern->rearrangeAllNotes(); - m_pattern->updateLength(); - m_pattern->dataChanged(); + m_midiClip->rearrangeAllNotes(); + m_midiClip->updateLength(); + m_midiClip->dataChanged(); // we modified the song update(); getGUI()->songEditor()->update(); @@ -1247,7 +1247,7 @@ void PianoRoll::shiftPos(NoteVector notes, int amount) bool PianoRoll::isSelection() const // are any notes selected? { - for( const Note *note : m_pattern->notes() ) + for( const Note *note : m_midiClip->notes() ) { if( note->selected() ) { @@ -1280,13 +1280,13 @@ void PianoRoll::keyPressEvent(QKeyEvent* ke) } } - if( hasValidPattern() && ke->modifiers() == Qt::NoModifier ) + if( hasValidMidiClip() && ke->modifiers() == Qt::NoModifier ) { const int key_num = PianoView::getKeyFromKeyEvent( ke ) + ( DefaultOctave - 1 ) * KeysPerOctave; if (!ke->isAutoRepeat() && key_num > -1) { - m_pattern->instrumentTrack()->pianoModel()->handleKeyPress(key_num); + m_midiClip->instrumentTrack()->pianoModel()->handleKeyPress(key_num); // if a chord is set, play all chord notes (simulate click on all): playChordNotes(key_num); ke->accept(); @@ -1303,7 +1303,7 @@ void PianoRoll::keyPressEvent(QKeyEvent* ke) { // shift selection up an octave // if nothing selected, shift _everything_ - if (hasValidPattern()) + if (hasValidMidiClip()) { shiftSemiTone( 12 * direction ); } @@ -1311,7 +1311,7 @@ void PianoRoll::keyPressEvent(QKeyEvent* ke) else if((ke->modifiers() & Qt::ShiftModifier) && m_action == ActionNone) { // Move selected notes up by one semitone - if (hasValidPattern()) + if (hasValidMidiClip()) { shiftSemiTone( 1 * direction ); } @@ -1347,7 +1347,7 @@ void PianoRoll::keyPressEvent(QKeyEvent* ke) if( ke->modifiers() & Qt::ControlModifier && m_action == ActionNone ) { // Move selected notes by one bar to the left - if (hasValidPattern()) + if (hasValidMidiClip()) { shiftPos( direction * TimePos::ticksPerBar() ); } @@ -1355,7 +1355,7 @@ void PianoRoll::keyPressEvent(QKeyEvent* ke) else if( ke->modifiers() & Qt::ShiftModifier && m_action == ActionNone) { // move notes - if (hasValidPattern()) + if (hasValidMidiClip()) { bool quantized = ! ( ke->modifiers() & Qt::AltModifier ); int amt = quantized ? quantization() : 1; @@ -1364,14 +1364,14 @@ void PianoRoll::keyPressEvent(QKeyEvent* ke) } else if( ke->modifiers() & Qt::AltModifier) { - // switch to editing a pattern adjacent to this one in the song editor - if (hasValidPattern()) + // switch to editing a clip adjacent to this one in the song editor + if (hasValidMidiClip()) { - Pattern * p = direction > 0 ? m_pattern->nextPattern() - : m_pattern->previousPattern(); - if(p != nullptr) + MidiClip * c = direction > 0 ? m_midiClip->nextMidiClip() + : m_midiClip->previousMidiClip(); + if(c != nullptr) { - setCurrentPattern(p); + setCurrentMidiClip(c); } } } @@ -1503,12 +1503,12 @@ void PianoRoll::keyPressEvent(QKeyEvent* ke) void PianoRoll::keyReleaseEvent(QKeyEvent* ke ) { - if( hasValidPattern() && ke->modifiers() == Qt::NoModifier ) + if( hasValidMidiClip() && ke->modifiers() == Qt::NoModifier ) { const int key_num = PianoView::getKeyFromKeyEvent( ke ) + ( DefaultOctave - 1 ) * KeysPerOctave; if (!ke->isAutoRepeat() && key_num > -1) { - m_pattern->instrumentTrack()->pianoModel()->handleKeyRelease(key_num); + m_midiClip->instrumentTrack()->pianoModel()->handleKeyRelease(key_num); // if a chord is set, simulate click release on all chord notes pauseChordNotes(key_num); ke->accept(); @@ -1530,7 +1530,7 @@ void PianoRoll::keyReleaseEvent(QKeyEvent* ke ) // update after undo/redo case Qt::Key_Z: case Qt::Key_R: - if( hasValidPattern() && ke->modifiers() == Qt::ControlModifier ) + if( hasValidMidiClip() && ke->modifiers() == Qt::ControlModifier ) { update(); } @@ -1605,7 +1605,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) { m_startedWithShift = me->modifiers() & Qt::ShiftModifier; - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { return; } @@ -1623,7 +1623,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) updateKnifePos(me); // Call splitNotes for the note - m_pattern->splitNotes(n, TimePos(m_knifeTickPos)); + m_midiClip->splitNotes(n, TimePos(m_knifeTickPos)); } update(); @@ -1632,19 +1632,19 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) if( m_editMode == ModeEditDetuning && noteUnderMouse() ) { - static QPointer detuningPattern = nullptr; - if (detuningPattern.data() != nullptr) + static QPointer detuningClip = nullptr; + if (detuningClip.data() != nullptr) { - detuningPattern->disconnect(this); + detuningClip->disconnect(this); } Note* n = noteUnderMouse(); if (n->detuning() == nullptr) { n->createDetuning(); } - detuningPattern = n->detuning()->automationPattern(); - connect(detuningPattern.data(), SIGNAL(dataChanged()), this, SLOT(update())); - getGUI()->automationEditor()->open(detuningPattern); + detuningClip = n->detuning()->automationClip(); + connect(detuningClip.data(), SIGNAL(dataChanged()), this, SLOT(update())); + getGUI()->automationEditor()->open(detuningClip); return; } @@ -1692,8 +1692,8 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) m_currentPosition; - // get note-vector of current pattern - const NoteVector & notes = m_pattern->notes(); + // get note-vector of current MIDI clip + const NoteVector & notes = m_midiClip->notes(); // will be our iterator in the following loop NoteVector::ConstIterator it = notes.begin()+notes.size()-1; @@ -1731,7 +1731,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) // area if( edit_note ) { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); // scribble note edit changes mouseMoveEvent( me ); return; @@ -1749,7 +1749,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) if( it == notes.begin()-1 ) { is_new_note = true; - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); // then set new note @@ -1766,7 +1766,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) new_note.setSelected( true ); new_note.setPanning( m_lastNotePanning ); new_note.setVolume( m_lastNoteVolume ); - created_new_note = m_pattern->addNote( new_note ); + created_new_note = m_midiClip->addNote( new_note ); const InstrumentFunctionNoteStacking::Chord & chord = InstrumentFunctionNoteStacking::ChordTable::getInstance() .getChordByName( m_chordModel.currentText() ); @@ -1786,7 +1786,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) new_note.setSelected( true ); new_note.setPanning( m_lastNotePanning ); new_note.setVolume( m_lastNoteVolume ); - m_pattern->addNote( new_note ); + m_midiClip->addNote( new_note ); } } @@ -1843,7 +1843,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) m_currentNote->endPos() * m_ppb / TimePos::ticksPerBar() - RESIZE_AREA_WIDTH && m_currentNote->length() > 0 ) { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); // then resize the note m_action = ActionResizeNote; @@ -1871,7 +1871,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) { if( ! created_new_note ) { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); } // otherwise move it @@ -1885,7 +1885,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) { for (Note *note: selectedNotes) { - Note *newNote = m_pattern->addNote(*note, false); + Note *newNote = m_midiClip->addNote(*note, false); newNote->setSelected(false); } @@ -1912,8 +1912,8 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) m_mouseDownRight = true; if( it != notes.begin()-1 ) { - m_pattern->addJournalCheckPoint(); - m_pattern->removeNote( *it ); + m_midiClip->addJournalCheckPoint(); + m_midiClip->removeNote( *it ); Engine::getSong()->setModified(); } } @@ -1953,7 +1953,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) { // left click - play the note int v = ((float) x) / ((float) m_whiteKeyWidth) * MidiDefaultVelocity; - m_pattern->instrumentTrack()->pianoModel()->handleKeyPress(key_num, v); + m_midiClip->instrumentTrack()->pianoModel()->handleKeyPress(key_num, v); // if a chord is set, play the chords notes as well: playChordNotes(key_num, v); } @@ -1984,7 +1984,7 @@ void PianoRoll::mousePressEvent(QMouseEvent * me ) void PianoRoll::mouseDoubleClickEvent(QMouseEvent * me ) { - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { return; } @@ -2005,7 +2005,7 @@ void PianoRoll::mouseDoubleClickEvent(QMouseEvent * me ) // go through notes to figure out which one we want to change bool altPressed = me->modifiers() & Qt::AltModifier; NoteVector nv; - for ( Note * i : m_pattern->notes() ) + for ( Note * i : m_midiClip->notes() ) { if( i->withinRange( ticks_start, ticks_end ) || ( i->selected() && !altPressed ) ) { @@ -2061,9 +2061,9 @@ void PianoRoll::testPlayNote( Note * n ) { n->setIsPlaying( true ); - const int baseVelocity = m_pattern->instrumentTrack()->midiPort()->baseVelocity(); + const int baseVelocity = m_midiClip->instrumentTrack()->midiPort()->baseVelocity(); - m_pattern->instrumentTrack()->pianoModel()->handleKeyPress(n->key(), n->midiVelocity(baseVelocity)); + m_midiClip->instrumentTrack()->pianoModel()->handleKeyPress(n->key(), n->midiVelocity(baseVelocity)); // if a chord is set, play the chords notes as well: playChordNotes(n->key(), n->midiVelocity(baseVelocity)); @@ -2072,7 +2072,7 @@ void PianoRoll::testPlayNote( Note * n ) event.setMetaEvent( MidiNotePanning ); - m_pattern->instrumentTrack()->processInEvent( event, 0 ); + m_midiClip->instrumentTrack()->processInEvent( event, 0 ); } } @@ -2081,14 +2081,14 @@ void PianoRoll::testPlayNote( Note * n ) void PianoRoll::pauseTestNotes( bool pause ) { - for (Note *note : m_pattern->notes()) + for (Note *note : m_midiClip->notes()) { if( note->isPlaying() ) { if( pause ) { // stop note - m_pattern->instrumentTrack()->pianoModel()->handleKeyRelease( note->key() ); + m_midiClip->instrumentTrack()->pianoModel()->handleKeyRelease( note->key() ); // if a chord was set, stop the chords notes as well: pauseChordNotes(note->key()); @@ -2106,7 +2106,7 @@ void PianoRoll::pauseTestNotes( bool pause ) void PianoRoll::playChordNotes(int key, int velocity) { // if a chord is set, play the chords notes beside the base note. - Piano *pianoModel = m_pattern->instrumentTrack()->pianoModel(); + Piano *pianoModel = m_midiClip->instrumentTrack()->pianoModel(); const InstrumentFunctionNoteStacking::Chord & chord = InstrumentFunctionNoteStacking::ChordTable::getInstance().getChordByName( m_chordModel.currentText()); @@ -2122,7 +2122,7 @@ void PianoRoll::playChordNotes(int key, int velocity) void PianoRoll::pauseChordNotes(int key) { // if a chord was set, stop the chords notes beside the base note. - Piano *pianoModel = m_pattern->instrumentTrack()->pianoModel(); + Piano *pianoModel = m_midiClip->instrumentTrack()->pianoModel(); const InstrumentFunctionNoteStacking::Chord & chord = InstrumentFunctionNoteStacking::ChordTable::getInstance().getChordByName( m_chordModel.currentText()); @@ -2158,7 +2158,7 @@ void PianoRoll::cancelKnifeAction() void PianoRoll::testPlayKey( int key, int velocity, int pan ) { - Piano *pianoModel = m_pattern->instrumentTrack()->pianoModel(); + Piano *pianoModel = m_midiClip->instrumentTrack()->pianoModel(); // turn off old key pianoModel->handleKeyRelease( m_lastKey ); // if a chord was set, stop the chords notes as well @@ -2203,9 +2203,9 @@ void PianoRoll::computeSelectedNotes(bool shift) } //int y_base = noteEditTop() - 1; - if( hasValidPattern() ) + if( hasValidMidiClip() ) { - for( Note *note : m_pattern->notes() ) + for( Note *note : m_midiClip->notes() ) { // make a new selection unless they're holding shift if( ! shift ) @@ -2275,8 +2275,8 @@ void PianoRoll::mouseReleaseEvent( QMouseEvent * me ) { // we moved one or more notes so they have to be // moved properly according to new starting- - // time in the note-array of pattern - m_pattern->rearrangeAllNotes(); + // time in the note-array of clip + m_midiClip->rearrangeAllNotes(); } @@ -2297,14 +2297,14 @@ void PianoRoll::mouseReleaseEvent( QMouseEvent * me ) mustRepaint = true; } - if( hasValidPattern() ) + if( hasValidMidiClip() ) { // turn off all notes that are playing - for ( Note *note : m_pattern->notes() ) + for ( Note *note : m_midiClip->notes() ) { if( note->isPlaying() ) { - m_pattern->instrumentTrack()->pianoModel()-> + m_midiClip->instrumentTrack()->pianoModel()-> handleKeyRelease( note->key() ); pauseChordNotes(note->key()); note->setIsPlaying( false ); @@ -2312,7 +2312,7 @@ void PianoRoll::mouseReleaseEvent( QMouseEvent * me ) } // stop playing keys that we let go of - m_pattern->instrumentTrack()->pianoModel()-> + m_midiClip->instrumentTrack()->pianoModel()-> handleKeyRelease( m_lastKey ); pauseChordNotes(m_lastKey); } @@ -2340,7 +2340,7 @@ void PianoRoll::mouseReleaseEvent( QMouseEvent * me ) void PianoRoll::mouseMoveEvent( QMouseEvent * me ) { - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { update(); return; @@ -2451,8 +2451,8 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me ) int ticks_end = ( x+pixel_range/2 ) * TimePos::ticksPerBar() / m_ppb + m_currentPosition; - // get note-vector of current pattern - const NoteVector & notes = m_pattern->notes(); + // get note-vector of current MIDI clip + const NoteVector & notes = m_midiClip->notes(); // determine what volume/panning to set note to // if middle-click, set to defaults @@ -2488,7 +2488,7 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me ) // When alt is pressed we only edit the note under the cursor bool altPressed = me->modifiers() & Qt::AltModifier; - // We iterate from last note in pattern to the first, + // We iterate from last note in MIDI clip to the first, // chronologically NoteVector::ConstIterator it = notes.begin()+notes.size()-1; for( int i = 0; i < notes.size(); ++i ) @@ -2511,22 +2511,22 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me ) { n->setVolume( vol ); - const int baseVelocity = m_pattern->instrumentTrack()->midiPort()->baseVelocity(); + const int baseVelocity = m_midiClip->instrumentTrack()->midiPort()->baseVelocity(); - m_pattern->instrumentTrack()->processInEvent( MidiEvent( MidiKeyPressure, -1, n->key(), n->midiVelocity( baseVelocity ) ) ); + m_midiClip->instrumentTrack()->processInEvent( MidiEvent( MidiKeyPressure, -1, n->key(), n->midiVelocity( baseVelocity ) ) ); } else if( m_noteEditMode == NoteEditPanning ) { n->setPanning( pan ); MidiEvent evt( MidiMetaEvent, -1, n->key(), panningToMidi( pan ) ); evt.setMetaEvent( MidiNotePanning ); - m_pattern->instrumentTrack()->processInEvent( evt ); + m_midiClip->instrumentTrack()->processInEvent( evt ); } } else if( n->isPlaying() && !isSelection() ) { // mouse not over this note, stop playing it. - m_pattern->instrumentTrack()->pianoModel()->handleKeyRelease( n->key() ); + m_midiClip->instrumentTrack()->pianoModel()->handleKeyRelease( n->key() ); pauseChordNotes(n->key()); n->setIsPlaying( false ); @@ -2536,8 +2536,8 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me ) --it; } - // Emit pattern has changed - m_pattern->dataChanged(); + // Emit MIDI clip has changed + m_midiClip->dataChanged(); } else if( me->buttons() == Qt::NoButton && m_editMode == ModeDraw ) @@ -2548,8 +2548,8 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me ) int pos_ticks = ( x * TimePos::ticksPerBar() ) / m_ppb + m_currentPosition; - // get note-vector of current pattern - const NoteVector & notes = m_pattern->notes(); + // get note-vector of current MIDI clip + const NoteVector & notes = m_midiClip->notes(); // will be our iterator in the following loop NoteVector::ConstIterator it = notes.begin()+notes.size()-1; @@ -2625,8 +2625,8 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me ) m_currentPosition; - // get note-vector of current pattern - const NoteVector & notes = m_pattern->notes(); + // get note-vector of current MIDI clip + const NoteVector & notes = m_midiClip->notes(); // will be our iterator in the following loop NoteVector::ConstIterator it = notes.begin(); @@ -2658,7 +2658,7 @@ void PianoRoll::mouseMoveEvent( QMouseEvent * me ) ) { // delete this note - m_pattern->removeNote( note ); + m_midiClip->removeNote( note ); Engine::getSong()->setModified(); } else @@ -2794,8 +2794,8 @@ void PianoRoll::dragNotes(int x, int y, bool alt, bool shift, bool ctrl) off_ticks -= m_mouseDownTick - m_currentPosition; off_key -= m_mouseDownKey - m_startKey; - // get note-vector of current pattern - const NoteVector & notes = m_pattern->notes(); + // get note-vector of current MIDI clip + const NoteVector & notes = m_midiClip->notes(); if (m_action == ActionMoveNote) { @@ -2996,8 +2996,8 @@ void PianoRoll::dragNotes(int x, int y, bool alt, bool shift, bool ctrl) } } - m_pattern->updateLength(); - m_pattern->dataChanged(); + m_midiClip->updateLength(); + m_midiClip->dataChanged(); Engine::getSong()->setModified(); } @@ -3040,7 +3040,7 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) // - note edit area resize bar // - cursor mode icon - if (hasValidPattern()) + if (hasValidMidiClip()) { int pianoAreaHeight, partialKeyVisible, topKey, topNote; pianoAreaHeight = keyAreaBottom() - keyAreaTop(); @@ -3176,8 +3176,8 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) const int key, const int yb) { - const bool mapped = m_pattern->instrumentTrack()->isKeyMapped(key); - const bool pressed = m_pattern->instrumentTrack()->pianoModel()->isKeyPressed(key); + const bool mapped = m_midiClip->instrumentTrack()->isKeyMapped(key); + const bool pressed = m_midiClip->instrumentTrack()->pianoModel()->isKeyPressed(key); const int keyCode = key % KeysPerOctave; const int yt = yb - gridCorrection(key); const int kh = keyHeight(key); @@ -3339,7 +3339,7 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) } } - // reset clip + // reset MIDI clip p.setClipRect(0, 0, width(), height()); // erase the area below the piano, because there might be keys that @@ -3384,7 +3384,7 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) } int y_base = keyAreaBottom() - 1; - if( hasValidPattern() ) + if( hasValidMidiClip() ) { p.setClipRect( m_whiteKeyWidth, @@ -3403,7 +3403,7 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) return (topKey - key) * m_keyLineHeight + keyAreaTop() - 1; }; - // -- Begin ghost pattern + // -- Begin ghost MIDI clip if( !m_ghostNotes.empty() ) { for( const Note *note : m_ghostNotes ) @@ -3443,9 +3443,9 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) } } - // -- End ghost pattern + // -- End ghost MIDI clip - for( const Note *note : m_pattern->notes() ) + for( const Note *note : m_midiClip->notes() ) { int len_ticks = note->length(); @@ -3613,7 +3613,7 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) p.setPen( QApplication::palette().color( QPalette::Active, QPalette::BrightText ) ); p.drawText(m_whiteKeyWidth + 20, PR_TOP_MARGIN + 40, - tr( "Please open a pattern by double-clicking " + tr( "Please open a clip by double-clicking " "on it!" ) ); } @@ -3635,7 +3635,7 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) p.drawRect(x + m_whiteKeyWidth, y, w, h); // TODO: Get this out of paint event - int l = ( hasValidPattern() )? (int) m_pattern->length() : 0; + int l = ( hasValidMidiClip() )? (int) m_midiClip->length() : 0; // reset scroll-range if( m_leftRightScroll->maximum() != l ) @@ -3652,7 +3652,7 @@ void PianoRoll::paintEvent(QPaintEvent * pe ) currentKeyCol.setAlpha( 64 ); // horizontal line for the key under the cursor - if(hasValidPattern() && getGUI()->pianoRoll()->hasFocus()) + if(hasValidMidiClip() && getGUI()->pianoRoll()->hasFocus()) { int key_num = getKey( mapFromGlobal( QCursor::pos() ).y() ); p.fillRect( 10, keyAreaBottom() + 3 - m_keyLineHeight * @@ -3730,7 +3730,7 @@ void PianoRoll::resizeEvent(QResizeEvent* re) { updatePositionLineHeight(); updateScrollbars(); - Engine::getSong()->getPlayPos(Song::Mode_PlayPattern) + Engine::getSong()->getPlayPos(Song::Mode_PlayMidiClip) .m_timeLine->setFixedWidth(width()); update(); } @@ -3745,7 +3745,7 @@ void PianoRoll::wheelEvent(QWheelEvent * we ) if(position(we).x() > noteEditLeft() && position(we).x() < noteEditRight() && position(we).y() > noteEditTop() && position(we).y() < noteEditBottom()) { - if (!hasValidPattern()) {return;} + if (!hasValidMidiClip()) {return;} // get values for going through notes int pixel_range = 8; int x = position(we).x() - m_whiteKeyWidth; @@ -3758,7 +3758,7 @@ void PianoRoll::wheelEvent(QWheelEvent * we ) bool altPressed = we->modifiers() & Qt::AltModifier; // go through notes to figure out which one we want to change NoteVector nv; - for ( Note * i : m_pattern->notes() ) + for ( Note * i : m_midiClip->notes() ) { if( i->withinRange( ticks_start, ticks_end ) || ( i->selected() && !altPressed ) ) { @@ -3887,12 +3887,12 @@ void PianoRoll::wheelEvent(QWheelEvent * we ) void PianoRoll::focusOutEvent( QFocusEvent * ) { - if( hasValidPattern() ) + if( hasValidMidiClip() ) { for( int i = 0; i < NumKeys; ++i ) { - m_pattern->instrumentTrack()->pianoModel()->midiEventProcessor()->processInEvent( MidiEvent( MidiNoteOff, -1, i, 0 ) ); - m_pattern->instrumentTrack()->pianoModel()->setKeyState( i, false ); + m_midiClip->instrumentTrack()->pianoModel()->midiEventProcessor()->processInEvent( MidiEvent( MidiNoteOff, -1, i, 0 ) ); + m_midiClip->instrumentTrack()->pianoModel()->setKeyState( i, false ); } } if (m_editMode == ModeEditKnife) { @@ -3906,10 +3906,10 @@ void PianoRoll::focusOutEvent( QFocusEvent * ) void PianoRoll::focusInEvent( QFocusEvent * ev ) { - if ( hasValidPattern() ) + if ( hasValidMidiClip() ) { // Assign midi device - m_pattern->instrumentTrack()->autoAssignMidiDevice(true); + m_midiClip->instrumentTrack()->autoAssignMidiDevice(true); } QWidget::focusInEvent(ev); } @@ -3943,7 +3943,7 @@ QList PianoRoll::getAllOctavesForKey( int keyToMirror ) const Song::PlayModes PianoRoll::desiredPlayModeForAccompany() const { - if( m_pattern->getTrack()->trackContainer() == + if( m_midiClip->getTrack()->trackContainer() == Engine::getBBTrackContainer() ) { return Song::Mode_PlayBB; @@ -3956,14 +3956,14 @@ Song::PlayModes PianoRoll::desiredPlayModeForAccompany() const void PianoRoll::play() { - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { return; } - if( Engine::getSong()->playMode() != Song::Mode_PlayPattern ) + if( Engine::getSong()->playMode() != Song::Mode_PlayMidiClip ) { - Engine::getSong()->playPattern( m_pattern ); + Engine::getSong()->playMidiClip( m_midiClip ); } else { @@ -3980,15 +3980,15 @@ void PianoRoll::record() { stop(); } - if( m_recording || ! hasValidPattern() ) + if( m_recording || ! hasValidMidiClip() ) { return; } - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); m_recording = true; - Engine::getSong()->playPattern( m_pattern, false ); + Engine::getSong()->playMidiClip( m_midiClip, false ); } @@ -4000,15 +4000,15 @@ void PianoRoll::recordAccompany() { stop(); } - if( m_recording || ! hasValidPattern() ) + if( m_recording || ! hasValidMidiClip() ) { return; } - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); m_recording = true; - if( m_pattern->getTrack()->trackContainer() == Engine::getSong() ) + if( m_midiClip->getTrack()->trackContainer() == Engine::getSong() ) { Engine::getSong()->playSong(); } @@ -4029,7 +4029,7 @@ bool PianoRoll::toggleStepRecording() } else { - if(hasValidPattern()) + if(hasValidMidiClip()) { if(Engine::getSong()->isPlaying()) { @@ -4039,7 +4039,7 @@ bool PianoRoll::toggleStepRecording() { m_stepRecorder.start( Engine::getSong()->getPlayPos( - Song::Mode_PlayPattern), newNoteLen()); + Song::Mode_PlayMidiClip), newNoteLen()); } } } @@ -4062,17 +4062,17 @@ void PianoRoll::stop() void PianoRoll::startRecordNote(const Note & n ) { - if(hasValidPattern()) + if(hasValidMidiClip()) { if( m_recording && Engine::getSong()->isPlaying() && (Engine::getSong()->playMode() == desiredPlayModeForAccompany() || - Engine::getSong()->playMode() == Song::Mode_PlayPattern )) + Engine::getSong()->playMode() == Song::Mode_PlayMidiClip )) { TimePos sub; if( Engine::getSong()->playMode() == Song::Mode_PlaySong ) { - sub = m_pattern->startPosition(); + sub = m_midiClip->startPosition(); } Note n1( 1, Engine::getSong()->getPlayPos( Engine::getSong()->playMode() ) - sub, @@ -4094,14 +4094,14 @@ void PianoRoll::startRecordNote(const Note & n ) void PianoRoll::finishRecordNote(const Note & n ) { - if(hasValidPattern()) + if(hasValidMidiClip()) { if( m_recording && Engine::getSong()->isPlaying() && ( Engine::getSong()->playMode() == desiredPlayModeForAccompany() || Engine::getSong()->playMode() == - Song::Mode_PlayPattern ) ) + Song::Mode_PlayMidiClip ) ) { for( QList::Iterator it = m_recordingNotes.begin(); it != m_recordingNotes.end(); ++it ) @@ -4112,7 +4112,7 @@ void PianoRoll::finishRecordNote(const Note & n ) it->key(), it->getVolume(), it->getPanning() ); n1.quantizeLength( quantization() ); - m_pattern->addNote( n1 ); + m_midiClip->addNote( n1 ); update(); m_recordingNotes.erase( it ); break; @@ -4161,7 +4161,7 @@ void PianoRoll::setEditMode(int mode) void PianoRoll::selectAll() { - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { return; } @@ -4169,7 +4169,7 @@ void PianoRoll::selectAll() // if first_time = true, we HAVE to set the vars for select bool first_time = true; - for( const Note *note : m_pattern->notes() ) + for( const Note *note : m_midiClip->notes() ) { int len_ticks = static_cast( note->length() ) > 0 ? static_cast( note->length() ) : 1; @@ -4217,9 +4217,9 @@ NoteVector PianoRoll::getSelectedNotes() const { NoteVector selectedNotes; - if (hasValidPattern()) + if (hasValidMidiClip()) { - for( Note *note : m_pattern->notes() ) + for( Note *note : m_midiClip->notes() ) { if( note->selected() ) { @@ -4233,8 +4233,8 @@ NoteVector PianoRoll::getSelectedNotes() const // selects all notess associated with m_lastKey void PianoRoll::selectNotesOnKey() { - if (hasValidPattern()) { - for (Note * note : m_pattern->notes()) { + if (hasValidMidiClip()) { + for (Note * note : m_midiClip->notes()) { if (note->key() == m_lastKey) { note->setSelected(true); } @@ -4345,7 +4345,7 @@ void PianoRoll::copySelectedNotes() void PianoRoll::cutSelectedNotes() { - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { return; } @@ -4354,7 +4354,7 @@ void PianoRoll::cutSelectedNotes() if( ! selected_notes.empty() ) { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); copyToClipboard( selected_notes ); @@ -4363,8 +4363,8 @@ void PianoRoll::cutSelectedNotes() for( Note *note : selected_notes ) { // note (the memory of it) is also deleted by - // pattern::removeNote(...) so we don't have to do that - m_pattern->removeNote( note ); + // MidiClip::removeNote(...) so we don't have to do that + m_midiClip->removeNote( note ); } } @@ -4380,7 +4380,7 @@ void PianoRoll::pasteNotes() // For getString() and MimeType enum class using namespace Clipboard; - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { return; } @@ -4398,7 +4398,7 @@ void PianoRoll::pasteNotes() if( ! list.isEmpty() ) { - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); } for( int i = 0; ! list.item( i ).isNull(); ++i ) @@ -4411,8 +4411,8 @@ void PianoRoll::pasteNotes() // select it cur_note.setSelected( true ); - // add to pattern - m_pattern->addNote( cur_note, false ); + // add to MIDI clip + m_midiClip->addNote( cur_note, false ); } // we only have to do the following lines if we pasted at @@ -4429,14 +4429,14 @@ void PianoRoll::pasteNotes() //Return false if no notes are deleted bool PianoRoll::deleteSelectedNotes() { - if (!hasValidPattern()) { return false; } + if (!hasValidMidiClip()) { return false; } auto selectedNotes = getSelectedNotes(); if (selectedNotes.empty()) { return false; } - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); - for (Note* note: selectedNotes) { m_pattern->removeNote( note ); } + for (Note* note: selectedNotes) { m_midiClip->removeNote( note ); } Engine::getSong()->setModified(); update(); @@ -4469,7 +4469,7 @@ void PianoRoll::autoScroll( const TimePos & t ) void PianoRoll::updatePosition( const TimePos & t ) { if( ( Engine::getSong()->isPlaying() - && Engine::getSong()->playMode() == Song::Mode_PlayPattern + && Engine::getSong()->playMode() == Song::Mode_PlayMidiClip && m_timeLine->autoScroll() == TimeLineWidget::AutoScrollEnabled ) || m_scrollBack ) { @@ -4505,17 +4505,17 @@ void PianoRoll::updatePositionAccompany( const TimePos & t ) { Song * s = Engine::getSong(); - if( m_recording && hasValidPattern() && - s->playMode() != Song::Mode_PlayPattern ) + if( m_recording && hasValidMidiClip() && + s->playMode() != Song::Mode_PlayMidiClip ) { TimePos pos = t; if( s->playMode() != Song::Mode_PlayBB ) { - pos -= m_pattern->startPosition(); + pos -= m_midiClip->startPosition(); } if( (int) pos > 0 ) { - s->getPlayPos( Song::Mode_PlayPattern ).setTicks( pos ); + s->getPlayPos( Song::Mode_PlayMidiClip ).setTicks( pos ); autoScroll( pos ); } } @@ -4593,18 +4593,18 @@ int PianoRoll::quantization() const void PianoRoll::quantizeNotes(QuantizeActions mode) { - if( ! hasValidPattern() ) + if( ! hasValidMidiClip() ) { return; } - m_pattern->addJournalCheckPoint(); + m_midiClip->addJournalCheckPoint(); NoteVector notes = getSelectedNotes(); if( notes.empty() ) { - for( Note* n : m_pattern->notes() ) + for( Note* n : m_midiClip->notes() ) { notes.push_back( n ); } @@ -4618,7 +4618,7 @@ void PianoRoll::quantizeNotes(QuantizeActions mode) } Note copy(*n); - m_pattern->removeNote( n ); + m_midiClip->removeNote( n ); if (mode == QuantizeBoth || mode == QuantizePos) { copy.quantizePos(quantization()); @@ -4627,7 +4627,7 @@ void PianoRoll::quantizeNotes(QuantizeActions mode) { copy.quantizeLength(quantization()); } - m_pattern->addNote(copy, false); + m_midiClip->addNote(copy, false); } update(); @@ -4670,7 +4670,7 @@ TimePos PianoRoll::newNoteLen() const bool PianoRoll::mouseOverNote() { - return hasValidPattern() && noteUnderMouse() != nullptr; + return hasValidMidiClip() && noteUnderMouse() != nullptr; } @@ -4693,7 +4693,7 @@ Note * PianoRoll::noteUnderMouse() TimePos::ticksPerBar() / m_ppb + m_currentPosition; // loop through whole note-vector... - for( Note* const& note : m_pattern->notes() ) + for( Note* const& note : m_midiClip->notes() ) { // and check whether the cursor is over an // existing note @@ -4724,11 +4724,11 @@ PianoRollWindow::PianoRollWindow() : { setCentralWidget( m_editor ); - m_playAction->setToolTip(tr( "Play/pause current pattern (Space)" ) ); + m_playAction->setToolTip(tr( "Play/pause current clip (Space)" ) ); m_recordAction->setToolTip(tr( "Record notes from MIDI-device/channel-piano" ) ); m_recordAccompanyAction->setToolTip( tr( "Record notes from MIDI-device/channel-piano while playing song or BB track" ) ); m_toggleStepRecordingAction->setToolTip( tr( "Record notes from MIDI-device/channel-piano, one step at the time" ) ); - m_stopAction->setToolTip( tr( "Stop playing of current pattern (Space)" ) ); + m_stopAction->setToolTip( tr( "Stop playing of current clip (Space)" ) ); DropToolBar *notesActionsToolBar = addDropToolBarToTop( tr( "Edit actions" ) ); @@ -4783,17 +4783,17 @@ PianoRollWindow::PianoRollWindow() : // Import / export QAction* importAction = new QAction(embed::getIconPixmap("project_import"), - tr("Import pattern"), m_fileToolsButton); + tr("Import clip"), m_fileToolsButton); QAction* exportAction = new QAction(embed::getIconPixmap("project_export"), - tr("Export pattern"), m_fileToolsButton); + tr("Export clip"), m_fileToolsButton); m_fileToolsButton->addAction(importAction); m_fileToolsButton->addAction(exportAction); fileActionsToolBar->addWidget(m_fileToolsButton); - connect(importAction, SIGNAL(triggered()), this, SLOT(importPattern())); - connect(exportAction, SIGNAL(triggered()), this, SLOT(exportPattern())); + connect(importAction, SIGNAL(triggered()), this, SLOT(importMidiClip())); + connect(exportAction, SIGNAL(triggered()), this, SLOT(exportMidiClip())); // -- End File actions // Copy + paste actions @@ -4934,13 +4934,13 @@ PianoRollWindow::PianoRollWindow() : m_snapComboBox->setFixedSize(105, ComboBox::DEFAULT_HEIGHT); m_snapComboBox->setToolTip(tr("Snap mode")); - // -- Clear ghost pattern button + // -- Clear ghost MIDI clip button m_clearGhostButton = new QPushButton( m_toolBar ); m_clearGhostButton->setIcon( embed::getIconPixmap( "clear_ghost_note" ) ); m_clearGhostButton->setToolTip( tr( "Clear ghost notes" ) ); m_clearGhostButton->setEnabled( false ); - connect( m_clearGhostButton, SIGNAL( clicked() ), m_editor, SLOT( clearGhostPattern() ) ); - connect( m_editor, SIGNAL( ghostPatternSet( bool ) ), this, SLOT( ghostPatternSet( bool ) ) ); + connect( m_clearGhostButton, SIGNAL( clicked() ), m_editor, SLOT( clearGhostClip() ) ); + connect( m_editor, SIGNAL( ghostClipSet( bool ) ), this, SLOT( ghostClipSet( bool ) ) ); // Wrap label icons and comboboxes in a single widget so when // the window is resized smaller in width it hides both @@ -5014,46 +5014,46 @@ PianoRollWindow::PianoRollWindow() : setFocusPolicy( Qt::StrongFocus ); setFocus(); setWindowIcon( embed::getIconPixmap( "piano" ) ); - setCurrentPattern( nullptr ); + setCurrentMidiClip( nullptr ); // Connections - connect( m_editor, SIGNAL( currentPatternChanged() ), this, SIGNAL( currentPatternChanged() ) ); - connect( m_editor, SIGNAL( currentPatternChanged() ), this, SLOT( updateAfterPatternChange() ) ); + connect( m_editor, SIGNAL( currentMidiClipChanged() ), this, SIGNAL( currentMidiClipChanged() ) ); + connect( m_editor, SIGNAL( currentMidiClipChanged() ), this, SLOT( updateAfterMidiClipChange() ) ); } -const Pattern* PianoRollWindow::currentPattern() const +const MidiClip* PianoRollWindow::currentMidiClip() const { - return m_editor->currentPattern(); + return m_editor->currentMidiClip(); } -void PianoRollWindow::setGhostPattern( Pattern* pattern ) +void PianoRollWindow::setGhostMidiClip( MidiClip* clip ) { - m_editor->setGhostPattern( pattern ); + m_editor->setGhostMidiClip( clip ); } -void PianoRollWindow::setCurrentPattern( Pattern* pattern ) +void PianoRollWindow::setCurrentMidiClip( MidiClip* clip ) { - m_editor->setCurrentPattern( pattern ); + m_editor->setCurrentMidiClip( clip ); - if ( pattern ) + if ( clip ) { - setWindowTitle( tr( "Piano-Roll - %1" ).arg( pattern->name() ) ); + setWindowTitle( tr( "Piano-Roll - %1" ).arg( clip->name() ) ); m_fileToolsButton->setEnabled(true); - connect( pattern->instrumentTrack(), SIGNAL( nameChanged() ), this, SLOT( updateAfterPatternChange()) ); - connect( pattern, SIGNAL( dataChanged() ), this, SLOT( updateAfterPatternChange() ) ); + connect( clip->instrumentTrack(), SIGNAL( nameChanged() ), this, SLOT( updateAfterMidiClipChange()) ); + connect( clip, SIGNAL( dataChanged() ), this, SLOT( updateAfterMidiClipChange() ) ); } else { - setWindowTitle( tr( "Piano-Roll - no pattern" ) ); + setWindowTitle( tr( "Piano-Roll - no clip" ) ); m_fileToolsButton->setEnabled(false); } } @@ -5209,22 +5209,22 @@ bool PianoRollWindow::hasFocus() const -void PianoRollWindow::updateAfterPatternChange() +void PianoRollWindow::updateAfterMidiClipChange() { - patternRenamed(); - updateStepRecordingIcon(); //pattern change turn step recording OFF - update icon accordingly + clipRenamed(); + updateStepRecordingIcon(); //MIDI clip change turn step recording OFF - update icon accordingly } -void PianoRollWindow::patternRenamed() +void PianoRollWindow::clipRenamed() { - if ( currentPattern() ) + if ( currentMidiClip() ) { - setWindowTitle( tr( "Piano-Roll - %1" ).arg( currentPattern()->name() ) ); + setWindowTitle( tr( "Piano-Roll - %1" ).arg( currentMidiClip()->name() ) ); m_fileToolsButton->setEnabled(true); } else { - setWindowTitle( tr( "Piano-Roll - no pattern" ) ); + setWindowTitle( tr( "Piano-Roll - no clip" ) ); m_fileToolsButton->setEnabled(false); } } @@ -5232,7 +5232,7 @@ void PianoRollWindow::patternRenamed() -void PianoRollWindow::ghostPatternSet( bool state ) +void PianoRollWindow::ghostClipSet( bool state ) { m_clearGhostButton->setEnabled( state ); } @@ -5240,10 +5240,10 @@ void PianoRollWindow::ghostPatternSet( bool state ) -void PianoRollWindow::exportPattern() +void PianoRollWindow::exportMidiClip() { - FileDialog exportDialog(this, tr("Export pattern"), "", - tr("XML pattern file (*.xpt *.xptz)")); + FileDialog exportDialog(this, tr("Export clip"), "", + tr("XML clip file (*.xpt *.xptz)")); exportDialog.setAcceptMode(FileDialog::AcceptSave); @@ -5258,13 +5258,13 @@ void PianoRollWindow::exportPattern() exportDialog.setDefaultSuffix(suffix); const QString fullPath = exportDialog.selectedFiles()[0]; - DataFile dataFile(DataFile::NotePattern); - m_editor->m_pattern->saveSettings(dataFile, dataFile.content()); + DataFile dataFile(DataFile::MidiClip); + m_editor->m_midiClip->saveSettings(dataFile, dataFile.content()); if (dataFile.writeFile(fullPath)) { - TextFloat::displayMessage(tr("Export pattern success"), - tr("Pattern saved to %1").arg(fullPath), + TextFloat::displayMessage(tr("Export clip success"), + tr("Clip saved to %1").arg(fullPath), embed::getIconPixmap("project_export"), 4000); } } @@ -5273,15 +5273,15 @@ void PianoRollWindow::exportPattern() -void PianoRollWindow::importPattern() +void PianoRollWindow::importMidiClip() { // Overwrite confirmation. - if (!m_editor->m_pattern->empty() && + if (!m_editor->m_midiClip->empty() && QMessageBox::warning( nullptr, - tr("Import pattern."), - tr("You are about to import a pattern, this will " - "overwrite your current pattern. Do you want to " + tr("Import clip."), + tr("You are about to import a clip, this will " + "overwrite your current clip. Do you want to " "continue?"), QMessageBox::Yes | QMessageBox::No, QMessageBox::Yes ) != QMessageBox::Yes) @@ -5289,8 +5289,8 @@ void PianoRollWindow::importPattern() return; } - FileDialog importDialog(this, tr("Open pattern"), "", - tr("XML pattern file (*.xpt *.xptz)")); + FileDialog importDialog(this, tr("Open clip"), "", + tr("XML clip file (*.xpt *.xptz)")); importDialog.setFileMode(FileDialog::ExistingFile); if (importDialog.exec() == QDialog::Accepted && @@ -5304,13 +5304,13 @@ void PianoRollWindow::importPattern() return; } - TimePos pos = m_editor->m_pattern->startPosition(); // Backup position in timeline. + TimePos pos = m_editor->m_midiClip->startPosition(); // Backup position in timeline. - m_editor->m_pattern->loadSettings(dataFile.content()); - m_editor->m_pattern->movePosition(pos); + m_editor->m_midiClip->loadSettings(dataFile.content()); + m_editor->m_midiClip->movePosition(pos); - TextFloat::displayMessage(tr("Import pattern success"), - tr("Imported pattern %1!").arg(fullPath), + TextFloat::displayMessage(tr("Import clip success"), + tr("Imported clip %1!").arg(fullPath), embed::getIconPixmap("project_import"), 4000); } } diff --git a/src/gui/editors/SongEditor.cpp b/src/gui/editors/SongEditor.cpp index 6024b9184be..55d22cf62a8 100644 --- a/src/gui/editors/SongEditor.cpp +++ b/src/gui/editors/SongEditor.cpp @@ -352,7 +352,7 @@ void SongEditor::selectRegionFromPixels(int xStart, int xEnd) { m_selectRegion = true; - //deselect all tcos + //deselect all clips for (auto &it : findChildren()) { it->setSelected(false); } rubberBand()->setEnabled(true); @@ -419,17 +419,17 @@ void SongEditor::updateRubberband() / pixelsPerBar() * TimePos::ticksPerBar()) + m_currentPosition; - //are tcos in the rect of selection? + //are clips in the rect of selection? for (auto &it : findChildren()) { - TrackContentObjectView * tco = dynamic_cast(it); - if (tco) + ClipView * clip = dynamic_cast(it); + if (clip) { - auto indexOfTrackView = trackViews().indexOf(tco->getTrackView()); + auto indexOfTrackView = trackViews().indexOf(clip->getTrackView()); bool isBeetweenRubberbandViews = indexOfTrackView >= qMin(m_rubberBandStartTrackview, rubberBandTrackview) && indexOfTrackView <= qMax(m_rubberBandStartTrackview, rubberBandTrackview); - bool isBeetweenRubberbandTimePos = tco->getTrackContentObject()->endPosition() >= qMin(m_rubberbandStartTimePos, rubberbandTimePos) - && tco->getTrackContentObject()->startPosition() <= qMax(m_rubberbandStartTimePos, rubberbandTimePos); + bool isBeetweenRubberbandTimePos = clip->getClip()->endPosition() >= qMin(m_rubberbandStartTimePos, rubberbandTimePos) + && clip->getClip()->startPosition() <= qMax(m_rubberbandStartTimePos, rubberbandTimePos); it->setSelected(isBeetweenRubberbandViews && isBeetweenRubberbandTimePos); } } @@ -506,18 +506,18 @@ void SongEditor::keyPressEvent( QKeyEvent * ke ) for( QVector::iterator it = so.begin(); it != so.end(); ++it ) { - TrackContentObjectView * tcov = - dynamic_cast( *it ); - tcov->remove(); + ClipView * clipv = + dynamic_cast( *it ); + clipv->remove(); } } else if( ke->key() == Qt::Key_A && ke->modifiers() & Qt::ControlModifier ) { - selectAllTcos( !isShiftPressed ); + selectAllClips( !isShiftPressed ); } else if( ke->key() == Qt::Key_Escape ) { - selectAllTcos( false ); + selectAllClips( false ); } else { @@ -559,7 +559,7 @@ void SongEditor::wheelEvent( QWheelEvent * we ) // update timeline m_song->m_playPos[Song::Mode_PlaySong].m_timeLine-> setPixelsPerBar( pixelsPerBar() ); - // and make sure, all TCO's are resized and relocated + // and make sure, all Clip's are resized and relocated realignTracks(); } @@ -845,7 +845,7 @@ void SongEditor::zoomingChanged() } -void SongEditor::selectAllTcos( bool select ) +void SongEditor::selectAllClips( bool select ) { QVector so = select ? rubberBand()->selectableObjects() : rubberBand()->selectedObjects(); for( int i = 0; i < so.count(); ++i ) diff --git a/src/gui/widgets/EnvelopeAndLfoView.cpp b/src/gui/widgets/EnvelopeAndLfoView.cpp index 586d01473fc..c99be1c03bf 100644 --- a/src/gui/widgets/EnvelopeAndLfoView.cpp +++ b/src/gui/widgets/EnvelopeAndLfoView.cpp @@ -305,7 +305,7 @@ void EnvelopeAndLfoView::mousePressEvent( QMouseEvent * _me ) void EnvelopeAndLfoView::dragEnterEvent( QDragEnterEvent * _dee ) { StringPairDrag::processDragEnterEvent( _dee, - QString( "samplefile,tco_%1" ).arg( + QString( "samplefile,clip_%1" ).arg( Track::SampleTrack ) ); } @@ -325,7 +325,7 @@ void EnvelopeAndLfoView::dropEvent( QDropEvent * _de ) _de->accept(); update(); } - else if( type == QString( "tco_%1" ).arg( Track::SampleTrack ) ) + else if( type == QString( "clip_%1" ).arg( Track::SampleTrack ) ) { DataFile dataFile( value.toUtf8() ); m_params->m_userWave.setAudioFile( dataFile.content(). diff --git a/src/gui/widgets/PositionLine.cpp b/src/gui/widgets/PositionLine.cpp index 978c94a96c2..a18e9cb8b23 100644 --- a/src/gui/widgets/PositionLine.cpp +++ b/src/gui/widgets/PositionLine.cpp @@ -63,7 +63,7 @@ void PositionLine::paintEvent(QPaintEvent* pe) if (m_hasTailGradient && Engine::getSong()->isPlaying() && (Engine::getSong()->playMode() == Song::Mode_PlaySong || - Engine::getSong()->playMode() == Song::Mode_PlayPattern)) + Engine::getSong()->playMode() == Song::Mode_PlayMidiClip)) { c.setAlpha(60); gradient.setColorAt(w, c); diff --git a/src/gui/widgets/TrackContentWidget.cpp b/src/gui/widgets/TrackContentWidget.cpp index 4c2c105296b..07c94dca4bf 100644 --- a/src/gui/widgets/TrackContentWidget.cpp +++ b/src/gui/widgets/TrackContentWidget.cpp @@ -29,7 +29,7 @@ #include #include -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "BBEditor.h" #include "BBTrackContainer.h" #include "Clipboard.h" @@ -40,7 +40,7 @@ #include "SongEditor.h" #include "StringPairDrag.h" #include "TrackContainerView.h" -#include "TrackContentObjectView.h" +#include "ClipView.h" #include "TrackView.h" @@ -132,41 +132,41 @@ void TrackContentWidget::updateBackground() -/*! \brief Adds a trackContentObjectView to this widget. +/*! \brief Adds a ClipView to this widget. * - * Adds a(nother) trackContentObjectView to our list of views. We also + * Adds a(nother) ClipView to our list of views. We also * check that our position is up-to-date. * - * \param tcov The trackContentObjectView to add. + * \param clipv The ClipView to add. */ -void TrackContentWidget::addTCOView( TrackContentObjectView * tcov ) +void TrackContentWidget::addClipView( ClipView * clipv ) { - TrackContentObject * tco = tcov->getTrackContentObject(); + Clip * clip = clipv->getClip(); - m_tcoViews.push_back( tcov ); + m_clipViews.push_back( clipv ); - tco->saveJournallingState( false ); + clip->saveJournallingState( false ); changePosition(); - tco->restoreJournallingState(); + clip->restoreJournallingState(); } -/*! \brief Removes the given trackContentObjectView to this widget. +/*! \brief Removes the given ClipView from this widget. * - * Removes the given trackContentObjectView from our list of views. + * Removes the given ClipView from our list of views. * - * \param tcov The trackContentObjectView to add. + * \param clipv The ClipView to add. */ -void TrackContentWidget::removeTCOView( TrackContentObjectView * tcov ) +void TrackContentWidget::removeClipView( ClipView * clipv ) { - tcoViewVector::iterator it = std::find( m_tcoViews.begin(), - m_tcoViews.end(), - tcov ); - if( it != m_tcoViews.end() ) + clipViewVector::iterator it = std::find( m_clipViews.begin(), + m_clipViews.end(), + clipv ); + if( it != m_clipViews.end() ) { - m_tcoViews.erase( it ); + m_clipViews.erase( it ); Engine::getSong()->setModified(); } } @@ -174,13 +174,13 @@ void TrackContentWidget::removeTCOView( TrackContentObjectView * tcov ) -/*! \brief Update ourselves by updating all the tCOViews attached. +/*! \brief Update ourselves by updating all the ClipViews attached. * */ void TrackContentWidget::update() { - for( tcoViewVector::iterator it = m_tcoViews.begin(); - it != m_tcoViews.end(); ++it ) + for( clipViewVector::iterator it = m_clipViews.begin(); + it != m_clipViews.end(); ++it ) { ( *it )->setFixedHeight( height() - 1 ); ( *it )->update(); @@ -204,11 +204,11 @@ void TrackContentWidget::changePosition( const TimePos & newPos ) const int curBB = Engine::getBBTrackContainer()->currentBB(); setUpdatesEnabled( false ); - // first show TCO for current BB... - for( tcoViewVector::iterator it = m_tcoViews.begin(); - it != m_tcoViews.end(); ++it ) + // first show Clip for current BB... + for( clipViewVector::iterator it = m_clipViews.begin(); + it != m_clipViews.end(); ++it ) { - if( ( *it )->getTrackContentObject()-> + if( ( *it )->getClip()-> startPosition().getBar() == curBB ) { ( *it )->move( 0, ( *it )->y() ); @@ -221,10 +221,10 @@ void TrackContentWidget::changePosition( const TimePos & newPos ) } } // ...then hide others to avoid flickering - for( tcoViewVector::iterator it = m_tcoViews.begin(); - it != m_tcoViews.end(); ++it ) + for( clipViewVector::iterator it = m_clipViews.begin(); + it != m_clipViews.end(); ++it ) { - if( ( *it )->getTrackContentObject()-> + if( ( *it )->getClip()-> startPosition().getBar() != curBB ) { ( *it )->hide(); @@ -245,31 +245,31 @@ void TrackContentWidget::changePosition( const TimePos & newPos ) const float ppb = m_trackView->trackContainerView()->pixelsPerBar(); setUpdatesEnabled( false ); - for( tcoViewVector::iterator it = m_tcoViews.begin(); - it != m_tcoViews.end(); ++it ) + for( clipViewVector::iterator it = m_clipViews.begin(); + it != m_clipViews.end(); ++it ) { - TrackContentObjectView * tcov = *it; - TrackContentObject * tco = tcov->getTrackContentObject(); + ClipView * clipv = *it; + Clip * clip = clipv->getClip(); - tco->changeLength( tco->length() ); + clip->changeLength( clip->length() ); - const int ts = tco->startPosition(); - const int te = tco->endPosition()-3; + const int ts = clip->startPosition(); + const int te = clip->endPosition()-3; if( ( ts >= begin && ts <= end ) || ( te >= begin && te <= end ) || ( ts <= begin && te >= end ) ) { - tcov->move( static_cast( ( ts - begin ) * ppb / + clipv->move( static_cast( ( ts - begin ) * ppb / TimePos::ticksPerBar() ), - tcov->y() ); - if( !tcov->isVisible() ) + clipv->y() ); + if( !clipv->isVisible() ) { - tcov->show(); + clipv->show(); } } else { - tcov->move( -tcov->width()-10, tcov->y() ); + clipv->move( -clipv->width()-10, clipv->y() ); } } setUpdatesEnabled( true ); @@ -303,14 +303,14 @@ TimePos TrackContentWidget::getPosition( int mouseX ) */ void TrackContentWidget::dragEnterEvent( QDragEnterEvent * dee ) { - TimePos tcoPos = getPosition( dee->pos().x() ); - if( canPasteSelection( tcoPos, dee ) == false ) + TimePos clipPos = getPosition( dee->pos().x() ); + if( canPasteSelection( clipPos, dee ) == false ) { dee->ignore(); } else { - StringPairDrag::processDragEnterEvent( dee, "tco_" + + StringPairDrag::processDragEnterEvent( dee, "clip_" + QString::number( getTrack()->type() ) ); } } @@ -318,24 +318,24 @@ void TrackContentWidget::dragEnterEvent( QDragEnterEvent * dee ) -/*! \brief Returns whether a selection of TCOs can be pasted into this +/*! \brief Returns whether a selection of Clips can be pasted into this * - * \param tcoPos the position of the TCO slot being pasted on + * \param clipPos the position of the Clip slot being pasted on * \param de the DropEvent generated */ -bool TrackContentWidget::canPasteSelection( TimePos tcoPos, const QDropEvent* de ) +bool TrackContentWidget::canPasteSelection( TimePos clipPos, const QDropEvent* de ) { const QMimeData * mimeData = de->mimeData(); // If the source of the DropEvent is the current instance of LMMS we don't allow pasting in the same bar // if it's another instance of LMMS we allow it return de->source() - ? canPasteSelection( tcoPos, mimeData ) - : canPasteSelection( tcoPos, mimeData, true ); + ? canPasteSelection( clipPos, mimeData ) + : canPasteSelection( clipPos, mimeData, true ); } // Overloaded method to make it possible to call this method without a Drag&Drop event -bool TrackContentWidget::canPasteSelection( TimePos tcoPos, const QMimeData* md , bool allowSameBar ) +bool TrackContentWidget::canPasteSelection( TimePos clipPos, const QMimeData* md , bool allowSameBar ) { // For decodeKey() and decodeValue() using namespace Clipboard; @@ -345,20 +345,20 @@ bool TrackContentWidget::canPasteSelection( TimePos tcoPos, const QMimeData* md QString value = decodeValue( md ); // We can only paste into tracks of the same type - if( type != ( "tco_" + QString::number( t->type() ) ) || - m_trackView->trackContainerView()->fixedTCOs() == true ) + if( type != ( "clip_" + QString::number( t->type() ) ) || + m_trackView->trackContainerView()->fixedClips() == true ) { return false; } - // value contains XML needed to reconstruct TCOs and place them + // value contains XML needed to reconstruct Clips and place them DataFile dataFile( value.toUtf8() ); - // Extract the metadata and which TCO was grabbed + // Extract the metadata and which Clip was grabbed QDomElement metadata = dataFile.content().firstChildElement( "copyMetadata" ); - QDomAttr tcoPosAttr = metadata.attributeNode( "grabbedTCOPos" ); - TimePos grabbedTCOPos = tcoPosAttr.value().toInt(); - TimePos grabbedTCOBar = TimePos( grabbedTCOPos.getBar(), 0 ); + QDomAttr clipPosAttr = metadata.attributeNode( "grabbedClipPos" ); + TimePos grabbedClipPos = clipPosAttr.value().toInt(); + TimePos grabbedClipBar = TimePos( grabbedClipPos.getBar(), 0 ); // Extract the track index that was originally clicked QDomAttr tiAttr = metadata.attributeNode( "initialTrackIndex" ); @@ -371,20 +371,20 @@ bool TrackContentWidget::canPasteSelection( TimePos tcoPos, const QMimeData* md // Don't paste if we're on the same bar and allowSameBar is false auto sourceTrackContainerId = metadata.attributeNode( "trackContainerId" ).value().toUInt(); if( !allowSameBar && sourceTrackContainerId == t->trackContainer()->id() && - tcoPos == grabbedTCOBar && currentTrackIndex == initialTrackIndex ) + clipPos == grabbedClipBar && currentTrackIndex == initialTrackIndex ) { return false; } - // Extract the tco data - QDomElement tcoParent = dataFile.content().firstChildElement( "tcos" ); - QDomNodeList tcoNodes = tcoParent.childNodes(); + // Extract the clip data + QDomElement clipParent = dataFile.content().firstChildElement( "tcos" ); //TODO: rename "tcos" to "clips" + QDomNodeList clipNodes = clipParent.childNodes(); - // Determine if all the TCOs will land on a valid track - for( int i = 0; i < tcoNodes.length(); i++ ) + // Determine if all the Clips will land on a valid track + for( int i = 0; i < clipNodes.length(); i++ ) { - QDomElement tcoElement = tcoNodes.item( i ).toElement(); - int trackIndex = tcoElement.attributeNode( "trackIndex" ).value().toInt(); + QDomElement clipElement = clipNodes.item( i ).toElement(); + int trackIndex = clipElement.attributeNode( "trackIndex" ).value().toInt(); int finalTrackIndex = trackIndex + currentTrackIndex - initialTrackIndex; // Track must be in TrackContainer's tracks @@ -394,7 +394,7 @@ bool TrackContentWidget::canPasteSelection( TimePos tcoPos, const QMimeData* md } // Track must be of the same type - auto startTrackType = tcoElement.attributeNode("trackType").value().toInt(); + auto startTrackType = clipElement.attributeNode("trackType").value().toInt(); Track * endTrack = tracks.at( finalTrackIndex ); if( startTrackType != endTrack->type() ) { @@ -405,32 +405,32 @@ bool TrackContentWidget::canPasteSelection( TimePos tcoPos, const QMimeData* md return true; } -/*! \brief Pastes a selection of TCOs onto the track +/*! \brief Pastes a selection of Clips onto the track * - * \param tcoPos the position of the TCO slot being pasted on + * \param clipPos the position of the Clip slot being pasted on * \param de the DropEvent generated */ -bool TrackContentWidget::pasteSelection( TimePos tcoPos, QDropEvent * de ) +bool TrackContentWidget::pasteSelection( TimePos clipPos, QDropEvent * de ) { const QMimeData * mimeData = de->mimeData(); - if( canPasteSelection( tcoPos, de ) == false ) + if( canPasteSelection( clipPos, de ) == false ) { return false; } // We set skipSafetyCheck to true because we already called canPasteSelection - return pasteSelection( tcoPos, mimeData, true ); + return pasteSelection( clipPos, mimeData, true ); } // Overloaded method so we can call it without a Drag&Drop event -bool TrackContentWidget::pasteSelection( TimePos tcoPos, const QMimeData * md, bool skipSafetyCheck ) +bool TrackContentWidget::pasteSelection( TimePos clipPos, const QMimeData * md, bool skipSafetyCheck ) { // For decodeKey() and decodeValue() using namespace Clipboard; // When canPasteSelection was already called before, skipSafetyCheck will skip this - if( !skipSafetyCheck && canPasteSelection( tcoPos, md ) == false ) + if( !skipSafetyCheck && canPasteSelection( clipPos, md ) == false ) { return false; } @@ -440,19 +440,19 @@ bool TrackContentWidget::pasteSelection( TimePos tcoPos, const QMimeData * md, b getTrack()->addJournalCheckPoint(); - // value contains XML needed to reconstruct TCOs and place them + // value contains XML needed to reconstruct Clips and place them DataFile dataFile( value.toUtf8() ); - // Extract the tco data - QDomElement tcoParent = dataFile.content().firstChildElement( "tcos" ); - QDomNodeList tcoNodes = tcoParent.childNodes(); + // Extract the clip data + QDomElement clipParent = dataFile.content().firstChildElement( "tcos" ); //TODO: rename "tcos" to "clips" + QDomNodeList clipNodes = clipParent.childNodes(); // Extract the track index that was originally clicked QDomElement metadata = dataFile.content().firstChildElement( "copyMetadata" ); QDomAttr tiAttr = metadata.attributeNode( "initialTrackIndex" ); int initialTrackIndex = tiAttr.value().toInt(); - QDomAttr tcoPosAttr = metadata.attributeNode( "grabbedTCOPos" ); - TimePos grabbedTCOPos = tcoPosAttr.value().toInt(); + QDomAttr clipPosAttr = metadata.attributeNode( "grabbedClipPos" ); + TimePos grabbedClipPos = clipPosAttr.value().toInt(); // Snap the mouse position to the beginning of the dropped bar, in ticks const TrackContainer::TrackList tracks = getTrack()->trackContainer()->tracks(); @@ -470,56 +470,56 @@ bool TrackContentWidget::pasteSelection( TimePos tcoPos, const QMimeData * md, b } - // TODO -- Need to draw the hovericon either way, or ghost the TCOs + // TODO -- Need to draw the hovericon either way, or ghost the Clips // onto their final position. float snapSize = getGUI()->songEditor()->m_editor->getSnapSize(); - // All patterns should be offset the same amount as the grabbed pattern - TimePos offset = TimePos(tcoPos - grabbedTCOPos); + // All clips should be offset the same amount as the grabbed clip + TimePos offset = TimePos(clipPos - grabbedClipPos); // Users expect clips to "fall" backwards, so bias the offset offset -= TimePos::ticksPerBar() * snapSize / 2; // The offset is quantized (rather than the positions) to preserve fine adjustments offset = offset.quantize(snapSize); - // Get the leftmost TCO and fix the offset if it reaches below bar 0 - TimePos leftmostPos = grabbedTCOPos; - for(int i = 0; i < tcoNodes.length(); ++i) + // Get the leftmost Clip and fix the offset if it reaches below bar 0 + TimePos leftmostPos = grabbedClipPos; + for(int i = 0; i < clipNodes.length(); ++i) { - QDomElement outerTCOElement = tcoNodes.item(i).toElement(); - QDomElement tcoElement = outerTCOElement.firstChildElement(); + QDomElement outerClipElement = clipNodes.item(i).toElement(); + QDomElement clipElement = outerClipElement.firstChildElement(); - TimePos pos = tcoElement.attributeNode("pos").value().toInt(); + TimePos pos = clipElement.attributeNode("pos").value().toInt(); if(pos < leftmostPos) { leftmostPos = pos; } } - // Fix offset if it sets the left most TCO to a negative position + // Fix offset if it sets the left most Clip to a negative position offset = std::max(offset.getTicks(), -leftmostPos.getTicks()); - for( int i = 0; isongEditor()->m_editor->getSnapSize(); if (offset == 0 && initialTrackIndex == currentTrackIndex) { pos += shift; } - TrackContentObject * tco = t->createTCO( pos ); - tco->restoreState( tcoElement ); - tco->movePosition(pos); // Because we restored the state, we need to move the TCO again. + Clip * clip = t->createClip( pos ); + clip->restoreState( clipElement ); + clip->movePosition(pos); // Because we restored the state, we need to move the Clip again. if( wasSelection ) { - tco->selectViewOnCreate( true ); + clip->selectViewOnCreate( true ); } } - AutomationPattern::resolveAllIDs(); + AutomationClip::resolveAllIDs(); return true; } @@ -531,8 +531,8 @@ bool TrackContentWidget::pasteSelection( TimePos tcoPos, const QMimeData * md, b */ void TrackContentWidget::dropEvent( QDropEvent * de ) { - TimePos tcoPos = TimePos( getPosition( de->pos().x() ) ); - if( pasteSelection( tcoPos, de ) == true ) + TimePos clipPos = TimePos( getPosition( de->pos().x() ) ); + if( pasteSelection( clipPos, de ) == true ) { de->accept(); } @@ -548,7 +548,7 @@ void TrackContentWidget::dropEvent( QDropEvent * de ) void TrackContentWidget::mousePressEvent( QMouseEvent * me ) { // Enable box select if control is held when clicking an empty space - // (If we had clicked a TCO it would have intercepted the mouse event) + // (If we had clicked a Clip it would have intercepted the mouse event) if( me->modifiers() & Qt::ControlModifier ){ getGUI()->songEditor()->m_editor->setEditMode(SongEditor::EditMode::SelectMode); } @@ -562,9 +562,9 @@ void TrackContentWidget::mousePressEvent( QMouseEvent * me ) { QWidget::mousePressEvent( me ); } - // For an unmodified click, create a new TCO + // For an unmodified click, create a new Clip else if( me->button() == Qt::LeftButton && - !m_trackView->trackContainerView()->fixedTCOs() ) + !m_trackView->trackContainerView()->fixedClips() ) { QVector so = m_trackView->trackContainerView()->rubberBand()->selectedObjects(); for( int i = 0; i < so.count(); ++i ) @@ -574,7 +574,7 @@ void TrackContentWidget::mousePressEvent( QMouseEvent * me ) getTrack()->addJournalCheckPoint(); const TimePos pos = getPosition( me->x() ).getBar() * TimePos::ticksPerBar(); - getTrack()->createTCO(pos); + getTrack()->createClip(pos); } } @@ -658,7 +658,7 @@ void TrackContentWidget::contextMenuEvent( QContextMenuEvent * cme ) return; } - // If we don't have TCO data in the clipboard there's no need to create this menu + // If we don't have Clip data in the clipboard there's no need to create this menu // since "paste" is the only action at the moment. if( ! hasFormat( MimeType::StringPair ) ) { @@ -683,9 +683,9 @@ void TrackContentWidget::contextMenuAction( QContextMenuEvent * cme, ContextMenu { case Paste: // Paste the selection on the TimePos of the context menu event - TimePos tcoPos = getPosition( cme->x() ); + TimePos clipPos = getPosition( cme->x() ); - pasteSelection( tcoPos, getMimeData() ); + pasteSelection( clipPos, getMimeData() ); break; } } diff --git a/src/gui/widgets/TrackOperationsWidget.cpp b/src/gui/widgets/TrackOperationsWidget.cpp index e7a9281d189..8d192eafd64 100644 --- a/src/gui/widgets/TrackOperationsWidget.cpp +++ b/src/gui/widgets/TrackOperationsWidget.cpp @@ -31,7 +31,7 @@ #include #include -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "AutomationTrackView.h" #include "ColorChooser.h" #include "ConfigManager.h" @@ -246,13 +246,13 @@ void TrackOperationsWidget::cloneTrack() } -/*! \brief Clear this track - clears all TCOs from the track */ +/*! \brief Clear this track - clears all Clips from the track */ void TrackOperationsWidget::clearTrack() { Track * t = m_trackView->getTrack(); t->addJournalCheckPoint(); t->lock(); - t->deleteTCOs(); + t->deleteClips(); t->unlock(); } @@ -300,13 +300,13 @@ void TrackOperationsWidget::randomizeTrackColor() Engine::getSong()->setModified(); } -void TrackOperationsWidget::resetTCOColors() +void TrackOperationsWidget::resetClipColors() { auto track = m_trackView->getTrack(); track->addJournalCheckPoint(); - for (auto tco: track->getTCOs()) + for (auto clip: track->getClips()) { - tco->useCustomClipColor(false); + clip->useCustomClipColor(false); } Engine::getSong()->setModified(); } @@ -319,7 +319,7 @@ void TrackOperationsWidget::resetTCOColors() * For all track types, we have the Clone and Remove options. * For instrument-tracks we also offer the MIDI-control-menu * For automation tracks, extra options: turn on/off recording - * on all TCOs (same should be added for sample tracks when + * on all Clips (same should be added for sample tracks when * sampletrack recording is implemented) */ void TrackOperationsWidget::updateMenu() @@ -333,7 +333,7 @@ void TrackOperationsWidget::updateMenu() tr( "Remove this track" ), this, SLOT( removeTrack() ) ); - if( ! m_trackView->trackContainerView()->fixedTCOs() ) + if( ! m_trackView->trackContainerView()->fixedClips() ) { toMenu->addAction( tr( "Clear this track" ), this, SLOT( clearTrack() ) ); } @@ -361,7 +361,7 @@ void TrackOperationsWidget::updateMenu() colorMenu->addAction(tr("Reset"), this, SLOT(resetTrackColor())); colorMenu->addAction(tr("Pick random"), this, SLOT(randomizeTrackColor())); colorMenu->addSeparator(); - colorMenu->addAction(tr("Reset clip colors"), this, SLOT(resetTCOColors())); + colorMenu->addAction(tr("Reset clip colors"), this, SLOT(resetClipColors())); } @@ -370,9 +370,9 @@ void TrackOperationsWidget::toggleRecording( bool on ) AutomationTrackView * atv = dynamic_cast( m_trackView ); if( atv ) { - for( TrackContentObject * tco : atv->getTrack()->getTCOs() ) + for( Clip * clip : atv->getTrack()->getClips() ) { - AutomationPattern * ap = dynamic_cast( tco ); + AutomationClip * ap = dynamic_cast( clip ); if( ap ) { ap->setRecording( on ); } } atv->update(); diff --git a/src/tracks/AutomationTrack.cpp b/src/tracks/AutomationTrack.cpp index 034ad4251d0..dfdbb32eec8 100644 --- a/src/tracks/AutomationTrack.cpp +++ b/src/tracks/AutomationTrack.cpp @@ -25,7 +25,7 @@ */ #include "AutomationTrackView.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" AutomationTrack::AutomationTrack( TrackContainer* tc, bool _hidden ) : @@ -35,7 +35,7 @@ AutomationTrack::AutomationTrack( TrackContainer* tc, bool _hidden ) : } bool AutomationTrack::play( const TimePos & time_start, const fpp_t _frames, - const f_cnt_t _frame_base, int _tco_num ) + const f_cnt_t _frame_base, int _clip_num ) { return false; } @@ -51,9 +51,9 @@ TrackView * AutomationTrack::createView( TrackContainerView* tcv ) -TrackContentObject* AutomationTrack::createTCO(const TimePos & pos) +Clip* AutomationTrack::createClip(const TimePos & pos) { - AutomationPattern* p = new AutomationPattern(this); + AutomationClip* p = new AutomationClip(this); p->movePosition(pos); return p; } diff --git a/src/tracks/BBTrack.cpp b/src/tracks/BBTrack.cpp index 9df773ddc0d..4c833f4c89c 100644 --- a/src/tracks/BBTrack.cpp +++ b/src/tracks/BBTrack.cpp @@ -43,7 +43,7 @@ BBTrack::BBTrack( TrackContainer* tc ) : s_infoMap[this] = bbNum; setName( tr( "Beat/Bassline %1" ).arg( bbNum ) ); - Engine::getBBTrackContainer()->createTCOsForBB( bbNum ); + Engine::getBBTrackContainer()->createClipsForBB( bbNum ); Engine::getBBTrackContainer()->setCurrentBB( bbNum ); Engine::getBBTrackContainer()->updateComboBox(); @@ -82,31 +82,31 @@ BBTrack::~BBTrack() -// play _frames frames of given TCO within starting with _start +// play _frames frames of given Clip within starting with _start bool BBTrack::play( const TimePos & _start, const fpp_t _frames, - const f_cnt_t _offset, int _tco_num ) + const f_cnt_t _offset, int _clip_num ) { if( isMuted() ) { return false; } - if( _tco_num >= 0 ) + if( _clip_num >= 0 ) { return Engine::getBBTrackContainer()->play( _start, _frames, _offset, s_infoMap[this] ); } - tcoVector tcos; - getTCOsInRange( tcos, _start, _start + static_cast( _frames / Engine::framesPerTick() ) ); + clipVector clips; + getClipsInRange( clips, _start, _start + static_cast( _frames / Engine::framesPerTick() ) ); - if( tcos.size() == 0 ) + if( clips.size() == 0 ) { return false; } TimePos lastPosition; TimePos lastLen; - for( tcoVector::iterator it = tcos.begin(); it != tcos.end(); ++it ) + for( clipVector::iterator it = clips.begin(); it != clips.end(); ++it ) { if( !( *it )->isMuted() && ( *it )->startPosition() >= lastPosition ) @@ -134,11 +134,11 @@ TrackView * BBTrack::createView( TrackContainerView* tcv ) -TrackContentObject* BBTrack::createTCO(const TimePos & pos) +Clip* BBTrack::createClip(const TimePos & pos) { - BBTCO* bbtco = new BBTCO(this); - bbtco->movePosition(pos); - return bbtco; + BBClip* bbclip = new BBClip(this); + bbclip->movePosition(pos); + return bbclip; } @@ -179,13 +179,13 @@ void BBTrack::loadTrackSpecificSettings( const QDomElement & _this ) const int dst = s_infoMap[this]; TrackContainer::TrackList tl = Engine::getBBTrackContainer()->tracks(); - // copy TCOs of all tracks from source BB (at bar "src") to destination - // TCOs (which are created if they do not exist yet) + // copy Clips of all tracks from source BB (at bar "src") to destination + // Clips (which are created if they do not exist yet) for( TrackContainer::TrackList::iterator it = tl.begin(); it != tl.end(); ++it ) { - TrackContentObject::copyStateTo( ( *it )->getTCO( src ), - ( *it )->getTCO( dst ) ); + Clip::copyStateTo( ( *it )->getClip( src ), + ( *it )->getClip( dst ) ); } setName( tr( "Clone of %1" ).arg( _this.parentNode().toElement().attribute( "name" ) ) ); diff --git a/src/tracks/CMakeLists.txt b/src/tracks/CMakeLists.txt index 158588318ac..a9fd83e908d 100644 --- a/src/tracks/CMakeLists.txt +++ b/src/tracks/CMakeLists.txt @@ -3,7 +3,7 @@ set(LMMS_SRCS tracks/AutomationTrack.cpp tracks/BBTrack.cpp tracks/InstrumentTrack.cpp - tracks/Pattern.cpp + tracks/MidiClip.cpp tracks/SampleTrack.cpp PARENT_SCOPE diff --git a/src/tracks/InstrumentTrack.cpp b/src/tracks/InstrumentTrack.cpp index f856c2b03ae..1891f9a4f5a 100644 --- a/src/tracks/InstrumentTrack.cpp +++ b/src/tracks/InstrumentTrack.cpp @@ -24,7 +24,7 @@ #include "InstrumentTrack.h" #include "AudioEngine.h" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "BBTrack.h" #include "ConfigManager.h" #include "ControllerConnection.h" @@ -33,8 +33,8 @@ #include "InstrumentTrackView.h" #include "Instrument.h" #include "MidiClient.h" +#include "MidiClip.h" #include "MixHelpers.h" -#include "Pattern.h" #include "Song.h" @@ -214,7 +214,7 @@ InstrumentTrack::~InstrumentTrack() void InstrumentTrack::processAudioBuffer( sampleFrame* buf, const fpp_t frames, NotePlayHandle* n ) { // we must not play the sound if this InstrumentTrack is muted... - if( isMuted() || ( Engine::getSong()->playMode() != Song::Mode_PlayPattern && + if( isMuted() || ( Engine::getSong()->playMode() != Song::Mode_PlayMidiClip && n && n->isBbTrackMuted() ) || ! m_instrument ) { return; @@ -679,7 +679,7 @@ void InstrumentTrack::removeMidiPortNode( DataFile & _dataFile ) bool InstrumentTrack::play( const TimePos & _start, const fpp_t _frames, - const f_cnt_t _offset, int _tco_num ) + const f_cnt_t _offset, int _clip_num ) { if( ! m_instrument || ! tryLock() ) { @@ -687,20 +687,20 @@ bool InstrumentTrack::play( const TimePos & _start, const fpp_t _frames, } const float frames_per_tick = Engine::framesPerTick(); - tcoVector tcos; + clipVector clips; ::BBTrack * bb_track = nullptr; - if( _tco_num >= 0 ) + if( _clip_num >= 0 ) { - TrackContentObject * tco = getTCO( _tco_num ); - tcos.push_back( tco ); + Clip * clip = getClip( _clip_num ); + clips.push_back( clip ); if (trackContainer() == (TrackContainer*)Engine::getBBTrackContainer()) { - bb_track = BBTrack::findBBTrack( _tco_num ); + bb_track = BBTrack::findBBTrack( _clip_num ); } } else { - getTCOsInRange( tcos, _start, _start + static_cast( + getClipsInRange( clips, _start, _start + static_cast( _frames / frames_per_tick ) ); } @@ -711,7 +711,7 @@ bool InstrumentTrack::play( const TimePos & _start, const fpp_t _frames, ( *it )->processTimePos( _start ); } - if ( tcos.size() == 0 ) + if ( clips.size() == 0 ) { unlock(); return false; @@ -719,25 +719,25 @@ bool InstrumentTrack::play( const TimePos & _start, const fpp_t _frames, bool played_a_note = false; // will be return variable - for( tcoVector::Iterator it = tcos.begin(); it != tcos.end(); ++it ) + for( clipVector::Iterator it = clips.begin(); it != clips.end(); ++it ) { - Pattern* p = dynamic_cast( *it ); - // everything which is not a pattern won't be played - // A pattern playing in the Piano Roll window will always play - if(p == nullptr || - (Engine::getSong()->playMode() != Song::Mode_PlayPattern + MidiClip* c = dynamic_cast( *it ); + // everything which is not a MIDI clip won't be played + // A MIDI clip playing in the Piano Roll window will always play + if(c == nullptr || + (Engine::getSong()->playMode() != Song::Mode_PlayMidiClip && (*it)->isMuted())) { continue; } TimePos cur_start = _start; - if( _tco_num < 0 ) + if( _clip_num < 0 ) { - cur_start -= p->startPosition(); + cur_start -= c->startPosition(); } - // get all notes from the given pattern... - const NoteVector & notes = p->notes(); + // get all notes from the given clip... + const NoteVector & notes = c->notes(); // ...and set our index to zero NoteVector::ConstIterator nit = notes.begin(); @@ -764,11 +764,11 @@ bool InstrumentTrack::play( const TimePos & _start, const fpp_t _frames, NotePlayHandle* notePlayHandle = NotePlayHandleManager::acquire( this, _offset, note_frames, *cur_note ); notePlayHandle->setBBTrack( bb_track ); // are we playing global song? - if( _tco_num < 0 ) + if( _clip_num < 0 ) { - // then set song-global offset of pattern in order to + // then set song-global offset of clip in order to // properly perform the note detuning - notePlayHandle->setSongGlobalParentOffset( p->startPosition() ); + notePlayHandle->setSongGlobalParentOffset( c->startPosition() ); } Engine::audioEngine()->addPlayHandle( notePlayHandle ); @@ -783,9 +783,9 @@ bool InstrumentTrack::play( const TimePos & _start, const fpp_t _frames, -TrackContentObject* InstrumentTrack::createTCO(const TimePos & pos) +Clip* InstrumentTrack::createClip(const TimePos & pos) { - Pattern* p = new Pattern(this); + MidiClip* p = new MidiClip(this); p->movePosition(pos); return p; } @@ -943,7 +943,7 @@ void InstrumentTrack::loadTrackSpecificSettings( const QDomElement & thisElement // compat code - if node-name doesn't match any known // one, we assume that it is an instrument-plugin // which we'll try to load - else if(AutomationPattern::classNodeName() != node.nodeName() && + else if(AutomationClip::classNodeName() != node.nodeName() && ControllerConnection::classNodeName() != node.nodeName() && !node.toElement().hasAttribute( "id" )) { diff --git a/src/tracks/Pattern.cpp b/src/tracks/MidiClip.cpp similarity index 76% rename from src/tracks/Pattern.cpp rename to src/tracks/MidiClip.cpp index 215fab7746e..307e62198e1 100644 --- a/src/tracks/Pattern.cpp +++ b/src/tracks/MidiClip.cpp @@ -1,5 +1,5 @@ /* - * Pattern.cpp - implementation of class pattern which holds notes + * MidiClip.cpp - implementation of class MidiClip, which holds notes * * Copyright (c) 2004-2014 Tobias Doerffel * Copyright (c) 2005-2007 Danny McRae @@ -23,7 +23,7 @@ * */ -#include "Pattern.h" +#include "MidiClip.h" #include "BBTrackContainer.h" #include "GuiApplication.h" @@ -33,17 +33,17 @@ #include -QPixmap * PatternView::s_stepBtnOn0 = nullptr; -QPixmap * PatternView::s_stepBtnOn200 = nullptr; -QPixmap * PatternView::s_stepBtnOff = nullptr; -QPixmap * PatternView::s_stepBtnOffLight = nullptr; +QPixmap * MidiClipView::s_stepBtnOn0 = nullptr; +QPixmap * MidiClipView::s_stepBtnOn200 = nullptr; +QPixmap * MidiClipView::s_stepBtnOff = nullptr; +QPixmap * MidiClipView::s_stepBtnOffLight = nullptr; -Pattern::Pattern( InstrumentTrack * _instrument_track ) : - TrackContentObject( _instrument_track ), +MidiClip::MidiClip( InstrumentTrack * _instrument_track ) : + Clip( _instrument_track ), m_instrumentTrack( _instrument_track ), - m_patternType( BeatPattern ), + m_clipType( BeatClip ), m_steps( TimePos::stepsPerBar() ) { if( _instrument_track->trackContainer() @@ -58,10 +58,10 @@ Pattern::Pattern( InstrumentTrack * _instrument_track ) : -Pattern::Pattern( const Pattern& other ) : - TrackContentObject( other.m_instrumentTrack ), +MidiClip::MidiClip( const MidiClip& other ) : + Clip( other.m_instrumentTrack ), m_instrumentTrack( other.m_instrumentTrack ), - m_patternType( other.m_patternType ), + m_clipType( other.m_clipType ), m_steps( other.m_steps ) { for( NoteVector::ConstIterator it = other.m_notes.begin(); it != other.m_notes.end(); ++it ) @@ -85,9 +85,9 @@ Pattern::Pattern( const Pattern& other ) : } -Pattern::~Pattern() +MidiClip::~MidiClip() { - emit destroyedPattern( this ); + emit destroyedMidiClip( this ); for( NoteVector::Iterator it = m_notes.begin(); it != m_notes.end(); ++it ) @@ -101,7 +101,7 @@ Pattern::~Pattern() -void Pattern::resizeToFirstTrack() +void MidiClip::resizeToFirstTrack() { // Resize this track to be the same as existing tracks in the BB const TrackContainer::TrackList & tracks = @@ -112,10 +112,10 @@ void Pattern::resizeToFirstTrack() { if(tracks.at(trackID) != m_instrumentTrack) { - unsigned int currentTCO = m_instrumentTrack-> - getTCOs().indexOf(this); - m_steps = static_cast - (tracks.at(trackID)->getTCO(currentTCO)) + unsigned int currentClip = m_instrumentTrack-> + getClips().indexOf(this); + m_steps = static_cast + (tracks.at(trackID)->getClip(currentClip)) ->m_steps; } break; @@ -126,7 +126,7 @@ void Pattern::resizeToFirstTrack() -void Pattern::init() +void MidiClip::init() { connect( Engine::getSong(), SIGNAL( timeSignatureChanged( int, int ) ), this, SLOT( changeTimeSignature() ) ); @@ -139,11 +139,11 @@ void Pattern::init() -void Pattern::updateLength() +void MidiClip::updateLength() { - if( m_patternType == BeatPattern ) + if( m_clipType == BeatClip ) { - changeLength( beatPatternLength() ); + changeLength( beatClipLength() ); updateBBTrack(); return; } @@ -167,7 +167,7 @@ void Pattern::updateLength() -TimePos Pattern::beatPatternLength() const +TimePos MidiClip::beatClipLength() const { tick_t max_length = TimePos::ticksPerBar(); @@ -193,7 +193,7 @@ TimePos Pattern::beatPatternLength() const -Note * Pattern::addNote( const Note & _new_note, const bool _quant_pos ) +Note * MidiClip::addNote( const Note & _new_note, const bool _quant_pos ) { Note * new_note = new Note( _new_note ); if( _quant_pos && getGUI()->pianoRoll() ) @@ -216,7 +216,7 @@ Note * Pattern::addNote( const Note & _new_note, const bool _quant_pos ) -void Pattern::removeNote( Note * _note_to_del ) +void MidiClip::removeNote( Note * _note_to_del ) { instrumentTrack()->lock(); NoteVector::Iterator it = m_notes.begin(); @@ -241,7 +241,7 @@ void Pattern::removeNote( Note * _note_to_del ) // returns a pointer to the note at specified step, or NULL if note doesn't exist -Note * Pattern::noteAtStep( int _step ) +Note * MidiClip::noteAtStep( int _step ) { for( NoteVector::Iterator it = m_notes.begin(); it != m_notes.end(); ++it ) @@ -257,7 +257,7 @@ Note * Pattern::noteAtStep( int _step ) -void Pattern::rearrangeAllNotes() +void MidiClip::rearrangeAllNotes() { // sort notes by start time std::sort(m_notes.begin(), m_notes.end(), Note::lessThan); @@ -265,7 +265,7 @@ void Pattern::rearrangeAllNotes() -void Pattern::clearNotes() +void MidiClip::clearNotes() { instrumentTrack()->lock(); for( NoteVector::Iterator it = m_notes.begin(); it != m_notes.end(); @@ -283,7 +283,7 @@ void Pattern::clearNotes() -Note * Pattern::addStepNote( int step ) +Note * MidiClip::addStepNote( int step ) { return addNote( Note( TimePos( -DefaultTicksPerBar ), TimePos::stepPosition( step ) ), false ); @@ -292,7 +292,7 @@ Note * Pattern::addStepNote( int step ) -void Pattern::setStep( int step, bool enabled ) +void MidiClip::setStep( int step, bool enabled ) { if( enabled ) { @@ -312,7 +312,7 @@ void Pattern::setStep( int step, bool enabled ) -void Pattern::splitNotes(NoteVector notes, TimePos pos) +void MidiClip::splitNotes(NoteVector notes, TimePos pos) { if (notes.empty()) { return; } @@ -346,47 +346,47 @@ void Pattern::splitNotes(NoteVector notes, TimePos pos) -void Pattern::setType( PatternTypes _new_pattern_type ) +void MidiClip::setType( MidiClipTypes _new_clip_type ) { - if( _new_pattern_type == BeatPattern || - _new_pattern_type == MelodyPattern ) + if( _new_clip_type == BeatClip || + _new_clip_type == MelodyClip ) { - m_patternType = _new_pattern_type; + m_clipType = _new_clip_type; } } -void Pattern::checkType() +void MidiClip::checkType() { NoteVector::Iterator it = m_notes.begin(); while( it != m_notes.end() ) { if( ( *it )->length() > 0 ) { - setType( MelodyPattern ); + setType( MelodyClip ); return; } ++it; } - setType( BeatPattern ); + setType( BeatClip ); } -void Pattern::saveSettings( QDomDocument & _doc, QDomElement & _this ) +void MidiClip::saveSettings( QDomDocument & _doc, QDomElement & _this ) { - _this.setAttribute( "type", m_patternType ); + _this.setAttribute( "type", m_clipType ); _this.setAttribute( "name", name() ); if( usesCustomClipColor() ) { _this.setAttribute( "color", color().name() ); } - // as the target of copied/dragged pattern is always an existing - // pattern, we must not store actual position, instead we store -1 + // as the target of copied/dragged MIDI clip is always an existing + // MIDI clip, we must not store actual position, instead we store -1 // which tells loadSettings() not to mess around with position if( _this.parentNode().nodeName() == "clipboard" || _this.parentNode().nodeName() == "dnddata" ) @@ -411,9 +411,9 @@ void Pattern::saveSettings( QDomDocument & _doc, QDomElement & _this ) -void Pattern::loadSettings( const QDomElement & _this ) +void MidiClip::loadSettings( const QDomElement & _this ) { - m_patternType = static_cast( _this.attribute( "type" + m_clipType = static_cast( _this.attribute( "type" ).toInt() ); setName( _this.attribute( "name" ) ); @@ -466,33 +466,33 @@ void Pattern::loadSettings( const QDomElement & _this ) -Pattern * Pattern::previousPattern() const +MidiClip * MidiClip::previousMidiClip() const { - return adjacentPatternByOffset(-1); + return adjacentMidiClipByOffset(-1); } -Pattern * Pattern::nextPattern() const +MidiClip * MidiClip::nextMidiClip() const { - return adjacentPatternByOffset(1); + return adjacentMidiClipByOffset(1); } -Pattern * Pattern::adjacentPatternByOffset(int offset) const +MidiClip * MidiClip::adjacentMidiClipByOffset(int offset) const { - QVector tcos = m_instrumentTrack->getTCOs(); - int tcoNum = m_instrumentTrack->getTCONum(this); - return dynamic_cast(tcos.value(tcoNum + offset, nullptr)); + QVector clips = m_instrumentTrack->getClips(); + int clipNum = m_instrumentTrack->getClipNum(this); + return dynamic_cast(clips.value(clipNum + offset, nullptr)); } -void Pattern::clear() +void MidiClip::clear() { addJournalCheckPoint(); clearNotes(); @@ -501,14 +501,14 @@ void Pattern::clear() -void Pattern::addSteps() +void MidiClip::addSteps() { m_steps += TimePos::stepsPerBar(); updateLength(); emit dataChanged(); } -void Pattern::cloneSteps() +void MidiClip::cloneSteps() { int oldLength = m_steps; m_steps *= 2; // cloning doubles the track @@ -532,7 +532,7 @@ void Pattern::cloneSteps() -void Pattern::removeSteps() +void MidiClip::removeSteps() { int n = TimePos::stepsPerBar(); if( n < m_steps ) @@ -550,15 +550,15 @@ void Pattern::removeSteps() -TrackContentObjectView * Pattern::createView( TrackView * _tv ) +ClipView * MidiClip::createView( TrackView * _tv ) { - return new PatternView( this, _tv ); + return new MidiClipView( this, _tv ); } -void Pattern::updateBBTrack() +void MidiClip::updateBBTrack() { if( getTrack()->trackContainer() == Engine::getBBTrackContainer() ) { @@ -567,7 +567,7 @@ void Pattern::updateBBTrack() if( getGUI() != nullptr && getGUI()->pianoRoll() - && getGUI()->pianoRoll()->currentPattern() == this ) + && getGUI()->pianoRoll()->currentMidiClip() == this ) { getGUI()->pianoRoll()->update(); } @@ -576,7 +576,7 @@ void Pattern::updateBBTrack() -bool Pattern::empty() +bool MidiClip::empty() { for( NoteVector::ConstIterator it = m_notes.begin(); it != m_notes.end(); ++it ) @@ -592,7 +592,7 @@ bool Pattern::empty() -void Pattern::changeTimeSignature() +void MidiClip::changeTimeSignature() { TimePos last_pos = TimePos::ticksPerBar() - 1; for( NoteVector::ConstIterator cit = m_notes.begin(); @@ -608,4 +608,4 @@ void Pattern::changeTimeSignature() m_steps = qMax( TimePos::stepsPerBar(), last_pos.getBar() * TimePos::stepsPerBar() ); updateLength(); -} \ No newline at end of file +} diff --git a/src/tracks/SampleTrack.cpp b/src/tracks/SampleTrack.cpp index b09662d9113..22f9c18a046 100644 --- a/src/tracks/SampleTrack.cpp +++ b/src/tracks/SampleTrack.cpp @@ -61,16 +61,16 @@ SampleTrack::~SampleTrack() bool SampleTrack::play( const TimePos & _start, const fpp_t _frames, - const f_cnt_t _offset, int _tco_num ) + const f_cnt_t _offset, int _clip_num ) { m_audioPort.effects()->startRunning(); - bool played_a_note = false; // will be return variable + bool played_a_note = false; // will be return variable - tcoVector tcos; + clipVector clips; ::BBTrack * bb_track = nullptr; - if( _tco_num >= 0 ) + if( _clip_num >= 0 ) { - if (_start > getTCO(_tco_num)->length()) + if (_start > getClip(_clip_num)->length()) { setPlaying(false); } @@ -78,55 +78,55 @@ bool SampleTrack::play( const TimePos & _start, const fpp_t _frames, { return false; } - tcos.push_back( getTCO( _tco_num ) ); + clips.push_back( getClip( _clip_num ) ); if (trackContainer() == (TrackContainer*)Engine::getBBTrackContainer()) { - bb_track = BBTrack::findBBTrack( _tco_num ); + bb_track = BBTrack::findBBTrack( _clip_num ); setPlaying(true); } } else { bool nowPlaying = false; - for( int i = 0; i < numOfTCOs(); ++i ) + for( int i = 0; i < numOfClips(); ++i ) { - TrackContentObject * tco = getTCO( i ); - SampleTCO * sTco = dynamic_cast( tco ); + Clip * clip = getClip( i ); + SampleClip * sClip = dynamic_cast( clip ); - if( _start >= sTco->startPosition() && _start < sTco->endPosition() ) + if( _start >= sClip->startPosition() && _start < sClip->endPosition() ) { - if( sTco->isPlaying() == false && _start >= (sTco->startPosition() + sTco->startTimeOffset()) ) + if( sClip->isPlaying() == false && _start >= (sClip->startPosition() + sClip->startTimeOffset()) ) { - auto bufferFramesPerTick = Engine::framesPerTick (sTco->sampleBuffer ()->sampleRate ()); - f_cnt_t sampleStart = bufferFramesPerTick * ( _start - sTco->startPosition() - sTco->startTimeOffset() ); - f_cnt_t tcoFrameLength = bufferFramesPerTick * ( sTco->endPosition() - sTco->startPosition() - sTco->startTimeOffset() ); - f_cnt_t sampleBufferLength = sTco->sampleBuffer()->frames(); - //if the Tco smaller than the sample length we play only until Tco end + auto bufferFramesPerTick = Engine::framesPerTick (sClip->sampleBuffer ()->sampleRate ()); + f_cnt_t sampleStart = bufferFramesPerTick * ( _start - sClip->startPosition() - sClip->startTimeOffset() ); + f_cnt_t clipFrameLength = bufferFramesPerTick * ( sClip->endPosition() - sClip->startPosition() - sClip->startTimeOffset() ); + f_cnt_t sampleBufferLength = sClip->sampleBuffer()->frames(); + //if the Clip smaller than the sample length we play only until Clip end //else we play the sample to the end but nothing more - f_cnt_t samplePlayLength = tcoFrameLength > sampleBufferLength ? sampleBufferLength : tcoFrameLength; + f_cnt_t samplePlayLength = clipFrameLength > sampleBufferLength ? sampleBufferLength : clipFrameLength; //we only play within the sampleBuffer limits if( sampleStart < sampleBufferLength ) { - sTco->setSampleStartFrame( sampleStart ); - sTco->setSamplePlayLength( samplePlayLength ); - tcos.push_back( sTco ); - sTco->setIsPlaying( true ); + sClip->setSampleStartFrame( sampleStart ); + sClip->setSamplePlayLength( samplePlayLength ); + clips.push_back( sClip ); + sClip->setIsPlaying( true ); nowPlaying = true; } } } else { - sTco->setIsPlaying( false ); + sClip->setIsPlaying( false ); } - nowPlaying = nowPlaying || sTco->isPlaying(); + nowPlaying = nowPlaying || sClip->isPlaying(); } setPlaying(nowPlaying); } - for( tcoVector::Iterator it = tcos.begin(); it != tcos.end(); ++it ) + for( clipVector::Iterator it = clips.begin(); it != clips.end(); ++it ) { - SampleTCO * st = dynamic_cast( *it ); + SampleClip * st = dynamic_cast( *it ); if( !st->isMuted() ) { PlayHandle* handle; @@ -167,11 +167,11 @@ TrackView * SampleTrack::createView( TrackContainerView* tcv ) -TrackContentObject * SampleTrack::createTCO(const TimePos & pos) +Clip * SampleTrack::createClip(const TimePos & pos) { - SampleTCO * sTco = new SampleTCO(this); - sTco->movePosition(pos); - return sTco; + SampleClip * sClip = new SampleClip(this); + sClip->movePosition(pos); + return sClip; } @@ -216,22 +216,22 @@ void SampleTrack::loadTrackSpecificSettings( const QDomElement & _this ) -void SampleTrack::updateTcos() +void SampleTrack::updateClips() { Engine::audioEngine()->removePlayHandlesOfTypes( this, PlayHandle::TypeSamplePlayHandle ); - setPlayingTcos( false ); + setPlayingClips( false ); } -void SampleTrack::setPlayingTcos( bool isPlaying ) +void SampleTrack::setPlayingClips( bool isPlaying ) { - for( int i = 0; i < numOfTCOs(); ++i ) + for( int i = 0; i < numOfClips(); ++i ) { - TrackContentObject * tco = getTCO( i ); - SampleTCO * sTco = dynamic_cast( tco ); - sTco->setIsPlaying( isPlaying ); + Clip * clip = getClip( i ); + SampleClip * sClip = dynamic_cast( clip ); + sClip->setIsPlaying( isPlaying ); } } diff --git a/tests/src/tracks/AutomationTrackTest.cpp b/tests/src/tracks/AutomationTrackTest.cpp index f86bfe44d2b..4df159604b2 100644 --- a/tests/src/tracks/AutomationTrackTest.cpp +++ b/tests/src/tracks/AutomationTrackTest.cpp @@ -26,13 +26,13 @@ #include "QCoreApplication" -#include "AutomationPattern.h" +#include "AutomationClip.h" #include "AutomationTrack.h" #include "BBTrack.h" #include "BBTrackContainer.h" #include "DetuningHelper.h" #include "InstrumentTrack.h" -#include "Pattern.h" +#include "MidiClip.h" #include "TrackContainer.h" #include "Engine.h" @@ -46,59 +46,59 @@ private slots: { } - void testPatternLinear() + void testClipLinear() { - AutomationPattern p(nullptr); - p.setProgressionType(AutomationPattern::LinearProgression); - p.putValue(0, 0.0, false); - p.putValue(100, 1.0, false); - - QCOMPARE(p.valueAt(0), 0.0f); - QCOMPARE(p.valueAt(25), 0.25f); - QCOMPARE(p.valueAt(50), 0.5f); - QCOMPARE(p.valueAt(75), 0.75f); - QCOMPARE(p.valueAt(100), 1.0f); - QCOMPARE(p.valueAt(150), 1.0f); + AutomationClip c(nullptr); + c.setProgressionType(AutomationClip::LinearProgression); + c.putValue(0, 0.0, false); + c.putValue(100, 1.0, false); + + QCOMPARE(c.valueAt(0), 0.0f); + QCOMPARE(c.valueAt(25), 0.25f); + QCOMPARE(c.valueAt(50), 0.5f); + QCOMPARE(c.valueAt(75), 0.75f); + QCOMPARE(c.valueAt(100), 1.0f); + QCOMPARE(c.valueAt(150), 1.0f); } - void testPatternDiscrete() + void testClipDiscrete() { - AutomationPattern p(nullptr); - p.setProgressionType(AutomationPattern::DiscreteProgression); - p.putValue(0, 0.0, false); - p.putValue(100, 1.0, false); - - QCOMPARE(p.valueAt(0), 0.0f); - QCOMPARE(p.valueAt(50), 0.0f); - QCOMPARE(p.valueAt(100), 1.0f); - QCOMPARE(p.valueAt(150), 1.0f); + AutomationClip c(nullptr); + c.setProgressionType(AutomationClip::DiscreteProgression); + c.putValue(0, 0.0, false); + c.putValue(100, 1.0, false); + + QCOMPARE(c.valueAt(0), 0.0f); + QCOMPARE(c.valueAt(50), 0.0f); + QCOMPARE(c.valueAt(100), 1.0f); + QCOMPARE(c.valueAt(150), 1.0f); } - void testPatterns() + void testClips() { FloatModel model; auto song = Engine::getSong(); AutomationTrack track(song); - AutomationPattern p1(&track); - p1.setProgressionType(AutomationPattern::LinearProgression); - p1.putValue(0, 0.0, false); - p1.putValue(10, 1.0, false); - p1.movePosition(0); - p1.addObject(&model); - - AutomationPattern p2(&track); - p2.setProgressionType(AutomationPattern::LinearProgression); - p2.putValue(0, 0.0, false); - p2.putValue(100, 1.0, false); - p2.movePosition(100); - p2.addObject(&model); - - AutomationPattern p3(&track); - p3.addObject(&model); + AutomationClip c1(&track); + c1.setProgressionType(AutomationClip::LinearProgression); + c1.putValue(0, 0.0, false); + c1.putValue(10, 1.0, false); + c1.movePosition(0); + c1.addObject(&model); + + AutomationClip c2(&track); + c2.setProgressionType(AutomationClip::LinearProgression); + c2.putValue(0, 0.0, false); + c2.putValue(100, 1.0, false); + c2.movePosition(100); + c2.addObject(&model); + + AutomationClip c3(&track); + c3.addObject(&model); //XXX: Why is this even necessary? - p3.clear(); + c3.clear(); QCOMPARE(song->automatedValuesAt( 0)[&model], 0.0f); QCOMPARE(song->automatedValuesAt( 5)[&model], 0.5f); @@ -115,19 +115,19 @@ private slots: auto song = Engine::getSong(); AutomationTrack track(song); - AutomationPattern p(&track); - p.setProgressionType(AutomationPattern::LinearProgression); - p.addObject(&model); + AutomationClip c(&track); + c.setProgressionType(AutomationClip::LinearProgression); + c.addObject(&model); - p.putValue(0, 0.0, false); - p.putValue(100, 1.0, false); + c.putValue(0, 0.0, false); + c.putValue(100, 1.0, false); - p.changeLength(100); + c.changeLength(100); QCOMPARE(song->automatedValuesAt( 0)[&model], 0.0f); QCOMPARE(song->automatedValuesAt( 50)[&model], 0.5f); QCOMPARE(song->automatedValuesAt(100)[&model], 1.0f); - p.changeLength(50); + c.changeLength(50); QCOMPARE(song->automatedValuesAt( 0)[&model], 0.0f); QCOMPARE(song->automatedValuesAt( 50)[&model], 0.5f); QCOMPARE(song->automatedValuesAt(100)[&model], 0.5f); @@ -140,21 +140,21 @@ private slots: InstrumentTrack* instrumentTrack = dynamic_cast(Track::create(Track::InstrumentTrack, song)); - Pattern* notePattern = dynamic_cast(instrumentTrack->createTCO(0)); - notePattern->changeLength(TimePos(4, 0)); - Note* note = notePattern->addNote(Note(TimePos(4, 0)), false); + MidiClip* midiClip = dynamic_cast(instrumentTrack->createClip(0)); + midiClip->changeLength(TimePos(4, 0)); + Note* note = midiClip->addNote(Note(TimePos(4, 0)), false); note->createDetuning(); DetuningHelper* dh = note->detuning(); - auto pattern = dh->automationPattern(); - pattern->setProgressionType( AutomationPattern::LinearProgression ); - pattern->putValue(TimePos(0, 0), 0.0); - pattern->putValue(TimePos(4, 0), 1.0); - - QCOMPARE(pattern->valueAt(TimePos(0, 0)), 0.0f); - QCOMPARE(pattern->valueAt(TimePos(1, 0)), 0.25f); - QCOMPARE(pattern->valueAt(TimePos(2, 0)), 0.5f); - QCOMPARE(pattern->valueAt(TimePos(4, 0)), 1.0f); + auto clip = dh->automationClip(); + clip->setProgressionType( AutomationClip::LinearProgression ); + clip->putValue(TimePos(0, 0), 0.0); + clip->putValue(TimePos(4, 0), 1.0); + + QCOMPARE(clip->valueAt(TimePos(0, 0)), 0.0f); + QCOMPARE(clip->valueAt(TimePos(1, 0)), 0.25f); + QCOMPARE(clip->valueAt(TimePos(2, 0)), 0.5f); + QCOMPARE(clip->valueAt(TimePos(4, 0)), 1.0f); } void testBBTrack() @@ -164,16 +164,16 @@ private slots: BBTrack bbTrack(song); Track* automationTrack = Track::create(Track::AutomationTrack, bbContainer); - QVERIFY(automationTrack->numOfTCOs()); - AutomationPattern* p1 = dynamic_cast(automationTrack->getTCO(0)); - QVERIFY(p1); + QVERIFY(automationTrack->numOfClips()); + AutomationClip* c1 = dynamic_cast(automationTrack->getClip(0)); + QVERIFY(c1); FloatModel model; - p1->setProgressionType(AutomationPattern::LinearProgression); - p1->putValue(0, 0.0, false); - p1->putValue(10, 1.0, false); - p1->addObject(&model); + c1->setProgressionType(AutomationClip::LinearProgression); + c1->putValue(0, 0.0, false); + c1->putValue(10, 1.0, false); + c1->addObject(&model); QCOMPARE(bbContainer->automatedValuesAt( 0, bbTrack.index())[&model], 0.0f); QCOMPARE(bbContainer->automatedValuesAt( 5, bbTrack.index())[&model], 0.5f); @@ -185,9 +185,9 @@ private slots: QCOMPARE(bbContainer->automatedValuesAt(5, bbTrack.index())[&model], 0.5f); QVERIFY(! bbContainer->automatedValuesAt(5, bbTrack2.index()).size()); - BBTCO tco(&bbTrack); - tco.changeLength(TimePos::ticksPerBar() * 2); - tco.movePosition(0); + BBClip clip(&bbTrack); + clip.changeLength(TimePos::ticksPerBar() * 2); + clip.movePosition(0); QCOMPARE(song->automatedValuesAt(0)[&model], 0.0f); QCOMPARE(song->automatedValuesAt(5)[&model], 0.5f); @@ -201,18 +201,18 @@ private slots: auto song = Engine::getSong(); auto globalTrack = song->globalAutomationTrack(); - AutomationPattern globalPattern(globalTrack); + AutomationClip globalClip(globalTrack); AutomationTrack localTrack(song); - AutomationPattern localPattern(&localTrack); + AutomationClip localClip(&localTrack); FloatModel model; - globalPattern.setProgressionType(AutomationPattern::DiscreteProgression); - localPattern.setProgressionType(AutomationPattern::DiscreteProgression); - globalPattern.addObject(&model); - localPattern.addObject(&model); - globalPattern.putValue(0, 100.0f, false); - localPattern.putValue(0, 50.0f, false); + globalClip.setProgressionType(AutomationClip::DiscreteProgression); + localClip.setProgressionType(AutomationClip::DiscreteProgression); + globalClip.addObject(&model); + localClip.addObject(&model); + globalClip.putValue(0, 100.0f, false); + localClip.putValue(0, 50.0f, false); QCOMPARE(song->automatedValuesAt(0)[&model], 50.0f); }