use super::View;
use crate::views;
impl View {
pub fn navigation_destination(
self,
state: &views::BoundState<bool>,
destination: View,
) -> Self {
Self::new(views::navigation_destination(
&self.handle,
state,
destination.handle(),
))
}
pub fn inspector(self, state: &views::BoundState<bool>, content: View) -> Self {
Self::new(views::inspector(&self.handle, state, content.handle()))
}
pub fn inspector_column_width(self, width: f64) -> Self {
Self::new(views::inspector_column_width(&self.handle, width))
}
pub fn inspector_column_width_range(
self,
min: Option<f64>,
ideal: f64,
max: Option<f64>,
) -> Self {
Self::new(views::inspector_column_width_range(&self.handle, min, ideal, max))
}
pub fn toolbar_background(
self,
visibility: views::Visibility,
placements: &[views::ToolbarPlacement],
) -> Self {
Self::new(views::toolbar_background(&self.handle, visibility, placements))
}
pub fn toolbar_visibility(
self,
visibility: views::Visibility,
placements: &[views::ToolbarPlacement],
) -> Self {
Self::new(views::toolbar_visibility(&self.handle, visibility, placements))
}
pub fn toolbar_title_display_mode(self, mode: views::ToolbarTitleDisplayMode) -> Self {
Self::new(views::toolbar_title_display_mode(&self.handle, mode))
}
pub fn toolbar_role(self, role: views::ToolbarRole) -> Self {
Self::new(views::toolbar_role(&self.handle, role))
}
pub fn searchable(
self,
text: &views::BoundState<String>,
presented: &views::BoundState<bool>,
placement: views::SearchFieldPlacement,
prompt: &str,
) -> Self {
Self::new(views::searchable(&self.handle, text, presented, placement, prompt))
}
pub fn navigation_split_view_style_automatic(self) -> Self {
Self::new(views::navigation_split_view_style_automatic(&self.handle))
}
pub fn navigation_view_style_automatic(self) -> Self {
Self::new(views::navigation_view_style_automatic(&self.handle))
}
pub fn navigation_document(self, item: &str) -> Self {
Self::new(views::navigation_document(&self.handle, item))
}
pub fn navigation_document_url(self, spec: &str) -> Self {
Self::new(views::navigation_document_url(&self.handle, spec))
}
pub fn toolbar_background_visibility(
self,
visibility: views::Visibility,
placements: &[views::ToolbarPlacement],
) -> Self {
Self::new(views::toolbar_background_visibility(&self.handle, visibility, placements))
}
pub fn toolbar_color_scheme(
self,
scheme: Option<views::ColorScheme>,
placements: &[views::ToolbarPlacement],
) -> Self {
Self::new(views::toolbar_color_scheme(&self.handle, scheme, placements))
}
pub fn toolbar_title_menu(self, content: View) -> Self {
Self::new(views::toolbar_title_menu(&self.handle, content.handle()))
}
pub fn presentation_sizing(self) -> Self {
Self::new(views::presentation_sizing(&self.handle))
}
pub fn presentation_background_interaction(
self,
value: views::PresentationBackgroundInteraction,
) -> Self {
Self::new(views::presentation_background_interaction(&self.handle, value))
}
pub fn presentation_compact_adaptation(self, value: views::PresentationAdaptation) -> Self {
Self::new(views::presentation_compact_adaptation(&self.handle, value))
}
pub fn presentation_content_interaction(
self,
value: views::PresentationContentInteraction,
) -> Self {
Self::new(views::presentation_content_interaction(&self.handle, value))
}
pub fn navigation_transition(self) -> Self {
Self::new(views::navigation_transition(&self.handle))
}
pub fn navigation_split_view_column_width(self, width: f64) -> Self {
Self::new(views::navigation_split_view_column_width(&self.handle, width))
}
pub fn matched_transition_source(self, id: views::HashableValue<'_>) -> Self {
Self::new(views::matched_transition_source(&self.handle, id))
}
pub fn presentation_detents(self, detents: &[views::PresentationDetent]) -> Self {
Self::new(views::presentation_detents(&self.handle, detents))
}
pub fn presentation_drag_indicator(self, visibility: views::Visibility) -> Self {
Self::new(views::presentation_drag_indicator(&self.handle, visibility))
}
pub fn presentation_corner_radius(self, radius: Option<f64>) -> Self {
Self::new(views::presentation_corner_radius(&self.handle, radius))
}
pub fn presentation_background(self, alignment: views::Alignment, content: View) -> Self {
Self::new(views::presentation_background(
&self.handle,
alignment,
content.handle(),
))
}
pub fn tint_system(self, c: views::SystemColor) -> Self {
Self::new(views::tint_color(&self.handle, views::system_color_value(c)))
}
pub fn search_toolbar_behavior(self, value: views::SearchToolbarBehavior) -> Self {
Self::new(views::search_toolbar_behavior(&self.handle, value))
}
pub fn search_presentation_toolbar_behavior(
self,
value: views::SearchPresentationToolbarBehavior,
) -> Self {
Self::new(views::search_presentation_toolbar_behavior(&self.handle, value))
}
pub fn text_selection_affinity(self, value: views::TextSelectionAffinity) -> Self {
Self::new(views::text_selection_affinity(&self.handle, value))
}
pub fn type_select_equivalent(self, text: Option<&str>) -> Self {
Self::new(views::type_select_equivalent(&self.handle, text))
}
pub fn search_scopes(self, scope: &views::BoundState<i64>, scopes: View) -> Self {
Self::new(views::search_scopes(&self.handle, scope, scopes.handle()))
}
pub fn search_suggestions(
self,
visibility: views::Visibility,
placements: views::SearchSuggestionsPlacementSet,
) -> Self {
Self::new(views::search_suggestions(&self.handle, visibility, placements))
}
pub fn search_selection(self, changed: impl Fn() + 'static) -> Self {
Self::new(views::search_selection(&self.handle, changed))
}
pub fn search_focused(self) -> Self {
Self::new(views::search_focused(&self.handle))
}
pub fn text_input_suggestions(self, count: usize, content: View) -> Self {
Self::new(views::text_input_suggestions(&self.handle, count, content.handle()))
}
pub fn find_navigator(self, state: &views::BoundState<bool>) -> Self {
Self::new(views::find_navigator(&self.handle, state))
}
}