gtk-rs / gtk-rs-core

Rust bindings for GNOME libraries
https://gtk-rs.org/gtk-rs-core
MIT License
279 stars 112 forks source link

opt-in fns behind feature flags should be documented as such #501

Open osa1 opened 2 years ago

osa1 commented 2 years ago

Compare

Both of these are behind feature flags. In the first one which feature flag you need is documented. In the second one you need to search rest of the documentation for tips.

It would be helpful if gtk-rs packages documented required feature flags for function in the function documentation.

sdroege commented 2 years ago

That's because here the #[cfg] is on the whole module imported in lib.rs instead of per function: https://gtk-rs.org/gtk-rs-core/git/docs/src/cairo/lib.rs.html#145

Fixing that would require moving it down on each function (exclusively or additionally).