Struct style::logical_geometry::LogicalSize
[−]
[src]
pub struct LogicalSize<T> {
pub inline: T,
pub block: T,
// some fields omitted
}A 2D size in flow-relative dimensions
Fields
inline: T
block: T
Methods
impl<T: Zero> LogicalSize<T>[src]
pub fn zero(mode: WritingMode) -> LogicalSize<T>[src]
impl<T: Copy> LogicalSize<T>[src]
pub fn new(mode: WritingMode, inline: T, block: T) -> LogicalSize<T>[src]
pub fn from_physical(mode: WritingMode, size: Size2D<T>) -> LogicalSize<T>[src]
pub fn width(&self, mode: WritingMode) -> T[src]
pub fn set_width(&mut self, mode: WritingMode, width: T)[src]
pub fn height(&self, mode: WritingMode) -> T[src]
pub fn set_height(&mut self, mode: WritingMode, height: T)[src]
pub fn to_physical(&self, mode: WritingMode) -> Size2D<T>[src]
pub fn convert(
&self,
mode_from: WritingMode,
mode_to: WritingMode
) -> LogicalSize<T>[src]
&self,
mode_from: WritingMode,
mode_to: WritingMode
) -> LogicalSize<T>
Trait Implementations
impl<T: Clone> Clone for LogicalSize<T>[src]
fn clone(&self) -> LogicalSize<T>[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)1.0.0[src]
Performs copy-assignment from source. Read more
impl<T: Copy> Copy for LogicalSize<T>[src]
impl<T: Eq> Eq for LogicalSize<T>[src]
impl<T: PartialEq> PartialEq for LogicalSize<T>[src]
fn eq(&self, __arg_0: &LogicalSize<T>) -> bool[src]
This method tests for self and other values to be equal, and is used by ==. Read more
fn ne(&self, __arg_0: &LogicalSize<T>) -> bool[src]
This method tests for !=.
impl<T: Debug> Debug for LogicalSize<T>[src]
fn fmt(&self, formatter: &mut Formatter) -> Result<(), Error>[src]
Formats the value using the given formatter. Read more
impl<T: Add<T, Output = T>> Add for LogicalSize<T>[src]
type Output = LogicalSize<T>
The resulting type after applying the + operator.
fn add(self, other: LogicalSize<T>) -> LogicalSize<T>[src]
Performs the + operation.
impl<T: Sub<T, Output = T>> Sub for LogicalSize<T>[src]
type Output = LogicalSize<T>
The resulting type after applying the - operator.
fn sub(self, other: LogicalSize<T>) -> LogicalSize<T>[src]
Performs the - operation.
impl<T: Copy + Add<T, Output = T>> Add<LogicalSize<T>> for LogicalPoint<T>[src]
type Output = LogicalPoint<T>
The resulting type after applying the + operator.
fn add(self, other: LogicalSize<T>) -> LogicalPoint<T>[src]
Performs the + operation.
impl<T: Copy + Sub<T, Output = T>> Sub<LogicalSize<T>> for LogicalPoint<T>[src]
type Output = LogicalPoint<T>
The resulting type after applying the - operator.
fn sub(self, other: LogicalSize<T>) -> LogicalPoint<T>[src]
Performs the - operation.