mirror of
https://github.com/fergalmoran/flameshot.git
synced 2026-02-17 16:04:15 +00:00
* Create developer docs * Remove mike dependency * Update docs * Make docs/dev self-contained * Add incomplete deploy-dev-docs workflow * Fix typo * Add workflow file to path: * Add doxygen as dependency * Add remaining deploy steps * Add working-directory * Fix working-directory error * Add missing Makefile * Change flameshot website repo url * Change working-directory for safety step * Add git credentials * Change push credentials * Use different token secret * Remove checkpoints * Add separate branch developer-docs * Add || true * Update docs * Update the 'Maintaining the documentation' docs * Fix error in deploy-dev-docs workflow * Remove accidentally committed file DOC.md * Update PAT expiry date * Rename developer-docs branch to dev-docs-staging
2.0 KiB
2.0 KiB
FAQ
!!! todo
Incomplete page.
How do I create a new subcommand?
How do I add a new tool?
How do I add a new config setting?
There are currently two groups of settings: General and Shortcuts.
The necessary steps are usually the following:
- Determine a name for the setting - for a general setting, it must be a valid C++ identifier, for a shortcut it must be the name of a tool type from TODO.
- Add a getter and a setter for the setting in
ConfigHandler. For most settings you should use theCONFIG_GETTER_SETTERmacro. If your setting is unusual enough you may need to useCONFIG_GETTERorCONFIG_SETTERindividually, or even need to create the methods manually. - If you need custom validation or conversion for the value, you must create a
subclass of
ValueHandler. Otherwise you can use one of the existing ones in valuehandler.h. - If you want to make your setting available in the configuration GUI (usually
you do), you should add the appropriate widgets into one of the tabs of
ConfigWindow. If your setting doesn't fit into any of the existing tabs, you can add a new one, but please discuss it with us first.
To get a deeper understanding of how the configuration works, please see Configuration.