![]() |
Geometrize
1.0
An application for geometrizing images into geometric primitives
|
The GlobalPreferences class models the preferences associated with the application as a whole. These mostly represent application-wide settings that are edited via the tabbed preferences widget. More...
#include <globalpreferences.h>


Classes | |
| class | GlobalPreferencesImpl |
Public Member Functions | |
| GlobalPreferences () | |
| GlobalPreferences & | operator= (const GlobalPreferences &)=delete |
| GlobalPreferences (const GlobalPreferences &)=delete | |
| ~GlobalPreferences () | |
| bool | load (const std::string &filePath) |
| load Loads the global preferences from a file. More... | |
| bool | save (const std::string &filePath) |
| save Saves the global preferences to a file. More... | |
| unsigned int | getApplicationLaunchCount () const |
| getApplicationLaunchCount More... | |
| void | incrementApplicationLaunchCount () |
| incrementApplicationLaunchCount Increments the count for the number of times the application has been launched. More... | |
| bool | shouldShowWelcomeScreenOnLaunch () const |
| shouldShowWelcomeScreenOnLaunch Gets the preference for whether the welcome screen should be displayed on launch. More... | |
| void | setShouldShowWelcomeScreenOnLaunch (bool show) |
| setShouldShowWelcomeScreenOnLaunch Sets the preference for whether the welcome screen should be displayed on launch. More... | |
| bool | shouldGeometrizeAppLogoOnLaunch () const |
| shouldGeometrizeAppLogoOnLaunch Gets the preference for whether the app logo on the launch window should be geometrized on launch. More... | |
| void | setShouldGeometrizeAppLogoOnLaunch (bool geometrizeLogo) |
| setShouldGeometrizeAppLogoOnLaunch Sets the preference for whether to geometrize the app logo on the launch window on launch. More... | |
| bool | shouldPopulateRecentItemsOnLaunch () const |
| shouldPopulateRecentItemsOnLaunch Gets the preference for whether the recent items list should be populated on launch. More... | |
| void | setShouldPopulateRecentItemsOnLaunch (bool populateRecents) |
| setShouldPopulateRecentItemsOnLaunch Sets the preference for whether the recent items list should be populated on launch. More... | |
| bool | shouldPopulateTemplatesOnLaunch () const |
| shouldPopulateTemplatesOnLaunch Gets the preference for whether to populate the task templates on the launch window on launch. More... | |
| void | setShouldPopulateTemplatesOnLaunch (bool populateTemplates) |
| setShouldPopulateTemplatesOnLaunch Sets the preference for whether to populate the task templates on the launch window on launch. More... | |
| std::array< std::int32_t, 4 > | getCustomImageTaskBackgroundOverrideColor () const |
| getCustomImageTaskBackgroundOverrideColor Gets the preference for the custom image task background override color to use when an image task is initially set up. More... | |
| void | setCustomImageTaskBackgroundOverrideColor (std::int32_t r, std::int32_t g, std::int32_t b, std::int32_t a) |
| setUseCustomImageTaskBackgroundOverrideColor Sets the preference for the custom image task background override color to use when an image task is initially set up. More... | |
| bool | shouldUseCustomImageTaskBackgroundOverrideColor () const |
| shouldUseCustomImageTaskBackgroundOverrideColor Gets the preference for whether to use the custom image task background override color. More... | |
| void | setShouldUseCustomImageTaskBackgroundOverrideColor (bool useColor) |
| setShouldUseCustomImageTaskBackgroundOverrideColor Sets the preference for whether to use the custom image task background override color. More... | |
| std::array< std::int32_t, 4 > | getTargetImageAlphaReplacementColor () const |
| getTargetImageAlphaReplacementColor Gets the preference for the color to replace the alpha of a target image with, when an image task is initially set up. More... | |
| void | setTargetImageAlphaReplacementColor (std::int32_t r, std::int32_t g, std::int32_t b, std::int32_t a) |
| setTargetImageAlphaReplacementColor Sets the preference for the color to replace the alpha of a target image with, when an image task is initially set up. More... | |
| bool | shouldUseImageAlphaReplacementColor () const |
| shouldUseImageAlphaReplacementColor Gets the preference for whether to replace the alpha of a target image with a color, when an image task is initially set up. More... | |
| void | setShouldReplaceTargetImageAlphaWithCustomColor (bool useColor) |
| setShouldReplaceTargetImageAlphaWithCustomColor Sets the preference for whether to replace the alpha of a target image with a color, when an image task is initially set up. More... | |
| bool | shouldAutoLoadImageTaskSettings () const |
| shouldAutoLoadImageTaskSettings Gets the preference for whether to automatically load any previously saved image task settings when a task window is opened. More... | |
| void | setShouldAutoLoadImageTaskSettings (bool loadSettings) |
| setShouldAutoLoadImageTaskSettings Sets the preference for whether to automatically load any previously saved image task settings when a task window is opened. More... | |
| bool | shouldAutoSaveImageTaskSettings () const |
| shouldAutoSaveImageTaskSettings Gets the preference for whether to automatically save the last task settings to disk/persistent storage when a task window is closed. More... | |
| void | setShouldAutoSaveImageTaskSettings (bool saveSettings) |
| setShouldAutoSaveImageTaskSettings Sets the preference for whether to automatically save the last task settings to disk/persistent storage when a task window is closed. More... | |
| bool | shouldShowLaunchConsoleByDefault () const |
| shouldShowLaunchConsoleByDefault Gets the preference for whether to show the console on the launch window when the window is opened. More... | |
| void | setShouldShowLaunchConsoleByDefault (bool showConsole) |
| setShouldShowLaunchConsoleByDefault Sets the preference for whether to show the console on the launch window when the window is opened. More... | |
| bool | shouldShowImageTaskVectorViewByDefault () const |
| shouldShowImageTaskVectorViewByDefault Gets the preference for whether to show the image task vector/SVG view when the window is opened. More... | |
| void | setShouldShowImageTaskVectorViewByDefault (bool showVectorView) |
| setShouldShowImageTaskVectorViewByDefault Sets the preference for whether to show the image task vector/SVG view when the window is opened. More... | |
| bool | shouldShowImageTaskConsoleByDefault () const |
| shouldShowImageTaskConsoleByDefault Gets the preference for whether to show the console on the image task window when the window is opened. More... | |
| void | setShouldShowImageTaskConsoleByDefault (bool showConsole) |
| setShouldShowImageTaskConsoleByDefault Sets the preference for whether to show the console on the image task window when the window is opened. More... | |
| bool | shouldShowImageTaskScriptEditorByDefault () const |
| shouldShowImageTaskScriptEditorByDefault Gets the preference for whether to open the script editor when an image task window is opened. More... | |
| void | setShouldShowImageTaskScriptEditorByDefault (bool showScriptEditor) |
| setShouldShowImageTaskScriptEditorByDefault Sets the preference for whether to open the script editor when an image task window is opened. More... | |
| bool | shouldShowImageTaskPixmapViewByDefault () const |
| shouldShowImageTaskPixmapViewByDefault Gets the preference for whether to show the image task pixmap/raster view when the window is opened. More... | |
| void | setShouldShowImageTaskPixmapViewByDefault (bool showPixmapView) |
| setShouldShowImageTaskPixmapViewByDefault Sets the preference for whether to show the image task pixmap/raster view when the window is opened. More... | |
| bool | isImageTaskImageResizeEnabled () const |
| isImageTaskImageResizeEnabled Gets the preference for whether image tasks should resize images that are too large. More... | |
| void | setImageTaskImageResizeEnabled (bool enabled) |
| setImageTaskImageResizeEnabled Sets the preference for whether image tasks should resize images that are too large. More... | |
| std::pair< std::uint32_t, std::uint32_t > | getImageTaskResizeThreshold () const |
| getImageTaskResizeThreshold Gets the maximum dimensions of an image that can be used in an image task without resizing. More... | |
| void | setImageTaskResizeThreshold (std::uint32_t width, std::uint32_t height) |
| setImageTaskResizeThreshold Sets the maximum dimensions of an image that can be used in an image task without resizing. More... | |
| std::uint32_t | getImageTaskMaxThreads () const |
| getImageTaskMaxThreads Gets the maximum number of threads the image task should use. More... | |
| void | setImageTaskMaxThreads (std::uint32_t maxThreads) |
| setImageTaskMaxThreads Sets the maximum number of threads the image task should use. More... | |
| std::string | getLanguageIsoCode () const |
| getLanguageIsoCode Gets the ISO 639-1 language preference for the application. More... | |
| void | setLanguageIsoCode (const std::string &languageIsoCode) |
| setLanguageIsoCode Sets the ISO 639-1 language preference for the application. More... | |
| std::string | getScriptIsoCode () const |
| getScriptIsoCode Gets the ISO-15924 script code preference for the application. More... | |
| void | setScriptIsoCode (const std::string &scriptIsoCode) |
| setScriptIsoCode Sets the ISO-15924 script code preference for the application. More... | |
| std::string | getCountryIsoCode () const |
| getCountryIsoCode Gets the ISO-3166 country code preference for the application. More... | |
| void | setCountryIsoCode (const std::string &countryIsoCode) |
| setCountryIsoCode Sets the ISO-3166 country code preference for the application. More... | |
| std::string | getLocaleName () const |
| getLocaleName Gets the locale name in the format "language[_script][_country]". language is a lowercase, two or three letter, ISO 639 language code. script is a titlecase, four-letter, ISO 15924 script code. country is an uppercase, two-letter, ISO 3166 country code (also "419" as defined by United Nations). More... | |
| void | setLocaleName (const std::string &localeName) |
| setLocaleName Sets the locale with the specified name, which must have the format "language[_script][_country]". More... | |
Private Attributes | |
| std::unique_ptr< GlobalPreferencesImpl > | d |
The GlobalPreferences class models the preferences associated with the application as a whole. These mostly represent application-wide settings that are edited via the tabbed preferences widget.
| geometrize::preferences::GlobalPreferences::GlobalPreferences | ( | ) |
|
delete |
| unsigned int geometrize::preferences::GlobalPreferences::getApplicationLaunchCount | ( | ) | const |
getApplicationLaunchCount
| std::string geometrize::preferences::GlobalPreferences::getCountryIsoCode | ( | ) | const |
getCountryIsoCode Gets the ISO-3166 country code preference for the application.
| std::array< std::int32_t, 4 > geometrize::preferences::GlobalPreferences::getCustomImageTaskBackgroundOverrideColor | ( | ) | const |
getCustomImageTaskBackgroundOverrideColor Gets the preference for the custom image task background override color to use when an image task is initially set up.

