1 /************************************************************************ 2 ** 3 ** Copyright (C) 2015-2020 Kevin B. Hendricks, Stratford Ontario Canada 4 ** Copyright (C) 2009-2011 Strahinja Markovic <strahinja.markovic@gmail.com> 5 ** 6 ** This file is part of Sigil. 7 ** 8 ** Sigil is free software: you can redistribute it and/or modify 9 ** it under the terms of the GNU General Public License as published by 10 ** the Free Software Foundation, either version 3 of the License, or 11 ** (at your option) any later version. 12 ** 13 ** Sigil is distributed in the hope that it will be useful, 14 ** but WITHOUT ANY WARRANTY; without even the implied warranty of 15 ** MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the 16 ** GNU General Public License for more details. 17 ** 18 ** You should have received a copy of the GNU General Public License 19 ** along with Sigil. If not, see <http://www.gnu.org/licenses/>. 20 ** 21 *************************************************************************/ 22 23 #pragma once 24 #ifndef CSSTAB_H 25 #define CSSTAB_H 26 27 #include "Tabs/TextTab.h" 28 29 class CSSResource; 30 31 class CSSTab : public TextTab 32 { 33 Q_OBJECT 34 35 public: 36 37 CSSTab(CSSResource *resource, int line_to_scroll_to = -1, int position_to_scroll_to = -1, QWidget *parent = 0); 38 39 bool PasteClipNumber(int clip_number); 40 bool PasteClipEntries(QList<ClipEditorModel::clipEntry *>clips); 41 42 43 public slots: 44 45 void Bold(); 46 void Italic(); 47 void Underline(); 48 void Strikethrough(); 49 50 void AlignLeft(); 51 void AlignCenter(); 52 void AlignRight(); 53 void AlignJustify(); 54 55 void TextDirectionLeftToRight(); 56 void TextDirectionRightToLeft(); 57 void TextDirectionDefault(); 58 59 signals: 60 void CSSUpdated(); 61 62 private slots: 63 void EmitCSSUpdated(); 64 }; 65 66 #endif // CSSTAB_H 67