#docs #gtk #vendor #lgpl-licensed

gtk-rs-lgpl-docs

LGPL-licensed docs for Gtk-rs crates

18 releases

Uses old Rust 2015

0.1.18 Jul 5, 2020
0.1.15 Dec 15, 2019
0.1.12 Jun 24, 2019
0.1.8 Mar 24, 2019
0.0.1 Mar 15, 2016

#211 in #docs

Download history 16/week @ 2023-12-04 41/week @ 2023-12-11 43/week @ 2023-12-18 26/week @ 2023-12-25 23/week @ 2024-01-01 37/week @ 2024-01-08 46/week @ 2024-01-15 22/week @ 2024-01-22 25/week @ 2024-01-29 36/week @ 2024-02-05 83/week @ 2024-02-12 133/week @ 2024-02-19 125/week @ 2024-02-26 91/week @ 2024-03-04 115/week @ 2024-03-11 82/week @ 2024-03-18

444 downloads per month
Used in 5 crates (3 directly)

LGPL-2.0

1.5MB
76 lines

lgpl-docs

LGPL-licensed docs for Gtk-rs crates.

Structure

The docs for each library come from two files:

  • docs.rs is maintained manually, its entries take precedence over the vendor.rs file. PRs should normally target this file.

  • vendor.rs is generated by gir via simple transformation of the upstream docs found in GIR definitions. It serves as a fallback, the docs in it are tailored for C not Rust. This file should not be hand-edited.

You can generate it as follows:

cd gir
cargo run --release -- -c ../your-repo/Gir.toml -d ../gir-files/ -o ../your-repo/ -m doc

Cairo, which lacks GIR definitions, doesn't have a vendor.rs file.

Format

The format of the files is Markdown with extra metadata in HTML-like comments, which ties each entry to a specific Rust item. For example, this rustdoc snippet:

impl Button {
    /// Creates a new `Button` widget. To add a child widget to the button,
    /// use `Container::add`.
    ///
    /// # Returns
    ///
    /// The newly created `Button` widget.
    pub fn new() -> Button {

corresponds to this entry in gtk/vendor.md:

<!-- impl Button::fn new -->
Creates a new `Button` widget. To add a child widget to the button,
use `Container::add`.

# Returns

The newly created `Button` widget.

License

LGPL

Dependencies