| std::uint32_t geometrize::preferences::GlobalPreferences::getImageTaskMaxThreads | ( | ) | const |
getImageTaskMaxThreads Gets the maximum number of threads the image task should use.

| std::pair< std::uint32_t, std::uint32_t > geometrize::preferences::GlobalPreferences::getImageTaskResizeThreshold | ( | ) | const |
getImageTaskResizeThreshold Gets the maximum dimensions of an image that can be used in an image task without resizing.

| std::string geometrize::preferences::GlobalPreferences::getLanguageIsoCode | ( | ) | const |
getLanguageIsoCode Gets the ISO 639-1 language preference for the application.
| std::string geometrize::preferences::GlobalPreferences::getLocaleName | ( | ) | const |
getLocaleName Gets the locale name in the format "language[_script][_country]". language is a lowercase, two or three letter, ISO 639 language code. script is a titlecase, four-letter, ISO 15924 script code. country is an uppercase, two-letter, ISO 3166 country code (also "419" as defined by United Nations).

| std::string geometrize::preferences::GlobalPreferences::getScriptIsoCode | ( | ) | const |
getScriptIsoCode Gets the ISO-15924 script code preference for the application.
| std::array< std::int32_t, 4 > geometrize::preferences::GlobalPreferences::getTargetImageAlphaReplacementColor | ( | ) | const |
getTargetImageAlphaReplacementColor Gets the preference for the color to replace the alpha of a target image with, when an image task is initially set up.

| void geometrize::preferences::GlobalPreferences::incrementApplicationLaunchCount | ( | ) |
incrementApplicationLaunchCount Increments the count for the number of times the application has been launched.
| bool geometrize::preferences::GlobalPreferences::isImageTaskImageResizeEnabled | ( | ) | const |
isImageTaskImageResizeEnabled Gets the preference for whether image tasks should resize images that are too large.
| bool geometrize::preferences::GlobalPreferences::load | ( | const std::string & | filePath | ) |
load Loads the global preferences from a file.
| filePath | The path to the global preferences file. |

|
delete |
| bool geometrize::preferences::GlobalPreferences::save | ( | const std::string & | filePath | ) |
save Saves the global preferences to a file.
| filePath | The path to the global preferences file. |

| void geometrize::preferences::GlobalPreferences::setCountryIsoCode | ( | const std::string & | countryIsoCode | ) |
setCountryIsoCode Sets the ISO-3166 country code preference for the application.
| countryIsoCode | The ISO-3166 country code. |
| void geometrize::preferences::GlobalPreferences::setCustomImageTaskBackgroundOverrideColor | ( | std::int32_t | r, |
| std::int32_t | g, | ||
| std::int32_t | b, | ||
| std::int32_t | a | ||
| ) |
setUseCustomImageTaskBackgroundOverrideColor Sets the preference for the custom image task background override color to use when an image task is initially set up.
| r | The red color component |
| g | The green color component |
| b | The blue color component |
| a | The alpha color component |

