PsPoint.create constructor

PsPoint.create({
  1. required double horizontal,
  2. required double vertical,
  3. String? unit,
})

Creates a Pnt point, storing unit floats when unit is given.

Implementation

factory PsPoint.create({
  required double horizontal,
  required double vertical,
  String? unit,
}) => PsPoint.fromDescriptor(
  PsDescriptor(
    name: '\u0000',
    classId: 'Pnt ',
    items: [
      PsDescriptorItem(key: 'Hrzn', value: _number(horizontal, unit)),
      PsDescriptorItem(key: 'Vrtc', value: _number(vertical, unit)),
    ],
  ),
);