diff options
author | Tomaž Vajngerl <tomaz.vajngerl@collabora.co.uk> | 2022-01-10 17:16:30 +0900 |
---|---|---|
committer | Tomaž Vajngerl <quikee@gmail.com> | 2022-01-10 13:51:08 +0100 |
commit | e17f003b5feb8da26498f317914eb2eb83be834b (patch) | |
tree | 711d1099f7a37ccc5e137fbdf9a1b4960f1de54b /include/svx | |
parent | 13a524392d6788727b27ad11aef20973ef3042f8 (diff) |
document GenericCheckDialog, GraphicSizeCheck and related classes
Change-Id: If3f8c33601f7823c87b75d601e0b8620d4bfe197
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/128205
Tested-by: Tomaž Vajngerl <quikee@gmail.com>
Reviewed-by: Tomaž Vajngerl <quikee@gmail.com>
Diffstat (limited to 'include/svx')
-rw-r--r-- | include/svx/GenericCheckDialog.hxx | 23 |
1 files changed, 22 insertions, 1 deletions
diff --git a/include/svx/GenericCheckDialog.hxx b/include/svx/GenericCheckDialog.hxx index ef2a41159737..9878ea9fab2a 100644 --- a/include/svx/GenericCheckDialog.hxx +++ b/include/svx/GenericCheckDialog.hxx @@ -16,20 +16,34 @@ namespace svx { +/** + * Interface for the data of a check, which must be extended by the + * check itself, to show the data in the GenericCheckDialog. + */ class CheckData { public: virtual ~CheckData() {} + /// check entry text virtual OUString getText() = 0; + /// true, if we can show the "Mark" button virtual bool canMarkObject() = 0; + /// executed, when the "Mark" button is hit virtual void markObject() = 0; + /// true, if we can show the "Properties" button virtual bool hasProperties() = 0; + /// executed, when the "Properties" button is hit virtual void runProperties() = 0; }; +/** + * Check data collection contains all the checks in one data structure, + * and also serves to define additional attributes that are used by the + * GenericCheckDialog (the title of the check dialog). + */ class CheckDataCollection { protected: @@ -43,6 +57,10 @@ public: virtual OUString getTitle() = 0; }; +/** + * A UI piece to show check result text and other widgets, which are + * relevant for the check (various buttons to act on the check result). + */ class GenericCheckEntry final { private: @@ -63,13 +81,16 @@ public: DECL_LINK(PropertiesButtonClicked, weld::Button&, void); }; +/** + * This is a generic dialog, which is used to display results of a + * document checks, like for example image size check. + */ class SVX_DLLPUBLIC GenericCheckDialog final : public weld::GenericDialogController { private: std::vector<std::unique_ptr<GenericCheckEntry>> m_aCheckEntries; CheckDataCollection& m_rCheckDataCollection; - // Controls std::unique_ptr<weld::Box> m_xCheckBox; public: |