| void geometrize::preferences::GlobalPreferences::setImageTaskImageResizeEnabled | ( | bool | enabled | ) |
setImageTaskImageResizeEnabled Sets the preference for whether image tasks should resize images that are too large.
| enabled | Whether to enable or disable the resizing. |

| void geometrize::preferences::GlobalPreferences::setImageTaskMaxThreads | ( | std::uint32_t | maxThreads | ) |
setImageTaskMaxThreads Sets the maximum number of threads the image task should use.
| maxThreads | The maximum number of threads the image task should use. |

| void geometrize::preferences::GlobalPreferences::setImageTaskResizeThreshold | ( | std::uint32_t | width, |
| std::uint32_t | height | ||
| ) |
setImageTaskResizeThreshold Sets the maximum dimensions of an image that can be used in an image task without resizing.
| width | The maximum width of an image. |
| height | The maximum height of an image. |

| void geometrize::preferences::GlobalPreferences::setLanguageIsoCode | ( | const std::string & | languageIsoCode | ) |
setLanguageIsoCode Sets the ISO 639-1 language preference for the application.
| languageIsoCode | The ISO 639-1 language code. |

| void geometrize::preferences::GlobalPreferences::setLocaleName | ( | const std::string & | localeName | ) |
setLocaleName Sets the locale with the specified name, which must have the format "language[_script][_country]".
| localeName | The locale name in the format "language[_script][_country]". language is a lowercase, two or three letter, ISO 639 language code. script is a titlecase, four-letter, ISO 15924 script code. country is an uppercase, two-letter, ISO 3166 country code (also "419" as defined by United Nations). |
| void geometrize::preferences::GlobalPreferences::setScriptIsoCode | ( | const std::string & | scriptIsoCode | ) |
setScriptIsoCode Sets the ISO-15924 script code preference for the application.
| scriptIsoCode | The ISO-15924 script code. |
| void geometrize::preferences::GlobalPreferences::setShouldAutoLoadImageTaskSettings | ( | bool | loadSettings | ) |
setShouldAutoLoadImageTaskSettings Sets the preference for whether to automatically load any previously saved image task settings when a task window is opened.
| loadSettings | Whether to automatically load any previously saved image task settings when a task window is opened |

| void geometrize::preferences::GlobalPreferences::setShouldAutoSaveImageTaskSettings | ( | bool | saveSettings | ) |
setShouldAutoSaveImageTaskSettings Sets the preference for whether to automatically save the last task settings to disk/persistent storage when a task window is closed.
| saveSettings | Whether to automatically save the last task settings to disk/persistent storage when a task window is closed |

| void geometrize::preferences::GlobalPreferences::setShouldGeometrizeAppLogoOnLaunch | ( | bool | geometrizeLogo | ) |
setShouldGeometrizeAppLogoOnLaunch Sets the preference for whether to geometrize the app logo on the launch window on launch.
| geometrizeLogo | Whether to geometrize the app logo on the launch window on launch. |

| void geometrize::preferences::GlobalPreferences::setShouldPopulateRecentItemsOnLaunch | ( | bool | populateRecents | ) |
setShouldPopulateRecentItemsOnLaunch Sets the preference for whether the recent items list should be populated on launch.
| populateRecents | Whether to populate the recent items list on launch. |

| void geometrize::preferences::GlobalPreferences::setShouldPopulateTemplatesOnLaunch | ( | bool | populateTemplates | ) |
setShouldPopulateTemplatesOnLaunch Sets the preference for whether to populate the task templates on the launch window on launch.
| populateTemplates | Whether to populate the task templates on the launch window on app launch. |

| void geometrize::preferences::GlobalPreferences::setShouldReplaceTargetImageAlphaWithCustomColor | ( | bool | useColor | ) |
setShouldReplaceTargetImageAlphaWithCustomColor Sets the preference for whether to replace the alpha of a target image with a color, when an image task is initially set up.
| useColor | Whether to replace the alpha of a target image with a color, when an image task is initially set up etc. |

| void geometrize::preferences::GlobalPreferences::setShouldShowImageTaskConsoleByDefault | ( | bool | showConsole | ) |
setShouldShowImageTaskConsoleByDefault Sets the preference for whether to show the console on the image task window when the window is opened.
| showConsole | Whether to show the console on the image task window when the window is opened. |

| void geometrize::preferences::GlobalPreferences::setShouldShowImageTaskPixmapViewByDefault | ( | bool | showPixmapView | ) |
setShouldShowImageTaskPixmapViewByDefault Sets the preference for whether to show the image task pixmap/raster view when the window is opened.
| showPixmapView | Whether to show the image task pixmap/raster view when the window is opened. |

| void geometrize::preferences::GlobalPreferences::setShouldShowImageTaskScriptEditorByDefault | ( | bool | showScriptEditor | ) |
setShouldShowImageTaskScriptEditorByDefault Sets the preference for whether to open the script editor when an image task window is opened.
| showScriptEditor | Whether to open the script editor when an image task window is opened. |

| void geometrize::preferences::GlobalPreferences::setShouldShowImageTaskVectorViewByDefault | ( | bool | showVectorView | ) |
setShouldShowImageTaskVectorViewByDefault Sets the preference for whether to show the image task vector/SVG view when the window is opened.
| showVectorView | Whether to show the image task vector/SVG view when the window is opened. |

| void geometrize::preferences::GlobalPreferences::setShouldShowLaunchConsoleByDefault | ( | bool | showConsole | ) |
setShouldShowLaunchConsoleByDefault Sets the preference for whether to show the console on the launch window when the window is opened.
| showConsole | Whether to show the show the console on the launch window when the window is opened. |

| void geometrize::preferences::GlobalPreferences::setShouldShowWelcomeScreenOnLaunch | ( | bool | show | ) |
setShouldShowWelcomeScreenOnLaunch Sets the preference for whether the welcome screen should be displayed on launch.
| show | Whether to show the welcome screen on launch. |
| void geometrize::preferences::GlobalPreferences::setShouldUseCustomImageTaskBackgroundOverrideColor | ( | bool | useColor | ) |
setShouldUseCustomImageTaskBackgroundOverrideColor Sets the preference for whether to use the custom image task background override color.
| useColor | Whether to use the custom image task background override color when setting up image tasks etc. |

