pub enum PostScriptOp<'a> {
Show 44 variants
Real(f32),
Integer(i32),
Abs,
Add,
Atan,
Ceiling,
Cos,
Cvi,
Cvr,
Div,
Exp,
Floor,
Idiv,
Ln,
Log,
Mod,
Mul,
Neg,
Round,
Sin,
Sqrt,
Sub,
Truncate,
And,
Bitshift,
Eq,
False,
Ge,
Gt,
Le,
Lt,
Ne,
Not,
Or,
True,
Xor,
If(&'a [Self]),
IfElse(&'a [Self], &'a [Self]),
Copy,
Dup,
Exch,
Index,
Pop,
Roll,
}
Expand description
PostScript operators for use in Type 4 functions.
Variants§
Real(f32)
Push a real number.
Integer(i32)
Push an integer number.
Abs
Absolute value. One number argument.
Add
Addition. Two number arguments.
Atan
Arc tangent. One number argument.
Ceiling
Round up to the nearest integer. One number argument.
Cos
Cosine. One number argument.
Cvi
Convert to integer. One real number argument.
Cvr
Convert to real. One integer argument.
Div
Divide. Two number arguments.
Exp
Raise the base to the exponent. Two number arguments.
Floor
Round down to the nearest integer. One number argument.
Idiv
Integer division. Two integer arguments.
Ln
Natural logarithm. One number argument.
Log
Logarithm base 10. One number argument.
Mod
Modulo. Two integer arguments.
Mul
Multiply. Two number arguments.
Neg
Negate. One number argument.
Round
Round to the nearest integer. One number argument.
Sin
Sine. One number argument.
Sqrt
Square root. One number argument.
Sub
Subtract. Two number arguments.
Truncate
Remove fractional part. One number argument.
And
Logical bitwise And. Two integer or boolean arguments.
Bitshift
Bitwise shift left. Negative shifts possible. Two integer arguments.
Eq
Equals. Any two arguments of the same type.
False
Constant false.
Ge
Greater than or equal. Two number arguments.
Gt
Greater than. Two number arguments.
Le
Less than or equal. Two number arguments.
Lt
Less than. Two number arguments.
Ne
Not equals. Any two arguments of the same type.
Not
Bitwise logical not. One integer or boolean argument.
Or
Bitwise logical or. Two integer or boolean arguments.
True
Constant true.
Xor
Bitwise logical exclusive or. Two integer or boolean arguments.
If(&'a [Self])
Conditional. Runs if boolean argument is true.
IfElse(&'a [Self], &'a [Self])
Conditional. Decides which branch to run depending on boolean argument.
Copy
Copy the top elements. One integer argument.
Dup
Duplicate the top element.
Exch
Exchange the two top elements.
Index
Duplicate any element. One integer argument.
Pop
Discard the top element.
Roll
Roll n
elements up j
times. Two integer arguments.
Implementations§
Trait Implementations§
source§impl<'a> Clone for PostScriptOp<'a>
impl<'a> Clone for PostScriptOp<'a>
source§fn clone(&self) -> PostScriptOp<'a>
fn clone(&self) -> PostScriptOp<'a>
1.6.0 · source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source
. Read moresource§impl<'a> Debug for PostScriptOp<'a>
impl<'a> Debug for PostScriptOp<'a>
source§impl<'a> PartialEq for PostScriptOp<'a>
impl<'a> PartialEq for PostScriptOp<'a>
impl<'a> Copy for PostScriptOp<'a>
impl<'a> StructuralPartialEq for PostScriptOp<'a>
Auto Trait Implementations§
impl<'a> Freeze for PostScriptOp<'a>
impl<'a> RefUnwindSafe for PostScriptOp<'a>
impl<'a> Send for PostScriptOp<'a>
impl<'a> Sync for PostScriptOp<'a>
impl<'a> Unpin for PostScriptOp<'a>
impl<'a> UnwindSafe for PostScriptOp<'a>
Blanket Implementations§
source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
source§unsafe fn clone_to_uninit(&self, dst: *mut T)
unsafe fn clone_to_uninit(&self, dst: *mut T)
clone_to_uninit
)