digiKam
userscript.h
Go to the documentation of this file.
1 /* ============================================================
2  *
3  * This file is a part of digiKam project
4  * https://www.digikam.org
5  *
6  * Date : 2014-05-24
7  * Description : user script batch tool.
8  *
9  * Copyright (C) 2009-2022 by Gilles Caulier <caulier dot gilles at gmail dot com>
10  * Copyright (C) 2014 by Hubert Law <hhclaw dot eb at gmail dot com>
11  *
12  * This program is free software; you can redistribute it
13  * and/or modify it under the terms of the GNU General
14  * Public License as published by the Free Software Foundation;
15  * either version 2, or (at your option)
16  * any later version.
17  *
18  * This program is distributed in the hope that it will be useful,
19  * but WITHOUT ANY WARRANTY; without even the implied warranty of
20  * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
21  * GNU General Public License for more details.
22  *
23  * ============================================================ */
24 
25 #ifndef DIGIKAM_BQM_USER_SCRIPT_H
26 #define DIGIKAM_BQM_USER_SCRIPT_H
27 
28 // Local includes
29 
30 #include "batchtool.h"
31 
32 using namespace Digikam;
33 
35 {
36 
37 class UserScript : public BatchTool
38 {
39  Q_OBJECT
40 
41 public:
42 
43  explicit UserScript(QObject* const parent = nullptr);
44  ~UserScript() override;
45 
46  QString outputSuffix() const override;
47 
48  BatchToolSettings defaultSettings() override;
49 
50  BatchTool* clone(QObject* const parent = nullptr) const override;
51 
52  void registerSettingsWidget() override;
53 
54 private:
55 
56  bool toolOperations() override;
57 
58 private Q_SLOTS:
59 
60  void slotAssignSettings2Widget() override;
61  void slotSettingsChanged() override;
62 
63 private:
64 
65  class Private;
66  Private* const d;
67 };
68 
69 } // namespace DigikamBqmUserScriptPlugin
70 
71 #endif // DIGIKAM_BQM_USER_SCRIPT_H
Definition: userscript.h:38
Definition: batchtool.h:56
Definition: userscript.cpp:49
Definition: datefolderview.cpp:43
QMap< QString, QVariant > BatchToolSettings
Definition: batchtool.h:48