mirror of
https://github.com/Zedfrigg/ironbar.git
synced 2025-07-02 11:11:04 +02:00
docs: add rustdoc comments to all module options
This part of an upcoming effort to generate documentation from code. Pushing this out before that stage so that the JSON schema is fully documented.
This commit is contained in:
parent
3b6480f3f2
commit
c7743b28c6
24 changed files with 833 additions and 48 deletions
|
@ -19,16 +19,33 @@ use tracing::{debug, error};
|
|||
|
||||
#[derive(Debug, Clone, Deserialize)]
|
||||
pub struct CairoModule {
|
||||
/// The path to the Lua script to load.
|
||||
/// This can be absolute, or relative to the working directory.
|
||||
///
|
||||
/// The script must contain the entry `draw` function.
|
||||
///
|
||||
/// **Required**
|
||||
path: PathBuf,
|
||||
|
||||
/// The number of milliseconds between each draw call.
|
||||
///
|
||||
/// **Default**: `200`
|
||||
#[serde(default = "default_frequency")]
|
||||
frequency: u64,
|
||||
|
||||
/// The canvas width in pixels.
|
||||
///
|
||||
/// **Default**: `42`
|
||||
#[serde(default = "default_size")]
|
||||
width: u32,
|
||||
|
||||
/// The canvas height in pixels.
|
||||
///
|
||||
/// **Default**: `42`
|
||||
#[serde(default = "default_size")]
|
||||
height: u32,
|
||||
|
||||
/// See [common options](module-level-options#common-options).
|
||||
#[serde(flatten)]
|
||||
pub common: Option<CommonConfig>,
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue