24 lines
No EOL
957 B
Swift
24 lines
No EOL
957 B
Swift
import Gtk
|
|
|
|
extension WidgetView where Target: Gtk.GridView {
|
|
/// Applies the `.navigation-sidebar` style class.
|
|
///
|
|
/// Sidebar look: rounded padded items, neutral (not accent) selection color, no default list background.
|
|
///
|
|
/// - Parameter enabled: Whether the style class is applied.
|
|
/// - Returns: A copy of this view with the modifier applied.
|
|
public func navigationSidebar(_ enabled: Bool = true) -> Self {
|
|
styleClass("navigation-sidebar", enabled)
|
|
}
|
|
|
|
/// Applies the `.navigation-sidebar` style class.
|
|
///
|
|
/// Sidebar look: rounded padded items, neutral (not accent) selection color, no default list background.
|
|
///
|
|
/// - Parameter enabled: A binding that controls whether the class is applied.
|
|
/// - Returns: A copy of this view with the modifier applied.
|
|
public func navigationSidebar(_ enabled: Binding<Bool>) -> Self {
|
|
styleClass("navigation-sidebar", enabled)
|
|
}
|
|
|
|
} |