DVUI

autoFit

Resets the autofit of the first pane

Must be called before showFirst

Parameters

#
self:*PanedWidget
*PanedWidget

Source

Implementation

#
pub fn autoFit(self: *PanedWidget) void {
    self.should_autofit = true;
    if (self.init_opts.autofit_first) |autofit| {
        // ensure the first pane is expanded before performing layout
        self.split_ratio.* = @max(self.split_ratio.*, autofit.min_split, 0.001);
        self.collapsing = false;
        self.collapsed_state = false;
    }
}