pub enum MacroContent {
Circle(CirclePrimitive),
VectorLine(VectorLinePrimitive),
CenterLine(CenterLinePrimitive),
Outline(OutlinePrimitive),
Polygon(PolygonPrimitive),
Moire(MoirePrimitive),
Thermal(ThermalPrimitive),
VariableDefinition(VariableDefinition),
Comment(String),
}Expand description
Gerber specification (2021.02 - 2024.05) 4.5.1.1 Primitives / Overview “Except for the comment all the parameters can be a decimal, integer, macro variables or an arithmetic expression”
However, AFAICT (DC), it doesn’t make sense for a the Vertices of the Outline to be a macro variable or expression. Only a literal makes sense since the amount of co-ordinate arguments for the macro cannot change after it is defined and the last point of an outline has to be the same as the first point.
FUTURE report this specification inconsistency with UCamco and provide a support reference or link here.
Fortunately for us the OutlinePrimitive doesn’t need to store the amount of vertices since it uses a Vec to store the points.
Variants§
Circle(CirclePrimitive)
VectorLine(VectorLinePrimitive)
CenterLine(CenterLinePrimitive)
Outline(OutlinePrimitive)
Polygon(PolygonPrimitive)
Moire(MoirePrimitive)
Thermal(ThermalPrimitive)
VariableDefinition(VariableDefinition)
Comment(String)
Trait Implementations§
Source§impl Clone for MacroContent
impl Clone for MacroContent
Source§fn clone(&self) -> MacroContent
fn clone(&self) -> MacroContent
Returns a duplicate of the value. Read more
1.0.0§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for MacroContent
impl Debug for MacroContent
Source§impl From<CenterLinePrimitive> for MacroContent
impl From<CenterLinePrimitive> for MacroContent
Source§fn from(val: CenterLinePrimitive) -> MacroContent
fn from(val: CenterLinePrimitive) -> MacroContent
Converts to this type from the input type.
Source§impl From<CirclePrimitive> for MacroContent
impl From<CirclePrimitive> for MacroContent
Source§fn from(val: CirclePrimitive) -> MacroContent
fn from(val: CirclePrimitive) -> MacroContent
Converts to this type from the input type.
Source§impl From<MoirePrimitive> for MacroContent
impl From<MoirePrimitive> for MacroContent
Source§fn from(val: MoirePrimitive) -> MacroContent
fn from(val: MoirePrimitive) -> MacroContent
Converts to this type from the input type.
Source§impl From<OutlinePrimitive> for MacroContent
impl From<OutlinePrimitive> for MacroContent
Source§fn from(val: OutlinePrimitive) -> MacroContent
fn from(val: OutlinePrimitive) -> MacroContent
Converts to this type from the input type.
Source§impl From<PolygonPrimitive> for MacroContent
impl From<PolygonPrimitive> for MacroContent
Source§fn from(val: PolygonPrimitive) -> MacroContent
fn from(val: PolygonPrimitive) -> MacroContent
Converts to this type from the input type.
Source§impl From<ThermalPrimitive> for MacroContent
impl From<ThermalPrimitive> for MacroContent
Source§fn from(val: ThermalPrimitive) -> MacroContent
fn from(val: ThermalPrimitive) -> MacroContent
Converts to this type from the input type.
Source§impl From<VariableDefinition> for MacroContent
impl From<VariableDefinition> for MacroContent
Source§fn from(val: VariableDefinition) -> MacroContent
fn from(val: VariableDefinition) -> MacroContent
Converts to this type from the input type.
Source§impl From<VectorLinePrimitive> for MacroContent
impl From<VectorLinePrimitive> for MacroContent
Source§fn from(val: VectorLinePrimitive) -> MacroContent
fn from(val: VectorLinePrimitive) -> MacroContent
Converts to this type from the input type.
Source§impl PartialEq for MacroContent
impl PartialEq for MacroContent
impl StructuralPartialEq for MacroContent
Auto Trait Implementations§
impl Freeze for MacroContent
impl RefUnwindSafe for MacroContent
impl Send for MacroContent
impl Sync for MacroContent
impl Unpin for MacroContent
impl UnwindSafe for MacroContent
Blanket Implementations§
§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
§unsafe fn clone_to_uninit(&self, dest: *mut u8)
unsafe fn clone_to_uninit(&self, dest: *mut u8)
🔬This is a nightly-only experimental API. (
clone_to_uninit)