metadata.h 2.5 KB

123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354
  1. /*****************************************************************************
  2. * dictplugin.h - QStarDict, a StarDict clone written using Qt *
  3. * Copyright (C) 2016 Ilinykh Sergey *
  4. * *
  5. * This program is free software; you can redistribute it and/or modify *
  6. * it under the terms of the GNU General Public License as published by *
  7. * the Free Software Foundation; either version 2 of the License, or *
  8. * (at your option) any later version. *
  9. * *
  10. * This program is distributed in the hope that it will be useful, *
  11. * but WITHOUT ANY WARRANTY; without even the implied warranty of *
  12. * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the *
  13. * GNU General Public License for more details. *
  14. * *
  15. * You should have received a copy of the GNU General Public License along *
  16. * with this program; if not, write to the Free Software Foundation, Inc., *
  17. * 51 Franklin Street, Fifth Floor, Boston, MA 02110-1301 USA. *
  18. *****************************************************************************/
  19. #ifndef QSD_METADATA_H
  20. #define QSD_METADATA_H
  21. #include <QString>
  22. #include <QStringList>
  23. #include <QVariantMap>
  24. #include <QIcon>
  25. namespace QStarDict
  26. {
  27. // IMPORTANT: If you change this structure,
  28. // don't forget to change BasePlugin interface version
  29. struct PluginMetadata
  30. {
  31. QString id; // not-human name. to identify
  32. QString name; // human name. to display it
  33. QString version; // plugin's version
  34. QString description; // short discription to show in plugins list or tooltip
  35. QStringList authors; // list of authors preferably in format "Name <e-mail>"
  36. QStringList features; // comma-separated list of supported features qstardict knows about
  37. // "dict" - dictionay plugin,
  38. // "defenable" - enable this plugin by default if not cached
  39. // "de" - desktop environment plugin
  40. // "toolbar" - toolbar plugin
  41. QIcon icon; // plugin's icon. it's cached as soon as we enable plugin once
  42. QVariantMap extra; // for any not described here use
  43. };
  44. } // namespace QStarDict
  45. #endif // QSD_METADATA_H