ResponsiveDesignUtils class

A utility class that provides responsive design functions.

This class adjusts the sizes of various UI components such as text, padding, and flags, depending on the current screen width.

Constructors

ResponsiveDesignUtils()

Properties

hashCode int
The hash code for this object.
no setterinherited
runtimeType Type
A representation of the runtime type of the object.
no setterinherited

Methods

noSuchMethod(Invocation invocation) → dynamic
Invoked when a nonexistent method or property is accessed.
inherited
toString() String
A string representation of this object.
inherited

Operators

operator ==(Object other) bool
The equality operator.
inherited

Static Methods

getBackNavigationSizes({required double currentScreenWidth}) WidgetSizeValues
Returns the size and padding for the back navigation icon, adjusted according to the screen width.
getListItemTitleFontSize(double currentScreenWidth) double
Returns the font size for list item titles, adjusted according to the screen width.
getOptimalHorizontalPadding({required double minPadding, required double currentScreenWidth, double? maxWidgetWidthOverwrite}) double
Calculates the optimal horizontal padding to ensure the content width does not exceed 800px.
getPanelPadding(double currentScreenWidth) double
Returns the padding for panels, adjusted according to the screen width.
getScreenTitleSize(double currentScreenWidth) double
Returns the font size for the screen title, adjusted according to the screen width.
getScreenTitleWidth(double currentScreenWidth) double
Returns the width of the screen title, adjusted based on the screen width.
getSettingsTileTextMaxWidth(double currentScreenWidth) double
Returns the maximum width for the settings tile text, adjusted according to the screen width.
getUserSettingFlagHeight(double currentScreenWidth) double
Returns the height for the user setting flag, adjusted according to the screen width.
getUserSettingFlagWidth(double currentScreenWidth) double
Returns the width for the user setting flag, adjusted according to the screen width.
interpolateBestDouble(InterpolationDoubleValues values, double currentScreenWidth, {bool invertedLogic = false}) double
Interpolates a value between a minimum and maximum range based on the screen width. Optionally inverts the logic, returning higher values for smaller widths and lower values for larger widths if invertedLogic is set to true.