1 /*** 2 3 Olive - Non-Linear Video Editor 4 Copyright (C) 2019 Olive Team 5 6 This program is free software: you can redistribute it and/or modify 7 it under the terms of the GNU General Public License as published by 8 the Free Software Foundation, either version 3 of the License, or 9 (at your option) any later version. 10 11 This program is distributed in the hope that it will be useful, 12 but WITHOUT ANY WARRANTY; without even the implied warranty of 13 MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 14 GNU General Public License for more details. 15 16 You should have received a copy of the GNU General Public License 17 along with this program. If not, see <http://www.gnu.org/licenses/>. 18 19 ***/ 20 21 #ifndef TEXTEFFECT_H 22 #define TEXTEFFECT_H 23 24 #include "effects/effect.h" 25 26 #include <QFont> 27 #include <QImage> 28 29 class TextEffect : public Effect { 30 Q_OBJECT 31 public: 32 TextEffect(Clip* c, const EffectMeta *em); 33 void redraw(double timecode); 34 private slots: 35 void outline_enable(bool); 36 void shadow_enable(bool); 37 private: 38 QFont font; 39 40 StringField* text_val; 41 DoubleField* size_val; 42 ColorField* set_color_button; 43 FontField* set_font_combobox; 44 ComboField* halign_field; 45 ComboField* valign_field; 46 BoolField* word_wrap_field; 47 DoubleField* padding_field; 48 DoubleField* position_x; 49 DoubleField* position_y; 50 51 BoolField* outline_bool; 52 DoubleField* outline_width; 53 ColorField* outline_color; 54 55 BoolField* shadow_bool; 56 DoubleField* shadow_angle; 57 DoubleField* shadow_distance; 58 ColorField* shadow_color; 59 DoubleField* shadow_softness; 60 DoubleField* shadow_opacity; 61 62 }; 63 64 #endif // TEXTEFFECT_H 65