Struct style::servo::media_queries::Expression
[−]
[src]
pub struct Expression(pub ExpressionKind);
A single expression a per:
Methods
impl Expression
[src]
pub fn kind_for_testing(&self) -> &ExpressionKind
[src]
The kind of expression we're, just for unit testing.
Eventually this will become servo-only.
pub fn parse<'i, 't>(
context: &ParserContext,
input: &mut Parser<'i, 't>
) -> Result<Self, ParseError<'i>>
[src]
context: &ParserContext,
input: &mut Parser<'i, 't>
) -> Result<Self, ParseError<'i>>
Parse a media expression of the form:
(media-feature: media-value)
Only supports width and width ranges for now.
pub fn matches(&self, device: &Device, quirks_mode: QuirksMode) -> bool
[src]
Evaluate this expression and return whether it matches the current device.
Trait Implementations
impl Clone for Expression
[src]
fn clone(&self) -> Expression
[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 Debug for Expression
[src]
fn fmt(&self, __arg_0: &mut Formatter) -> Result
[src]
Formats the value using the given formatter. Read more
impl PartialEq for Expression
[src]
fn eq(&self, __arg_0: &Expression) -> bool
[src]
This method tests for self
and other
values to be equal, and is used by ==
. Read more
fn ne(&self, __arg_0: &Expression) -> bool
[src]
This method tests for !=
.
impl MallocSizeOf for Expression
[src]
fn size_of(&self, ops: &mut MallocSizeOfOps) -> usize
[src]
Measure the heap usage of all descendant heap-allocated structures, but not the space taken up by the value itself. Read more