| void geometrize::preferences::GlobalPreferences::setTargetImageAlphaReplacementColor | ( | std::int32_t | r, |
| std::int32_t | g, | ||
| std::int32_t | b, | ||
| std::int32_t | a | ||
| ) |
setTargetImageAlphaReplacementColor Sets the preference for the color to replace the alpha of a target image with, when an image task is initially set up.
| r | The red color component |
| g | The green color component |
| b | The blue color component |
| a | The alpha color component |

| bool geometrize::preferences::GlobalPreferences::shouldAutoLoadImageTaskSettings | ( | ) | const |
shouldAutoLoadImageTaskSettings Gets the preference for whether to automatically load any previously saved image task settings when a task window is opened.
| bool geometrize::preferences::GlobalPreferences::shouldAutoSaveImageTaskSettings | ( | ) | const |
shouldAutoSaveImageTaskSettings Gets the preference for whether to automatically save the last task settings to disk/persistent storage when a task window is closed.
| bool geometrize::preferences::GlobalPreferences::shouldGeometrizeAppLogoOnLaunch | ( | ) | const |
shouldGeometrizeAppLogoOnLaunch Gets the preference for whether the app logo on the launch window should be geometrized on launch.
| bool geometrize::preferences::GlobalPreferences::shouldPopulateRecentItemsOnLaunch | ( | ) | const |
shouldPopulateRecentItemsOnLaunch Gets the preference for whether the recent items list should be populated on launch.
| bool geometrize::preferences::GlobalPreferences::shouldPopulateTemplatesOnLaunch | ( | ) | const |
shouldPopulateTemplatesOnLaunch Gets the preference for whether to populate the task templates on the launch window on launch.
| bool geometrize::preferences::GlobalPreferences::shouldShowImageTaskConsoleByDefault | ( | ) | const |
shouldShowImageTaskConsoleByDefault Gets the preference for whether to show the console on the image task window when the window is opened.
| bool geometrize::preferences::GlobalPreferences::shouldShowImageTaskPixmapViewByDefault | ( | ) | const |
shouldShowImageTaskPixmapViewByDefault Gets the preference for whether to show the image task pixmap/raster view when the window is opened.
| bool geometrize::preferences::GlobalPreferences::shouldShowImageTaskScriptEditorByDefault | ( | ) | const |
shouldShowImageTaskScriptEditorByDefault Gets the preference for whether to open the script editor when an image task window is opened.
| bool geometrize::preferences::GlobalPreferences::shouldShowImageTaskVectorViewByDefault | ( | ) | const |
shouldShowImageTaskVectorViewByDefault Gets the preference for whether to show the image task vector/SVG view when the window is opened.
| bool geometrize::preferences::GlobalPreferences::shouldShowLaunchConsoleByDefault | ( | ) | const |
shouldShowLaunchConsoleByDefault Gets the preference for whether to show the console on the launch window when the window is opened.
| bool geometrize::preferences::GlobalPreferences::shouldShowWelcomeScreenOnLaunch | ( | ) | const |
shouldShowWelcomeScreenOnLaunch Gets the preference for whether the welcome screen should be displayed on launch.
| bool geometrize::preferences::GlobalPreferences::shouldUseCustomImageTaskBackgroundOverrideColor | ( | ) | const |
shouldUseCustomImageTaskBackgroundOverrideColor Gets the preference for whether to use the custom image task background override color.
| bool geometrize::preferences::GlobalPreferences::shouldUseImageAlphaReplacementColor | ( | ) | const |
shouldUseImageAlphaReplacementColor Gets the preference for whether to replace the alpha of a target image with a color, when an image task is initially set up.
|
private |