-
-
Notifications
You must be signed in to change notification settings - Fork 2
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #8 from NickvisionApps/docs
Add Docs Folder
- Loading branch information
Showing
74 changed files
with
2,739 additions
and
592 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,49 @@ | ||
# libaura | ||
|
||
UNDER CONSTRUCTION | ||
A cross-platform base for native Nickvision applications. | ||
|
||
A cross-platform base for native Nickvision applications | ||
libaura provides Nickvision apps with a common set of cross-platform (Windows and Linux) APIs for managing system and desktop app functionality such as network management, taskbar icons, translations, app updates, and more. | ||
|
||
## Documentation | ||
|
||
Documentation for this library and its modules can be found [here](/docs). | ||
|
||
## Installation | ||
|
||
TODO when published on Conan. | ||
|
||
## Manual Building and Installation | ||
libaura uses Conan package manager for resolving dependencies and CMake as it's build system. | ||
|
||
Ensure both `conan` and `cmake` are installed on your system before building libaura. | ||
|
||
A C++20 compiler is also required to build libaura. | ||
|
||
### Windows | ||
Visual Studio 2022 with C++ Desktop workload is required to be installed. | ||
|
||
1. First, clone/download the repo. | ||
1. From the `conan` folder within the repo, copy `conanfile-windows.txt` and `conanprofile-windows.txt` to the root directory of the repo. | ||
1. Open a terminal and navigate to the repo's root directory. | ||
1. Run `conan install conanfile-windows.txt --profile:host=conanprofile-windows.txt --profile:build=conanprofile-windows.txt -s compiler.cppstd=20 --build=missing`. | ||
1. Once that command finishes, cd into the `build` folder. | ||
1. From the `build` folder, run `cmake .. -G "Visual Studio 17 2022" -DCMAKE_TOOLCHAIN_FILE="generators/conan_toolchain.cmake"` and `cmake --build . --config Release`. | ||
1. After these commands, libaura will be successfully built and its binaries can be found in the `Release` folder of the `build` folder. | ||
1. To install libaura to the system, run `cmake --install . --prefix "PATH_TO_INSTALL_DIR"`. | ||
- Replace `PATH_TO_INSTALL_DIR` with the path to a folder to install libaura to. This is usually a dependencies folder set up by the programmer, added to the PATH variable, to allow linking to said dependencies. | ||
1. If contributing to upstream, remove `conanfile-windows.txt` and `conanprofile-windows.txt` from the repo's root directory as to not accidentally add and commit them. | ||
|
||
### Linux | ||
1. First, clone/download the repo. | ||
1. From the `conan` folder within the repo, copy `conansettings.yml`, `conanfile-linux.txt`, and `conanprofile-linux.txt` to the root directory of the repo. | ||
1. Rename `conansettings.yml` to `settings_user.yml`. | ||
1. Open a terminal and navigate to the repo's root directory. | ||
1. Run `conan config install settings_user.yml`. | ||
1. Run `conan install conanfile-linux.txt --profile:host=conanprofile-linux.txt --profile:build=conanprofile-linux.txt -s compiler.cppstd=20 --build=missing`. | ||
1. Once that command finished, cd into the `build` folder. | ||
1. From the `build` folder, run `cmake .. -DCMAKE_TOOLCHAIN_FILE="Release/generators/conan_toolchain.cmake" -DCMAKE_BUILD_TYPE=Release` and `cmake --build`. | ||
1. After these commands, libaura will be successfully built and its binaries can be found in the `Release` folder of the `build` folder. | ||
1. To install libaura to the system, run `cmake --install . --prefix "PATH_TO_INSTALL_DIR"`. | ||
- Replace `PATH_TO_INSTALL_DIR` with the path to a folder to install libaura to. This is usually a dependencies folder set up by the programmer, added to the PATH variable, to allow linking to said dependencies. | ||
- On linux, `PATH_TO_INSTALL_DIR` would usually be `/usr`. | ||
1. If contributing to upstream, remove `conanfile-windows.txt` and `conanprofile-windows.txt` from the repo's root directory as to not accidentally add and commit them. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,39 @@ | ||
# libaura Documentation | ||
|
||
This folder contains all of the necessary documentation for using libaura and it's provided modules. | ||
|
||
Each module (separated by namespace) contains its own documentation file that can be found within this folder or via one of the links below. | ||
|
||
## Table of Contents | ||
- [Documentation Syntax](#documentationsyntax) | ||
- [Modules](#modules) | ||
|
||
## Documentation Syntax | ||
|
||
### Member Variables | ||
Many class types contain member variables exposed by getter and/or setter methods depending on the class' exposure of the variable. | ||
|
||
For example, assume a class exposes the member variable `std::string m_var`. We will document this as `std::string Var: get, set`. | ||
|
||
This means that the class provides the following methods for `m_var`: `std::string getVar() const` and `void setVar(const std::string& var)`. | ||
|
||
If a member variable is get or set only, we will document this as `std::string Var: get` and `std::string Var: set` respectively. | ||
|
||
### Events | ||
libaura provides a C#-inspired event system module under the Nickvision::Aura::Events namespace. This module contains a class `Event<T>` that handles registering and calling callbacks when said event is invoked. | ||
|
||
For example, assume a class has an event defined as `Nickvision::Aura::Events::Event<Nickvision::Aura::Events::EventArgs> m_saved`. We will document exposure of this event as `Event<Nickvision::Aura::Events::EventArgs> Saved`. | ||
|
||
This means that the class provides the following method, allowing consumers to register callbacks to the event using the `+=` operator: `Nickvision::Aura::Events::Event<Nickvision::Aura::Events::EventArgs>& saved()`. | ||
|
||
## Modules | ||
- [Nickvision::Aura](aura.md) | ||
- [Nickvision::Aura::Events](events.md) | ||
- [Nickvision::Aura::Filesystem](filesystem.md) | ||
- [Nickvision::Aura::Helpers](helpers.md) | ||
- [Nickvision::Aura::Keyring](keyring.md) | ||
- [Nickvision::Aura::Localization](localization.md) | ||
- [Nickvision::Aura::Network](network.md) | ||
- [Nickvision::Aura::Notifications](notifications.md) | ||
- [Nickvision::Aura::Taskbar](taskbar.md) | ||
- [Nickvision::Aura::Update](update.md) |
Oops, something went wrong.